sqllogictest
Artifact Content
Not logged in

Artifact 16ab3a835c3876681001b52749cb05a65de509fd:


hash-threshold 8

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

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

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

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

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

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

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

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

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

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-0
SELECT DISTINCT + 25 - + tab2.col0 * CAST( - col1 AS SIGNED ) AS col0 FROM tab2
----
1368
242
4627

skipif mysql # not compatible
query I rowsort label-0
SELECT DISTINCT + 25 - + tab2.col0 * CAST ( - col1 AS INTEGER ) AS col0 FROM tab2
----
1368
242
4627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + 28 col0 FROM tab1
----
-36
-52
25

query I rowsort
SELECT ALL - col0 + 66 * col1 AS col2 FROM tab2
----
1043
2039
3816

query I rowsort
SELECT col2 * - col1 * col1 + col2 FROM tab1
----
-16128
-36450
-5643

query I rowsort
SELECT - col1 * - ( col0 * col0 ) + col1 * + col2 * + tab1.col1 FROM tab1
----
36738
46660
99424

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

query I rowsort
SELECT + 95 FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT ( + col0 ) * ( + 78 * cor0.col2 ) + ( + col0 + + col1 ) FROM tab0 AS cor0
----
2862
569424
61886

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

query I rowsort
SELECT 31 * - col0 AS col1 FROM tab2 AS cor0
----
-217
-2418
-2449

query I rowsort
SELECT DISTINCT 26 + + col1 * - col2 AS col1 FROM tab0 AS cor0
----
-2812
-71
-7436

query I rowsort
SELECT 23 * - col1 - + 57 FROM tab0 AS cor0
----
-2035
-2150
-2288

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

query I rowsort
SELECT + - col1 + + col0 * - 56 FROM tab0 AS cor0
----
-1430
-2057
-5075

onlyif mysql # use DIV operator for integer division
query I rowsort label-18
SELECT DISTINCT - col1 * + col0 * CAST( col1 AS SIGNED ) - col1 DIV col0 FROM tab1 AS cor0
----
-13520
-2036
-6400

skipif mysql # not compatible
query I rowsort label-18
SELECT DISTINCT - col1 * + col0 * CAST ( col1 AS INTEGER ) - col1 / col0 FROM tab1 AS cor0
----
-13520
-2036
-6400

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

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

query I rowsort
SELECT + 94 + - col2 + col0 * - col2 FROM tab0 AS cor0
----
-7286
-731
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 53 * + col0 + col0 col1 FROM tab2 cor0
----
-364
-4056
-4108

query I rowsort
SELECT DISTINCT - 87 AS col0 FROM tab1
----
-87

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( col0 AS REAL ) * - col2 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-26
SELECT + - ( col2 ) DIV col0 - - col0 FROM tab2 AS cor0
----
4
78
79

skipif mysql # not compatible
query I rowsort label-26
SELECT + - ( col2 ) / col0 - - col0 FROM tab2 AS cor0
----
4
78
79

query I rowsort
SELECT + col1 + - 76 + tab2.col0 FROM tab2
----
-38
20
61

query I rowsort
SELECT DISTINCT col1 - + 86 AS col1 FROM tab1
----
-60
-73
-76

query I rowsort
SELECT ALL - 58 FROM tab0, tab0 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 897f42d096eff3935f4f50603850c23b

query I rowsort
SELECT ALL - col1 + 27 AS col2 FROM tab0 AS cor0
----
-59
-64
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col0 ) * cor0.col0 * 27 col0 FROM tab1 AS cor0
----
-110592
-172800
-243

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

query I rowsort
SELECT + ( - 86 ) * tab2.col2 AS col1 FROM tab2
----
-2236
-2322
-3268

query I rowsort
SELECT ALL 52 * + tab0.col2 FROM tab0, tab1, tab2 AS cor0, tab2
----
81 values hashing to 090f198ecfaf0fff0392460cf03d1a83

query I rowsort
SELECT 63 + ( + col2 ) * + col2 AS col0 FROM tab2
----
1507
739
792

query I rowsort
SELECT DISTINCT + col0 + tab1.col1 * + col0 + + col1 FROM tab1
----
107
1133
714

query I rowsort
SELECT DISTINCT - 81 + 38 AS col0 FROM tab0
----
-43

query I rowsort
SELECT DISTINCT - ( - col0 ) + col1 + + 11 * - col0 FROM tab0
----
-154
-253
-799

query I rowsort
SELECT DISTINCT + - col0 + + ( col2 ) AS col0 FROM tab2 AS cor0
----
-41
-52
20

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

query I rowsort
SELECT DISTINCT + col0 + + 68 AS col0 FROM tab0 AS cor0
----
103
157
92

query I rowsort
SELECT col1 * col1 * - 8 FROM tab1 AS cor0
----
-1352
-5408
-800

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

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

skipif mysql # not compatible
query I rowsort label-44
SELECT - + col0 + - col2 / cor0.col1 AS col2 FROM tab2 AS cor0
----
-7
-78
-81

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

query I rowsort
SELECT ALL + col2 + ( - col2 ) * - col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT 36 + + col2 AS col1 FROM tab2
----
62
63
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-48
SELECT ALL + col1 * ( - col0 ) DIV col0 AS col1 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-48
SELECT ALL + col1 * ( - col0 ) / col0 AS col1 FROM tab2 AS cor0
----
-17
-31
-59

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

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

query I rowsort
SELECT ALL + col2 * 24 FROM tab2 AS cor0
----
624
648
912

onlyif mysql # use DIV operator for integer division
query I rowsort label-52
SELECT DISTINCT col0 + - 12 DIV col0 col2 FROM tab1 cor0
----
-1
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-52
SELECT DISTINCT col0 + - 12 / col0 col2 FROM tab1 cor0
----
-1
64
80

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

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

query I rowsort
SELECT ALL - 71 FROM tab0, tab0 AS cor0
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

onlyif mysql # use DIV operator for integer division
query I rowsort label-55
SELECT - - col0 + + cor0.col0 DIV cor0.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-55
SELECT - - col0 + + cor0.col0 / cor0.col0 col2 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT ALL - cor0.col2 AS col2 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT ALL col2 * + ( 15 ) FROM tab1
----
1440
810
855

query I rowsort
SELECT + cor0.col2 AS col2 FROM tab2, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( - col2 AS REAL ) * col2 + - col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT + ( col1 ) + - col2 * ( cor0.col0 ) * col2 FROM tab0 AS cor0
----
-26050
-598345
62

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

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

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

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

query I rowsort
SELECT 55 AS col1 FROM tab1 cor0
----
55
55
55

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

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

query I rowsort
SELECT - 49 * cor0.col0 + + col0 + - col2 AS col2 FROM tab1 AS cor0
----
-198
-3129
-3936

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-69
SELECT DISTINCT col1 DIV 17 FROM tab0 AS cor0
----
5

skipif mysql # not compatible
query I rowsort label-69
SELECT DISTINCT col1 / 17 FROM tab0 AS cor0
----
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col1 * - 6 col1 FROM tab0 AS cor0
----
-430
-455
-485

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

query I rowsort
SELECT + - col0 * + ( - 94 * + col0 ) FROM tab0 AS cor0
----
115150
54144
744574

onlyif mysql # use DIV operator for integer division
query I rowsort label-73
SELECT - 95 DIV col2 + + col0 + ( - col2 ) FROM tab1
----
-16
-52
6

skipif mysql # not compatible
query I rowsort label-73
SELECT - 95 / col2 + + col0 + ( - col2 ) FROM tab1
----
-16
-52
6

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

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( - col2 AS REAL ) - - col0 AS col0 FROM tab2
----
-20
41
52

query I rowsort
SELECT - 79 AS col0 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to c9cc9510604e093bd158ca33928acaed

onlyif mysql # use DIV operator for integer division
query I rowsort label-77
SELECT - col1 + - col0 DIV + tab1.col1 + col0 AS col0 FROM tab1
----
-23
48
61

skipif mysql # not compatible
query I rowsort label-77
SELECT - col1 + - col0 / + tab1.col1 + col0 AS col0 FROM tab1
----
-23
48
61

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-79
SELECT - 53 DIV col0 FROM tab1 AS cor0
----
-17
0
0

skipif mysql # not compatible
query I rowsort label-79
SELECT - 53 / col0 FROM tab1 AS cor0
----
-17
0
0

query I rowsort
SELECT ALL - 74 + col0 * ( ( - col1 ) + + col2 ) FROM tab1 AS cor0
----
10
2934
6566

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

query I rowsort
SELECT DISTINCT + + 4 * - col0 AS col2 FROM tab2 cor0
----
-28
-312
-316

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-85
SELECT DISTINCT + 80 DIV - cor0.col1 AS col0 FROM tab1 AS cor0
----
-3
-6
-8

skipif mysql # not compatible
query I rowsort label-85
SELECT DISTINCT + 80 / - cor0.col1 AS col0 FROM tab1 AS cor0
----
-3
-6
-8

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

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

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

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

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

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

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

query I rowsort
SELECT ALL 19 * + col1 AS col1 FROM tab2 AS cor0
----
1121
323
589

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

query I rowsort
SELECT DISTINCT + + 94 + - cor0.col2 FROM tab2 AS cor0
----
56
67
68

query I rowsort
SELECT + col0 - + 78 * col1 AS col2 FROM tab0
----
-6684
-7009
-7531

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

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

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

query I rowsort
SELECT - + 80 - col1 * + col2 FROM tab2 AS cor0
----
-1614
-726
-917

query I rowsort
SELECT ALL 35 + col2 FROM tab1 AS cor0
----
131
89
92

query I rowsort
SELECT ALL + col1 + 78 * - col0 AS col2 FROM tab2 AS cor0
----
-515
-6025
-6145

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

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

query I rowsort
SELECT ( + 35 ) + col2 AS col1 FROM tab2 AS cor0
----
61
62
73

query I rowsort
SELECT DISTINCT col1 * col1 + + col2 - + ( - 81 ) * col1 FROM tab1 AS cor0
----
1318
2836
967

onlyif mysql # use DIV operator for integer division
query I rowsort label-105
SELECT ALL col0 DIV 51 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-105
SELECT ALL col0 / 51 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT ALL 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-107
SELECT DISTINCT CAST( ( col2 ) AS SIGNED ) FROM tab1 AS cor0
----
54
57
96

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

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

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

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

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

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

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

query I rowsort
SELECT ALL 70 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

query I rowsort
SELECT + cor0.col1 * 95 AS col1 FROM tab0 AS cor0
----
8170
8645
9215

query I rowsort
SELECT 64 * col2 * col0 AS col0 FROM tab2 AS cor0
----
12096
129792
192128

onlyif mysql # use DIV operator for integer division
query I rowsort label-115
SELECT + CAST( col0 AS SIGNED ) DIV tab0.col1 - 74 col0 FROM tab0
----
-74
-74
-74

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-115
SELECT + CAST ( col0 AS INTEGER ) / tab0.col1 - 74 col0 FROM tab0
----
-74
-74
-74

onlyif mysql # use DIV operator for integer division
query I rowsort label-116
SELECT ALL tab0.col1 DIV ( col0 ) - ( 46 ) FROM tab0
----
-43
-44
-45

skipif mysql # not compatible
query I rowsort label-116
SELECT ALL tab0.col1 / ( col0 ) - ( 46 ) FROM tab0
----
-43
-44
-45

query I rowsort
SELECT DISTINCT + - col2 + - cor0.col0 * 38 * + 26 FROM tab0 AS cor0
----
-23745
-34581
-88014

query I rowsort
SELECT - col0 - col0 * + 69 FROM tab0 AS cor0
----
-1680
-2450
-6230

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

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

query I rowsort
SELECT + tab0.col1 AS col0 FROM tab0, tab2 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ALL + 63 - + tab2.col0 FROM tab2
----
-15
-16
56

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

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

query I rowsort
SELECT - ( col2 ) * + col2 + + col0 FROM tab1
----
-2913
-3185
-9136

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

query I rowsort
SELECT DISTINCT - col1 * 99 FROM tab0 cor0
----
-8514
-9009
-9603

query I rowsort
SELECT ALL - col0 * + 65 AS col0 FROM tab2 AS cor0
----
-455
-5070
-5135

query I rowsort
SELECT - col2 * + 76 FROM tab1 AS cor0
----
-4104
-4332
-7296

query I rowsort
SELECT ALL col1 * 39 * - col1 AS col2 FROM tab0
----
-288444
-322959
-366951

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

query I rowsort
SELECT - - col2 * 4 AS col0 FROM tab1 AS cor0
----
216
228
384

query I rowsort
SELECT ALL - col0 * + cor0.col2 + 33 FROM tab0 AS cor0
----
-2
-7265
-759

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

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

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

query I rowsort
SELECT ALL - - col2 - col1 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-135
SELECT - col1 * col1 * CAST( 66 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-11154
-44616
-6600

skipif mysql # not compatible
query I rowsort label-135
SELECT - col1 * col1 * CAST ( 66 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-11154
-44616
-6600

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

query I rowsort
SELECT + 53 * col0 AS col1 FROM tab0 AS cor0
----
1272
1855
4717

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

query I rowsort
SELECT ALL + + 34 * col2 FROM tab1 AS cor0
----
1836
1938
3264

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

query I rowsort
SELECT ALL + 44 - col1 * + col2 AS col1 FROM tab1 AS cor0
----
-1204
-1360
-526

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

query I rowsort
SELECT DISTINCT + col0 * col2 * + 65 AS col0 FROM tab0 AS cor0
----
2275
474370
51480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 58 + 68 col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 19b1f1fcc466c23e5267b585248665fc

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

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-147
SELECT DISTINCT + CAST( + 45 * cor0.col2 AS SIGNED ) FROM tab1, tab1 cor0, tab0 AS cor1, tab2 AS cor2
----
2430
2565
4320

skipif mysql # not compatible
query I rowsort label-147
SELECT DISTINCT + CAST ( + 45 * cor0.col2 AS INTEGER ) FROM tab1, tab1 cor0, tab0 AS cor1, tab2 AS cor2
----
2430
2565
4320

query I rowsort
SELECT + - cor0.col0 * - col1 + + col0 * - 42 FROM tab1 AS cor0
----
-2048
-2320
-48

query I rowsort
SELECT ALL col1 * - 19 * tab0.col1 FROM tab0
----
-140524
-157339
-178771

onlyif mysql # use DIV operator for integer division
query I rowsort label-150
SELECT ALL ( + 76 ) DIV - col0 AS col1 FROM tab0 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-150
SELECT ALL ( + 76 ) / - col0 AS col1 FROM tab0 AS cor0
----
-2
-3
0

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

query I rowsort
SELECT col0 * + tab0.col2 * col2 + col1 FROM tab0
----
132
26222
598527

query I rowsort
SELECT + 9 AS col2 FROM tab1
----
9
9
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + 81 col1 FROM tab0
----
2673
6642
81

query I rowsort
SELECT col2 + ( tab2.col0 + col0 ) AS col0 FROM tab2
----
182
196
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-156
SELECT - col0 DIV 24 + + col0 * - col2 * 93 FROM tab2
----
-17577
-188607
-279189

skipif mysql # not compatible
query I rowsort label-156
SELECT - col0 / 24 + + col0 * - col2 * 93 FROM tab2
----
-17577
-188607
-279189

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

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

query I rowsort
SELECT + + col1 + + col1 * 1 AS col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT + + col0 * + 95 + cor0.col1 AS col1 FROM tab0 AS cor0
----
2366
3422
8546

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

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

query I rowsort
SELECT + col2 + 9 AS col1 FROM tab1
----
105
63
66

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

query I rowsort
SELECT DISTINCT - col1 + 69 * - ( tab0.col0 ) FROM tab0
----
-1742
-2512
-6232

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-167
SELECT DISTINCT - 53 DIV - 12 + + cor0.col1 AS col1 FROM tab0, tab2 AS cor0
----
21
35
63

skipif mysql # not compatible
query I rowsort label-167
SELECT DISTINCT - 53 / - 12 + + cor0.col1 AS col1 FROM tab0, tab2 AS cor0
----
21
35
63

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

query I rowsort
SELECT DISTINCT col0 + 16 FROM tab1
----
19
80
96

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 10 col0 FROM tab0, tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

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

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

query I rowsort
SELECT - 85 + ( - col1 ) FROM tab0 AS cor0
----
-171
-176
-182

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-176
SELECT - col2 * col0 + + col2 DIV - ( - col1 + col0 ) FROM tab2 AS cor0
----
-188
-2029
-3002

skipif mysql # not compatible
query I rowsort label-176
SELECT - col2 * col0 + + col2 / - ( - col1 + col0 ) FROM tab2 AS cor0
----
-188
-2029
-3002

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

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

query I rowsort
SELECT col0 - - 16 AS col1 FROM tab2 AS cor0
----
23
94
95

query I rowsort
SELECT - 35 * + col0 * 87 FROM tab1
----
-194880
-243600
-9135

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-183
SELECT - + col0 - 39 DIV col1 FROM tab2 AS cor0
----
-78
-8
-81

skipif mysql # not compatible
query I rowsort label-183
SELECT - + col0 - 39 / col1 FROM tab2 AS cor0
----
-78
-8
-81

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

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

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

skipif mysql # not compatible
query I rowsort label-185
SELECT ALL + col1 * col0 / col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + col1 * 35 + col1 FROM tab2
----
1116
2124
612

query I rowsort
SELECT - col1 * col1 - col2 FROM tab2 AS cor0
----
-327
-3507
-988

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

query I rowsort
SELECT - col0 + 9 * - col2 FROM tab2 AS cor0
----
-250
-312
-421

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

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

query I rowsort
SELECT - + col1 * cor0.col1 + - col1 FROM tab0 AS cor0
----
-7482
-8372
-9506

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

query I rowsort
SELECT ALL ( - col2 * - col0 ) + + col2 * - col2 AS col1 FROM tab0
----
-297
34
574

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 7 + 99 * col2 col0 FROM tab2 AS cor0
----
2581
2680
3769

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 cor0, tab2 AS cor1, tab2 AS cor2
----
972 values hashing to 958533d1a7bf61199ed7c03eadf37f9a

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

query I rowsort
SELECT ALL 68 + col1 * - col1 * + col0 AS col1 FROM tab1 AS cor0
----
-13452
-1960
-6332

query I rowsort
SELECT ALL - 10 * + col1 + col1 AS col2 FROM tab2 cor0
----
-153
-279
-531

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col2 col0 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT + - 24 + col2 FROM tab0 cor0
----
-23
58
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + cor0.col1 * - col2 col1 FROM tab0 AS cor0
----
-2805
-7380
-96

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col1 + ( - col1 ) * col0 col0 FROM tab1 AS cor0
----
-70
1326
208

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

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

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - - col1 + col2 * CAST ( col1 AS REAL ) AS col2 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT - - col1 * + col2 + 78 FROM tab0 AS cor0
----
175
2916
7540

onlyif mysql # use DIV operator for integer division
query I rowsort label-213
SELECT DISTINCT + col2 + cor0.col0 DIV - col1 + col2 FROM tab0 AS cor0
----
164
2
66

skipif mysql # not compatible
query I rowsort label-213
SELECT DISTINCT + col2 + cor0.col0 / - col1 + col2 FROM tab0 AS cor0
----
164
2
66

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

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

query I rowsort
SELECT - - cor0.col0 * + 24 AS col1 FROM tab1 AS cor0
----
1536
1920
72

query I rowsort
SELECT ALL + col2 + 19 + + ( col1 * 84 ) AS col1 FROM tab1 AS cor0
----
1207
2257
916

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

query I rowsort
SELECT DISTINCT - col2 * 12 FROM tab2 AS cor0
----
-312
-324
-456

query I rowsort
SELECT + + 80 * col0 + + col0 * - col0 + - col2 AS col2 FROM tab2 AS cor0
----
130
41
484

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 61 col1 FROM tab2 cor0
----
1037
1891
3599

query I rowsort
SELECT ALL + + 72 FROM tab1 AS cor0
----
72
72
72

query I rowsort
SELECT 79 + + col1 FROM tab0 AS cor0
----
165
170
176

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

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

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

query I rowsort
SELECT DISTINCT 12 + col1 AS col0 FROM tab1
----
22
25
38

query I rowsort
SELECT DISTINCT col0 * tab2.col1 + + col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT + 85 AS col1 FROM tab2 cor0
----
85
85
85

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

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

query I rowsort
SELECT col2 * - 82 * tab0.col2 FROM tab0
----
-551368
-82
-89298

onlyif mysql # use DIV operator for integer division
query I rowsort label-231
SELECT 63 * ( + col2 ) + + 72 DIV col2 AS col2 FROM tab0
----
135
2081
5166

skipif mysql # not compatible
query I rowsort label-231
SELECT 63 * ( + col2 ) + + 72 / col2 AS col2 FROM tab0
----
135
2081
5166

query I rowsort
SELECT DISTINCT col1 + 83 AS col2 FROM tab1
----
109
93
96

query I rowsort
SELECT ALL + col1 * - 65 * col0 + ( col1 ) * - col2 AS col2 FROM tab1
----
-42170
-6474
-68848

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col1 * - col2 col1 FROM tab0
----
-132
-2862
-7551

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

query I rowsort
SELECT DISTINCT + 43 + + col0 * + col2 AS col0 FROM tab0
----
7341
78
835

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

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

query I rowsort
SELECT DISTINCT col0 + 76 + col1 AS col1 FROM tab1
----
105
150
169

query I rowsort
SELECT ALL col1 * - 72 FROM tab2
----
-1224
-2232
-4248

query I rowsort
SELECT - + 76 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

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

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

query I rowsort
SELECT col0 * - col2 * ( col2 ) AS col2 FROM tab1
----
-207936
-737280
-8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-243
SELECT ALL + + 75 * 38 + col2 DIV - ( + col1 ) AS col0 FROM tab2 AS cor0
----
2848
2850
2850

skipif mysql # not compatible
query I rowsort label-243
SELECT ALL + + 75 * 38 + col2 / - ( + col1 ) AS col0 FROM tab2 AS cor0
----
2848
2850
2850

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-245
SELECT cor1.col1 + + CAST( + 65 AS SIGNED ) * cor0.col1 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 9b5b31457c825ad4391014f5027ef04a

skipif mysql # not compatible
query I rowsort label-245
SELECT cor1.col1 + + CAST ( + 65 AS INTEGER ) * cor0.col1 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 9b5b31457c825ad4391014f5027ef04a

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + col1 ) * col0 + 79 col0 FROM tab0 cor0
----
-1985
-3316
-8020

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-251
SELECT + 86 DIV + col1 FROM tab1
----
3
6
8

skipif mysql # not compatible
query I rowsort label-251
SELECT + 86 / + col1 FROM tab1
----
3
6
8

query I rowsort
SELECT + 3 * tab2.col2 FROM tab2
----
114
78
81

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

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

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

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

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

query I rowsort
SELECT - - col0 * 65 FROM tab2 AS cor0
----
455
5070
5135

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

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

query I rowsort
SELECT DISTINCT + + col1 + ( 9 ) FROM tab1 AS cor0
----
19
22
35

query I rowsort
SELECT ALL - - col2 + ( col1 ) + + col2 FROM tab2 AS cor0
----
111
85
93

query I rowsort
SELECT DISTINCT - col1 * 90 FROM tab1 AS cor0
----
-1170
-2340
-900

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

query I rowsort
SELECT + cor0.col1 * - 47 FROM tab2 AS cor0
----
-1457
-2773
-799

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

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

query I rowsort
SELECT DISTINCT - col2 * 93 + + col0 * cor0.col1 FROM tab2 AS cor0
----
-2191
-2294
2184

query I rowsort
SELECT col2 + 11 FROM tab1 AS cor0
----
107
65
68

query I rowsort
SELECT DISTINCT - - col1 + - col0 * col1 + col0 FROM tab1 AS cor0
----
-49
-566
-947

query I rowsort
SELECT ALL col1 * col1 + col2 FROM tab2
----
327
3507
988

query I rowsort
SELECT DISTINCT + 47 + - col0 AS col2 FROM tab0
----
-42
12
23

query I rowsort
SELECT - col2 * + cor0.col0 + cor0.col2 * - col2 * + ( + col2 * cor0.col1 ) AS col1 FROM tab0 AS cor0
----
-132
-3091374
-50181786

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-271
SELECT col1 * CAST( col1 AS SIGNED ) * tab0.col0 AS col0 FROM tab0
----
177504
329315
737009

skipif mysql # not compatible
query I rowsort label-271
SELECT col1 * CAST ( col1 AS INTEGER ) * tab0.col0 AS col0 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT - col0 - ( 29 ) * + col1 * - col0 FROM tab2 AS cor0
----
133380
38868
6286

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

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

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

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

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

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

query I rowsort
SELECT - - 73 + 45 AS col2 FROM tab0 AS cor0
----
118
118
118

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - ( 40 ) col1 FROM tab0
----
3440
3640
3880

query I rowsort
SELECT DISTINCT 88 FROM tab0, tab0 cor0
----
88

query I rowsort
SELECT ALL - col2 * col2 * - 57 FROM tab1
----
166212
185193
525312

query I rowsort
SELECT + 96 FROM tab0, tab2 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

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

query I rowsort
SELECT - 72 FROM tab0, tab0 AS cor0
----
9 values hashing to ad521144c976ff25e77cdf10a84d1dc6

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-286
SELECT ALL + col1 * + CAST( - col1 AS SIGNED ) * - col0 FROM tab0
----
177504
329315
737009

skipif mysql # not compatible
query I rowsort label-286
SELECT ALL + col1 * + CAST ( - col1 AS INTEGER ) * - col0 FROM tab0
----
177504
329315
737009

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

query I rowsort
SELECT 83 - col1 FROM tab0 AS cor0
----
-14
-3
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 col1 FROM tab0, tab0 cor0
----
24
35
89

query I rowsort
SELECT + 91 * + col2 * col2 AS col2 FROM tab0
----
611884
91
99099

query I rowsort
SELECT DISTINCT 18 + cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
107
42
53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-292
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-292
SELECT ALL ( - cor0.col0 ) * CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

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

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

query I rowsort
SELECT ALL col0 * col1 + + col2 * - col0 FROM tab2 AS cor0
----
-1659
2574
28

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

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

query I rowsort
SELECT ALL - ( col1 ) + ( + col1 ) * - cor0.col0 + 61 AS col1 FROM tab0 AS cor0
----
-2089
-3431
-8129

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 88 col1 FROM tab1, tab1 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 00f4aded8ec5b6d9904061ce3da09e20

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

query I rowsort
SELECT DISTINCT cor0.col2 + col2 * + col2 FROM tab1 AS cor0
----
2970
3306
9312

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

query I rowsort
SELECT - 27 + - col0 * col1 FROM tab1 AS cor0
----
-105
-1067
-667

query I rowsort
SELECT ALL + col0 + col2 + cor0.col0 AS col0 FROM tab1 AS cor0
----
185
256
60

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

query I rowsort
SELECT ALL - + col1 * col2 * + col2 + cor0.col2 + + cor0.col0 AS col1 FROM tab2 cor0
----
-22565
-24431
-39780

query I rowsort
SELECT ( - col0 * 61 ) FROM tab2
----
-427
-4758
-4819

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 * + 26 * 41 col0 FROM tab2 AS cor0
----
27716
28782
40508

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

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

query I rowsort
SELECT ALL + + cor0.col1 * col1 + - 39 AS col2 FROM tab2 cor0
----
250
3442
922

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-312
SELECT ALL - col1 + + CAST( + ( + col0 ) AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-312
SELECT ALL - col1 + + CAST ( + ( + col0 ) AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-23
54
67

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-314
SELECT tab1.col2 DIV - tab1.col2 - + 16 AS col2 FROM tab1
----
-17
-17
-17

skipif mysql # not compatible
query I rowsort label-314
SELECT tab1.col2 / - tab1.col2 - + 16 AS col2 FROM tab1
----
-17
-17
-17

query I rowsort
SELECT ALL - 4 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 39ed23475412c3cbba02ecdd2d7018e6

query I rowsort
SELECT DISTINCT 90 * + 68 FROM tab1 AS cor0
----
6120

onlyif mysql # use DIV operator for integer division
query I rowsort label-317
SELECT + col2 DIV 7 + + col1 * + CAST( + col0 AS SIGNED ) * col0 AS col1 FROM tab0 AS cor0
----
118825
49540
720822

skipif mysql # not compatible
query I rowsort label-317
SELECT + col2 / 7 + + col1 * + CAST ( + col0 AS INTEGER ) * col0 AS col1 FROM tab0 AS cor0
----
118825
49540
720822

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

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

skipif mysql # not compatible
query I rowsort label-319
SELECT ALL + + ( col1 ) / + col0 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT - col2 * + ( - col2 * ( + col2 ) ) + col2 AS col0 FROM tab0 AS cor0
----
2
35970
551450

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

query I rowsort
SELECT - - col2 * 25 * + col2 FROM tab1 AS cor0
----
230400
72900
81225

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

query I rowsort
SELECT + col1 * + 63 AS col2 FROM tab0
----
5418
5733
6111

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

query I rowsort
SELECT DISTINCT - 68 + col0 * col1 AS col1 FROM tab2 cor0
----
1275
149
4534

query I rowsort
SELECT DISTINCT 73 + - 33 FROM tab1, tab0 AS cor0
----
40

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

skipif mysql # not compatible
query I rowsort label-328
SELECT CAST ( + tab2.col0 AS INTEGER ) FROM tab2, tab0 cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

onlyif mysql # use DIV operator for integer division
query I rowsort label-329
SELECT - 49 DIV 68 AS col0 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-329
SELECT - 49 / 68 AS col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - col0 + 23 + cor0.col0 AS col1 FROM tab0 AS cor0
----
23
23
23

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-333
SELECT col2 + tab0.col1 * + col0 DIV + col0 - tab0.col1 * col1 FROM tab0
----
-7277
-8108
-9311

skipif mysql # not compatible
query I rowsort label-333
SELECT col2 + tab0.col1 * + col0 / + col0 - tab0.col1 * col1 FROM tab0
----
-7277
-8108
-9311

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-334
SELECT + CAST( 76 AS SIGNED ) + + col2 FROM tab2
----
102
103
114

skipif mysql # not compatible
query I rowsort label-334
SELECT + CAST ( 76 AS INTEGER ) + + col2 FROM tab2
----
102
103
114

query I rowsort
SELECT DISTINCT + 85 * col0 AS col0 FROM tab1 AS cor0
----
255
5440
6800

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

skipif mysql # not compatible
query I rowsort label-336
SELECT + col2 * col0 / col2 + col0 FROM tab0 AS cor0
----
178
48
70

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-339
SELECT DISTINCT - 68 * - col2 + + col2 DIV col0 FROM tab1
----
3690
3876
6529

skipif mysql # not compatible
query I rowsort label-339
SELECT DISTINCT - 68 * - col2 + + col2 / col0 FROM tab1
----
3690
3876
6529

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

query I rowsort
SELECT DISTINCT 42 * 89 + - col0 FROM tab0
----
3649
3703
3714

query I rowsort
SELECT + 69 + 60 * + col0 AS col2 FROM tab0
----
1509
2169
5409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col1 col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL 2 * - col0 + - col2 * col2 FROM tab2 cor0
----
-1602
-743
-832

query I rowsort
SELECT DISTINCT 62 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
-5332
-5642
-6014

query I rowsort
SELECT + + 32 * col2 FROM tab2 AS cor0
----
1216
832
864

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

query I rowsort
SELECT ALL - - 26 * - col1 AS col0 FROM tab0 AS cor0
----
-2236
-2366
-2522

query I rowsort
SELECT - col0 + - col1 * + 9 AS col2 FROM tab2 AS cor0
----
-232
-286
-609

query I rowsort
SELECT - 16 + + col0 FROM tab0 cor0
----
19
73
8

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

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

query I rowsort
SELECT col2 - ( 31 * col0 ) AS col1 FROM tab2
----
-190
-2392
-2411

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

query I rowsort
SELECT - col2 + + ( + 27 ) FROM tab2
----
-11
0
1

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

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

query I rowsort
SELECT DISTINCT - + col0 * 78 FROM tab0 AS cor0
----
-1872
-2730
-6942

query I rowsort
SELECT ALL - col1 + + col0 * 92 AS col0 FROM tab2 AS cor0
----
613
7117
7251

query I rowsort
SELECT DISTINCT - col2 + 40 AS col0 FROM tab2 AS cor0
----
13
14
2

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

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

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

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

query I rowsort
SELECT + cor0.col0 * + col0 - 99 AS col0 FROM tab1 AS cor0
----
-90
3997
6301

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

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

query I rowsort
SELECT ALL + + 35 + - ( + col1 * + col0 ) FROM tab0 AS cor0
----
-2029
-3360
-8064

query I rowsort
SELECT + 76 * - col2 - + col1 FROM tab2 AS cor0
----
-2035
-2083
-2905

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

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

query I rowsort
SELECT ALL - col1 * + 15 * cor0.col0 AS col2 FROM tab0 AS cor0
----
-121485
-30960
-50925

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

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

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

query I rowsort
SELECT DISTINCT - 39 + - 85 AS col2 FROM tab0 AS cor0
----
-124

query I rowsort
SELECT DISTINCT - col0 + - 42 AS col0 FROM tab0 AS cor0
----
-131
-66
-77

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * ( col0 ) + col0 * - col0 col1 FROM tab1 AS cor0
----
-14080
-171
-7744

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

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

query I rowsort
SELECT ALL + col2 + + 80 FROM tab1 AS cor0
----
134
137
176

query I rowsort
SELECT + ( tab1.col1 ) * col2 + - col2 AS col0 FROM tab1
----
1152
1350
513

query I rowsort
SELECT - + 26 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 4e49eac022daeae6f88f610644ba3754

query I rowsort
SELECT 63 * - col1 + + 7 FROM tab1
----
-1631
-623
-812

query I rowsort
SELECT + + col1 + + col2 * col2 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT + - col0 * + 67 AS col0 FROM tab0 AS cor0
----
-1608
-2345
-5963

query I rowsort
SELECT + col1 * - 46 FROM tab1
----
-1196
-460
-598

query I rowsort
SELECT + tab1.col2 * 63 * - col1 FROM tab1
----
-35910
-78624
-88452

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-385
SELECT - ( col0 ) * - 32 - col2 DIV cor0.col1 AS col0 FROM tab0 AS cor0
----
1120
2848
768

skipif mysql # not compatible
query I rowsort label-385
SELECT - ( col0 ) * - 32 - col2 / cor0.col1 AS col0 FROM tab0 AS cor0
----
1120
2848
768

query I rowsort
SELECT DISTINCT col0 + col0 + col0 * + col2 AS col2 FROM tab0
----
105
7476
840

query I rowsort
SELECT col1 * - tab2.col2 AS col1 FROM tab2
----
-1534
-646
-837

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

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

query I rowsort
SELECT - col1 - + col2 * - col2 FROM tab2 AS cor0
----
1427
617
698

onlyif mysql # use DIV operator for integer division
query I rowsort label-390
SELECT col2 + col0 * col1 DIV - col0 FROM tab1
----
28
47
83

skipif mysql # not compatible
query I rowsort label-390
SELECT col2 + col0 * col1 / - col0 FROM tab1
----
28
47
83

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

query I rowsort
SELECT ALL col2 + col2 + - col1 * tab0.col0 AS col0 FROM tab0
----
-1998
-3393
-7935

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) * 71 * tab0.col2 col2 FROM tab0
----
2485
518158
56232

query I rowsort
SELECT DISTINCT 54 * col1 + 9 + 59 * col1 * + col2 FROM tab2
----
39041
51066
93701

query I rowsort
SELECT DISTINCT 13 + - col2 AS col2 FROM tab1 cor0
----
-41
-44
-83

query I rowsort
SELECT DISTINCT - + col1 * col2 + - col2 * col2 AS col0 FROM tab0 AS cor0
----
-14186
-3927
-98

query I rowsort
SELECT 34 * - col2 - - 69 FROM tab2 AS cor0
----
-1223
-815
-849

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

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

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

query I rowsort
SELECT ALL 26 + 80 AS col2 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e3a970c661a05070afa8a3ed8dca742e

query I rowsort
SELECT + col2 * col1 + 46 * col1 AS col2 FROM tab0 AS cor0
----
11648
4559
6794

query I rowsort
SELECT - - 28 AS col2 FROM tab0 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

query I rowsort
SELECT + col0 + ( + 97 ) + col0 * - col1 FROM tab0 AS cor0
----
-1943
-3263
-7913

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

query I rowsort
SELECT - ( 71 ) FROM tab0, tab2 AS cor0
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

onlyif mysql # use DIV operator for integer division
query I rowsort label-409
SELECT + + col1 + 24 - + col2 DIV col1 AS col0 FROM tab1 AS cor0
----
29
30
48

skipif mysql # not compatible
query I rowsort label-409
SELECT + + col1 + 24 - + col2 / col1 AS col0 FROM tab1 AS cor0
----
29
30
48

query I rowsort
SELECT col0 * + col0 + col0 * col0 + ( + col0 ) * + col2 AS col2 FROM tab0 AS cor0
----
1944
23140
2485

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

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

query I rowsort
SELECT + col1 + 84 FROM tab0 AS cor0
----
170
175
181

query I rowsort
SELECT - + ( + 44 ) * + col0 FROM tab2 AS cor0
----
-308
-3432
-3476

query I rowsort
SELECT - + 77 * col2 FROM tab2 cor0
----
-2002
-2079
-2926

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

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

query I rowsort
SELECT - 36 * col2 AS col0 FROM tab0 AS cor0
----
-1188
-2952
-36

query I rowsort
SELECT col2 + cor0.col1 * 81 FROM tab0 AS cor0
----
6999
7453
7858

query I rowsort
SELECT ALL tab2.col1 * tab2.col1 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 4a2f25e7025075a0ce048be425c35957

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

query I rowsort
SELECT DISTINCT + - 91 * col0 + 21 AS col1 FROM tab0 AS cor0
----
-2163
-3164
-8078

query I rowsort
SELECT col1 - ( - col2 ) FROM tab1
----
109
67
80

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

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

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

query I rowsort
SELECT - - col1 * + 73 + - col0 + + cor0.col1 * 95 FROM tab1 AS cor0
----
1616
2104
4365

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

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + col0 * - 98 + - cor0.col1 * - 51 FROM tab1 AS cor0
----
-5762
-7177
1032

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

query I rowsort
SELECT 13 * + 35 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to b4222bac6bea0322e29295b9d4f5b998

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

skipif mysql # not compatible
query I rowsort label-436
SELECT - + col0 * + ( col2 ) + + CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT - + 18 + col1 FROM tab1 AS cor0
----
-5
-8
8

query I rowsort
SELECT ALL + + col2 + 49 AS col1 FROM tab0 cor0
----
131
50
82

query I rowsort
SELECT - 63 + col2 + ( + col2 ) AS col2 FROM tab0 AS cor0
----
-61
101
3

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

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

query I rowsort
SELECT + 26 - + col2 FROM tab0 AS cor0
----
-56
-7
25

query I rowsort
SELECT DISTINCT - 67 FROM tab2 cor0
----
-67

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 28 * + cor0.col0 col2 FROM tab1 AS cor0
----
1792
2240
84

query I rowsort
SELECT col1 * - col1 * - 21 - cor0.col1 FROM tab0 cor0
----
155230
173810
197492

query I rowsort
SELECT DISTINCT + + col0 * - 85 FROM tab1 AS cor0
----
-255
-5440
-6800

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

query I rowsort
SELECT DISTINCT - 88 * col2 - 87 * col1 AS col2 FROM tab2
----
-4823
-5073
-7421

query I rowsort
SELECT - - col1 * 75 - col1 AS col2 FROM tab2 AS cor0
----
1258
2294
4366

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * - 87 col1 FROM tab0 cor0
----
-7482
-7917
-8439

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-457
SELECT + col1 DIV - col0 + 55 + col2 FROM tab2 AS cor0
----
78
81
93

skipif mysql # not compatible
query I rowsort label-457
SELECT + col1 / - col0 + 55 + col2 FROM tab2 AS cor0
----
78
81
93

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

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

query I rowsort
SELECT DISTINCT col1 * + ( + col1 + col2 ) AS col2 FROM tab0 AS cor0
----
10234
15743
9506

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

query I rowsort
SELECT cor0.col1 * col0 + col1 + - col0 FROM tab0 AS cor0
----
2126
3457
8101

query I rowsort
SELECT ALL - 58 - col2 AS col2 FROM tab0
----
-140
-59
-91

query I rowsort
SELECT - + col0 + - 48 + col1 AS col1 FROM tab0 AS cor0
----
-46
14
14

query I rowsort
SELECT ALL - ( tab0.col1 ) + - ( 41 ) - col0 FROM tab0
----
-151
-173
-221

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-466
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-466
SELECT CAST ( NULL AS REAL ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + ( 80 ) col2 FROM tab1
----
134
137
176

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

query I rowsort
SELECT ALL + col0 + - 46 AS col1 FROM tab2
----
-39
32
33

query I rowsort
SELECT ALL 95 * - tab1.col2 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to 33b946f8d0ffc1b06b274930e2b28b79

query I rowsort
SELECT DISTINCT col2 * col0 + col1 + + col1 * - 58 FROM tab1
----
-1320
3078
6939

query I rowsort
SELECT DISTINCT tab0.col1 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
86
91
97

query I rowsort
SELECT + 23 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

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

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

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

query I rowsort
SELECT + ( + col2 ) * - 18 * col1 + + col2 + col0 FROM tab2 AS cor0
----
-11511
-15032
-27508

query I rowsort
SELECT - + col0 * + col1 * 80 AS col0 FROM tab0 AS cor0
----
-165120
-271600
-647920

query I rowsort
SELECT ALL 68 + col2 + + ( col0 + col2 ) * 72 AS col1 FROM tab2
----
2543
7582
8530

query I rowsort
SELECT ALL col2 * - tab0.col1 * 64 + + 33 AS col2 FROM tab0
----
-181599
-477535
-6175

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

query I rowsort
SELECT ALL + ( cor0.col1 ) * - 32 + - col1 AS col2 FROM tab2 AS cor0
----
-1023
-1947
-561

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

query I rowsort
SELECT DISTINCT + 54 AS col1 FROM tab2 cor0
----
54

query I rowsort
SELECT DISTINCT 30 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
1920
2400
90

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

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

query I rowsort
SELECT ALL + 4 + col0 AS col2 FROM tab0 AS cor0
----
28
39
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-488
SELECT + - col2 DIV - col0 + + col2 FROM tab1 AS cor0
----
57
72
97

skipif mysql # not compatible
query I rowsort label-488
SELECT + - col2 / - col0 + + col2 FROM tab1 AS cor0
----
57
72
97

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

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

query I rowsort
SELECT ALL - col2 + - 32 FROM tab1 AS cor0
----
-128
-86
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-491
SELECT ALL + 93 * ( - col2 ) DIV - col2 - - ( + col1 * + col1 + col2 ) AS col0 FROM tab1 AS cor0
----
250
358
823

skipif mysql # not compatible
query I rowsort label-491
SELECT ALL + 93 * ( - col2 ) / - col2 - - ( + col1 * + col1 + col2 ) AS col0 FROM tab1 AS cor0
----
250
358
823

query I rowsort
SELECT ALL - cor1.col1 FROM tab1, tab2 AS cor0, tab2, tab2 AS cor1
----
81 values hashing to b7a1b38fe8e4f34388e3be1f52601ae5

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

query I rowsort
SELECT + + col2 + + col2 AS col1 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT - + 3 + - col2 * + cor0.col0 * 10 FROM tab1 AS cor0
----
-1623
-36483
-76803

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-496
SELECT ALL - - col0 + 37 / - col1 col0 FROM tab1 AS cor0
----
2
61
78

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

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

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

query I rowsort
SELECT ALL col1 * 76 + col1 FROM tab1
----
1001
2002
770

query I rowsort
SELECT - col1 + + col1 * 38 FROM tab1 AS cor0
----
370
481
962

query I rowsort
SELECT DISTINCT + - col1 * 71 FROM tab1 AS cor0
----
-1846
-710
-923

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

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

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

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

query I rowsort
SELECT 79 * col2 + col2 AS col1 FROM tab1 AS cor0
----
4320
4560
7680

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

skipif mysql # not compatible
query I rowsort label-507
SELECT DISTINCT - col0 * + CAST ( cor0.col1 AS INTEGER ) AS col2 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + col0 * - 52 FROM tab2
----
-364
-4056
-4108

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

skipif mysql # not compatible
query I rowsort label-509
SELECT DISTINCT CAST ( 8 AS INTEGER ) FROM tab2 AS cor0
----
8

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * ( - tab1.col2 ) col1 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT ALL 5 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

query I rowsort
SELECT + ( + col1 ) * + tab0.col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT - 1 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

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

query I rowsort
SELECT + + col2 * 12 AS col0 FROM tab0 AS cor0
----
12
396
984

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-517
SELECT - 92 * col0 + + col0 * CAST( - col2 AS SIGNED ) AS col2 FROM tab0
----
-15486
-3000
-3255

skipif mysql # not compatible
query I rowsort label-517
SELECT - 92 * col0 + + col0 * CAST ( - col2 AS INTEGER ) AS col2 FROM tab0
----
-15486
-3000
-3255

onlyif mysql # use DIV operator for integer division
query I rowsort label-518
SELECT col0 * - tab0.col0 + ( tab0.col2 ) * col0 DIV - 30 AS col0 FROM tab0
----
-1226
-602
-8164

skipif mysql # not compatible
query I rowsort label-518
SELECT col0 * - tab0.col0 + ( tab0.col2 ) * col0 / - 30 AS col0 FROM tab0
----
-1226
-602
-8164

query I rowsort
SELECT - + 58 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to a38440572743ed8a3d8af7b49a5388c9

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

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

query I rowsort
SELECT DISTINCT - + 55 + col2 + - 15 FROM tab0 AS cor0
----
-37
-69
12

query I rowsort
SELECT - + cor0.col0 * + col1 + 69 AS col1 FROM tab2 AS cor0
----
-1274
-148
-4533

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-523
SELECT + cor0.col1 * CAST ( NULL AS INTEGER ) col0 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT cor0.col0 * 9 * ( + col2 ) FROM tab0 AS cor0
----
315
65682
7128

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-526
SELECT + col1 * 37 DIV + 59 + - col1 AS col1 FROM tab1 AS cor0
----
-10
-4
-5

skipif mysql # not compatible
query I rowsort label-526
SELECT + col1 * 37 / + 59 + - col1 AS col1 FROM tab1 AS cor0
----
-10
-4
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-527
SELECT - 55 * cor0.col0 + - col2 + col2 DIV col0 FROM tab1 AS cor0
----
-201
-3577
-4495

skipif mysql # not compatible
query I rowsort label-527
SELECT - 55 * cor0.col0 + - col2 + col2 / col0 FROM tab1 AS cor0
----
-201
-3577
-4495

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-529
SELECT DISTINCT - 59 + + col1 DIV - col2 + col1 AS col0 FROM tab0 AS cor0
----
-59
25
31

skipif mysql # not compatible
query I rowsort label-529
SELECT DISTINCT - 59 + + col1 / - col2 + col1 AS col0 FROM tab0 AS cor0
----
-59
25
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-530
SELECT 46 + - col2 DIV + col2 col0 FROM tab0
----
45
45
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-530
SELECT 46 + - col2 / + col2 col0 FROM tab0
----
45
45
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-531
SELECT col1 * col1 DIV col0 + + col1 DIV col0 FROM tab1
----
1
2
233

skipif mysql # not compatible
query I rowsort label-531
SELECT col1 * col1 / col0 + + col1 / col0 FROM tab1
----
1
2
233

query I rowsort
SELECT - 5 * col2 FROM tab1
----
-270
-285
-480

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

query I rowsort
SELECT ALL col2 + - col2 * - col2 AS col1 FROM tab1
----
2970
3306
9312

query I rowsort
SELECT DISTINCT - 36 FROM tab2, tab1, tab0 cor0
----
-36

query I rowsort
SELECT DISTINCT col2 * col0 + 63 FROM tab2
----
2091
252
3065

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 73 ) col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 2931474b870c05694e446771031a6949

query I rowsort
SELECT DISTINCT - col2 + col0 * 83 + - col0 * col2 * - col2 FROM tab0
----
28095
2939
605741

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

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

query I rowsort
SELECT DISTINCT - col0 * col1 + 18 * cor0.col0 FROM tab1 AS cor0
----
-24
400
512

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

query I rowsort
SELECT col0 * - col0 + + 64 + col1 AS col0 FROM tab2 AS cor0
----
-5961
-6160
46

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

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

query I rowsort
SELECT tab0.col1 + 10 FROM tab0
----
101
107
96

query I rowsort
SELECT + col0 + 22 FROM tab0 AS cor0
----
111
46
57

query I rowsort
SELECT + 3 AS col0 FROM tab1, tab0 cor0, tab0 AS cor1, tab2, tab2 AS cor2
----
243 values hashing to 651d73b1d4aaebc5a692f9febc779292

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

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT - ( - 17 ) * col0 - CAST ( col2 AS REAL ) FROM tab2 AS cor0
----
1300
1305
92

query I rowsort
SELECT - + col2 * - 74 + col0 FROM tab0 AS cor0
----
109
2466
6157

query I rowsort
SELECT DISTINCT + 39 + - 51 * col1 FROM tab0 AS cor0
----
-4347
-4602
-4908

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

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

query I rowsort
SELECT - col2 * col2 * cor0.col2 + - col2 + 34 FROM tab0 AS cor0
----
-35936
-551416
32

query I rowsort
SELECT DISTINCT - + ( - col2 ) AS col2 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT + ( col0 ) + cor0.col1 + 6 FROM tab1 AS cor0
----
35
80
99

query I rowsort
SELECT - - col2 * - 69 * col1 + ( + col2 + col1 ) AS col2 FROM tab0 AS cor0
----
-195703
-514705
-6595

query I rowsort
SELECT ALL + 23 * col1 + - col0 FROM tab1 AS cor0
----
166
219
595

query I rowsort
SELECT DISTINCT ( - col2 * tab0.col2 + ( col1 ) ) FROM tab0
----
-1003
-6633
96

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

skipif mysql # not compatible
query I rowsort label-561
SELECT + - CAST ( NULL AS REAL ) AS col1 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * cor0.col0 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 4734c38591591662f77999e8d1e5daf1

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

skipif mysql # not compatible
query I rowsort label-563
SELECT ALL - - ( + 87 ) + - col0 / - 91 FROM tab2 AS cor0
----
87
87
87

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

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

query I rowsort
SELECT DISTINCT + col1 * cor0.col2 * col0 + + 26 + 64 AS col2 FROM tab2 AS cor0
----
119742
51124
5949

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

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

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

query I rowsort
SELECT ALL - - 41 * - cor0.col0 * - col1 FROM tab1 AS cor0
----
26240
3198
42640

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-570
SELECT - col1 * col1 - CAST( col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-164
-249
-679

skipif mysql # not compatible
query I rowsort label-570
SELECT - col1 * col1 - CAST ( col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-164
-249
-679

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

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

query I rowsort
SELECT ALL + 15 FROM tab1 cor0
----
15
15
15

query I rowsort
SELECT + col1 * cor0.col0 * - col1 - + col0 FROM tab1 AS cor0
----
-13600
-2031
-6464

query I rowsort
SELECT ALL - + 39 + - col2 FROM tab0 AS cor0
----
-121
-40
-72

query I rowsort
SELECT ALL - col0 - 18 AS col0 FROM tab2
----
-25
-96
-97

query I rowsort
SELECT ALL - col2 - 69 FROM tab2
----
-107
-95
-96

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

skipif mysql # not compatible
query I rowsort label-578
SELECT ALL ( + col0 ) - - col2 / tab0.col1 FROM tab0
----
24
35
89

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

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

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

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

query I rowsort
SELECT DISTINCT + + col0 * + 47 FROM tab0 AS cor0
----
1128
1645
4183

query I rowsort
SELECT + + col0 + 59 FROM tab1 AS cor0
----
123
139
62

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

query I rowsort
SELECT + col0 * - 33 + cor0.col1 FROM tab2 AS cor0
----
-200
-2515
-2590

query I rowsort
SELECT DISTINCT - + col2 + + 23 AS col1 FROM tab0 AS cor0
----
-10
-59
22

query I rowsort
SELECT ALL col2 + col1 * tab2.col2 + tab2.col0 AS col0 FROM tab2
----
1638
763
871

query I rowsort
SELECT ALL col1 + col2 + + 14 * col2 FROM tab2
----
436
449
587

query I rowsort
SELECT + col1 + + ( - 74 ) AS col1 FROM tab1 AS cor0
----
-48
-61
-64

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

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

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

skipif mysql # not compatible
query I rowsort label-592
SELECT ALL + 22 / col1 AS col2 FROM tab1
----
0
1
2

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL 82 * cor0.col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 5ed674b86bc66220451666145bcd25fd

query I rowsort
SELECT ALL + - 57 * - 36 + - col2 * col2 AS col1 FROM tab2 AS cor0
----
1323
1376
608

onlyif mysql # use DIV operator for integer division
query I rowsort label-604
SELECT DISTINCT - + col2 - 35 DIV col0 FROM tab2 AS cor0
----
-26
-32
-38

skipif mysql # not compatible
query I rowsort label-604
SELECT DISTINCT - + col2 - 35 / col0 FROM tab2 AS cor0
----
-26
-32
-38

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

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

query I rowsort
SELECT ALL + + col1 + + col1 * cor0.col1 AS col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT + - ( 70 ) + - col2 * - 18 FROM tab2 AS cor0
----
398
416
614

query I rowsort
SELECT ALL + col2 + 32 * + col1 AS col2 FROM tab0 AS cor0
----
2785
2994
3105

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 58 * col0 col0 FROM tab0 AS cor0
----
1392
2030
5162

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

skipif mysql # not compatible
query I rowsort label-613
SELECT ALL 32 / col2 AS col2 FROM tab1 AS cor0
----
0
0
0

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + col2 + - col2 col0 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT + 98 * + col0 FROM tab1 AS cor0
----
294
6272
7840

query I rowsort
SELECT 48 * col2 + col2 FROM tab2 AS cor0
----
1274
1323
1862

query I rowsort
SELECT ALL - 31 FROM tab1 cor0
----
-31
-31
-31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 + + col0 * + ( col0 ) * col0 col0 FROM tab2 AS cor0
----
350
474630
493118

query I rowsort
SELECT ALL + - col0 * + col1 + 70 FROM tab2 AS cor0
----
-1273
-147
-4532

query I rowsort
SELECT + 50 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
128
129
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-624
SELECT ALL col1 DIV + 45 AS col1 FROM tab2 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-624
SELECT ALL col1 / + 45 AS col1 FROM tab2 cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-625
SELECT DISTINCT - col0 + - col0 DIV - col0 AS col2 FROM tab2 AS cor0
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-625
SELECT DISTINCT - col0 + - col0 / - col0 AS col2 FROM tab2 AS cor0
----
-6
-77
-78

query I rowsort
SELECT + 32 * + ( + cor0.col2 * 14 ) FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 13095423722988391d5d1bf49cd2a2ca

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

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

query I rowsort
SELECT DISTINCT col1 * 47 + 7 * + col0 FROM tab2 AS cor0
----
1352
1506
3319

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

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

query I rowsort
SELECT DISTINCT ( cor0.col0 ) * + tab2.col1 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 4079a7bf86eef7fda5333d4a7bc8c08e

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

query I rowsort
SELECT ALL + ( + 20 ) AS col2 FROM tab2
----
20
20
20

query I rowsort
SELECT ALL 41 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

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

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

query I rowsort
SELECT col0 + + col0 + col0 FROM tab2 AS cor0
----
21
234
237

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 45 + cor0.col1 + ( ( cor0.col2 ) ) col0 FROM tab1 AS cor0
----
-2350
-2498
-4211

query I rowsort
SELECT - 21 - - cor0.col1 FROM tab1 AS cor0
----
-11
-8
5

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-647
SELECT DISTINCT - - col2 - col0 * - col0 DIV - col0 FROM tab2 cor0
----
-41
-52
20

skipif mysql # not compatible
query I rowsort label-647
SELECT DISTINCT - - col2 - col0 * - col0 / - col0 FROM tab2 cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-648
SELECT ALL 44 * col1 DIV col0 FROM tab2
----
194
33
9

skipif mysql # not compatible
query I rowsort label-648
SELECT ALL 44 * col1 / col0 FROM tab2
----
194
33
9

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

query I rowsort
SELECT ALL - col1 - tab2.col1 * col1 AS col2 FROM tab2
----
-306
-3540
-992

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

query I rowsort
SELECT ALL col0 * + col2 - col1 * + col0 FROM tab2
----
-2574
-28
1659

query I rowsort
SELECT ALL col0 + col0 * col0 + - col0 AS col1 FROM tab1
----
4096
6400
9

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

query I rowsort
SELECT - tab1.col2 + col1 + - col1 * - col0 FROM tab1
----
50
593
957

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 89 + - cor0.col1 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 2355d1e9c554c9af0946fc7669f0fb79

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

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

query I rowsort
SELECT ALL - + cor0.col2 * + cor0.col1 + + cor0.col0 + + cor0.col2 FROM tab1 AS cor0
----
-1072
-1347
-449

query I rowsort
SELECT ALL + col1 * - 81 FROM tab0
----
-6966
-7371
-7857

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

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

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

query I rowsort
SELECT 57 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT 0 * tab0.col0 * col0 - col2 * - col1 FROM tab0
----
2838
7462
97

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

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

skipif mysql # not compatible
query I rowsort label-666
SELECT DISTINCT + col0 / col1 + col0 + - col2 FROM tab1 cor0
----
-10
-51
13

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 ALL + 66 * + col1 AS col0 FROM tab2 AS cor0
----
1122
2046
3894

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

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

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

query I rowsort
SELECT 13 * + col1 * col0 FROM tab2 AS cor0
----
17459
2821
59826

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col2 + + tab0.col1 * - col1 col2 FROM tab0
----
-7363
-8199
-9408

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT col1 = + col0 * col0
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

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

query I rowsort
SELECT col1 + col1 AS col1 FROM tab2 WHERE NULL BETWEEN col2 AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + tab0.col2 col0 FROM tab0
----
1
1089
6724

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE col2 < col0 / col0
----

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

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

query I rowsort
SELECT DISTINCT col0 * col0 + col0 * col0 FROM tab0 AS cor0
----
1152
15842
2450

query I rowsort
SELECT + col2 * - col2 * col0 + tab0.col1 FROM tab0
----
-26050
-598345
62

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + col1 * + col2 col1 FROM tab2
----
1612
725
844

query I rowsort
SELECT DISTINCT col1 AS col1 FROM tab0 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

query III rowsort
SELECT ALL * FROM tab1 WHERE - col1 * + col1 >= + col0 * col2 + - col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-686
SELECT ALL tab0.col0 + col0 DIV col0 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-686
SELECT ALL tab0.col0 + col0 / col0 FROM tab0
----
25
36
90

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

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL < + col0 * col1
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col2 + col0 col1 FROM tab2
----
-20
41
52

query I rowsort
SELECT - col1 + - col0 AS col1 FROM tab1 WHERE NOT ( NULL ) BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT col1 + + col0 * - col0 AS col1 FROM tab1
----
-4086
-6387
17

query I rowsort
SELECT + tab1.col1 + tab1.col0 * col2 - col2 * tab1.col1 FROM tab1
----
-1216
3088
6445

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

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

query I rowsort
SELECT ALL + col2 * + col2 + col0 + col1 AS col0 FROM tab2 cor0
----
1540
767
813

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

query I rowsort
SELECT ALL + col0 * - col2 + + tab2.col0 * - col1 * col1 FROM tab2
----
-25833
-273546
-6916

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 + + col0 * cor0.col1 col0 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT col2 + col2 * col0 + col1 * col2 AS col0 FROM tab0 AS cor0
----
133
14842
3663

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-704
SELECT DISTINCT - - col2 DIV + cor0.col0 - col1 * - col2 FROM tab2 AS cor0
----
1534
646
840

skipif mysql # not compatible
query I rowsort label-704
SELECT DISTINCT - - col2 / + cor0.col0 - col1 * - col2 FROM tab2 AS cor0
----
1534
646
840

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-707
SELECT ALL + + col2 DIV - col2 + col1 + col1 AS col0 FROM tab1 AS cor0
----
19
25
51

skipif mysql # not compatible
query I rowsort label-707
SELECT ALL + + col2 / - col2 + col1 + col1 AS col0 FROM tab1 AS cor0
----
19
25
51

query I rowsort
SELECT DISTINCT col0 * - col1 * col0 + cor0.col1 FROM tab0 AS cor0
----
-118728
-49450
-720720

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-710
SELECT ALL tab2.col1 DIV col0 + + col0 * - col1 AS col2 FROM tab2
----
-1343
-213
-4602

skipif mysql # not compatible
query I rowsort label-710
SELECT ALL tab2.col1 / col0 + + col0 * - col1 AS col2 FROM tab2
----
-1343
-213
-4602

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 + cor0.col1 + + 14 * cor0.col1 AS col2 FROM tab1 AS cor0
----
150
195
390

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-716
SELECT DISTINCT - tab0.col1 DIV 17 AS col1 FROM tab0
----
-5

skipif mysql # not compatible
query I rowsort label-716
SELECT DISTINCT - tab0.col1 / 17 AS col1 FROM tab0
----
-5

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + 48 * col1 col0 FROM tab1
----
1251
544
704

query I rowsort
SELECT + tab2.col1 + - 36 * col2 * - col1 AS col1 FROM tab2
----
23273
30163
55283

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

query I rowsort
SELECT 37 AS col2 FROM tab0, tab2 cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

query I rowsort
SELECT ALL - 67 * 96 + - cor0.col0 * 38 FROM tab0 AS cor0
----
-7344
-7762
-9814

query I rowsort
SELECT + 39 * 39 AS col2 FROM tab0 AS cor0
----
1521
1521
1521

query I rowsort
SELECT ALL 64 * - col2 AS col1 FROM tab2 AS cor0
----
-1664
-1728
-2432

query I rowsort
SELECT col0 + + 16 FROM tab1 AS cor0
----
19
80
96

skipif mysql # not compatible
query I rowsort
SELECT ALL - col2 + tab0.col0 * + CAST ( - 37 AS REAL ) FROM tab0
----
-1296
-3375
-921

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

query I rowsort
SELECT DISTINCT + - 29 * - col0 AS col2 FROM tab0 AS cor0
----
1015
2581
696

query I rowsort
SELECT ALL + 1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT + col2 * col0 + - ( + cor0.col2 + + col0 ) FROM tab0 AS cor0
----
-1
7127
735

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-733
SELECT + col0 + col1 DIV + col0 FROM tab0 AS cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-733
SELECT + col0 + col1 / + col0 FROM tab0 AS cor0
----
27
37
90

query I rowsort
SELECT ALL + + 78 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

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

skipif mysql # not compatible
query I rowsort label-735
SELECT + + cor0.col0 + + CAST ( col1 AS INTEGER ) * col2 * col0 AS col1 FROM tab0 AS cor0
----
3430
664207
68136

query I rowsort
SELECT col2 + col0 * - 43 FROM tab2 AS cor0
----
-274
-3328
-3359

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

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

query I rowsort
SELECT - col1 * col1 + + col1 AS col0 FROM tab2 AS cor0
----
-272
-3422
-930

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

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

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

query I rowsort
SELECT - 82 + - cor0.col1 * - col0 * cor0.col1 AS col1 FROM tab0 AS cor0
----
177422
329233
736927

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

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

query I rowsort
SELECT ALL - col2 + + tab2.col1 - ( + col2 ) FROM tab2
----
-23
-59
7

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

query I rowsort
SELECT DISTINCT + - col1 + col2 * + 17 * col1 AS col0 FROM tab2 cor0
----
10965
14198
26019

query I rowsort
SELECT ALL col1 + 97 AS col1 FROM tab2 AS cor0
----
114
128
156

query I rowsort
SELECT DISTINCT 59 * col1 + col1 FROM tab1
----
1560
600
780

query I rowsort
SELECT ALL tab2.col0 + col1 * 57 FROM tab2
----
1048
1774
3441

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

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

skipif mysql # not compatible
query I rowsort label-752
SELECT 79 / col1 FROM tab2
----
1
2
4

query I rowsort
SELECT + - 37 + + col2 FROM tab1 AS cor0
----
17
20
59

query I rowsort
SELECT ALL - + col2 + + cor0.col1 AS col1 FROM tab0 AS cor0
----
53
9
96

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-758
SELECT DISTINCT + cor0.col0 + col0 * 7 - col2 DIV + col0 FROM tab1 AS cor0
----
512
6
639

skipif mysql # not compatible
query I rowsort label-758
SELECT DISTINCT + cor0.col0 + col0 * 7 - col2 / + col0 FROM tab1 AS cor0
----
512
6
639

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-761
SELECT ALL 15 DIV + col2 + ( + 77 ) * - cor0.col1 AS col1 FROM tab1 AS cor0
----
-1001
-2002
-770

skipif mysql # not compatible
query I rowsort label-761
SELECT ALL 15 / + col2 + ( + 77 ) * - cor0.col1 AS col1 FROM tab1 AS cor0
----
-1001
-2002
-770

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-762
SELECT DISTINCT - + cor0.col2 * col1 * CAST( 2 AS SIGNED ) FROM tab1 cor0
----
-1140
-2496
-2808

skipif mysql # not compatible
query I rowsort label-762
SELECT DISTINCT - + cor0.col2 * col1 * CAST ( 2 AS INTEGER ) FROM tab1 cor0
----
-1140
-2496
-2808

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-765
SELECT - - col2 + 76 DIV col0 FROM tab0 cor0
----
3
36
82

skipif mysql # not compatible
query I rowsort label-765
SELECT - - col2 + 76 / col0 FROM tab0 cor0
----
3
36
82

query I rowsort
SELECT ALL + ( - cor0.col1 ) AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

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

skipif mysql # not compatible
query I rowsort label-767
SELECT + col0 + CAST ( col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-768
SELECT DISTINCT + - col0 DIV 12 FROM tab2 AS cor0
----
-6
0

skipif mysql # not compatible
query I rowsort label-768
SELECT DISTINCT + - col0 / 12 FROM tab2 AS cor0
----
-6
0

query I rowsort
SELECT ALL + col1 + 73 AS col0 FROM tab1 AS cor0
----
83
86
99

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

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

query I rowsort
SELECT - ( 33 ) AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to a539377dccf415ca13c845420f532336

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 32 col2 FROM tab2
----
1888
544
992

query I rowsort
SELECT + 40 + col0 FROM tab2 AS cor0
----
118
119
47

query I rowsort
SELECT - + col1 * - 51 + + cor0.col0 FROM tab0 AS cor0
----
4410
4730
4982

query I rowsort
SELECT - 96 AS col1 FROM tab1 AS cor0
----
-96
-96
-96

query I rowsort
SELECT ALL col0 * - 15 AS col0 FROM tab0
----
-1335
-360
-525

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

query I rowsort
SELECT ALL - 7 + col1 FROM tab0 AS cor0
----
79
84
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-782
SELECT DISTINCT - col2 + col1 DIV + col2 AS col0 FROM tab0 cor0
----
-31
-81
96

skipif mysql # not compatible
query I rowsort label-782
SELECT DISTINCT - col2 + col1 / + col2 AS col0 FROM tab0 cor0
----
-31
-81
96

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

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

query I rowsort
SELECT ALL - col1 * - col1 * col0 + cor0.col0 - - col2 FROM tab0 AS cor0
----
177561
329351
737180

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

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

query I rowsort
SELECT - 39 + col2 * - col2 FROM tab2 AS cor0
----
-1483
-715
-768

query I rowsort
SELECT + + col1 + col0 + + 10 AS col0 FROM tab1 AS cor0
----
103
39
84

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

query I rowsort
SELECT ALL col2 + col2 + col1 * - ( + col1 ) FROM tab0
----
-7330
-8117
-9407

query I rowsort
SELECT ALL - 50 * + cor0.col0 AS col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to ae3857849fcd8c8daf0afed9b81631c2

query I rowsort
SELECT ALL - 64 AS col2 FROM tab2
----
-64
-64
-64

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

query I rowsort
SELECT + cor0.col1 - + cor0.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to c1eca5ea8dadf5efbc400ae6094b52e3

query I rowsort
SELECT ALL - 72 + - col2 AS col1 FROM tab2 AS cor0
----
-110
-98
-99

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

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

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

query I rowsort
SELECT - + col1 - - 18 AS col1 FROM tab2 AS cor0
----
-13
-41
1

query I rowsort
SELECT + col1 * cor0.col0 + col0 * - ( + col2 ) FROM tab0 AS cor0
----
1272
3360
801

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

query I rowsort
SELECT col1 + col1 + 58 FROM tab1
----
110
78
84

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

query I rowsort
SELECT ALL col2 * - ( col2 ) + col2 * ( tab1.col1 ) AS col1 FROM tab1
----
-1512
-2679
-7968

query I rowsort
SELECT ALL + 25 * - cor0.col1 AS col2 FROM tab1 cor0
----
-250
-325
-650

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

query I rowsort
SELECT DISTINCT + + 11 FROM tab1 AS cor0
----
11

query I rowsort
SELECT + ( 41 ) * - col2 + col0 AS col0 FROM tab1 AS cor0
----
-2211
-2273
-3856

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-811
SELECT ALL + 44 DIV - cor0.col2 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-811
SELECT ALL + 44 / - cor0.col2 AS col2 FROM tab1 AS cor0
----
0
0
0

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

query I rowsort
SELECT DISTINCT - 67 * - col2 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
10854
244416
514560

query I rowsort
SELECT ALL - - 52 + - col1 FROM tab1 cor0
----
26
39
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-815
SELECT ALL - 14 * cor0.col2 DIV - cor0.col0 AS col2 FROM tab2 AS cor0
----
4
54
6

skipif mysql # not compatible
query I rowsort label-815
SELECT ALL - 14 * cor0.col2 / - cor0.col0 AS col2 FROM tab2 AS cor0
----
4
54
6

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

query I rowsort
SELECT cor0.col0 * 31 FROM tab0, tab2 AS cor0
----
9 values hashing to 4a0cf49c2135fc224646191a4a736cc8

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

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

skipif mysql # not compatible
query I rowsort
SELECT col0 + CAST ( + col1 AS REAL ) * cor0.col0 FROM tab2 AS cor0
----
1422
224
4680

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

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

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

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

query I rowsort
SELECT - 3 * 75 FROM tab0 AS cor0
----
-225
-225
-225

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-825
SELECT ALL + 53 * - ( col0 * col2 ) + ( col1 ) * + CAST( + ( - col1 ) AS SIGNED ) + - cor0.col1 FROM tab0 AS cor0
----
-11361
-395166
-49458

skipif mysql # not compatible
query I rowsort label-825
SELECT ALL + 53 * - ( col0 * col2 ) + ( col1 ) * + CAST ( + ( - col1 ) AS INTEGER ) + - cor0.col1 FROM tab0 AS cor0
----
-11361
-395166
-49458

query I rowsort
SELECT + col0 + + ( col2 * - col2 + + 43 ) FROM tab0
----
-1022
-6592
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + 17 ) * + col1 col0 FROM tab1 cor0
----
-170
-221
-442

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

query I rowsort
SELECT - 89 * - col1 AS col2 FROM tab1 AS cor0
----
1157
2314
890

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-831
SELECT 71 DIV - col1 + - tab2.col1 FROM tab2
----
-21
-33
-60

skipif mysql # not compatible
query I rowsort label-831
SELECT 71 / - col1 + - tab2.col1 FROM tab2
----
-21
-33
-60

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

query I rowsort
SELECT ALL + 73 * + cor0.col2 FROM tab2 AS cor0
----
1898
1971
2774

query I rowsort
SELECT + 52 - col2 AS col2 FROM tab0 AS cor0
----
-30
19
51

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

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

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

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

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

query I rowsort
SELECT ALL + col0 * 56 + + col0 AS col1 FROM tab1 AS cor0
----
171
3648
4560

onlyif mysql # use DIV operator for integer division
query I rowsort label-839
SELECT ALL - col2 * 20 - 73 DIV col0 FROM tab1 cor0
----
-1104
-1141
-1920

skipif mysql # not compatible
query I rowsort label-839
SELECT ALL - col2 * 20 - 73 / col0 FROM tab1 cor0
----
-1104
-1141
-1920

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

query I rowsort
SELECT - + col0 * - 86 * + 34 AS col0 FROM tab2 AS cor0
----
20468
228072
230996

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-844
SELECT - - col1 DIV CAST( + 13 AS SIGNED ) FROM tab1 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-844
SELECT - - col1 / CAST ( + 13 AS INTEGER ) FROM tab1 AS cor0
----
0
1
2

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

skipif mysql # not compatible
query I rowsort label-845
SELECT DISTINCT 51 / col2 AS col0 FROM tab0
----
0
1
51

query I rowsort
SELECT + 9 + + cor1.col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 5e7274997f12ee8b297da9d88315a0f8

query I rowsort
SELECT + ( - col0 ) - - col2 FROM tab2
----
-41
-52
20

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

query I rowsort
SELECT DISTINCT - - 51 * cor0.col0 FROM tab0, tab2, tab0 AS cor0
----
1224
1785
4539

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

query I rowsort
SELECT - col2 * ( - col1 * - cor0.col2 ) + col2 AS col1 FROM tab2 AS cor0
----
-22572
-24510
-39858

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

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

skipif mysql # not compatible
query I rowsort label-853
SELECT DISTINCT - col2 + col2 / col1 FROM tab2 AS cor0
----
-26
-27
-36

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

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

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

query I rowsort
SELECT + + 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 ALL + ( col0 ) col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL col2 * - tab0.col2 + col2 AS col2 FROM tab0
----
-1056
-6642
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-859
SELECT ALL col1 + col1 * + tab0.col2 + - col2 DIV + ( 96 ) FROM tab0
----
194
2924
7553

skipif mysql # not compatible
query I rowsort label-859
SELECT ALL col1 + col1 * + tab0.col2 + - col2 / + ( 96 ) FROM tab0
----
194
2924
7553

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

query I rowsort
SELECT ALL col2 + ( - col2 ) * col0 AS col1 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT col0 + - tab2.col1 + - col2 AS col2 FROM tab2
----
-51
-7
24

query I rowsort
SELECT - ( 36 ) * + col1 + col0 FROM tab0 AS cor0
----
-3072
-3187
-3457

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-865
SELECT + cor0.col1 * - CAST( NULL AS DECIMAL ) FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-865
SELECT + cor0.col1 * - CAST ( NULL AS REAL ) FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

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

skipif mysql # not compatible
query I rowsort label-866
SELECT DISTINCT CAST ( NULL AS INTEGER ) * - 68 AS col1 FROM tab1 AS cor0
----
NULL

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

query I rowsort
SELECT ALL 21 * 7 AS col0 FROM tab0 AS cor0
----
147
147
147

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

query I rowsort
SELECT DISTINCT tab1.col2 * col1 + 1 AS col1 FROM tab1
----
1249
1405
571

query I rowsort
SELECT ALL + 9 + + tab2.col1 * - tab2.col0 * col2 AS col2 FROM tab2
----
-119643
-51025
-5850

query I rowsort
SELECT DISTINCT + 28 * + col2 + col0 * + 62 FROM tab2 AS cor0
----
1190
5564
5962

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

query I rowsort
SELECT DISTINCT - 3 * 33 AS col1 FROM tab2, tab2 cor0, tab1 AS cor1
----
-99

query I rowsort
SELECT ALL col0 + col2 - + col2 AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + 12 + col1 FROM tab2 cor0
----
29
43
71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 73 * - col0 - + col2 col0 FROM tab0 AS cor0
----
-1785
-2556
-6579

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

query I rowsort
SELECT DISTINCT + cor0.col2 + + col1 * + col0 * col1 AS col0 FROM tab0 cor0
----
177537
329316
737091

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

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

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

query I rowsort
SELECT DISTINCT - col2 * 90 - + ( - cor0.col0 ) AS col2 FROM tab0 cor0
----
-2946
-55
-7291

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-884
SELECT - col0 + col1 * 12 DIV col1 FROM tab2 AS cor0
----
-66
-67
5

skipif mysql # not compatible
query I rowsort label-884
SELECT - col0 + col1 * 12 / col1 FROM tab2 AS cor0
----
-66
-67
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * 82 col0 FROM tab1 AS cor0
----
246
5248
6560

onlyif mysql # use DIV operator for integer division
query I rowsort label-886
SELECT DISTINCT + + cor0.col0 DIV 83 + ( col2 ) AS col1 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-886
SELECT DISTINCT + + cor0.col0 / 83 + ( col2 ) AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + - col1 * 59 AS col2 FROM tab0 AS cor0
----
-5074
-5369
-5723

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

query I rowsort
SELECT + + col2 * 26 + - cor0.col1 FROM tab0 AS cor0
----
-71
2041
772

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

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

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

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

query I rowsort
SELECT ALL - col2 - + 64 FROM tab0 AS cor0
----
-146
-65
-97

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

query I rowsort
SELECT ALL + col2 * - col2 * col2 + - col1 AS col2 FROM tab2 AS cor0
----
-17635
-19714
-54889

query I rowsort
SELECT DISTINCT - col1 + + 89 AS col2 FROM tab1 AS cor0
----
63
76
79

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

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

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

query I rowsort
SELECT ALL - col2 + 66 AS col0 FROM tab2
----
28
39
40

query I rowsort
SELECT ALL col0 + col1 * - col1 FROM tab2
----
-210
-3403
-954

query I rowsort
SELECT ALL col1 * 33 + + col1 FROM tab0
----
2924
3094
3298

query I rowsort
SELECT - 74 + + col2 AS col0 FROM tab2 AS cor0
----
-36
-47
-48

query I rowsort
SELECT 88 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

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

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

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

skipif mysql # not compatible
query I rowsort label-905
SELECT + col1 * CAST ( + col0 AS INTEGER ) * tab1.col2 + ( + col2 ) AS col0 FROM tab1
----
36537
4266
99936

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

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

query I rowsort
SELECT DISTINCT + + ( cor0.col2 ) + + ( 27 ) AS col0 FROM tab1 AS cor0
----
123
81
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-909
SELECT - - col1 + + col2 DIV CAST( + col0 AS SIGNED ) FROM tab1 cor0
----
10
14
44

skipif mysql # not compatible
query I rowsort label-909
SELECT - - col1 + + col2 / CAST ( + col0 AS INTEGER ) FROM tab1 cor0
----
10
14
44

query I rowsort
SELECT ALL + - 86 AS col1 FROM tab2 AS cor0
----
-86
-86
-86

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

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

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

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

query I rowsort
SELECT 8 + - col0 AS col0 FROM tab2
----
-70
-71
1

query I rowsort
SELECT DISTINCT 27 * col2 * col0 AS col2 FROM tab2
----
5103
54756
81054

query I rowsort
SELECT DISTINCT col2 * - 67 AS col0 FROM tab0
----
-2211
-5494
-67

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

query I rowsort
SELECT + 68 AS col0 FROM tab2
----
68
68
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-918
SELECT DISTINCT col0 DIV col2 + + col0 DIV - col1 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-918
SELECT DISTINCT col0 / col2 + + col0 / - col1 FROM tab0
----
0
1
35

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

query I rowsort
SELECT + cor0.col2 + - col2 * - col2 AS col0 FROM tab1 AS cor0
----
2970
3306
9312

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

query I rowsort
SELECT ALL - col1 * col2 * 37 FROM tab1 AS cor0
----
-21090
-46176
-51948

query I rowsort
SELECT + 97 + + col2 FROM tab2
----
123
124
135

query I rowsort
SELECT DISTINCT - cor0.col0 + + col2 * cor0.col2 * - cor0.col2 FROM tab2 AS cor0
----
-17654
-19690
-54951

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-927
SELECT DISTINCT - col2 * + col1 DIV col1 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-927
SELECT DISTINCT - col2 * + col1 / col1 FROM tab1
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-928
SELECT - col2 * col1 DIV - tab0.col0 FROM tab0
----
118
2
83

skipif mysql # not compatible
query I rowsort label-928
SELECT - col2 * col1 / - tab0.col0 FROM tab0
----
118
2
83

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

query I rowsort
SELECT + 44 FROM tab2, tab2 AS cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 * 19 col1 FROM tab1 AS cor0
----
-1026
-1083
-1824

onlyif mysql # use DIV operator for integer division
query I rowsort label-932
SELECT + ( col2 ) * + col2 + + 2 DIV + cor0.col2 FROM tab1 AS cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-932
SELECT + ( col2 ) * + col2 + + 2 / + cor0.col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT + 74 + col0 AS col2 FROM tab0 AS cor0
----
109
163
98

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 89 + - col2 col0 FROM tab0 AS cor0
----
56
7
88

query I rowsort
SELECT col2 + + col2 * col0 * 92 + - tab0.col2 AS col1 FROM tab0
----
3220
671416
72864

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

query I rowsort
SELECT - 45 + + col2 + ( 54 ) FROM tab1 AS cor0
----
105
63
66

query I rowsort
SELECT - cor0.col2 + - 6 FROM tab0 AS cor0
----
-39
-7
-88

query I rowsort
SELECT - col2 * - 89 + + 89 * + col1 FROM tab0 AS cor0
----
10591
15397
8722

query I rowsort
SELECT DISTINCT col0 * + 77 + + col1 AS col0 FROM tab2 cor0
----
570
6065
6100

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

query I rowsort
SELECT ALL + - col2 * + 61 + 31 FROM tab0 AS cor0
----
-1982
-30
-4971

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

query I rowsort
SELECT - col1 * 89 FROM tab0 AS cor0
----
-7654
-8099
-8633

query I rowsort
SELECT cor1.col1 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab0, tab2 cor2
----
243 values hashing to c6425afc100dd55de8d45dec18c469ea

skipif mysql # not compatible
query I rowsort
SELECT CAST ( cor0.col0 AS REAL ) AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

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

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

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

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

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

query I rowsort
SELECT ALL + 88 * - 67 + - col2 FROM tab2 AS cor0
----
-5922
-5923
-5934

query I rowsort
SELECT 30 * - col1 AS col2 FROM tab1 AS cor0
----
-300
-390
-780

onlyif mysql # use DIV operator for integer division
query I rowsort label-956
SELECT DISTINCT - - 95 DIV - cor0.col1 FROM tab1 AS cor0
----
-3
-7
-9

skipif mysql # not compatible
query I rowsort label-956
SELECT DISTINCT - - 95 / - cor0.col1 FROM tab1 AS cor0
----
-3
-7
-9

query I rowsort
SELECT + ( cor0.col2 ) AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL - col1 * cor0.col1 + + col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 50 - - col0 * - 61 * col0 col1 FROM tab2 cor0
----
-2939
-371074
-380651

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

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

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

query I rowsort
SELECT ALL + - cor0.col1 + 57 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to d5b3a4d577c02cc0cc030c536e56959b

query I rowsort
SELECT DISTINCT + cor0.col0 + 50 AS col0 FROM tab1 AS cor0
----
114
130
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-965
SELECT DISTINCT + 46 DIV - col2 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-965
SELECT DISTINCT + 46 / - col2 FROM tab1
----
0

query I rowsort
SELECT ( + col1 ) * 19 FROM tab1
----
190
247
494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + tab2.col1 col0 FROM tab2
----
118
34
62

query I rowsort
SELECT col0 * ( col0 ) * col1 - - col0 * + tab2.col2 FROM tab2
----
109099
1708
360984

query I rowsort
SELECT DISTINCT ( tab0.col1 ) AS col1 FROM tab0, tab2 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + 91 - + 77 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

onlyif mysql # use DIV operator for integer division
query I rowsort label-971
SELECT - col2 DIV + col2 + col0 * + col2 FROM tab1
----
161
3647
7679

skipif mysql # not compatible
query I rowsort label-971
SELECT - col2 / + col2 + col0 * + col2 FROM tab1
----
161
3647
7679

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

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

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

query I rowsort
SELECT 28 * col2 - - col1 * col2 FROM tab0 AS cor0
----
125
3762
9758

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

query I rowsort
SELECT - 39 + col0 AS col1 FROM tab1 cor0
----
-36
25
41

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

query I rowsort
SELECT DISTINCT - 71 * col2 AS col2 FROM tab1 AS cor0
----
-3834
-4047
-6816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 75 * + col0 col0 FROM tab0 AS cor0
----
1800
2625
6675

query I rowsort
SELECT DISTINCT - ( - col1 ) - - col2 FROM tab1
----
109
67
80

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

query I rowsort
SELECT ALL 67 * + tab2.col0 - col0 * + col1 AS col1 FROM tab2
----
252
3950
624

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-985
SELECT ALL - ( + tab0.col2 ) * col1 - col2 DIV + col0 FROM tab0
----
-2839
-7462
-97

skipif mysql # not compatible
query I rowsort label-985
SELECT ALL - ( + tab0.col2 ) * col1 - col2 / + col0 FROM tab0
----
-2839
-7462
-97

query I rowsort
SELECT + tab0.col0 * - 51 + col1 * col0 * - col2 AS col1 FROM tab0
----
-5180
-668657
-69336

query I rowsort
SELECT ( col0 + col2 ) * col2 AS col2 FROM tab0
----
14022
1881
36

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-989
SELECT - 71 * col2 - + col0 DIV + col2 FROM tab1
----
-3834
-4048
-6816

skipif mysql # not compatible
query I rowsort label-989
SELECT - 71 * col2 - + col0 / + col2 FROM tab1
----
-3834
-4048
-6816

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

query I rowsort
SELECT DISTINCT 89 + + col0 AS col0 FROM tab1
----
153
169
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-992
SELECT - col0 * col0 DIV cor0.col0 - col1 FROM tab0 AS cor0
----
-110
-132
-180

skipif mysql # not compatible
query I rowsort label-992
SELECT - col0 * col0 / cor0.col0 - col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT - 71 * - col1 + - cor0.col1 AS col0 FROM tab2 AS cor0
----
1190
2170
4130

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

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

query I rowsort
SELECT DISTINCT - cor0.col0 * - cor0.col0 + col2 * col2 - - col0 AS col2 FROM tab0 AS cor0
----
1261
14734
1689

query I rowsort
SELECT ALL - 15 * - col1 + col1 FROM tab1 AS cor0
----
160
208
416

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

query I rowsort
SELECT ALL - 36 + - col2 * cor0.col1 + - col2 AS col1 FROM tab2 cor0
----
-1596
-720
-900

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

query I rowsort
SELECT - ( - tab2.col1 ) * - col2 FROM tab2
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-1002
SELECT ( - col0 ) DIV col2 + col1 AS col1 FROM tab1
----
13
26
9

skipif mysql # not compatible
query I rowsort label-1002
SELECT ( - col0 ) / col2 + col1 AS col1 FROM tab1
----
13
26
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1003
SELECT DISTINCT ( col0 ) DIV - col0 + + col1 * - col1 col0 FROM tab0
----
-7397
-8282
-9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1003
SELECT DISTINCT ( col0 ) / - col0 + + col1 * - col1 col0 FROM tab0
----
-7397
-8282
-9410

query I rowsort
SELECT cor0.col1 + - 52 AS col0 FROM tab2 AS cor0
----
-21
-35
7

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

query I rowsort
SELECT DISTINCT + col1 * + col1 + - col2 * - col0 * col0 FROM tab0 AS cor0
----
10634
26404
657803

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

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

query I rowsort
SELECT ALL 62 + col0 * col1 AS col2 FROM tab0
----
2126
3457
8161

query I rowsort
SELECT + ( - 93 ) * - col0 FROM tab2 AS cor0
----
651
7254
7347

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

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

query I rowsort
SELECT - 18 * + col0 FROM tab0 AS cor0
----
-1602
-432
-630

query I rowsort
SELECT ALL - col0 FROM tab1 WHERE NOT NULL = NULL
----

query I rowsort
SELECT - col1 * col2 + + col0 FROM tab2
----
-1456
-567
-830

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

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

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

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

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

query I rowsort
SELECT ALL col0 * col0 + - cor0.col1 * - col1 FROM tab2 AS cor0
----
1010
6530
9565

query I rowsort
SELECT col0 + + col0 + - col1 * col2 FROM tab1 cor0
----
-1088
-1398
-442

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

query I rowsort
SELECT - col2 * col1 + col0 + col1 FROM tab2 AS cor0
----
-1397
-550
-799

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

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

query I rowsort
SELECT col0 + - col0 + + cor0.col0 AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL col1 + - col0 * + col2 - col0 FROM tab0 AS cor0
----
-7296
-730
27

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

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

skipif mysql # not compatible
query I rowsort label-1027
SELECT ALL col2 * col0 / - col2 FROM tab0 AS cor0
----
-24
-35
-89

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1028
SELECT col2 / - col1 + + col0 col1 FROM tab1
----
1
59
73

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

query I rowsort
SELECT - col2 FROM tab0 WHERE NOT NULL BETWEEN NULL AND ( NULL ) AND NULL < ( NULL )
----

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1033
SELECT + col1 + col2 DIV col1 FROM tab1
----
15
20
28

skipif mysql # not compatible
query I rowsort label-1033
SELECT + col1 + col2 / col1 FROM tab1
----
15
20
28

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

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

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

query I rowsort
SELECT - + cor0.col2 * ( cor0.col0 ) AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to f7e57a354e4e5925116b9650d1011609

query I rowsort
SELECT + 29 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

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

query I rowsort
SELECT DISTINCT + col0 * + ( col0 + + col1 ) FROM tab1
----
4736
7440
87

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

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

query I rowsort
SELECT ALL + 70 * cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to be00591f9886d7eb84584586c1406373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( 38 ) * col0 * 16 + cor0.col1 col2 FROM tab2 AS cor0
----
4287
47483
48049

onlyif mysql # use DIV operator for integer division
query I rowsort label-1045
SELECT DISTINCT 22 DIV col0 AS col0 FROM tab2
----
0
3

skipif mysql # not compatible
query I rowsort label-1045
SELECT DISTINCT 22 / col0 AS col0 FROM tab2
----
0
3

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

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

query I rowsort
SELECT - + 66 * col1 AS col2 FROM tab2 AS cor0
----
-1122
-2046
-3894

query I rowsort
SELECT + 84 * + col1 * + 30 FROM tab2 AS cor0
----
148680
42840
78120

query I rowsort
SELECT - col0 + cor0.col0 * + col0 AS col0 FROM tab2 cor0
----
42
6006
6162

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

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

skipif mysql # not compatible
query I rowsort label-1051
SELECT DISTINCT ( - col1 ) + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1053
SELECT 55 - col1 DIV - ( col2 ) FROM tab1
----
55
55
55

skipif mysql # not compatible
query I rowsort label-1053
SELECT 55 - col1 / - ( col2 ) FROM tab1
----
55
55
55

query I rowsort
SELECT DISTINCT - col0 * col2 + 44 * + col1 FROM tab2
----
-2254
1175
568

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * + col0 col1 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1058
SELECT - col1 * cor0.col1 * 44 + 26 DIV cor0.col1 FROM tab0 AS cor0
----
-325424
-364364
-413996

skipif mysql # not compatible
query I rowsort label-1058
SELECT - col1 * cor0.col1 * 44 + 26 / cor0.col1 FROM tab0 AS cor0
----
-325424
-364364
-413996

onlyif mysql # use DIV operator for integer division
query I rowsort label-1059
SELECT ALL + + col1 * ( - ( - col0 ) ) DIV col2 + col2 + - col2 col0 FROM tab1 AS cor0
----
1
10
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1059
SELECT ALL + + col1 * ( - ( - col0 ) ) / col2 + col2 + - col2 col0 FROM tab1 AS cor0
----
1
10
11

query I rowsort
SELECT ALL col0 * - 0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 * + 64 AS col2 FROM tab1 AS cor0
----
1664
640
832

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 + 99 + col1 col1 FROM tab2 AS cor0
----
137
195
236

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1065
SELECT ALL - col2 + + col0 DIV ( - 31 ) AS col2 FROM tab1
----
-54
-59
-98

skipif mysql # not compatible
query I rowsort label-1065
SELECT ALL - col2 + + col0 / ( - 31 ) AS col2 FROM tab1
----
-54
-59
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-1066
SELECT + col0 + col2 DIV + 37 AS col0 FROM tab2 AS cor0
----
7
78
80

skipif mysql # not compatible
query I rowsort label-1066
SELECT + col0 + col2 / + 37 AS col0 FROM tab2 AS cor0
----
7
78
80

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1070
SELECT - + col1 + col0 / col0 col1 FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT col2 + col1 * col0 - 3 AS col1 FROM tab0
----
2094
3393
8178

query I rowsort
SELECT 34 * - col0 + + cor0.col0 * + cor0.col2 FROM tab1 cor0
----
1472
4960
60

query I rowsort
SELECT - col1 * - 19 * + col0 FROM tab2 AS cor0
----
25517
4123
87438

query I rowsort
SELECT - - 38 + - ( col2 ) AS col1 FROM tab0 cor0
----
-44
37
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1075
SELECT CAST( + 0 AS SIGNED ) + - col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-1075
SELECT CAST ( + 0 AS INTEGER ) + - col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL col1 + - 95 AS col0 FROM tab1 AS cor0
----
-69
-82
-85

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

skipif mysql # not compatible
query I rowsort label-1077
SELECT col2 / 55 AS col1 FROM tab0
----
0
0
1

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

query I rowsort
SELECT DISTINCT + 5 * 94 + col1 AS col2 FROM tab2 AS cor0
----
487
501
529

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

query I rowsort
SELECT ALL - ( 21 ) + + cor0.col1 * col2 FROM tab0 AS cor0
----
2817
7441
76

query I rowsort
SELECT - - col1 - 62 * - col0 FROM tab1 AS cor0
----
212
3978
4973

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

query I rowsort
SELECT DISTINCT - 84 + + col0 FROM tab0
----
-49
-60
5

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

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

query I rowsort
SELECT DISTINCT + + ( col2 ) + - cor0.col1 * + col0 + - cor0.col1 FROM tab1 AS cor0
----
-50
-593
-957

query I rowsort
SELECT DISTINCT - col0 + 5 AS col0 FROM tab0 AS cor0
----
-19
-30
-84

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( - col0 AS REAL ) + col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT - 35 * col0 FROM tab1 cor0
----
-105
-2240
-2800

query I rowsort
SELECT DISTINCT - ( col1 ) * + col0 - 76 AS col1 FROM tab0 AS cor0
----
-2140
-3471
-8175

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

query I rowsort
SELECT DISTINCT + + col1 * 87 AS col2 FROM tab2 AS cor0
----
1479
2697
5133

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1094
SELECT DISTINCT - CAST( - 65 AS SIGNED ) + - cor0.col0 * col1 AS col0 FROM tab0 AS cor0
----
-1999
-3330
-8034

skipif mysql # not compatible
query I rowsort label-1094
SELECT DISTINCT - CAST ( - 65 AS INTEGER ) + - cor0.col0 * col1 AS col0 FROM tab0 AS cor0
----
-1999
-3330
-8034

query I rowsort
SELECT DISTINCT - col0 + cor0.col2 + col1 * - col2 * + 58 AS col0 FROM tab0 AS cor0
----
-164595
-432803
-5660

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1096
SELECT ALL - CAST( col1 AS SIGNED ) - col0 * - ( 15 ) AS col1 FROM tab2 AS cor0
----
1111
1168
74

skipif mysql # not compatible
query I rowsort label-1096
SELECT ALL - CAST ( col1 AS INTEGER ) - col0 * - ( 15 ) AS col1 FROM tab2 AS cor0
----
1111
1168
74

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1100
SELECT col0 * CAST ( col2 AS INTEGER ) * col1 + - 19 * col2 FROM tab0
----
3376
662560
67485

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

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

query I rowsort
SELECT ALL - cor0.col1 - + 81 AS col0 FROM tab2 AS cor0
----
-112
-140
-98

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

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

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

query I rowsort
SELECT DISTINCT - col2 * + 80 AS col0 FROM tab2 cor0
----
-2080
-2160
-3040

query I rowsort
SELECT ALL col2 + - 28 FROM tab2 AS cor0
----
-1
-2
10

query I rowsort
SELECT + col0 * ( cor0.col1 + col1 ) AS col1 FROM tab2 AS cor0
----
2686
434
9204

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

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

query I rowsort
SELECT ALL + 7 + col0 FROM tab0
----
31
42
96

query I rowsort
SELECT ALL + col2 + - tab1.col0 + 78 AS col1 FROM tab1
----
129
71
94

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

query I rowsort
SELECT col0 - 71 * + col1 AS col1 FROM tab0
----
-6082
-6372
-6852

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

query I rowsort
SELECT - 79 FROM tab1, tab2 cor0
----
9 values hashing to 1b7b0b34fe3431fb409719624d12791f

query I rowsort
SELECT - 22 * tab0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 537e5885fc7fd0d75c6a2a51b2d0dd23

query I rowsort
SELECT ALL + ( - cor1.col0 ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + 49 - col2 col1 FROM tab2 AS cor0
----
101
29
90

query I rowsort
SELECT ALL - 57 * + col0 FROM tab2
----
-399
-4446
-4503

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - 20 col2 FROM tab0 AS cor0
----
-1780
-480
-700

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

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

query I rowsort
SELECT DISTINCT + 83 * col2 + col2 FROM tab2
----
2184
2268
3192

query I rowsort
SELECT + 69 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 2810c3097fe4771e273cfff903357b40

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1128
SELECT ALL + col2 DIV - col2 + col1 FROM tab0 cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-1128
SELECT ALL + col2 / - col2 + col1 FROM tab0 cor0
----
85
90
96

query I rowsort
SELECT ALL - 5 + col1 AS col0 FROM tab1 AS cor0
----
21
5
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-1130
SELECT - - col0 + col1 DIV col1 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-1130
SELECT - - col0 + col1 / col1 FROM tab2 AS cor0
----
79
8
80

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

query I rowsort
SELECT - 22 * col1 + + 27 * 30 AS col2 FROM tab1 AS cor0
----
238
524
590

query I rowsort
SELECT DISTINCT + col2 + + 88 * col0 AS col2 FROM tab0 AS cor0
----
2145
3081
7914

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

query I rowsort
SELECT + col1 * - col1 + + 49 FROM tab2 AS cor0
----
-240
-3432
-912

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1138
SELECT ALL - col0 + + 70 * + col1 DIV - col1 col0 FROM tab1 AS cor0
----
-134
-150
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1138
SELECT ALL - col0 + + 70 * + col1 / - col1 col0 FROM tab1 AS cor0
----
-134
-150
-73

query I rowsort
SELECT - col2 * ( 82 * col1 + - ( col0 ) ) FROM tab2 AS cor0
----
-123760
-49970
-68445

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

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

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

query I rowsort
SELECT DISTINCT col2 + ( 31 ) FROM tab2 cor0
----
57
58
69

query I rowsort
SELECT DISTINCT cor0.col1 * + cor0.col0 + col0 * - col2 FROM tab1 AS cor0
----
-3008
-6640
-84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 + ( - col2 * col1 ) + cor0.col2 col0 FROM tab1 AS cor0
----
-1165
-1376
-523

onlyif mysql # use DIV operator for integer division
query I rowsort label-1146
SELECT DISTINCT - 59 + + col2 + - 61 DIV 97 AS col0 FROM tab2
----
-21
-32
-33

skipif mysql # not compatible
query I rowsort label-1146
SELECT DISTINCT - 59 + + col2 + - 61 / 97 AS col0 FROM tab2
----
-21
-32
-33

query I rowsort
SELECT - 11 * + col1 FROM tab0
----
-1001
-1067
-946

onlyif mysql # use DIV operator for integer division
query I rowsort label-1148
SELECT - col0 + - ( - 43 + + col0 ) DIV - 99 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-1148
SELECT - col0 + - ( - 43 + + col0 ) / - 99 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + col2 + + 34 FROM tab2 AS cor0
----
60
61
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-1150
SELECT - + cor0.col1 * col2 + + col2 DIV cor0.col2 AS col2 FROM tab1 AS cor0
----
-1247
-1403
-569

skipif mysql # not compatible
query I rowsort label-1150
SELECT - + cor0.col1 * col2 + + col2 / cor0.col2 AS col2 FROM tab1 AS cor0
----
-1247
-1403
-569

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

query I rowsort
SELECT - 5 * col0 FROM tab0 AS cor0
----
-120
-175
-445

query I rowsort
SELECT DISTINCT + 86 * + cor1.col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
4644
4902
8256

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

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

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

query I rowsort
SELECT - 71 * col1 FROM tab1 AS cor0
----
-1846
-710
-923

query I rowsort
SELECT + tab2.col1 * - 94 FROM tab2, tab0, tab0 AS cor0, tab1
----
81 values hashing to acaf898aaa02ea4e44742217ef52330b

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1162
SELECT DISTINCT - col0 - - CAST ( col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
2
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-1163
SELECT ALL - col2 DIV + ( - col1 ) + + col1 * - col0 + col1 FROM tab0 cor0
----
-1978
-3298
-8008

skipif mysql # not compatible
query I rowsort label-1163
SELECT ALL - col2 / + ( - col1 ) + + col1 * - col0 + col1 FROM tab0 cor0
----
-1978
-3298
-8008

query I rowsort
SELECT col2 - + col0 * ( + col0 * + col1 + - col0 ) FROM tab0
----
-117599
-48927
-712808

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * tab2.col2 * tab2.col2 col2 FROM tab2
----
114076
5103
52728

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1171
SELECT ALL + col0 + + col0 DIV col2 col1 FROM tab0
----
24
70
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1171
SELECT ALL + col0 + + col0 / col2 col1 FROM tab0
----
24
70
90

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

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

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

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

query I rowsort
SELECT ALL col2 AS col0 FROM tab2 WHERE NULL BETWEEN col2 + col0 AND col2 * + col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col1 + col0 col1 FROM tab1
----
1328
1407
634

query III rowsort
SELECT * FROM tab1 WHERE ( - col1 ) <> + col2 + col2
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT DISTINCT - col0 + col0 AS col1 FROM tab1 WHERE ( - col2 ) BETWEEN ( NULL ) AND - col1
----

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

query I rowsort
SELECT tab2.col1 * - col1 + col2 * col0 AS col1 FROM tab2
----
-1453
-772
2713

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

query I rowsort
SELECT ALL - tab1.col0 + - tab1.col0 + + col1 * - tab1.col1 FROM tab1
----
-228
-329
-682

query I rowsort
SELECT 37 + + col1 FROM tab2
----
54
68
96

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

skipif mysql # not compatible
query I rowsort label-1185
SELECT + ( - col1 ) / 46 FROM tab0 AS cor0
----
-1
-1
-2

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 45 col2 FROM tab0
----
45

query I rowsort
SELECT - ( + 23 ) - cor0.col1 FROM tab2 AS cor0
----
-40
-54
-82

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

query I rowsort
SELECT ALL + ( - 20 ) + col0 * col0 + col2 AS col2 FROM tab2
----
56
6090
6259

query I rowsort
SELECT col1 + + 32 * - col0 AS col0 FROM tab1
----
-2038
-2547
-70

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

query I rowsort
SELECT ALL col1 + col0 * + 9 * ( col0 * ( col0 ) ) FROM tab0 AS cor0
----
124502
385972
6344812

onlyif mysql # use DIV operator for integer division
query I rowsort label-1194
SELECT DISTINCT col1 + col2 DIV col2 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-1194
SELECT DISTINCT col1 + col2 / col2 FROM tab1 AS cor0
----
11
14
27

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

query I rowsort
SELECT ALL + col0 + cor0.col1 * - 32 AS col1 FROM tab0 cor0
----
-2728
-2823
-3069

query I rowsort
SELECT + 63 * col1 + + cor0.col0 * + cor0.col2 FROM tab0 AS cor0
----
13031
6146
6210

query I rowsort
SELECT DISTINCT + 36 * - col1 FROM tab1 AS cor0
----
-360
-468
-936

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

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

skipif mysql # not compatible
query I rowsort label-1200
SELECT ALL + 20 / - col0 AS col0 FROM tab2 AS cor0
----
-2
0
0

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

query I rowsort
SELECT DISTINCT + + 63 FROM tab1 AS cor0
----
63

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

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

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

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

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 99 * - col2 col1 FROM tab1 AS cor0
----
-5346
-5643
-9504

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

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

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

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

query I rowsort
SELECT col2 - + 8 AS col0 FROM tab1 cor0
----
46
49
88

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

query I rowsort
SELECT - tab0.col1 * col0 * col1 + 24 AS col1 FROM tab0
----
-177480
-329291
-736985

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

skipif mysql # not compatible
query I rowsort label-1217
SELECT 29 * col1 - - CAST ( + ( col0 ) AS INTEGER ) AS col0 FROM tab2
----
1789
572
906

query I rowsort
SELECT + 68 FROM tab0, tab2, tab0 cor0
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

query I rowsort
SELECT - - 42 * col2 * ( 12 ) FROM tab0 cor0
----
16632
41328
504

query I rowsort
SELECT ALL 73 * col1 * - col0 FROM tab0
----
-150672
-247835
-591227

query I rowsort
SELECT - 57 + + col1 FROM tab1
----
-31
-44
-47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - 15 + - col1 col1 FROM tab0 AS cor0
----
1244
274
428

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * + col1 * col1 col2 FROM tab2 AS cor0
----
-22831
-271518
-6727

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

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

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

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

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

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

query I rowsort
SELECT - 59 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 1e6537c922fa953e0fd2f59430803703

query I rowsort
SELECT - cor0.col0 * + 68 AS col1 FROM tab0 AS cor0
----
-1632
-2380
-6052

query I rowsort
SELECT ALL - cor0.col1 + - 25 * - col1 FROM tab1 AS cor0
----
240
312
624

query I rowsort
SELECT - - col2 + col1 * 70 AS col2 FROM tab2 AS cor0
----
1228
2197
4156

query I rowsort
SELECT DISTINCT - 2 * - col1 FROM tab2
----
118
34
62

query I rowsort
SELECT ALL + + col0 + + 33 FROM tab0 AS cor0
----
122
57
68

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

query I rowsort
SELECT ALL - cor0.col0 * - 79 FROM tab1 AS cor0
----
237
5056
6320

query I rowsort
SELECT - col0 * col2 * - 17 AS col0 FROM tab2 AS cor0
----
3213
34476
51034

query I rowsort
SELECT ALL + 96 + + 35 FROM tab1 AS cor0
----
131
131
131

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1239
SELECT DISTINCT + cor0.col1 + col0 DIV col1 FROM tab2 AS cor0
----
21
31
60

skipif mysql # not compatible
query I rowsort label-1239
SELECT DISTINCT + cor0.col1 + col0 / col1 FROM tab2 AS cor0
----
21
31
60

query I rowsort
SELECT - col1 + - 39 * + col0 FROM tab1 AS cor0
----
-143
-2506
-3133

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

skipif mysql # not compatible
query I rowsort label-1241
SELECT ALL - - col2 * ( col2 ) + CAST ( cor0.col2 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
1482
702
756

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

query I rowsort
SELECT DISTINCT - + col2 * - col1 + + col1 * 59 FROM tab1 AS cor0
----
1160
2015
2938

query I rowsort
SELECT - + 14 + + 8 * col2 * 28 FROM tab0 AS cor0
----
18354
210
7378

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

skipif mysql # not compatible
query I rowsort
SELECT ALL - + ( 14 ) + + cor0.col1 * + CAST ( cor0.col2 AS REAL ) FROM tab0 AS cor0
----
2824
7448
83

query I rowsort
SELECT ALL 50 + ( col0 + - 9 * col2 ) AS col2 FROM tab0 AS cor0
----
-223
-599
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-1248
SELECT DISTINCT - 68 DIV + col0 FROM tab1 AS cor0
----
-1
-22
0

skipif mysql # not compatible
query I rowsort label-1248
SELECT DISTINCT - 68 / + col0 FROM tab1 AS cor0
----
-1
-22
0

query I rowsort
SELECT ALL - + 3 * 80 + col1 FROM tab2 AS cor0
----
-181
-209
-223

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

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

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

query I rowsort
SELECT DISTINCT + - 90 + col0 FROM tab1 AS cor0
----
-10
-26
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-1254
SELECT ALL 69 DIV - 31 AS col2 FROM tab2 AS cor0
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-1254
SELECT ALL 69 / - 31 AS col2 FROM tab2 AS cor0
----
-2
-2
-2

query I rowsort
SELECT 20 + - ( col1 ) FROM tab1 cor0
----
-6
10
7

query I rowsort
SELECT DISTINCT - ( - 63 ) + col2 AS col0 FROM tab2 AS cor0
----
101
89
90

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

query I rowsort
SELECT DISTINCT 54 + + 90 * - col2 FROM tab1
----
-4806
-5076
-8586

query I rowsort
SELECT - - 33 + col0 * + col0 FROM tab1 AS cor0
----
4129
42
6433

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

query I rowsort
SELECT 32 + - cor0.col0 FROM tab1 AS cor0
----
-32
-48
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 + - cor0.col0 + ( col1 * - col2 ) col2 FROM tab0 AS cor0
----
-131
-2829
-7469

onlyif mysql # use DIV operator for integer division
query I rowsort label-1263
SELECT DISTINCT + ( col2 ) DIV col1 + 41 * + tab2.col2 FROM tab2
----
1066
1107
1560

skipif mysql # not compatible
query I rowsort label-1263
SELECT DISTINCT + ( col2 ) / col1 + 41 * + tab2.col2 FROM tab2
----
1066
1107
1560

onlyif mysql # use DIV operator for integer division
query I rowsort label-1264
SELECT 5 * col1 + col1 DIV 61 AS col0 FROM tab0
----
431
456
486

skipif mysql # not compatible
query I rowsort label-1264
SELECT 5 * col1 + col1 / 61 AS col0 FROM tab0
----
431
456
486

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

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

query I rowsort
SELECT ALL + 55 AS col1 FROM tab2
----
55
55
55

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1269
SELECT - tab1.col1 DIV - tab1.col2 + - col0 * col1 AS col1 FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-1269
SELECT - tab1.col1 / - tab1.col2 + - col0 * col1 AS col1 FROM tab1
----
-1040
-640
-78

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 2 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT ALL 58 + col0 AS col1 FROM tab1
----
122
138
61

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1273
SELECT + CAST ( NULL AS REAL ) * + 59 col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * - col0 + col2 AS col1 FROM tab2
----
-22
-6058
-6203

query I rowsort
SELECT DISTINCT 13 * 31 + cor0.col1 FROM tab0 AS cor0
----
489
494
500

query I rowsort
SELECT + cor0.col0 + cor0.col1 * + col2 * + ( - 9 ) AS col2 FROM tab2 AS cor0
----
-13728
-5735
-7526

query I rowsort
SELECT DISTINCT + 36 - ( col1 + col2 ) * col1 FROM tab1 AS cor0
----
-1381
-2044
-634

query I rowsort
SELECT + + 87 + - 40 FROM tab0 AS cor0
----
47
47
47

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor1.col0 col2 FROM tab2, tab0 AS cor0, tab2 cor1, tab1, tab1 AS cor2
----
243 values hashing to 455e4df3bf7b0fa681c56e89df1a761f

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

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

query I rowsort
SELECT - cor0.col0 * + ( 78 ) + + col1 AS col2 FROM tab0 cor0
----
-1786
-2633
-6851

query I rowsort
SELECT + col1 + 62 * col1 FROM tab0 cor0
----
5418
5733
6111

query I rowsort
SELECT + + col0 * 91 + col2 FROM tab2 AS cor0
----
664
7124
7227

query I rowsort
SELECT + col1 * + 42 + 94 AS col2 FROM tab0 cor0
----
3706
3916
4168

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

query I rowsort
SELECT 56 * col1 AS col1 FROM tab0 AS cor0
----
4816
5096
5432

query I rowsort
SELECT + - ( + col1 ) + + col2 * 64 FROM tab1 AS cor0
----
3430
3638
6131

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 4 + - 4 * - col2 * - col0 col1 FROM tab2 AS cor0
----
-12012
-760
-8116

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

query I rowsort
SELECT DISTINCT + - ( - 38 ) * - col0 FROM tab0 AS cor0
----
-1330
-3382
-912

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col1 + 63 * + cor0.col0 col0 FROM tab1 AS cor0
----
267
4672
6080

query I rowsort
SELECT ALL + ( - col2 ) - 5 AS col0 FROM tab1
----
-101
-59
-62

query I rowsort
SELECT 20 + col0 FROM tab1 AS cor0
----
100
23
84

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

query I rowsort
SELECT - col2 + + cor0.col2 * col2 AS col1 FROM tab1 AS cor0
----
2862
3192
9120

query I rowsort
SELECT ALL col0 * ( 86 ) AS col2 FROM tab2 AS cor0
----
602
6708
6794

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 + + 64 col2 FROM tab0 AS cor0
----
146
65
97

query I rowsort
SELECT - col0 - - 52 * 54 AS col1 FROM tab2 AS cor0
----
2729
2730
2801

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

query I rowsort
SELECT DISTINCT ( 79 * cor0.col2 ) AS col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
4266
4503
7584

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

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

query I rowsort
SELECT + col2 - + 50 FROM tab2 AS cor0
----
-12
-23
-24

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

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

skipif mysql # not compatible
query I rowsort label-1309
SELECT ALL + - col0 / ( 55 ) AS col1 FROM tab1 cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + ( - col2 ) * col0 col0 FROM tab2 AS cor0
----
-182
-1950
-2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * - col0 - col2 col0 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT + - col1 * cor0.col1 - 49 AS col1 FROM tab1 AS cor0
----
-149
-218
-725

onlyif mysql # use DIV operator for integer division
query I rowsort label-1313
SELECT DISTINCT - col2 - ( - col0 ) DIV col0 FROM tab1
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-1313
SELECT DISTINCT - col2 - ( - col0 ) / col0 FROM tab1
----
-53
-56
-95

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

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

query I rowsort
SELECT DISTINCT + 71 + - 27 * col1 AS col1 FROM tab2 AS cor0
----
-1522
-388
-766

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL + - CAST ( + 86 AS REAL ) + col0 col1 FROM tab0 AS cor0
----
-51
-62
3

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

query I rowsort
SELECT + col1 * + col1 + + 96 * col0 FROM tab0 cor0
----
12769
16825
9700

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

query I rowsort
SELECT DISTINCT col0 + 95 AS col1 FROM tab2
----
102
173
174

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col0 * + col2 + 87 col0 FROM tab2
----
2115
276
3089

query I rowsort
SELECT - 94 FROM tab2, tab1, tab0 AS cor0, tab0
----
81 values hashing to d4c5b1dbf2cd8753fb5ffe745ca9f5de

onlyif mysql # use DIV operator for integer division
query I rowsort label-1324
SELECT ALL + 28 DIV - col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1324
SELECT ALL + 28 / - col2 FROM tab1 cor0
----
0
0
0

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor1.col0 col2 FROM tab2, tab0, tab1 AS cor0, tab2 cor1
----
-7
-78
-79

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

skipif mysql # not compatible
query I rowsort label-1327
SELECT ALL + ( + 47 ) / + tab0.col0 AS col2 FROM tab0
----
0
1
1

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + cor0.col2 + - col1 - + CAST ( col0 AS REAL ) AS col1 FROM tab0 AS cor0
----
-131
-77
-98

query I rowsort
SELECT ALL + col1 + - col2 * + 77 AS col2 FROM tab1 AS cor0
----
-4132
-4379
-7379

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

query I rowsort
SELECT DISTINCT + ( col0 ) + 44 FROM tab0 AS cor0
----
133
68
79

query I rowsort
SELECT + 83 FROM tab2, tab0 cor0
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

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

query I rowsort
SELECT - 98 * + col1 + - col1 AS col1 FROM tab2 AS cor0
----
-1683
-3069
-5841

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1337
SELECT DISTINCT col0 DIV ( - 65 + col0 ) AS col1 FROM tab1
----
-64
0
5

skipif mysql # not compatible
query I rowsort label-1337
SELECT DISTINCT col0 / ( - 65 + col0 ) AS col1 FROM tab1
----
-64
0
5

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

query I rowsort
SELECT - col0 * 57 + - 52 * col0 FROM tab0
----
-2616
-3815
-9701

query I rowsort
SELECT DISTINCT - col2 * + col2 + + col2 + tab2.col0 FROM tab2
----
-1327
-572
-695

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

skipif mysql # not compatible
query I rowsort label-1341
SELECT DISTINCT + CAST ( - 9 AS INTEGER ) FROM tab2 AS cor0
----
-9

query I rowsort
SELECT DISTINCT - - 66 * col0 - cor0.col0 AS col0 FROM tab0 AS cor0
----
1560
2275
5785

query I rowsort
SELECT - ( + 73 ) FROM tab0
----
-73
-73
-73

query I rowsort
SELECT ALL col1 * - 4 AS col2 FROM tab0 AS cor0
----
-344
-364
-388

query I rowsort
SELECT - - cor0.col2 * + 4 * col2 FROM tab0 cor0
----
26896
4
4356

query I rowsort
SELECT col1 + 99 * col0 AS col1 FROM tab0 AS cor0
----
2462
3562
8902

query I rowsort
SELECT DISTINCT + 35 + 46 FROM tab1 AS cor0
----
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 61 * - cor0.col0 * col1 col1 FROM tab2 AS cor0
----
13237
280722
81923

query I rowsort
SELECT DISTINCT + col1 * - 74 FROM tab0 AS cor0
----
-6364
-6734
-7178

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1351
SELECT DISTINCT + - col2 * col0 + col0 DIV - col1 FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-1351
SELECT DISTINCT + - col2 * col0 + col0 / - col1 FROM tab0 AS cor0
----
-35
-7298
-792

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

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

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

query I rowsort
SELECT 79 + col0 FROM tab1
----
143
159
82

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

query I rowsort
SELECT ALL - col1 * + cor0.col1 + col0 * - col1 * + col2 + col2 * 62 FROM tab2 cor0
----
-121521
-48967
-5146

query I rowsort
SELECT col1 * - col2 + + 23 + - 66 * col0 AS col2 FROM tab1 cor0
----
-1579
-4771
-6505

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

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

query I rowsort
SELECT - col1 * col2 + + 92 + ( col0 ) AS col2 FROM tab1 AS cor0
----
-1076
-1309
-414

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

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

skipif mysql # not compatible
query I rowsort label-1363
SELECT ALL - col1 / + col0 + col1 FROM tab2 AS cor0
----
17
27
59

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

query I rowsort
SELECT ( 5 ) AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 + ( - cor0.col1 * col2 ) + 58 col1 FROM tab2 AS cor0
----
-1535
-605
-810

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

query I rowsort
SELECT ALL 55 + cor0.col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 2e22653dd511815ad294b192ab0e7fd2

onlyif mysql # use DIV operator for integer division
query I rowsort label-1370
SELECT col0 DIV + col1 + + col0 * - cor0.col0 AS col2 FROM tab0 cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-1370
SELECT col0 / + col1 + + col0 * - cor0.col0 AS col2 FROM tab0 cor0
----
-1225
-576
-7921

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

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

query I rowsort
SELECT col2 * col0 + 67 FROM tab2 AS cor0
----
2095
256
3069

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

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

query I rowsort
SELECT - col1 * col0 * 78 + - col1 * col1 - cor0.col1 FROM tab0 AS cor0
----
-168474
-274316
-640094

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

skipif mysql # not compatible
query I rowsort label-1375
SELECT CAST ( NULL AS REAL ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - col1 + 22 AS col0 FROM tab0 AS cor0
----
-64
-69
-75

query I rowsort
SELECT + - col1 + - cor0.col1 * - 50 AS col2 FROM tab1 AS cor0
----
1274
490
637

query I rowsort
SELECT DISTINCT col1 * + 13 + 8 AS col1 FROM tab2 AS cor0
----
229
411
775

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

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

query I rowsort
SELECT - cor0.col0 * 77 * cor0.col1 + - col0 AS col2 FROM tab0 AS cor0
----
-158952
-261450
-623712

query I rowsort
SELECT + 53 - - cor0.col1 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 8ebf8a463ed6934c4a1fbd29e1cc9e19

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1385
SELECT col2 * col0 DIV - col1 + - col1 FROM tab1
----
-32
-374
-603

skipif mysql # not compatible
query I rowsort label-1385
SELECT col2 * col0 / - col1 + - col1 FROM tab1
----
-32
-374
-603

query I rowsort
SELECT + 5 * col2 FROM tab0 AS cor0
----
165
410
5

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

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

query I rowsort
SELECT ALL col2 * - col0 + + 17 FROM tab1
----
-145
-3631
-7663

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

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

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

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

query I rowsort
SELECT + 64 * - col1 + - col1 AS col2 FROM tab1
----
-1690
-650
-845

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

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

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

query I rowsort
SELECT DISTINCT 29 * - col2 - col0 AS col0 FROM tab0
----
-2467
-64
-981

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 8 col2 FROM tab1, tab0 AS cor0, tab2, tab1 cor1
----
81 values hashing to a42c42e56e75960d97c09dd731d99c01

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 16 * - col1 * ( + col1 ) - col1 col2 FROM tab0 AS cor0
----
-118422
-132587
-150641

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

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

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

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

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 6 * 44 col2 FROM tab1 cor0
----
-264
-264
-264

query I rowsort
SELECT - 57 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-1482
-570
-741

query I rowsort
SELECT DISTINCT - ( - col0 ) AS col1 FROM tab2 AS cor0
----
7
78
79

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

query I rowsort
SELECT - 84 + + 37 FROM tab0 AS cor0
----
-47
-47
-47

query I rowsort
SELECT ALL + 27 * + col1 + - col1 * ( - cor0.col0 ) FROM tab2 AS cor0
----
1054
1802
6195

query I rowsort
SELECT ALL + 67 + - 40 AS col1 FROM tab1 AS cor0
----
27
27
27

query I rowsort
SELECT DISTINCT - col2 + - 73 * col2 * - ( + cor0.col1 ) AS col2 FROM tab1 AS cor0
----
102438
41553
91008

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

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

query I rowsort
SELECT ALL + col2 + - col2 + ( + col1 ) AS col2 FROM tab2 AS cor0
----
17
31
59

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

query I rowsort
SELECT - 17 + col2 AS col0 FROM tab2 AS cor0
----
10
21
9

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

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

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

query I rowsort
SELECT - 56 * - col0 - + 91 AS col1 FROM tab1 AS cor0
----
3493
4389
77

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

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

query I rowsort
SELECT - 28 + col2 * col0 FROM tab1 AS cor0
----
134
3620
7652

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

query I rowsort
SELECT col1 - 61 * + col1 FROM tab1
----
-1560
-600
-780

query I rowsort
SELECT + tab2.col0 * col0 * + col0 + 28 FROM tab2
----
371
474580
493067

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1434
SELECT DISTINCT + + col1 DIV + 92 FROM tab2 cor0
----
0

skipif mysql # not compatible
query I rowsort label-1434
SELECT DISTINCT + + col1 / + 92 FROM tab2 cor0
----
0

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1436
SELECT ALL + - col1 DIV - 29 FROM tab0 AS cor0
----
2
3
3

skipif mysql # not compatible
query I rowsort label-1436
SELECT ALL + - col1 / - 29 FROM tab0 AS cor0
----
2
3
3

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

query I rowsort
SELECT ALL 17 * + col1 AS col2 FROM tab0
----
1462
1547
1649

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

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

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

query I rowsort
SELECT + col0 - ( - col0 + + col1 ) AS col2 FROM tab2 cor0
----
-17
141
97

query I rowsort
SELECT ALL + col0 + + col1 * 29 AS col0 FROM tab1 cor0
----
354
457
757

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

query I rowsort
SELECT DISTINCT + tab1.col0 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
3
64
80

query I rowsort
SELECT ALL - + col2 * ( col0 ) + - col1 AS col2 FROM tab1 AS cor0
----
-188
-3658
-7693

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1450
SELECT ALL 91 DIV - tab2.col1 - ( - col0 + + col0 ) AS col1 FROM tab2
----
-1
-2
-5

skipif mysql # not compatible
query I rowsort label-1450
SELECT ALL 91 / - tab2.col1 - ( - col0 + + col0 ) AS col1 FROM tab2
----
-1
-2
-5

query I rowsort
SELECT + + col0 + + 60 FROM tab2 AS cor0
----
138
139
67

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

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

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

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

query I rowsort
SELECT tab1.col1 + - 44 * col1 FROM tab1
----
-1118
-430
-559

query I rowsort
SELECT - col2 * 53 + - 7 + - col1 FROM tab2
----
-1444
-1469
-2038

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

query I rowsort
SELECT + 25 * - col0 FROM tab0 AS cor0
----
-2225
-600
-875

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

query I rowsort
SELECT DISTINCT - - col1 + - col0 * - col2 - - col1 FROM tab1 AS cor0
----
214
3668
7706

query I rowsort
SELECT - ( 57 ) AS col2 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 0b74bbd7631afe9b2eeb9f18b9dc6505

query I rowsort
SELECT - tab1.col2 + + 15 FROM tab1
----
-39
-42
-81

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1464
SELECT 12 DIV - col1 + - 34 AS col1 FROM tab1
----
-34
-34
-35

skipif mysql # not compatible
query I rowsort label-1464
SELECT 12 / - col1 + - 34 AS col1 FROM tab1
----
-34
-34
-35

query I rowsort
SELECT DISTINCT tab0.col0 + + 31 AS col0 FROM tab0, tab1 AS cor0
----
120
55
66

query I rowsort
SELECT DISTINCT + col2 * col1 + 62 FROM tab1 AS cor0
----
1310
1466
632

query I rowsort
SELECT ALL col2 + col0 * 62 FROM tab1 cor0
----
240
4025
5056

query I rowsort
SELECT ALL + cor0.col0 + cor0.col2 - col2 FROM tab2 AS cor0
----
7
78
79

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

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

query I rowsort
SELECT ALL col2 * col2 - + 82 AS col2 FROM tab2 AS cor0
----
1362
594
647

query I rowsort
SELECT ALL - + 6 FROM tab0, tab1, tab0 cor0
----
27 values hashing to 8be8910507908e6353d02a545b748252

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

query I rowsort
SELECT + cor0.col1 + 29 AS col1 FROM tab0, tab2, tab0 AS cor0, tab1
----
81 values hashing to 7fbe40f56456f6724be12ae4dd459ae5

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

query I rowsort
SELECT col2 * ( - 64 ) AS col2 FROM tab1
----
-3456
-3648
-6144

query I rowsort
SELECT - + col0 * + 20 * 41 - - col2 FROM tab0 AS cor0
----
-19647
-28699
-72898

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

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

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

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

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

query I rowsort
SELECT - 17 + + 77 AS col2 FROM tab1 AS cor0
----
60
60
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1482
SELECT DISTINCT + CAST( - 31 AS SIGNED ) * col1 col0 FROM tab0 AS cor0
----
-2666
-2821
-3007

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1482
SELECT DISTINCT + CAST ( - 31 AS INTEGER ) * col1 col0 FROM tab0 AS cor0
----
-2666
-2821
-3007

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

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

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

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

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

query I rowsort
SELECT ALL - - 90 * - 33 - + col2 * col0 FROM tab2 AS cor0
----
-3159
-4998
-5972

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

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

query I rowsort
SELECT + col2 + col1 * + 15 FROM tab2 AS cor0
----
293
492
911

query I rowsort
SELECT ALL - col1 * 18 FROM tab1
----
-180
-234
-468

query I rowsort
SELECT DISTINCT + 4 AS col1 FROM tab1, tab1 AS cor0
----
4

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

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

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 ALL col0 * col1 + col0 AS col0 FROM tab2
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-1495
SELECT DISTINCT col0 DIV + col1 + col0 * + col2 FROM tab2
----
189
2029
3006

skipif mysql # not compatible
query I rowsort label-1495
SELECT DISTINCT col0 / + col1 + col0 * + col2 FROM tab2
----
189
2029
3006

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

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

skipif mysql # not compatible
query I rowsort label-1497
SELECT ALL col2 / - col1 + + tab0.col0 * + tab0.col1 AS col2 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-1498
SELECT DISTINCT + col0 + col0 DIV tab0.col2 FROM tab0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-1498
SELECT DISTINCT + col0 + col0 / tab0.col2 FROM tab0
----
24
70
90

query I rowsort
SELECT ALL col1 * - col0 * + col1 + + col2 * col1 FROM tab1
----
-12272
-5830
-624

query I rowsort
SELECT - col2 + - col1 * tab2.col1 FROM tab2
----
-327
-3507
-988

query I rowsort
SELECT ALL col0 + col0 - col1 FROM tab1
----
-20
118
147

query I rowsort
SELECT - 7 - - col1 AS col1 FROM tab2 AS cor0
----
10
24
52

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

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

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( col1 ) <> col1 + col1 / col0
----

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + - col2 col2 FROM tab0 WHERE NOT NULL IN ( - col0 )
----

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

query I rowsort
SELECT DISTINCT + col1 / - col2 FROM tab0 AS cor0 WHERE NULL = col0
----

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT col2 FROM tab1 AS cor0 WHERE NULL NOT BETWEEN NULL AND NULL
----

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1521
SELECT DISTINCT 78 + 44 DIV cor0.col2 FROM tab2, tab0 AS cor0
----
122
78
79

skipif mysql # not compatible
query I rowsort label-1521
SELECT DISTINCT 78 + 44 / cor0.col2 FROM tab2, tab0 AS cor0
----
122
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + col0 * + col1 col2 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL - cor0.col1 + 4 AS col1 FROM tab1 AS cor0
----
-22
-6
-9

query I rowsort
SELECT DISTINCT + col0 * + 88 FROM tab0 AS cor0
----
2112
3080
7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-1525
SELECT DISTINCT col2 * col2 DIV + col1 FROM tab0 AS cor0
----
0
12
73

skipif mysql # not compatible
query I rowsort label-1525
SELECT DISTINCT col2 * col2 / + col1 FROM tab0 AS cor0
----
0
12
73

query I rowsort
SELECT ALL - 53 AS col0 FROM tab1 AS cor0
----
-53
-53
-53

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

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

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

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

query I rowsort
SELECT + 94 + col0 * + col1 FROM tab0 cor0
----
2158
3489
8193

query I rowsort
SELECT ALL - - 24 * + 9 FROM tab1 cor0
----
216
216
216

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

skipif mysql # not compatible
query I rowsort label-1533
SELECT DISTINCT + - CAST ( cor0.col2 AS INTEGER ) / col2 AS col1 FROM tab1 AS cor0
----
-1

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

query I rowsort
SELECT ALL 3 + - 33 FROM tab2, tab2 cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 6993f5c634597e63319c949df6b4733d

query I rowsort
SELECT DISTINCT - ( + 57 ) * col0 AS col0 FROM tab1 AS cor0
----
-171
-3648
-4560

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

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

query I rowsort
SELECT ALL + col0 + tab1.col0 AS col1 FROM tab1
----
128
160
6

query I rowsort
SELECT ALL + - 9 + col2 FROM tab2 AS cor0
----
17
18
29

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

query I rowsort
SELECT cor1.col1 * + 86 AS col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 149415a063bb0f6819c6aede5bcaf735

query I rowsort
SELECT DISTINCT + - 58 + - cor0.col0 FROM tab1 AS cor0
----
-122
-138
-61

query I rowsort
SELECT + + col0 * col0 + 43 FROM tab0 AS cor0
----
1268
619
7964

query I rowsort
SELECT DISTINCT 66 - col0 * - col1 AS col2 FROM tab0 cor0
----
2130
3461
8165

onlyif mysql # use DIV operator for integer division
query I rowsort label-1545
SELECT + col1 * col1 DIV 31 + - col0 + col2 AS col0 FROM tab1 AS cor0
----
-4
21
72

skipif mysql # not compatible
query I rowsort label-1545
SELECT + col1 * col1 / 31 + - col0 + col2 AS col0 FROM tab1 AS cor0
----
-4
21
72

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

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

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

skipif mysql # not compatible
query I rowsort label-1547
SELECT col0 + CAST ( col0 AS INTEGER ) + - cor0.col2 FROM tab0 AS cor0
----
15
69
96

query I rowsort
SELECT DISTINCT - cor0.col2 + 55 FROM tab0 AS cor0
----
-27
22
54

query I rowsort
SELECT + col0 * 31 + 92 FROM tab2 cor0
----
2510
2541
309

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

query I rowsort
SELECT DISTINCT - col0 + 64 AS col2 FROM tab0 cor0
----
-25
29
40

query I rowsort
SELECT ALL - cor0.col1 * 29 AS col2 FROM tab1 cor0
----
-290
-377
-754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * 52 col0 FROM tab0 AS cor0
----
4472
4732
5044

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1555
SELECT - col0 DIV - col0 + ( col2 ) FROM tab2 cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-1555
SELECT - col0 / - col0 + ( col2 ) FROM tab2 cor0
----
27
28
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 + + col1 * + col0 col1 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-1557
SELECT cor0.col0 + CAST( - col1 AS SIGNED ) DIV - col0 FROM tab0 AS cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-1557
SELECT cor0.col0 + CAST ( - col1 AS INTEGER ) / - col0 FROM tab0 AS cor0
----
27
37
90

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

skipif mysql # not compatible
query I rowsort label-1558
SELECT DISTINCT tab2.col2 + col2 / col0 AS col1 FROM tab2
----
26
30
38

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

skipif mysql # not compatible
query I rowsort label-1559
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-1560
SELECT DISTINCT cor0.col2 + - col1 DIV col0 AS col1 FROM tab0 cor0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-1560
SELECT DISTINCT cor0.col2 + - col1 / col0 AS col1 FROM tab0 cor0
----
-1
30
81

query I rowsort
SELECT ALL 91 + + col2 + col0 FROM tab2
----
125
195
208

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

query I rowsort
SELECT cor0.col2 * + tab2.col0 FROM tab1, tab0, tab2 AS cor0, tab2
----
81 values hashing to 6caddfe5c357b7e258927d1751d2db27

query I rowsort
SELECT ALL ( 94 ) * col0 + + col2 * col2 FROM tab0 AS cor0
----
15090
3291
3345

query I rowsort
SELECT ALL + + 95 * col1 + + col0 + col2 FROM tab0 AS cor0
----
8227
8816
9251

query I rowsort
SELECT DISTINCT + col2 * 34 AS col2 FROM tab1 AS cor0
----
1836
1938
3264

query I rowsort
SELECT - col2 * 20 AS col0 FROM tab2 AS cor0
----
-520
-540
-760

query I rowsort
SELECT 30 * cor0.col0 FROM tab0 AS cor0
----
1050
2670
720

query I rowsort
SELECT - + 9 * - col2 + - col2 FROM tab0 AS cor0
----
264
656
8

query I rowsort
SELECT - 91 - + col1 * - 12 AS col2 FROM tab0 AS cor0
----
1001
1073
941

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1571
SELECT - col0 + col1 + CAST( 80 AS SIGNED ) FROM tab1 AS cor0
----
103
13
26

skipif mysql # not compatible
query I rowsort label-1571
SELECT - col0 + col1 + CAST ( 80 AS INTEGER ) FROM tab1 AS cor0
----
103
13
26

query I rowsort
SELECT col1 + - col2 * - col2 + + col1 FROM tab0 cor0
----
1261
195
6906

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * cor0.col2 + ( + col1 ) col0 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT + col2 + col2 * - col2 FROM tab0 AS cor0
----
-1056
-6642
0

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

query I rowsort
SELECT ALL 12 + col0 - + tab2.col2 FROM tab2
----
-8
53
64

query I rowsort
SELECT ALL - + col0 * + cor0.col2 - col1 * col2 * ( col0 ) FROM tab1 cor0
----
-107520
-40128
-4374

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

query I rowsort
SELECT ALL + col1 + col0 - 42 AS col2 FROM tab2 AS cor0
----
-4
54
95

query I rowsort
SELECT ALL col0 + 40 AS col0 FROM tab2 AS cor0
----
118
119
47

query I rowsort
SELECT ALL - + col1 * + 50 * 83 AS col2 FROM tab2 AS cor0
----
-128650
-244850
-70550

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1583
SELECT ALL col1 + col0 * 8 - col2 * CAST( NULL AS SIGNED ) / - 13 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1583
SELECT ALL col1 + col0 * 8 - col2 * CAST ( NULL AS INTEGER ) / - 13 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + 60 col1 FROM tab2 AS cor0
----
86
87
98

query I rowsort
SELECT + - col1 * - 12 FROM tab1 AS cor0
----
120
156
312

query I rowsort
SELECT DISTINCT col2 + + ( - col0 ) AS col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT 88 + - col0 AS col1 FROM tab2
----
10
81
9

query I rowsort
SELECT ALL + tab1.col1 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT DISTINCT - col0 * cor0.col2 * + 64 FROM tab0 AS cor0
----
-2240
-467072
-50688

onlyif mysql # use DIV operator for integer division
query I rowsort label-1590
SELECT + + col2 * + col2 + col2 DIV + cor0.col1 AS col1 FROM tab1 AS cor0
----
2918
3254
9223

skipif mysql # not compatible
query I rowsort label-1590
SELECT + + col2 * + col2 + col2 / + cor0.col1 AS col1 FROM tab1 AS cor0
----
2918
3254
9223

query I rowsort
SELECT DISTINCT + col0 + - 41 AS col1 FROM tab2 AS cor0
----
-34
37
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 7 * 3 col0 FROM tab0 AS cor0
----
21
21
21

query I rowsort
SELECT 0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT - 75 FROM tab0, tab1 cor0
----
9 values hashing to 258bc565c64924d905a55eaaa6e57547

query I rowsort
SELECT ALL 11 * + col0 FROM tab1
----
33
704
880

query I rowsort
SELECT ALL + 58 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 9ee363c6ac19cfdb8a50c7dfd5cc2b8a

query I rowsort
SELECT DISTINCT 3 + 41 AS col1 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
44

query I rowsort
SELECT DISTINCT + + 57 + 97 * + col1 AS col1 FROM tab1 AS cor0
----
1027
1318
2579

query I rowsort
SELECT - + col1 + col0 - + col0 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT - 59 AS col0 FROM tab0 cor0
----
-59
-59
-59

query I rowsort
SELECT ALL - 85 + col1 * 75 AS col2 FROM tab2 AS cor0
----
1190
2240
4340

query I rowsort
SELECT col2 + col0 * col1 * 80 + + col2 AS col2 FROM tab0 AS cor0
----
165186
271602
648084

onlyif mysql # use DIV operator for integer division
query I rowsort label-1603
SELECT cor0.col2 DIV cor0.col1 + - ( cor0.col0 ) * cor0.col1 * + col1 AS col1 FROM tab1 AS cor0
----
-13513
-2026
-6395

skipif mysql # not compatible
query I rowsort label-1603
SELECT cor0.col2 / cor0.col1 + - ( cor0.col0 ) * cor0.col1 * + col1 AS col1 FROM tab1 AS cor0
----
-13513
-2026
-6395

query I rowsort
SELECT + + col0 * 78 FROM tab0 AS cor0
----
1872
2730
6942

query I rowsort
SELECT - 69 + - col2 FROM tab2 AS cor0
----
-107
-95
-96

query I rowsort
SELECT DISTINCT - 19 * col0 + + ( col1 * col1 ) AS col2 FROM tab2 cor0
----
-1212
1999
828

query I rowsort
SELECT - 25 + col1 FROM tab1 cor0
----
-12
-15
1

query I rowsort
SELECT DISTINCT - 66 + + col1 + col2 AS col2 FROM tab0 AS cor0
----
107
32
53

query I rowsort
SELECT - - col1 + col2 * ( 27 ) AS col2 FROM tab2 cor0
----
1043
760
761

query I rowsort
SELECT + - cor0.col2 * + cor0.col1 + - ( 74 * col0 ) + ( - 1 ) FROM tab1 AS cor0
----
-1627
-5307
-7169

onlyif mysql # use DIV operator for integer division
query I rowsort label-1611
SELECT ALL - col2 DIV + col1 + + col1 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-1611
SELECT ALL - col2 / + col1 + + col1 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + - col0 * 13 + ( + cor0.col2 ) AS col1 FROM tab2 AS cor0
----
-64
-988
-989

query I rowsort
SELECT cor0.col1 * ( 19 ) AS col2 FROM tab0 AS cor0
----
1634
1729
1843

query I rowsort
SELECT + - col0 + 65 FROM tab2 AS cor0
----
-13
-14
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-1615
SELECT - tab2.col1 DIV - tab2.col0 - - col0 AS col0 FROM tab2
----
11
78
79

skipif mysql # not compatible
query I rowsort label-1615
SELECT - tab2.col1 / - tab2.col0 - - col0 AS col0 FROM tab2
----
11
78
79

query I rowsort
SELECT + col2 + 17 FROM tab2 cor0
----
43
44
55

query I rowsort
SELECT + 66 * 72 FROM tab2 AS cor0
----
4752
4752
4752

query I rowsort
SELECT - + col0 - + col0 * col2 AS col0 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT ALL 96 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT ALL + 58 + col0 AS col1 FROM tab2 AS cor0
----
136
137
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + - col1 col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT col0 * col0 * - col1 FROM tab2
----
-106097
-1519
-358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - 63 col0 FROM tab0 AS cor0
----
-30
-62
19

query I rowsort
SELECT + 54 * ( col0 ) FROM tab0
----
1296
1890
4806

query I rowsort
SELECT - tab0.col0 FROM tab0, tab0 cor0, tab2 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT ALL + col2 + + col0 * + tab1.col0 * col0 FROM tab1
----
262201
512096
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col1 + col1 col2 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT ALL - 35 * col0 FROM tab1 AS cor0
----
-105
-2240
-2800

query I rowsort
SELECT col1 * 45 AS col2 FROM tab2
----
1395
2655
765

onlyif mysql # use DIV operator for integer division
query I rowsort label-1630
SELECT ( + col0 ) DIV + col2 + + col2 AS col2 FROM tab1
----
54
58
96

skipif mysql # not compatible
query I rowsort label-1630
SELECT ( + col0 ) / + col2 + + col2 AS col2 FROM tab1
----
54
58
96

query I rowsort
SELECT DISTINCT 26 * col1 FROM tab2
----
1534
442
806

query I rowsort
SELECT col0 * - col2 + + col0 * + 18 FROM tab1
----
-108
-2496
-6240

onlyif mysql # use DIV operator for integer division
query I rowsort label-1633
SELECT - col0 - - col2 DIV + col0 FROM tab1
----
-64
-79
15

skipif mysql # not compatible
query I rowsort label-1633
SELECT - col0 - - col2 / + col0 FROM tab1
----
-64
-79
15

query I rowsort
SELECT DISTINCT col0 * col1 + ( - tab2.col2 ) AS col2 FROM tab2
----
1305
190
4576

query I rowsort
SELECT 93 + - col1 * - 7 FROM tab1 AS cor0
----
163
184
275

query I rowsort
SELECT - ( - col1 ) + - col2 FROM tab0 cor0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 - - col2 col2 FROM tab1 AS cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-1638
SELECT + col0 + cor0.col1 DIV col2 AS col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-1638
SELECT + col0 + cor0.col1 / col2 AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT col2 + col2 - 40 FROM tab1 cor0
----
152
68
74

query I rowsort
SELECT ALL 18 * - col2 FROM tab1
----
-1026
-1728
-972

query I rowsort
SELECT DISTINCT - col1 * col1 * + 78 FROM tab1 AS cor0
----
-13182
-52728
-7800

onlyif mysql # use DIV operator for integer division
query I rowsort label-1642
SELECT DISTINCT + 38 + col1 DIV cor0.col2 FROM tab1 AS cor0
----
38

skipif mysql # not compatible
query I rowsort label-1642
SELECT DISTINCT + 38 + col1 / cor0.col2 FROM tab1 AS cor0
----
38

query I rowsort
SELECT DISTINCT col1 * - col0 * + col2 AS col2 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT + + 18 AS col2 FROM tab2, tab0, tab0 AS cor0, tab1
----
81 values hashing to a13db73ec93475d2821cb4a6d0eff298

query I rowsort
SELECT + col0 - - ( - tab1.col0 ) FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 73 col0 FROM tab1, tab2 cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT + col2 + ( + col2 ) FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT - 93 FROM tab2, tab0 cor0, tab2 AS cor1
----
27 values hashing to ea79c61f7a02d25805171f5e85229fba

query I rowsort
SELECT ALL 57 + + cor0.col0 AS col2 FROM tab2 AS cor0
----
135
136
64

query I rowsort
SELECT DISTINCT col0 * - 26 FROM tab0 AS cor0
----
-2314
-624
-910

query I rowsort
SELECT DISTINCT + 32 + col1 FROM tab1 cor0
----
42
45
58

query I rowsort
SELECT + - cor1.col1 AS col2 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 18 + + col0 + + col1 col1 FROM tab0 cor0
----
128
150
198

query I rowsort
SELECT + - cor0.col1 * - 39 + - cor0.col0 + - col0 AS col1 FROM tab1 AS cor0
----
1008
262
347

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 34 + col1 col1 FROM tab2 AS cor0
----
51
65
93

query I rowsort
SELECT - 19 - - col1 FROM tab1 AS cor0
----
-6
-9
7

query I rowsort
SELECT ALL - - 84 AS col1 FROM tab0 AS cor0
----
84
84
84

query I rowsort
SELECT ALL - col2 * 70 FROM tab0
----
-2310
-5740
-70

query I rowsort
SELECT - - col0 + col1 * - col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL + cor0.col1 * - 81 FROM tab2 cor0
----
-1377
-2511
-4779

query I rowsort
SELECT DISTINCT col2 * - 98 * tab0.col2 AS col1 FROM tab0
----
-106722
-658952
-98

query I rowsort
SELECT DISTINCT + col2 * col2 + - 80 AS col1 FROM tab2 cor0
----
1364
596
649

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 24 + + col0 col1 FROM tab0
----
113
48
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-1664
SELECT 4 DIV - 48 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1664
SELECT 4 / - 48 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - 54 AS col1 FROM tab1 AS cor0
----
-54
-54
-54

onlyif mysql # use DIV operator for integer division
query I rowsort label-1666
SELECT DISTINCT + 16 DIV - col1 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-1666
SELECT DISTINCT + 16 / - col1 FROM tab2
----
0

query I rowsort
SELECT DISTINCT + cor0.col0 * + col0 + + col1 + + 40 AS col2 FROM tab0 AS cor0
----
1362
702
8052

query I rowsort
SELECT + - ( col1 ) * + cor0.col1 + col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

onlyif mysql # use DIV operator for integer division
query I rowsort label-1669
SELECT + + col0 * col0 DIV 21 AS col1 FROM tab1 AS cor0
----
0
195
304

skipif mysql # not compatible
query I rowsort label-1669
SELECT + + col0 * col0 / 21 AS col1 FROM tab1 AS cor0
----
0
195
304

query I rowsort
SELECT DISTINCT + col0 + + col0 * + 4 FROM tab0 AS cor0
----
120
175
445

onlyif mysql # use DIV operator for integer division
query I rowsort label-1671
SELECT 24 DIV col1 AS col2 FROM tab1 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-1671
SELECT 24 / col1 AS col2 FROM tab1 AS cor0
----
0
1
2

query I rowsort
SELECT DISTINCT + - ( cor0.col0 ) * - 67 AS col1 FROM tab2 AS cor0
----
469
5226
5293

query I rowsort
SELECT - + col2 * + col1 * 69 AS col0 FROM tab2 AS cor0
----
-105846
-44574
-57753

onlyif mysql # use DIV operator for integer division
query I rowsort label-1674
SELECT - cor0.col2 DIV col1 FROM tab2 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-1674
SELECT - cor0.col2 / col1 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT ALL - 68 * col0 + - 86 AS col1 FROM tab2
----
-5390
-5458
-562

query I rowsort
SELECT - col1 * col0 + - col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1677
SELECT - - CAST( NULL AS SIGNED ) AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1677
SELECT - - CAST ( NULL AS INTEGER ) AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + - col0 + 92 AS col2 FROM tab1 AS cor0
----
12
28
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-1679
SELECT + col0 DIV - 44 FROM tab2 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-1679
SELECT + col0 / - 44 FROM tab2 AS cor0
----
-1
-1
0

query I rowsort
SELECT - cor0.col0 * col2 + - 83 AS col1 FROM tab0 AS cor0
----
-118
-7381
-875

query I rowsort
SELECT DISTINCT col0 + - 43 * - cor0.col1 FROM tab0 cor0
----
3722
4002
4206

query I rowsort
SELECT + col0 * - 90 AS col1 FROM tab1 AS cor0
----
-270
-5760
-7200

query I rowsort
SELECT 84 + + col0 * - col0 * col1 FROM tab0
----
-118741
-49452
-720727

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col2 ) + col1 * + 60 col0 FROM tab1 AS cor0
----
1614
657
876

query I rowsort
SELECT - cor0.col0 - cor0.col1 AS col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT ( - col0 ) - col1 AS col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT + ( - 55 ) + + col2 AS col1 FROM tab1 AS cor0
----
-1
2
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 53 col2 FROM tab2 AS cor0
----
53
53
53

query I rowsort
SELECT - + cor0.col2 - 68 FROM tab0 AS cor0
----
-101
-150
-69

query I rowsort
SELECT + col1 + + 66 AS col1 FROM tab0 cor0
----
152
157
163

query I rowsort
SELECT DISTINCT - col1 * ( 91 ) * col1 + col1 AS col1 FROM tab2
----
-26282
-316712
-87420

query I rowsort
SELECT - - 88 FROM tab1 cor0
----
88
88
88

query I rowsort
SELECT DISTINCT 51 + - col0 FROM tab2 AS cor0
----
-27
-28
44

query I rowsort
SELECT DISTINCT - 0 AS col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - col0 * ( + 46 ) AS col2 FROM tab1
----
-138
-2944
-3680

query I rowsort
SELECT DISTINCT - ( + col1 ) + + col0 - - col2 * + col2 FROM tab1 cor0
----
2893
3303
9283

query I rowsort
SELECT - tab0.col2 * ( col1 ) * - col1 AS col0 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT - col0 * - col1 + cor0.col0 * col1 - col0 AS col1 FROM tab1 AS cor0
----
1216
153
2000

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1699
SELECT ALL + col1 + + CAST( NULL AS SIGNED ) + col0 * - col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1699
SELECT ALL + col1 + + CAST ( NULL AS INTEGER ) + col0 * - col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( 44 ) FROM tab1 AS cor0
----
-44
-44
-44

query I rowsort
SELECT ALL - col1 * - col0 * col1 + col1 * cor0.col2 FROM tab2 AS cor0
----
23477
273052
7564

query I rowsort
SELECT ALL - + ( ( col0 ) ) + + ( col1 * col2 ) FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT - - col1 * cor0.col1 + - col2 FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT DISTINCT - 86 - - 88 AS col1 FROM tab1 cor0
----
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 69 * - col1 * cor0.col1 col1 FROM tab2 AS cor0
----
-19941
-240189
-66309

query I rowsort
SELECT + - 40 + col0 AS col1 FROM tab1 AS cor0
----
-37
24
40

query I rowsort
SELECT DISTINCT - + 91 * + col2 * col0 AS col1 FROM tab2 AS cor0
----
-17199
-184548
-273182

query I rowsort
SELECT ( 77 ) AS col1 FROM tab1 AS cor0
----
77
77
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * + col0 col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + + col0 + + 20 * col0 FROM tab0 AS cor0
----
1869
504
735

onlyif mysql # use DIV operator for integer division
query I rowsort label-1711
SELECT DISTINCT + - 97 * col0 DIV - col2 FROM tab1 AS cor0
----
108
5
80

skipif mysql # not compatible
query I rowsort label-1711
SELECT DISTINCT + - 97 * col0 / - col2 FROM tab1 AS cor0
----
108
5
80

query I rowsort
SELECT ( - col2 ) * + col0 - + ( col0 + - col0 ) FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL + col1 * + col0 - + ( - col0 ) FROM tab1
----
1120
704
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1714
SELECT ( + col1 ) + - CAST( - col0 AS SIGNED ) * col0 AS col2 FROM tab0 cor0
----
1322
662
8012

skipif mysql # not compatible
query I rowsort label-1714
SELECT ( + col1 ) + - CAST ( - col0 AS INTEGER ) * col0 AS col2 FROM tab0 cor0
----
1322
662
8012

query I rowsort
SELECT 23 * cor0.col2 AS col0 FROM tab1 AS cor0
----
1242
1311
2208

query I rowsort
SELECT + - 96 + - cor0.col1 FROM tab0 AS cor0
----
-182
-187
-193

query I rowsort
SELECT + 42 + cor0.col0 FROM tab0 AS cor0
----
131
66
77

query I rowsort
SELECT ALL + col1 * 32 AS col1 FROM tab2 AS cor0
----
1888
544
992

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1719
SELECT ALL - col0 * CAST( col0 * cor0.col2 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-1323
-158184
-237158

skipif mysql # not compatible
query I rowsort label-1719
SELECT ALL - col0 * CAST ( col0 * cor0.col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT + col0 + - 84 + 63 * col0 FROM tab1 cor0
----
108
4012
5036

query I rowsort
SELECT - 82 * - 74 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to f41185da2374fb43e5e8ab782e14bf3e

query I rowsort
SELECT DISTINCT - + col0 * 31 * + col2 + col2 FROM tab1 AS cor0
----
-113031
-237984
-4968

query I rowsort
SELECT + col1 * col1 - + 53 FROM tab0 AS cor0
----
7343
8228
9356

query I rowsort
SELECT + col0 + col0 * 18 FROM tab2 AS cor0
----
133
1482
1501

query I rowsort
SELECT col0 * 7 - + col0 AS col0 FROM tab1 cor0
----
18
384
480

query I rowsort
SELECT DISTINCT col0 * 55 * + 51 + - col1 * + col1 + + cor0.col1 FROM tab2 AS cor0
----
18705
215368
221323

query I rowsort
SELECT ALL + col0 + 67 + col2 * col2 FROM tab2 AS cor0
----
1590
803
821

query I rowsort
SELECT ALL + col2 * - ( col0 ) + + col0 FROM tab0 AS cor0
----
-7209
-768
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + - cor0.col1 col0 FROM tab2 cor0
----
-118
-34
-62

query I rowsort
SELECT col0 - - col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT ALL col1 + + ( + 30 ) * - cor0.col0 FROM tab0 cor0
----
-2579
-634
-953

query I rowsort
SELECT DISTINCT + col1 * + 15 + 82 + + cor0.col2 * col2 AS col2 FROM tab0 AS cor0
----
1538
2461
8171

onlyif mysql # use DIV operator for integer division
query I rowsort label-1733
SELECT + - col1 * + ( - col1 ) DIV - col1 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-1733
SELECT + - col1 * + ( - col1 ) / - col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL - col1 + 84 + - col1 AS col2 FROM tab0 AS cor0
----
-110
-88
-98

query I rowsort
SELECT DISTINCT - cor0.col2 - + col0 * - 13 FROM tab1 AS cor0
----
-15
775
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-1736
SELECT ALL + col2 DIV 82 - - col1 * col1 col2 FROM tab0 AS cor0
----
7396
8282
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1736
SELECT ALL + col2 / 82 - - col1 * col1 col2 FROM tab0 AS cor0
----
7396
8282
9409

query I rowsort
SELECT ALL - col1 * - cor0.col1 * col0 + + col2 AS col2 FROM tab2 AS cor0
----
22869
271544
6754

query I rowsort
SELECT ALL - + col1 * col1 + - 70 FROM tab0 AS cor0
----
-7466
-8351
-9479

query I rowsort
SELECT + col0 * cor0.col1 + col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT DISTINCT col2 + 29 FROM tab2
----
55
56
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-1741
SELECT DISTINCT + - ( - col0 ) DIV - col0 col1 FROM tab2 AS cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1741
SELECT DISTINCT + - ( - col0 ) / - col0 col1 FROM tab2 AS cor0
----
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1742
SELECT col2 * - 39 + col2 + - CAST( + 88 AS SIGNED ) col0 FROM tab1 AS cor0
----
-2140
-2254
-3736

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1742
SELECT col2 * - 39 + col2 + - CAST ( + 88 AS INTEGER ) col0 FROM tab1 AS cor0
----
-2140
-2254
-3736

query I rowsort
SELECT + 94 AS col1 FROM tab2, tab0 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to d876bb0ae813b06a5ee497ecacf37ee6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col0 - cor0.col0 col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + col0 + 80 FROM tab1
----
144
160
83

query I rowsort
SELECT ALL - cor0.col2 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab2, tab1 AS cor2
----
243 values hashing to 1d38a1a4aacea9827ed2338191291f0e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1747
SELECT col1 + CAST( NULL AS SIGNED ) * - col2 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1747
SELECT col1 + CAST ( NULL AS INTEGER ) * - col2 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * + col1 + cor0.col0 FROM tab0 AS cor0
----
2088
3430
8188

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0, tab2 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to 52c9380a39df7a744b9f2f2c5bf55dd5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * cor0.col2 col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL cor0.col1 * + col0 + ( + col0 ) * col2 AS col0 FROM tab2 AS cor0
----
406
4345
6630

query I rowsort
SELECT - - col0 + - col2 * - col2 AS col2 FROM tab0 AS cor0
----
1113
36
6813

onlyif mysql # use DIV operator for integer division
query I rowsort label-1753
SELECT DISTINCT - - col2 DIV - col1 + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-1753
SELECT DISTINCT - - col2 / - col1 + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + col2 * col1 + 84 FROM tab2 AS cor0
----
1618
730
921

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( 20 AS REAL ) col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
20

query I rowsort
SELECT - ( col2 ) AS col0 FROM tab2
----
-26
-27
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1757
SELECT ALL CAST( + cor0.col1 AS SIGNED ) col2 FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab2, tab2 AS cor1
----
243 values hashing to 42b04a30acb32fcd35bf97afdee87fe6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1757
SELECT ALL CAST ( + cor0.col1 AS INTEGER ) col2 FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab2, tab2 AS cor1
----
243 values hashing to 42b04a30acb32fcd35bf97afdee87fe6

query I rowsort
SELECT DISTINCT - 19 + col0 AS col1 FROM tab2
----
-12
59
60

query I rowsort
SELECT DISTINCT + tab1.col2 AS col2 FROM tab1, tab0, tab1 AS cor0
----
54
57
96

query I rowsort
SELECT 50 + + col1 AS col1 FROM tab0
----
136
141
147

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + col2 * + ( - ( col1 ) + ( - col2 ) ) col0 FROM tab1 AS cor0
----
-10451
-3809
-4294

query I rowsort
SELECT + 40 * col2 + + col2 FROM tab0 AS cor0
----
1353
3362
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-1763
SELECT ALL - 15 DIV col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1763
SELECT ALL - 15 / col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1764
SELECT col1 DIV 1 + col1 FROM tab2 AS cor0
----
118
34
62

skipif mysql # not compatible
query I rowsort label-1764
SELECT col1 / 1 + col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT + col0 * col1 + + col0 * col1 AS col1 FROM tab1
----
1280
156
2080

query I rowsort
SELECT tab0.col2 + + col2 AS col0 FROM tab0
----
164
2
66

query I rowsort
SELECT DISTINCT + tab1.col1 + 45 * - col0 FROM tab1
----
-109
-2870
-3587

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col1 col2 FROM tab2
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 24 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1770
SELECT ALL + CAST( NULL AS DECIMAL ) * + col0 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1770
SELECT ALL + CAST ( NULL AS REAL ) * + col0 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( - col2 ) * tab1.col1 AS col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + col0 - - 24 * ( col2 ) AS col0 FROM tab1 AS cor0
----
1299
1432
2384

query I rowsort
SELECT DISTINCT col1 - + col0 * col2 AS col0 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT col1 + col2 + 70 * 92 FROM tab2
----
6495
6498
6525

query I rowsort
SELECT ALL 69 * - col2 + col1 * - col0 FROM tab1
----
-3804
-4573
-7664

query I rowsort
SELECT DISTINCT + 37 + + col1 FROM tab2
----
54
68
96

query I rowsort
SELECT ALL 70 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1778
SELECT + - 86 * col2 - CAST( col2 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-4698
-4959
-8352

skipif mysql # not compatible
query I rowsort label-1778
SELECT + - 86 * col2 - CAST ( col2 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-4698
-4959
-8352

query I rowsort
SELECT ALL col0 + col1 + tab1.col0 FROM tab1
----
138
173
32

query I rowsort
SELECT col2 * + col1 + + col0 * col2 + tab0.col1 AS col1 FROM tab0
----
14851
229
3716

onlyif mysql # use DIV operator for integer division
query I rowsort label-1781
SELECT - 97 DIV + col0 FROM tab0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-1781
SELECT - 97 / + col0 FROM tab0
----
-1
-2
-4

query I rowsort
SELECT - col1 * + 65 FROM tab2 AS cor0
----
-1105
-2015
-3835

onlyif mysql # use DIV operator for integer division
query I rowsort label-1783
SELECT DISTINCT + col1 * - col2 DIV - col2 - col0 AS col2 FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-1783
SELECT DISTINCT + col1 * - col2 / - col2 - col0 AS col2 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1784
SELECT ALL + col1 + + CAST( col0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
137
38
96

skipif mysql # not compatible
query I rowsort label-1784
SELECT ALL + col1 + + CAST ( col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT col2 - col1 * col0 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT col2 * ( col0 ) * cor0.col1 + + col1 AS col0 FROM tab2 AS cor0
----
119711
51051
5890

query I rowsort
SELECT ALL + col0 * - 77 FROM tab1 AS cor0
----
-231
-4928
-6160

query I rowsort
SELECT - - col2 * - 73 + cor0.col0 + cor0.col1 AS col2 FROM tab1 AS cor0
----
-3913
-4087
-6915

query I rowsort
SELECT ALL - col0 * + 18 FROM tab2 cor0
----
-126
-1404
-1422

query I rowsort
SELECT - cor0.col0 + ( 16 ) * col0 FROM tab2 AS cor0
----
105
1170
1185

query I rowsort
SELECT - cor0.col2 * col0 - col0 * + col2 AS col0 FROM tab2 AS cor0
----
-378
-4056
-6004

query I rowsort
SELECT ALL - col0 * - cor0.col2 + col0 + col0 AS col1 FROM tab1 AS cor0
----
168
3776
7840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col1 col0 FROM tab1
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 * col0 col1 FROM tab0
----
13824
42875
704969

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col2 * col1 col2 FROM tab1
----
-16224
-36504
-5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-1796
SELECT - col0 DIV tab0.col2 AS col0 FROM tab0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-1796
SELECT - col0 / tab0.col2 AS col0 FROM tab0
----
-1
-35
0

query I rowsort
SELECT + col0 + + col1 * - col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT - col2 * col0 + col0 * col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT - col1 + cor0.col0 + - cor0.col1 FROM tab2 AS cor0
----
-40
-55
45

query I rowsort
SELECT ALL - col1 * cor0.col2 * col1 AS col2 FROM tab0 AS cor0
----
-244068
-679042
-9409

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT ( col1 ) BETWEEN + col1 AND ( NULL ) OR ( NULL ) >= NULL
----

query I rowsort
SELECT ALL + col0 + tab0.col1 * tab0.col2 AS col1 FROM tab0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-1803
SELECT - + col2 * cor0.col0 DIV - col0 + + col2 * col1 - - col0 * col2 AS col0 FROM tab0 AS cor0
----
133
14842
3663

skipif mysql # not compatible
query I rowsort label-1803
SELECT - + col2 * cor0.col0 / - col0 + + col2 * col1 - - col0 * col2 AS col0 FROM tab0 AS cor0
----
133
14842
3663

onlyif mysql # use DIV operator for integer division
query I rowsort label-1804
SELECT DISTINCT - - col1 DIV + col0 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-1804
SELECT DISTINCT - - col1 / + col0 FROM tab0 AS cor0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 84 * col2 + + col2 * col2 col0 FROM tab1 AS cor0
----
17280
7452
8037

query I rowsort
SELECT ALL + col1 * col1 * col2 + cor0.col0 FROM tab0 AS cor0
----
244092
679131
9444

onlyif mysql # use DIV operator for integer division
query I rowsort label-1807
SELECT + 85 * col0 DIV + col1 FROM tab1 AS cor0
----
523
544
9

skipif mysql # not compatible
query I rowsort label-1807
SELECT + 85 * col0 / + col1 FROM tab1 AS cor0
----
523
544
9

query I rowsort
SELECT col0 + - cor0.col2 * cor0.col1 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT - + 21 AS col2 FROM tab2 AS cor0
----
-21
-21
-21

onlyif mysql # use DIV operator for integer division
query I rowsort label-1810
SELECT + 75 DIV - cor0.col1 col0 FROM tab2 AS cor0
----
-1
-2
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1810
SELECT + 75 / - cor0.col1 col0 FROM tab2 AS cor0
----
-1
-2
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-1811
SELECT col1 + + col1 DIV + col1 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-1811
SELECT col1 + + col1 / + col1 FROM tab0
----
87
92
98

query I rowsort
SELECT - col2 * col0 + + col1 * - col0 + col2 * + col2 FROM tab2 AS cor0
----
-2901
-5954
323

query I rowsort
SELECT + + col0 * - col1 * cor0.col2 - + col1 * col2 FROM tab2 AS cor0
----
-121186
-51680
-6696

onlyif mysql # use DIV operator for integer division
query I rowsort label-1814
SELECT 44 DIV - col1 FROM tab1
----
-1
-3
-4

skipif mysql # not compatible
query I rowsort label-1814
SELECT 44 / - col1 FROM tab1
----
-1
-3
-4

query I rowsort
SELECT ALL + col0 * cor0.col0 - col0 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT ALL + - col0 * - col2 + + 50 * 48 AS col2 FROM tab1 AS cor0
----
10080
2562
6048

query I rowsort
SELECT DISTINCT - ( + col1 ) * ( 0 ) FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col2 - + col0 AS col2 FROM tab0
----
-34
-7
9

query I rowsort
SELECT ALL 82 - 66 FROM tab1
----
16
16
16

query I rowsort
SELECT 22 * - 1 AS col2 FROM tab2
----
-22
-22
-22

onlyif mysql # use DIV operator for integer division
query I rowsort label-1821
SELECT col2 DIV 68 AS col1 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1821
SELECT col2 / 68 AS col1 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1822
SELECT + ( + col1 ) DIV col1 AS col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1822
SELECT + ( + col1 ) / col1 AS col0 FROM tab2
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1823
SELECT DISTINCT tab1.col1 + - col2 DIV - col2 AS col2 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-1823
SELECT DISTINCT tab1.col1 + - col2 / - col2 AS col2 FROM tab1
----
11
14
27

query I rowsort
SELECT ALL + cor0.col0 * + 37 + 44 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 093f34b781581a9eeb578deacb4de4be

query I rowsort
SELECT - col0 * + col0 + - col1 FROM tab2
----
-6143
-6258
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1826
SELECT - col0 DIV cor0.col0 - 74 DIV cor0.col0 FROM tab2 cor0
----
-1
-1
-11

skipif mysql # not compatible
query I rowsort label-1826
SELECT - col0 / cor0.col0 - 74 / cor0.col0 FROM tab2 cor0
----
-1
-1
-11

query I rowsort
SELECT col1 + col1 * ( col2 * + col0 ) FROM tab0 AS cor0
----
3492
664209
68198

query I rowsort
SELECT - - 89 * col0 + + ( + ( + col1 ) ) FROM tab2 cor0
----
654
7001
7048

query I rowsort
SELECT + 7 * col1 AS col1 FROM tab0 AS cor0
----
602
637
679

query I rowsort
SELECT + col0 * col2 * 36 + - col0 FROM tab1 AS cor0
----
131264
276400
5829

query I rowsort
SELECT - col1 * col0 + col2 * ( + col1 ) + - 10 * + cor0.col0 FROM tab2 AS cor0
----
-1487
-3848
550

query I rowsort
SELECT DISTINCT 13 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 11 col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
11

query I rowsort
SELECT DISTINCT - ( - cor0.col2 ) + - ( + 19 ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
19
7
8

query I rowsort
SELECT col0 + - col0 * col1 AS col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT - col0 * 58 AS col1 FROM tab1 AS cor0
----
-174
-3712
-4640

onlyif mysql # use DIV operator for integer division
query I rowsort label-1837
SELECT - ( - tab1.col0 ) + + col0 DIV col2 col2 FROM tab1
----
3
65
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1837
SELECT - ( - tab1.col0 ) + + col0 / col2 col2 FROM tab1
----
3
65
80

query I rowsort
SELECT DISTINCT + ( + 83 ) * col2 AS col1 FROM tab0
----
2739
6806
83

query I rowsort
SELECT + 73 * - ( col2 ) FROM tab1 cor0
----
-3942
-4161
-7008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1840
SELECT + CAST( + col1 AS SIGNED ) * + col1 FROM tab1 AS cor0
----
100
169
676

skipif mysql # not compatible
query I rowsort label-1840
SELECT + CAST ( + col1 AS INTEGER ) * + col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT col0 + - 60 AS col1 FROM tab2 AS cor0
----
-53
18
19

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1842
SELECT DISTINCT - CAST( NULL AS SIGNED ) + + col1 - + col0 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1842
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + + col1 - + col0 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col0 + + 47 FROM tab1 AS cor0
----
111
127
50

query I rowsort
SELECT DISTINCT + 85 * + 49 AS col2 FROM tab1 AS cor0
----
4165

query I rowsort
SELECT + + 68 FROM tab1 cor0
----
68
68
68

query I rowsort
SELECT + cor2.col2 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1847
SELECT DISTINCT + + col0 * - col2 - + cor0.col2 DIV - col0 FROM tab1 AS cor0
----
-144
-3648
-7679

skipif mysql # not compatible
query I rowsort label-1847
SELECT DISTINCT + + col0 * - col2 - + cor0.col2 / - col0 FROM tab1 AS cor0
----
-144
-3648
-7679

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( + col0 AS REAL ) * col1 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + 81 + col2 + cor0.col1 * 49 * + col2 FROM tab0 cor0
----
139176
365801
4835

onlyif mysql # use DIV operator for integer division
query I rowsort label-1850
SELECT ALL - 76 DIV - 13 FROM tab1
----
5
5
5

skipif mysql # not compatible
query I rowsort label-1850
SELECT ALL - 76 / - 13 FROM tab1
----
5
5
5

query I rowsort
SELECT ( + tab0.col0 + - col1 ) FROM tab0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT - + 36 * - 93 FROM tab1 AS cor0
----
3348

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 18 col2 FROM tab2 AS cor0
----
18
18
18

query I rowsort
SELECT + ( - col2 ) * - col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1855
SELECT ALL + - ( + ( + col2 ) ) * CAST( NULL AS DECIMAL ) 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-1855
SELECT ALL + - ( + ( + col2 ) ) * CAST ( NULL AS REAL ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1856
SELECT col0 DIV + col0 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-1856
SELECT col0 / + col0 col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + - ( - 77 ) + + col0 FROM tab2 AS cor0
----
155
156
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * 87 + col1 col1 FROM tab0 AS cor0
----
7568
8008
8536

query I rowsort
SELECT DISTINCT - ( - cor0.col2 ) + col0 AS col2 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT ALL - + col2 * 79 + col1 - + col1 * + col2 AS col2 FROM tab0 AS cor0
----
-13849
-5359
-79

query I rowsort
SELECT ALL + 50 + 51 AS col2 FROM tab0 AS cor0
----
101
101
101

query I rowsort
SELECT ALL + 38 FROM tab0 cor0
----
38
38
38

query I rowsort
SELECT DISTINCT + col0 * + col2 + + ( - col1 ) FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT - + 8 + - col1 + - col2 FROM tab0 cor0
----
-106
-127
-181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1865
SELECT DISTINCT CAST( 36 AS SIGNED ) * + col2 * CAST( + col2 * col0 AS SIGNED ) AS col1 FROM tab2
----
183708
1898208
4106736

skipif mysql # not compatible
query I rowsort label-1865
SELECT DISTINCT CAST ( 36 AS INTEGER ) * + col2 * CAST ( + col2 * col0 AS INTEGER ) AS col1 FROM tab2
----
183708
1898208
4106736

query I rowsort
SELECT DISTINCT col1 + + 70 AS col0 FROM tab2 AS cor0
----
101
129
87

query I rowsort
SELECT DISTINCT - cor1.col2 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + col0 * - 81 * + col2 - - cor0.col2 AS col2 FROM tab0 AS cor0
----
-2834
-591056
-64119

query I rowsort
SELECT ALL + cor0.col1 + col1 AS col0 FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT DISTINCT - col0 + 76 AS col1 FROM tab2 cor0
----
-2
-3
69

query I rowsort
SELECT ALL 23 * 41 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to d77a4f95b251046f93804f864ed01c1e

query I rowsort
SELECT ALL + + ( + col2 ) + + col1 * + col1 AS col1 FROM tab0 AS cor0
----
7429
8363
9410

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1873
SELECT ALL + CAST( - col2 AS SIGNED ) AS col2 FROM tab0 cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-1873
SELECT ALL + CAST ( - col2 AS INTEGER ) AS col2 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT ALL 39 * col2 + + col0 * - col2 * col2 AS col1 FROM tab2 AS cor0
----
-112594
-4050
-51714

query I rowsort
SELECT ALL - - col1 + col1 * + col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT col0 + col1 * - col0 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT - tab0.col0 + - 42 AS col2 FROM tab0
----
-131
-66
-77

query I rowsort
SELECT col2 + tab2.col0 * + col2 AS col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT DISTINCT col2 * 60 AS col2 FROM tab2
----
1560
1620
2280

query I rowsort
SELECT + + col0 + 49 AS col1 FROM tab0 AS cor0
----
138
73
84

query I rowsort
SELECT ALL + + cor0.col1 * - col2 + + col1 + + col0 AS col1 FROM tab1 AS cor0
----
-1155
-1375
-496

query I rowsort
SELECT - col0 * col0 - cor0.col0 AS col2 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT + + cor0.col2 - cor0.col1 FROM tab2 AS cor0
----
-33
-4
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1884
SELECT + + col0 * + ( 84 ) + col1 - + CAST( col2 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
224
5329
6637

skipif mysql # not compatible
query I rowsort label-1884
SELECT + + col0 * + ( 84 ) + col1 - + CAST ( col2 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
224
5329
6637

query I rowsort
SELECT DISTINCT - + col0 + col0 * col2 FROM tab0 AS cor0
----
0
7209
768

onlyif mysql # use DIV operator for integer division
query I rowsort label-1886
SELECT + col0 - + col2 DIV - col1 AS col0 FROM tab1 AS cor0
----
5
69
87

skipif mysql # not compatible
query I rowsort label-1886
SELECT + col0 - + col2 / - col1 AS col0 FROM tab1 AS cor0
----
5
69
87

query I rowsort
SELECT col0 + - 69 AS col2 FROM tab1 AS cor0
----
-5
-66
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-1888
SELECT + - 35 + col1 DIV col0 FROM tab2 AS cor0
----
-31
-35
-35

skipif mysql # not compatible
query I rowsort label-1888
SELECT + - 35 + col1 / col0 FROM tab2 AS cor0
----
-31
-35
-35

query I rowsort
SELECT - cor0.col0 + 24 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1494
-487
-751

query I rowsort
SELECT - 96 FROM tab1, tab1 AS cor0
----
9 values hashing to c89b545346f99713888a7934e4caa539

query I rowsort
SELECT 47 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

query I rowsort
SELECT DISTINCT - - 36 + + col0 + - col0 * col1 AS col2 FROM tab0 cor0
----
-2004
-3324
-7974

query I rowsort
SELECT ALL - col0 * - col2 * - col2 AS col1 FROM tab2 AS cor0
----
-114076
-5103
-52728

query I rowsort
SELECT - ( + col0 ) * + col1 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + 63 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT ALL col1 + + col1 * + col0 AS col2 FROM tab1
----
104
1053
650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1897
SELECT ALL + col1 * + col2 + CAST( NULL AS SIGNED ) * - 84 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1897
SELECT ALL + col1 * + col2 + CAST ( NULL AS INTEGER ) * - 84 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 98 + col1 FROM tab2
----
115
129
157

query I rowsort
SELECT + 6 + tab0.col2 AS col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 29a13f51c602f39128abd2a4152d1cf6

query I rowsort
SELECT + - col1 + col2 - - col2 FROM tab2 AS cor0
----
-7
23
59

query I rowsort
SELECT + col2 * col2 - - cor0.col1 AS col0 FROM tab1 cor0
----
2942
3259
9229

query I rowsort
SELECT ALL + ( col0 ) + + tab1.col0 FROM tab1
----
128
160
6

query I rowsort
SELECT ( col1 ) * - tab1.col1 AS col2 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT - + 83 * col2 * cor0.col1 FROM tab1 cor0
----
-103584
-116532
-47310

query I rowsort
SELECT DISTINCT col0 - - 93 * col2 AS col1 FROM tab1 AS cor0
----
5025
5365
9008

query I rowsort
SELECT DISTINCT col0 - 86 * col1 FROM tab1
----
-1038
-2233
-796

query I rowsort
SELECT DISTINCT 43 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 53 col1 FROM tab1, tab2 AS cor0
----
53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1909
SELECT + CAST( NULL AS SIGNED ) * 26 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1909
SELECT + CAST ( NULL AS INTEGER ) * 26 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - 30 col1 FROM tab2
----
-1140
-780
-810

query I rowsort
SELECT 13 * - 8 + tab2.col2 FROM tab2
----
-66
-77
-78

query I rowsort
SELECT DISTINCT 0 + 46 FROM tab0, tab2, tab1 AS cor0
----
46

query I rowsort
SELECT DISTINCT + ( - tab0.col2 ) * col1 FROM tab0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1914
SELECT + 29 * col2 * + col1 + + CAST( cor0.col2 AS SIGNED ) + - col0 / CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1914
SELECT + 29 * col2 * + col1 + + CAST ( cor0.col2 AS INTEGER ) + - col0 / CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 61 * + ( tab1.col2 ) FROM tab1
----
-3294
-3477
-5856

query I rowsort
SELECT - 10 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

query I rowsort
SELECT col2 * - ( tab0.col0 ) FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + + 39 + col2 * 39 AS col1 FROM tab2 AS cor0
----
1053
1092
1521

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1919
SELECT + - ( - col1 ) * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1919
SELECT + - ( - col1 ) * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 42 + + col0 + col1 AS col1 FROM tab0 AS cor0
----
152
174
222

query I rowsort
SELECT DISTINCT - ( - 27 ) * col0 FROM tab1 AS cor0
----
1728
2160
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1922
SELECT DISTINCT CAST( NULL AS SIGNED ) * - tab1.col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-1922
SELECT DISTINCT CAST ( NULL AS INTEGER ) * - tab1.col2 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col0 * ( - col0 ) col2 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT + - 32 + - col1 AS col2 FROM tab0 AS cor0
----
-118
-123
-129

query I rowsort
SELECT ALL + + col0 * - col1 * + col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1926
SELECT DISTINCT + + col1 * col2 * - cor0.col2 + CAST( NULL AS SIGNED ) * + cor0.col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1926
SELECT DISTINCT + + col1 * col2 * - cor0.col2 + CAST ( NULL AS INTEGER ) * + cor0.col2 FROM tab0 AS cor0
----
NULL

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0, tab1 AS cor1, tab1, tab0 AS cor2 WHERE NOT NULL >= ( NULL )
----

query I rowsort
SELECT col1 * col0 + 24 + + col2 AS col2 FROM tab0 AS cor0
----
2121
3420
8205

query I rowsort
SELECT + col2 + + col2 * 41 + col0 AS col1 FROM tab0 cor0
----
1410
3533
77

query I rowsort
SELECT ALL + - 86 AS col2 FROM tab0 AS cor0
----
-86
-86
-86

query I rowsort
SELECT + col1 * col1 + col1 * col2 + col0 * col0 FROM tab0 cor0
----
10731
10810
23664

query I rowsort
SELECT ( tab2.col1 ) + - col1 * ( - tab2.col2 ) AS col2 FROM tab2
----
1593
663
868

query I rowsort
SELECT - ( - col0 ) - col1 * + col1 AS col1 FROM tab1
----
-36
-673
-89

query I rowsort
SELECT col0 + col0 * - col1 * + ( + col0 * col0 ) FROM tab1
----
-2621376
-6655920
-699

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 56 + - 89 col2 FROM tab2
----
-33
-33
-33

query I rowsort
SELECT + + cor0.col2 + - 47 * - col2 FROM tab1 AS cor0
----
2592
2736
4608

query I rowsort
SELECT DISTINCT - col1 + + cor0.col2 * + 87 FROM tab0 AS cor0
----
-10
2785
7043

onlyif mysql # use DIV operator for integer division
query I rowsort label-1938
SELECT ALL + col2 * col0 + col2 DIV col1 FROM tab1 AS cor0
----
164
3653
7687

skipif mysql # not compatible
query I rowsort label-1938
SELECT ALL + col2 * col0 + col2 / col1 FROM tab1 AS cor0
----
164
3653
7687

query I rowsort
SELECT ALL col0 + - 4 FROM tab0 AS cor0
----
20
31
85

query I rowsort
SELECT - - col1 * 67 + + ( + col2 ) FROM tab0 AS cor0
----
5795
6179
6500

onlyif mysql # use DIV operator for integer division
query I rowsort label-1941
SELECT ALL - - cor0.col1 DIV col1 + + cor0.col2 DIV + col1 FROM tab1 AS cor0
----
3
6
8

skipif mysql # not compatible
query I rowsort label-1941
SELECT ALL - - cor0.col1 / col1 + + cor0.col2 / + col1 FROM tab1 AS cor0
----
3
6
8

query I rowsort
SELECT DISTINCT col2 + - cor0.col0 * - col1 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL - col1 + 92 FROM tab0 cor0
----
-5
1
6

query I rowsort
SELECT - - cor0.col2 + 15 AS col2 FROM tab0 AS cor0
----
16
48
97

query I rowsort
SELECT DISTINCT + col0 * - col0 + + col0 * cor0.col1 FROM tab1 cor0
----
-3456
-5360
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * tab0.col1 col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT col2 + + ( - col2 ) * col2 * tab1.col0 AS col1 FROM tab1
----
-207879
-737184
-8694

query I rowsort
SELECT + col0 + - col0 * col2 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT - - cor0.col2 * - 99 * col1 AS col1 FROM tab2 AS cor0
----
-151866
-63954
-82863

query I rowsort
SELECT + col1 + col2 + + col1 FROM tab1 AS cor0
----
106
122
77

query I rowsort
SELECT + ( + cor0.col1 ) FROM tab0, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT ALL col1 + 95 * col2 FROM tab0
----
192
3221
7881

query I rowsort
SELECT + ( + 98 ) + + col0 AS col2 FROM tab2 AS cor0
----
105
176
177

query I rowsort
SELECT DISTINCT + col1 * + ( col2 ) + col2 AS col1 FROM tab1
----
1344
1458
627

query I rowsort
SELECT ALL - cor0.col1 * - tab0.col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c60831db2936bdb61fb09e86d08b0883

query I rowsort
SELECT col2 + - 70 AS col1 FROM tab2
----
-32
-43
-44

query I rowsort
SELECT + ( col1 + + col1 ) AS col2 FROM tab0
----
172
182
194

onlyif mysql # use DIV operator for integer division
query I rowsort label-1958
SELECT ALL + col0 + + ( col2 ) DIV ( col0 ) AS col0 FROM tab0 AS cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-1958
SELECT ALL + col0 + + ( col2 ) / ( col0 ) AS col0 FROM tab0 AS cor0
----
25
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1959
SELECT - ( + col1 ) * - col1 + + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1959
SELECT - ( + col1 ) * - col1 + + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( 94 ) * col1 FROM tab0 cor0
----
-8084
-8554
-9118

onlyif mysql # use DIV operator for integer division
query I rowsort label-1961
SELECT DISTINCT - + col1 DIV col1 + col1 AS col0 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-1961
SELECT DISTINCT - + col1 / col1 + col1 AS col0 FROM tab1 AS cor0
----
12
25
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 74 + - col1 col1 FROM tab0 AS cor0
----
-12
-17
-23

query I rowsort
SELECT ALL - 92 + col1 AS col2 FROM tab2 AS cor0
----
-33
-61
-75

query I rowsort
SELECT ALL + col2 * 81 + - col1 * cor0.col2 FROM tab1 AS cor0
----
2970
4047
6528

query I rowsort
SELECT + cor0.col0 * - 21 AS col2 FROM tab0 cor0
----
-1869
-504
-735

query I rowsort
SELECT DISTINCT - + col2 * - 72 FROM tab2 cor0
----
1872
1944
2736

query I rowsort
SELECT DISTINCT - - col0 * col1 - col1 AS col1 FROM tab0 AS cor0
----
1978
3298
8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1968
SELECT + - CAST( NULL AS DECIMAL ) * + col1 * col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1968
SELECT + - CAST ( NULL AS REAL ) * + col1 * col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col1 + col1 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL - col2 * - 32 + col1 * col2 AS col2 FROM tab1 AS cor0
----
2394
3132
4320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1971
SELECT ALL - CAST( NULL AS SIGNED ) * col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1971
SELECT ALL - CAST ( NULL AS INTEGER ) * col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col2 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL - col2 + - col2 * 53 * + col1 AS col0 FROM tab0 AS cor0
----
-150447
-395568
-5142

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1974
SELECT ALL - col2 + - col1 * CAST( col0 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

skipif mysql # not compatible
query I rowsort label-1974
SELECT ALL - col2 + - col1 * CAST ( col0 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT - - cor0.col2 - - col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT - 67 * col2 + - col2 + col1 * col1 FROM tab0 AS cor0
----
2705
5152
9341

query I rowsort
SELECT DISTINCT - col1 + col0 * + tab0.col2 FROM tab0
----
-62
706
7207

query I rowsort
SELECT - cor0.col0 + col2 + - 65 AS col2 FROM tab2 AS cor0
----
-106
-117
-45

query I rowsort
SELECT DISTINCT col1 * + col2 + 9 AS col1 FROM tab0 AS cor0
----
106
2847
7471

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1980
SELECT ALL - + 74 * col2 + CAST( - col2 AS SIGNED ) * + col0 AS col2 FROM tab2 cor0
----
-2187
-3952
-5814

skipif mysql # not compatible
query I rowsort label-1980
SELECT ALL - + 74 * col2 + CAST ( - col2 AS INTEGER ) * + col0 AS col2 FROM tab2 cor0
----
-2187
-3952
-5814

query I rowsort
SELECT ALL + cor0.col0 * 88 AS col0 FROM tab2 cor0
----
616
6864
6952

query I rowsort
SELECT DISTINCT + col2 * - col2 + - 30 AS col2 FROM tab0 AS cor0
----
-1119
-31
-6754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 * + col0 col2 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-1984
SELECT ALL - col1 DIV 5 AS col1 FROM tab2 cor0
----
-11
-3
-6

skipif mysql # not compatible
query I rowsort label-1984
SELECT ALL - col1 / 5 AS col1 FROM tab2 cor0
----
-11
-3
-6

query I rowsort
SELECT - col1 + 56 + - cor0.col1 * - col0 AS col0 FROM tab1 AS cor0
----
108
1083
686

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab1.col1 col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT DISTINCT + + col0 - + 13 AS col1 FROM tab1 AS cor0
----
-10
51
67

query I rowsort
SELECT ALL + + col1 + col0 - - col0 * + col1 * cor0.col2 FROM tab0 cor0
----
3527
664298
68222

query I rowsort
SELECT - tab2.col1 - col1 * + tab2.col1 FROM tab2
----
-306
-3540
-992

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1990
SELECT DISTINCT + col1 + CAST( - cor0.col0 AS SIGNED ) FROM tab2 AS cor0
----
-19
-62
24

skipif mysql # not compatible
query I rowsort label-1990
SELECT DISTINCT + col1 + CAST ( - cor0.col0 AS INTEGER ) FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + col1 + 69 + col2 FROM tab2 AS cor0
----
124
127
154

onlyif mysql # use DIV operator for integer division
query I rowsort label-1992
SELECT + col1 DIV + ( col1 ) AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1992
SELECT + col1 / + ( col1 ) AS col2 FROM tab1
----
1
1
1

query I rowsort
SELECT DISTINCT 70 * col0 + + col1 FROM tab1
----
236
4490
5613

query I rowsort
SELECT 6 + - 87 * + col1 FROM tab0 cor0
----
-7476
-7911
-8433

query I rowsort
SELECT DISTINCT - col1 + + 85 * cor0.col1 FROM tab2 cor0
----
1428
2604
4956

query I rowsort
SELECT - - col0 + + col1 * - cor0.col1 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT DISTINCT - 62 * col2 + col0 AS col1 FROM tab1 cor0
----
-3345
-3470
-5872

query I rowsort
SELECT 33 * col1 FROM tab2 AS cor0
----
1023
1947
561

query I rowsort
SELECT ALL - col1 * - col2 + col0 * + col0 AS col1 FROM tab1 AS cor0
----
1413
4666
7648

query I rowsort
SELECT 55 * col2 - - 13 * - col1 AS col2 FROM tab2 AS cor0
----
1082
1869
663

query I rowsort
SELECT ALL 3 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT - col2 * col0 + - cor0.col0 AS col1 FROM tab0 cor0
----
-70
-7387
-816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 13 * cor0.col2 col2 FROM tab0 AS cor0
----
1066
13
429

query I rowsort
SELECT - + col2 * - col0 - + col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT 53 * cor0.col2 FROM tab2 AS cor0
----
1378
1431
2014

onlyif mysql # use DIV operator for integer division
query I rowsort label-2006
SELECT + col1 DIV ( + col2 * + col1 ) AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2006
SELECT + col1 / ( + col2 * + col1 ) AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT col0 * cor0.col0 * - col2 + + col1 * - 91 FROM tab0 AS cor0
----
-10052
-26834
-657803

query I rowsort
SELECT DISTINCT - cor0.col2 + ( - 25 ) FROM tab1 AS cor0
----
-121
-79
-82

query I rowsort
SELECT ALL tab0.col2 * - tab0.col2 * - col0 AS col1 FROM tab0
----
26136
35
598436

query I rowsort
SELECT - - cor0.col2 * col0 AS col0 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT + col2 + 7 * + col2 AS col1 FROM tab0 AS cor0
----
264
656
8

query I rowsort
SELECT + + 19 AS col2 FROM tab1 AS cor0
----
19
19
19

skipif mysql # not compatible
query I rowsort
SELECT + col2 * - CAST ( 67 AS REAL ) + - col0 * col2 * 80 AS col2 FROM tab1
----
-16578
-295659
-620832

query I rowsort
SELECT + tab0.col1 AS col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT 37 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c023509f63faa044d654943e6df55ca2

query IIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 AS cor0 WHERE NOT NULL <= ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 * - 89 + col0 col1 FROM tab0 AS cor0
----
2160
3150
8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2018
SELECT ALL CAST( + col1 * col0 AS SIGNED ) FROM tab0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-2018
SELECT ALL CAST ( + col1 * col0 AS INTEGER ) FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col2 * + col1 + + cor0.col0 * col1 FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT ALL + 82 * - col0 * col0 AS col1 FROM tab0 cor0
----
-100450
-47232
-649522

query I rowsort
SELECT ALL 54 * + col2 FROM tab1 AS cor0
----
2916
3078
5184

onlyif mysql # use DIV operator for integer division
query I rowsort label-2022
SELECT + - col2 DIV + col1 col0 FROM tab1 AS cor0
----
-2
-5
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2022
SELECT + - col2 / + col1 col0 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT - tab2.col0 FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT ALL ( col0 * + col2 ) AS col0 FROM tab1
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2025
SELECT + ( 74 ) DIV col2 - - col1 * - tab0.col0 AS col0 FROM tab0
----
-2062
-3321
-8099

skipif mysql # not compatible
query I rowsort label-2025
SELECT + ( 74 ) / col2 - - col1 * - tab0.col0 AS col0 FROM tab0
----
-2062
-3321
-8099

query I rowsort
SELECT + ( - ( col1 ) * - 11 ) FROM tab0
----
1001
1067
946

query I rowsort
SELECT ALL ( - col2 * + tab1.col0 ) AS col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT - col1 + - 82 * col1 AS col0 FROM tab2 AS cor0
----
-1411
-2573
-4897

query I rowsort
SELECT DISTINCT - 85 * + cor0.col1 FROM tab0, tab1, tab2 AS cor0
----
-1445
-2635
-5015

onlyif mysql # use DIV operator for integer division
query I rowsort label-2030
SELECT + col1 * + 71 + - col0 DIV - col1 FROM tab2 AS cor0
----
1211
2201
4190

skipif mysql # not compatible
query I rowsort label-2030
SELECT + col1 * + 71 + - col0 / - col1 FROM tab2 AS cor0
----
1211
2201
4190

query I rowsort
SELECT + col1 + + col2 * - 21 FROM tab1 AS cor0
----
-1108
-1187
-2003

query I rowsort
SELECT - col2 * - col2 * + ( + 76 ) FROM tab2
----
109744
51376
55404

query I rowsort
SELECT DISTINCT - 73 AS col2 FROM tab1
----
-73

query I rowsort
SELECT tab2.col2 * + tab2.col1 AS col2 FROM tab2
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-2035
SELECT ALL + 37 DIV 14 AS col2 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

skipif mysql # not compatible
query I rowsort label-2035
SELECT ALL + 37 / 14 AS col2 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * - col2 col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - + col0 + - col2 AS col1 FROM tab2 cor0
----
-104
-117
-34

query I rowsort
SELECT - col1 * - col2 + - col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT cor0.col1 * col1 + cor0.col2 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT + cor0.col2 + - col0 * - col1 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT + col2 * 50 AS col2 FROM tab0 AS cor0
----
1650
4100
50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2042
SELECT DISTINCT tab2.col2 * col0 * CAST( + 22 AS SIGNED ) AS col2 FROM tab2
----
4158
44616
66044

skipif mysql # not compatible
query I rowsort label-2042
SELECT DISTINCT tab2.col2 * col0 * CAST ( + 22 AS INTEGER ) AS col2 FROM tab2
----
4158
44616
66044

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2043
SELECT - col2 * + col2 + CAST( NULL AS SIGNED ) * col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2043
SELECT - col2 * + col2 + CAST ( NULL AS INTEGER ) * col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT tab1.col2 + + col1 AS col0 FROM tab1
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2045
SELECT 99 - col1 / + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2045
SELECT 99 - col1 / + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + 4 FROM tab0 AS cor0
----
-4
-4
-4

query I rowsort
SELECT 59 FROM tab0, tab1 cor0, tab0 AS cor1
----
27 values hashing to e29fef8cdec1ee45a71d213f16d2f1d3

query I rowsort
SELECT + ( cor0.col0 ) * + col1 * + col1 AS col2 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT ALL - cor0.col0 * + ( + 21 ) AS col2 FROM tab1 AS cor0
----
-1344
-1680
-63

query I rowsort
SELECT + cor0.col1 * col1 * 43 FROM tab2 AS cor0
----
12427
149683
41323

query I rowsort
SELECT DISTINCT cor0.col2 * ( col1 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + + cor0.col0 + col1 * + 65 AS col2 FROM tab1 AS cor0
----
1693
714
925

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 * 42 col2 FROM tab1 AS cor0
----
2268
2394
4032

onlyif mysql # use DIV operator for integer division
query I rowsort label-2054
SELECT DISTINCT - col0 + + col1 DIV + col1 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-2054
SELECT DISTINCT - col0 + + col1 / + col1 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT ALL 13 AS col0 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT + + col1 + ( + col0 ) * + cor0.col0 AS col2 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT + + col1 * + 77 FROM tab1 AS cor0
----
1001
2002
770

query I rowsort
SELECT ALL col1 + ( - col0 ) + col1 FROM tab1 AS cor0
----
-44
-54
49

query I rowsort
SELECT DISTINCT col1 + + col1 * + 66 AS col2 FROM tab1 AS cor0
----
1742
670
871

query I rowsort
SELECT - + 14 * col0 + - col2 FROM tab1 AS cor0
----
-1216
-953
-96

query I rowsort
SELECT 49 * + col2 * + col0 + 23 * - 24 - col1 FROM tab2 AS cor0
----
146529
8678
98761

query I rowsort
SELECT DISTINCT + + col0 + 81 * - col2 * + col1 AS col1 FROM tab2 cor0
----
-124176
-52247
-67790

query I rowsort
SELECT ALL - - col0 + - col1 * - col1 AS col0 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT + 86 + - col1 FROM tab0 AS cor0
----
-11
-5
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2065
SELECT col0 * + ( + col2 ) DIV - col2 AS col2 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-2065
SELECT col0 * + ( + col2 ) / - col2 AS col2 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT - + 6 + col2 FROM tab0 AS cor0
----
-5
27
76

query I rowsort
SELECT ALL + 67 * col2 + col1 AS col2 FROM tab1 AS cor0
----
3644
3829
6445

query I rowsort
SELECT ALL + col2 + cor0.col2 AS col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL - - 14 * cor0.col1 FROM tab1 AS cor0
----
140
182
364

query I rowsort
SELECT + + col1 + col1 * - ( 82 ) AS col0 FROM tab1 AS cor0
----
-1053
-2106
-810

query I rowsort
SELECT 85 FROM tab1, tab2 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 5e8deeabad7bbbaf313fcdcb4adc75eb

query I rowsort
SELECT - ( 26 ) - col1 FROM tab1
----
-36
-39
-52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2073
SELECT DISTINCT - ( col2 ) * - CAST( col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-2073
SELECT DISTINCT - ( col2 ) * - CAST ( col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT + col2 + + col1 * - ( col1 * + col0 ) AS col0 FROM tab2 AS cor0
----
-22793
-271492
-6700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 + cor0.col1 col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT - col0 * + col0 - col1 * + col1 FROM tab1 AS cor0
----
-4196
-6569
-685

query I rowsort
SELECT + 8 + col0 FROM tab0 AS cor0
----
32
43
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2078
SELECT ALL + ( - col1 ) DIV col0 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-2078
SELECT ALL + ( - col1 ) / col0 FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT DISTINCT - col2 + + cor0.col0 * + col2 AS col2 FROM tab2 cor0
----
162
2002
2964

query I rowsort
SELECT cor0.col2 + - col0 AS col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT col1 + + col0 + - ( - col0 ) AS col1 FROM tab2 AS cor0
----
175
215
45

query I rowsort
SELECT ALL - 21 + cor0.col2 * 13 AS col0 FROM tab1 AS cor0
----
1227
681
720

query I rowsort
SELECT ALL - col0 * col2 * 49 FROM tab0 cor0
----
-1715
-357602
-38808

query I rowsort
SELECT ALL + col2 + col1 * 85 AS col2 FROM tab0 AS cor0
----
7343
7817
8246

query I rowsort
SELECT ALL + tab0.col2 * col1 + + col0 FROM tab0
----
132
2862
7551

query I rowsort
SELECT ALL + 79 + - tab1.col0 * - col1 FROM tab1
----
1119
157
719

query I rowsort
SELECT ALL col2 * - 45 + col1 * + col0 FROM tab2
----
-367
-998
3432

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2088
SELECT + col2 + - col0 * + CAST( NULL AS SIGNED ) col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2088
SELECT + col2 + - col0 * + CAST ( NULL AS INTEGER ) col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * tab1.col0 + + col2 AS col1 FROM tab1
----
4153
63
6496

onlyif mysql # use DIV operator for integer division
query I rowsort label-2090
SELECT - 73 DIV - 65 AS col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2090
SELECT - 73 / - 65 AS col0 FROM tab0
----
1
1
1

query I rowsort
SELECT - - ( 5 ) FROM tab2 cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 6035628694bdea36f584f3649088551d

query I rowsort
SELECT col1 * + col2 + - 6 FROM tab2
----
1528
640
831

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2093
SELECT 68 + col2 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2093
SELECT 68 + col2 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col1 * col0 + - 14 AS col2 FROM tab2 AS cor0
----
1329
203
4588

query I rowsort
SELECT 81 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT ALL ( 39 ) + - col0 * + col1 FROM tab0 cor0
----
-2025
-3356
-8060

query I rowsort
SELECT - 33 * 38 * col1 AS col2 FROM tab0 AS cor0
----
-107844
-114114
-121638

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2098
SELECT ALL - CAST( NULL AS SIGNED ) * - ( + col0 ) + ( col0 * + cor0.col1 ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2098
SELECT ALL - CAST ( NULL AS INTEGER ) * - ( + col0 ) + ( col0 * + cor0.col1 ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2099
SELECT col1 DIV 59 - col0 AS col2 FROM tab0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-2099
SELECT col1 / 59 - col0 AS col2 FROM tab0
----
-23
-34
-88

query I rowsort
SELECT ( 36 * - col1 ) AS col1 FROM tab0
----
-3096
-3276
-3492

query I rowsort
SELECT DISTINCT + - 89 * + col0 + col1 AS col1 FROM tab0 AS cor0
----
-2050
-3018
-7830

query I rowsort
SELECT ALL - ( - 65 ) * - col0 FROM tab0 AS cor0
----
-1560
-2275
-5785

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 - col0 col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + 92 * - col1 + + col2 AS col0 FROM tab0 cor0
----
-7879
-8290
-8923

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2105
SELECT ALL CAST( NULL AS SIGNED ) + + ( col2 ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2105
SELECT ALL CAST ( NULL AS INTEGER ) + + ( col2 ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2106
SELECT cor0.col2 + + col0 DIV col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2106
SELECT cor0.col2 + + col0 / col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT 47 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1, tab0 cor2
----
81 values hashing to 5c7a6f591fb2a38893dafe56c4b9b97f

query I rowsort
SELECT ALL 16 * + col2 AS col1 FROM tab1
----
1536
864
912

query I rowsort
SELECT + 83 AS col0 FROM tab1
----
83
83
83

query I rowsort
SELECT ALL + + cor0.col1 FROM tab0, tab1, tab0 cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 91 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

onlyif mysql # use DIV operator for integer division
query I rowsort label-2112
SELECT DISTINCT col2 DIV tab0.col2 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-2112
SELECT DISTINCT col2 / tab0.col2 FROM tab0
----
1

query I rowsort
SELECT - col0 * + col1 * col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT - 51 + col0 AS col0 FROM tab1
----
-48
13
29

query I rowsort
SELECT 96 + col1 FROM tab1
----
106
109
122

query I rowsort
SELECT DISTINCT + col1 * - col1 + - tab2.col2 AS col1 FROM tab2
----
-327
-3507
-988

query I rowsort
SELECT DISTINCT - ( - ( col1 ) ) FROM tab2 AS cor0
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-2118
SELECT + - cor0.col0 * 70 + + col0 DIV - col0 AS col1 FROM tab0 AS cor0
----
-1681
-2451
-6231

skipif mysql # not compatible
query I rowsort label-2118
SELECT + - cor0.col0 * 70 + + col0 / - col0 AS col1 FROM tab0 AS cor0
----
-1681
-2451
-6231

query I rowsort
SELECT ALL - - 41 + col2 * + cor0.col2 FROM tab2 cor0
----
1485
717
770

onlyif mysql # use DIV operator for integer division
query I rowsort label-2120
SELECT ALL - col0 * col2 + + col1 DIV + col2 - - col1 DIV col1 AS col0 FROM tab0 AS cor0
----
-7296
-789
63

skipif mysql # not compatible
query I rowsort label-2120
SELECT ALL - col0 * col2 + + col1 / + col2 - - col1 / col1 AS col0 FROM tab0 AS cor0
----
-7296
-789
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 95 + - cor0.col0 col1 FROM tab2, tab0, tab1 AS cor0
----
15
31
92

query I rowsort
SELECT + + 51 AS col1 FROM tab0 AS cor0
----
51
51
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 2 col0 FROM tab2 cor0
----
2
2
2

query I rowsort
SELECT - col0 + + col0 * - col0 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT - 19 + col1 + + col0 AS col1 FROM tab2
----
118
19
77

query I rowsort
SELECT ALL 77 + + col2 + col2 AS col1 FROM tab0
----
143
241
79

query I rowsort
SELECT - col2 * - col2 + - cor0.col2 AS col2 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT 34 + col1 + col2 * - col1 AS col0 FROM tab0 AS cor0
----
-2718
-7337
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2129
SELECT + 61 + col1 DIV col0 AS col0 FROM tab1 cor0
----
61
61
69

skipif mysql # not compatible
query I rowsort label-2129
SELECT + 61 + col1 / col0 AS col0 FROM tab1 cor0
----
61
61
69

query I rowsort
SELECT - col2 * col1 + + cor0.col2 * + col2 * + cor0.col0 + col2 * col1 FROM tab0 AS cor0
----
26136
35
598436

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * - col1 col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - col1 * - col2 + + cor0.col0 * col0 FROM tab0 AS cor0
----
1322
15383
3414

query III rowsort
SELECT * FROM tab2 WHERE NOT ( NULL NOT IN ( - tab2.col2 * - col2 ) ) AND NOT ( NULL ) = ( col0 )
----

query I rowsort
SELECT DISTINCT + + col2 * - cor0.col1 * + col0 AS col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-2135
SELECT ALL col2 DIV + col2 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2135
SELECT ALL col2 / + col2 AS col2 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2136
SELECT + - CAST( NULL AS DECIMAL ) + ( col0 ) * cor0.col0 - + col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2136
SELECT + - CAST ( NULL AS REAL ) + ( col0 ) * cor0.col0 - + col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2137
SELECT - CAST( NULL AS SIGNED ) * + 33 + - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2137
SELECT - CAST ( NULL AS INTEGER ) * + 33 + - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( + col1 AS REAL ) + + col2 + col0 * + col2 AS col1 FROM tab2 AS cor0
----
185
1995
3023

query I rowsort
SELECT DISTINCT 97 - col0 * tab0.col1 * + col0 FROM tab0
----
-118728
-49439
-720714

query I rowsort
SELECT DISTINCT ( - 85 ) * col1 * + col0 - col0 AS col0 FROM tab0
----
-175464
-288610
-688504

query I rowsort
SELECT ALL 77 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

onlyif mysql # use DIV operator for integer division
query I rowsort label-2142
SELECT - col1 * - col2 + col1 DIV - col0 - col2 DIV col0 AS col0 FROM tab2
----
1534
646
830

skipif mysql # not compatible
query I rowsort label-2142
SELECT - col1 * - col2 + col1 / - col0 - col2 / col0 AS col0 FROM tab2
----
1534
646
830

query I rowsort
SELECT col0 * - col0 + col2 + col1 * col2 FROM tab2 AS cor0
----
-4524
-5557
815

query I rowsort
SELECT DISTINCT - cor0.col1 * - col0 + col0 AS col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL ( ( + col0 ) ) AS col2 FROM tab1 AS cor0
----
3
64
80

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab2 cor1, tab0 cor2
----
972 values hashing to 63ccb67e72ebac679a0221202c067b9e

query I rowsort
SELECT ( col0 ) + col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT - col1 * - col1 + - col0 * col2 * + col1 FROM tab1 AS cor0
----
-3536
-36380
-99671

query I rowsort
SELECT DISTINCT - col1 * + 5 FROM tab0
----
-430
-455
-485

query I rowsort
SELECT cor0.col0 * + col0 + cor0.col0 * col2 AS col2 FROM tab2 AS cor0
----
238
8112
9243

onlyif mysql # use DIV operator for integer division
query I rowsort label-2151
SELECT + 73 + cor0.col1 DIV - cor0.col0 - cor0.col1 * + cor0.col0 FROM tab2 AS cor0
----
-1270
-148
-4529

skipif mysql # not compatible
query I rowsort label-2151
SELECT + 73 + cor0.col1 / - cor0.col0 - cor0.col1 * + cor0.col0 FROM tab2 AS cor0
----
-1270
-148
-4529

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col1 ) * col0 col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT - tab2.col2 * - col1 * + col1 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT ( + col0 ) * col1 AS col2 FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT ( col1 ) * col1 AS col2 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT + 86 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2157
SELECT ALL CAST( NULL AS SIGNED ) * - col0 + col2 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2157
SELECT ALL CAST ( NULL AS INTEGER ) * - col0 + col2 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2158
SELECT DISTINCT - - CAST( NULL AS DECIMAL ) AS col0 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2158
SELECT DISTINCT - - CAST ( NULL AS REAL ) AS col0 FROM tab1 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2159
SELECT + CAST( col2 AS SIGNED ) * + col2 AS col1 FROM tab1 AS cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-2159
SELECT + CAST ( col2 AS INTEGER ) * + col2 AS col1 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL col2 + + ( - cor0.col0 ) FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT + tab1.col2 * + ( 20 ) - - col0 FROM tab1
----
1083
1204
2000

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2162
SELECT ALL CAST( NULL AS SIGNED ) + + cor0.col2 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2162
SELECT ALL CAST ( NULL AS INTEGER ) + + cor0.col2 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + col2 * ( - col1 ) AS col0 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT col0 + 33 FROM tab1
----
113
36
97

query I rowsort
SELECT DISTINCT 40 FROM tab1, tab0 AS cor0
----
40

query I rowsort
SELECT col0 - + 98 FROM tab0
----
-63
-74
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2167
SELECT ALL - ( col1 ) + col2 / CAST( NULL AS SIGNED ) + col0 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2167
SELECT ALL - ( col1 ) + col2 / CAST ( NULL AS INTEGER ) + col0 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 54 AS col1 FROM tab0
----
-54

query I rowsort
SELECT ALL - - col0 * 53 - + col2 FROM tab1 AS cor0
----
105
3335
4144

query I rowsort
SELECT - - 79 + col1 FROM tab1 AS cor0
----
105
89
92

query I rowsort
SELECT cor0.col1 * - col1 + col2 * + col1 * col1 FROM tab1 AS cor0
----
16055
35828
5600

query I rowsort
SELECT DISTINCT + ( col0 ) + - col2 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT ALL - + col0 - - 24 AS col1 FROM tab0 AS cor0
----
-11
-65
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2174
SELECT 90 + col1 DIV ( 47 ) AS col1 FROM tab0
----
91
91
92

skipif mysql # not compatible
query I rowsort label-2174
SELECT 90 + col1 / ( 47 ) AS col1 FROM tab0
----
91
91
92

query I rowsort
SELECT 61 - + col0 FROM tab1
----
-19
-3
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2176
SELECT col0 + - CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
-16
-51
7

skipif mysql # not compatible
query I rowsort label-2176
SELECT col0 + - CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2177
SELECT DISTINCT + col1 DIV 94 - - cor0.col1 DIV col2 AS col1 FROM tab1 cor0
----
0

skipif mysql # not compatible
query I rowsort label-2177
SELECT DISTINCT + col1 / 94 - - cor0.col1 / col2 AS col1 FROM tab1 cor0
----
0

query I rowsort
SELECT + + col0 - col2 * 11 * col0 AS col0 FROM tab0 AS cor0
----
-350
-80189
-8688

query I rowsort
SELECT ALL - col1 * + col2 + col1 + col2 AS col1 FROM tab2 cor0
----
-1449
-591
-779

query I rowsort
SELECT ALL col1 * + 51 FROM tab0 AS cor0
----
4386
4641
4947

query I rowsort
SELECT DISTINCT - col0 * + cor0.col2 - cor0.col1 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT DISTINCT - cor0.col0 * ( - col1 ) FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT col0 + + col1 + + 4 AS col1 FROM tab0 AS cor0
----
114
136
184

query I rowsort
SELECT 4 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

query I rowsort
SELECT ALL + - col2 * ( + 93 + cor0.col0 ) FROM tab2 cor0
----
-2700
-4446
-6536

query I rowsort
SELECT - cor0.col0 + ( 58 ) * col1 + - col1 * 68 FROM tab1 AS cor0
----
-164
-210
-263

query I rowsort
SELECT ALL cor0.col1 * + ( ( + col2 ) ) AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + + col2 + + col0 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL col1 + - tab0.col0 * col0 + - col1 * col1 FROM tab0
----
-10537
-16111
-7886

query I rowsort
SELECT ALL col0 * + 8 + 17 + - col2 AS col0 FROM tab2
----
46
611
615

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + - col0 * col0 col1 FROM tab0
----
-1322
-662
-8012

query I rowsort
SELECT col2 * + col0 * tab2.col2 FROM tab2
----
114076
5103
52728

query I rowsort
SELECT DISTINCT - 25 + 26 AS col1 FROM tab2, tab2 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col1 + col2 * col1 col0 FROM tab0 AS cor0
----
15561
3492
4902

query I rowsort
SELECT DISTINCT - col2 * + col0 + - col2 AS col1 FROM tab2 AS cor0
----
-2054
-216
-3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-2196
SELECT ALL - col1 + col0 DIV col1 AS col2 FROM tab2 AS cor0
----
-13
-31
-58

skipif mysql # not compatible
query I rowsort label-2196
SELECT ALL - col1 + col0 / col1 AS col2 FROM tab2 AS cor0
----
-13
-31
-58

query I rowsort
SELECT - + col2 * ( col2 ) FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT + - ( col2 ) + + col0 AS col2 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2199
SELECT CAST( + 18 AS SIGNED ) + col1 * cor0.col0 AS col1 FROM tab0 AS cor0
----
2082
3413
8117

skipif mysql # not compatible
query I rowsort label-2199
SELECT CAST ( + 18 AS INTEGER ) + col1 * cor0.col0 AS col1 FROM tab0 AS cor0
----
2082
3413
8117

query I rowsort
SELECT col0 - ( - col1 ) FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( - ( col2 ) ) - - col2 col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL + + col1 * col2 - - col0 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT cor0.col2 - - col2 * cor0.col2 FROM tab1 AS cor0
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-2204
SELECT DISTINCT + col2 DIV - col1 + - col2 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-2204
SELECT DISTINCT + col2 / - col1 + - col2 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT col0 + - col2 * col0 + + cor0.col1 AS col1 FROM tab2 AS cor0
----
-151
-1891
-2906

query I rowsort
SELECT ALL 59 * - cor0.col0 AS col1 FROM tab2 cor0
----
-413
-4602
-4661

query I rowsort
SELECT ALL + 26 FROM tab2, tab2 cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

onlyif mysql # use DIV operator for integer division
query I rowsort label-2208
SELECT - - col0 DIV cor0.col0 - col2 AS col2 FROM tab2 AS cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-2208
SELECT - - col0 / cor0.col0 - col2 AS col2 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT DISTINCT col2 * - col2 + col1 + - col1 * - col2 FROM tab0
----
1835
193
829

onlyif mysql # use DIV operator for integer division
query I rowsort label-2210
SELECT ALL - col0 + col1 DIV col0 + col1 AS col2 FROM tab0
----
3
64
65

skipif mysql # not compatible
query I rowsort label-2210
SELECT ALL - col0 + col1 / col0 + col1 AS col2 FROM tab0
----
3
64
65

query I rowsort
SELECT ALL col0 + 42 * col0 AS col0 FROM tab1
----
129
2752
3440

query I rowsort
SELECT DISTINCT + 86 AS col1 FROM tab1 cor0
----
86

query I rowsort
SELECT ALL + - col1 * col0 + 94 AS col2 FROM tab2 AS cor0
----
-123
-1249
-4508

query I rowsort
SELECT col0 * - cor0.col0 + 97 FROM tab2 cor0
----
-5987
-6144
48

query I rowsort
SELECT DISTINCT col1 + + col1 * + 49 FROM tab2 cor0
----
1550
2950
850

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * + col0 col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + 57 + col1 * - col1 FROM tab1 cor0
----
-112
-43
-619

query I rowsort
SELECT ALL - col1 + col0 * 64 AS col0 FROM tab1 AS cor0
----
166
4086
5107

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col0 col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT 64 + col1 FROM tab1 cor0
----
74
77
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + col1 col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL + - col2 + - cor0.col0 * - col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT + col0 + - col1 * - 72 FROM tab2 AS cor0
----
1303
2239
4326

query I rowsort
SELECT ( + col2 ) * + 91 FROM tab0 AS cor0
----
3003
7462
91

query I rowsort
SELECT - 25 * + col1 + - col2 * - col0 * + col0 AS col0 FROM tab1
----
-164
233222
614075

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 22 col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2227
SELECT - - 47 DIV col0 + + ( - col2 ) FROM tab2 AS cor0
----
-21
-26
-38

skipif mysql # not compatible
query I rowsort label-2227
SELECT - - 47 / col0 + + ( - col2 ) FROM tab2 AS cor0
----
-21
-26
-38

query I rowsort
SELECT DISTINCT - - cor1.col0 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
24
35
89

query I rowsort
SELECT DISTINCT - - col1 + - col2 AS col2 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT ALL - col1 * + col1 + + 32 AS col1 FROM tab0 AS cor0
----
-7364
-8249
-9377

query I rowsort
SELECT DISTINCT + 26 + col0 * - 12 AS col1 FROM tab2 AS cor0
----
-58
-910
-922

query I rowsort
SELECT + 50 FROM tab1, tab0 AS cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT 96 * + col2 + col1 FROM tab1 AS cor0
----
5210
5482
9229

query I rowsort
SELECT + 15 * + col2 FROM tab1
----
1440
810
855

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col2 FROM tab1 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2, tab0 AS cor3
----
243 values hashing to 63f734facb33901524f6f2c799118db4

query I rowsort
SELECT ( cor0.col2 ) * - 95 FROM tab1, tab2 AS cor0
----
9 values hashing to 381c83e2a0077d0955cd3283ddc85954

query I rowsort
SELECT ( + ( col1 ) ) FROM tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 48 - - col2 col1 FROM tab1 AS cor0
----
102
105
144

query I rowsort
SELECT + 85 + 18 + + tab0.col1 AS col1 FROM tab0
----
189
194
200

query I rowsort
SELECT ( 51 ) FROM tab2
----
51
51
51

query I rowsort
SELECT col0 * + 35 FROM tab1
----
105
2240
2800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 39 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 * - col2 ) col1 FROM tab1
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2244
SELECT ALL + - CAST( NULL AS SIGNED ) / + 85 - 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-2244
SELECT ALL + - CAST ( NULL AS INTEGER ) / + 85 - col2 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 * 81 - col0 AS col1 FROM tab0 AS cor0
----
6942
7282
7822

query I rowsort
SELECT - 33 * - ( col0 ) AS col2 FROM tab1
----
2112
2640
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-2247
SELECT ALL col1 * col0 DIV + col1 - - 38 FROM tab1 cor0
----
102
118
41

skipif mysql # not compatible
query I rowsort label-2247
SELECT ALL col1 * col0 / + col1 - - 38 FROM tab1 cor0
----
102
118
41

query I rowsort
SELECT - ( col2 ) + + col0 AS col2 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT ALL + ( col1 ) * + 90 - + col2 * + col1 * - ( - 10 * - col0 ) AS col1 FROM tab2 AS cor0
----
1201830
511870
61380

query I rowsort
SELECT ALL 69 * + col1 FROM tab2 AS cor0
----
1173
2139
4071

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2251
SELECT DISTINCT col1 * + col0 - + col2 / + CAST( NULL AS SIGNED ) AS col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2251
SELECT DISTINCT col1 * + col0 - + col2 / + CAST ( NULL AS INTEGER ) AS col2 FROM tab1
----
NULL

query I rowsort
SELECT + 28 * + 37 * - col2 AS col1 FROM tab2
----
-26936
-27972
-39368

query I rowsort
SELECT - + col1 + ( + col1 ) AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT 15 * + 7 - col1 * + 27 * col2 FROM tab2 AS cor0
----
-17337
-22494
-41313

query I rowsort
SELECT ALL col1 + col1 * col0 AS col0 FROM tab0
----
2150
3492
8190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2256
SELECT - col2 * + cor0.col2 + CAST( NULL AS SIGNED ) * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2256
SELECT - col2 * + cor0.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-2257
SELECT col0 + col2 / CAST( NULL AS SIGNED ) - + col2 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2257
SELECT col0 + col2 / CAST ( NULL AS INTEGER ) - + col2 AS col0 FROM tab1
----
NULL
NULL
NULL

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0, tab2 AS cor0, tab2 cor1
----
972 values hashing to 617c9545df26d6d983e3967864e8e9e4

query I rowsort
SELECT DISTINCT - col0 * col1 - 35 FROM tab2 AS cor0
----
-1378
-252
-4637

query I rowsort
SELECT ALL - ( col1 ) * + cor0.col2 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2261
SELECT 70 * - col1 + CAST( + col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-1817
-636
-830

skipif mysql # not compatible
query I rowsort label-2261
SELECT 70 * - col1 + CAST ( + col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-1817
-636
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2262
SELECT DISTINCT - CAST( NULL AS SIGNED ) * 15 col1 FROM tab2, tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2262
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * 15 col1 FROM tab2, tab2 AS cor0
----
NULL

query I rowsort
SELECT col1 - ( + col1 ) AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT + col1 * - ( + col1 ) FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT - col2 * 81 * col2 AS col2 FROM tab2 AS cor0
----
-116964
-54756
-59049

query I rowsort
SELECT + ( + 11 ) * col2 AS col1 FROM tab2 AS cor0
----
286
297
418

query I rowsort
SELECT 20 * - 57 + col1 FROM tab2 AS cor0
----
-1081
-1109
-1123

onlyif mysql # use DIV operator for integer division
query I rowsort label-2268
SELECT ALL + + cor0.col2 DIV 71 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

skipif mysql # not compatible
query I rowsort label-2268
SELECT ALL + + cor0.col2 / 71 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

query I rowsort
SELECT 66 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT DISTINCT + ( - ( col2 ) ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT + - col1 + cor0.col2 AS col1 FROM tab1 cor0
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col0 ) col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT col2 + - col1 + col1 AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL cor0.col1 * + cor0.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to bc669a3cc969c7619ebcffb5400ba0ba

query III rowsort
SELECT * FROM tab0 cor0 WHERE NOT NULL BETWEEN col2 + col2 + + col2 / col1 AND NULL
----

query I rowsort
SELECT col1 - col0 * col0 * + cor0.col1 FROM tab0 AS cor0
----
-118728
-49450
-720720

query I rowsort
SELECT DISTINCT - col1 * col0 + col0 FROM tab1 cor0
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-2278
SELECT cor0.col0 DIV col2 + + col2 AS col2 FROM tab1 AS cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-2278
SELECT cor0.col0 / col2 + + col2 AS col2 FROM tab1 AS cor0
----
54
58
96

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE + col1 + col0 BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT - col1 + col0 + - cor0.col1 * - col0 AS col2 FROM tab2 cor0
----
1405
193
4621

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 + cor0.col2 col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL col0 + - cor0.col2 + - col0 AS col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + cor0.col0 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col1 col1 FROM tab1
----
100
169
676

query I rowsort
SELECT ALL col1 + col1 + + tab2.col1 AS col0 FROM tab2
----
177
51
93

query I rowsort
SELECT DISTINCT - col2 * col1 + - col0 + tab1.col0 AS col0 FROM tab1
----
-1248
-1404
-570

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT + col0 + - col1 NOT IN ( col1 * col1 )
----

query I rowsort
SELECT + col1 * + col1 * + col1 FROM tab1
----
1000
17576
2197

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT col0 * - tab2.col1 IN ( col2 - - col1 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2290
SELECT DISTINCT + tab1.col2 + tab1.col0 DIV col2 + col0 AS col1 FROM tab1
----
122
176
57

skipif mysql # not compatible
query I rowsort label-2290
SELECT DISTINCT + tab1.col2 + tab1.col0 / col2 + col0 AS col1 FROM tab1
----
122
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + - col1 * col2 col1 FROM tab0
----
-2805
-7380
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * tab1.col0 col1 FROM tab1
----
-162
-3648
-7680

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT BETWEEN ( NULL ) AND col0 * - col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2294
SELECT ALL col0 * - cor0.col2 + col1 DIV col2 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-2294
SELECT ALL col0 * - cor0.col2 + col1 / col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2295
SELECT tab0.col2 + tab0.col2 * col2 DIV + col0 + - col2 FROM tab0
----
0
45
75

skipif mysql # not compatible
query I rowsort label-2295
SELECT tab0.col2 + tab0.col2 * col2 / + col0 + - col2 FROM tab0
----
0
45
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-2296
SELECT DISTINCT + tab0.col1 DIV col0 + + col2 * + col1 - col0 DIV - col2 AS col2 FROM tab0
----
134
2841
7464

skipif mysql # not compatible
query I rowsort label-2296
SELECT DISTINCT + tab0.col1 / col0 + + col2 * + col1 - col0 / - col2 AS col2 FROM tab0
----
134
2841
7464

query III rowsort
SELECT * FROM tab2 WHERE NULL <> ( col1 + + col1 )
----

query I rowsort
SELECT ALL col0 * col0 FROM tab2 WHERE NULL NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT DISTINCT - col2 * + col0 + + col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT - cor0.col0 * col2 - - col2 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + col0 * col1 col2 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT col0 - tab2.col1 * + col1 AS col2 FROM tab2
----
-210
-3403
-954

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col2 + col2 col1 FROM tab2
----
52
54
76

query I rowsort
SELECT col2 * - col0 - + tab2.col2 * - col1 AS col2 FROM tab2
----
-2356
-494
648

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + col2 col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL - col2 * col1 + + col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT + cor0.col2 * + col1 + + col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2308
SELECT DISTINCT tab2.col1 - - CAST( NULL AS SIGNED ) AS col0 FROM tab0, tab1, tab0 AS cor0, tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-2308
SELECT DISTINCT tab2.col1 - - CAST ( NULL AS INTEGER ) AS col0 FROM tab0, tab1, tab0 AS cor0, tab2
----
NULL

query I rowsort
SELECT DISTINCT + - 41 AS col1 FROM tab0 AS cor0
----
-41

query I rowsort
SELECT ALL + 54 * + col2 - col0 AS col0 FROM tab0 AS cor0
----
1758
19
4339

query I rowsort
SELECT DISTINCT + cor0.col0 * cor0.col2 * 7 FROM tab1 AS cor0
----
1134
25536
53760

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-2313
SELECT DISTINCT + col2 DIV + col0 + + col2 * - col2 - - ( col0 ) FROM tab0 AS cor0
----
-1064
-6635
34

skipif mysql # not compatible
query I rowsort label-2313
SELECT DISTINCT + col2 / + col0 + + col2 * - col2 - - ( col0 ) FROM tab0 AS cor0
----
-1064
-6635
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2314
SELECT ALL - col0 * CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-2314
SELECT ALL - col0 * CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
-162
-3648
-7680

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2, tab2 AS cor3
----
3645 values hashing to fa0488bdae83f58c7ffa92505e928570

query I rowsort
SELECT ALL + col2 * 40 + col0 FROM tab1 AS cor0
----
2163
2344
3920

query I rowsort
SELECT + col0 * ( + col2 ) * - col1 AS col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * 61 col2 FROM tab0 AS cor0
----
1464
2135
5429

query I rowsort
SELECT DISTINCT - - col0 * - col2 + + col0 FROM tab2 cor0
----
-182
-1950
-2923

query I rowsort
SELECT ALL - + col1 * + col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT col1 * + 29 FROM tab0 AS cor0
----
2494
2639
2813

query I rowsort
SELECT col2 + + tab2.col2 AS col2 FROM tab2
----
52
54
76

query I rowsort
SELECT ALL + col1 * - col1 + col0 FROM tab0
----
-7372
-8192
-9374

query I rowsort
SELECT DISTINCT + col1 + + tab0.col2 * - tab0.col0 AS col0 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT col1 FROM tab0 WHERE NULL <> NULL
----

query I rowsort
SELECT col2 * - col2 - - col2 FROM tab1
----
-2862
-3192
-9120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + + col1 * col2 col2 FROM tab0
----
0
2752
7371

query I rowsort
SELECT ALL + col1 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 + col2 * + cor0.col0 * 61 FROM tab1 AS cor0
----
222471
468384
9828

query I rowsort
SELECT ALL + cor0.col0 * col2 AS col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ALL + col1 * col2 - - col1 FROM tab2
----
1593
663
868

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) IN ( col1 * col1 + col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col0 * col1 col0 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT col1 - tab1.col0 * col2 AS col0 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT 54 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT ALL 74 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

query I rowsort
SELECT DISTINCT 90 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2338
SELECT col2 / - CAST( NULL AS SIGNED ) + col2 / col0 + 54 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2338
SELECT col2 / - CAST ( NULL AS INTEGER ) + col2 / col0 + 54 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * ( + tab2.col2 ) FROM tab2
----
1444
676
729

query I rowsort
SELECT - cor0.col0 * - 88 * - col0 + 19 AS col2 FROM tab2 AS cor0
----
-4293
-535373
-549189

query I rowsort
SELECT + col2 * col2 + col1 AS col1 FROM tab2 cor0
----
1461
735
760

query I rowsort
SELECT - + ( cor0.col1 ) + - col1 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT col2 + col2 + cor0.col0 FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT - col1 + 43 AS col0 FROM tab2 AS cor0
----
-16
12
26

query I rowsort
SELECT 99 + - col1 AS col2 FROM tab2 AS cor0
----
40
68
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * col0 * col0 col1 FROM tab1 AS cor0
----
-234
-40960
-83200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2347
SELECT - 9 * + col0 * CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2347
SELECT - 9 * + col0 * CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 + col1 * cor0.col0 AS col2 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT - - 96 * + cor0.col1 + col2 FROM tab2 AS cor0
----
1670
3003
5690

query I rowsort
SELECT - col2 + + cor0.col1 * - col2 AS col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT 88 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

query I rowsort
SELECT col2 * col2 + cor0.col1 AS col1 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT DISTINCT ( 13 ) FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
13

query I rowsort
SELECT col2 * + col2 + col2 * - col0 * col0 FROM tab1
----
-230223
-605184
2430

query I rowsort
SELECT + + 20 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

query I rowsort
SELECT ALL col2 * col1 + - col1 AS col0 FROM tab2 AS cor0
----
1475
629
806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + + 3 col0 FROM tab2 cor0
----
10
81
82

query I rowsort
SELECT DISTINCT - - col0 * col0 + - 62 FROM tab0 AS cor0
----
1163
514
7859

query I rowsort
SELECT DISTINCT + - col0 + 38 * col2 AS col1 FROM tab1 cor0
----
2049
2102
3568

onlyif mysql # use DIV operator for integer division
query I rowsort label-2360
SELECT cor0.col2 * col0 DIV 25 FROM tab2 AS cor0
----
120
7
81

skipif mysql # not compatible
query I rowsort label-2360
SELECT cor0.col2 * col0 / 25 FROM tab2 AS cor0
----
120
7
81

query I rowsort
SELECT ALL col2 + - 88 AS col1 FROM tab2 AS cor0
----
-50
-61
-62

query I rowsort
SELECT DISTINCT - - col1 * - col2 + ( + col2 ) * cor0.col0 FROM tab0 cor0
----
-164
-2046
-62

query I rowsort
SELECT ALL col1 + + cor0.col1 * + 99 FROM tab1 AS cor0
----
1000
1300
2600

query I rowsort
SELECT col1 + - ( - col2 ) - - col0 * col0 AS col2 FROM tab2 AS cor0
----
107
6169
6296

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab2, tab1 cor1, tab1 AS cor2, tab2 AS cor3
----
3645 values hashing to 85e6cb74738e0d8388af8fb625b2bd38

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 AS cor2, tab2 cor3
----
3645 values hashing to 28412d50061391eec23a02d0efcfb3f9

query I rowsort
SELECT DISTINCT + 78 FROM tab2, tab2 AS cor0
----
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col1 * + tab2.col2 - tab2.col2 * col1 col0 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL + + 32 * + col2 FROM tab2 AS cor0
----
1216
832
864

query I rowsort
SELECT DISTINCT + 35 * + col0 + col1 AS col2 FROM tab1 AS cor0
----
131
2250
2813

query I rowsort
SELECT - col0 * + tab0.col0 - + col0 FROM tab0
----
-1260
-600
-8010

query I rowsort
SELECT + ( + col2 ) * col1 FROM tab2
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2373
SELECT CAST( NULL AS SIGNED ) * col1 * - tab1.col0 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2373
SELECT CAST ( NULL AS INTEGER ) * col1 * - tab1.col0 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * + col1 col1 FROM tab2 AS cor0
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 2 col2 FROM tab2 cor0
----
-2
-2
-2

query I rowsort
SELECT tab0.col2 + tab0.col1 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 15ff38272c484fb486e1883e64781cf3

query I rowsort
SELECT ALL col1 + cor0.col2 AS col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + - 84 AS col0 FROM tab0 AS cor0
----
-84
-84
-84

query I rowsort
SELECT ( - col0 ) * - col2 AS col0 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-2380
SELECT - col2 DIV + col2 AS col0 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2380
SELECT - col2 / + col2 AS col0 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - + ( + ( + col1 ) ) * - 23 FROM tab0 AS cor0
----
1978
2093
2231

query I rowsort
SELECT DISTINCT col1 * col1 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT ( ( cor0.col2 ) ) FROM tab2 AS cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 60 col1 FROM tab2 AS cor0
----
60
60
60

query I rowsort
SELECT DISTINCT - 77 * + col0 * col1 AS col1 FROM tab0 AS cor0
----
-158928
-261415
-623623

onlyif mysql # use DIV operator for integer division
query I rowsort label-2386
SELECT ALL - col0 DIV - 60 FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-2386
SELECT ALL - col0 / - 60 FROM tab2 AS cor0
----
0
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2387
SELECT ALL CAST( + 44 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
44
44
44

skipif mysql # not compatible
query I rowsort label-2387
SELECT ALL CAST ( + 44 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
44
44
44

query I rowsort
SELECT ALL - col0 - - col1 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT ALL 92 * col1 + + 14 * col0 AS col0 FROM tab0 AS cor0
----
8248
9414
9618

query I rowsort
SELECT DISTINCT - col0 * + col0 - + ( + col0 ) FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT DISTINCT col1 + + col0 AS col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - col0 * - col1 + col0 - + col2 FROM tab1 AS cor0
----
1024
27
647

query I rowsort
SELECT + col1 - + col2 * + col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT - 47 + col0 AS col1 FROM tab1 AS cor0
----
-44
17
33

query I rowsort
SELECT ALL - + col1 + + cor0.col0 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ALL - - 71 AS col0 FROM tab2 AS cor0
----
71
71
71

query I rowsort
SELECT - + col1 * + cor0.col2 + 30 FROM tab0 AS cor0
----
-2808
-67
-7432

query I rowsort
SELECT ALL + - col0 * col0 * 39 AS col0 FROM tab0 AS cor0
----
-22464
-308919
-47775

onlyif mysql # use DIV operator for integer division
query I rowsort label-2399
SELECT DISTINCT - col2 DIV 47 AS col1 FROM tab0 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-2399
SELECT DISTINCT - col2 / 47 AS col1 FROM tab0 cor0
----
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2400
SELECT DISTINCT + - col2 + + CAST( NULL AS SIGNED ) * + col2 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2400
SELECT DISTINCT + - col2 + + CAST ( NULL AS INTEGER ) * + col2 AS col2 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + - cor0.col0 col2 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT DISTINCT - 67 + cor0.col1 AS col0 FROM tab0 AS cor0
----
19
24
30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2403
SELECT DISTINCT + - CAST( NULL AS SIGNED ) + col0 * + col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2403
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) + col0 * + col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + ( 66 ) FROM tab1 AS cor0
----
66
66
66

query I rowsort
SELECT ALL - 19 + - col0 AS col2 FROM tab0 AS cor0
----
-108
-43
-54

query I rowsort
SELECT DISTINCT 57 + + col0 AS col2 FROM tab1 AS cor0
----
121
137
60

query I rowsort
SELECT - 34 AS col2 FROM tab0 AS cor0
----
-34
-34
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2408
SELECT ALL - CAST( + col0 AS SIGNED ) + - col1 * + col0 * - 27 FROM tab1 AS cor0
----
17216
2103
28000

skipif mysql # not compatible
query I rowsort label-2408
SELECT ALL - CAST ( + col0 AS INTEGER ) + - col1 * + col0 * - 27 FROM tab1 AS cor0
----
17216
2103
28000

query I rowsort
SELECT ( + 76 ) FROM tab0 cor0
----
76
76
76

query I rowsort
SELECT col1 * + ( 30 ) + col2 AS col0 FROM tab0
----
2613
2812
2911

onlyif mysql # use DIV operator for integer division
query I rowsort label-2411
SELECT ALL - col2 DIV ( 94 * - col2 + + 83 ) AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2411
SELECT ALL - col2 / ( 94 * - col2 + + 83 ) AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT - 88 * 65 FROM tab1 AS cor0
----
-5720

query I rowsort
SELECT ALL 3 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT 11 * col1 + col2 AS col1 FROM tab0
----
1068
1083
979

query I rowsort
SELECT DISTINCT - ( 70 ) * + col0 FROM tab1
----
-210
-4480
-5600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 col0 FROM tab1, tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ( + 82 ) * - col1 + ( col1 ) FROM tab0 AS cor0
----
-6966
-7371
-7857

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 - 28 col2 FROM tab1 AS cor0
----
-108
-31
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-2419
SELECT col1 - col1 DIV + col0 FROM tab2 AS cor0
----
17
27
59

skipif mysql # not compatible
query I rowsort label-2419
SELECT col1 - col1 / + col0 FROM tab2 AS cor0
----
17
27
59

query I rowsort
SELECT - col0 + - ( + cor0.col1 ) FROM tab1 AS cor0
----
-29
-74
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col0 + col2 col1 FROM tab0
----
-34
-7
9

query I rowsort
SELECT + 99 * col0 AS col1 FROM tab1 cor0
----
297
6336
7920

query I rowsort
SELECT ALL + 91 * col2 AS col0 FROM tab0 cor0
----
3003
7462
91

query I rowsort
SELECT ALL tab1.col2 * col0 + - ( col1 ) AS col1 FROM tab1
----
136
3638
7667

query I rowsort
SELECT DISTINCT - col1 + + cor0.col1 + col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + col0 - 47 * 32 FROM tab2 AS cor0
----
-1425
-1426
-1497

query I rowsort
SELECT col1 + + ( ( + col0 ) ) AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - cor0.col2 * - 68 * - col0 FROM tab2 AS cor0
----
-12852
-137904
-204136

query I rowsort
SELECT - + cor0.col0 - + col0 * + 44 FROM tab1 AS cor0
----
-135
-2880
-3600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2430
SELECT ALL + cor0.col2 * + CAST( NULL AS SIGNED ) col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2430
SELECT ALL + cor0.col2 * + CAST ( NULL AS INTEGER ) col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * ( col0 ) + + col2 AS col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT cor0.col2 - + 81 AS col1 FROM tab2 AS cor0
----
-43
-54
-55

query I rowsort
SELECT - - col1 + + col1 * col0 AS col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT cor0.col1 * - ( col1 ) AS col0 FROM tab1 AS cor0
----
-100
-169
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-2435
SELECT col1 + 26 DIV - col1 FROM tab2 cor0
----
16
31
59

skipif mysql # not compatible
query I rowsort label-2435
SELECT col1 + 26 / - col1 FROM tab2 cor0
----
16
31
59

query I rowsort
SELECT - 20 + - 97 FROM tab0
----
-117
-117
-117

query I rowsort
SELECT ALL - ( 7 ) FROM tab1
----
-7
-7
-7

query I rowsort
SELECT ALL - 50 * 38 * col0 AS col2 FROM tab1
----
-121600
-152000
-5700

query I rowsort
SELECT + + 49 + + col2 FROM tab0 AS cor0
----
131
50
82

query I rowsort
SELECT DISTINCT - col1 - col0 * + 82 AS col1 FROM tab2
----
-605
-6455
-6495

query I rowsort
SELECT 24 - col0 FROM tab1 AS cor0
----
-40
-56
21

query I rowsort
SELECT - col2 - cor0.col0 AS col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT - 93 * col0 + + 2 AS col1 FROM tab0 AS cor0
----
-2230
-3253
-8275

query I rowsort
SELECT 44 * + col0 FROM tab0 AS cor0
----
1056
1540
3916

query I rowsort
SELECT - + cor0.col1 * col2 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 cor0 CROSS JOIN tab2, tab2 AS cor1, tab2 AS cor2
----
972 values hashing to 958533d1a7bf61199ed7c03eadf37f9a

query I rowsort
SELECT - - col0 * - cor0.col1 + col1 * col0 * col2 FROM tab2 cor0
----
115050
49691
5642

query I rowsort
SELECT + col0 + ( + cor0.col2 ) * col1 FROM tab1 cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT + col0 * + col2 * col2 AS col2 FROM tab0 cor0
----
26136
35
598436

query I rowsort
SELECT + col1 + + ( - col1 ) * cor0.col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT - - col1 * 81 AS col0 FROM tab1 AS cor0
----
1053
2106
810

query I rowsort
SELECT 4 * col0 AS col2 FROM tab0 AS cor0
----
140
356
96

query I rowsort
SELECT - col0 * - 30 AS col0 FROM tab2 AS cor0
----
210
2340
2370

query I rowsort
SELECT ALL - 69 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 3bd7460efa48c66c072ad5f3c2def7e9

query I rowsort
SELECT - 36 * col2 AS col0 FROM tab2 AS cor0
----
-1368
-936
-972

query I rowsort
SELECT DISTINCT ( 85 ) * + cor2.col0 FROM tab2, tab1 AS cor0, tab2 AS cor1, tab2 AS cor2
----
595
6630
6715

onlyif mysql # use DIV operator for integer division
query I rowsort label-2457
SELECT + 72 DIV + 95 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2457
SELECT + 72 / + 95 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + ( + ( + col0 ) ) + col0 AS col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT + 60 + ( + col0 ) FROM tab2
----
138
139
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-2460
SELECT ALL - col0 DIV ( + col0 ) FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2460
SELECT ALL - col0 / ( + col0 ) FROM tab2
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2461
SELECT DISTINCT CAST( col0 AS SIGNED ) + col1 * + ( col0 ) AS col0 FROM tab2 AS cor0
----
1422
224
4680

skipif mysql # not compatible
query I rowsort label-2461
SELECT DISTINCT CAST ( col0 AS INTEGER ) + col1 * + ( col0 ) AS col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT + + ( + col2 ) * + col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT + ( col1 ) + + col2 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL cor0.col0 + + col1 * col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT ALL + ( 71 ) * col0 AS col1 FROM tab1 AS cor0
----
213
4544
5680

query I rowsort
SELECT + 46 * col0 * cor0.col1 AS col1 FROM tab2 AS cor0
----
211692
61778
9982

query I rowsort
SELECT ALL col2 * + 35 FROM tab2 AS cor0
----
1330
910
945

query I rowsort
SELECT - ( cor0.col1 ) * col1 * + col0 FROM tab0 cor0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL - + 88 AS col1 FROM tab2 AS cor0
----
-88
-88
-88

query I rowsort
SELECT DISTINCT - 55 * col0 AS col0 FROM tab1 AS cor0
----
-165
-3520
-4400

query I rowsort
SELECT DISTINCT + 57 * + col2 FROM tab1 AS cor0
----
3078
3249
5472

query I rowsort
SELECT ALL - 26 * col0 * - col1 FROM tab0 AS cor0
----
210574
53664
88270

query I rowsort
SELECT ALL ( + cor1.col0 ) FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2474
SELECT DISTINCT ( - col0 ) DIV col1 AS col0 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-2474
SELECT DISTINCT ( - col0 ) / col1 AS col0 FROM tab0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2475
SELECT DISTINCT + CAST( NULL AS SIGNED ) / + 9 AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2475
SELECT DISTINCT + CAST ( NULL AS INTEGER ) / + 9 AS col0 FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT + 70 AS col0 FROM tab0, tab0 AS cor0
----
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-2477
SELECT - - col2 DIV + 74 + - col2 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-2477
SELECT - - col2 / + 74 + - col2 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - - col0 + 92 * - col1 FROM tab0 AS cor0
----
-7888
-8283
-8889

query I rowsort
SELECT DISTINCT - col2 * col2 * col2 FROM tab2 AS cor0
----
-17576
-19683
-54872

query I rowsort
SELECT ALL + - col2 + - col2 * + 77 FROM tab1 cor0
----
-4212
-4446
-7488

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 38 col0 FROM tab2
----
1026
1444
988

query I rowsort
SELECT DISTINCT - 25 * - 33 * + tab1.col1 FROM tab1, tab2 cor0
----
10725
21450
8250

query I rowsort
SELECT ALL + col0 * 81 AS col0 FROM tab1
----
243
5184
6480

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1, tab1 cor0, tab0 AS cor1
----
972 values hashing to 909b7ebab62aff8f69dc42ccbb5c2eae

query I rowsort
SELECT DISTINCT - - col1 * - col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT 91 FROM tab1, tab1 AS cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

skipif mysql # not compatible
query I rowsort
SELECT - tab0.col0 * - CAST ( ( col0 ) + - col2 AS REAL ) FROM tab0
----
-216
1190
623

query I rowsort
SELECT DISTINCT + col2 + tab1.col2 AS col0 FROM tab1
----
108
114
192

query I rowsort
SELECT 36 + - col0 AS col2 FROM tab0 AS cor0
----
-53
1
12

query I rowsort
SELECT + + 9 FROM tab2 cor0
----
9
9
9

query I rowsort
SELECT ALL + 90 * col2 FROM tab0 AS cor0
----
2970
7380
90

query I rowsort
SELECT col0 * 66 FROM tab1 AS cor0
----
198
4224
5280

query I rowsort
SELECT ALL - col1 + - ( + col2 ) * + col1 * - col2 FROM tab2 AS cor0
----
22568
24531
39825

query I rowsort
SELECT DISTINCT + cor0.col1 + col1 FROM tab1 cor0
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2495
SELECT + CAST( NULL AS SIGNED ) + - cor0.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2495
SELECT + CAST ( NULL AS INTEGER ) + - cor0.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - + col0 * + 39 AS col0 FROM tab1 AS cor0
----
-117
-2496
-3120

skipif mysql # not compatible
query I rowsort
SELECT + col1 * CAST ( cor0.col0 AS REAL ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL + cor0.col0 + ( + col2 ) * col0 AS col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + + col2 * col1 * 75 AS col2 FROM tab1 AS cor0
----
105300
42750
93600

query I rowsort
SELECT ALL 57 + tab0.col1 * col2 + col1 * - col2 AS col1 FROM tab0
----
57
57
57

query I rowsort
SELECT ALL - + 10 AS col2 FROM tab2 AS cor0
----
-10
-10
-10

query I rowsort
SELECT ( cor0.col2 ) + - col2 + col1 AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - + ( ( - col2 ) ) + + col2 AS col0 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT DISTINCT + 8 * col1 + col2 + + 69 FROM tab0 AS cor0
----
790
846
879

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 80 * + cor0.col1 + - cor0.col2 col1 FROM tab2 AS cor0
----
-1398
-2507
-4746

query I rowsort
SELECT DISTINCT - - 31 * cor0.col2 FROM tab2 AS cor0
----
1178
806
837

query I rowsort
SELECT DISTINCT + 43 + + cor0.col1 * 33 FROM tab2, tab0 AS cor0
----
2881
3046
3244

query I rowsort
SELECT - col1 * + 37 - + col0 AS col0 FROM tab1 AS cor0
----
-434
-561
-965

query I rowsort
SELECT + col0 * col2 + cor0.col1 - 20 FROM tab1 AS cor0
----
168
3638
7673

query I rowsort
SELECT DISTINCT col2 + col2 * - col2 * col1 AS col0 FROM tab0 AS cor0
----
-611802
-93621
-96

query I rowsort
SELECT - + col1 + - col2 + col2 FROM tab2 AS cor0
----
-17
-31
-59

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 DISTINCT + ( - col2 ) * + col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - - col0 * + cor0.col1 + col1 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-2515
SELECT DISTINCT - col2 * + col2 - col0 * col1 DIV col1 AS col2 FROM tab1 AS cor0
----
-2919
-3313
-9296

skipif mysql # not compatible
query I rowsort label-2515
SELECT DISTINCT - col2 * + col2 - col0 * col1 / col1 AS col2 FROM tab1 AS cor0
----
-2919
-3313
-9296

query I rowsort
SELECT ALL + col0 + - col2 * - col1 FROM tab2 cor0
----
1612
725
844

query I rowsort
SELECT ALL - + col0 * - col0 + col2 - col1 * col0 FROM tab0 AS cor0
----
-1455
-2169
-96

query I rowsort
SELECT + + col1 + col0 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + 1 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 * - col1 col0 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT - col0 + col1 * col2 + 57 * - col1 AS col1 FROM tab1 AS cor0
----
-64
-81
427

query I rowsort
SELECT ALL + + 14 * col2 FROM tab0 AS cor0
----
1148
14
462

query I rowsort
SELECT DISTINCT - 96 * + col0 AS col2 FROM tab0
----
-2304
-3360
-8544

query I rowsort
SELECT DISTINCT - col2 * col0 + cor0.col2 * + cor0.col0 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ( - col1 ) * 58 + ( col1 ) AS col1 FROM tab2 AS cor0
----
-1767
-3363
-969

query I rowsort
SELECT DISTINCT + 24 + cor0.col2 AS col1 FROM tab1 AS cor0
----
120
78
81

query I rowsort
SELECT + + ( + col0 ) * + col0 + col2 * - col2 FROM tab0 AS cor0
----
-513
1197
1224

onlyif mysql # use DIV operator for integer division
query I rowsort label-2528
SELECT ALL - col0 DIV + col1 + - col2 DIV - 88 col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2528
SELECT ALL - col0 / + col1 + - col2 / - 88 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - 46 * - col1 + col1 FROM tab2 AS cor0
----
-1395
-2655
-765

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + col2 * col0 * + 81 col1 FROM tab2
----
15316
164346
243241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor1.col1 col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
86
91
97

query I rowsort
SELECT ALL + col1 * - col0 + - col0 + col2 FROM tab0
----
-2055
-3429
-8106

query I rowsort
SELECT + + col2 * cor0.col1 * 88 + + col0 FROM tab0 AS cor0
----
249768
656745
8571

skipif mysql # not compatible
query I rowsort
SELECT + col2 + CAST ( + col0 AS REAL ) * cor0.col1 * - col0 FROM tab2 AS cor0
----
-106059
-1492
-358930

query I rowsort
SELECT 44 * - col0 FROM tab0
----
-1056
-1540
-3916

query I rowsort
SELECT + cor0.col1 AS col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT 34 * col2 FROM tab0 cor0
----
1122
2788
34

query I rowsort
SELECT ALL ( - 70 ) * - col0 FROM tab0 AS cor0
----
1680
2450
6230

query I rowsort
SELECT + - col2 * + ( + col0 ) + col1 FROM tab1 AS cor0
----
-136
-3638
-7667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2540
SELECT DISTINCT - + CAST( NULL AS SIGNED ) + 66 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2540
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) + 66 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - 86 AS col0 FROM tab2 AS cor0
----
-86
-86
-86

query I rowsort
SELECT DISTINCT - col2 * 22 AS col1 FROM tab1 AS cor0
----
-1188
-1254
-2112

query I rowsort
SELECT ALL 3 * + cor0.col2 FROM tab1 AS cor0
----
162
171
288

query I rowsort
SELECT - col2 + + 78 * + 99 AS col1 FROM tab1
----
7626
7665
7668

query I rowsort
SELECT DISTINCT col2 + 62 * col2 AS col1 FROM tab1
----
3402
3591
6048

query I rowsort
SELECT - - 77 - - 77 * col1 FROM tab2 AS cor0
----
1386
2464
4620

query I rowsort
SELECT DISTINCT + 29 + 33 FROM tab2 AS cor0
----
62

query I rowsort
SELECT - 72 - cor0.col0 AS col0 FROM tab1 AS cor0
----
-136
-152
-75

query I rowsort
SELECT ALL + col0 * col1 + col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT DISTINCT col0 + + col1 - - col0 FROM tab1 AS cor0
----
138
173
32

query I rowsort
SELECT DISTINCT + 55 * + col0 + tab1.col0 FROM tab1
----
168
3584
4480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2552
SELECT ALL 42 * col0 + cor0.col2 + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2552
SELECT ALL 42 * col0 + cor0.col2 + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2553
SELECT DISTINCT ( ( cor0.col2 ) ) * + 3 + - 56 + col0 DIV - ( + 3 + col1 ) FROM tab2 AS cor0
----
21
25
55

skipif mysql # not compatible
query I rowsort label-2553
SELECT DISTINCT ( ( cor0.col2 ) ) * + 3 + - 56 + col0 / - ( + 3 + col1 ) FROM tab2 AS cor0
----
21
25
55

query I rowsort
SELECT + - 36 * - col2 * + col1 - + col1 FROM tab1 AS cor0
----
20510
44915
50518

query I rowsort
SELECT - 23 * cor1.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 873aca2c0aaeaf94667fbf381a589907

query I rowsort
SELECT DISTINCT - 41 AS col1 FROM tab1, tab1 cor0
----
-41

query I rowsort
SELECT + 73 * - cor0.col1 AS col2 FROM tab0 AS cor0
----
-6278
-6643
-7081

query I rowsort
SELECT - tab2.col2 * + 97 AS col2 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to bffef995f2157ad2ea135c0731aa2c13

query I rowsort
SELECT ALL - ( cor0.col0 ) + col0 * cor0.col1 * col1 FROM tab1 AS cor0
----
13440
2025
6336

query I rowsort
SELECT 35 * col1 AS col0 FROM tab0 AS cor0
----
3010
3185
3395

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + cor0.col2 * + 60 col1 FROM tab2 AS cor0
----
1501
1589
2263

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( cor0.col0 ) col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT - col1 + - col0 * - ( col2 ) FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT DISTINCT ( - 15 ) * + tab2.col0 FROM tab2
----
-105
-1170
-1185

query I rowsort
SELECT ( col0 ) - - tab2.col0 AS col0 FROM tab2
----
14
156
158

query I rowsort
SELECT 95 FROM tab2, tab1 cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

query I rowsort
SELECT ( + col0 ) * col1 - col1 AS col0 FROM tab0
----
1978
3298
8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-2568
SELECT col0 + + ( col1 ) DIV col2 AS col1 FROM tab0 AS cor0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-2568
SELECT col0 + + ( col1 ) / col2 AS col1 FROM tab0 AS cor0
----
132
26
90

query I rowsort
SELECT DISTINCT - 77 AS col1 FROM tab0
----
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 86 col2 FROM tab2
----
86
86
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-2571
SELECT DISTINCT - tab1.col0 DIV - col1 AS col1 FROM tab1
----
0
6

skipif mysql # not compatible
query I rowsort label-2571
SELECT DISTINCT - tab1.col0 / - col1 AS col1 FROM tab1
----
0
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2572
SELECT - + col0 + col2 DIV cor0.col1 FROM tab2 AS cor0
----
-7
-77
-78

skipif mysql # not compatible
query I rowsort label-2572
SELECT - + col0 + col2 / cor0.col1 FROM tab2 AS cor0
----
-7
-77
-78

query I rowsort
SELECT col0 * - col2 + col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT + col2 + + col2 AS col1 FROM tab0
----
164
2
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2575
SELECT ALL + + CAST( 10 AS SIGNED ) * + col1 FROM tab1 AS cor0
----
100
130
260

skipif mysql # not compatible
query I rowsort label-2575
SELECT ALL + + CAST ( 10 AS INTEGER ) * + col1 FROM tab1 AS cor0
----
100
130
260

query I rowsort
SELECT col2 * + 78 AS col1 FROM tab2
----
2028
2106
2964

query I rowsort
SELECT + ( 41 ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

onlyif mysql # use DIV operator for integer division
query I rowsort label-2578
SELECT + col1 * 89 DIV - col0 + + cor0.col0 FROM tab1 AS cor0
----
-768
51
66

skipif mysql # not compatible
query I rowsort label-2578
SELECT + col1 * 89 / - col0 + + cor0.col0 FROM tab1 AS cor0
----
-768
51
66

query I rowsort
SELECT DISTINCT - col0 * col2 + + col2 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT + - 7 FROM tab1 AS cor0
----
-7
-7
-7

query I rowsort
SELECT + col1 + 76 AS col1 FROM tab2 cor0
----
107
135
93

query I rowsort
SELECT DISTINCT - + 24 * col1 + col0 AS col1 FROM tab2 AS cor0
----
-1338
-329
-737

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2583
SELECT ALL + col0 * + 60 / col1 + CAST( NULL AS SIGNED ) - - col2 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2583
SELECT ALL + col0 * + 60 / col1 + CAST ( NULL AS INTEGER ) - - col2 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col1 + - col1 * col2 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT ALL cor0.col0 + 44 AS col2 FROM tab2 AS cor0
----
122
123
51

query I rowsort
SELECT DISTINCT - + ( col0 ) * - col2 + col1 * col0 * - col1 AS col2 FROM tab2 cor0
----
-19829
-269490
-6538

query I rowsort
SELECT ALL col1 - + 28 FROM tab2 AS cor0
----
-11
3
31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2588
SELECT DISTINCT - col1 * + 46 * - col1 + CAST( NULL AS SIGNED ) + 85 AS col1 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2588
SELECT DISTINCT - col1 * + 46 * - col1 + CAST ( NULL AS INTEGER ) + 85 AS col1 FROM tab1 cor0
----
NULL

query I rowsort
SELECT + 69 * col2 AS col0 FROM tab1 AS cor0
----
3726
3933
6624

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2590
SELECT DISTINCT CAST( NULL AS SIGNED ) + - 14 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2590
SELECT DISTINCT CAST ( NULL AS INTEGER ) + - 14 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2591
SELECT ALL - + col1 DIV - 89 + + col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2591
SELECT ALL - + col1 / - 89 + + col1 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + cor0.col2 col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL 55 + col2 * col2 FROM tab0 AS cor0
----
1144
56
6779

onlyif mysql # use DIV operator for integer division
query I rowsort label-2594
SELECT + col0 DIV col0 + + col0 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-2594
SELECT + col0 / col0 + + col0 FROM tab0
----
25
36
90

query I rowsort
SELECT col2 - + col0 AS col2 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-2596
SELECT cor0.col0 + + col0 DIV + 62 FROM tab1 AS cor0
----
3
65
81

skipif mysql # not compatible
query I rowsort label-2596
SELECT cor0.col0 + + col0 / + 62 FROM tab1 AS cor0
----
3
65
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-2597
SELECT DISTINCT - col2 DIV cor0.col0 FROM tab2 AS cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-2597
SELECT DISTINCT - col2 / cor0.col0 FROM tab2 AS cor0
----
-3
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2598
SELECT ( + col0 ) + col1 DIV + col1 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-2598
SELECT ( + col0 ) + col1 / + col1 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT DISTINCT - + ( col0 ) * + 24 + 64 FROM tab0 AS cor0
----
-2072
-512
-776

query I rowsort
SELECT - cor0.col2 - + col1 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2601
SELECT ALL + col1 - CAST( NULL AS DECIMAL ) * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2601
SELECT ALL + col1 - CAST ( NULL AS REAL ) * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2602
SELECT DISTINCT - col2 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2602
SELECT DISTINCT - col2 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + col2 + - col1 * col1 AS col2 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT cor0.col1 * + col0 - col1 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2605
SELECT - CAST( NULL AS SIGNED ) * + cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2605
SELECT - CAST ( NULL AS INTEGER ) * + cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL col1 * - col0 - 56 * col2 FROM tab1 AS cor0
----
-3102
-3832
-6416

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2607
SELECT DISTINCT col1 - + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2607
SELECT DISTINCT col1 - + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + col1 * + 99 FROM tab0 AS cor0
----
8514
9009
9603

query I rowsort
SELECT DISTINCT - cor0.col2 * 41 + col2 FROM tab1 AS cor0
----
-2160
-2280
-3840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2610
SELECT col1 * + CAST( NULL AS SIGNED ) * + col2 - - col0 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-2610
SELECT col1 * + CAST ( NULL AS INTEGER ) * + col2 - - col0 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col0 + - col1 * + col2 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT - col2 + col0 * - col1 AS col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT col1 + - col2 * col1 * col1 FROM tab2 AS cor0
----
-10965
-25916
-90447

query I rowsort
SELECT DISTINCT - cor0.col1 * col1 + + col0 AS col1 FROM tab0 AS cor0
----
-7372
-8192
-9374

onlyif mysql # use DIV operator for integer division
query I rowsort label-2615
SELECT - - cor0.col0 + - col0 DIV + col2 col2 FROM tab0 AS cor0
----
0
24
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2615
SELECT - - cor0.col0 + - col0 / + col2 col2 FROM tab0 AS cor0
----
0
24
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-2616
SELECT col0 DIV + col1 + + col2 AS col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2616
SELECT col0 / + col1 + + col2 AS col0 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2617
SELECT + + cor0.col2 DIV + cor0.col2 + + col1 DIV - col0 AS col1 FROM tab0 cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-2617
SELECT + + cor0.col2 / + cor0.col2 + + col1 / - col0 AS col1 FROM tab0 cor0
----
-1
-2
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2618
SELECT + col0 + - col1 DIV col1 AS col2 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-2618
SELECT + col0 + - col1 / col1 AS col2 FROM tab2 AS cor0
----
6
77
78

query I rowsort
SELECT col0 * + col0 + - cor0.col0 FROM tab0 AS cor0
----
1190
552
7832

query I rowsort
SELECT - tab1.col2 + col1 * + col2 AS col0 FROM tab1
----
1152
1350
513

query I rowsort
SELECT ALL - col1 + tab2.col2 AS col1 FROM tab2
----
-33
-4
21

query I rowsort
SELECT DISTINCT - col1 * - col0 + - col0 FROM tab2
----
1264
210
4524

query I rowsort
SELECT DISTINCT - col0 + - col1 * - col1 AS col2 FROM tab2
----
210
3403
954

onlyif mysql # use DIV operator for integer division
query I rowsort label-2624
SELECT col0 * - col1 - tab0.col2 DIV col1 FROM tab0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-2624
SELECT col0 * - col1 - tab0.col2 / col1 FROM tab0
----
-2064
-3395
-8099

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT ( NULL ) IN ( col1 * col0 )
----

query I rowsort
SELECT tab0.col0 + col2 * col0 FROM tab0
----
70
7387
816

query I rowsort
SELECT - col1 * col2 + col1 AS col0 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT + col2 + - cor0.col0 * + col0 FROM tab0 AS cor0
----
-1224
-543
-7839

onlyif mysql # use DIV operator for integer division
query I rowsort label-2629
SELECT ALL - col1 DIV - col0 AS col0 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-2629
SELECT ALL - col1 / - col0 AS col0 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT col1 * + col2 + col0 AS col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT col2 + cor0.col2 * col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT col0 AS col0 FROM tab0 WHERE NOT ( NULL ) NOT IN ( - tab0.col0 * - col2 )
----

query I rowsort
SELECT 46 + - col0 * col0 FROM tab0
----
-1179
-530
-7875

query I rowsort
SELECT DISTINCT + - col1 * - col2 + - col1 * + col2 - - col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL col0 - col2 * col0 AS col2 FROM tab2 cor0
----
-182
-1950
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-2636
SELECT DISTINCT + col0 DIV col1 + - col2 * + col2 AS col0 FROM tab2 AS cor0
----
-1440
-675
-729

skipif mysql # not compatible
query I rowsort label-2636
SELECT DISTINCT + col0 / col1 + - col2 * + col2 AS col0 FROM tab2 AS cor0
----
-1440
-675
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-2637
SELECT col2 DIV + col1 + col0 FROM tab2
----
7
78
81

skipif mysql # not compatible
query I rowsort label-2637
SELECT col2 / + col1 + col0 FROM tab2
----
7
78
81

query I rowsort
SELECT ALL col0 + + col0 * col1 AS col1 FROM tab2
----
1422
224
4680

query I rowsort
SELECT ALL - col0 + + col0 * col1 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT tab2.col2 AS col1 FROM tab2, tab2 AS cor0 WHERE NULL <= NULL
----

query I rowsort
SELECT ALL tab0.col0 * col0 + col0 * col1 + col2 FROM tab0
----
16102
2673
4621

onlyif mysql # use DIV operator for integer division
query I rowsort label-2642
SELECT ALL - col0 DIV + col2 + col1 FROM tab0 AS cor0
----
62
86
90

skipif mysql # not compatible
query I rowsort label-2642
SELECT ALL - col0 / + col2 + col1 FROM tab0 AS cor0
----
62
86
90

query I rowsort
SELECT DISTINCT + col2 * - col1 + col2 * + col0 FROM tab2 AS cor0
----
-648
2356
494

query I rowsort
SELECT cor0.col2 - + cor0.col2 * col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 + + col0 col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - col2 * col1 + + col2 - - col0 * + col1 AS col2 FROM tab2 AS cor0
----
-593
3094
735

onlyif mysql # use DIV operator for integer division
query I rowsort label-2647
SELECT col0 DIV col2 + - col2 AS col0 FROM tab0
----
-33
-81
34

skipif mysql # not compatible
query I rowsort label-2647
SELECT col0 / col2 + - col2 AS col0 FROM tab0
----
-33
-81
34

query I rowsort
SELECT col0 * col0 * col0 FROM tab2
----
343
474552
493039

query I rowsort
SELECT ALL + col0 * + col1 AS col0 FROM tab0 WHERE ( NULL ) BETWEEN ( col1 ) AND + tab0.col2 * + col2
----

query I rowsort
SELECT ALL col2 FROM tab2 WHERE NOT + col0 NOT IN ( - tab2.col2 + col1 * - col0 * - col0 + tab2.col0 * col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2651
SELECT tab2.col2 + col1 DIV - col0 FROM tab2
----
23
26
38

skipif mysql # not compatible
query I rowsort label-2651
SELECT tab2.col2 + col1 / - col0 FROM tab2
----
23
26
38

query I rowsort
SELECT DISTINCT + tab0.col2 + + tab0.col2 AS col2 FROM tab0
----
164
2
66

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( + col1 + + col2 ) NOT BETWEEN NULL AND col1
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2654
SELECT - col2 DIV col1 + col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2654
SELECT - col2 / col1 + col1 FROM tab0
----
86
91
97

query I rowsort
SELECT tab0.col0 AS col2 FROM tab0 WHERE NOT col2 NOT BETWEEN + col1 AND NULL
----

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL <> + col1 + - col2
----

query I rowsort
SELECT col1 - col2 * col1 AS col0 FROM tab1
----
-1235
-1378
-560

query I rowsort
SELECT ALL col1 * col1 + + col1 FROM tab1
----
110
182
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-2659
SELECT DISTINCT col1 + + tab1.col0 DIV col0 FROM tab1 WHERE + col0 * col2 NOT IN ( col0 )
----
11
14
27

skipif mysql # not compatible
query I rowsort label-2659
SELECT DISTINCT col1 + + tab1.col0 / col0 FROM tab1 WHERE + col0 * col2 NOT IN ( col0 )
----
11
14
27

query I rowsort
SELECT col2 - col1 * col0 AS col0 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL + + col1 * col1 + col1 AS col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT ALL - col1 * col1 * tab2.col2 FROM tab2
----
-10982
-25947
-90506

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE col0 NOT BETWEEN - col0 * col2 AND NULL
----

query I rowsort
SELECT + col2 / col1 + col2 FROM tab2 AS cor0 WHERE col1 * - cor0.col0 IN ( col1 )
----

query I rowsort
SELECT + col0 * cor0.col2 AS col1 FROM tab2 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND - col0 + col0 / + col0
----

query III rowsort
SELECT * FROM tab1 cor0 WHERE NOT ( NULL ) >= ( NULL )
----

query I rowsort
SELECT - col2 FROM tab1 WHERE NOT NULL BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT + col2 * - col1 + col0 + - col2 FROM tab2
----
-1482
-605
-857

onlyif mysql # use DIV operator for integer division
query I rowsort label-2669
SELECT DISTINCT col0 DIV col0 + col1 AS col2 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-2669
SELECT DISTINCT col0 / col0 + col1 AS col2 FROM tab1
----
11
14
27

query I rowsort
SELECT DISTINCT col1 + - col0 * col0 FROM tab0
----
-1128
-490
-7830

query I rowsort
SELECT + col1 + col0 + + col1 * - col2 * col1 FROM tab1
----
-16131
-36475
-5626

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT col1 <> NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col2 + col1 col0 FROM tab2
----
55
58
85

query III rowsort
SELECT * FROM tab2 WHERE NOT col0 < col0 * tab2.col2
----

query I rowsort
SELECT ALL - tab1.col1 + - tab1.col2 AS col1 FROM tab1
----
-109
-67
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2676
SELECT DISTINCT col0 + - col2 DIV - col2 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-2676
SELECT DISTINCT col0 + - col2 / - col2 FROM tab1
----
4
65
81

query I rowsort
SELECT ALL + 90 + col0 * - ( + col2 + - col2 ) FROM tab2
----
90
90
90

query I rowsort
SELECT DISTINCT 70 * 19 AS col2 FROM tab1, tab0 AS cor0
----
1330

query I rowsort
SELECT + 92 * col0 * + 18 FROM tab2 cor0
----
11592
129168
130824

query I rowsort
SELECT + 56 * - col0 * - col2 AS col1 FROM tab0 AS cor0
----
1960
408688
44352

onlyif mysql # use DIV operator for integer division
query I rowsort label-2681
SELECT + - col1 DIV - col1 + - ( col1 ) * + col0 + - 58 FROM tab0 AS cor0
----
-2121
-3452
-8156

skipif mysql # not compatible
query I rowsort label-2681
SELECT + - col1 / - col1 + - ( col1 ) * + col0 + - 58 FROM tab0 AS cor0
----
-2121
-3452
-8156

query I rowsort
SELECT DISTINCT col2 + - ( 39 ) * col0 FROM tab0 AS cor0
----
-1364
-3389
-903

query I rowsort
SELECT - col1 * - 55 * + col2 FROM tab1 AS cor0
----
31350
68640
77220

query I rowsort
SELECT ALL - col1 + - 86 FROM tab0 AS cor0
----
-172
-177
-183

query I rowsort
SELECT DISTINCT + + col2 * 88 FROM tab1 AS cor0
----
4752
5016
8448

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2686
SELECT - col2 * + CAST( - 85 AS SIGNED ) FROM tab1 AS cor0
----
4590
4845
8160

skipif mysql # not compatible
query I rowsort label-2686
SELECT - col2 * + CAST ( - 85 AS INTEGER ) FROM tab1 AS cor0
----
4590
4845
8160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2687
SELECT + col2 * - CAST( col1 AS SIGNED ) * - cor0.col2 AS col2 FROM tab2 AS cor0
----
22599
24548
39884

skipif mysql # not compatible
query I rowsort label-2687
SELECT + col2 * - CAST ( col1 AS INTEGER ) * - cor0.col2 AS col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT 57 + - 5 AS col2 FROM tab0 AS cor0
----
52
52
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-2689
SELECT - + 73 DIV + col1 + + col2 col2 FROM tab2 AS cor0
----
25
25
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2689
SELECT - + 73 / + col1 + + col2 col2 FROM tab2 AS cor0
----
25
25
34

query I rowsort
SELECT 9 * col0 + - col1 - + col0 AS col2 FROM tab0 AS cor0
----
106
183
621

query I rowsort
SELECT + col2 * col0 + col0 * + cor0.col1 + col0 FROM tab2 AS cor0
----
413
4424
6708

query I rowsort
SELECT col1 + 64 - + col0 * ( ( col1 ) ) AS col0 FROM tab2 AS cor0
----
-122
-1262
-4479

query I rowsort
SELECT ALL col2 * col1 + col1 * col2 FROM tab2
----
1292
1674
3068

query I rowsort
SELECT ALL - col2 + + ( 11 ) FROM tab2
----
-15
-16
-27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col1 ) col2 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT + col2 * + cor0.col0 + col1 AS col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT + + ( + ( col2 ) ) * col2 + - col1 * - col2 FROM tab2 cor0
----
1566
2090
2210

query I rowsort
SELECT DISTINCT + cor0.col2 * col2 * 80 + - 43 FROM tab2 AS cor0
----
115477
54037
58277

query I rowsort
SELECT DISTINCT + 39 AS col1 FROM tab0 cor0
----
39

query I rowsort
SELECT 8 - cor0.col2 AS col0 FROM tab2 AS cor0
----
-18
-19
-30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 22 + + cor0.col0 col1 FROM tab2 AS cor0
----
-15
56
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2702
SELECT DISTINCT + cor0.col1 * col2 - CAST( - col0 AS SIGNED ) FROM tab2 AS cor0
----
1612
725
844

skipif mysql # not compatible
query I rowsort label-2702
SELECT DISTINCT + cor0.col1 * col2 - CAST ( - col0 AS INTEGER ) FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-2703
SELECT + + col2 DIV - col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2703
SELECT + + col2 / - col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - 75 + col2 * 7 AS col2 FROM tab2 AS cor0
----
107
114
191

query I rowsort
SELECT DISTINCT - - 63 AS col2 FROM tab1 cor0
----
63

query I rowsort
SELECT DISTINCT + col1 - + 55 FROM tab1
----
-29
-42
-45

query I rowsort
SELECT + tab2.col0 AS col0 FROM tab2, tab0, tab2 AS cor0, tab1
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query I rowsort
SELECT col0 + col0 + + col1 AS col1 FROM tab2
----
175
215
45

query I rowsort
SELECT DISTINCT 43 * + ( cor0.col1 ) AS col0 FROM tab1, tab2, tab0 AS cor0
----
3698
3913
4171

onlyif mysql # use DIV operator for integer division
query I rowsort label-2710
SELECT col2 * 85 DIV - col0 FROM tab1
----
-102
-1530
-75

skipif mysql # not compatible
query I rowsort label-2710
SELECT col2 * 85 / - col0 FROM tab1
----
-102
-1530
-75

query I rowsort
SELECT + ( - 67 ) AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to fbe03b15d6b951410b38f7e98895006f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2712
SELECT DISTINCT CAST( 12 AS SIGNED ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
12

skipif mysql # not compatible
query I rowsort label-2712
SELECT DISTINCT CAST ( 12 AS INTEGER ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
12

query I rowsort
SELECT - + 74 * cor0.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c4490650c0ebf9d27375b62fd0e5a5bd

onlyif mysql # use DIV operator for integer division
query I rowsort label-2714
SELECT + 44 DIV col1 - - 27 * + col2 FROM tab0 AS cor0
----
2214
27
891

skipif mysql # not compatible
query I rowsort label-2714
SELECT + 44 / col1 - - 27 * + col2 FROM tab0 AS cor0
----
2214
27
891

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( - col0 ) col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + col1 * col0 + + col2 * - col2 AS col2 FROM tab0 AS cor0
----
1375
3394
975

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 70 col0 FROM tab2 AS cor0
----
70
70
70

query I rowsort
SELECT 28 * - col1 - - col1 FROM tab2
----
-1593
-459
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-2719
SELECT col2 + col2 + - col0 * tab1.col0 DIV + col0 FROM tab1
----
105
112
50

skipif mysql # not compatible
query I rowsort label-2719
SELECT col2 + col2 + - col0 * tab1.col0 / + col0 FROM tab1
----
105
112
50

query I rowsort
SELECT ALL - cor0.col0 - - cor0.col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + 29 * 40 FROM tab1 cor0
----
1160
1160
1160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2722
SELECT ALL + CAST( cor0.col2 AS SIGNED ) * - col0 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-2722
SELECT ALL + CAST ( cor0.col2 AS INTEGER ) * - col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ( cor0.col1 ) + col1 * ( col2 + col2 ) AS col0 FROM tab1 cor0
----
1150
2509
2834

query I rowsort
SELECT ALL - - ( col0 ) - + col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT + 98 * 23 + - col0 FROM tab1 AS cor0
----
2174
2190
2251

query I rowsort
SELECT + - col0 + 27 AS col1 FROM tab2 cor0
----
-51
-52
20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2727
SELECT col1 * CAST( NULL AS SIGNED ) + - 82 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2727
SELECT col1 * CAST ( NULL AS INTEGER ) + - 82 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 + ( 59 ) AS col1 FROM tab0 AS cor0
----
-30
24
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2729
SELECT + col0 * + CAST( col0 AS SIGNED ) + col1 * + col1 - col0 FROM tab0 AS cor0
----
10599
16113
7948

skipif mysql # not compatible
query I rowsort label-2729
SELECT + col0 * + CAST ( col0 AS INTEGER ) + col1 * + col1 - col0 FROM tab0 AS cor0
----
10599
16113
7948

query I rowsort
SELECT DISTINCT - col0 * ( cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2731
SELECT DISTINCT - col0 * cor0.col1 DIV col1 col0 FROM tab2 AS cor0
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2731
SELECT DISTINCT - col0 * cor0.col1 / col1 col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + - cor0.col1 * 56 AS col2 FROM tab0 AS cor0
----
-4816
-5096
-5432

query I rowsort
SELECT + + col0 * ( 46 ) + + col2 + - col0 FROM tab1 cor0
----
189
2937
3696

query I rowsort
SELECT tab2.col2 + col1 * col0 AS col0 FROM tab2
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-2735
SELECT + col1 * + col1 - - 96 DIV + col1 FROM tab0
----
7397
8282
9409

skipif mysql # not compatible
query I rowsort label-2735
SELECT + col1 * + col1 - - 96 / + col1 FROM tab0
----
7397
8282
9409

query I rowsort
SELECT col1 + ( col0 ) * + col1 FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2737
SELECT col0 * - CAST( col0 AS SIGNED ) * col2 - 26 FROM tab0 AS cor0
----
-1251
-19034
-649548

skipif mysql # not compatible
query I rowsort label-2737
SELECT col0 * - CAST ( col0 AS INTEGER ) * col2 - 26 FROM tab0 AS cor0
----
-1251
-19034
-649548

query I rowsort
SELECT DISTINCT col2 * - 15 AS col2 FROM tab0 AS cor0
----
-1230
-15
-495

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 * - col0 col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL 45 * 88 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab2 cor2
----
81 values hashing to 0af6580d698f93e6dfa89dd19da0d8ea

query I rowsort
SELECT DISTINCT - cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
-7
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 col0 FROM tab1, tab0 AS cor0, tab2, tab1 AS cor1
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 89 col2 FROM tab2, tab1 AS cor0, tab0, tab0 AS cor1
----
81 values hashing to bb5bb13eab35a33bb4641905f5e7c9b6

query I rowsort
SELECT ALL + col2 + + ( + col0 ) * col1 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT + ( + cor0.col0 ) + col1 AS col0 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-2746
SELECT ALL col1 + - col0 DIV + col1 AS col1 FROM tab2 AS cor0
----
13
31
58

skipif mysql # not compatible
query I rowsort label-2746
SELECT ALL col1 + - col0 / + col1 AS col1 FROM tab2 AS cor0
----
13
31
58

query I rowsort
SELECT ALL 29 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT DISTINCT 99 * col1 FROM tab2 AS cor0
----
1683
3069
5841

onlyif mysql # use DIV operator for integer division
query I rowsort label-2749
SELECT ALL + col1 + - col0 DIV col1 FROM tab2 AS cor0
----
13
31
58

skipif mysql # not compatible
query I rowsort label-2749
SELECT ALL + col1 + - col0 / col1 FROM tab2 AS cor0
----
13
31
58

query I rowsort
SELECT DISTINCT - 27 * + col2 AS col2 FROM tab0 AS cor0
----
-2214
-27
-891

query I rowsort
SELECT + 84 + col0 * col2 FROM tab2 AS cor0
----
2112
273
3086

query I rowsort
SELECT DISTINCT 57 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2753
SELECT + CAST( + ( + col1 ) * ( - col1 ) AS SIGNED ) AS col1 FROM tab1
----
-100
-169
-676

skipif mysql # not compatible
query I rowsort label-2753
SELECT + CAST ( + ( + col1 ) * ( - col1 ) AS INTEGER ) AS col1 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT 32 - col0 FROM tab2
----
-46
-47
25

query I rowsort
SELECT DISTINCT + + 79 AS col2 FROM tab1, tab2, tab1 cor0
----
79

query I rowsort
SELECT col2 + col1 * ( 2 + + col1 ) AS col1 FROM tab0
----
7601
8545
9604

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2757
SELECT + + col0 * CAST( NULL AS DECIMAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2757
SELECT + + col0 * CAST ( NULL AS REAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2758
SELECT + CAST( NULL AS DECIMAL ) AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2758
SELECT + CAST ( NULL AS REAL ) AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + + col1 * 22 AS col0 FROM tab2 AS cor0
----
1298
374
682

query I rowsort
SELECT + col1 * ( ( - col0 ) * - col1 ) FROM tab0 AS cor0
----
177504
329315
737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-2761
SELECT ALL + col2 DIV - 24 + + ( col2 ) * ( + col0 ) FROM tab2 AS cor0
----
188
2027
3001

skipif mysql # not compatible
query I rowsort label-2761
SELECT ALL + col2 / - 24 + + ( col2 ) * ( + col0 ) FROM tab2 AS cor0
----
188
2027
3001

query I rowsort
SELECT ALL + 75 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

onlyif mysql # use DIV operator for integer division
query I rowsort label-2763
SELECT + col2 DIV 45 + tab1.col2 DIV 70 FROM tab1
----
1
1
3

skipif mysql # not compatible
query I rowsort label-2763
SELECT + col2 / 45 + tab1.col2 / 70 FROM tab1
----
1
1
3

query I rowsort
SELECT DISTINCT ( + col0 ) * + tab1.col0 AS col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT - - col2 + + col2 + col0 AS col0 FROM tab0 AS cor0
----
253
37
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2766
SELECT DISTINCT CAST( NULL AS SIGNED ) * 95 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2766
SELECT DISTINCT CAST ( NULL AS INTEGER ) * 95 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2767
SELECT ALL - CAST( - col1 AS SIGNED ) DIV + col2 col2 FROM tab0 AS cor0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2767
SELECT ALL - CAST ( - col1 AS INTEGER ) / + col2 col2 FROM tab0 AS cor0
----
1
2
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2768
SELECT - 98 DIV + 84 + col2 + col1 * ( cor0.col1 * col1 ) AS col2 FROM tab0 AS cor0
----
636088
753652
912673

skipif mysql # not compatible
query I rowsort label-2768
SELECT - 98 / + 84 + col2 + col1 * ( cor0.col1 * col1 ) AS col2 FROM tab0 AS cor0
----
636088
753652
912673

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( - col1 + col1 AS REAL ) * + col0 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT + col2 * col2 + - col2 FROM tab1 cor0
----
2862
3192
9120

query I rowsort
SELECT DISTINCT cor0.col1 + + col1 AS col2 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT DISTINCT - col1 * col1 * 31 + col2 AS col2 FROM tab2 AS cor0
----
-107885
-29764
-8921

query I rowsort
SELECT ALL 80 * - col0 - 45 AS col0 FROM tab2 AS cor0
----
-605
-6285
-6365

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col2 col0 FROM tab2 cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-2775
SELECT ALL 91 DIV col0 AS col0 FROM tab1 AS cor0
----
1
1
30

skipif mysql # not compatible
query I rowsort label-2775
SELECT ALL 91 / col0 AS col0 FROM tab1 AS cor0
----
1
1
30

query I rowsort
SELECT - + 60 * col1 + - col2 FROM tab0 AS cor0
----
-5193
-5542
-5821

query I rowsort
SELECT DISTINCT - col2 * - col1 + + col2 * cor0.col0 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT ALL + + col1 * col0 + col1 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT - cor0.col0 AS col2 FROM tab1, tab0, tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL - ( - col1 ) + - col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL ( - col1 ) + col1 + col0 FROM tab2
----
7
78
79

query I rowsort
SELECT - col1 + + col0 * + col0 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT - + col0 * cor0.col0 + + 40 FROM tab1 AS cor0
----
-4056
-6360
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col0 * - 34 * + col0 col0 FROM tab1
----
139264
217600
306

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2785
SELECT DISTINCT + col2 * - col2 * col1 - CAST( - col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-611802
-93621
-96

skipif mysql # not compatible
query I rowsort label-2785
SELECT DISTINCT + col2 * - col2 * col1 - CAST ( - col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-611802
-93621
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 89 + - col2 col2 FROM tab0 AS cor0
----
56
7
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-2787
SELECT - col1 - col0 DIV cor0.col0 col0 FROM tab2 AS cor0
----
-18
-32
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2787
SELECT - col1 - col0 / cor0.col0 col0 FROM tab2 AS cor0
----
-18
-32
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-2788
SELECT ALL - col0 - ( col0 ) DIV col2 AS col0 FROM tab1
----
-3
-65
-80

skipif mysql # not compatible
query I rowsort label-2788
SELECT ALL - col0 - ( col0 ) / col2 AS col0 FROM tab1
----
-3
-65
-80

query I rowsort
SELECT 41 FROM tab1, tab0 cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT ALL 35 + - col1 * col1 AS col0 FROM tab0
----
-7361
-8246
-9374

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2791
SELECT DISTINCT - CAST( + 63 AS SIGNED ) * + col2 * col0 + col1 * col0 FROM tab0
----
-451675
-47832
1190

skipif mysql # not compatible
query I rowsort label-2791
SELECT DISTINCT - CAST ( + 63 AS INTEGER ) * + col2 * col0 + col1 * col0 FROM tab0
----
-451675
-47832
1190

query I rowsort
SELECT ALL - 30 AS col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to a96370a8187089b6b83ce9bfbade5142

query I rowsort
SELECT - 28 + - col1 FROM tab0
----
-114
-119
-125

query I rowsort
SELECT ALL col0 * col1 + col2 * - 77 FROM tab2
----
-1583
-1862
2600

query I rowsort
SELECT DISTINCT + cor0.col1 + + col1 AS col1 FROM tab1 cor0
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2796
SELECT CAST( NULL AS SIGNED ) - - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2796
SELECT CAST ( NULL AS INTEGER ) - - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2797
SELECT DISTINCT - CAST( + 3 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-3

skipif mysql # not compatible
query I rowsort label-2797
SELECT DISTINCT - CAST ( + 3 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-2798
SELECT ( col0 ) + - col1 DIV col0 FROM tab0 AS cor0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-2798
SELECT ( col0 ) + - col1 / col0 FROM tab0 AS cor0
----
21
33
88

query I rowsort
SELECT DISTINCT - + cor0.col1 AS col0 FROM tab1, tab2 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT - 6 + tab0.col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to b1c02e7e52c5c0935fb798de98c56d46

query I rowsort
SELECT ALL - col2 * tab2.col1 * ( + 68 ) AS col2 FROM tab2
----
-104312
-43928
-56916

query I rowsort
SELECT ALL 62 AS col1 FROM tab2
----
62
62
62

query I rowsort
SELECT DISTINCT + 39 FROM tab1, tab2 AS cor0, tab2 AS cor1, tab1 AS cor2
----
39

query I rowsort
SELECT - - ( col0 ) * + col1 + - col0 AS col1 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT - + 62 FROM tab2 AS cor0
----
-62
-62
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2807
SELECT col2 + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2807
SELECT col2 + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2808
SELECT - + col2 - - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2808
SELECT - + col2 - - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * + 53 - + col2 * + cor0.col0 FROM tab0 cor0
----
-2952
18
957

query I rowsort
SELECT - col0 - - cor0.col1 * cor0.col2 AS col1 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT ALL + col1 * + 0 - - col1 AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + col2 * + 63 + col0 FROM tab2 AS cor0
----
1708
1716
2473

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2813
SELECT ALL col2 * 75 + + col1 - + col0 * CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2813
SELECT ALL col2 * 75 + + col1 - + col0 * CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + 37 * - 68 FROM tab0 AS cor0
----
-2434
-2483
-2515

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * 76 col2 FROM tab0 AS cor0
----
2508
6232
76

query I rowsort
SELECT ALL - - col1 * + 4 + + col2 FROM tab2 AS cor0
----
106
151
262

query I rowsort
SELECT + 45 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT + col1 + 48 FROM tab1
----
58
61
74

query I rowsort
SELECT ALL + col1 + - ( col2 ) * - col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL + + col1 + 21 * + col0 * + col1 FROM tab0 AS cor0
----
170170
43430
71392

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * + 83 col1 FROM tab2 cor0
----
-1411
-2573
-4897

query I rowsort
SELECT DISTINCT - cor1.col2 AS col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
-26
-27
-38

query I rowsort
SELECT ALL + cor1.col0 AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + col1 + ( - col1 ) AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - col2 * - col0 + + col1 * col2 FROM tab0 AS cor0
----
132
14760
3630

query I rowsort
SELECT ALL col1 * cor0.col1 + col0 AS col2 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT DISTINCT 61 * 33 AS col0 FROM tab2 AS cor0
----
2013

query I rowsort
SELECT - col1 * col2 - - col2 AS col0 FROM tab1 cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL - 21 + col1 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-2085
-3416
-8120

query I rowsort
SELECT DISTINCT - col1 * col2 - col0 AS col0 FROM tab2 AS cor0
----
-1612
-725
-844

onlyif mysql # use DIV operator for integer division
query I rowsort label-2831
SELECT ALL ( col2 ) DIV col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2831
SELECT ALL ( col2 ) / col0 FROM tab0 AS cor0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2832
SELECT DISTINCT - + CAST( NULL AS SIGNED ) * + col2 * col0 col2 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2832
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) * + col2 * col0 col2 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col0 ) - col1 col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT - - col0 - - 56 AS col0 FROM tab0 AS cor0
----
145
80
91

query I rowsort
SELECT + col0 * col0 - + cor0.col1 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT ALL + col2 * 76 AS col0 FROM tab0 AS cor0
----
2508
6232
76

query I rowsort
SELECT 91 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2838
SELECT + col0 - ( col1 ) * col0 * CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2838
SELECT + col0 - ( col1 ) * col0 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * + col0 - - col1 * + col0 AS col2 FROM tab1
----
240
4288
8720

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + + col0 + col2 / + CAST ( col2 AS REAL ) AS col2 FROM tab0 AS cor0
----
25
36
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2841
SELECT - cor0.col2 DIV + col1 + cor0.col1 AS col2 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2841
SELECT - cor0.col2 / + col1 + cor0.col1 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + - 87 AS col0 FROM tab0 AS cor0
----
-87
-87
-87

query I rowsort
SELECT ALL + - col0 * col1 AS col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - col0 + col2 * col2 * + cor0.col0 FROM tab2 AS cor0
----
113997
5096
52650

onlyif mysql # use DIV operator for integer division
query I rowsort label-2845
SELECT - col0 + + col0 + + ( 42 ) DIV col0 FROM tab0 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-2845
SELECT - col0 + + col0 + + ( 42 ) / col0 FROM tab0 AS cor0
----
0
1
1

query I rowsort
SELECT DISTINCT + + col1 * - cor0.col2 * col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-2847
SELECT DISTINCT + 66 DIV 34 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-2847
SELECT DISTINCT + 66 / 34 FROM tab1
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2848
SELECT DISTINCT tab0.col2 DIV tab0.col2 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-2848
SELECT DISTINCT tab0.col2 / tab0.col2 FROM tab0
----
1

query I rowsort
SELECT - + 0 + - col0 * col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT + col0 * + col0 + - col1 * col2 * - col1 FROM tab0
----
10634
244644
686963

query I rowsort
SELECT ( tab0.col2 ) + - col2 * - ( + 87 ) FROM tab0
----
2904
7216
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2852
SELECT - CAST( 94 + col1 AS SIGNED ) FROM tab2
----
-111
-125
-153

skipif mysql # not compatible
query I rowsort label-2852
SELECT - CAST ( 94 + col1 AS INTEGER ) FROM tab2
----
-111
-125
-153

query I rowsort
SELECT ALL - tab0.col1 + 10 AS col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to b2ef474779fc2c543f2187d33fba1441

query I rowsort
SELECT 28 * + tab0.col0 + tab0.col2 FROM tab0
----
2574
705
981

query I rowsort
SELECT 38 + col0 * tab2.col1 FROM tab2
----
1381
255
4640

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2856
SELECT DISTINCT CAST( + col0 AS SIGNED ) * tab1.col1 AS col0 FROM tab1
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-2856
SELECT DISTINCT CAST ( + col0 AS INTEGER ) * tab1.col1 AS col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL ( - 43 ) + + col0 FROM tab2 cor0
----
-36
35
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * col0 * - col0 col1 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT DISTINCT - col1 * col0 * ( ( col1 ) * col1 ) AS col2 FROM tab2 AS cor0
----
-16019562
-208537
-388127

query I rowsort
SELECT + cor0.col1 * cor0.col1 + 89 FROM tab1 AS cor0
----
189
258
765

query I rowsort
SELECT DISTINCT - - 65 AS col2 FROM tab1 AS cor0
----
65

query I rowsort
SELECT ALL ( + col0 ) * + col1 + + col1 AS col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT + col1 * - col0 + - 81 AS col2 FROM tab0 cor0
----
-2145
-3476
-8180

query I rowsort
SELECT ALL + + 19 AS col2 FROM tab2 AS cor0
----
19
19
19

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

query I rowsort
SELECT ALL 75 + - col1 AS col2 FROM tab0 AS cor0
----
-11
-16
-22

query I rowsort
SELECT DISTINCT col1 * - col1 * + 57 + col0 * - 72 FROM tab2 cor0
----
-204033
-22161
-55281

query I rowsort
SELECT ALL - col0 - - ( + cor0.col1 ) AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL - 54 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4ecdb0f1b85f0d4fdc3a826efd9f2342

query I rowsort
SELECT + col1 * col0 + - ( - col2 ) AS col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT - - col2 * + 68 FROM tab1 cor0
----
3672
3876
6528

onlyif mysql # use DIV operator for integer division
query I rowsort label-2872
SELECT DISTINCT col1 * col2 DIV - 6 col0 FROM tab0 AS cor0
----
-1243
-16
-473

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2872
SELECT DISTINCT col1 * col2 / - 6 col0 FROM tab0 AS cor0
----
-1243
-16
-473

query I rowsort
SELECT col1 + - ( 66 * cor0.col0 + col1 * - col0 ) AS col0 FROM tab2 AS cor0
----
-214
-3854
-487

query I rowsort
SELECT DISTINCT + col1 * + ( - col1 ) FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + col2 + col1 * col1 AS col0 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT + col2 + + 60 AS col0 FROM tab2 AS cor0
----
86
87
98

query I rowsort
SELECT + + 8 * - col2 AS col0 FROM tab2 AS cor0
----
-208
-216
-304

query I rowsort
SELECT ALL - 58 * col0 FROM tab0 AS cor0
----
-1392
-2030
-5162

query I rowsort
SELECT DISTINCT - + 16 AS col0 FROM tab2 AS cor0
----
-16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * - ( + col2 + col0 ) * - 35 col0 FROM tab0 AS cor0
----
-122220
-171570
-544635

query I rowsort
SELECT + ( - 10 ) * - col2 AS col1 FROM tab2 AS cor0
----
260
270
380

query I rowsort
SELECT - cor1.col0 + 60 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1, tab0 cor1
----
27 values hashing to f771217bebfb5373e98c6c77fb487b48

query I rowsort
SELECT ALL col2 + + 25 FROM tab0
----
107
26
58

query I rowsort
SELECT col2 * - 7 + col1 AS col2 FROM tab1 cor0
----
-352
-389
-659

query I rowsort
SELECT - ( - col2 ) * + col2 AS col2 FROM tab2 AS cor0
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) + - col0 col0 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2887
SELECT - CAST( NULL AS SIGNED ) + - col0 / col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2887
SELECT - CAST ( NULL AS INTEGER ) + - col0 / col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * ( col1 ) col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT - ( col1 ) + - col2 * 56 * + col2 AS col2 FROM tab1 AS cor0
----
-163322
-181954
-516109

onlyif mysql # use DIV operator for integer division
query I rowsort label-2890
SELECT col2 DIV + ( - col2 ) FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2890
SELECT col2 / + ( - col2 ) FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - 95 + - col2 * col2 AS col0 FROM tab0 AS cor0
----
-1184
-6819
-96

query I rowsort
SELECT + ( + cor0.col2 ) AS col1 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT + cor0.col0 * col2 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
114076
5103
52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-2894
SELECT - ( 22 ) + col1 DIV col0 AS col1 FROM tab1 AS cor0
----
-14
-22
-22

skipif mysql # not compatible
query I rowsort label-2894
SELECT - ( 22 ) + col1 / col0 AS col1 FROM tab1 AS cor0
----
-14
-22
-22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 - + cor0.col2 col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL - 20 FROM tab0, tab2 cor0
----
9 values hashing to f1cccb95c90889319e7a51e4ae9475bb

onlyif mysql # use DIV operator for integer division
query I rowsort label-2897
SELECT - cor0.col2 DIV cor0.col0 AS col2 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-2897
SELECT - cor0.col2 / cor0.col0 AS col2 FROM tab2 AS cor0
----
-3
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + col2 * col0 * - col1 col0 FROM tab2 cor0
----
-119626
-50996
-5832

query I rowsort
SELECT DISTINCT + ( + 11 ) * tab2.col1 AS col1 FROM tab2
----
187
341
649

onlyif mysql # use DIV operator for integer division
query I rowsort label-2900
SELECT + cor0.col1 DIV 22 + - col1 FROM tab0 cor0
----
-83
-87
-93

skipif mysql # not compatible
query I rowsort label-2900
SELECT + cor0.col1 / 22 + - col1 FROM tab0 cor0
----
-83
-87
-93

query I rowsort
SELECT ALL 73 + col1 * 18 FROM tab0
----
1621
1711
1819

query I rowsort
SELECT ALL + col2 * - ( col1 ) + + col0 FROM tab2 AS cor0
----
-1456
-567
-830

onlyif mysql # use DIV operator for integer division
query I rowsort label-2903
SELECT + col1 DIV - 60 + + col0 AS col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-2903
SELECT + col1 / - 60 + + col0 AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - col0 - col0 FROM tab0 cor0
----
-178
-48
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2905
SELECT + col1 * CAST( NULL AS DECIMAL ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2905
SELECT + col1 * CAST ( NULL AS REAL ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col0 + cor0.col0 AS col1 FROM tab1 AS cor0
----
128
160
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 74 * cor0.col0 + + cor0.col1 col0 FROM tab2 AS cor0
----
-487
-5713
-5829

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 38 col1 FROM tab2 AS cor0
----
38
38
38

query I rowsort
SELECT + 15 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT - ( 13 ) AS col2 FROM tab0
----
-13
-13
-13

onlyif mysql # use DIV operator for integer division
query I rowsort label-2911
SELECT ALL - 59 DIV + col1 FROM tab1
----
-2
-4
-5

skipif mysql # not compatible
query I rowsort label-2911
SELECT ALL - 59 / + col1 FROM tab1
----
-2
-4
-5

query I rowsort
SELECT + 60 * + col0 AS col2 FROM tab0
----
1440
2100
5340

query I rowsort
SELECT ALL - tab2.col0 + 72 FROM tab2, tab2 AS cor0
----
9 values hashing to 5a9714648b5bb2bd50f56da4455612e7

query I rowsort
SELECT DISTINCT - 77 * - col1 - - col2 * - col1 AS col0 FROM tab1
----
-247
200
598

query I rowsort
SELECT DISTINCT - 86 - col2 FROM tab1
----
-140
-143
-182

query I rowsort
SELECT DISTINCT 83 * + tab2.col1 AS col2 FROM tab2
----
1411
2573
4897

query I rowsort
SELECT col1 - - col0 * - ( col1 + cor0.col0 ) FROM tab0 AS cor0
----
-15929
-2554
-4523

query I rowsort
SELECT - 79 + - col1 * - 64 - - col2 FROM tab2
----
1047
1932
3723

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 1 * - col1 col2 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT col0 + col2 + + ( col1 ) FROM tab0
----
133
143
262

query I rowsort
SELECT DISTINCT cor0.col1 - - 2 FROM tab0, tab2 AS cor0
----
19
33
61

query I rowsort
SELECT ALL - 75 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c0722b1d77ac0ed13c0f2691a5751c59

query I rowsort
SELECT DISTINCT 12 AS col1 FROM tab2, tab0 AS cor0
----
12

query I rowsort
SELECT DISTINCT - tab1.col2 + - 65 FROM tab1, tab0, tab1 AS cor0
----
-119
-122
-161

query I rowsort
SELECT - col1 * - col1 + + col1 AS col0 FROM tab2 AS cor0
----
306
3540
992

onlyif mysql # use DIV operator for integer division
query I rowsort label-2926
SELECT + 1 DIV + col0 + col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2926
SELECT + 1 / + col0 + col1 FROM tab0
----
86
91
97

query I rowsort
SELECT 40 AS col0 FROM tab2 AS cor0
----
40
40
40

query I rowsort
SELECT - - 29 + - col1 AS col2 FROM tab1 cor0
----
16
19
3

query I rowsort
SELECT ALL col2 * + col0 + col1 * + col1 FROM tab1 AS cor0
----
3748
7849
838

onlyif mysql # use DIV operator for integer division
query I rowsort label-2930
SELECT DISTINCT + + CAST( - cor0.col1 AS SIGNED ) * col2 + - ( col1 ) DIV col2 AS col0 FROM tab0 AS cor0
----
-194
-2840
-7463

skipif mysql # not compatible
query I rowsort label-2930
SELECT DISTINCT + + CAST ( - cor0.col1 AS INTEGER ) * col2 + - ( col1 ) / col2 AS col0 FROM tab0 AS cor0
----
-194
-2840
-7463

query I rowsort
SELECT - - col2 * 34 * + col0 AS col1 FROM tab2 AS cor0
----
102068
6426
68952

query I rowsort
SELECT - + col0 * ( + col1 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT 93 + - col2 AS col2 FROM tab1
----
-3
36
39

query I rowsort
SELECT DISTINCT + col2 * ( col1 ) FROM tab0
----
2838
7462
97

query I rowsort
SELECT + col0 + + col1 * col0 FROM tab1
----
1120
704
81

query I rowsort
SELECT ALL - col0 * + col1 * col2 FROM tab1
----
-36480
-4212
-99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2937
SELECT ALL CAST( tab2.col2 AS SIGNED ) FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-2937
SELECT ALL CAST ( tab2.col2 AS INTEGER ) FROM tab2
----
26
27
38

query I rowsort
SELECT 37 + ( - col0 ) AS col1 FROM tab0
----
-52
13
2

query I rowsort
SELECT DISTINCT - - ( + col0 ) * col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT + - 97 * col0 FROM tab1 AS cor0
----
-291
-6208
-7760

query I rowsort
SELECT ALL - 48 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to 31c94943c073954e4ca20b170ab61f8c

query I rowsort
SELECT 72 + - col2 FROM tab2
----
34
45
46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 90 * + 24 col1 FROM tab1 AS cor0
----
2160
2160
2160

query I rowsort
SELECT + cor0.col0 * ( + col2 * + col1 ) + col2 FROM tab2 AS cor0
----
119678
51072
5886

query I rowsort
SELECT ALL 72 + - col2 FROM tab2 AS cor0
----
34
45
46

query I rowsort
SELECT ALL - col2 + + col0 * + col0 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT DISTINCT - col0 + + cor0.col1 + - col0 AS col1 FROM tab2 AS cor0
----
-141
-97
17

query I rowsort
SELECT DISTINCT + col2 * + col1 + cor0.col0 * col0 * - col1 AS col2 FROM tab1 AS cor0
----
-40390
-81952
1170

query I rowsort
SELECT ALL + ( cor0.col0 ) * + col1 * - col2 - col0 FROM tab1 AS cor0
----
-36544
-4215
-99920

query I rowsort
SELECT ALL - col1 - col1 * + col0 AS col0 FROM tab2 AS cor0
----
-1360
-248
-4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 39 col1 FROM tab2 AS cor0
----
-39
-39
-39

query I rowsort
SELECT + - 9 * - col1 * col2 FROM tab1 cor0
----
11232
12636
5130

query I rowsort
SELECT DISTINCT - 7 AS col2 FROM tab2 AS cor0
----
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 + col1 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 + - col0 * col2 AS col2 FROM tab1 cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT - 50 + - col0 AS col1 FROM tab2 cor0
----
-128
-129
-57

query I rowsort
SELECT ALL col1 + + col2 * col1 FROM tab0 AS cor0
----
194
2924
7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - cor0.col1 * col1 col0 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT ALL + + 89 * - col2 + col2 AS col1 FROM tab2 AS cor0
----
-2288
-2376
-3344

query I rowsort
SELECT + col1 * 22 + cor0.col1 FROM tab0 AS cor0
----
1978
2093
2231

query I rowsort
SELECT ALL cor1.col0 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2, tab0 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT - col2 + + ( - col2 ) - col2 AS col1 FROM tab0
----
-246
-3
-99

query I rowsort
SELECT col2 * ( tab2.col1 ) AS col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT + col2 * + ( + ( + col1 ) ) + - col2 FROM tab2 AS cor0
----
1508
608
810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - 35 col0 FROM tab1 AS cor0
----
-1890
-1995
-3360

query I rowsort
SELECT + + col1 * + ( cor0.col2 * col0 ) + - col2 + col1 * + col2 FROM tab0 AS cor0
----
3491
671498
70917

onlyif mysql # use DIV operator for integer division
query I rowsort label-2967
SELECT col2 + + ( - col0 ) * col1 DIV col1 AS col2 FROM tab0 AS cor0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-2967
SELECT col2 + + ( - col0 ) * col1 / col1 AS col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + col0 + ( ( + col2 ) ) * + col0 AS col2 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-2969
SELECT - col1 * 54 DIV col2 FROM tab1 AS cor0
----
-26
-7
-9

skipif mysql # not compatible
query I rowsort label-2969
SELECT - col1 * 54 / col2 FROM tab1 AS cor0
----
-26
-7
-9

query I rowsort
SELECT + col2 * cor0.col0 + 96 * + col2 AS col1 FROM tab1 cor0
----
16896
5346
9120

query I rowsort
SELECT ALL + + col1 + 24 FROM tab1 AS cor0
----
34
37
50

query I rowsort
SELECT DISTINCT - - col0 * - col1 + 54 + col0 FROM tab0 AS cor0
----
-1986
-3306
-7956

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2973
SELECT ALL CAST( NULL AS SIGNED ) * - col2 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2973
SELECT ALL CAST ( NULL AS INTEGER ) * - col2 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2974
SELECT DISTINCT - - col0 DIV col2 AS col1 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-2974
SELECT DISTINCT - - col0 / col2 AS col1 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT ALL - - col0 * 89 * col2 FROM tab2 AS cor0
----
16821
180492
267178

query I rowsort
SELECT DISTINCT - ( 79 ) + col2 FROM tab2 AS cor0
----
-41
-52
-53

query I rowsort
SELECT ALL col1 + 93 + - col2 FROM tab2
----
126
72
97

query I rowsort
SELECT DISTINCT cor1.col2 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab2 AS cor2
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2979
SELECT - col0 DIV + col0 + col0 * tab0.col0 AS col1 FROM tab0
----
1224
575
7920

skipif mysql # not compatible
query I rowsort label-2979
SELECT - col0 / + col0 + col0 * tab0.col0 AS col1 FROM tab0
----
1224
575
7920

query I rowsort
SELECT + col1 * 79 + 10 FROM tab2 AS cor0
----
1353
2459
4671

query I rowsort
SELECT cor0.col1 * cor0.col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - tab0.col2 AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT DISTINCT + 48 FROM tab2, tab1, tab1 AS cor0
----
48

query I rowsort
SELECT DISTINCT - tab1.col1 + tab1.col0 + 5 AS col1 FROM tab1, tab0 AS cor0
----
-18
59
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-2985
SELECT ALL - col2 DIV col0 + - col2 FROM tab2 AS cor0
----
-26
-30
-38

skipif mysql # not compatible
query I rowsort label-2985
SELECT ALL - col2 / col0 + - col2 FROM tab2 AS cor0
----
-26
-30
-38

query I rowsort
SELECT ALL + col1 + + 8 FROM tab0 AS cor0
----
105
94
99

query I rowsort
SELECT DISTINCT + col2 + + ( + 89 + - col2 ) AS col0 FROM tab2 AS cor0
----
89

query I rowsort
SELECT ALL cor0.col0 + - ( - 92 ) AS col1 FROM tab2 AS cor0
----
170
171
99

query I rowsort
SELECT DISTINCT - + col2 + + ( + col1 ) * col0 FROM tab1 AS cor0
----
24
583
944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2990
SELECT + col0 * CAST( NULL AS SIGNED ) * col2 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2990
SELECT + col0 * CAST ( NULL AS INTEGER ) * col2 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col0 + 95 FROM tab2 AS cor0
----
16
17
88

query I rowsort
SELECT ALL + + cor0.col0 + 79 * 29 * + col1 AS col1 FROM tab2 AS cor0
----
135247
39026
71028

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2993
SELECT DISTINCT + cor0.col1 + - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2993
SELECT DISTINCT + cor0.col1 + - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + col1 + ( col0 ) * - col2 * + col1 AS col1 FROM tab0 AS cor0
----
-3298
-664027
-68026

query I rowsort
SELECT DISTINCT - cor0.col0 + ( col2 ) AS col1 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2996
SELECT - ( col0 + + col0 ) * - CAST( NULL AS SIGNED ) * 82 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2996
SELECT - ( col0 + + col0 ) * - CAST ( NULL AS INTEGER ) * 82 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab0.col2 + - ( - col1 * 24 ) FROM tab0
----
2097
2266
2329

query I rowsort
SELECT DISTINCT 78 + tab1.col2 FROM tab1
----
132
135
174

query I rowsort
SELECT ( col0 ) * col1 - - ( + col0 ) AS col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT + 88 + col2 AS col1 FROM tab1 cor0
----
142
145
184

query I rowsort
SELECT ALL - - 28 * 49 * + col0 FROM tab2 AS cor0
----
107016
108388
9604

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 74 col0 FROM tab0 AS cor0
----
-74

query I rowsort
SELECT - - col2 + col2 * + col1 AS col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT + + col1 * + 10 AS col1 FROM tab1 AS cor0
----
100
130
260

query I rowsort
SELECT - col0 * 77 - col0 AS col1 FROM tab0 AS cor0
----
-1872
-2730
-6942

onlyif mysql # use DIV operator for integer division
query I rowsort label-3006
SELECT col0 DIV 63 + col1 AS col0 FROM tab2
----
18
31
60

skipif mysql # not compatible
query I rowsort label-3006
SELECT col0 / 63 + col1 AS col0 FROM tab2
----
18
31
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - 47 ) * tab1.col1 col0 FROM tab1
----
1222
470
611

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col2 - - col2 col0 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT 29 * col2 FROM tab0 AS cor0
----
2378
29
957

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + cor0.col2 + col2 col1 FROM tab2 AS cor0
----
-7
23
59

query I rowsort
SELECT DISTINCT - + 28 + cor0.col2 FROM tab0 AS cor0
----
-27
5
54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3012
SELECT + CAST( - 72 AS SIGNED ) col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to b7689a8218ac9df1cca20d2ba5c53888

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3012
SELECT + CAST ( - 72 AS INTEGER ) col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to b7689a8218ac9df1cca20d2ba5c53888

query I rowsort
SELECT + col1 * col0 + col1 * + col1 FROM tab0 AS cor0
----
12804
16380
9460

query I rowsort
SELECT - col0 * col0 * + col2 FROM tab2
----
-1323
-158184
-237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-3015
SELECT DISTINCT - + 86 + + col2 DIV col1 AS col1 FROM tab1 AS cor0
----
-79
-81
-84

skipif mysql # not compatible
query I rowsort label-3015
SELECT DISTINCT - + 86 + + col2 / col1 AS col1 FROM tab1 AS cor0
----
-79
-81
-84

query I rowsort
SELECT ALL - - col0 * + col1 + 27 AS col2 FROM tab0 AS cor0
----
2091
3422
8126

query I rowsort
SELECT ALL 94 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3018
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col0 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-3018
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col0 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
NULL

query I rowsort
SELECT ALL + 70 AS col2 FROM tab2 cor0
----
70
70
70

query I rowsort
SELECT + 14 + col1 + col1 * + col1 * cor0.col1 FROM tab1 AS cor0
----
1024
17616
2224

query I rowsort
SELECT + 86 - col1 * + 76 FROM tab1 cor0
----
-1890
-674
-902

query I rowsort
SELECT cor0.col1 + col0 + - 34 AS col0 FROM tab2 AS cor0
----
103
4
62

query I rowsort
SELECT - + ( col2 ) * col1 + 88 FROM tab1 AS cor0
----
-1160
-1316
-482

query I rowsort
SELECT + 38 * - col0 - col0 FROM tab2 AS cor0
----
-273
-3042
-3081

query I rowsort
SELECT col2 * + cor0.col0 + - 23 * - col0 + - col1 FROM tab2 AS cor0
----
319
3763
4802

query I rowsort
SELECT cor0.col2 * ( col1 + col0 ) AS col0 FROM tab0 cor0
----
132
14760
3630

query I rowsort
SELECT DISTINCT ( + col1 + + col1 ) AS col2 FROM tab1
----
20
26
52

query I rowsort
SELECT ALL - ( - col1 ) * + ( + 27 ) AS col1 FROM tab1
----
270
351
702

query I rowsort
SELECT tab2.col0 + + tab2.col0 AS col1 FROM tab2
----
14
156
158

query I rowsort
SELECT DISTINCT 25 AS col0 FROM tab2, tab2 cor0
----
25

query I rowsort
SELECT - col2 * + 66 * col0 FROM tab1 AS cor0
----
-10692
-240768
-506880

query I rowsort
SELECT + col0 * 7 AS col2 FROM tab1 AS cor0
----
21
448
560

query I rowsort
SELECT cor2.col1 AS col2 FROM tab1, tab2 cor0, tab0 cor1, tab2 cor2
----
81 values hashing to a5b6acb471910ea4ad7f31cae3b818f7

query I rowsort
SELECT - ( - col1 ) * + col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT cor1.col1 + + 31 AS col2 FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to 289626c4ce7ff1ad149257cf2e75693e

query I rowsort
SELECT DISTINCT + 13 AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
13

query I rowsort
SELECT - col1 + - col1 * col2 + + 54 AS col1 FROM tab2
----
-1539
-609
-814

query I rowsort
SELECT DISTINCT - col1 + - ( + col1 * - col0 ) + - col0 FROM tab0
----
1954
3263
7919

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3039
SELECT ALL - tab1.col1 * + col2 * - col1 + CAST( tab1.col2 + - col1 AS SIGNED ) AS col2 FROM tab1
----
16307
36532
5747

skipif mysql # not compatible
query I rowsort label-3039
SELECT ALL - tab1.col1 * + col2 * - col1 + CAST ( tab1.col2 + - col1 AS INTEGER ) AS col2 FROM tab1
----
16307
36532
5747

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3040
SELECT + CAST( NULL AS SIGNED ) * col1 + - col1 * CAST( NULL AS DECIMAL ) + 40 col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3040
SELECT + CAST ( NULL AS INTEGER ) * col1 + - col1 * CAST ( NULL AS REAL ) + 40 col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + 50 + col1 + 24 FROM tab2 AS cor0
----
105
133
91

query I rowsort
SELECT - ( + col1 ) * + col0 AS col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + 5 * - col2 AS col2 FROM tab2
----
-130
-135
-190

query I rowsort
SELECT ALL 57 + - col1 + + col2 FROM tab1
----
104
140
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col1 col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3046
SELECT - - CAST( 12 AS SIGNED ) + - cor0.col2 AS col1 FROM tab2 AS cor0
----
-14
-15
-26

skipif mysql # not compatible
query I rowsort label-3046
SELECT - - CAST ( 12 AS INTEGER ) + - cor0.col2 AS col1 FROM tab2 AS cor0
----
-14
-15
-26

query I rowsort
SELECT - - cor0.col0 * - ( + col0 ) AS col0 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT + ( + 2 ) AS col0 FROM tab2 AS cor0
----
2
2
2

query I rowsort
SELECT - ( col2 ) + col2 * - ( col1 ) FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT ALL + cor0.col0 * 26 + + col1 AS col0 FROM tab2 cor0
----
2071
2087
213

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( - col0 AS REAL ) col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT col0 * 96 + cor0.col0 AS col0 FROM tab2 cor0
----
679
7566
7663

query I rowsort
SELECT 51 + + col0 * col1 FROM tab2 AS cor0
----
1394
268
4653

query I rowsort
SELECT - 67 * - ( + col1 ) AS col2 FROM tab2 AS cor0
----
1139
2077
3953

query I rowsort
SELECT DISTINCT + 54 * col0 FROM tab2 AS cor0
----
378
4212
4266

query I rowsort
SELECT ALL + col1 + - col0 * 74 AS col0 FROM tab0 cor0
----
-1690
-2493
-6495

query I rowsort
SELECT 44 * - col1 FROM tab2 AS cor0
----
-1364
-2596
-748

query I rowsort
SELECT DISTINCT ( ( - col1 ) ) * 30 * + col1 AS col2 FROM tab1
----
-20280
-3000
-5070

query I rowsort
SELECT - 34 + col2 * + col1 AS col1 FROM tab0
----
2804
63
7428

skipif mysql # not compatible
query I rowsort
SELECT ALL + col2 * + CAST ( - col0 AS REAL ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - - cor0.col2 + + ( cor0.col1 ) * + col1 AS col2 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT DISTINCT + + col1 * cor0.col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT cor0.col1 * + 67 AS col1 FROM tab2 AS cor0
----
1139
2077
3953

query I rowsort
SELECT - cor0.col2 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT DISTINCT + tab0.col1 * + 99 AS col2 FROM tab0
----
8514
9009
9603

query I rowsort
SELECT ALL + - 73 FROM tab2 AS cor0
----
-73
-73
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-3067
SELECT DISTINCT - col1 DIV + 72 AS col1 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-3067
SELECT DISTINCT - col1 / + 72 AS col1 FROM tab0
----
-1

query I rowsort
SELECT - - col1 * cor0.col1 + col0 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT col0 * - 7 AS col1 FROM tab2
----
-49
-546
-553

query I rowsort
SELECT ALL col0 + - col2 + col0 AS col0 FROM tab2
----
-13
120
130

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3071
SELECT ALL - col2 * CAST( + col2 AS SIGNED ) * + col1 + + col0 AS col0 FROM tab1
----
-119728
-32426
-75813

skipif mysql # not compatible
query I rowsort label-3071
SELECT ALL - col2 * CAST ( + col2 AS INTEGER ) * + col1 + + col0 AS col0 FROM tab1
----
-119728
-32426
-75813

onlyif mysql # use DIV operator for integer division
query I rowsort label-3072
SELECT DISTINCT + + cor0.col1 * + col1 + col0 DIV - col2 FROM tab1 AS cor0
----
169
676
99

skipif mysql # not compatible
query I rowsort label-3072
SELECT DISTINCT + + cor0.col1 * + col1 + col0 / - col2 FROM tab1 AS cor0
----
169
676
99

query I rowsort
SELECT + + cor0.col0 * cor0.col2 + + cor0.col0 AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT - 91 + col1 * col0 AS col0 FROM tab2 AS cor0
----
1252
126
4511

query I rowsort
SELECT ALL - + 69 * + col1 * + cor0.col1 AS col2 FROM tab0 AS cor0
----
-510324
-571389
-649221

query I rowsort
SELECT - 1 AS col0 FROM tab2 cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3077
SELECT DISTINCT - 95 DIV col0 AS col1 FROM tab1 cor0
----
-1
-31

skipif mysql # not compatible
query I rowsort label-3077
SELECT DISTINCT - 95 / col0 AS col1 FROM tab1 cor0
----
-1
-31

query I rowsort
SELECT - cor1.col2 + cor1.col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 09b61d5303a3c257c2b4280abfc64db7

query I rowsort
SELECT tab1.col2 + - col0 * col0 FROM tab1
----
-4039
-6304
45

query I rowsort
SELECT ALL 13 FROM tab0, tab1 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query I rowsort
SELECT ALL + 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-3082
SELECT DISTINCT + CAST( - col0 AS SIGNED ) * cor0.col0 FROM tab2 AS cor0
----
-49
-6084
-6241

skipif mysql # not compatible
query I rowsort label-3082
SELECT DISTINCT + CAST ( - col0 AS INTEGER ) * cor0.col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT 71 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT + ( - tab0.col1 + - col0 ) FROM tab0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT + + 65 * col0 * - col2 AS col2 FROM tab0 AS cor0
----
-2275
-474370
-51480

query I rowsort
SELECT ALL + ( + 48 ) AS col1 FROM tab0 AS cor0
----
48
48
48

query I rowsort
SELECT ALL - col1 * - cor0.col0 * - col0 + 43 FROM tab1 AS cor0
----
-191
-40917
-83157

query I rowsort
SELECT DISTINCT + col1 - - col0 * - col2 * tab0.col1 FROM tab0
----
-3298
-664027
-68026

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3089
SELECT DISTINCT col0 * + col1 * CAST( NULL AS SIGNED ) - - tab2.col0 * tab2.col0 * - 70 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-3089
SELECT DISTINCT col0 * + col1 * CAST ( NULL AS INTEGER ) - - tab2.col0 * tab2.col0 * - 70 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT - col0 + tab1.col1 - col1 AS col0 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT ALL 58 * col0 FROM tab1
----
174
3712
4640

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 ) * col0 + - col2 col0 FROM tab1
----
-45
4039
6304

query I rowsort
SELECT col1 - tab2.col1 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT + col1 * + col2 + + 96 FROM tab0 cor0
----
193
2934
7558

query I rowsort
SELECT DISTINCT - col2 * ( 99 ) + cor0.col1 AS col2 FROM tab0 AS cor0
----
-2
-3181
-8027

query I rowsort
SELECT col2 + 70 FROM tab2 AS cor0
----
108
96
97

query I rowsort
SELECT ALL + - col2 * ( + 75 ) + cor0.col0 FROM tab0 AS cor0
----
-2451
-40
-6061

query I rowsort
SELECT ALL + cor0.col2 * + ( cor0.col2 ) FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT - + col2 * + 3 + 60 FROM tab0 AS cor0
----
-186
-39
57

query I rowsort
SELECT - cor0.col0 - - 16 AS col2 FROM tab0 cor0
----
-19
-73
-8

query I rowsort
SELECT col0 * + col1 + - 53 * + col2 AS col0 FROM tab1 AS cor0
----
-2381
-2784
-4048

query I rowsort
SELECT ALL + + col0 * ( + 49 ) + + col0 FROM tab1 cor0
----
150
3200
4000

query I rowsort
SELECT DISTINCT - col2 * + col1 + - col1 * + col1 FROM tab0 AS cor0
----
-10234
-15743
-9506

query I rowsort
SELECT DISTINCT - + col0 + - col0 * - col0 AS col1 FROM tab1 cor0
----
4032
6
6320

query I rowsort
SELECT - + cor0.col0 * - ( 33 ) FROM tab1 AS cor0
----
2112
2640
99

query I rowsort
SELECT col2 * 24 + col2 AS col2 FROM tab2 AS cor0
----
650
675
950

query I rowsort
SELECT DISTINCT - col1 * - col0 * + 47 FROM tab0 AS cor0
----
159565
380653
97008

query I rowsort
SELECT DISTINCT - - 38 + - col2 + ( + col2 ) FROM tab1 AS cor0
----
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3109
SELECT - ( cor0.col0 ) + - 27 * + 73 + col0 DIV 37 FROM tab2 AS cor0
----
-1978
-2047
-2048

skipif mysql # not compatible
query I rowsort label-3109
SELECT - ( cor0.col0 ) + - 27 * + 73 + col0 / 37 FROM tab2 AS cor0
----
-1978
-2047
-2048

query I rowsort
SELECT ALL + 27 * col0 FROM tab0 cor0
----
2403
648
945

onlyif mysql # use DIV operator for integer division
query I rowsort label-3111
SELECT + cor0.col1 DIV cor0.col2 AS col1 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-3111
SELECT + cor0.col1 / cor0.col2 AS col1 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT ALL - 71 + col2 - col0 AS col0 FROM tab2 AS cor0
----
-112
-123
-51

query I rowsort
SELECT + 76 + + col1 FROM tab1 cor0
----
102
86
89

query I rowsort
SELECT - cor0.col1 + col0 * cor0.col2 * col0 FROM tab2 cor0
----
1292
158125
237141

query I rowsort
SELECT - col2 * col1 * col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT + 17 + + ( col1 ) FROM tab2 cor0
----
34
48
76

query I rowsort
SELECT - col0 * col0 * + col1 AS col0 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT + + col1 * col0 * col2 AS col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ALL + 99 * - col0 + col1 AS col0 FROM tab1 AS cor0
----
-271
-6326
-7907

query I rowsort
SELECT + 66 * + cor0.col0 + col2 FROM tab2 cor0
----
489
5174
5252

skipif mysql # not compatible
query I rowsort
SELECT ALL + cor0.col1 / + 86 + + col1 + CAST ( col0 AS REAL ) FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT - - 42 + cor0.col2 * col2 FROM tab1 AS cor0
----
2958
3291
9258

query I rowsort
SELECT DISTINCT - ( + 20 ) + col0 * - 12 FROM tab0 AS cor0
----
-1088
-308
-440

query I rowsort
SELECT ALL - 95 + - col1 AS col1 FROM tab1 AS cor0
----
-105
-108
-121

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + col0 col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT col1 * + 83 FROM tab0
----
7138
7553
8051

query I rowsort
SELECT DISTINCT cor1.col2 + ( 84 ) FROM tab1, tab0 AS cor0, tab1 cor1
----
138
141
180

query I rowsort
SELECT - 30 + + col2 + + col0 FROM tab1 AS cor0
----
146
27
91

query I rowsort
SELECT DISTINCT cor0.col0 * + col1 AS col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + - 70 + 74 AS col1 FROM tab2 AS cor0
----
4
4
4

query I rowsort
SELECT - col0 * col2 + col0 + ( + col2 ) AS col2 FROM tab1 AS cor0
----
-105
-3527
-7504

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3132
SELECT ALL - - CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-3132
SELECT ALL - - CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT ( ( col0 ) ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - ( col0 + col1 ) * - col2 FROM tab1
----
1566
4218
8928

onlyif mysql # use DIV operator for integer division
query I rowsort label-3135
SELECT ALL - col1 + col1 DIV - col0 AS col0 FROM tab1
----
-10
-13
-34

skipif mysql # not compatible
query I rowsort label-3135
SELECT ALL - col1 + col1 / - col0 AS col0 FROM tab1
----
-10
-13
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3136
SELECT ALL + CAST( 36 AS SIGNED ) FROM tab0
----
36
36
36

skipif mysql # not compatible
query I rowsort label-3136
SELECT ALL + CAST ( 36 AS INTEGER ) FROM tab0
----
36
36
36

query I rowsort
SELECT DISTINCT + + 25 + + col0 AS col1 FROM tab1 cor0
----
105
28
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 75 + col1 col0 FROM tab2 cor0
----
106
134
92

query I rowsort
SELECT ALL col2 - col2 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT 51 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
51

query I rowsort
SELECT - + col0 * - col0 + col0 FROM tab0 cor0
----
1260
600
8010

query I rowsort
SELECT 35 * tab2.col2 AS col1 FROM tab2
----
1330
910
945

query I rowsort
SELECT + ( col0 ) - col0 AS col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3144
SELECT col0 + col2 * - CAST( - col1 AS SIGNED ) * col1 col2 FROM tab1 AS cor0
----
16304
36507
5764

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3144
SELECT col0 + col2 * - CAST ( - col1 AS INTEGER ) * col1 col2 FROM tab1 AS cor0
----
16304
36507
5764

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3145
SELECT col0 - - cor0.col1 * - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3145
SELECT col0 - - cor0.col1 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col1 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col1 * - col0 + col2 * 3 * col2 - - col2 * + 85 AS col0 FROM tab0 AS cor0
----
3483
35241
8136

query I rowsort
SELECT ( + col0 ) FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT 37 - + 83 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to 491ad1fb79fec0b5715ea54949d1aa2d

query I rowsort
SELECT - + col0 + col1 * + col2 AS col1 FROM tab1 AS cor0
----
1168
1401
506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col0 + col0 col1 FROM tab1 AS cor0
----
1120
704
81

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to 3a186ad492d315801f56fb30a5e89dbb

query I rowsort
SELECT ALL - - col1 + - col1 AS col2 FROM tab1 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3154
SELECT DISTINCT - - cor0.col1 DIV 15 - - 97 FROM tab2 AS cor0
----
100
98
99

skipif mysql # not compatible
query I rowsort label-3154
SELECT DISTINCT - - cor0.col1 / 15 - - 97 FROM tab2 AS cor0
----
100
98
99

query I rowsort
SELECT ALL cor0.col1 AS col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 63 * col1 col0 FROM tab1 AS cor0
----
1638
630
819

query I rowsort
SELECT ALL 34 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

query I rowsort
SELECT col0 + col0 + - 14 AS col2 FROM tab0
----
164
34
56

query I rowsort
SELECT + 59 + 63 * - cor1.col0 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 7ea43dde69c69131a46701264779b587

query I rowsort
SELECT - 17 * col2 + + col0 * + col0 AS col2 FROM tab2 AS cor0
----
-410
5595
5642

query I rowsort
SELECT DISTINCT col2 + + tab2.col0 * col2 AS col0 FROM tab2
----
2054
216
3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3162
SELECT col2 + - col0 * - CAST( + 70 + col0 AS SIGNED ) FROM tab0 cor0
----
14233
2289
3676

skipif mysql # not compatible
query I rowsort label-3162
SELECT col2 + - col0 * - CAST ( + 70 + col0 AS INTEGER ) FROM tab0 cor0
----
14233
2289
3676

query I rowsort
SELECT 13 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT - col0 + + ( col2 ) FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - + col1 + - ( - col2 ) FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT - - cor0.col0 * + 30 FROM tab0 AS cor0
----
1050
2670
720

query I rowsort
SELECT - - ( - 88 ) + cor0.col1 * + 51 * 87 AS col0 FROM tab1 cor0
----
115274
44282
57593

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( - col0 ) * + col1 * - col2 - + 9 col1 FROM tab1 AS cor0
----
36471
4203
99831

query I rowsort
SELECT DISTINCT col2 + cor0.col1 * + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT - col0 + 78 * col1 FROM tab2 cor0
----
1247
2411
4524

query I rowsort
SELECT - + col2 - col1 * + col2 AS col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT ALL - - col2 * - col0 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL col2 + + col2 * - col2 FROM tab2 cor0
----
-1406
-650
-702

query I rowsort
SELECT ALL + 49 * col0 FROM tab0 AS cor0
----
1176
1715
4361

onlyif mysql # use DIV operator for integer division
query I rowsort label-3175
SELECT + col1 DIV + col1 + + col0 * + ( col2 ) + ( cor0.col2 ) DIV + col0 FROM tab2 AS cor0
----
193
2029
3003

skipif mysql # not compatible
query I rowsort label-3175
SELECT + col1 / + col1 + + col0 * + ( col2 ) + ( cor0.col2 ) / + col0 FROM tab2 AS cor0
----
193
2029
3003

query I rowsort
SELECT DISTINCT 83 AS col0 FROM tab1
----
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-3177
SELECT 42 DIV col1 FROM tab2
----
0
1
2

skipif mysql # not compatible
query I rowsort label-3177
SELECT 42 / col1 FROM tab2
----
0
1
2

query I rowsort
SELECT ALL + ( col2 ) * + col2 AS col0 FROM tab2
----
1444
676
729

query I rowsort
SELECT - - col2 * - col0 + cor0.col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL - ( - col0 ) * col2 AS col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ALL + - cor0.col1 * col1 + 33 + col1 AS col1 FROM tab0 AS cor0
----
-7277
-8157
-9279

query I rowsort
SELECT - col0 + col0 + cor0.col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL - + 74 + cor0.col0 FROM tab1 AS cor0
----
-10
-71
6

query I rowsort
SELECT DISTINCT - 26 * col1 + - col1 AS col0 FROM tab0 AS cor0
----
-2322
-2457
-2619

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3185
SELECT DISTINCT - CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-3185
SELECT DISTINCT - CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
NULL

query I rowsort
SELECT + 2 AS col1 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

query I rowsort
SELECT ALL + col1 + col0 + - col2 AS col2 FROM tab0
----
131
77
98

query I rowsort
SELECT DISTINCT col2 + + col2 * tab2.col0 FROM tab2
----
2054
216
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 70 col2 FROM tab2
----
-70
-70
-70

query I rowsort
SELECT DISTINCT + tab0.col2 * col0 + col2 + + col0 AS col0 FROM tab0
----
71
7469
849

query I rowsort
SELECT col2 + - tab1.col1 + + 70 AS col1 FROM tab1
----
117
153
98

query I rowsort
SELECT ( 13 ) * cor1.col1 + + 41 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to f47e4cdb53d454ef81a33c6723e974ec

query I rowsort
SELECT + cor0.col2 * cor0.col1 + + col2 * - 17 + - col2 FROM tab2 AS cor0
----
-38
1066
351

onlyif mysql # use DIV operator for integer division
query I rowsort label-3194
SELECT DISTINCT - - col2 DIV col0 + ( 69 ) FROM tab1 AS cor0
----
69
70
87

skipif mysql # not compatible
query I rowsort label-3194
SELECT DISTINCT - - col2 / col0 + ( 69 ) FROM tab1 AS cor0
----
69
70
87

query I rowsort
SELECT - col0 * cor0.col1 + + cor0.col0 AS col1 FROM tab0 cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL col1 * + col0 + col1 * col2 FROM tab1
----
1210
1482
2288

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + + col1 + + col2 * 37 col0 FROM tab2
----
1061
1080
1440

query I rowsort
SELECT - 86 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 9ac806793c03d3a6b5e3a3029d20e4da

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( col0 AS REAL ) * cor0.col0 + cor0.col1 AS col1 FROM tab1 cor0
----
35
4106
6413

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 38 * col0 + cor0.col0 col2 FROM tab1 AS cor0
----
117
2496
3120

query I rowsort
SELECT ALL - 90 + - col0 FROM tab0 AS cor0
----
-114
-125
-179

query I rowsort
SELECT - col2 * + col1 + cor0.col2 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT - - ( col0 ) * - col0 AS col0 FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3204
SELECT ALL + CAST( NULL AS DECIMAL ) * ( col0 ) + col2 * - 65 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3204
SELECT ALL + CAST ( NULL AS REAL ) * ( col0 ) + col2 * - 65 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 57 * col2 * - col0 + - col1 * - 97 AS col0 FROM tab1
----
-206966
-436499
-6712

query I rowsort
SELECT ALL + + col2 * - 41 FROM tab0 AS cor0
----
-1353
-3362
-41

query I rowsort
SELECT DISTINCT + ( col2 ) * col1 + 36 * - 48 AS col0 FROM tab1 AS cor0
----
-1158
-324
-480

query I rowsort
SELECT ALL - ( col2 ) * + col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT - - col1 + + col2 * cor0.col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT - ( 67 ) + - col2 * - col1 FROM tab1 AS cor0
----
1181
1337
503

onlyif mysql # use DIV operator for integer division
query I rowsort label-3211
SELECT ALL + col1 DIV - 36 AS col2 FROM tab2 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3211
SELECT ALL + col1 / - 36 AS col2 FROM tab2 cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3212
SELECT ALL + tab2.col2 DIV 57 + col2 + col0 FROM tab2
----
104
117
34

skipif mysql # not compatible
query I rowsort label-3212
SELECT ALL + tab2.col2 / 57 + col2 + col0 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL col2 + ( + col1 ) AS col2 FROM tab0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3214
SELECT DISTINCT - - col1 DIV CAST( + col1 * cor0.col0 AS SIGNED ) + - col0 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-3214
SELECT DISTINCT - - col1 / CAST ( + col1 * cor0.col0 AS INTEGER ) + - col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + - cor0.col2 + col1 * - col1 AS col1 FROM tab2 AS cor0
----
-327
-3507
-988

query I rowsort
SELECT ALL - col1 * - col0 + col2 AS col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT + cor0.col2 * - col0 - + 14 FROM tab1 AS cor0
----
-176
-3662
-7694

query I rowsort
SELECT 87 * + col2 * + col2 + + 40 + + col0 * col0 * + col0 AS col1 FROM tab0 AS cor0
----
108607
1289997
43002

query I rowsort
SELECT - 58 - + 66 * + col1 AS col0 FROM tab0 AS cor0
----
-5734
-6064
-6460

query I rowsort
SELECT - cor0.col1 * - col1 + + cor0.col0 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT - 30 * + 4 + col2 AS col1 FROM tab2 AS cor0
----
-82
-93
-94

onlyif mysql # use DIV operator for integer division
query I rowsort label-3222
SELECT DISTINCT + 29 * 52 DIV - col0 - + cor0.col1 AS col1 FROM tab0 AS cor0
----
-107
-140
-148

skipif mysql # not compatible
query I rowsort label-3222
SELECT DISTINCT + 29 * 52 / - col0 - + cor0.col1 AS col1 FROM tab0 AS cor0
----
-107
-140
-148

query I rowsort
SELECT ALL - + 0 + cor0.col1 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - col0 * 82 - col0 AS col2 FROM tab0 AS cor0
----
-1992
-2905
-7387

query I rowsort
SELECT ALL - ( col2 ) * col2 * - col2 AS col1 FROM tab1 cor0
----
157464
185193
884736

query I rowsort
SELECT + col1 + + 70 * col1 FROM tab2 cor0
----
1207
2201
4189

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3227
SELECT + cor0.col2 + + col2 * cor0.col1 * - CAST( NULL AS SIGNED ) + - 46 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3227
SELECT + cor0.col2 + + col2 * cor0.col1 * - CAST ( NULL AS INTEGER ) + - 46 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col1 * 53 AS col2 FROM tab2 AS cor0
----
-1643
-3127
-901

query I rowsort
SELECT DISTINCT tab2.col2 + ( col2 + - col2 ) AS col0 FROM tab2
----
26
27
38

query I rowsort
SELECT - col0 * + col1 + tab0.col2 * + col1 FROM tab0
----
-3298
-637
774

query I rowsort
SELECT DISTINCT col1 * tab1.col2 + + ( col0 ) AS col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT - ( - col0 ) + - col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL + + col1 * + col0 + col0 + + 5 AS col2 FROM tab1 cor0
----
1125
709
86

query I rowsort
SELECT - - col1 + - col2 * 92 FROM tab2 AS cor0
----
-2333
-2453
-3479

query I rowsort
SELECT ALL + - 52 * - col0 FROM tab1 AS cor0
----
156
3328
4160

query I rowsort
SELECT + 58 * - col0 FROM tab2 AS cor0
----
-406
-4524
-4582

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3237
SELECT DISTINCT - col2 * - cor0.col1 + CAST( col2 AS SIGNED ) * col0 FROM tab2 AS cor0
----
1026
3562
3648

skipif mysql # not compatible
query I rowsort label-3237
SELECT DISTINCT - col2 * - cor0.col1 + CAST ( col2 AS INTEGER ) * col0 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT DISTINCT - 85 + col1 AS col1 FROM tab1 AS cor0
----
-59
-72
-75

query I rowsort
SELECT ALL + + 62 + + col1 FROM tab1 AS cor0
----
72
75
88

query I rowsort
SELECT + + 21 * col0 * col2 FROM tab0 AS cor0
----
153258
16632
735

query I rowsort
SELECT ALL - 1 AS col2 FROM tab2 cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3242
SELECT - CAST( - 60 AS SIGNED ) + cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 4795521d3b453f5e361af4dccb226f29

skipif mysql # not compatible
query I rowsort label-3242
SELECT - CAST ( - 60 AS INTEGER ) + cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 4795521d3b453f5e361af4dccb226f29

query I rowsort
SELECT - - col1 + col0 * 83 FROM tab1 AS cor0
----
275
5322
6653

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3244
SELECT - col2 + CAST( + col1 AS SIGNED ) * col0 AS col0 FROM tab1 cor0
----
24
583
944

skipif mysql # not compatible
query I rowsort label-3244
SELECT - col2 + CAST ( + col1 AS INTEGER ) * col0 AS col0 FROM tab1 cor0
----
24
583
944

query I rowsort
SELECT DISTINCT 52 AS col2 FROM tab1, tab2, tab0 AS cor0
----
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col0 col0 FROM tab0, tab1 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT ( - tab1.col2 ) * 33 AS col1 FROM tab1
----
-1782
-1881
-3168

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 cor0 CROSS JOIN tab2, tab2 AS cor1, tab2 AS cor2, tab0 cor3
----
3645 values hashing to 5ec52b92c3c8d78cc0a61df3fc16f18b

query I rowsort
SELECT + col2 + - 28 FROM tab1 AS cor0
----
26
29
68

query I rowsort
SELECT - 86 FROM tab0, tab0 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to 1ef7453f3d4bc7d93f06fc98b5d59841

onlyif mysql # use DIV operator for integer division
query I rowsort label-3251
SELECT col2 DIV + col1 + 74 + cor0.col1 FROM tab2 AS cor0
----
105
133
93

skipif mysql # not compatible
query I rowsort label-3251
SELECT col2 / + col1 + 74 + cor0.col1 FROM tab2 AS cor0
----
105
133
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3252
SELECT ALL + CAST( - cor0.col1 AS SIGNED ) + - col2 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

skipif mysql # not compatible
query I rowsort label-3252
SELECT ALL + CAST ( - cor0.col1 AS INTEGER ) + - col2 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT + col2 * 12 FROM tab2
----
312
324
456

onlyif mysql # use DIV operator for integer division
query I rowsort label-3254
SELECT DISTINCT - + ( + col2 ) + col0 DIV 96 + - 66 AS col1 FROM tab2 AS cor0
----
-104
-92
-93

skipif mysql # not compatible
query I rowsort label-3254
SELECT DISTINCT - + ( + col2 ) + col0 / 96 + - 66 AS col1 FROM tab2 AS cor0
----
-104
-92
-93

query I rowsort
SELECT 98 + + col0 AS col1 FROM tab2 AS cor0
----
105
176
177

query I rowsort
SELECT ALL + + 88 + + col0 * - col2 + + cor0.col1 AS col1 FROM tab0 AS cor0
----
-618
-7119
150

query I rowsort
SELECT + + col0 + cor0.col2 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT + 97 AS col2 FROM tab0 cor0
----
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 2 col0 FROM tab2 AS cor0
----
-2

query I rowsort
SELECT - col0 * ( col2 ) AS col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT col1 - 39 * 86 * + col1 FROM tab2
----
-103943
-197827
-57001

query I rowsort
SELECT DISTINCT + ( 68 ) + col0 AS col0 FROM tab1
----
132
148
71

query I rowsort
SELECT ALL cor1.col2 AS col0 FROM tab0, tab1 cor0 CROSS JOIN tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT 71 * + col0 AS col0 FROM tab1
----
213
4544
5680

query I rowsort
SELECT ALL col1 + col0 * - col2 AS col0 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT - col2 + tab1.col0 * - col2 FROM tab1
----
-216
-3705
-7776

query I rowsort
SELECT ( - col2 ) + - col1 * - col1 + + ( - col1 ) FROM tab2 cor0
----
234
3396
903

query I rowsort
SELECT ALL - 72 * + ( - cor0.col1 ) FROM tab2 AS cor0
----
1224
2232
4248

onlyif mysql # use DIV operator for integer division
query I rowsort label-3269
SELECT + + 23 DIV - cor0.col0 AS col0 FROM tab1 AS cor0
----
-7
0
0

skipif mysql # not compatible
query I rowsort label-3269
SELECT + + 23 / - cor0.col0 AS col0 FROM tab1 AS cor0
----
-7
0
0

query I rowsort
SELECT DISTINCT 51 * - col1 AS col2 FROM tab1 cor0
----
-1326
-510
-663

query I rowsort
SELECT DISTINCT - cor0.col0 + 52 AS col2 FROM tab1 AS cor0
----
-12
-28
49

query I rowsort
SELECT ALL + + ( 58 ) AS col1 FROM tab0 AS cor0
----
58
58
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col2 + cor0.col1 col0 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT 77 + col2 FROM tab2
----
103
104
115

onlyif mysql # use DIV operator for integer division
query I rowsort label-3275
SELECT - 5 DIV col0 AS col0 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3275
SELECT - 5 / col0 AS col0 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT + col0 * + 96 AS col2 FROM tab0 AS cor0
----
2304
3360
8544

query I rowsort
SELECT + 45 * cor0.col0 - - cor0.col0 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 47332122c626b044d782a3115598aecb

query I rowsort
SELECT col0 + + col0 - col0 AS col1 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT + col2 - 6 * ( col0 ) FROM tab2
----
-15
-436
-442

query I rowsort
SELECT DISTINCT - - cor0.col2 * col0 + col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT 80 AS col1 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3282
SELECT - tab0.col0 + ( - col0 ) DIV + col2 FROM tab0
----
-24
-70
-90

skipif mysql # not compatible
query I rowsort label-3282
SELECT - tab0.col0 + ( - col0 ) / + col2 FROM tab0
----
-24
-70
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3283
SELECT DISTINCT - col1 + - CAST( NULL AS SIGNED ) - col0 * + col0 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3283
SELECT DISTINCT - col1 + - CAST ( NULL AS INTEGER ) - col0 * + col0 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - - col0 + + 39 AS col2 FROM tab2 AS cor0
----
117
118
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-3285
SELECT DISTINCT + - col0 * cor0.col2 - col2 DIV - col0 FROM tab0 AS cor0
----
-35
-7298
-791

skipif mysql # not compatible
query I rowsort label-3285
SELECT DISTINCT + - col0 * cor0.col2 - col2 / - col0 FROM tab0 AS cor0
----
-35
-7298
-791

query I rowsort
SELECT DISTINCT col1 * + 92 FROM tab1 AS cor0
----
1196
2392
920

onlyif mysql # use DIV operator for integer division
query I rowsort label-3287
SELECT ALL - col2 DIV ( ( col2 ) ) + + cor0.col2 + - cor0.col0 * cor0.col1 col2 FROM tab0 AS cor0
----
-2032
-3395
-8018

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3287
SELECT ALL - col2 / ( ( col2 ) ) + + cor0.col2 + - cor0.col0 * cor0.col1 col2 FROM tab0 AS cor0
----
-2032
-3395
-8018

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3288
SELECT ALL - col2 * + CAST( + col0 AS SIGNED ) + col2 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

skipif mysql # not compatible
query I rowsort label-3288
SELECT ALL - col2 * + CAST ( + col0 AS INTEGER ) + col2 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3289
SELECT DISTINCT + col2 + + CAST( - ( - col1 ) AS SIGNED ) AS col2 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-3289
SELECT DISTINCT + col2 + + CAST ( - ( - col1 ) AS INTEGER ) AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT col0 * - col0 + + 46 FROM tab1 AS cor0
----
-4050
-6354
37

query I rowsort
SELECT ALL ( - col1 ) + + col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT + - ( - col0 ) * + col1 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + 13 + + col0 AS col1 FROM tab0 AS cor0
----
102
37
48

query I rowsort
SELECT + + cor0.col0 * - col0 - + col0 * cor0.col2 FROM tab0 AS cor0
----
-1260
-1368
-15219

query I rowsort
SELECT - col2 * - col1 + - col0 AS col0 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT DISTINCT - 64 FROM tab0, tab1 AS cor0
----
-64

query I rowsort
SELECT - + col0 + 46 * col0 FROM tab1 cor0
----
135
2880
3600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col1 * col0 + col2 * + col1 col2 FROM tab2 AS cor0
----
-105451
-357422
-682

query I rowsort
SELECT - tab1.col2 - 64 FROM tab1
----
-118
-121
-160

query I rowsort
SELECT ALL + 16 * - 15 AS col1 FROM tab1 cor0
----
-240
-240
-240

query I rowsort
SELECT + - col2 - - 57 FROM tab0 AS cor0
----
-25
24
56

query I rowsort
SELECT - + 35 + + col2 * - ( + 34 + + cor0.col2 ) FROM tab0 AS cor0
----
-2246
-70
-9547

query I rowsort
SELECT - col2 * cor0.col2 * col2 AS col0 FROM tab2 AS cor0
----
-17576
-19683
-54872

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( - col0 ) + - 82 * ( col1 * col0 ) col2 FROM tab0 AS cor0
----
-169272
-278425
-664207

query I rowsort
SELECT - - ( col1 ) * cor0.col0 AS col2 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3306
SELECT + cor0.col0 DIV + cor0.col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

skipif mysql # not compatible
query I rowsort label-3306
SELECT + cor0.col0 / + cor0.col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

query I rowsort
SELECT DISTINCT 81 * - col1 AS col0 FROM tab1 cor0
----
-1053
-2106
-810

query I rowsort
SELECT - col2 + + col1 * + col1 FROM tab2 cor0
----
251
3455
934

query I rowsort
SELECT DISTINCT + + ( + col1 ) + col2 * col2 AS col0 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT + col1 * - ( + 87 ) FROM tab0 AS cor0
----
-7482
-7917
-8439

query I rowsort
SELECT ALL - col0 + - 95 * + col1 FROM tab2 AS cor0
----
-1694
-2952
-5683

query I rowsort
SELECT ALL - col1 * 90 FROM tab0 cor0
----
-7740
-8190
-8730

query I rowsort
SELECT ALL + - cor0.col0 * + cor0.col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT col0 * tab0.col1 AS col2 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT 72 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT + 25 * 95 + tab0.col0 AS col0 FROM tab0
----
2399
2410
2464

query I rowsort
SELECT ALL - - cor1.col1 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT tab1.col2 FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL + col1 * col0 * + tab2.col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT + 85 + - cor0.col0 FROM tab2 AS cor0
----
6
7
78

query I rowsort
SELECT ALL - - 33 * col2 FROM tab1 AS cor0
----
1782
1881
3168

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 44 col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 07457d9e571e036a9a3a0f5a5a2e1ef2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3323
SELECT - col1 * CAST( NULL AS DECIMAL ) + col1 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3323
SELECT - col1 * CAST ( NULL AS REAL ) + col1 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 18 + + cor0.col1 col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
104
109
115

query I rowsort
SELECT DISTINCT + 71 + + tab0.col1 AS col0 FROM tab0, tab0 AS cor0
----
157
162
168

query I rowsort
SELECT ALL col1 * - 15 AS col2 FROM tab0 cor0
----
-1290
-1365
-1455

query I rowsort
SELECT - col0 * ( col1 ) * col0 AS col0 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT - col1 + 86 FROM tab0 AS cor0
----
-11
-5
0

query I rowsort
SELECT DISTINCT - - col2 + ( - cor0.col1 ) + + col0 AS col1 FROM tab0 AS cor0
----
-29
-61
80

query I rowsort
SELECT + ( - 75 ) + + col1 * + col2 FROM tab0 AS cor0
----
22
2763
7387

onlyif mysql # use DIV operator for integer division
query I rowsort label-3331
SELECT DISTINCT + ( + col0 ) + col1 DIV col2 AS col1 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3331
SELECT DISTINCT + ( + col0 ) + col1 / col2 AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL ( - col1 ) * col0 AS col0 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3333
SELECT col2 DIV cor0.col0 col0 FROM tab2 cor0
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3333
SELECT col2 / cor0.col0 col0 FROM tab2 cor0
----
0
0
3

query I rowsort
SELECT DISTINCT col2 * + ( + col0 + 98 ) FROM tab1 cor0
----
17088
5454
9234

onlyif mysql # use DIV operator for integer division
query I rowsort label-3335
SELECT ALL + 85 DIV - 2 + col0 FROM tab1 AS cor0
----
-39
22
38

skipif mysql # not compatible
query I rowsort label-3335
SELECT ALL + 85 / - 2 + col0 FROM tab1 AS cor0
----
-39
22
38

query I rowsort
SELECT ALL 19 * 47 + + col2 FROM tab1 AS cor0
----
947
950
989

query I rowsort
SELECT - cor0.col0 * 23 + col0 AS col0 FROM tab1 AS cor0
----
-1408
-1760
-66

query I rowsort
SELECT ALL + + cor0.col1 * - col0 + - col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT ALL - - 29 + ( col1 ) * col2 FROM tab1 AS cor0
----
1277
1433
599

query I rowsort
SELECT tab2.col0 * tab2.col1 AS col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT + ( + 72 ) AS col2 FROM tab1 AS cor0
----
72
72
72

query I rowsort
SELECT - - cor0.col0 + - cor0.col1 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT - - 85 + col2 FROM tab1 AS cor0
----
139
142
181

query I rowsort
SELECT + ( - col0 ) * + col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT - col2 + - col1 * col0 AS col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT - ( - col0 ) * col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + 11 * col1 + + col2 AS col0 FROM tab2 cor0
----
225
368
675

query I rowsort
SELECT - cor0.col0 * col1 FROM tab1 cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 3 + cor0.col0 col0 FROM tab0 AS cor0
----
21
32
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3350
SELECT DISTINCT + ( - col0 ) * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3350
SELECT DISTINCT + ( - col0 ) * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col2 * - col1 AS col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT + - 43 + col1 * 71 FROM tab1 AS cor0
----
1803
667
880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 col0 FROM tab0, tab1 cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT - - col2 + + ( - col1 ) - col2 FROM tab2 AS cor0
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-3356
SELECT + col2 * col2 DIV - col2 + - col2 * + col0 FROM tab0 AS cor0
----
-36
-7380
-825

skipif mysql # not compatible
query I rowsort label-3356
SELECT + col2 * col2 / - col2 + - col2 * + col0 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT - + col2 * + col0 - col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT - col1 + - col1 * 14 AS col0 FROM tab0 AS cor0
----
-1290
-1365
-1455

query I rowsort
SELECT - col0 * ( - col2 ) * col0 - col1 * - col0 FROM tab2 AS cor0
----
1540
162786
238501

onlyif mysql # use DIV operator for integer division
query I rowsort label-3360
SELECT DISTINCT col1 DIV - col1 + + col1 + + col0 FROM tab1
----
28
73
92

skipif mysql # not compatible
query I rowsort label-3360
SELECT DISTINCT col1 / - col1 + + col1 + + col0 FROM tab1
----
28
73
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-3361
SELECT col0 DIV col2 col2 FROM tab0
----
0
1
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3361
SELECT col0 / col2 col2 FROM tab0
----
0
1
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-3362
SELECT + 15 * - col2 DIV col2 FROM tab0
----
-15
-15
-15

skipif mysql # not compatible
query I rowsort label-3362
SELECT + 15 * - col2 / col2 FROM tab0
----
-15
-15
-15

query I rowsort
SELECT - col2 * - col1 - - col1 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-3364
SELECT cor0.col2 DIV + 71 + col1 + col0 AS col1 FROM tab2 AS cor0
----
137
38
96

skipif mysql # not compatible
query I rowsort label-3364
SELECT cor0.col2 / + 71 + col1 + col0 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT + 8 + + col0 AS col1 FROM tab0 cor0
----
32
43
97

query I rowsort
SELECT + col1 + - col2 * - 1 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT - 43 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 2f72bd9cab68c8d8c38874510a290a3c

query I rowsort
SELECT cor0.col2 * - 83 AS col2 FROM tab0 AS cor0
----
-2739
-6806
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3369
SELECT DISTINCT - col1 * - CAST( NULL AS SIGNED ) col1 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3369
SELECT DISTINCT - col1 * - CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + col2 * 18 AS col0 FROM tab2 cor0
----
468
486
684

query I rowsort
SELECT col1 * ( - col0 ) AS col0 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT + + cor0.col1 * + 21 AS col0 FROM tab2 AS cor0
----
1239
357
651

query I rowsort
SELECT DISTINCT + - col1 * ( + col0 ) FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - col0 + + cor0.col0 AS col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL cor0.col1 * - cor0.col2 FROM tab1 cor0
----
-1248
-1404
-570

query IIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT + tab2.col0 * + 30 AS col2 FROM tab2
----
210
2340
2370

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( - col0 AS REAL ) AS col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL - 66 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to a408108d423d7784b7d610cb779e515a

query I rowsort
SELECT DISTINCT + tab1.col2 * + col2 - + col2 FROM tab1
----
2862
3192
9120

query I rowsort
SELECT DISTINCT tab2.col0 * col1 AS col1 FROM tab2 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL 52 * + col0 + + 38 FROM tab1 cor0
----
194
3366
4198

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col1 * col2 col1 FROM tab0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + tab2.col2 col1 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT col0 + - tab2.col0 * + col1 + + col0 FROM tab2
----
-1185
-203
-4446

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE col2 IN ( - col1 * col0 / - col0 + col1 * col1 * + tab2.col1 )
----

query I rowsort
SELECT - tab0.col1 + col1 AS col2 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3388
SELECT - tab2.col2 DIV 99 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-3388
SELECT - tab2.col2 / 99 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + col2 col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT 3 AS col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT ALL - ( col2 * ( + col2 ) ) FROM tab2
----
-1444
-676
-729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3392
SELECT + col0 * col1 * + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3392
SELECT + col0 * col1 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * + col0 + + col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT - 73 FROM tab1 AS cor0
----
-73

query I rowsort
SELECT DISTINCT + ( - col1 ) * 4 AS col0 FROM tab0 AS cor0
----
-344
-364
-388

query I rowsort
SELECT ALL - cor0.col0 * - 91 FROM tab0 AS cor0
----
2184
3185
8099

query I rowsort
SELECT ALL + col0 * + 70 * 82 FROM tab1 AS cor0
----
17220
367360
459200

query I rowsort
SELECT DISTINCT + col2 * 71 AS col2 FROM tab1 AS cor0
----
3834
4047
6816

query I rowsort
SELECT - col1 + + 93 FROM tab1
----
67
80
83

query I rowsort
SELECT DISTINCT + col2 * - col2 + - 88 FROM tab1 AS cor0
----
-3004
-3337
-9304

onlyif mysql # use DIV operator for integer division
query I rowsort label-3401
SELECT ALL - + col2 + col1 DIV - col1 AS col2 FROM tab1 cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-3401
SELECT ALL - + col2 + col1 / - col1 AS col2 FROM tab1 cor0
----
-55
-58
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3402
SELECT ALL - + col1 * - col0 + - col0 DIV - col2 FROM tab1 AS cor0
----
1040
641
78

skipif mysql # not compatible
query I rowsort label-3402
SELECT ALL - + col1 * - col0 + - col0 / - col2 FROM tab1 AS cor0
----
1040
641
78

query I rowsort
SELECT DISTINCT - cor0.col1 + - ( col2 ) * col2 FROM tab0 AS cor0
----
-1175
-6815
-98

query I rowsort
SELECT - 14 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to d321461994ba49c3a70fa6373032fc94

query I rowsort
SELECT ALL 14 * - col2 + - tab2.col0 + - 2 * col1 AS col1 FROM tab2
----
-447
-560
-645

query I rowsort
SELECT ALL - 3 + 41 AS col0 FROM tab0
----
38
38
38

query I rowsort
SELECT ALL - ( 43 ) AS col0 FROM tab0 AS cor0
----
-43
-43
-43

query I rowsort
SELECT - cor1.col2 AS col2 FROM tab0, tab2 AS cor0, tab0 cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT - col1 + 81 FROM tab1 AS cor0
----
55
68
71

query I rowsort
SELECT DISTINCT - col0 * + 68 - - col1 FROM tab0 AS cor0
----
-1546
-2283
-5961

query I rowsort
SELECT DISTINCT + col2 * - col1 - col0 AS col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT - - 55 * 25 * col2 + col1 AS col0 FROM tab0 cor0
----
112841
1472
45461

query I rowsort
SELECT - col2 - - 41 FROM tab0 cor0
----
-41
40
8

query I rowsort
SELECT DISTINCT - - col2 * col0 + col0 FROM tab2 AS cor0
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-3415
SELECT DISTINCT + - 11 DIV ( + col2 ) - + 92 FROM tab0 AS cor0
----
-103
-92

skipif mysql # not compatible
query I rowsort label-3415
SELECT DISTINCT + - 11 / ( + col2 ) - + 92 FROM tab0 AS cor0
----
-103
-92

query I rowsort
SELECT + + 6 * col1 FROM tab0 AS cor0
----
516
546
582

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 56 + - col0 col1 FROM tab2 AS cor0
----
-134
-135
-63

query I rowsort
SELECT ALL + + 97 * col0 FROM tab0 AS cor0
----
2328
3395
8633

query I rowsort
SELECT ALL + - col0 * col0 + col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT ALL - col1 + - col1 * 22 * + col0 AS col0 FROM tab0 AS cor0
----
-178269
-45494
-74787

query I rowsort
SELECT ALL - 49 + + col2 AS col0 FROM tab1 AS cor0
----
47
5
8

query I rowsort
SELECT DISTINCT - + 65 - - col0 FROM tab0 AS cor0
----
-30
-41
24

query I rowsort
SELECT 49 + + col0 - col1 FROM tab1
----
103
116
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3424
SELECT CAST( NULL AS SIGNED ) * + col0 - col1 * - ( + tab1.col0 ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3424
SELECT CAST ( NULL AS INTEGER ) * + col0 - col1 * - ( + tab1.col0 ) FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3425
SELECT DISTINCT + - 92 DIV col1 - 57 FROM tab2 AS cor0
----
-58
-59
-62

skipif mysql # not compatible
query I rowsort label-3425
SELECT DISTINCT + - 92 / col1 - 57 FROM tab2 AS cor0
----
-58
-59
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3426
SELECT col0 * - col0 + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3426
SELECT col0 * - col0 + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * + cor0.col0 + col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT DISTINCT - ( + 51 ) + col1 AS col0 FROM tab0
----
35
40
46

query I rowsort
SELECT + ( - tab1.col0 * tab1.col0 ) + + 37 AS col2 FROM tab1
----
-4059
-6363
28

query IIIIII rowsort
SELECT * FROM tab0, tab0 cor0 WHERE NULL = ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab0.col1 col0 FROM tab0, tab0 AS cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3432
SELECT - col0 DIV col0 + + col2 AS col0 FROM tab2
----
25
26
37

skipif mysql # not compatible
query I rowsort label-3432
SELECT - col0 / col0 + + col2 AS col0 FROM tab2
----
25
26
37

query I rowsort
SELECT DISTINCT col0 * col0 * - col2 AS col1 FROM tab0
----
-1225
-19008
-649522

onlyif mysql # use DIV operator for integer division
query I rowsort label-3434
SELECT DISTINCT - tab1.col0 DIV col1 FROM tab1
----
-6
0

skipif mysql # not compatible
query I rowsort label-3434
SELECT DISTINCT - tab1.col0 / col1 FROM tab1
----
-6
0

query I rowsort
SELECT ( 53 ) FROM tab2
----
53
53
53

query I rowsort
SELECT ( - 56 ) FROM tab1
----
-56
-56
-56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 44 col2 FROM tab2
----
1364
2596
748

query I rowsort
SELECT + col2 + + cor0.col0 * - col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT col1 * + col0 * col1 - + cor0.col0 AS col1 FROM tab1 AS cor0
----
13440
2025
6336

onlyif mysql # use DIV operator for integer division
query I rowsort label-3440
SELECT DISTINCT + col2 + col2 DIV + col2 AS col0 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-3440
SELECT DISTINCT + col2 + col2 / + col2 AS col0 FROM tab1
----
55
58
97

query I rowsort
SELECT DISTINCT + 49 + col2 FROM tab2
----
75
76
87

query I rowsort
SELECT ALL 10 + col1 * + col2 FROM tab1
----
1258
1414
580

query I rowsort
SELECT ALL + 62 + tab1.col2 AS col0 FROM tab1
----
116
119
158

query I rowsort
SELECT DISTINCT - + ( + col0 ) + col0 AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL - ( - 30 ) + col1 + col0 AS col0 FROM tab0
----
140
162
210

query I rowsort
SELECT DISTINCT + ( + ( col0 ) ) + - col2 FROM tab0
----
-9
34
7

query I rowsort
SELECT ALL + - ( col2 ) + col0 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT col0 + - col2 + + col0 * col2 FROM tab2
----
169
2080
3043

query I rowsort
SELECT DISTINCT - - 18 AS col1 FROM tab1 cor0
----
18

query I rowsort
SELECT - col2 + + col0 AS col1 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT - ( col1 ) * col2 + col0 AS col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT + ( col2 ) + col1 AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT 11 + col2 * col2 FROM tab0 AS cor0
----
1100
12
6735

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col1 col0 FROM tab1
----
29
74
93

query I rowsort
SELECT + col2 + - col0 * - col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT ALL - col2 + tab0.col0 * - col1 * col1 AS col2 FROM tab0
----
-177537
-329316
-737091

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + + tab2.col0 col1 FROM tab2
----
-20
41
52

query I rowsort
SELECT - col1 * col2 * + tab0.col0 - col0 FROM tab0
----
-3430
-664207
-68136

query I rowsort
SELECT col1 * - col2 + + col0 AS col2 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT + col0 + - tab0.col2 + - col0 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT ALL - col2 FROM tab1 WHERE ( NULL ) NOT IN ( tab1.col2 + col0 )
----

query I rowsort
SELECT tab1.col0 * tab1.col0 + col2 + tab1.col1 AS col0 FROM tab1
----
4163
6509
89

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( NULL ) NOT BETWEEN ( col2 ) AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3464
SELECT - col1 * col2 * col0 + + col1 - col0 DIV + col0 col0 FROM tab0
----
-3299
-664028
-68027

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3464
SELECT - col1 * col2 * col0 + + col1 - col0 / + col0 col0 FROM tab0
----
-3299
-664028
-68027

query I rowsort
SELECT ALL col2 * + tab2.col0 AS col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT ALL col0 * col2 * tab1.col1 FROM tab1
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - col2 + - col1 col1 FROM tab0
----
-195
-205
-264

query I rowsort
SELECT ALL col1 + col1 * col2 AS col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT - col1 + + col1 FROM tab1 WHERE NULL NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT ALL col0 * col1 * col2 + - col0 FROM tab2
----
119574
50955
5852

query I rowsort
SELECT tab0.col0 * + col0 + col0 * - tab0.col1 FROM tab0
----
-1488
-178
-2170

query III rowsort
SELECT * FROM tab2 WHERE + col1 NOT BETWEEN - col0 - col1 AND + col1 * + col2 * + col1
----

query I rowsort
SELECT ALL tab0.col1 * - col2 AS col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - col2 * col2 + col0 FROM tab2
----
-1365
-598
-722

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL = ( col2 * col2 )
----

query I rowsort
SELECT ALL + col1 * + tab1.col0 FROM tab1 WHERE NOT - col0 + - col2 * col2 >= NULL
----

query I rowsort
SELECT DISTINCT + - col1 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL col1 * col1 + col0 FROM tab0
----
7420
8370
9444

query I rowsort
SELECT - col2 - - col0 * col1 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT DISTINCT - + col1 * + 13 AS col1 FROM tab1 AS cor0
----
-130
-169
-338

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( col2 ) col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL cor0.col0 AS col2 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT + 7 + + cor0.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 8572bc6ab6ac42a2a42ce047def95b65

query I rowsort
SELECT ALL + col0 * - 56 FROM tab1 AS cor0
----
-168
-3584
-4480

query I rowsort
SELECT col1 + - col1 * + col2 FROM tab1
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col1 ) + - cor0.col1 col0 FROM tab2 AS cor0
----
-118
-34
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3488
SELECT ALL + col1 DIV + cor0.col0 + + ( - ( + col0 ) ) AS col2 FROM tab2 AS cor0
----
-3
-78
-79

skipif mysql # not compatible
query I rowsort label-3488
SELECT ALL + col1 / + cor0.col0 + + ( - ( + col0 ) ) AS col2 FROM tab2 AS cor0
----
-3
-78
-79

query I rowsort
SELECT ALL - col1 * col2 + - ( col0 ) + + col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - 33 * col0 + col2 * + 14 FROM tab1 AS cor0
----
-1296
-1314
657

onlyif mysql # use DIV operator for integer division
query I rowsort label-3491
SELECT ALL cor0.col1 + + col0 + 18 DIV 78 col2 FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3491
SELECT ALL cor0.col1 + + col0 + 18 / 78 col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT + + 60 - - col2 FROM tab2 cor0
----
86
87
98

query I rowsort
SELECT + + 72 AS col1 FROM tab2 AS cor0
----
72
72
72

query I rowsort
SELECT ALL 57 * col2 + + col0 FROM tab2 AS cor0
----
1546
1560
2245

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3495
SELECT ALL - - col0 - col2 * CAST( col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-1168
-1401
-506

skipif mysql # not compatible
query I rowsort label-3495
SELECT ALL - - col0 - col2 * CAST ( col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-1168
-1401
-506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3496
SELECT DISTINCT + col2 + - cor0.col1 * CAST( + col0 AS SIGNED ) FROM tab2 AS cor0
----
-1305
-190
-4576

skipif mysql # not compatible
query I rowsort label-3496
SELECT DISTINCT + col2 + - cor0.col1 * CAST ( + col0 AS INTEGER ) FROM tab2 AS cor0
----
-1305
-190
-4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-3497
SELECT DISTINCT + - col0 DIV + col0 + col0 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-3497
SELECT DISTINCT + - col0 / + col0 + col0 FROM tab2 AS cor0
----
6
77
78

query I rowsort
SELECT + col0 + + ( col0 ) + col1 * - col0 FROM tab1 AS cor0
----
-512
-72
-880

query I rowsort
SELECT DISTINCT cor0.col2 - col2 AS col0 FROM tab0 cor0
----
0

query I rowsort
SELECT + + cor0.col2 * ( - col0 ) + col1 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT col0 * + 72 FROM tab2 AS cor0
----
504
5616
5688

query I rowsort
SELECT + col2 * col2 + - 58 + + col1 FROM tab1 AS cor0
----
2884
3201
9171

query I rowsort
SELECT - + col0 + + col2 * col1 AS col2 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT DISTINCT + + col2 + + 98 - + 33 * col2 AS col2 FROM tab0 cor0
----
-2526
-958
66

query I rowsort
SELECT + col1 - 22 FROM tab0 AS cor0
----
64
69
75

query I rowsort
SELECT - + cor0.col1 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT ( col2 ) * + cor0.col0 AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - ( 39 ) + col2 * col2 FROM tab2 AS cor0
----
1405
637
690

query I rowsort
SELECT + 1 FROM tab1, tab1 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 2a004dce2d308bae163576f54ee1a3fc

query I rowsort
SELECT + 52 * + col2 FROM tab1 AS cor0
----
2808
2964
4992

query I rowsort
SELECT DISTINCT ( cor0.col1 ) * - col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3512
SELECT + col2 * - CAST( NULL AS SIGNED ) - 29 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3512
SELECT + col2 * - CAST ( NULL AS INTEGER ) - 29 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 * col2 + col1 + ( - col2 ) * - col2 AS col1 FROM tab2 AS cor0
----
-1293
-1541
571

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 94 col0 FROM tab0 AS cor0
----
94
94
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-3515
SELECT + col0 DIV - 72 AS col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3515
SELECT + col0 / - 72 AS col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT - col0 + - col1 + + col2 * - col1 FROM tab2 AS cor0
----
-1671
-742
-875

onlyif mysql # use DIV operator for integer division
query I rowsort label-3517
SELECT ALL 33 DIV + col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3517
SELECT ALL 33 / + col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - + 30 + - col2 FROM tab0 AS cor0
----
-112
-31
-63

query I rowsort
SELECT ALL cor0.col2 * - 63 FROM tab0 cor0
----
-2079
-5166
-63

query I rowsort
SELECT ALL - + 99 + - 2 AS col1 FROM tab0 cor0
----
-101
-101
-101

onlyif mysql # use DIV operator for integer division
query I rowsort label-3521
SELECT - 34 + - 58 DIV col0 AS col0 FROM tab0 AS cor0
----
-34
-35
-36

skipif mysql # not compatible
query I rowsort label-3521
SELECT - 34 + - 58 / col0 AS col0 FROM tab0 AS cor0
----
-34
-35
-36

query I rowsort
SELECT DISTINCT - col1 * ( + col2 ) AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + tab2.col2 + ( col2 * + col0 ) + ( - col0 ) AS col2 FROM tab2
----
1976
209
2961

query I rowsort
SELECT + + col1 * col2 + col0 FROM tab1 AS cor0
----
1328
1407
634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 - 9 * ( col2 ) col2 FROM tab2
----
-208
-216
-304

query I rowsort
SELECT col2 + + 4 AS col1 FROM tab0
----
37
5
86

query I rowsort
SELECT ALL + ( col1 ) * col1 FROM tab0 cor0
----
7396
8281
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3528
SELECT DISTINCT - CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3528
SELECT DISTINCT - CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT 28 + + tab2.col0 FROM tab2
----
106
107
35

query I rowsort
SELECT ALL - col1 * + col0 + cor0.col0 AS col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT ALL + 14 * - tab0.col2 * 52 AS col1 FROM tab0
----
-24024
-59696
-728

query I rowsort
SELECT ALL col2 + col2 * col0 FROM tab2
----
2054
216
3040

query I rowsort
SELECT ALL col0 * col2 + 50 + col1 FROM tab0
----
182
7439
928

query I rowsort
SELECT DISTINCT col1 * 52 FROM tab2 AS cor0
----
1612
3068
884

query I rowsort
SELECT - cor0.col0 + ( col2 ) + + col2 * 70 * + col2 AS col2 FROM tab1 AS cor0
----
204171
227423
645136

query I rowsort
SELECT + col2 * + col1 * + col0 + col0 - - col1 * + col2 * + col2 FROM tab0 AS cor0
----
1276091
161790
3527

query I rowsort
SELECT + cor0.col1 * + 26 + - 20 - col1 FROM tab2 AS cor0
----
1455
405
755

onlyif mysql # use DIV operator for integer division
query I rowsort label-3538
SELECT ALL - cor0.col1 DIV - col0 + + 93 + - col1 FROM tab2 AS cor0
----
34
66
76

skipif mysql # not compatible
query I rowsort label-3538
SELECT ALL - cor0.col1 / - col0 + + 93 + - col1 FROM tab2 AS cor0
----
34
66
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-3539
SELECT DISTINCT 79 DIV + cor1.col2 + - 4 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
-2
-4
75

skipif mysql # not compatible
query I rowsort label-3539
SELECT DISTINCT 79 / + cor1.col2 + - 4 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
-2
-4
75

query I rowsort
SELECT DISTINCT + cor0.col1 + + col2 + 0 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3541
SELECT + col2 + - CAST( col1 AS SIGNED ) * - cor0.col1 FROM tab0 AS cor0
----
7429
8363
9410

skipif mysql # not compatible
query I rowsort label-3541
SELECT + col2 + - CAST ( col1 AS INTEGER ) * - cor0.col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT col2 * - col2 + + col1 AS col2 FROM tab0 AS cor0
----
-1003
-6633
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 55 col1 FROM tab0
----
55

query I rowsort
SELECT + - 99 * - cor0.col1 + - col1 FROM tab2 AS cor0
----
1666
3038
5782

query I rowsort
SELECT DISTINCT - col2 + - cor0.col0 FROM tab2 cor0
----
-104
-117
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col0 + - tab2.col1 col1 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT DISTINCT + col1 * col1 + tab2.col0 AS col2 FROM tab2
----
3559
368
968

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col2 + - ( col1 ) col2 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT 31 + 97 + + col0 AS col1 FROM tab1
----
131
192
208

query I rowsort
SELECT DISTINCT ( col2 ) * col1 + 56 AS col0 FROM tab1
----
1304
1460
626

query I rowsort
SELECT ALL - 80 + 7 AS col1 FROM tab0 AS cor0
----
-73
-73
-73

query I rowsort
SELECT DISTINCT col2 + + col1 * ( col1 * + col1 ) FROM tab0 AS cor0
----
636089
753653
912674

query I rowsort
SELECT DISTINCT 25 * - col0 + + col2 AS col0 FROM tab0 AS cor0
----
-2143
-567
-874

query I rowsort
SELECT 22 * + col1 - col0 FROM tab0 AS cor0
----
1868
1913
2099

query I rowsort
SELECT DISTINCT - 0 AS col2 FROM tab1, tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
0

query I rowsort
SELECT col2 * col1 * tab1.col0 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT cor0.col0 + + tab2.col1 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to af3a539c18b07c0d2d3147e1b73e81ac

query I rowsort
SELECT - 24 + + col2 FROM tab1
----
30
33
72

query I rowsort
SELECT 43 - - col2 AS col2 FROM tab0
----
125
44
76

query I rowsort
SELECT DISTINCT col0 + - col0 * col0 - col1 FROM tab1
----
-32
-4042
-6333

query I rowsort
SELECT + ( - 27 ) AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 0259a67676b131a4843853be4811b775

query I rowsort
SELECT + col0 + + cor0.col2 + - 28 FROM tab0 AS cor0
----
143
29
8

query I rowsort
SELECT - - cor0.col2 * col0 + cor0.col1 FROM tab2 cor0
----
2087
220
3019

query I rowsort
SELECT - - col0 + cor0.col1 + 81 * col0 AS col2 FROM tab1 AS cor0
----
272
5258
6573

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3565
SELECT + tab0.col1 + - CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3565
SELECT + tab0.col1 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - col0 + col2 - + col2 * 32 * + tab2.col0 FROM tab2
----
-6028
-64948
-96105

query I rowsort
SELECT + col1 * - col0 * tab0.col0 AS col0 FROM tab0
----
-118825
-49536
-720811

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3568
SELECT ( - col0 ) / + 85 + + ( + col0 ) * CAST( NULL AS SIGNED ) + - col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3568
SELECT ( - col0 ) / + 85 + + ( + col0 ) * CAST ( NULL AS INTEGER ) + - col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * col0 - + 41 FROM tab2
----
6043
6200
8

query I rowsort
SELECT - col0 * col1 - col1 * ( - col1 ) AS col2 FROM tab1 cor0
----
-540
-871
598

query I rowsort
SELECT ALL + col2 + + ( col2 * - 0 ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - - col1 * ( col2 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT col1 * 2 * + 31 AS col1 FROM tab0
----
5332
5642
6014

query I rowsort
SELECT ALL + - 14 * + col2 + - col2 FROM tab2 cor0
----
-390
-405
-570

query I rowsort
SELECT + + 75 * 71 AS col2 FROM tab2 AS cor0
----
5325
5325
5325

onlyif mysql # use DIV operator for integer division
query I rowsort label-3576
SELECT DISTINCT col0 * col0 * - col2 + col0 DIV - col1 FROM tab1
----
-233478
-486
-614406

skipif mysql # not compatible
query I rowsort label-3576
SELECT DISTINCT col0 * col0 * - col2 + col0 / - col1 FROM tab1
----
-233478
-486
-614406

query I rowsort
SELECT - ( - col0 ) + ( col2 ) - col1 AS col0 FROM tab1
----
111
163
31

query I rowsort
SELECT DISTINCT + 36 AS col2 FROM tab0, tab2, tab1 AS cor0
----
36

query I rowsort
SELECT cor0.col2 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3580
SELECT ALL col2 + col2 * CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3580
SELECT ALL col2 + col2 * CAST ( NULL AS INTEGER ) * col1 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab1.col2 + + tab1.col0 + ( + col1 ) AS col1 FROM tab1
----
131
189
83

query I rowsort
SELECT + 65 * - col2 * + 4 FROM tab2
----
-6760
-7020
-9880

query I rowsort
SELECT DISTINCT + cor0.col0 + - ( cor0.col1 * + col2 ) FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-3584
SELECT ALL - + col1 * 67 + + col2 * + col0 DIV + col0 FROM tab0 AS cor0
----
-5729
-6015
-6498

skipif mysql # not compatible
query I rowsort label-3584
SELECT ALL - + col1 * 67 + + col2 * + col0 / + col0 FROM tab0 AS cor0
----
-5729
-6015
-6498

query I rowsort
SELECT - tab0.col1 + ( col2 + tab0.col1 ) * tab0.col2 FROM tab0
----
1
14095
3841

query I rowsort
SELECT DISTINCT 64 AS col0 FROM tab1, tab2 AS cor0
----
64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3587
SELECT ALL + - col2 / CAST( NULL AS DECIMAL ) + col0 * cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3587
SELECT ALL + - col2 / CAST ( NULL AS REAL ) + col0 * cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 + ( - col2 ) * col1 + + 69 * col2 FROM tab1 AS cor0
----
2296
3353
5363

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - ( - col1 ) col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL col0 * col2 + col0 + - col1 AS col1 FROM tab2 AS cor0
----
165
2047
3064

query I rowsort
SELECT - col1 * + 29 * col2 FROM tab2 cor0
----
-18734
-24273
-44486

onlyif mysql # use DIV operator for integer division
query I rowsort label-3592
SELECT + col0 DIV 89 AS col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3592
SELECT + col0 / 89 AS col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT ALL - col0 + - cor0.col0 FROM tab0 cor0
----
-178
-48
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3594
SELECT - - col1 * + col2 / col0 + CAST( NULL AS DECIMAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3594
SELECT - - col1 * + col2 / col0 + CAST ( NULL AS REAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 - + 11 FROM tab2
----
-4
67
68

query I rowsort
SELECT + + col0 + - col0 * col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT - ( 67 ) * - col1 FROM tab1 AS cor0
----
1742
670
871

query I rowsort
SELECT + - ( 23 ) FROM tab0 AS cor0
----
-23
-23
-23

query I rowsort
SELECT col1 * 12 FROM tab0 AS cor0
----
1032
1092
1164

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 6 - + 3 col1 FROM tab1 AS cor0
----
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 40 - - col1 col2 FROM tab1 AS cor0
----
50
53
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3602
SELECT CAST( + col0 AS SIGNED ) + - col0 * + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3602
SELECT CAST ( + col0 AS INTEGER ) + - col0 * + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 42 * + col1 - col0 * 3 FROM tab2 AS cor0
----
1281
2244
477

query I rowsort
SELECT - col1 + - ( - col0 ) * col1 AS col0 FROM tab1 cor0
----
1027
52
630

query I rowsort
SELECT ALL 79 * col0 - - 54 FROM tab2 AS cor0
----
607
6216
6295

onlyif mysql # use DIV operator for integer division
query I rowsort label-3606
SELECT ALL col1 - cor0.col1 DIV ( + col2 + + col0 ) FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-3606
SELECT ALL col1 - cor0.col1 / ( + col2 + + col0 ) FROM tab2 AS cor0
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3607
SELECT - CAST( cor0.col1 AS SIGNED ) AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

skipif mysql # not compatible
query I rowsort label-3607
SELECT - CAST ( cor0.col1 AS INTEGER ) AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT DISTINCT - col1 - + col0 * col0 * - 11 FROM tab1 AS cor0
----
45046
70387
73

query I rowsort
SELECT - col0 * - col2 + ( + 78 ) AS col1 FROM tab2 AS cor0
----
2106
267
3080

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 cor0, tab1, tab2 cor1
----
972 values hashing to bcf430f79386b43bc4077271fcd15cf0

query I rowsort
SELECT cor1.col1 * 59 + cor0.col0 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 2383342b89854c1b814a9c041196e2af

query I rowsort
SELECT 55 - col2 AS col2 FROM tab1 AS cor0
----
-2
-41
1

query I rowsort
SELECT ALL - 9 + col0 FROM tab1 AS cor0
----
-6
55
71

query I rowsort
SELECT + - col0 - - col0 * - col2 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT + - col1 + cor0.col2 * - col2 AS col0 FROM tab0 AS cor0
----
-1175
-6815
-98

query I rowsort
SELECT 87 * + col0 + + col1 + col2 * col0 FROM tab2 AS cor0
----
829
8873
9892

query I rowsort
SELECT ALL + + ( - col2 ) + col0 AS col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT + - 69 * col1 - - 87 AS col0 FROM tab1 AS cor0
----
-1707
-603
-810

query I rowsort
SELECT + 38 - + cor0.col0 AS col1 FROM tab0 AS cor0
----
-51
14
3

query I rowsort
SELECT DISTINCT col1 * - col1 - col2 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT ALL + 77 * col1 FROM tab2 AS cor0
----
1309
2387
4543

query I rowsort
SELECT 25 - - col2 AS col1 FROM tab0 AS cor0
----
107
26
58

query I rowsort
SELECT DISTINCT + + 64 + col0 AS col2 FROM tab0 AS cor0
----
153
88
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3624
SELECT ALL + col2 - - col2 * - CAST( - col2 AS SIGNED ) FROM tab0 AS cor0
----
1122
2
6806

skipif mysql # not compatible
query I rowsort label-3624
SELECT ALL + col2 - - col2 * - CAST ( - col2 AS INTEGER ) FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT ALL - cor0.col2 + - col1 AS col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT + + col1 * 89 + 93 FROM tab0 AS cor0
----
7747
8192
8726

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3627
SELECT DISTINCT + 52 + + col2 * CAST( col2 AS SIGNED ) AS col1 FROM tab2
----
1496
728
781

skipif mysql # not compatible
query I rowsort label-3627
SELECT DISTINCT + 52 + + col2 * CAST ( col2 AS INTEGER ) AS col1 FROM tab2
----
1496
728
781

query I rowsort
SELECT 10 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query I rowsort
SELECT - 71 * col1 + + 22 AS col1 FROM tab0
----
-6084
-6439
-6865

query I rowsort
SELECT ALL - col2 * tab1.col1 + - col1 FROM tab1
----
-1261
-1430
-580

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3631
SELECT DISTINCT - ( col1 ) + col2 * + CAST( - 55 AS SIGNED ) FROM tab2 AS cor0
----
-1489
-1516
-2107

skipif mysql # not compatible
query I rowsort label-3631
SELECT DISTINCT - ( col1 ) + col2 * + CAST ( - 55 AS INTEGER ) FROM tab2 AS cor0
----
-1489
-1516
-2107

query I rowsort
SELECT DISTINCT + cor0.col0 * 10 AS col0 FROM tab0 AS cor0
----
240
350
890

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 33 col2 FROM tab1 AS cor0
----
33
33
33

query I rowsort
SELECT DISTINCT + ( - 14 ) * + cor0.col1 FROM tab2 AS cor0
----
-238
-434
-826

query I rowsort
SELECT col2 * + col1 + col2 AS col2 FROM tab0
----
2871
7544
98

query I rowsort
SELECT ALL 26 FROM tab1, tab2 cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT ( - col0 ) * + col2 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + 35 AS col2 FROM tab2, tab2 AS cor0
----
35

query I rowsort
SELECT - tab2.col2 * - tab2.col0 FROM tab2
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3640
SELECT ALL - col2 + CAST( NULL AS SIGNED ) col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3640
SELECT ALL - col2 + CAST ( NULL AS INTEGER ) col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col2 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT DISTINCT + col1 + col0 AS col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT - + col1 * 46 FROM tab2 AS cor0
----
-1426
-2714
-782

onlyif mysql # use DIV operator for integer division
query I rowsort label-3644
SELECT ALL col1 * + 20 + 78 DIV + col2 FROM tab1 AS cor0
----
201
260
521

skipif mysql # not compatible
query I rowsort label-3644
SELECT ALL col1 * + 20 + 78 / + col2 FROM tab1 AS cor0
----
201
260
521

skipif mysql # not compatible
query I rowsort
SELECT col2 + CAST ( ( + col2 ) AS REAL ) * - cor0.col1 AS col0 FROM tab1 cor0
----
-1152
-1350
-513

query I rowsort
SELECT - col0 * ( col0 ) FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT ALL + col1 * ( - 60 ) FROM tab2 AS cor0
----
-1020
-1860
-3540

query I rowsort
SELECT + + col0 - + 47 AS col0 FROM tab2 AS cor0
----
-40
31
32

query I rowsort
SELECT 54 FROM tab2, tab0 cor0
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT + ( + col0 ) + - col2 AS col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT - cor1.col0 AS col2 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT ALL + 50 + 15 AS col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 1c9d0bf96cd3361942fadad668138b9c

query I rowsort
SELECT ALL 77 * col0 FROM tab0 AS cor0
----
1848
2695
6853

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 94 * - col0 * - ( 56 * - col1 ) col0 FROM tab2
----
-1142288
-24224928
-7069552

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * tab2.col0 * - col2 col2 FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT DISTINCT + - ( col2 ) * 69 AS col1 FROM tab0 AS cor0
----
-2277
-5658
-69

query I rowsort
SELECT - - col1 * + ( + col0 ) + + col0 * - col2 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT DISTINCT - 9 * + col1 FROM tab0 AS cor0
----
-774
-819
-873

query I rowsort
SELECT DISTINCT + cor0.col2 + 30 * col0 AS col1 FROM tab0 cor0
----
1051
2752
753

query I rowsort
SELECT ALL - 8 + col0 FROM tab0 cor0
----
16
27
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-3661
SELECT ALL col1 * 77 DIV - col1 FROM tab1 AS cor0
----
-77
-77
-77

skipif mysql # not compatible
query I rowsort label-3661
SELECT ALL col1 * 77 / - col1 FROM tab1 AS cor0
----
-77
-77
-77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3662
SELECT ALL CAST( + cor0.col1 AS SIGNED ) FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3662
SELECT ALL CAST ( + cor0.col1 AS INTEGER ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - 51 * - 76 FROM tab1 cor0
----
3876
3876
3876

query I rowsort
SELECT ALL col1 * 85 AS col0 FROM tab1
----
1105
2210
850

query I rowsort
SELECT 35 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 0d13dfd4c4a9d51ace3582c31cadcdbc

onlyif mysql # use DIV operator for integer division
query I rowsort label-3666
SELECT - col1 DIV + col1 + + CAST( - col0 AS SIGNED ) * - col0 AS col2 FROM tab1 AS cor0
----
4095
6399
8

skipif mysql # not compatible
query I rowsort label-3666
SELECT - col1 / + col1 + + CAST ( - col0 AS INTEGER ) * - col0 AS col2 FROM tab1 AS cor0
----
4095
6399
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-3667
SELECT + + col0 + - cor0.col2 DIV + col1 AS col2 FROM tab2 AS cor0
----
7
77
78

skipif mysql # not compatible
query I rowsort label-3667
SELECT + + col0 + - cor0.col2 / + col1 AS col2 FROM tab2 AS cor0
----
7
77
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3668
SELECT 22 * + col0 + + col0 DIV - col0 FROM tab1 AS cor0
----
1407
1759
65

skipif mysql # not compatible
query I rowsort label-3668
SELECT 22 * + col0 + + col0 / - col0 FROM tab1 AS cor0
----
1407
1759
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3669
SELECT CAST( col1 AS SIGNED ) AS col2 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-3669
SELECT CAST ( col1 AS INTEGER ) AS col2 FROM tab2
----
17
31
59

query I rowsort
SELECT ALL ( + col0 + col2 ) * col1 AS col2 FROM tab2
----
1054
1989
6136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3671
SELECT ALL - + CAST( NULL AS SIGNED ) col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3671
SELECT ALL - + CAST ( NULL AS INTEGER ) col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + + ( col0 ) + 44 FROM tab1 AS cor0
----
108
124
47

query I rowsort
SELECT + + col0 + + cor0.col1 * - ( col2 + col2 ) FROM tab0 AS cor0
----
-14835
-159
-5652

query I rowsort
SELECT - col0 + col1 * - col1 FROM tab2 AS cor0
----
-3559
-368
-968

query I rowsort
SELECT - cor0.col1 + cor0.col0 + - ( - col1 ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL + ( col2 ) + 63 * + col0 AS col0 FROM tab0 cor0
----
1545
2206
5689

query I rowsort
SELECT ALL + - 47 * + col1 AS col0 FROM tab1 cor0
----
-1222
-470
-611

query I rowsort
SELECT ALL col1 + - col2 * col0 + col2 FROM tab1
----
-3581
-7571
-82

query III rowsort
SELECT * FROM tab0 WHERE - col0 - col0 < ( NULL )
----

query I rowsort
SELECT + col2 + + tab2.col0 + col2 * - col0 AS col1 FROM tab2
----
-155
-1924
-2885

onlyif mysql # use DIV operator for integer division
query I rowsort label-3681
SELECT DISTINCT + col0 DIV + col1 AS col1 FROM tab1
----
0
6

skipif mysql # not compatible
query I rowsort label-3681
SELECT DISTINCT + col0 / + col1 AS col1 FROM tab1
----
0
6

query I rowsort
SELECT ALL - - ( + col2 ) + col1 AS col0 FROM tab1 cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 - cor0.col0 col0 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT + col2 * col1 * - ( col1 ) FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT - 62 FROM tab0 cor0
----
-62

query I rowsort
SELECT ALL + col1 + - col2 FROM tab1 WHERE NOT - col1 = ( col2 * col2 - tab1.col2 )
----
-28
-47
-83

query I rowsort
SELECT + col0 + - col2 * col0 AS col0 FROM tab0
----
-7209
-768
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 + - col1 col1 FROM tab1
----
-1261
-1430
-580

query I rowsort
SELECT - col2 + + col0 * tab2.col1 AS col1 FROM tab2
----
1305
190
4576

query I rowsort
SELECT DISTINCT col1 * col1 + col0 AS col2 FROM tab0
----
7420
8370
9444

query I rowsort
SELECT ALL 28 + col0 AS col0 FROM tab1
----
108
31
92

query I rowsort
SELECT col2 * col2 AS col2 FROM tab2 WHERE NOT NULL > col0 * - col0
----

query I rowsort
SELECT ALL col2 * col1 + - col1 * + col2 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 + - col1 AS col0 FROM tab0 WHERE NOT NULL <> col0 + + col1
----

query I rowsort
SELECT DISTINCT col1 + - tab0.col0 * - col1 FROM tab0
----
2150
3492
8190

query III rowsort
SELECT * FROM tab1 WHERE NOT ( col0 * - col0 / + col2 ) NOT IN ( + tab1.col2 + tab1.col2 / col1 + + col2 )
----

query I rowsort
SELECT DISTINCT col1 + tab1.col1 AS col0 FROM tab1
----
20
26
52

query I rowsort
SELECT col1 * - col1 + - col1 + + col2 AS col2 FROM tab1
----
-53
-648
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col1 + + col2 col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT ALL + col1 - + col2 FROM tab1 WHERE NOT NULL <> col1
----

query I rowsort
SELECT col2 + - col0 * + col1 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT tab1.col1 * - tab1.col2 * - tab1.col1 AS col1 FROM tab1
----
16224
36504
5700

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL IN ( tab1.col1 - col1 / col0 )
----

query I rowsort
SELECT col1 + col0 * + col0 FROM tab1
----
35
4106
6413

query I rowsort
SELECT col0 + + col1 + - col2 AS col1 FROM tab1
----
-25
-3
17

query I rowsort
SELECT DISTINCT col1 + col0 + col2 FROM tab0
----
133
143
262

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT + col0 - col1 / col0 BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT + col2 + col2 * + col0 + col1 * + col0 AS col2 FROM tab2
----
433
4383
6656

onlyif mysql # use DIV operator for integer division
query I rowsort label-3709
SELECT ALL - col0 DIV tab1.col0 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3709
SELECT ALL - col0 / tab1.col0 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col0 + col2 * - col1 AS col0 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT ALL - col0 * col2 * tab2.col0 FROM tab2 WHERE ( NULL ) <= NULL
----

query I rowsort
SELECT - col0 FROM tab0 WHERE NOT NULL BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL + col1 - + col2 * + col0 FROM tab2
----
-158
-1969
-2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-3714
SELECT DISTINCT - col0 DIV col2 + - tab0.col1 AS col1 FROM tab0
----
-132
-86
-92

skipif mysql # not compatible
query I rowsort label-3714
SELECT DISTINCT - col0 / col2 + - tab0.col1 AS col1 FROM tab0
----
-132
-86
-92

query I rowsort
SELECT ALL + col0 * col1 * col2 AS col0 FROM tab2 WHERE NOT NULL IN ( col2 * - col2 * + col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 26 col0 FROM tab1
----
26

query I rowsort
SELECT + col2 + - 17 FROM tab0
----
-16
16
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-3718
SELECT DISTINCT - ( - 21 ) DIV tab0.col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-3718
SELECT DISTINCT - ( - 21 ) / tab0.col1 FROM tab0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3719
SELECT + tab1.col2 + - 98 DIV + col2 AS col1 FROM tab1
----
53
56
95

skipif mysql # not compatible
query I rowsort label-3719
SELECT + tab1.col2 + - 98 / + col2 AS col1 FROM tab1
----
53
56
95

query I rowsort
SELECT ( + col1 ) + + col0 AS col1 FROM tab0
----
110
132
180

query I rowsort
SELECT - 28 FROM tab0, tab1 cor0
----
9 values hashing to c3e7fa3d059fc708f03c60e9cef0c115

query I rowsort
SELECT ALL - + col1 * 21 AS col1 FROM tab2 AS cor0
----
-1239
-357
-651

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3723
SELECT DISTINCT + CAST( NULL AS SIGNED ) / + ( - col1 ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3723
SELECT DISTINCT + CAST ( NULL AS INTEGER ) / + ( - col1 ) AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + - col2 + col2 + 29 * - col0 FROM tab1 cor0
----
-1856
-2320
-87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3725
SELECT DISTINCT ( + col1 ) + + CAST( + ( col0 ) * 4 + - col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
140
356
96

skipif mysql # not compatible
query I rowsort label-3725
SELECT DISTINCT ( + col1 ) + + CAST ( + ( col0 ) * 4 + - col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
140
356
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 63 col1 FROM tab0 AS cor0
----
63
63
63

query I rowsort
SELECT + col2 * col2 - - 13 AS col1 FROM tab0 AS cor0
----
1102
14
6737

query I rowsort
SELECT DISTINCT - cor0.col0 + col0 * 90 * col0 AS col1 FROM tab2 AS cor0
----
4403
547482
561611

onlyif mysql # use DIV operator for integer division
query I rowsort label-3729
SELECT - col1 DIV col0 + col2 DIV - ( col1 ) AS col0 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-3729
SELECT - col1 / col0 + col2 / - ( col1 ) AS col0 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT 93 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT ALL + col1 * - col0 * ( - col0 ) FROM tab1 AS cor0
----
234
40960
83200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3732
SELECT DISTINCT + + col0 + + col0 + CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3732
SELECT DISTINCT + + col0 + + col0 + CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - col1 * + col2 * ( - col1 ) AS col2 FROM tab2
----
10982
25947
90506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * + ( - col0 ) - col1 * col2 * - col1 col2 FROM tab0 AS cor0
----
10634
244644
686963

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3735
SELECT - col0 * - CAST( 41 AS SIGNED ) * - tab0.col1 AS col0 FROM tab0
----
-139195
-332059
-84624

skipif mysql # not compatible
query I rowsort label-3735
SELECT - col0 * - CAST ( 41 AS INTEGER ) * - tab0.col1 AS col0 FROM tab0
----
-139195
-332059
-84624

query I rowsort
SELECT DISTINCT 65 AS col2 FROM tab2, tab1 AS cor0
----
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - 0 col1 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL - col2 * col2 AS col0 FROM tab2 cor0
----
-1444
-676
-729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3739
SELECT DISTINCT - col0 + CAST( NULL AS SIGNED ) + cor0.col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3739
SELECT DISTINCT - col0 + CAST ( NULL AS INTEGER ) + cor0.col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - + col0 * 36 + - col2 AS col1 FROM tab1 AS cor0
----
-162
-2361
-2976

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * + col0 - col1 col1 FROM tab1 AS cor0
----
-35
-4106
-6413

query I rowsort
SELECT ALL + col0 + 52 FROM tab0 AS cor0
----
141
76
87

query I rowsort
SELECT DISTINCT - - cor0.col1 + col2 AS col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL + col1 * - 87 AS col2 FROM tab1 AS cor0
----
-1131
-2262
-870

query I rowsort
SELECT col2 * - 28 + + col0 * + col2 FROM tab2 AS cor0
----
-567
1300
1938

query I rowsort
SELECT DISTINCT + + col0 + 83 * - cor0.col1 * cor0.col1 AS col1 FROM tab1 AS cor0
----
-13947
-56105
-8236

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 + col2 * - col0 col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT ALL - - col2 + + 51 * col1 * 57 FROM tab1 AS cor0
----
29127
37887
75636

onlyif mysql # use DIV operator for integer division
query I rowsort label-3749
SELECT DISTINCT - 18 DIV 87 FROM tab2 cor0
----
0

skipif mysql # not compatible
query I rowsort label-3749
SELECT DISTINCT - 18 / 87 FROM tab2 cor0
----
0

query I rowsort
SELECT - col0 + - 19 AS col1 FROM tab1 cor0
----
-22
-83
-99

query I rowsort
SELECT col1 - 71 * col1 FROM tab1
----
-1820
-700
-910

query I rowsort
SELECT + - cor0.col2 + - col1 * + col2 FROM tab2 cor0
----
-1560
-684
-864

query I rowsort
SELECT + + 7 * - col0 AS col0 FROM tab1 AS cor0
----
-21
-448
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-3754
SELECT DISTINCT 39 DIV + col0 FROM tab2
----
0
5

skipif mysql # not compatible
query I rowsort label-3754
SELECT DISTINCT 39 / + col0 FROM tab2
----
0
5

query I rowsort
SELECT DISTINCT ( - tab2.col0 * col2 + + col0 ) FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT ALL + tab2.col1 * col0 AS col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT 3 * + col1 * col2 AS col1 FROM tab0 AS cor0
----
22386
291
8514

query I rowsort
SELECT col2 * 65 * - col1 + tab1.col2 * + col1 AS col2 FROM tab1
----
-36480
-79872
-89856

query I rowsort
SELECT + col1 * ( - col2 ) AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + - cor0.col1 * + col1 AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-3761
SELECT ALL col1 * 15 DIV col0 FROM tab0 cor0
----
15
41
53

skipif mysql # not compatible
query I rowsort label-3761
SELECT ALL col1 * 15 / col0 FROM tab0 cor0
----
15
41
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-3762
SELECT + + col2 * ( col0 ) DIV col0 + + col0 * - col0 FROM tab0 AS cor0
----
-1224
-543
-7839

skipif mysql # not compatible
query I rowsort label-3762
SELECT + + col2 * ( col0 ) / col0 + + col0 * - col0 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT + tab0.col1 * - ( col2 ) FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT ( - 95 ) FROM tab2, tab0 AS cor0
----
9 values hashing to 1c7934db0632c123332c43f17b661d6c

query I rowsort
SELECT + col1 * - col2 * col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT - + 78 AS col0 FROM tab1 AS cor0
----
-78
-78
-78

query I rowsort
SELECT 30 FROM tab2, tab1 cor0
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

query I rowsort
SELECT DISTINCT - cor0.col0 * - cor0.col0 AS col1 FROM tab1, tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - cor0.col2 FROM tab1, tab2 AS cor0 CROSS JOIN tab2
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT - + cor0.col2 * col0 + col2 AS col2 FROM tab0 AS cor0
----
-34
-7216
-759

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT ( NULL ) BETWEEN ( col0 * + col1 + + col2 ) AND col0 OR + col2 > - col0 * - cor0.col1
----

query I rowsort
SELECT + - col1 + col0 * col0 * col2 AS col2 FROM tab2 AS cor0
----
1292
158125
237141

query I rowsort
SELECT ALL cor0.col2 FROM tab0 AS cor0 WHERE col0 * col0 = NULL
----

query I rowsort
SELECT ALL - col2 + col1 * col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT - col1 * - col2 + col0 * col0 AS col1 FROM tab1 AS cor0
----
1413
4666
7648

query I rowsort
SELECT + col0 * col0 + col1 * + col2 + - cor0.col1 FROM tab2 AS cor0
----
6870
7559
855

query I rowsort
SELECT DISTINCT tab0.col1 - + col1 FROM tab0
----
0

query I rowsort
SELECT col1 * col2 * - col2 AS col0 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT + col0 - col1 * - tab1.col2 AS col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT ALL col2 * col0 - - cor0.col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT - + col1 * + col1 + + col0 AS col0 FROM tab1 AS cor0
----
-36
-673
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3782
SELECT DISTINCT - - col1 DIV - col1 - - col0 AS col2 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-3782
SELECT DISTINCT - - col1 / - col1 - - col0 AS col2 FROM tab0 AS cor0
----
23
34
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-3783
SELECT DISTINCT col2 DIV cor0.col0 + + col2 AS col1 FROM tab2 AS cor0
----
26
30
38

skipif mysql # not compatible
query I rowsort label-3783
SELECT DISTINCT col2 / cor0.col0 + + col2 AS col1 FROM tab2 AS cor0
----
26
30
38

query I rowsort
SELECT DISTINCT + + cor0.col1 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT col2 * - col0 - + col2 FROM tab0 AS cor0
----
-36
-7380
-825

onlyif mysql # use DIV operator for integer division
query I rowsort label-3786
SELECT DISTINCT + col2 - col2 DIV col1 FROM tab2
----
26
27
36

skipif mysql # not compatible
query I rowsort label-3786
SELECT DISTINCT + col2 - col2 / col1 FROM tab2
----
26
27
36

query I rowsort
SELECT + col1 * - col0 + col0 * col2 * col1 AS col0 FROM tab2
----
115050
49691
5642

query I rowsort
SELECT ALL col2 * col0 * col1 AS col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT DISTINCT + col1 - + col1 AS col1 FROM tab0 WHERE ( - col0 ) IN ( - col0 ) AND NULL NOT IN ( tab0.col0 - - col1 * - col2 )
----

query I rowsort
SELECT DISTINCT - col2 * - cor0.col1 AS col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - + col2 * - 18 FROM tab1 AS cor0
----
1026
1728
972

query I rowsort
SELECT DISTINCT + col1 * 20 + - col2 * col2 FROM tab0 cor0
----
-4904
1939
631

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - col0 col0 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT + col0 * ( + cor0.col2 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL + cor0.col2 * 56 + - col2 AS col2 FROM tab2 cor0
----
1430
1485
2090

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 72 col0 FROM tab0 AS cor0
----
-6192
-6552
-6984

query I rowsort
SELECT DISTINCT + col0 - + 68 FROM tab0 AS cor0
----
-33
-44
21

query I rowsort
SELECT DISTINCT col2 * col1 + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + cor0.col2 + - 45 FROM tab2 AS cor0
----
-18
-19
-7

query I rowsort
SELECT + - 31 * col0 + + col2 FROM tab2 AS cor0
----
-190
-2392
-2411

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3801
SELECT DISTINCT CAST( col2 AS SIGNED ) * + col1 * - col2 + - ( - col2 ) * + 67 FROM tab1 AS cor0
----
-113376
-28671
-72198

skipif mysql # not compatible
query I rowsort label-3801
SELECT DISTINCT CAST ( col2 AS INTEGER ) * + col1 * - col2 + - ( - col2 ) * + 67 FROM tab1 AS cor0
----
-113376
-28671
-72198

query I rowsort
SELECT DISTINCT col2 * col0 + col2 * col1 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT - 80 * 9 * col2 AS col2 FROM tab1 cor0
----
-38880
-41040
-69120

query I rowsort
SELECT ALL - cor0.col1 * - col0 - + cor0.col1 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT DISTINCT + ( - 67 ) FROM tab2 AS cor0
----
-67

query I rowsort
SELECT + - col0 + + 6 FROM tab0 AS cor0
----
-18
-29
-83

query I rowsort
SELECT - col2 - + 97 AS col2 FROM tab2 AS cor0
----
-123
-124
-135

query I rowsort
SELECT ALL - ( cor0.col2 ) + col1 AS col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + 14 - col1 * col2 FROM tab1 AS cor0
----
-1234
-1390
-556

query I rowsort
SELECT ALL 38 * col1 FROM tab0 AS cor0
----
3268
3458
3686

query I rowsort
SELECT + col1 * 7 * - col0 + col0 * ( + col2 * 89 + col0 ) FROM tab2 AS cor0
----
15351
154362
264018

query I rowsort
SELECT DISTINCT col1 - 38 FROM tab0
----
48
53
59

query I rowsort
SELECT - tab0.col2 + - ( + ( col0 ) * - 18 ) FROM tab0
----
1520
399
629

onlyif mysql # use DIV operator for integer division
query I rowsort label-3814
SELECT col1 DIV - 92 + col2 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3814
SELECT col1 / - 92 + col2 FROM tab1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3815
SELECT col0 + col2 DIV 19 AS col0 FROM tab2
----
79
8
81

skipif mysql # not compatible
query I rowsort label-3815
SELECT col0 + col2 / 19 AS col0 FROM tab2
----
79
8
81

query I rowsort
SELECT tab1.col1 + tab1.col2 - + col2 * tab1.col2 FROM tab1
----
-2836
-3182
-9107

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3817
SELECT ALL + tab2.col1 * + 37 * - 27 - + tab2.col1 * CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3817
SELECT ALL + tab2.col1 * + 37 * - 27 - + tab2.col1 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + 75 AS col1 FROM tab0 AS cor0
----
75
75
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 + col2 * + 77 col0 FROM tab2 AS cor0
----
1943
2048
2909

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - cor0.col1 * 42 col2 FROM tab0 AS cor0
----
-3526
-3731
-3977

onlyif mysql # use DIV operator for integer division
query I rowsort label-3821
SELECT DISTINCT - 2 + col2 DIV + 39 FROM tab2 AS cor0
----
-2

skipif mysql # not compatible
query I rowsort label-3821
SELECT DISTINCT - 2 + col2 / + 39 FROM tab2 AS cor0
----
-2

query I rowsort
SELECT - col2 + col1 * col2 * + 87 FROM tab0 AS cor0
----
246873
649112
8438

onlyif mysql # use DIV operator for integer division
query I rowsort label-3823
SELECT - + col1 + col2 DIV col2 AS col0 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-3823
SELECT - + col1 + col2 / col2 AS col0 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT DISTINCT - + 42 * - col2 FROM tab2 AS cor0
----
1092
1134
1596

query I rowsort
SELECT + ( 95 + + tab0.col1 ) AS col2 FROM tab0
----
181
186
192

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3826
SELECT + CAST( NULL AS SIGNED ) - + col1 * - col2 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3826
SELECT + CAST ( NULL AS INTEGER ) - + col1 * - col2 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * col1 + col2 AS col0 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL 79 * - col1 * 3 FROM tab1 cor0
----
-2370
-3081
-6162

query I rowsort
SELECT ALL - col2 * col1 * 10 + + col0 FROM tab1 AS cor0
----
-12400
-14037
-5636

query I rowsort
SELECT ( 65 ) FROM tab2
----
65
65
65

query I rowsort
SELECT ALL 89 * + col1 * col1 FROM tab2
----
25721
309809
85529

query I rowsort
SELECT - col1 * col1 * col1 AS col2 FROM tab1 AS cor0
----
-1000
-17576
-2197

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 54 col2 FROM tab0
----
54
54
54

query I rowsort
SELECT + col0 + + 87 * cor0.col1 AS col1 FROM tab2 AS cor0
----
1558
2704
5211

query I rowsort
SELECT - col0 * 91 FROM tab1 AS cor0
----
-273
-5824
-7280

query I rowsort
SELECT ALL - ( - tab0.col2 ) * tab0.col0 * - col0 FROM tab0
----
-1225
-19008
-649522

query I rowsort
SELECT ALL + ( - col1 ) * + col0 * + col1 AS col2 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT ALL - + col2 * 12 FROM tab2 AS cor0
----
-312
-324
-456

query I rowsort
SELECT - col1 + + ( + col0 ) * col2 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT DISTINCT + col2 * + 97 * col1 FROM tab0 cor0
----
275286
723814
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-3841
SELECT DISTINCT + col0 * cor0.col2 DIV + col1 AS col0 FROM tab2 AS cor0
----
176
34
6

skipif mysql # not compatible
query I rowsort label-3841
SELECT DISTINCT + col0 * cor0.col2 / + col1 AS col0 FROM tab2 AS cor0
----
176
34
6

query I rowsort
SELECT + ( - tab1.col1 ) + col2 AS col1 FROM tab1
----
28
47
83

query I rowsort
SELECT DISTINCT 38 FROM tab2, tab1 AS cor0 CROSS JOIN tab1
----
38

query I rowsort
SELECT ALL - col2 * - col2 + - cor0.col2 FROM tab1 AS cor0
----
2862
3192
9120

query I rowsort
SELECT - 2 * + 99 + - col0 * 43 FROM tab2 AS cor0
----
-3552
-3595
-499

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 + col0 * + cor0.col1 col1 FROM tab2 cor0
----
1326
186
4543

query I rowsort
SELECT DISTINCT 7 * col0 AS col1 FROM tab0 AS cor0
----
168
245
623

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + 10 ) * + col1 - col0 col2 FROM tab2 AS cor0
----
303
512
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-3849
SELECT ALL - col0 DIV - col2 + col2 FROM tab1 AS cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-3849
SELECT ALL - col0 / - col2 + col2 FROM tab1 AS cor0
----
54
58
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 * col0 - - cor0.col1 * ( + col2 ) col0 FROM tab1 AS cor0
----
1566
4218
8928

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3851
SELECT CAST( 83 AS SIGNED ) FROM tab1 AS cor0
----
83
83
83

skipif mysql # not compatible
query I rowsort label-3851
SELECT CAST ( 83 AS INTEGER ) FROM tab1 AS cor0
----
83
83
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3852
SELECT ALL - 90 + + col2 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3852
SELECT ALL - 90 + + col2 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3853
SELECT ALL col2 * col1 - CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3853
SELECT ALL col2 * col1 - CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 * col1 + - 78 AS col0 FROM tab2 cor0
----
211
3403
883

query I rowsort
SELECT - ( col1 ) + - 5 AS col1 FROM tab2 AS cor0
----
-22
-36
-64

onlyif mysql # use DIV operator for integer division
query I rowsort label-3856
SELECT - + 98 + - col2 DIV 83 FROM tab2 AS cor0
----
-98
-98
-98

skipif mysql # not compatible
query I rowsort label-3856
SELECT - + 98 + - col2 / 83 FROM tab2 AS cor0
----
-98
-98
-98

query I rowsort
SELECT + 93 * + col0 AS col1 FROM tab0 AS cor0
----
2232
3255
8277

query I rowsort
SELECT + 22 * col0 FROM tab0 AS cor0
----
1958
528
770

query I rowsort
SELECT + col2 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - col2 * - 84 * cor0.col1 + 5 FROM tab2 AS cor0
----
128861
54269
70313

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3861
SELECT - CAST( NULL AS SIGNED ) + + 51 * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3861
SELECT - CAST ( NULL AS INTEGER ) + + 51 * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 53 * - 71 AS col0 FROM tab0 cor0
----
-3763
-3763
-3763

query I rowsort
SELECT - cor1.col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT DISTINCT - col1 + + col2 + - col1 FROM tab1 AS cor0
----
2
37
70

query I rowsort
SELECT ALL + 25 * + 96 AS col0 FROM tab1
----
2400
2400
2400

query I rowsort
SELECT 86 FROM tab0, tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
81 values hashing to e219687f6f4ab6f7ee442792edcebca9

query I rowsort
SELECT col0 + - ( col0 ) * col1 - col1 * + 5 AS col1 FROM tab0 cor0
----
-2470
-3845
-8465

query I rowsort
SELECT col1 * + 92 + col2 AS col2 FROM tab0 AS cor0
----
7945
8454
8925

query I rowsort
SELECT + col2 + - col2 * col1 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3870
SELECT CAST( NULL AS SIGNED ) AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-3870
SELECT CAST ( NULL AS INTEGER ) AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + col1 * 38 AS col1 FROM tab1
----
380
494
988

query I rowsort
SELECT DISTINCT + - cor0.col2 * + 99 * + ( col1 ) FROM tab1 AS cor0
----
-123552
-138996
-56430

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + 19 col0 FROM tab0 AS cor0
----
101
20
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-3874
SELECT - col2 + + cor0.col1 DIV - col0 FROM tab2 AS cor0
----
-26
-31
-38

skipif mysql # not compatible
query I rowsort label-3874
SELECT - col2 + + cor0.col1 / - col0 FROM tab2 AS cor0
----
-26
-31
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3875
SELECT DISTINCT col1 / + CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-3875
SELECT DISTINCT col1 / + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

query I rowsort
SELECT ALL - ( + ( - col2 ) ) AS col1 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3877
SELECT ALL - col1 DIV + col1 + col0 - - col2 AS col0 FROM tab2
----
103
116
33

skipif mysql # not compatible
query I rowsort label-3877
SELECT ALL - col1 / + col1 + col0 - - col2 AS col0 FROM tab2
----
103
116
33

query I rowsort
SELECT 37 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c023509f63faa044d654943e6df55ca2

query I rowsort
SELECT - col1 * - cor0.col2 - + col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT + 92 + - 23 AS col1 FROM tab1
----
69
69
69

query I rowsort
SELECT DISTINCT - - tab1.col2 FROM tab1, tab2, tab0 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT col2 * col2 * - col1 + + col0 FROM tab0
----
-611795
-62
-93630

query I rowsort
SELECT ALL col0 + - ( col0 ) + col2 AS col2 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL - col2 + col0 + + col2 FROM tab1
----
3
64
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3885
SELECT - - CAST( NULL AS SIGNED ) * + 27 * - col1 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3885
SELECT - - CAST ( NULL AS INTEGER ) * + 27 * - col1 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( col2 ) * col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT + ( - 72 ) + + col2 * 38 AS col2 FROM tab0 AS cor0
----
-34
1182
3044

query I rowsort
SELECT - ( cor0.col0 ) + col1 * + 31 AS col2 FROM tab1 AS cor0
----
246
323
803

query I rowsort
SELECT + col2 + 62 FROM tab0 AS cor0
----
144
63
95

query I rowsort
SELECT + 45 * - col0 AS col1 FROM tab2 cor0
----
-315
-3510
-3555

query I rowsort
SELECT - cor0.col2 + + ( + 90 ) AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 93a6deec4d89bb1e2b552c076bf2920b

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 cor0, tab1 AS cor1, tab1 cor2
----
972 values hashing to f8fe28681e8720551e1ec173631fc529

query I rowsort
SELECT - - cor0.col1 - - 65 FROM tab2 AS cor0
----
124
82
96

query I rowsort
SELECT ALL col0 + 68 AS col1 FROM tab1 AS cor0
----
132
148
71

query I rowsort
SELECT + col1 - ( col2 ) AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT col1 * col2 - cor0.col0 AS col0 FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # use DIV operator for integer division
query I rowsort label-3897
SELECT - cor0.col2 * - 89 + + col2 DIV + col1 FROM tab0 cor0
----
2937
7298
89

skipif mysql # not compatible
query I rowsort label-3897
SELECT - cor0.col2 * - 89 + + col2 / + col1 FROM tab0 cor0
----
2937
7298
89

query I rowsort
SELECT ALL + cor0.col1 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL + cor0.col1 * + col1 * cor0.col2 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT - col1 * 94 AS col1 FROM tab1 AS cor0
----
-1222
-2444
-940

query I rowsort
SELECT + 85 + + col0 FROM tab0 cor0
----
109
120
174

query I rowsort
SELECT DISTINCT - 99 + + col0 FROM tab1 AS cor0
----
-19
-35
-96

query I rowsort
SELECT 23 * + col1 * + col2 AS col1 FROM tab0
----
171626
2231
65274

query I rowsort
SELECT DISTINCT 50 AS col2 FROM tab2, tab1, tab1 AS cor0
----
50

query I rowsort
SELECT cor0.col1 AS col1 FROM tab0, tab2 cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL - 22 * - col2 FROM tab0
----
1804
22
726

onlyif mysql # use DIV operator for integer division
query I rowsort label-3907
SELECT ALL + - col2 + + 65 DIV 51 AS col0 FROM tab2 cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-3907
SELECT ALL + - col2 + + 65 / 51 AS col0 FROM tab2 cor0
----
-25
-26
-37

query I rowsort
SELECT col0 - + ( cor0.col2 ) FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT col0 * - col1 + col0 AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL - col0 * cor0.col1 - col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT ALL - col2 - 39 * col1 FROM tab2 AS cor0
----
-1236
-2327
-701

query I rowsort
SELECT + cor0.col1 - - ( - col0 ) * col0 AS col0 FROM tab0 AS cor0
----
-1128
-490
-7830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3913
SELECT col2 * - col0 / + col2 + + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3913
SELECT col2 * - col0 / + col2 + + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 + 90 + col1 * + ( - col2 ) FROM tab0 AS cor0
----
-2662
-7281
90

query I rowsort
SELECT ALL - - cor0.col0 + + col1 + col2 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT DISTINCT col2 * col0 + - cor0.col2 AS col0 FROM tab1 cor0
----
108
3591
7584

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( 57 AS REAL ) FROM tab0 AS cor0
----
-57

query I rowsort
SELECT DISTINCT - - ( 58 ) + - col2 + col0 AS col1 FROM tab1 AS cor0
----
42
65
7

query I rowsort
SELECT ALL 4 AS col0 FROM tab1 cor0
----
4
4
4

query I rowsort
SELECT ALL + 6 * - col0 FROM tab2 AS cor0
----
-42
-468
-474

query I rowsort
SELECT - 6 * col0 + + col1 FROM tab2 AS cor0
----
-11
-409
-457

query I rowsort
SELECT DISTINCT + col1 + tab1.col1 + tab1.col1 * + tab1.col1 * col0 AS col1 FROM tab1
----
13546
2080
6420

skipif mysql # not compatible
query I rowsort
SELECT - col1 * CAST ( col2 AS REAL ) * col1 + col2 AS col1 FROM tab0
----
-244035
-678960
-9408

query I rowsort
SELECT + col1 + 40 * col0 AS col2 FROM tab0
----
1046
1497
3651

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3925
SELECT DISTINCT - col2 + CAST( - col0 AS SIGNED ) FROM tab1
----
-121
-176
-57

skipif mysql # not compatible
query I rowsort label-3925
SELECT DISTINCT - col2 + CAST ( - col0 AS INTEGER ) FROM tab1
----
-121
-176
-57

query I rowsort
SELECT DISTINCT col2 + + 75 FROM tab1
----
129
132
171

query I rowsort
SELECT DISTINCT - col0 + + 61 AS col1 FROM tab1
----
-19
-3
58

query I rowsort
SELECT DISTINCT + + cor0.col1 * - col0 - col2 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT + + ( + ( col0 ) ) + cor0.col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) * - col2 - - col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT DISTINCT - + col1 * + 72 * - col2 AS col1 FROM tab2 AS cor0
----
110448
46512
60264

onlyif mysql # use DIV operator for integer division
query I rowsort label-3932
SELECT ALL - + CAST( + ( - col0 ) AS SIGNED ) + col2 * col1 DIV col2 - - col1 col2 FROM tab1 AS cor0
----
106
55
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3932
SELECT ALL - + CAST ( + ( - col0 ) AS INTEGER ) + col2 * col1 / col2 - - col1 col2 FROM tab1 AS cor0
----
106
55
84

query I rowsort
SELECT ( 39 ) FROM tab2 AS cor0
----
39
39
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3934
SELECT + CAST( NULL AS SIGNED ) * col2 * - col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3934
SELECT + CAST ( NULL AS INTEGER ) * col2 * - col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * 72 - col2 AS col2 FROM tab1 AS cor0
----
3834
4047
6816

onlyif mysql # use DIV operator for integer division
query I rowsort label-3936
SELECT - cor0.col2 * + col1 DIV ( + col1 ) FROM tab0 cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-3936
SELECT - cor0.col2 * + col1 / ( + col1 ) FROM tab0 cor0
----
-1
-33
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3937
SELECT DISTINCT + + col0 + CAST( NULL AS SIGNED ) * col0 * - col1 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3937
SELECT DISTINCT + + col0 + CAST ( NULL AS INTEGER ) * col0 * - col1 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col2 * ( col0 ) AS col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT ALL + col2 + + ( - col0 ) FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + cor0.col1 * 31 FROM tab1 AS cor0
----
310
403
806

query I rowsort
SELECT + 56 + - col0 AS col2 FROM tab1
----
-24
-8
53

query I rowsort
SELECT - 22 AS col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 647e567609c5ada1d3454d2102819bfe

query I rowsort
SELECT DISTINCT - 80 * - col2 FROM tab2
----
2080
2160
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 60 col2 FROM tab1
----
60
60
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3945
SELECT + cor1.col1 + + CAST( 72 AS SIGNED ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to a84e1f9c09388c8750768fd88f294f37

skipif mysql # not compatible
query I rowsort label-3945
SELECT + cor1.col1 + + CAST ( 72 AS INTEGER ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to a84e1f9c09388c8750768fd88f294f37

query I rowsort
SELECT col2 * 58 FROM tab1
----
3132
3306
5568

query I rowsort
SELECT DISTINCT + cor0.col0 * - 20 + col1 FROM tab2 AS cor0
----
-109
-1501
-1563

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + ( 5 ) col0 FROM tab1 AS cor0
----
-59
-75
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col0 - col1 col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT cor0.col0 * + ( cor0.col0 ) + + cor0.col2 * ( col2 ) FROM tab0 AS cor0
----
1226
14645
1665

query I rowsort
SELECT ALL - col1 * 86 - - col0 AS col0 FROM tab1 AS cor0
----
-1038
-2233
-796

query I rowsort
SELECT ALL + - col2 * + 46 FROM tab2 AS cor0
----
-1196
-1242
-1748

query I rowsort
SELECT + - col1 + col0 * col0 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT DISTINCT + col2 * ( 29 ) FROM tab0
----
2378
29
957

query I rowsort
SELECT ALL - 66 * + col0 * col1 FROM tab1
----
-42240
-5148
-68640

query I rowsort
SELECT 44 AS col0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

query I rowsort
SELECT + cor0.col1 + - cor0.col0 AS col1 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT 41 - + col0 FROM tab2
----
-37
-38
34

query I rowsort
SELECT + - col2 - cor0.col2 FROM tab1 cor0
----
-108
-114
-192

onlyif mysql # use DIV operator for integer division
query I rowsort label-3960
SELECT col2 DIV ( - 34 ) FROM tab1 AS cor0
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-3960
SELECT col2 / ( - 34 ) FROM tab1 AS cor0
----
-1
-1
-2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3961
SELECT + col1 * + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3961
SELECT + col1 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL tab1.col1 + ( + col1 ) FROM tab1
----
20
26
52

query I rowsort
SELECT + + col2 * 85 * col0 FROM tab0 AS cor0
----
2975
620330
67320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3964
SELECT ALL col2 + + CAST( - col2 AS SIGNED ) * col0 FROM tab2 AS cor0
----
-162
-2002
-2964

skipif mysql # not compatible
query I rowsort label-3964
SELECT ALL col2 + + CAST ( - col2 AS INTEGER ) * col0 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT - col0 + + 78 AS col0 FROM tab1 AS cor0
----
-2
14
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3966
SELECT ALL + - cor0.col1 * + CAST( col0 AS SIGNED ) * col2 + + col0 + cor0.col1 FROM tab0 AS cor0
----
-3263
-663938
-68002

skipif mysql # not compatible
query I rowsort label-3966
SELECT ALL + - cor0.col1 * + CAST ( col0 AS INTEGER ) * col2 + + col0 + cor0.col1 FROM tab0 AS cor0
----
-3263
-663938
-68002

onlyif mysql # use DIV operator for integer division
query I rowsort label-3967
SELECT - - col2 + - cor0.col0 DIV + col0 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-3967
SELECT - - col2 + - cor0.col0 / + col0 FROM tab2 AS cor0
----
25
26
37

query I rowsort
SELECT + cor0.col0 * - 3 FROM tab0 AS cor0
----
-105
-267
-72

query I rowsort
SELECT - col2 * + 12 AS col2 FROM tab0 AS cor0
----
-12
-396
-984

query I rowsort
SELECT - + col1 + + col2 * col0 AS col2 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT col1 * ( + cor0.col0 ) AS col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3972
SELECT - cor0.col2 * - cor0.col1 - + CAST( NULL AS DECIMAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3972
SELECT - cor0.col2 * - cor0.col1 - + CAST ( NULL AS REAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 55 + - col1 FROM tab2 AS cor0
----
-4
24
38

query I rowsort
SELECT DISTINCT + + col2 + cor0.col1 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT - 19 AS col2 FROM tab2 AS cor0
----
-19
-19
-19

query I rowsort
SELECT ALL - + col2 * + col0 AS col0 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT - cor0.col0 * col0 - - col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT ( 85 ) AS col2 FROM tab0
----
85
85
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-3979
SELECT DISTINCT + + ( - col0 ) DIV 90 AS col2 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3979
SELECT DISTINCT + + ( - col0 ) / 90 AS col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL + - col0 * + col2 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL 98 * col1 + - col1 FROM tab2 AS cor0
----
1649
3007
5723

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3982
SELECT col0 + col2 * - CAST( NULL AS SIGNED ) * + cor0.col2 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3982
SELECT col0 + col2 * - CAST ( NULL AS INTEGER ) * + cor0.col2 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 74 AS col0 FROM tab2 AS cor0
----
-74
-74
-74

query I rowsort
SELECT + col0 + col0 * 86 FROM tab1 AS cor0
----
261
5568
6960

query I rowsort
SELECT - col1 * + 1 AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL - col1 - col2 * ( col0 ) * - col2 FROM tab2
----
114059
5072
52669

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3987
SELECT ALL + + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3987
SELECT ALL + + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL ( ( cor0.col2 ) ) * col1 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-3989
SELECT cor0.col0 * + col0 DIV + col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3989
SELECT cor0.col0 * + col0 / + col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL - - ( 24 ) AS col0 FROM tab1 AS cor0
----
24
24
24

query I rowsort
SELECT DISTINCT + + col1 * + col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - - 85 * cor0.col1 FROM tab1 AS cor0
----
1105
2210
850

query I rowsort
SELECT ALL + col2 * 96 FROM tab1 AS cor0
----
5184
5472
9216

query I rowsort
SELECT ALL 83 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT DISTINCT 59 + cor0.col0 FROM tab1, tab0 AS cor0
----
148
83
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - ( col2 + - col1 ) col2 FROM tab0
----
1749
738
96

query I rowsort
SELECT cor1.col1 AS col1 FROM tab1, tab0 cor0, tab0 cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ALL - 47 * col1 FROM tab2
----
-1457
-2773
-799

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 21 col0 FROM tab2 AS cor0
----
21
21
21

query I rowsort
SELECT 43 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4001
SELECT - + col2 + - CAST( NULL AS SIGNED ) / + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4001
SELECT - + col2 + - CAST ( NULL AS INTEGER ) / + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT ALL - + col0 + - 21 FROM tab2 AS cor0
----
-100
-28
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-4004
SELECT + col0 DIV + ( col0 + + col2 * 73 ) FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4004
SELECT + col0 / + ( col0 + + col2 * 73 ) FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4005
SELECT ALL - col1 + col0 DIV + col0 FROM tab1
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-4005
SELECT ALL - col1 + col0 / + col0 FROM tab1
----
-12
-25
-9

query I rowsort
SELECT + - 96 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c89b545346f99713888a7934e4caa539

query I rowsort
SELECT ALL ( col0 ) + ( 24 * col2 ) FROM tab1
----
1299
1432
2384

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4008
SELECT ALL + col1 * CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4008
SELECT ALL + col1 * CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - + cor0.col0 * 53 FROM tab0 AS cor0
----
-1272
-1855
-4717

query I rowsort
SELECT ALL + - col1 * 94 + + col1 AS col2 FROM tab2 AS cor0
----
-1581
-2883
-5487

query I rowsort
SELECT + col2 + 67 AS col0 FROM tab0 AS cor0
----
100
149
68

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 + 51 FROM tab1 cor0
----
-1197
-1353
-519

query I rowsort
SELECT ALL + col1 + col2 * - 66 FROM tab1 AS cor0
----
-3538
-3752
-6323

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4014
SELECT col1 + CAST( NULL AS SIGNED ) * - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4014
SELECT col1 + CAST ( NULL AS INTEGER ) * - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( tab2.col0 ) * + col2 * + col1 - - col0 AS col1 FROM tab2
----
119730
51113
5866

onlyif mysql # use DIV operator for integer division
query I rowsort label-4016
SELECT - tab0.col1 DIV 22 FROM tab0
----
-3
-4
-4

skipif mysql # not compatible
query I rowsort label-4016
SELECT - tab0.col1 / 22 FROM tab0
----
-3
-4
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-4017
SELECT 81 DIV 45 AS col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4017
SELECT 81 / 45 AS col1 FROM tab0
----
1
1
1

query I rowsort
SELECT DISTINCT - tab2.col0 - cor0.col1 * - 2 FROM tab2, tab0 AS cor0
----
9 values hashing to 23a38568df0221ca49a783f0c137e690

query I rowsort
SELECT ALL 30 - + 84 * col2 FROM tab1
----
-4506
-4758
-8034

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 34 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 1146d159f0b9b4378a8b738b963f7039

query I rowsort
SELECT DISTINCT 50 * ( col0 ) * 49 - + col0 FROM tab1
----
156736
195920
7347

query I rowsort
SELECT ALL col1 + col2 + + col2 FROM tab2
----
111
85
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4023
SELECT CAST( NULL AS DECIMAL ) * ( + col2 ) col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4023
SELECT CAST ( NULL AS REAL ) * ( + col2 ) col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + 69 + col0 AS col0 FROM tab1 AS cor0
----
133
149
72

query I rowsort
SELECT ALL + - col1 + col0 * + 51 FROM tab1 cor0
----
127
3254
4067

onlyif mysql # use DIV operator for integer division
query I rowsort label-4026
SELECT + + col0 DIV col0 - - col0 * - col2 * - col2 col2 FROM tab1 AS cor0
----
207937
737281
8749

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4026
SELECT + + col0 / col0 - - col0 * - col2 * - col2 col2 FROM tab1 AS cor0
----
207937
737281
8749

query I rowsort
SELECT ALL + col2 + cor0.col2 * 19 * ( col0 ) AS col0 FROM tab0 AS cor0
----
138744
15081
666

query I rowsort
SELECT DISTINCT col1 + + col0 + 70 FROM tab0
----
180
202
250

query I rowsort
SELECT ALL - + 13 FROM tab1 cor0
----
-13
-13
-13

query I rowsort
SELECT col0 * - col2 + + col2 FROM tab0 AS cor0
----
-34
-7216
-759

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 * - cor0.col2 + + col1 col0 FROM tab1 cor0
----
-1235
-1378
-560

query I rowsort
SELECT - - col2 * + col2 + cor0.col1 * col2 FROM tab0 cor0
----
14186
3927
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4033
SELECT + 55 DIV + col0 + - col1 * cor0.col0 * - col2 - + ( cor0.col2 ) * - col1 AS col0 FROM tab0 AS cor0
----
3493
671580
70952

skipif mysql # not compatible
query I rowsort label-4033
SELECT + 55 / + col0 + - col1 * cor0.col0 * - col2 - + ( cor0.col2 ) * - col1 AS col0 FROM tab0 AS cor0
----
3493
671580
70952

query I rowsort
SELECT - - col0 + col2 * 2 * + ( + col0 ) + 16 AS col1 FROM tab1 cor0
----
15456
343
7376

query I rowsort
SELECT ( - col1 ) + ( + col2 ) FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL + 48 + + cor0.col1 * - col0 FROM tab1 AS cor0
----
-30
-592
-992

query I rowsort
SELECT col2 * - col1 + - col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT + + cor0.col0 * - col0 + - col2 AS col1 FROM tab0 AS cor0
----
-1226
-609
-8003

query I rowsort
SELECT + 72 + col2 - col1 FROM tab1 AS cor0
----
100
119
155

query I rowsort
SELECT DISTINCT - 69 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
-69

query I rowsort
SELECT ALL 71 + - col2 * + col0 AS col1 FROM tab2
----
-118
-1957
-2931

query I rowsort
SELECT ALL 47 AS col2 FROM tab2
----
47
47
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4043
SELECT - col2 - col0 * + CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
-2054
-216
-3040

skipif mysql # not compatible
query I rowsort label-4043
SELECT - col2 - col0 * + CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
-2054
-216
-3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 + col2 col0 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL - col2 * col2 + - col2 FROM tab0 cor0
----
-1122
-2
-6806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 6 - - col2 * col2 col2 FROM tab0 AS cor0
----
1095
6730
7

query I rowsort
SELECT col2 + - cor0.col0 * + ( - col1 ) FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT + col1 + - ( col1 ) * - col1 AS col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT col1 + 73 AS col0 FROM tab2 AS cor0
----
104
132
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4050
SELECT ALL + col1 * + CAST( - 21 AS SIGNED ) FROM tab2 cor0
----
-1239
-357
-651

skipif mysql # not compatible
query I rowsort label-4050
SELECT ALL + col1 * + CAST ( - 21 AS INTEGER ) FROM tab2 cor0
----
-1239
-357
-651

query I rowsort
SELECT + cor0.col1 + - 93 * + col1 FROM tab2 AS cor0
----
-1564
-2852
-5428

query I rowsort
SELECT col0 * + col0 + col0 * col2 FROM tab2
----
238
8112
9243

query I rowsort
SELECT ALL + 51 + + col0 * 43 FROM tab0
----
1083
1556
3878

query I rowsort
SELECT DISTINCT + col1 * col0 + ( 77 ) AS col1 FROM tab2
----
1420
294
4679

query I rowsort
SELECT - - cor0.col2 + col2 * col2 AS col2 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT - col2 * 8 FROM tab2 AS cor0
----
-208
-216
-304

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4057
SELECT ALL CAST( NULL AS SIGNED ) * 75 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4057
SELECT ALL CAST ( NULL AS INTEGER ) * 75 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 88 * col1 col2 FROM tab0 AS cor0
----
7568
8008
8536

query I rowsort
SELECT ( + col2 ) * col1 FROM tab2 cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4060
SELECT ALL + col2 + - col1 * col0 * + CAST( ( + col1 ) AS SIGNED ) FROM tab2 AS cor0
----
-22793
-271492
-6700

skipif mysql # not compatible
query I rowsort label-4060
SELECT ALL + col2 + - col1 * col0 * + CAST ( ( + col1 ) AS INTEGER ) FROM tab2 AS cor0
----
-22793
-271492
-6700

query I rowsort
SELECT ALL + 11 AS col0 FROM tab1 AS cor0
----
11
11
11

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( col2 AS REAL ) * + col1 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT 74 * - col1 - col0 AS col1 FROM tab0 AS cor0
----
-6388
-6823
-7213

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4064
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + cor0.col1 * col0 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4064
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + cor0.col1 * col0 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + 72 * ( + col0 ) AS col2 FROM tab1 AS cor0
----
216
4608
5760

query I rowsort
SELECT DISTINCT - cor0.col1 + col1 * col2 AS col0 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT - 54 AS col1 FROM tab1, tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
81 values hashing to 440ee4bea4c39df49899f4a4d88059fe

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( col1 AS REAL ) AS col2 FROM tab1
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-4069
SELECT - col1 * col0 DIV - col2 AS col2 FROM tab1
----
1
10
11

skipif mysql # not compatible
query I rowsort label-4069
SELECT - col1 * col0 / - col2 AS col2 FROM tab1
----
1
10
11

query I rowsort
SELECT DISTINCT - col2 + + col1 + col2 AS col2 FROM tab0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4071
SELECT - CAST( cor0.col0 AS SIGNED ) DIV col1 + col0 * 97 FROM tab2 cor0
----
679
7565
7659

skipif mysql # not compatible
query I rowsort label-4071
SELECT - CAST ( cor0.col0 AS INTEGER ) / col1 + col0 * 97 FROM tab2 cor0
----
679
7565
7659

query I rowsort
SELECT - ( 25 ) + col0 * + 95 + + col2 AS col1 FROM tab1 AS cor0
----
314
6112
7671

query I rowsort
SELECT DISTINCT + 33 + col2 FROM tab0 AS cor0
----
115
34
66

query I rowsort
SELECT DISTINCT + col2 * - col0 + col2 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT + col0 + - col0 AS col0 FROM tab1 cor0
----
0

query I rowsort
SELECT ALL col0 + col2 - col0 AS col2 FROM tab1
----
54
57
96

query I rowsort
SELECT - - ( + col1 ) + + col1 - + ( col1 + cor0.col0 ) FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT 61 - col0 * col2 FROM tab0 AS cor0
----
-7237
-731
26

query I rowsort
SELECT + - 49 * - 87 + col1 + col1 AS col0 FROM tab1 AS cor0
----
4283
4289
4315

query I rowsort
SELECT - col0 * - 35 + cor0.col0 - 47 AS col2 FROM tab1 AS cor0
----
2257
2833
61

query I rowsort
SELECT + col1 + col0 * - col0 + - 25 FROM tab0 AS cor0
----
-1153
-515
-7855

query I rowsort
SELECT DISTINCT 32 + - col1 AS col1 FROM tab2 AS cor0
----
-27
1
15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4083
SELECT - ( - col2 ) + CAST( NULL AS SIGNED ) * + col0 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4083
SELECT - ( - col2 ) + CAST ( NULL AS INTEGER ) * + col0 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( - col1 ) + - col2 * + col2 AS col0 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT - col0 * + cor0.col1 AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-4086
SELECT - col1 + + 19 DIV col2 AS col1 FROM tab0 AS cor0
----
-78
-86
-91

skipif mysql # not compatible
query I rowsort label-4086
SELECT - col1 + + 19 / col2 AS col1 FROM tab0 AS cor0
----
-78
-86
-91

query I rowsort
SELECT tab1.col1 * - col2 + ( tab1.col1 ) FROM tab1
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-4088
SELECT ALL + 77 DIV + col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4088
SELECT ALL + 77 / + col1 FROM tab0
----
0
0
0

query I rowsort
SELECT + col1 + 60 * cor0.col0 FROM tab0 AS cor0
----
1526
2197
5431

query I rowsort
SELECT - - col0 * ( + cor0.col2 ) + cor0.col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT + + col2 * - ( col1 ) * col1 AS col0 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT ALL + col1 + ( - cor0.col1 ) FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4093
SELECT ALL col1 DIV + 16 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4093
SELECT ALL col1 / + 16 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT ALL col1 - 15 AS col1 FROM tab1 AS cor0
----
-2
-5
11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4095
SELECT ALL + cor0.col1 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4095
SELECT ALL + cor0.col1 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 + - col1 - + col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + ( - col2 ) * - col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-4098
SELECT DISTINCT + col2 * + col0 + col0 DIV + col2 AS col0 FROM tab0 AS cor0
----
70
7299
792

skipif mysql # not compatible
query I rowsort label-4098
SELECT DISTINCT + col2 * + col0 + col0 / + col2 AS col0 FROM tab0 AS cor0
----
70
7299
792

query I rowsort
SELECT DISTINCT - col1 * - 45 AS col1 FROM tab2 cor0
----
1395
2655
765

onlyif mysql # use DIV operator for integer division
query I rowsort label-4100
SELECT ALL - col0 * - col0 + - cor0.col2 DIV + 24 + + col2 FROM tab0 AS cor0
----
1226
608
8000

skipif mysql # not compatible
query I rowsort label-4100
SELECT ALL - col0 * - col0 + - cor0.col2 / + 24 + + col2 FROM tab0 AS cor0
----
1226
608
8000

query I rowsort
SELECT ALL - - col2 * - col1 - col0 FROM tab0 AS cor0
----
-132
-2862
-7551

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4102
SELECT CAST( 70 AS SIGNED ) AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

skipif mysql # not compatible
query I rowsort label-4102
SELECT CAST ( 70 AS INTEGER ) AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT DISTINCT + - col1 - col0 AS col1 FROM tab2 AS cor0
----
-137
-38
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4104
SELECT 81 DIV cor0.col2 AS col0 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-4104
SELECT 81 / cor0.col2 AS col0 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT DISTINCT 83 * col1 * col2 FROM tab1 AS cor0
----
103584
116532
47310

query I rowsort
SELECT + col0 * col1 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
2040
3360
8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4107
SELECT DISTINCT + col2 * + col1 * - col1 + col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4107
SELECT DISTINCT + col2 * + col1 * - col1 + col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + col2 * 97 FROM tab1 AS cor0
----
5238
5529
9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4109
SELECT ALL - col0 + + CAST( NULL AS SIGNED ) * - col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4109
SELECT ALL - col0 + + CAST ( NULL AS INTEGER ) * - col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 11 * tab0.col0 + 93 * + col1 FROM tab0
----
7484
7734
8636

query I rowsort
SELECT ALL - tab2.col2 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT DISTINCT - col0 + col2 + - tab0.col1 * - col1 AS col0 FROM tab0
----
7405
8274
9375

query I rowsort
SELECT ALL + - 98 - + cor0.col0 AS col1 FROM tab0 cor0
----
-122
-133
-187

query I rowsort
SELECT DISTINCT + col1 * col0 + 36 FROM tab0 AS cor0
----
2100
3431
8135

query I rowsort
SELECT - + col2 + + col2 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL + 72 + + cor0.col2 * - 91 FROM tab0 AS cor0
----
-19
-2931
-7390

query I rowsort
SELECT DISTINCT - + col1 + col2 + - col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - col1 * tab0.col1 + - col1 + + col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT 15 * tab0.col1 FROM tab0
----
1290
1365
1455

query I rowsort
SELECT 74 + col1 AS col0 FROM tab1 AS cor0
----
100
84
87

query I rowsort
SELECT ( col0 ) - ( + col1 + col0 * col2 ) FROM tab2 AS cor0
----
-2009
-213
-2940

query I rowsort
SELECT + col0 + cor0.col2 * col2 AS col2 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT ALL - + ( col2 ) - + col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT + col1 * + col1 - - col2 AS col2 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT 11 * + cor0.col0 FROM tab0 cor0
----
264
385
979

query I rowsort
SELECT DISTINCT - 86 * + col1 AS col0 FROM tab1 AS cor0
----
-1118
-2236
-860

query I rowsort
SELECT + col0 * col0 + 53 FROM tab0 AS cor0
----
1278
629
7974

query I rowsort
SELECT + col2 * + ( col2 ) * - col2 FROM tab0 AS cor0
----
-1
-35937
-551368

query I rowsort
SELECT + col1 * 27 + - col2 * col2 FROM tab1 AS cor0
----
-2214
-2979
-8865

query I rowsort
SELECT DISTINCT + cor0.col0 FROM tab0, tab0 AS cor0, tab1, tab1 AS cor1
----
24
35
89

query I rowsort
SELECT DISTINCT col1 * - 83 AS col0 FROM tab2 AS cor0
----
-1411
-2573
-4897

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4132
SELECT ALL CAST( col2 AS SIGNED ) + col1 * - 78 AS col0 FROM tab0 AS cor0
----
-6675
-7016
-7565

skipif mysql # not compatible
query I rowsort label-4132
SELECT ALL CAST ( col2 AS INTEGER ) + col1 * - 78 AS col0 FROM tab0 AS cor0
----
-6675
-7016
-7565

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4133
SELECT DISTINCT + - CAST( NULL AS SIGNED ) * + col1 + - cor0.col1 * col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4133
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) * + col1 + - cor0.col1 * col2 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4134
SELECT ALL + - col1 + col0 DIV col0 AS col2 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-4134
SELECT ALL + - col1 + col0 / col0 AS col2 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT DISTINCT - + col1 - - col2 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT col2 * col2 + + 85 FROM tab2
----
1529
761
814

onlyif mysql # use DIV operator for integer division
query I rowsort label-4137
SELECT DISTINCT + col1 DIV ( + col1 ) AS col2 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-4137
SELECT DISTINCT + col1 / ( + col1 ) AS col2 FROM tab1
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4138
SELECT ALL + col0 * col1 DIV + col2 AS col1 FROM tab0
----
3395
62
98

skipif mysql # not compatible
query I rowsort label-4138
SELECT ALL + col0 * col1 / + col2 AS col1 FROM tab0
----
3395
62
98

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab1 AS cor2, tab0 cor3
----
3645 values hashing to f2e58df61204c8a189e87d6816ea9159

query I rowsort
SELECT tab2.col1 - col1 * 74 AS col2 FROM tab2
----
-1241
-2263
-4307

query I rowsort
SELECT ALL - + 8 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 47f43f23dcd23959d97d8e3b0aab692e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4142
SELECT - CAST( col0 AS SIGNED ) + tab1.col1 AS col2 FROM tab1
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-4142
SELECT - CAST ( col0 AS INTEGER ) + tab1.col1 AS col2 FROM tab1
----
-54
-67
23

query I rowsort
SELECT tab0.col1 + + 59 FROM tab0
----
145
150
156

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 50 col1 FROM tab1, tab2 AS cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT DISTINCT - ( tab1.col2 ) - col0 FROM tab1
----
-121
-176
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4146
SELECT ALL - col0 * 54 + col2 / CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4146
SELECT ALL - col0 * 54 + col2 / CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4147
SELECT DISTINCT CAST( NULL AS SIGNED ) * + col0 col0 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4147
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + col0 col0 FROM tab1
----
NULL

query I rowsort
SELECT 38 + 70 FROM tab2
----
108
108
108

query I rowsort
SELECT DISTINCT ( + col0 * - col2 ) AS col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT 77 * - col2 * - col2 AS col0 FROM tab1 AS cor0
----
224532
250173
709632

onlyif mysql # use DIV operator for integer division
query I rowsort label-4151
SELECT ALL + tab1.col1 DIV tab1.col0 AS col1 FROM tab1
----
0
0
8

skipif mysql # not compatible
query I rowsort label-4151
SELECT ALL + tab1.col1 / tab1.col0 AS col1 FROM tab1
----
0
0
8

query I rowsort
SELECT + - cor0.col2 + col1 * + ( col2 ) AS col1 FROM tab2 cor0
----
1508
608
810

query I rowsort
SELECT ALL - 82 FROM tab1, tab2 AS cor0
----
9 values hashing to f800b0aad28b82b2deb67f7045c9a45c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 74 col2 FROM tab1
----
-74
-74
-74

query I rowsort
SELECT ALL - - 75 AS col0 FROM tab1, tab0, tab2 cor0
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT cor0.col0 + + tab1.col2 AS col2 FROM tab1, tab0, tab1 AS cor0, tab2
----
81 values hashing to 857798c7eb5508bb9547fe4f1683a136

query I rowsort
SELECT cor0.col0 * cor0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to e1120e7b687b32270ef70393236e7341

query I rowsort
SELECT - + 43 AS col0 FROM tab0 AS cor0
----
-43
-43
-43

query I rowsort
SELECT DISTINCT - ( - col2 ) + - col1 * col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT - cor0.col0 * cor0.col1 AS col2 FROM tab2, tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT ( - 87 ) AS col0 FROM tab2, tab1 AS cor0
----
-87

query I rowsort
SELECT ALL col1 * + 68 * col0 FROM tab2
----
14756
312936
91324

query I rowsort
SELECT - + col1 * + col0 + cor0.col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT - - col1 * 60 - col2 FROM tab1 AS cor0
----
1506
543
684

query I rowsort
SELECT + ( col2 ) + - col1 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT - 13 * - 18 FROM tab1 AS cor0
----
234

query I rowsort
SELECT - + 10 + + col0 * col1 AS col2 FROM tab1 AS cor0
----
1030
630
68

query I rowsort
SELECT + + 26 FROM tab2 cor0
----
26
26
26

query I rowsort
SELECT DISTINCT - - ( + col2 ) * col1 * ( col2 ) AS col1 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT 61 * - col0 * - col1 FROM tab1 AS cor0
----
39040
4758
63440

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4171
SELECT ALL + CAST( cor0.col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-4171
SELECT ALL + CAST ( cor0.col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + col0 * col2 * col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) FROM tab1, tab1 AS cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * ( + col1 ) col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT col2 + cor0.col2 * - 94 FROM tab0 AS cor0
----
-3069
-7626
-93

query I rowsort
SELECT - col0 - col0 * + col0 AS col0 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT DISTINCT ( col0 ) + + col1 * + col0 * col0 + - col0 AS col1 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT ( ( + col2 ) ) FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL - + ( col2 ) * col2 * - 36 + - 63 * col0 + cor0.col1 FROM tab2 AS cor0
----
19481
25834
47024

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4180
SELECT CAST( + 31 AS SIGNED ) AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

skipif mysql # not compatible
query I rowsort label-4180
SELECT CAST ( + 31 AS INTEGER ) AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query I rowsort
SELECT + 13 AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT DISTINCT - 30 + - col0 FROM tab0 cor0
----
-119
-54
-65

query I rowsort
SELECT cor0.col1 * + col1 + + col1 * 1 AS col1 FROM tab0 AS cor0
----
7482
8372
9506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4184
SELECT + - col1 * + col1 * - CAST( - col0 AS SIGNED ) FROM tab2 AS cor0
----
-22831
-271518
-6727

skipif mysql # not compatible
query I rowsort label-4184
SELECT + - col1 * + col1 * - CAST ( - col0 AS INTEGER ) FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT - - ( - col0 ) * - col1 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-4186
SELECT ALL + ( 98 ) DIV + col1 AS col2 FROM tab2
----
1
3
5

skipif mysql # not compatible
query I rowsort label-4186
SELECT ALL + ( 98 ) / + col1 AS col2 FROM tab2
----
1
3
5

query I rowsort
SELECT ALL - 68 AS col2 FROM tab0
----
-68
-68
-68

query I rowsort
SELECT ALL 16 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

query I rowsort
SELECT ALL - 27 * + cor0.col1 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 33ca158e4b50316b3787dced60f0f273

onlyif mysql # use DIV operator for integer division
query I rowsort label-4190
SELECT + 54 DIV col2 AS col0 FROM tab0 AS cor0
----
0
1
54

skipif mysql # not compatible
query I rowsort label-4190
SELECT + 54 / col2 AS col0 FROM tab0 AS cor0
----
0
1
54

query I rowsort
SELECT - ( - cor0.col2 ) + col2 AS col0 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT tab2.col2 * col2 * col0 - + 66 * col2 AS col1 FROM tab2
----
111568
3321
51012

query I rowsort
SELECT + tab2.col1 * col0 + + col1 AS col1 FROM tab2
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-4194
SELECT col2 DIV col1 + col0 DIV + col0 AS col0 FROM tab1 AS cor0
----
3
6
8

skipif mysql # not compatible
query I rowsort label-4194
SELECT col2 / col1 + col0 / + col0 AS col0 FROM tab1 AS cor0
----
3
6
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-4195
SELECT - col2 DIV - 85 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4195
SELECT - col2 / - 85 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 * + tab1.col2 + - ( - 28 ) FROM tab1
----
1276
1432
598

query I rowsort
SELECT + col1 * + col0 + + col0 * - col0 AS col0 FROM tab2 AS cor0
----
-1482
-4898
168

onlyif mysql # use DIV operator for integer division
query I rowsort label-4198
SELECT col0 DIV col1 + col2 AS col1 FROM tab1 AS cor0
----
102
54
63

skipif mysql # not compatible
query I rowsort label-4198
SELECT col0 / col1 + col2 AS col1 FROM tab1 AS cor0
----
102
54
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-4199
SELECT DISTINCT col2 * - col2 + col1 DIV + 12 AS col1 FROM tab0
----
-1082
-6717
7

skipif mysql # not compatible
query I rowsort label-4199
SELECT DISTINCT col2 * - col2 + col1 / + 12 AS col1 FROM tab0
----
-1082
-6717
7

query I rowsort
SELECT ALL - col1 + - col0 * - ( col0 ) AS col2 FROM tab2
----
18
6025
6224

onlyif mysql # use DIV operator for integer division
query I rowsort label-4201
SELECT ALL + col2 * + tab1.col0 * - 49 + + tab1.col0 DIV col1 AS col0 FROM tab1
----
-178746
-376314
-7938

skipif mysql # not compatible
query I rowsort label-4201
SELECT ALL + col2 * + tab1.col0 * - 49 + + tab1.col0 / col1 AS col0 FROM tab1
----
-178746
-376314
-7938

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + col2 col1 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-4203
SELECT - - cor0.col0 DIV - cor0.col1 FROM tab1 cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-4203
SELECT - - cor0.col0 / - cor0.col1 FROM tab1 cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort
SELECT + col2 * CAST ( cor0.col0 AS REAL ) + col1 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-4205
SELECT DISTINCT - - col0 * 44 + 37 DIV - col0 FROM tab1 AS cor0
----
120
2816
3520

skipif mysql # not compatible
query I rowsort label-4205
SELECT DISTINCT - - col0 * 44 + 37 / - col0 FROM tab1 AS cor0
----
120
2816
3520

query I rowsort
SELECT - col2 + - ( - 52 ) AS col0 FROM tab1 AS cor0
----
-2
-44
-5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4207
SELECT + col1 * + CAST( + col1 AS SIGNED ) FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-4207
SELECT + col1 * + CAST ( + col1 AS INTEGER ) FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4208
SELECT DISTINCT col2 * - CAST( - 89 AS SIGNED ) FROM tab1 AS cor0
----
4806
5073
8544

skipif mysql # not compatible
query I rowsort label-4208
SELECT DISTINCT col2 * - CAST ( - 89 AS INTEGER ) FROM tab1 AS cor0
----
4806
5073
8544

query I rowsort
SELECT DISTINCT - col2 + - 44 AS col1 FROM tab2 cor0
----
-70
-71
-82

query I rowsort
SELECT ALL + col2 * - 64 FROM tab0 AS cor0
----
-2112
-5248
-64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4211
SELECT DISTINCT col1 + CAST( 35 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
45
48
61

skipif mysql # not compatible
query I rowsort label-4211
SELECT DISTINCT col1 + CAST ( 35 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
45
48
61

query I rowsort
SELECT DISTINCT - col0 + + ( cor0.col1 ) AS col2 FROM tab0 AS cor0
----
2
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4213
SELECT + CAST( NULL AS SIGNED ) + + col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4213
SELECT + CAST ( NULL AS INTEGER ) + + col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 56 - + col0 * - col1 AS col2 FROM tab1 cor0
----
1096
134
696

query I rowsort
SELECT + - col2 + 18 - - col1 AS col0 FROM tab1 AS cor0
----
-10
-29
-65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 * - 18 + + col2 * col1 + 61 col1 FROM tab0 AS cor0
----
140
2305
6047

query I rowsort
SELECT + col1 + 59 FROM tab2 cor0
----
118
76
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 + - col1 col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col0 * - col0 - - col2 AS col0 FROM tab1 cor0
----
4153
63
6496

query I rowsort
SELECT - 58 + col2 AS col1 FROM tab0 AS cor0
----
-25
-57
24

query I rowsort
SELECT + - ( + 3 ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

query I rowsort
SELECT ALL - 33 * col2 + ( - 23 ) FROM tab2 AS cor0
----
-1277
-881
-914

onlyif mysql # use DIV operator for integer division
query I rowsort label-4223
SELECT ALL + + 34 DIV col1 + - col1 FROM tab1 AS cor0
----
-11
-25
-7

skipif mysql # not compatible
query I rowsort label-4223
SELECT ALL + + 34 / col1 + - col1 FROM tab1 AS cor0
----
-11
-25
-7

query I rowsort
SELECT + - cor0.col2 - + cor0.col0 FROM tab1 AS cor0
----
-121
-176
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4225
SELECT DISTINCT + + col1 + + CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4225
SELECT DISTINCT + + col1 + + CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL

query I rowsort
SELECT ALL col2 - - col2 * 90 FROM tab2 AS cor0
----
2366
2457
3458

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + - 64 * + col2 col2 FROM tab0 cor0
----
-2088
-29
-5159

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + 59 * 58 col2 FROM tab0 AS cor0
----
3333
3387
3398

query I rowsort
SELECT ALL + - 18 * col1 + cor0.col2 FROM tab1 AS cor0
----
-123
-138
-414

query I rowsort
SELECT DISTINCT + - col0 + col0 + col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - 40 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1, tab1 cor2
----
-40

query I rowsort
SELECT DISTINCT + 97 AS col1 FROM tab2, tab2 AS cor0
----
97

query I rowsort
SELECT + col0 * + col2 + col1 - + 44 AS col1 FROM tab1 AS cor0
----
144
3614
7649

query I rowsort
SELECT ALL + col2 + col2 * - col2 + + 40 AS col1 FROM tab1 cor0
----
-2822
-3152
-9080

query I rowsort
SELECT - - ( col1 ) + + col0 + col2 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
-6544
-979
131

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab1 AS cor2, tab2 AS cor3
----
3645 values hashing to 48b1d5d88e8ac6a6daea5a8e5606f112

query I rowsort
SELECT + col2 * + 14 + - col1 AS col1 FROM tab1
----
1331
730
788

onlyif mysql # use DIV operator for integer division
query I rowsort label-4238
SELECT col2 - col2 DIV + col2 AS col0 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-4238
SELECT col2 - col2 / + col2 AS col0 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT + + 44 * cor0.col0 - - col2 FROM tab0 AS cor0
----
1089
1541
3998

query I rowsort
SELECT - - ( + col0 ) AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT cor0.col1 * col1 AS col0 FROM tab0 cor0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-4242
SELECT ALL + + col2 DIV cor0.col1 - - col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4242
SELECT ALL + + col2 / cor0.col1 - - col2 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 66 * - col0 col2 FROM tab2 AS cor0
----
-462
-5148
-5214

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + col2 col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL - col1 * col1 + + col0 AS col1 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT DISTINCT + - col1 + col1 * + col1 AS col0 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT + col1 + + ( 18 ) * cor0.col2 FROM tab2 AS cor0
----
517
527
701

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4248
SELECT - CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4248
SELECT - CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - cor0.col2 - - tab0.col2 FROM tab0, tab1 cor0
----
9 values hashing to f5ea0c1696dbdacaeeb93b5c525a0784

query I rowsort
SELECT - 38 FROM tab1, tab2 cor0
----
9 values hashing to e571541ae40cb0ddaca16e11f4359507

query I rowsort
SELECT 79 * - col1 FROM tab0 cor0
----
-6794
-7189
-7663

query I rowsort
SELECT ALL - col0 * 77 AS col1 FROM tab2 AS cor0
----
-539
-6006
-6083

query I rowsort
SELECT 68 AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

query I rowsort
SELECT ALL - 2 + - col1 * tab0.col0 AS col1 FROM tab0
----
-2066
-3397
-8101

query I rowsort
SELECT DISTINCT + ( + col2 ) + col0 * + ( - col2 ) * col0 + 65 * col2 AS col0 FROM tab0
----
-1159
-16830
-644110

query I rowsort
SELECT col0 * col0 + - col2 FROM tab2
----
22
6058
6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-4257
SELECT + 68 DIV col2 + - col1 FROM tab0 AS cor0
----
-29
-84
-91

skipif mysql # not compatible
query I rowsort label-4257
SELECT + 68 / col2 + - col1 FROM tab0 AS cor0
----
-29
-84
-91

query I rowsort
SELECT 42 * cor0.col2 FROM tab1 AS cor0
----
2268
2394
4032

query I rowsort
SELECT ( + col2 ) * - tab2.col1 + + col0 AS col0 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT - tab0.col2 * + 36 + col2 * + 72 AS col2 FROM tab0
----
1188
2952
36

query I rowsort
SELECT ( - cor0.col0 ) + col1 * + col2 + col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + 81 FROM tab1, tab2 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT ALL col1 + - 90 AS col0 FROM tab2
----
-31
-59
-73

query I rowsort
SELECT DISTINCT + 54 * - col2 AS col0 FROM tab0
----
-1782
-4428
-54

query I rowsort
SELECT - - cor0.col1 + cor0.col0 * + col2 AS col0 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT - - cor0.col2 * cor0.col0 + - col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT + - 51 AS col2 FROM tab1 AS cor0
----
-51
-51
-51

query I rowsort
SELECT ALL - 53 * col2 AS col1 FROM tab2 AS cor0
----
-1378
-1431
-2014

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4269
SELECT - col2 + col2 * CAST( NULL AS SIGNED ) + + ( - col1 * + 88 ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4269
SELECT - col2 + col2 * CAST ( NULL AS INTEGER ) + + ( - col1 * + 88 ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 86 + + col1 FROM tab2 AS cor0
----
103
117
145

query I rowsort
SELECT - 72 + col2 AS col2 FROM tab2 cor0
----
-34
-45
-46

query I rowsort
SELECT ALL col0 + - cor0.col1 * + col2 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

onlyif mysql # use DIV operator for integer division
query I rowsort label-4273
SELECT DISTINCT + ( 13 ) DIV col1 + - col2 AS col1 FROM tab1
----
-54
-56
-95

skipif mysql # not compatible
query I rowsort label-4273
SELECT DISTINCT + ( 13 ) / col1 + - col2 AS col1 FROM tab1
----
-54
-56
-95

query I rowsort
SELECT ALL col1 + tab2.col1 * + col0 FROM tab2
----
1360
248
4661

query I rowsort
SELECT ( - tab1.col1 ) + + col2 FROM tab1
----
28
47
83

query I rowsort
SELECT - 33 FROM tab2 cor0
----
-33
-33
-33

query I rowsort
SELECT DISTINCT + col1 * - col0 + 23 FROM tab0 AS cor0
----
-2041
-3372
-8076

query I rowsort
SELECT - 37 * - col1 AS col1 FROM tab0 AS cor0
----
3182
3367
3589

query I rowsort
SELECT DISTINCT + cor0.col0 * - cor0.col2 + - 99 FROM tab1 AS cor0
----
-261
-3747
-7779

onlyif mysql # use DIV operator for integer division
query I rowsort label-4280
SELECT - - col0 + col2 DIV col0 FROM tab0 AS cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-4280
SELECT - - col0 + col2 / col0 FROM tab0 AS cor0
----
25
35
89

query I rowsort
SELECT ( - tab1.col1 ) * - col2 AS col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT - 44 AS col0 FROM tab0
----
-44
-44
-44

query I rowsort
SELECT - - 10 AS col0 FROM tab1 AS cor0
----
10
10
10

query I rowsort
SELECT DISTINCT col1 * - col0 + 59 * col0 AS col0 FROM tab0 cor0
----
-1330
-2848
-648

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4285
SELECT - col0 * - CAST( - col2 AS SIGNED ) FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-4285
SELECT - col0 * - CAST ( - col2 AS INTEGER ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - col0 * + ( - col0 ) - + col2 AS col1 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT DISTINCT + col1 * + col2 + 44 FROM tab0
----
141
2882
7506

query I rowsort
SELECT + 70 * - col1 AS col1 FROM tab0
----
-6020
-6370
-6790

query I rowsort
SELECT DISTINCT + col1 + col2 * - col1 * col1 AS col0 FROM tab2
----
-10965
-25916
-90447

query I rowsort
SELECT col0 * - ( col1 ) + - col0 + - col1 AS col2 FROM tab1 AS cor0
----
-107
-1133
-714

query I rowsort
SELECT - + col0 * ( ( cor0.col1 ) ) AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - - col0 * col2 * + col0 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT + + ( 49 ) * cor0.col0 FROM tab2 AS cor0
----
343
3822
3871

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 cor0 CROSS JOIN tab0, tab0 AS cor1, tab1, tab1 cor2
----
3645 values hashing to 51e2051aff75c58a5edaa314f1412983

query I rowsort
SELECT DISTINCT + col0 * - 73 * col0 FROM tab2
----
-3577
-444132
-455593

query I rowsort
SELECT col2 * ( col2 ) * - tab0.col0 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT + ( + 23 ) + col1 * col0 + 65 * col2 * + 74 AS col1 FROM tab1 AS cor0
----
259841
274833
462823

query I rowsort
SELECT DISTINCT 95 + + col2 * col2 FROM tab2 AS cor0
----
1539
771
824

onlyif mysql # use DIV operator for integer division
query I rowsort label-4299
SELECT DISTINCT - 19 + 62 DIV col1 FROM tab0 AS cor0
----
-19

skipif mysql # not compatible
query I rowsort label-4299
SELECT DISTINCT - 19 + 62 / col1 FROM tab0 AS cor0
----
-19

query I rowsort
SELECT ALL + - 22 + + col2 FROM tab1 AS cor0
----
32
35
74

query I rowsort
SELECT 59 + - 48 * col2 FROM tab2 AS cor0
----
-1189
-1237
-1765

query I rowsort
SELECT ALL - - 22 + col0 * + col2 - - col2 AS col1 FROM tab0 AS cor0
----
58
7402
847

query I rowsort
SELECT ALL - ( col1 ) * - cor0.col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + 28 * + col0 + + col2 FROM tab2 AS cor0
----
2210
223
2250

query I rowsort
SELECT - 50 * + col2 FROM tab2 AS cor0
----
-1300
-1350
-1900

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4306
SELECT ALL + tab1.col1 - - CAST( + col1 AS SIGNED ) AS col2 FROM tab1
----
20
26
52

skipif mysql # not compatible
query I rowsort label-4306
SELECT ALL + tab1.col1 - - CAST ( + col1 AS INTEGER ) AS col2 FROM tab1
----
20
26
52

query I rowsort
SELECT DISTINCT + col1 - col0 AS col0 FROM tab0
----
2
62

query I rowsort
SELECT + col1 - col2 * - col2 FROM tab2
----
1461
735
760

query I rowsort
SELECT col0 + tab1.col1 + - 1 AS col2 FROM tab1
----
28
73
92

query I rowsort
SELECT ALL + 27 AS col2 FROM tab1, tab2, tab2 AS cor0, tab0
----
81 values hashing to 092918b9163061e291041d594b1a402a

query I rowsort
SELECT - cor2.col2 FROM tab0, tab1 cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 AS cor2
----
243 values hashing to 3e2b81ca10484cbfc66f186955e0e920

query I rowsort
SELECT col0 + - 27 * col2 AS col1 FROM tab2 AS cor0
----
-624
-722
-947

onlyif mysql # use DIV operator for integer division
query I rowsort label-4313
SELECT DISTINCT + - col2 DIV - col2 + col2 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-4313
SELECT DISTINCT + - col2 / - col2 + col2 FROM tab1 AS cor0
----
55
58
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4314
SELECT DISTINCT CAST( NULL AS SIGNED ) * col0 + + cor0.col2 * 65 - - col0 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4314
SELECT DISTINCT CAST ( NULL AS INTEGER ) * col0 + + cor0.col2 * 65 - - col0 AS col1 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT - CAST ( - col1 AS REAL ) + - col1 * col0 col1 FROM tab2 AS cor0
----
-1326
-186
-4543

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4316
SELECT + - CAST( + 3 AS SIGNED ) + + col0 col1 FROM tab0 AS cor0
----
21
32
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4316
SELECT + - CAST ( + 3 AS INTEGER ) + + col0 col1 FROM tab0 AS cor0
----
21
32
86

query I rowsort
SELECT DISTINCT + - col1 + 65 FROM tab2 AS cor0
----
34
48
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4318
SELECT DISTINCT - - CAST( - col0 AS SIGNED ) * + col1 - - col0 col1 FROM tab2 AS cor0
----
-1264
-210
-4524

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4318
SELECT DISTINCT - - CAST ( - col0 AS INTEGER ) * + col1 - - col0 col1 FROM tab2 AS cor0
----
-1264
-210
-4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-4319
SELECT - + col2 DIV col2 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-4319
SELECT - + col2 / col2 col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + 61 + + col2 FROM tab1
----
115
118
157

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4321
SELECT - - col0 * + CAST( NULL AS SIGNED ) + col2 * col0 + ( - col0 ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4321
SELECT - - col0 * + CAST ( NULL AS INTEGER ) + col2 * col0 + ( - col0 ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * - ( - col2 * + col1 ) - - cor0.col2 AS col0 FROM tab1 AS cor0
----
119904
32547
75870

query I rowsort
SELECT + col1 + - 67 FROM tab1
----
-41
-54
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-4324
SELECT ALL col2 DIV col1 + - col1 + col2 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

skipif mysql # not compatible
query I rowsort label-4324
SELECT ALL col2 / col1 + - col1 + col2 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL cor0.col0 * - cor0.col2 * 40 + - col2 AS col0 FROM tab2 AS cor0
----
-120118
-7587
-81146

query I rowsort
SELECT DISTINCT col0 * - 44 AS col0 FROM tab2 AS cor0
----
-308
-3432
-3476

query I rowsort
SELECT col2 * - cor0.col2 * col0 AS col0 FROM tab1 cor0
----
-207936
-737280
-8748

query I rowsort
SELECT col0 * - 42 + + 28 FROM tab2 cor0
----
-266
-3248
-3290

query I rowsort
SELECT ALL - cor0.col0 + ( + col1 ) FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT + col2 + - 96 * + col2 AS col1 FROM tab1 AS cor0
----
-5130
-5415
-9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-4331
SELECT ALL - col0 DIV col2 + + ( - col0 ) AS col2 FROM tab1 cor0
----
-3
-65
-80

skipif mysql # not compatible
query I rowsort label-4331
SELECT ALL - col0 / col2 + + ( - col0 ) AS col2 FROM tab1 cor0
----
-3
-65
-80

query I rowsort
SELECT - 80 + col2 * - ( 90 + col2 ) AS col2 FROM tab2 cor0
----
-3096
-3239
-4944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4333
SELECT CAST( 48 AS SIGNED ) AS col0 FROM tab1
----
48
48
48

skipif mysql # not compatible
query I rowsort label-4333
SELECT CAST ( 48 AS INTEGER ) AS col0 FROM tab1
----
48
48
48

query I rowsort
SELECT + cor0.col1 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT + col2 + + cor0.col2 * col2 * cor0.col0 AS col2 FROM tab0 AS cor0
----
26169
36
598518

query I rowsort
SELECT ALL ( + col2 + + tab2.col0 ) * 81 FROM tab2
----
2754
8424
9477

onlyif mysql # use DIV operator for integer division
query I rowsort label-4337
SELECT ALL ( + col1 ) DIV - tab1.col0 AS col0 FROM tab1
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-4337
SELECT ALL ( + col1 ) / - tab1.col0 AS col0 FROM tab1
----
-8
0
0

query I rowsort
SELECT ALL ( - 83 ) AS col0 FROM tab0
----
-83
-83
-83

query I rowsort
SELECT - + cor0.col0 * col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + - ( col2 ) * + col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT + + col0 * cor0.col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col1 + + col1 * cor0.col2 * - ( cor0.col1 + 7 * 26 ) FROM tab1 AS cor0
----
-109430
-243347
-292006

onlyif mysql # use DIV operator for integer division
query I rowsort label-4343
SELECT ALL col1 DIV - col0 AS col2 FROM tab2 cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-4343
SELECT ALL col1 / - col0 AS col2 FROM tab2 cor0
----
-4
0
0

query I rowsort
SELECT DISTINCT - col0 * + col2 * ( col1 ) FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4345
SELECT DISTINCT 1 + + col0 DIV 73 col1 FROM tab0 AS cor0
----
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4345
SELECT DISTINCT 1 + + col0 / 73 col1 FROM tab0 AS cor0
----
1
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4346
SELECT DISTINCT + - cor0.col0 * - CAST( NULL AS SIGNED ) + + col1 * cor0.col0 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4346
SELECT DISTINCT + - cor0.col0 * - CAST ( NULL AS INTEGER ) + + col1 * cor0.col0 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - + col2 * col0 * cor0.col2 + cor0.col0 * + col2 * + 46 AS col1 FROM tab1 cor0
----
-1296
-384000
-40128

query I rowsort
SELECT DISTINCT + col2 + cor0.col1 AS col2 FROM tab1 AS cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + 97 col1 FROM tab0 AS cor0
----
62
73
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-4350
SELECT ALL + - col0 DIV - CAST( - 81 AS SIGNED ) - + col0 * col1 DIV cor0.col0 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-4350
SELECT ALL + - col0 / - CAST ( - 81 AS INTEGER ) - + col0 * col1 / cor0.col0 AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + col2 * 87 + col2 * col1 AS col1 FROM tab2 AS cor0
----
3186
3796
3952

query I rowsort
SELECT - - cor0.col1 * 32 + + 67 * - cor0.col1 * col2 AS col2 FROM tab2 AS cor0
----
-100890
-42738
-55087

query I rowsort
SELECT - - col2 * - 82 FROM tab2 AS cor0
----
-2132
-2214
-3116

query I rowsort
SELECT DISTINCT - tab1.col2 + 77 + + col1 AS col0 FROM tab1
----
-6
30
49

query I rowsort
SELECT ALL - col2 * - 42 AS col2 FROM tab1 AS cor0
----
2268
2394
4032

query I rowsort
SELECT ALL col2 * - 82 AS col1 FROM tab1 AS cor0
----
-4428
-4674
-7872

query I rowsort
SELECT DISTINCT col1 + - cor0.col2 * - col2 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT DISTINCT + ( - cor0.col0 ) + - cor0.col0 AS col2 FROM tab0 AS cor0
----
-178
-48
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 99 * col1 * + col1 col1 FROM tab2 cor0
----
28611
344619
95139

query I rowsort
SELECT ALL + ( cor0.col2 ) AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - + 60 * col0 AS col1 FROM tab0 AS cor0
----
-1440
-2100
-5340

query I rowsort
SELECT - 59 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 1e6537c922fa953e0fd2f59430803703

query I rowsort
SELECT + 80 AS col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 6dd5038be71dffa82f5ceba787caab91

query I rowsort
SELECT col2 + - ( col2 ) * ( + tab0.col1 ) FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT ALL - + 34 + 59 AS col1 FROM tab2 AS cor0
----
25
25
25

query I rowsort
SELECT ALL - 11 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
77
858
869

query I rowsort
SELECT + col2 + col1 * + cor0.col2 AS col1 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT + cor0.col1 + - 27 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 17bb483c1a6823021af0d3c55259faa0

query I rowsort
SELECT ALL - col1 * col2 + cor0.col1 * col1 AS col1 FROM tab0 AS cor0
----
4558
819
9312

query I rowsort
SELECT col0 * cor0.col2 + - col1 AS col0 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT + col0 * 66 - + col1 AS col2 FROM tab1 cor0
----
172
4214
5267

query I rowsort
SELECT ( 80 ) + col2 FROM tab2 AS cor0
----
106
107
118

onlyif mysql # use DIV operator for integer division
query I rowsort label-4373
SELECT - col2 * 95 DIV + cor0.col1 + cor0.col2 AS col0 FROM tab1 AS cor0
----
-143
-484
-605

skipif mysql # not compatible
query I rowsort label-4373
SELECT - col2 * 95 / + cor0.col1 + cor0.col2 AS col0 FROM tab1 AS cor0
----
-143
-484
-605

query I rowsort
SELECT + col1 + col0 + 49 FROM tab2 cor0
----
145
186
87

query I rowsort
SELECT + col0 * col2 * col2 AS col0 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT DISTINCT - 1 * + col2 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT - col0 * + 60 AS col2 FROM tab2
----
-420
-4680
-4740

query I rowsort
SELECT - + cor0.col2 + + ( - cor0.col0 ) AS col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + col1 * 33 AS col0 FROM tab0 AS cor0
----
2838
3003
3201

query I rowsort
SELECT ALL + col0 + - col2 * + cor0.col2 FROM tab0 cor0
----
-1065
-6635
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4381
SELECT - cor0.col0 - + col2 DIV col2 AS col2 FROM tab0 AS cor0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-4381
SELECT - cor0.col0 - + col2 / col2 AS col2 FROM tab0 AS cor0
----
-25
-36
-90

query I rowsort
SELECT DISTINCT - + col1 + - 71 FROM tab2 AS cor0
----
-102
-130
-88

query I rowsort
SELECT + col0 + 6 FROM tab1 AS cor0
----
70
86
9

query I rowsort
SELECT + col1 * + 61 FROM tab0 AS cor0
----
5246
5551
5917

query I rowsort
SELECT DISTINCT + col1 * + tab0.col1 + - col0 FROM tab0
----
7372
8192
9374

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4386
SELECT - CAST( - col2 AS SIGNED ) - col0 FROM tab1 AS cor0
----
-7
16
51

skipif mysql # not compatible
query I rowsort label-4386
SELECT - CAST ( - col2 AS INTEGER ) - col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT - - 3 - cor0.col0 AS col2 FROM tab2 AS cor0
----
-4
-75
-76

query I rowsort
SELECT col2 * + ( col0 ) FROM tab1
----
162
3648
7680

query I rowsort
SELECT col0 * ( + col2 ) + + tab0.col1 + col0 * col1 AS col0 FROM tab0
----
15488
2942
3527

query I rowsort
SELECT + 81 * - tab2.col2 FROM tab2, tab0 cor0
----
9 values hashing to 8fb26f057d451dfd317c4a7cb83f297b

onlyif mysql # use DIV operator for integer division
query I rowsort label-4391
SELECT col1 DIV + 66 AS col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4391
SELECT col1 / + 66 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT + 81 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
81

query I rowsort
SELECT + col2 + col1 * col2 + col1 AS col2 FROM tab1
----
1357
1484
637

query I rowsort
SELECT + + cor0.col0 + col1 * - col1 AS col2 FROM tab1 cor0
----
-36
-673
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 45 col1 FROM tab2, tab2 cor0, tab0 AS cor1
----
27 values hashing to 63e2b488a204f83ec8c063dafdfd4371

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 26 + col1 col2 FROM tab1
----
1430
1492
2509

query I rowsort
SELECT DISTINCT col2 + ( + ( col2 ) ) * - col0 AS col0 FROM tab2
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-4398
SELECT - col1 * col0 DIV + cor0.col1 AS col2 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-4398
SELECT - col1 * col0 / + cor0.col1 AS col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL + - col1 * 16 + col2 FROM tab0 AS cor0
----
-1343
-1374
-1551

query I rowsort
SELECT DISTINCT + col2 * col0 AS col1 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + col0 * + ( col0 * - col2 + 93 ) FROM tab2 AS cor0
----
-150930
-229811
-672

query I rowsort
SELECT DISTINCT - tab2.col0 * - cor0.col0 FROM tab2, tab2 cor0
----
49
546
553
6084
6162
6241

query I rowsort
SELECT ALL 9 * tab2.col2 FROM tab2
----
234
243
342

query I rowsort
SELECT - ( col0 * - col2 ) AS col2 FROM tab2
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT + - 97 AS col2 FROM tab2 AS cor0
----
-97
-97
-97

query I rowsort
SELECT - - col1 - - col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - - 24 + col0 - - col2 AS col0 FROM tab1 AS cor0
----
145
200
81

query I rowsort
SELECT DISTINCT - ( col0 ) + - col0 * col2 * col0 AS col1 FROM tab0 AS cor0
----
-1260
-19032
-649611

query I rowsort
SELECT - 92 * - col1 + - col2 + col1 AS col2 FROM tab2 AS cor0
----
1543
2856
5461

onlyif mysql # use DIV operator for integer division
query I rowsort label-4411
SELECT DISTINCT - - col2 DIV - col0 FROM tab2 AS cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-4411
SELECT DISTINCT - - col2 / - col0 FROM tab2 AS cor0
----
-3
0

query I rowsort
SELECT - 90 - - col1 FROM tab2 AS cor0
----
-31
-59
-73

query I rowsort
SELECT - - col1 * + col0 * - cor0.col2 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
-36537
-4266
-99936

query I rowsort
SELECT - cor0.col0 + + col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col0 + + col1 * col1 AS col1 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT ALL + + 38 * col2 + + col0 AS col0 FROM tab1 AS cor0
----
2055
2230
3728

query I rowsort
SELECT ALL + col0 + cor0.col0 + + 70 AS col1 FROM tab0 cor0
----
118
140
248

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 7 col1 FROM tab1 AS cor0
----
7
7
7

query I rowsort
SELECT DISTINCT - cor0.col2 * - col1 * - 92 + - 62 AS col1 FROM tab1 AS cor0
----
-114878
-129230
-52502

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - col2 * 4 + col1 col0 FROM tab0
----
-13
-155
94

query I rowsort
SELECT DISTINCT + col1 + col0 * - col0 + tab1.col1 AS col2 FROM tab1
----
-4076
-6374
43

query I rowsort
SELECT - ( col0 ) + + ( - ( col0 ) ) + col2 AS col2 FROM tab1
----
-64
-71
48

query I rowsort
SELECT DISTINCT + 78 + - col1 * cor0.col2 + - col0 AS col0 FROM tab2 AS cor0
----
-1534
-647
-766

onlyif mysql # use DIV operator for integer division
query I rowsort label-4424
SELECT DISTINCT + - col1 * + col2 + - col1 DIV + col1 + col0 AS col0 FROM tab1 AS cor0
----
-1169
-1402
-507

skipif mysql # not compatible
query I rowsort label-4424
SELECT DISTINCT + - col1 * + col2 + - col1 / + col1 + col0 AS col0 FROM tab1 AS cor0
----
-1169
-1402
-507

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - 34 * cor1.col1 ) col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 0b3ab941cc485d31b676d4d234bf59d4

query I rowsort
SELECT - - 81 FROM tab1 AS cor0
----
81
81
81

query I rowsort
SELECT ALL + cor0.col0 + - 36 FROM tab1 AS cor0
----
-33
28
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-4428
SELECT col0 DIV - col0 + col0 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-4428
SELECT col0 / - col0 + col0 FROM tab2 AS cor0
----
6
77
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col2 * - 79 col1 FROM tab0 AS cor0
----
-531196
-79
-86031

query I rowsort
SELECT ALL + cor0.col0 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL - col2 * col1 * + col0 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT - col2 * ( - 56 + - col1 ) FROM tab2 AS cor0
----
2349
2774
2990

query I rowsort
SELECT - col2 + ( - 0 ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * col0 * 56 + - cor0.col1 col0 FROM tab0 AS cor0
----
32170
443485
68503

query I rowsort
SELECT ALL + col2 - - tab0.col0 AS col1 FROM tab0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-4436
SELECT - col2 + col1 - col0 DIV 43 AS col1 FROM tab2
----
-22
32
4

skipif mysql # not compatible
query I rowsort label-4436
SELECT - col2 + col1 - col0 / 43 AS col1 FROM tab2
----
-22
32
4

query I rowsort
SELECT col2 + col1 + 23 AS col2 FROM tab1
----
103
132
90

query I rowsort
SELECT ALL - col2 + cor0.col0 * cor0.col1 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4439
SELECT - + CAST( + col1 AS SIGNED ) + + col1 * + col1 AS col0 FROM tab1 cor0
----
156
650
90

skipif mysql # not compatible
query I rowsort label-4439
SELECT - + CAST ( + col1 AS INTEGER ) + + col1 * + col1 AS col0 FROM tab1 cor0
----
156
650
90

query I rowsort
SELECT DISTINCT - - col0 - + col2 * - col2 * + col2 AS col1 FROM tab2 AS cor0
----
17654
19690
54951

onlyif mysql # use DIV operator for integer division
query I rowsort label-4441
SELECT ALL col2 + 6 DIV cor0.col0 + 85 * + col1 col2 FROM tab0 AS cor0
----
7343
7817
8246

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4441
SELECT ALL col2 + 6 / cor0.col0 + 85 * + col1 col2 FROM tab0 AS cor0
----
7343
7817
8246

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4442
SELECT DISTINCT - + ( - cor0.col1 ) * col2 / CAST( NULL AS SIGNED ) + 98 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4442
SELECT DISTINCT - + ( - cor0.col1 ) * col2 / CAST ( NULL AS INTEGER ) + 98 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - 24 + + 92 AS col1 FROM tab1 AS cor0
----
68
68
68

query I rowsort
SELECT DISTINCT 21 * + col0 + - col2 * 27 AS col2 FROM tab0 AS cor0
----
-345
-387
708

query I rowsort
SELECT ( cor0.col2 ) * - col0 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + col1 + ( col2 ) AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT + col1 + + col1 * col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT + col2 + col1 + col0 FROM tab2
----
134
163
65

query I rowsort
SELECT ALL - - 68 * + col2 FROM tab1 AS cor0
----
3672
3876
6528

query I rowsort
SELECT ( + col1 ) * col2 + 49 * col0 FROM tab0 AS cor0
----
11823
1812
4014

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4451
SELECT DISTINCT - - CAST( NULL AS SIGNED ) * col1 * col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4451
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) * col1 * col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + ( + cor0.col2 ) AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - - cor1.col1 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
17
31
59

query I rowsort
SELECT ALL - + col2 + cor0.col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + 77 * cor0.col2 AS col0 FROM tab0 AS cor0
----
2541
6314
77

query I rowsort
SELECT - col1 * - col1 * + col1 FROM tab2 AS cor0
----
205379
29791
4913

query I rowsort
SELECT ALL col1 * - col0 + - col1 * - tab1.col0 + + col1 AS col1 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT col2 * col1 * + col1 + tab2.col0 * col2 + col0 AS col1 FROM tab2
----
14063
26143
92612

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL <= col1 * col1 * col2
----

query I rowsort
SELECT ALL - col2 + + col2 + + col2 AS col2 FROM tab0
----
1
33
82

query I rowsort
SELECT - col2 * col0 * - col2 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT col1 * - col1 - col1 AS col0 FROM tab2
----
-306
-3540
-992

query I rowsort
SELECT - col2 - - tab1.col0 * col0 FROM tab1 WHERE ( NULL ) NOT BETWEEN ( NULL ) AND ( NULL )
----

query I rowsort
SELECT DISTINCT col2 * col0 + + col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT tab1.col1 + col1 + - tab1.col2 FROM tab1
----
-2
-37
-70

query I rowsort
SELECT ALL + col1 + + col0 + + col1 AS col0 FROM tab1
----
106
55
84

query III rowsort
SELECT * FROM tab0 WHERE NULL <= ( - col0 * + col1 - col0 )
----

query I rowsort
SELECT ALL col1 + col2 + - col2 FROM tab2
----
17
31
59

query I rowsort
SELECT - - cor0.col1 * 51 FROM tab1, tab0 cor0
----
9 values hashing to 98c668e36be52a824d29bbc0004a3f1b

query I rowsort
SELECT ALL + col0 - - col1 AS col1 FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT + col1 * + col2 + + col1 AS col1 FROM tab2
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col1 * col0 + + col1 col0 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT + tab2.col0 * col0 - - tab2.col1 * - col1 AS col0 FROM tab2
----
-912
2603
5952

query I rowsort
SELECT col1 AS col2 FROM tab2 WHERE NULL = ( col0 )
----

query I rowsort
SELECT ALL col1 - + col1 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4476
SELECT tab0.col1 * col0 + col0 DIV col0 AS col2 FROM tab0
----
2065
3396
8100

skipif mysql # not compatible
query I rowsort label-4476
SELECT tab0.col1 * col0 + col0 / col0 AS col2 FROM tab0
----
2065
3396
8100

query I rowsort
SELECT ALL + col0 AS col2 FROM tab0 WHERE col2 NOT IN ( - tab0.col2 * - col2 + - col0 + - col0 )
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - cor0.col1 * - col2 + + col2 col0 FROM tab2 cor0
----
1619
701
895

query I rowsort
SELECT DISTINCT col0 * col0 + + col1 AS col2 FROM tab2
----
6143
6258
80

query I rowsort
SELECT col0 * + col2 * tab1.col2 AS col2 FROM tab1
----
207936
737280
8748

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL BETWEEN ( NULL ) AND ( NULL )
----

query III rowsort
SELECT * FROM tab1 WHERE col1 + - col1 IN ( - col0 - - tab1.col0 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL BETWEEN ( NULL ) AND - col0
----

query III rowsort
SELECT ALL * FROM tab1 AS cor0 WHERE NOT col2 * col0 NOT IN ( + col2 )
----

query I rowsort
SELECT - col2 * col0 + + col2 + col0 AS col0 FROM tab0 AS cor0
----
-7127
-735
1

query I rowsort
SELECT ALL + - 62 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

query I rowsort
SELECT ALL col1 + - 22 FROM tab1
----
-12
-9
4

query I rowsort
SELECT ALL + cor0.col0 * col1 + + col2 * cor0.col0 * + 42 FROM tab1 AS cor0
----
153856
323600
6882

query I rowsort
SELECT cor0.col0 + col2 * + col0 AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + col1 + - col2 + - col0 * col2 AS col1 FROM tab1 AS cor0
----
-190
-3695
-7763

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4491
SELECT + col2 * CAST( NULL AS DECIMAL ) + + 5 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4491
SELECT + col2 * CAST ( NULL AS REAL ) + + 5 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col0 * + ( col0 ) AS col2 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4493
SELECT + col1 DIV + cor0.col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4493
SELECT + col1 / + cor0.col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT - col0 * 69 FROM tab2
----
-483
-5382
-5451

query I rowsort
SELECT + + 66 + - 73 - col0 FROM tab0 AS cor0
----
-31
-42
-96

query I rowsort
SELECT ALL - cor0.col1 * - cor0.col1 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 4a2f25e7025075a0ce048be425c35957

query I rowsort
SELECT - col0 + + col1 + - col0 AS col2 FROM tab0 AS cor0
----
-87
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-4498
SELECT ALL + + 52 DIV - col0 AS col0 FROM tab1 AS cor0
----
-17
0
0

skipif mysql # not compatible
query I rowsort label-4498
SELECT ALL + + 52 / - col0 AS col0 FROM tab1 AS cor0
----
-17
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 82 col0 FROM tab1
----
-82
-82
-82

query I rowsort
SELECT + col0 + col0 * - ( + cor0.col2 ) AS col1 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT - + 43 * col2 AS col1 FROM tab0 AS cor0
----
-1419
-3526
-43

query I rowsort
SELECT 56 * + cor0.col2 FROM tab2 AS cor0
----
1456
1512
2128

query I rowsort
SELECT DISTINCT + + col2 + col0 * 21 AS col2 FROM tab1 AS cor0
----
117
1401
1776

onlyif mysql # use DIV operator for integer division
query I rowsort label-4504
SELECT DISTINCT - cor0.col1 DIV cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-4504
SELECT DISTINCT - cor0.col1 / cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT - cor0.col1 * - 16 * - col0 FROM tab2 AS cor0
----
-21488
-3472
-73632

query I rowsort
SELECT + col1 + ( ( - cor0.col1 ) ) * ( - 88 ) FROM tab1 AS cor0
----
1157
2314
890

query I rowsort
SELECT - col1 * ( - cor0.col2 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + cor0.col2 AS col0 FROM tab0, tab2 cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

onlyif mysql # use DIV operator for integer division
query I rowsort label-4509
SELECT cor0.col1 - - 82 DIV - cor0.col0 AS col0 FROM tab2 AS cor0
----
16
20
58

skipif mysql # not compatible
query I rowsort label-4509
SELECT cor0.col1 - - 82 / - cor0.col0 AS col0 FROM tab2 AS cor0
----
16
20
58

query I rowsort
SELECT ALL - ( + col0 ) * - col1 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL + 79 * - col0 * + col2 FROM tab0 cor0
----
-2765
-576542
-62568

query I rowsort
SELECT cor0.col0 + - cor0.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 1c0f12b2ac8c8b522b92205460500f94

query I rowsort
SELECT ALL + + cor0.col0 + - col2 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT col0 * - col1 - + cor0.col0 * col1 FROM tab2 AS cor0
----
-2686
-434
-9204

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4515
SELECT - CAST( - col0 AS SIGNED ) - + col0 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
-1190
-552
-7832

skipif mysql # not compatible
query I rowsort label-4515
SELECT - CAST ( - col0 AS INTEGER ) - + col0 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT 47 FROM tab2, tab1 cor0
----
47

query I rowsort
SELECT + 99 + - col1 AS col0 FROM tab0
----
13
2
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4518
SELECT CAST( NULL AS SIGNED ) * col2 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4518
SELECT CAST ( NULL AS INTEGER ) * col2 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 45 - - col0 FROM tab0
----
134
69
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4520
SELECT DISTINCT col2 * col1 DIV + col0 - - col1 FROM tab1
----
18
28
494

skipif mysql # not compatible
query I rowsort label-4520
SELECT DISTINCT col2 * col1 / + col0 - - col1 FROM tab1
----
18
28
494

query I rowsort
SELECT + ( - 78 ) * - col1 * + tab0.col2 AS col2 FROM tab0
----
221364
582036
7566

onlyif mysql # use DIV operator for integer division
query I rowsort label-4522
SELECT 0 + + col0 + - tab2.col0 * col0 DIV + col1 AS col2 FROM tab2
----
-25
-288
6

skipif mysql # not compatible
query I rowsort label-4522
SELECT 0 + + col0 + - tab2.col0 * col0 / + col1 AS col2 FROM tab2
----
-25
-288
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-4523
SELECT + ( + tab1.col1 ) - col1 DIV tab1.col0 FROM tab1
----
10
13
18

skipif mysql # not compatible
query I rowsort label-4523
SELECT + ( + tab1.col1 ) - col1 / tab1.col0 FROM tab1
----
10
13
18

query I rowsort
SELECT col1 + + col0 + col2 AS col0 FROM tab0
----
133
143
262

query I rowsort
SELECT - ( - tab2.col2 ) + - col1 AS col1 FROM tab2
----
-33
-4
21

query I rowsort
SELECT tab2.col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col2 col1 FROM tab2
----
52
54
76

query I rowsort
SELECT + col1 * col1 - ( + col1 + tab2.col2 ) AS col2 FROM tab2
----
234
3396
903

query I rowsort
SELECT + 61 * cor1.col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 86ad322ab690fae692344a42a0d894c1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - tab2.col1 col2 FROM tab2
----
-137
-38
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4531
SELECT - cor0.col2 * CAST( + col1 AS SIGNED ) FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-4531
SELECT - cor0.col2 * CAST ( + col1 AS INTEGER ) FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - cor0.col0 + col0 * col1 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT - col1 * col0 * 6 AS col0 FROM tab0 AS cor0
----
-12384
-20370
-48594

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + ( 58 ) col1 FROM tab2 AS cor0
----
136
137
65

query I rowsort
SELECT col0 * col2 + - col1 * col1 FROM tab0
----
-6604
-9374
-983

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col2 * + col1 + + col1 * + col0 col2 FROM tab2 AS cor0
----
124254
52377
6076

onlyif mysql # use DIV operator for integer division
query I rowsort label-4537
SELECT ALL + col1 DIV col1 AS col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4537
SELECT ALL + col1 / col1 AS col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - col1 * col1 + col0 AS col2 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT DISTINCT + col0 + + col0 * - col0 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT ALL + col0 * col2 + col2 * col2 FROM tab0 AS cor0
----
14022
1881
36

query I rowsort
SELECT ALL col2 + - cor0.col0 * col2 AS col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT col1 * col2 + + tab2.col1 * - col1 * col2 FROM tab2
----
-10336
-25110
-88972

query I rowsort
SELECT DISTINCT cor0.col0 AS col2 FROM tab2, tab0, tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4544
SELECT ALL + cor0.col2 DIV - col0 + - col0 DIV - col1 col1 FROM tab2 AS cor0
----
-3
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4544
SELECT ALL + cor0.col2 / - col0 + - col0 / - col1 col1 FROM tab2 AS cor0
----
-3
1
4

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT - col0 - - cor0.col2 NOT BETWEEN NULL AND NULL OR NOT col1 NOT BETWEEN cor0.col1 * col0 AND NULL
----

query I rowsort
SELECT ALL - col1 + + col1 * col2 AS col0 FROM tab2 cor0
----
1475
629
806

query I rowsort
SELECT - 75 + - col1 FROM tab1 cor0
----
-101
-85
-88

query I rowsort
SELECT DISTINCT + col1 * cor0.col1 * - col0 + cor0.col1 FROM tab1 AS cor0
----
-13507
-2002
-6390

query I rowsort
SELECT 46 + + col0 + + col1 AS col0 FROM tab1
----
120
139
75

query I rowsort
SELECT 68 * + col2 + - col2 + col2 * - tab1.col1 AS col0 FROM tab1
----
2214
3249
5184

query I rowsort
SELECT DISTINCT 10 + col2 * col1 FROM tab1 AS cor0
----
1258
1414
580

query I rowsort
SELECT ALL + 69 - col2 * - col2 FROM tab0 AS cor0
----
1158
6793
70

query I rowsort
SELECT ALL + + cor0.col0 * col2 + col0 + col2 AS col0 FROM tab1 AS cor0
----
219
3769
7856

query I rowsort
SELECT DISTINCT + + 41 AS col0 FROM tab2 cor0
----
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-4555
SELECT + tab0.col2 DIV - col1 - + col1 col2 FROM tab0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4555
SELECT + tab0.col2 / - col1 - + col1 col2 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT ( - col2 ) * + 72 AS col0 FROM tab2
----
-1872
-1944
-2736

query I rowsort
SELECT col1 * + col1 * 31 AS col0 FROM tab0
----
229276
256711
291679

query I rowsort
SELECT ALL - tab0.col1 * 11 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 13afe11d6134df4c5c12a7815716b949

query I rowsort
SELECT DISTINCT - 76 + + cor0.col1 FROM tab1 AS cor0
----
-50
-63
-66

query I rowsort
SELECT - col2 + + 18 FROM tab0 cor0
----
-15
-64
17

query I rowsort
SELECT + + col1 + + cor0.col0 * + col0 FROM tab2 AS cor0
----
6143
6258
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4562
SELECT - col2 DIV cor0.col0 AS col0 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4562
SELECT - col2 / cor0.col0 AS col0 FROM tab0 cor0
----
-1
0
0

query I rowsort
SELECT + + cor0.col2 + 74 FROM tab1 AS cor0
----
128
131
170

onlyif mysql # use DIV operator for integer division
query I rowsort label-4564
SELECT ALL + col0 * col1 + + 89 DIV col1 FROM tab0 AS cor0
----
2065
3395
8099

skipif mysql # not compatible
query I rowsort label-4564
SELECT ALL + col0 * col1 + + 89 / col1 FROM tab0 AS cor0
----
2065
3395
8099

query I rowsort
SELECT + col2 * + col1 + + col2 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT tab0.col2 + col1 * - tab0.col0 AS col2 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT - 41 + - col1 + 63 FROM tab2
----
-37
-9
5

query I rowsort
SELECT ALL 38 + + col1 * ( - col0 ) FROM tab2
----
-1305
-179
-4564

query I rowsort
SELECT DISTINCT + col2 + + tab1.col1 AS col0 FROM tab1
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - cor0.col1 col1 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * col2 + 65 col1 FROM tab0 AS cor0
----
-1024
-6659
64

query I rowsort
SELECT + col2 + 58 FROM tab1 AS cor0
----
112
115
154

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT + col0 + CAST ( + cor0.col1 * col1 AS REAL ) - ( + cor0.col2 ) col2 FROM tab2 AS cor0
----
330
3533
941

query I rowsort
SELECT - - cor0.col2 * + ( col0 ) AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL + col0 + 41 AS col1 FROM tab2 AS cor0
----
119
120
48

query I rowsort
SELECT DISTINCT 1 * col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + ( cor0.col2 ) * + col1 * - ( - col1 ) + + col0 + - col0 * 89 AS col1 FROM tab1 AS cor0
----
36240
68
9184

query I rowsort
SELECT DISTINCT - - 56 + cor0.col0 FROM tab1 AS cor0
----
120
136
59

query I rowsort
SELECT DISTINCT - 97 * 2 + cor0.col2 FROM tab2 AS cor0
----
-156
-167
-168

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( 29 ) + cor0.col1 col2 FROM tab2 cor0
----
46
60
88

query I rowsort
SELECT DISTINCT + col2 + col2 + + col2 AS col1 FROM tab2 AS cor0
----
114
78
81

query I rowsort
SELECT + cor0.col2 * + 2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL + + col0 + cor0.col1 FROM tab2 cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4584
SELECT ALL col0 + ( col0 ) DIV - ( - 5 ) FROM tab1 AS cor0
----
3
76
96

skipif mysql # not compatible
query I rowsort label-4584
SELECT ALL col0 + ( col0 ) / - ( - 5 ) FROM tab1 AS cor0
----
3
76
96

query I rowsort
SELECT + - 49 AS col1 FROM tab2 AS cor0
----
-49
-49
-49

query I rowsort
SELECT + 28 + - 34 AS col0 FROM tab1 AS cor0
----
-6
-6
-6

query I rowsort
SELECT DISTINCT 5 - 91 AS col2 FROM tab1, tab2 AS cor0
----
-86

query I rowsort
SELECT + tab2.col2 + tab2.col2 * col2 * tab2.col1 AS col0 FROM tab2
----
22626
24586
39910

query I rowsort
SELECT ALL cor0.col0 AS col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT - - ( col0 ) + - col2 AS col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL - - 66 + ( col1 ) FROM tab1 AS cor0
----
76
79
92

query I rowsort
SELECT - ( col1 ) * + col1 AS col1 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - + cor0.col1 FROM tab0, tab0 cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT DISTINCT - 51 FROM tab0, tab1 cor0
----
-51

query I rowsort
SELECT DISTINCT - - col0 - - col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - + 78 AS col2 FROM tab0, tab1, tab0 AS cor0
----
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4597
SELECT - ( col2 ) * CAST( NULL AS DECIMAL ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4597
SELECT - ( col2 ) * CAST ( NULL AS REAL ) AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * 80 FROM tab1
----
4320
4560
7680

query I rowsort
SELECT DISTINCT cor0.col2 AS col2 FROM tab2, tab1 AS cor0, tab1 AS cor1, tab2 AS cor2
----
54
57
96

query I rowsort
SELECT - 12 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e698dd57d3aac30af14ce35da434bb45

query I rowsort
SELECT DISTINCT + 98 FROM tab2, tab2 cor0
----
98

skipif mysql # not compatible
query I rowsort
SELECT ALL - col1 * CAST ( col2 AS REAL ) + - col2 AS col0 FROM tab1 cor0
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT + 28 * col1 FROM tab2
----
1652
476
868

query I rowsort
SELECT - ( + col0 ) * + col2 * - col1 AS col1 FROM tab0 AS cor0
----
3395
664118
68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col1 * col1 col1 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT + 25 FROM tab1, tab2 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 68fc0eecd4f434589f3ec576bbd0c540

query I rowsort
SELECT - col2 + - 72 FROM tab2
----
-110
-98
-99

query I rowsort
SELECT - col1 + + col2 * + 41 FROM tab0 AS cor0
----
-56
1267
3271

query I rowsort
SELECT DISTINCT + col1 * - 89 AS col2 FROM tab2 AS cor0
----
-1513
-2759
-5251

query I rowsort
SELECT DISTINCT col1 - col0 * 9 AS col2 FROM tab0 AS cor0
----
-130
-218
-710

query I rowsort
SELECT ALL - cor0.col0 + ( 25 + col2 ) AS col2 FROM tab1 cor0
----
18
41
76

query I rowsort
SELECT col0 * + 69 FROM tab2 AS cor0
----
483
5382
5451

query I rowsort
SELECT ALL + col2 + ( - col2 ) AS col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - - col2 * 31 + col2 FROM tab1 AS cor0
----
1728
1824
3072

query I rowsort
SELECT ALL - ( 94 ) + col0 * col2 AS col0 FROM tab0 AS cor0
----
-59
698
7204

query I rowsort
SELECT ALL 18 * - col1 + + col2 * - ( - cor0.col0 ) + + col2 * + cor0.col0 FROM tab0 AS cor0
----
-1676
12958
36

query I rowsort
SELECT DISTINCT + ( - col2 ) * col2 AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT - ( - cor1.col0 ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + 36 * + 55 FROM tab1, tab1 AS cor0
----
9 values hashing to 86870309577f915d87b6adce04b0683f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4620
SELECT ALL - col1 / - CAST( NULL AS SIGNED ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4620
SELECT ALL - col1 / - CAST ( NULL AS INTEGER ) AS col0 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4621
SELECT ALL CAST( + col0 AS SIGNED ) + + col2 AS col1 FROM tab1 AS cor0
----
121
176
57

skipif mysql # not compatible
query I rowsort label-4621
SELECT ALL CAST ( + col0 AS INTEGER ) + + col2 AS col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - + ( col2 ) * - ( - col2 ) FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 + col2 * col1 col0 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT DISTINCT - col1 * - col0 + col0 AS col2 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT 20 * col0 AS col1 FROM tab2
----
140
1560
1580

query I rowsort
SELECT DISTINCT + col2 + + ( + col0 ) FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - - col2 + col1 AS col0 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT + 68 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

query I rowsort
SELECT ALL - 13 + col2 AS col0 FROM tab1
----
41
44
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4630
SELECT + - col2 * col2 * + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4630
SELECT + - col2 * col2 * + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4631
SELECT col1 DIV - col1 + - ( - ( col1 ) ) DIV - col0 AS col0 FROM tab0
----
-2
-3
-4

skipif mysql # not compatible
query I rowsort label-4631
SELECT col1 / - col1 + - ( - ( col1 ) ) / - col0 AS col0 FROM tab0
----
-2
-3
-4

query I rowsort
SELECT + ( 77 ) AS col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to d7b027bca5d37c67e29013904def8125

query I rowsort
SELECT tab2.col1 - col0 * - ( tab2.col1 ) FROM tab2
----
1360
248
4661

query I rowsort
SELECT DISTINCT - tab1.col2 * + col1 + col1 FROM tab1
----
-1235
-1378
-560

query I rowsort
SELECT col1 - col0 * 54 FROM tab2
----
-347
-4153
-4249

skipif mysql # not compatible
query I rowsort
SELECT - col2 * - CAST ( + col2 AS REAL ) AS col0 FROM tab2 AS cor0
----
1444
676
729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4637
SELECT DISTINCT + col0 * - CAST( col0 AS SIGNED ) FROM tab0 AS cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-4637
SELECT DISTINCT + col0 * - CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL - - col2 * 46 + - col0 FROM tab0 AS cor0
----
11
1494
3683

query I rowsort
SELECT - col0 * 95 + + col0 AS col1 FROM tab1 AS cor0
----
-282
-6016
-7520

query I rowsort
SELECT DISTINCT 61 * + tab2.col1 + col1 * 63 + + col2 * + ( ( col0 ) ) FROM tab2
----
4033
5110
9344

query I rowsort
SELECT ALL + col0 + - col1 * col0 AS col2 FROM tab0
----
-2040
-3360
-8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4642
SELECT cor0.col1 + - CAST( NULL AS SIGNED ) * + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4642
SELECT cor0.col1 + - CAST ( NULL AS INTEGER ) * + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 + + ( 86 ) AS col1 FROM tab0 AS cor0
----
110
121
175

onlyif mysql # use DIV operator for integer division
query I rowsort label-4644
SELECT DISTINCT col1 DIV 90 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4644
SELECT DISTINCT col1 / 90 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - + col1 + - 76 * - 81 FROM tab2 cor0
----
6097
6125
6139

query I rowsort
SELECT DISTINCT col2 * + 8 FROM tab1 AS cor0
----
432
456
768

query I rowsort
SELECT cor0.col1 + col1 * - col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT ALL col1 * - 24 FROM tab1 cor0
----
-240
-312
-624

query I rowsort
SELECT ALL - cor1.col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT ALL col1 * col1 * col1 - col2 * + col2 FROM tab1
----
-2249
-7019
14660

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 - + 67 col1 FROM tab1
----
-10
-13
29

query I rowsort
SELECT ALL 64 * + ( - col0 ) - - ( - col0 ) AS col0 FROM tab0
----
-1560
-2275
-5785

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 24 + col1 col0 FROM tab2
----
41
55
83

query I rowsort
SELECT ALL col0 + + 48 * col2 FROM tab1 AS cor0
----
2595
2800
4688

query I rowsort
SELECT DISTINCT - 83 + - col0 + - col1 FROM tab1
----
-112
-157
-176

query I rowsort
SELECT DISTINCT + 43 + 59 * + col1 FROM tab2
----
1046
1872
3524

query I rowsort
SELECT 12 * col2 AS col2 FROM tab0 cor0
----
12
396
984

query I rowsort
SELECT - col2 * col1 * + col0 + col2 AS col0 FROM tab1 AS cor0
----
-36423
-4158
-99744

query I rowsort
SELECT ALL 67 * + col0 AS col1 FROM tab0 AS cor0
----
1608
2345
5963

query I rowsort
SELECT + col0 + - col2 + col1 AS col0 FROM tab0 cor0
----
131
77
98

query I rowsort
SELECT - 77 * - tab1.col0 FROM tab1
----
231
4928
6160

query I rowsort
SELECT ALL - col2 * col2 * col1 + ( col1 ) FROM tab0 AS cor0
----
-611793
-93568
0

query I rowsort
SELECT ALL col2 + - col2 + col2 AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT + - col2 * col2 AS col0 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + 57 * col0 * + 75 AS col2 FROM tab1 AS cor0
----
12825
273600
342000

onlyif mysql # use DIV operator for integer division
query I rowsort label-4666
SELECT ALL 23 DIV - ( + col0 * + col1 ) FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4666
SELECT ALL 23 / - ( + col0 * + col1 ) FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4667
SELECT ALL + - col2 DIV - col2 + + col1 * - cor0.col1 FROM tab1 AS cor0
----
-168
-675
-99

skipif mysql # not compatible
query I rowsort label-4667
SELECT ALL + - col2 / - col2 + + col1 * - cor0.col1 FROM tab1 AS cor0
----
-168
-675
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-4668
SELECT cor0.col0 + - col1 DIV - col0 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-4668
SELECT cor0.col0 + - col1 / - col0 FROM tab1 AS cor0
----
11
64
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4669
SELECT DISTINCT + ( cor0.col0 ) * - CAST( - col1 + + col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-1482
-4898
168

skipif mysql # not compatible
query I rowsort label-4669
SELECT DISTINCT + ( cor0.col0 ) * - CAST ( - col1 + + col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-1482
-4898
168

onlyif mysql # use DIV operator for integer division
query I rowsort label-4670
SELECT DISTINCT 27 DIV cor0.col2 col1 FROM tab0 AS cor0
----
0
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4670
SELECT DISTINCT 27 / cor0.col2 col1 FROM tab0 AS cor0
----
0
27

skipif mysql # not compatible
query I rowsort
SELECT + + col0 + - col2 * + CAST ( col1 AS REAL ) AS col1 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL + - 89 * cor0.col2 * - col0 FROM tab0 AS cor0
----
3115
649522
70488

query I rowsort
SELECT col1 + col2 * col2 * col1 AS col1 FROM tab1 AS cor0
----
119821
32500
75842

query I rowsort
SELECT ALL tab0.col1 * + col2 AS col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT ALL + ( - 37 ) AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to ed4644af7729c2425ea6cc3d84c6504f

query I rowsort
SELECT DISTINCT + 14 AS col0 FROM tab2, tab0 cor0
----
14

query I rowsort
SELECT DISTINCT 87 + + 33 FROM tab0, tab0 AS cor0
----
120

query I rowsort
SELECT DISTINCT col0 * 74 FROM tab1
----
222
4736
5920

query I rowsort
SELECT - 78 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to b6e4cc21599216686f0cf45b85668b2c

query I rowsort
SELECT - 21 - col1 AS col2 FROM tab0 AS cor0
----
-107
-112
-118

query I rowsort
SELECT ALL - - 97 FROM tab0 AS cor0
----
97
97
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4682
SELECT + - 3 * col1 + - col0 + CAST( - 18 AS SIGNED ) FROM tab2 AS cor0
----
-118
-148
-273

skipif mysql # not compatible
query I rowsort label-4682
SELECT + - 3 * col1 + - col0 + CAST ( - 18 AS INTEGER ) FROM tab2 AS cor0
----
-118
-148
-273

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col1 - col1 col2 FROM tab1 cor0
----
-20
-26
-52

query I rowsort
SELECT ( 18 ) + col1 * - col0 * + col1 FROM tab0 AS cor0
----
-177486
-329297
-736991

query I rowsort
SELECT DISTINCT + - col1 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + + cor0.col2 * + col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT 56 * col2 * - col0 AS col2 FROM tab0
----
-1960
-408688
-44352

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4688
SELECT DISTINCT + CAST( NULL AS SIGNED ) + + ( - col2 ) * ( - col1 ) * + col1 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4688
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + + ( - col2 ) * ( - col1 ) * + col1 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col1 * col1 + + col0 AS col0 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT col1 * cor0.col1 + col2 + - col1 FROM tab0 AS cor0
----
7343
8272
9313

query I rowsort
SELECT ALL + col0 * - col2 * col2 FROM tab2 cor0
----
-114076
-5103
-52728

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4692
SELECT + - CAST( NULL AS SIGNED ) + + cor0.col1 * cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4692
SELECT + - CAST ( NULL AS INTEGER ) + + cor0.col1 * cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 + col2 * - 90 col2 FROM tab1 AS cor0
----
-4834
-5120
-8627

query I rowsort
SELECT DISTINCT - + 44 + col2 FROM tab0 AS cor0
----
-11
-43
38

query I rowsort
SELECT DISTINCT cor0.col0 FROM tab0, tab0 AS cor0, tab2, tab1 AS cor1
----
24
35
89

query I rowsort
SELECT DISTINCT + + cor0.col0 + + col1 - + 99 FROM tab1 AS cor0
----
-25
-6
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 - - col0 * 10 col0 FROM tab2 AS cor0
----
806
828
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4698
SELECT ALL + + cor0.col0 * col1 * CAST( + col1 * col1 AS SIGNED ) + col0 AS col2 FROM tab2 cor0
----
16019640
208544
388206

skipif mysql # not compatible
query I rowsort label-4698
SELECT ALL + + cor0.col0 * col1 * CAST ( + col1 * col1 AS INTEGER ) + col0 AS col2 FROM tab2 cor0
----
16019640
208544
388206

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4699
SELECT ALL + + col0 + - col2 + - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4699
SELECT ALL + + col0 + - col2 + - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - 24 * col0 AS col0 FROM tab2 AS cor0
----
-168
-1872
-1896

query I rowsort
SELECT DISTINCT - - ( - cor0.col1 ) AS col1 FROM tab2 AS cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 77 + col0 col2 FROM tab2 AS cor0
----
-70
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 54 col0 FROM tab0, tab0 AS cor0, tab1 cor1
----
54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4704
SELECT + col1 * - CAST( NULL AS DECIMAL ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4704
SELECT + col1 * - CAST ( NULL AS REAL ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - tab2.col1 * col1 * + col2 + + col1 * + col2 * tab2.col0 FROM tab2
----
-20088
29146
40052

query I rowsort
SELECT col0 * col0 * cor0.col2 AS col0 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT - col2 * - cor0.col0 + - 32 AS col1 FROM tab1 AS cor0
----
130
3616
7648

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4708
SELECT DISTINCT - CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4708
SELECT DISTINCT - CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 59 + + tab1.col1 col2 FROM tab1
----
-33
-46
-49

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT + col0 + ( col2 + cor0.col2 ) * CAST ( 23 AS REAL ) col1 FROM tab2 AS cor0
----
1249
1274
1827

query I rowsort
SELECT DISTINCT col0 + - 52 FROM tab0 cor0
----
-17
-28
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-4712
SELECT ALL + ( + col0 ) + col1 DIV - col1 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-4712
SELECT ALL + ( + col0 ) + col1 / - col1 FROM tab2 AS cor0
----
6
77
78

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab0, tab1 cor1, tab0 cor2
----
972 values hashing to 95920403df268a272c4e933cd0bbe0be

query I rowsort
SELECT 54 - col0 * - 36 FROM tab1 AS cor0
----
162
2358
2934

onlyif mysql # use DIV operator for integer division
query I rowsort label-4715
SELECT ALL - col1 + - 32 * col0 DIV - 88 AS col0 FROM tab1
----
-25
13
16

skipif mysql # not compatible
query I rowsort label-4715
SELECT ALL - col1 + - 32 * col0 / - 88 AS col0 FROM tab1
----
-25
13
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 43 * + col1 * col1 col0 FROM tab1
----
-29068
-4300
-7267

query I rowsort
SELECT ALL - 99 FROM tab0, tab2 AS cor0
----
9 values hashing to 64d06513850a26495bc6c2fddeb254b7

query I rowsort
SELECT - 26 * col0 AS col1 FROM tab2 AS cor0
----
-182
-2028
-2054

query I rowsort
SELECT col2 + + col1 + - cor0.col1 AS col0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + col0 + tab0.col1 + col1 * + col0 FROM tab0
----
2174
3527
8279

query I rowsort
SELECT - - 92 * col1 + cor0.col2 * col2 * + 22 AS col2 FROM tab2 AS cor0
----
18890
20300
33332

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4722
SELECT + - CAST( NULL AS SIGNED ) + - 55 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-4722
SELECT + - CAST ( NULL AS INTEGER ) + - 55 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 41 + - 84 * col1 FROM tab0 cor0
----
-7183
-7603
-8107

query I rowsort
SELECT cor1.col1 AS col0 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT 16 * + col2 AS col1 FROM tab1 AS cor0
----
1536
864
912

query I rowsort
SELECT ( - col2 ) + 80 * + col1 AS col0 FROM tab0 cor0
----
6847
7198
7759

query I rowsort
SELECT ALL 26 * col2 AS col1 FROM tab0 AS cor0
----
2132
26
858

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4728
SELECT ALL - CAST( NULL AS SIGNED ) AS col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4728
SELECT ALL - CAST ( NULL AS INTEGER ) AS col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + + col2 * - col0 + + col2 AS col0 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT ALL tab2.col0 - ( 39 * - col0 ) AS col1 FROM tab2
----
280
3120
3160

query I rowsort
SELECT DISTINCT - tab0.col2 * + col2 + col2 - col1 FROM tab0
----
-1142
-6733
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - tab1.col1 + col2 - col1 col0 FROM tab1
----
-53
-648
-86

query I rowsort
SELECT - col1 - col2 * + 29 FROM tab2 AS cor0
----
-1119
-813
-814

query I rowsort
SELECT + col1 * col2 + 53 FROM tab0 AS cor0
----
150
2891
7515

query I rowsort
SELECT ALL - col0 * 11 FROM tab0 AS cor0
----
-264
-385
-979

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * + 92 - - ( + col2 ) col2 FROM tab1 cor0
----
330
5945
7456

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4737
SELECT + - col1 - + CAST( col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-4737
SELECT + - col1 - + CAST ( col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL + - ( + cor0.col1 ) + cor0.col0 * col1 * 3 FROM tab1 AS cor0
----
1910
208
3107

query I rowsort
SELECT DISTINCT - col2 * 6 AS col0 FROM tab2 AS cor0
----
-156
-162
-228

onlyif mysql # use DIV operator for integer division
query I rowsort label-4740
SELECT 79 DIV col2 AS col1 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-4740
SELECT 79 / col2 AS col1 FROM tab1 AS cor0
----
0
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4741
SELECT DISTINCT - 43 DIV 35 + col2 * col2 + + col1 * col1 FROM tab1 AS cor0
----
3348
3591
9384

skipif mysql # not compatible
query I rowsort label-4741
SELECT DISTINCT - 43 / 35 + col2 * col2 + + col1 * col1 FROM tab1 AS cor0
----
3348
3591
9384

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4742
SELECT + CAST( + col2 AS SIGNED ) + col2 FROM tab2 AS cor0
----
52
54
76

skipif mysql # not compatible
query I rowsort label-4742
SELECT + CAST ( + col2 AS INTEGER ) + col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT + 67 + col0 FROM tab2 AS cor0
----
145
146
74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4744
SELECT ALL CAST( + 18 AS SIGNED ) * - col1 FROM tab1 AS cor0
----
-180
-234
-468

skipif mysql # not compatible
query I rowsort label-4744
SELECT ALL CAST ( + 18 AS INTEGER ) * - col1 FROM tab1 AS cor0
----
-180
-234
-468

query I rowsort
SELECT 99 + + col0 AS col2 FROM tab2 AS cor0
----
106
177
178

onlyif mysql # use DIV operator for integer division
query I rowsort label-4746
SELECT - col1 + col0 DIV + col0 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-4746
SELECT - col1 + col0 / + col0 FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT + 19 * + cor0.col1 FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to 2370f55cecbdf566d5959c043f8529d3

query I rowsort
SELECT 60 * 88 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 857a4853400b64ac89a793fe8a6078fe

onlyif mysql # use DIV operator for integer division
query I rowsort label-4749
SELECT col2 DIV ( col0 ) + col0 + + col0 FROM tab1
----
128
161
24

skipif mysql # not compatible
query I rowsort label-4749
SELECT col2 / ( col0 ) + col0 + + col0 FROM tab1
----
128
161
24

query I rowsort
SELECT ALL + 19 FROM tab2, tab2 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT - 4 - col1 * cor0.col1 FROM tab1 cor0
----
-104
-173
-680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4752
SELECT ALL - CAST( NULL AS SIGNED ) - col2 / + col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4752
SELECT ALL - CAST ( NULL AS INTEGER ) - col2 / + col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4753
SELECT DISTINCT + cor1.col1 - CAST( - 25 AS SIGNED ) AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
111
116
122

skipif mysql # not compatible
query I rowsort label-4753
SELECT DISTINCT + cor1.col1 - CAST ( - 25 AS INTEGER ) AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
111
116
122

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4754
SELECT ALL + CAST( NULL AS SIGNED ) * + 76 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4754
SELECT ALL + CAST ( NULL AS INTEGER ) * + 76 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 - col0 * + col1 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT ALL ( + col1 ) + + col0 AS col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - col1 * + col1 + cor0.col0 AS col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT - col2 * col1 - 73 FROM tab2
----
-1607
-719
-910

query I rowsort
SELECT DISTINCT - ( + col0 ) + col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT + 47 * col1 AS col0 FROM tab0 AS cor0
----
4042
4277
4559

onlyif mysql # use DIV operator for integer division
query I rowsort label-4761
SELECT - 96 - - col1 DIV + col1 FROM tab1 AS cor0
----
-95
-95
-95

skipif mysql # not compatible
query I rowsort label-4761
SELECT - 96 - - col1 / + col1 FROM tab1 AS cor0
----
-95
-95
-95

query I rowsort
SELECT - - ( col2 ) + col0 * 93 FROM tab1 AS cor0
----
333
6009
7536

onlyif mysql # use DIV operator for integer division
query I rowsort label-4763
SELECT DISTINCT + col2 - - col2 DIV cor0.col1 FROM tab2 AS cor0
----
26
27
40

skipif mysql # not compatible
query I rowsort label-4763
SELECT DISTINCT + col2 - - col2 / cor0.col1 FROM tab2 AS cor0
----
26
27
40

query I rowsort
SELECT col0 * - col2 + tab2.col2 * + 95 AS col2 FROM tab2
----
2376
442
608

query I rowsort
SELECT + 2 + col0 AS col0 FROM tab2
----
80
81
9

query I rowsort
SELECT ALL + 46 FROM tab0, tab2 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT DISTINCT + col0 + 72 FROM tab1
----
136
152
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col1 ) * tab1.col1 + 42 col0 FROM tab1
----
142
211
718

query I rowsort
SELECT 22 FROM tab0, tab0 cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT DISTINCT ( 32 ) AS col1 FROM tab1 AS cor0
----
32

query I rowsort
SELECT 0 + col1 AS col2 FROM tab1
----
10
13
26

query I rowsort
SELECT ( - 87 ) * + col2 * + col1 FROM tab1
----
-108576
-122148
-49590

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4773
SELECT DISTINCT + col1 / CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4773
SELECT DISTINCT + col1 / CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL cor0.col0 * - col2 + col2 AS col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT col1 * 67 FROM tab1 AS cor0
----
1742
670
871

query I rowsort
SELECT DISTINCT - col0 + - col2 * col2 - + col1 * + 34 FROM tab0 AS cor0
----
-3334
-4037
-9907

query I rowsort
SELECT DISTINCT - col0 + - col2 * 19 AS col0 FROM tab1 AS cor0
----
-1029
-1147
-1904

query I rowsort
SELECT ALL + col0 * 90 + + 86 * col2 * col2 FROM tab0 cor0
----
3236
586274
95814

query I rowsort
SELECT DISTINCT + col2 - col1 * - col2 * + col1 FROM tab0 AS cor0
----
244101
679124
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-4780
SELECT ALL col0 DIV 69 + col1 DIV col0 AS col2 FROM tab2
----
1
1
4

skipif mysql # not compatible
query I rowsort label-4780
SELECT ALL col0 / 69 + col1 / col0 AS col2 FROM tab2
----
1
1
4

query I rowsort
SELECT + cor0.col1 + - col2 * + col1 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + cor0.col0 + + col2 col1 FROM tab0 AS cor0
----
-1224
-543
-7839

onlyif mysql # use DIV operator for integer division
query I rowsort label-4783
SELECT ALL + - col1 DIV - col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-4783
SELECT ALL + - col1 / - col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT DISTINCT + col0 * col2 * + 15 AS col2 FROM tab0 AS cor0
----
109470
11880
525

query I rowsort
SELECT - cor0.col2 * + col2 AS col0 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT - col2 / cor0.col0 + + col0 / + col1 FROM tab0 AS cor0 WHERE NULL <= col0
----

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NULL = col1
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 col2 FROM tab0, tab0 cor0
----
86
91
97

query I rowsort
SELECT DISTINCT col0 + col2 * col2 AS col0 FROM tab2
----
1523
736
754

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( NULL ) BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT DISTINCT col1 * + col1 + - col1 FROM tab0
----
7310
8190
9312

query I rowsort
SELECT - col2 - - tab2.col2 AS col1 FROM tab2
----
0
0
0

query III rowsort
SELECT * FROM tab2 WHERE col0 * + col1 <= ( NULL )
----

query I rowsort
SELECT ALL col2 + col1 * - tab1.col1 AS col2 FROM tab1
----
-43
-622
-73

query I rowsort
SELECT DISTINCT col1 * tab2.col2 + + col1 AS col0 FROM tab2
----
1593
663
868

query III rowsort
SELECT * FROM tab2 WHERE col1 <> NULL
----

query I rowsort
SELECT + col0 - + col2 AS col2 FROM tab1
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4798
SELECT + tab0.col0 + col0 DIV + col2 AS col2 FROM tab0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-4798
SELECT + tab0.col0 + col0 / + col2 AS col2 FROM tab0
----
24
70
90

query I rowsort
SELECT col1 + + col0 + + col2 FROM tab2
----
134
163
65

query I rowsort
SELECT DISTINCT + col0 + col1 * - col1 AS col2 FROM tab0
----
-7372
-8192
-9374

query I rowsort
SELECT col0 + - col1 * + col1 AS col1 FROM tab1
----
-36
-673
-89

query I rowsort
SELECT - col0 + col1 + - col0 FROM tab2
----
-141
-97
17

query I rowsort
SELECT - col2 + col0 + col0 AS col0 FROM tab0 AS cor0
----
15
69
96

query I rowsort
SELECT DISTINCT col2 * + col1 * col0 FROM tab1 cor0 WHERE NOT ( + col2 - col2 * - col0 ) <> NULL OR ( NULL ) IN ( col2 * - col1 + + col1 * - col0 )
----

query I rowsort
SELECT - - col1 + + col0 + col1 AS col2 FROM tab0 AS cor0
----
196
229
271

query I rowsort
SELECT col0 + - col2 * - col1 AS col0 FROM tab1
----
1328
1407
634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col1 * + col2 col0 FROM tab0
----
611884
93654
97

query I rowsort
SELECT DISTINCT tab2.col0 * col0 + + col0 + col1 AS col0 FROM tab2
----
6221
6337
87

query I rowsort
SELECT - col2 / + col2 AS col0 FROM tab2 WHERE NOT ( - col0 - + col0 * + col2 * col1 ) NOT IN ( tab2.col1 )
----

query I rowsort
SELECT DISTINCT - + col2 * col1 * + cor0.col0 + - col2 - + col0 FROM tab1 AS cor0
----
-100016
-36601
-4269

query I rowsort
SELECT DISTINCT - col0 * + col2 + + col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT - tab1.col2 * + col0 AS col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT + col2 * - tab2.col2 AS col0 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT + col2 * - col1 + cor0.col2 + col0 * - col1 AS col2 FROM tab0 AS cor0
----
-15479
-3491
-4869

query I rowsort
SELECT - - col2 * col1 + col2 * + col2 FROM tab2 AS cor0
----
1566
2090
2210

onlyif mysql # use DIV operator for integer division
query I rowsort label-4816
SELECT DISTINCT - - col2 * col0 + + col1 DIV cor0.col0 FROM tab1 AS cor0
----
170
3648
7680

skipif mysql # not compatible
query I rowsort label-4816
SELECT DISTINCT - - col2 * col0 + + col1 / cor0.col0 FROM tab1 AS cor0
----
170
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4817
SELECT DISTINCT + col2 - col2 DIV col2 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-4817
SELECT DISTINCT + col2 - col2 / col2 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT ALL - - cor0.col1 + - col2 * - col0 AS col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT ( col1 * col2 ) AS col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT - - tab1.col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL - cor0.col1 AS col2 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT - ( - col0 ) + + col0 AS col0 FROM tab1 AS cor0
----
128
160
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4823
SELECT + col2 - tab0.col1 * CAST( + 38 AS SIGNED ) col2 FROM tab0
----
-3235
-3376
-3685

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4823
SELECT + col2 - tab0.col1 * CAST ( + 38 AS INTEGER ) col2 FROM tab0
----
-3235
-3376
-3685

query I rowsort
SELECT ALL col1 + col0 - 13 * col2 FROM tab1
----
-1155
-667
-673

query I rowsort
SELECT - - col2 + ( - 94 ) FROM tab1 AS cor0
----
-37
-40
2

query I rowsort
SELECT col0 + + 3 * cor0.col1 AS col0 FROM tab0 cor0
----
282
326
362

onlyif mysql # use DIV operator for integer division
query I rowsort label-4827
SELECT ALL - - col1 DIV + ( + col1 ) + + col2 AS col2 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-4827
SELECT ALL - - col1 / + ( + col1 ) + + col2 AS col2 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT - col0 * 79 * 59 + col1 * cor0.col1 AS col1 FROM tab0 cor0
----
-104468
-153726
-406548

onlyif mysql # use DIV operator for integer division
query I rowsort label-4829
SELECT col1 DIV ( cor0.col1 ) + + col1 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-4829
SELECT col1 / ( cor0.col1 ) + + col1 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT ALL - + col2 * - col1 * col0 FROM tab0 AS cor0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-4831
SELECT + col0 DIV - 77 FROM tab2 cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4831
SELECT + col0 / - 77 FROM tab2 cor0
----
-1
-1
0

query I rowsort
SELECT ALL - cor0.col0 * cor0.col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4833
SELECT col1 + - col2 DIV - ( col1 ) AS col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-4833
SELECT col1 + - col2 / - ( col1 ) AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT cor0.col1 * 12 AS col0 FROM tab1 cor0
----
120
156
312

onlyif mysql # use DIV operator for integer division
query I rowsort label-4835
SELECT + col2 DIV + col2 AS col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4835
SELECT + col2 / + col2 AS col0 FROM tab0
----
1
1
1

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( col0 ) IN ( - col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query III rowsort
SELECT ALL * FROM tab0 WHERE col0 <= NULL
----

query I rowsort
SELECT tab1.col0 * - col1 + - col2 + col2 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT col0 * + tab0.col1 * col2 - col1 FROM tab0
----
3298
664027
68026

query III rowsort
SELECT * FROM tab0 WHERE NOT ( NULL ) NOT BETWEEN col0 AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4841
SELECT + col1 DIV col1 + + col1 * + col0 AS col0 FROM tab1
----
1041
641
79

skipif mysql # not compatible
query I rowsort label-4841
SELECT + col1 / col1 + + col1 * + col0 AS col0 FROM tab1
----
1041
641
79

query I rowsort
SELECT ALL - col0 FROM tab2 WHERE NOT ( col0 / + col1 ) = NULL
----

query I rowsort
SELECT DISTINCT col0 * - col2 * col0 + col1 FROM tab2
----
-1292
-158125
-237141

query I rowsort
SELECT col2 FROM tab2 WHERE NOT NULL < + col2
----

query I rowsort
SELECT ALL tab2.col2 * col1 + col1 * col2 FROM tab2
----
1292
1674
3068

query I rowsort
SELECT - col2 * col2 + 0 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-4847
SELECT - col1 DIV + cor0.col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4847
SELECT - col1 / + cor0.col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT col2 * - col1 * col2 AS col1 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT - 39 * + cor0.col2 - 87 AS col0 FROM tab0 AS cor0
----
-126
-1374
-3285

query I rowsort
SELECT col1 * - col1 + 1 FROM tab2 AS cor0
----
-288
-3480
-960

query I rowsort
SELECT - tab0.col2 + + tab0.col2 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT + col0 * tab2.col2 + col0 * col1 FROM tab2
----
406
4345
6630

query I rowsort
SELECT DISTINCT - col0 * col1 - + col2 * col1 / tab2.col1 FROM tab2 WHERE ( NULL ) <= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - 2 col0 FROM tab2 AS cor0
----
-28
-29
-40

query I rowsort
SELECT ALL col0 + col2 + + ( + cor0.col2 ) FROM tab1 AS cor0
----
111
178
272

query I rowsort
SELECT ALL + cor0.col2 + 17 AS col0 FROM tab2 AS cor0
----
43
44
55

query I rowsort
SELECT DISTINCT col2 * + 66 - col2 AS col2 FROM tab2 cor0
----
1690
1755
2470

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4858
SELECT DISTINCT - col2 + - CAST( NULL AS SIGNED ) / col0 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4858
SELECT DISTINCT - col2 + - CAST ( NULL AS INTEGER ) / col0 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT col2 + + 4 FROM tab0 AS cor0
----
37
5
86

query I rowsort
SELECT DISTINCT - col2 + 54 * col1 * col0 FROM tab2 AS cor0
----
11691
248482
72484

query I rowsort
SELECT DISTINCT + - col2 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT + + cor0.col2 + ( - 83 ) * - col2 * col0 + + cor0.col2 * col2 FROM tab2 AS cor0
----
16443
169026
250648

query I rowsort
SELECT DISTINCT col2 + 39 * 24 + cor0.col0 FROM tab0 AS cor0
----
1107
972
993

query I rowsort
SELECT ALL - col2 - + col2 FROM tab1
----
-108
-114
-192

onlyif mysql # use DIV operator for integer division
query I rowsort label-4865
SELECT DISTINCT tab0.col2 - - col1 DIV - 15 AS col1 FROM tab0
----
-5
28
76

skipif mysql # not compatible
query I rowsort label-4865
SELECT DISTINCT tab0.col2 - - col1 / - 15 AS col1 FROM tab0
----
-5
28
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-4866
SELECT DISTINCT col0 DIV col1 - tab2.col1 DIV - col0 AS col1 FROM tab2
----
1
4

skipif mysql # not compatible
query I rowsort label-4866
SELECT DISTINCT col0 / col1 - tab2.col1 / - col0 AS col1 FROM tab2
----
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 8 col1 FROM tab2
----
8
8
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + col0 col2 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT ALL - - col1 + col2 + col0 FROM tab0 cor0
----
133
143
262

onlyif mysql # use DIV operator for integer division
query I rowsort label-4870
SELECT DISTINCT - col1 DIV col1 - col0 DIV col1 FROM tab1 AS cor0
----
-1
-7

skipif mysql # not compatible
query I rowsort label-4870
SELECT DISTINCT - col1 / col1 - col0 / col1 FROM tab1 AS cor0
----
-1
-7

query I rowsort
SELECT ALL - col2 * + ( + col1 ) + col2 * - cor0.col0 * + col1 AS col1 FROM tab2 AS cor0
----
-121186
-51680
-6696

query I rowsort
SELECT DISTINCT - - col2 * + 48 * + col1 - col2 FROM tab2 AS cor0
----
30970
40149
73606

query I rowsort
SELECT - col1 + - 52 FROM tab2 AS cor0
----
-111
-69
-83

query I rowsort
SELECT ALL tab0.col0 + + 23 AS col1 FROM tab0
----
112
47
58

query I rowsort
SELECT - cor1.col0 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT cor0.col0 + + cor0.col0 FROM tab1 cor0
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-4877
SELECT ALL col0 * tab1.col0 DIV col2 FROM tab1
----
0
66
71

skipif mysql # not compatible
query I rowsort label-4877
SELECT ALL col0 * tab1.col0 / col2 FROM tab1
----
0
66
71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 79 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

onlyif mysql # use DIV operator for integer division
query I rowsort label-4879
SELECT col1 DIV + 21 FROM tab2 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-4879
SELECT col1 / + 21 FROM tab2 AS cor0
----
0
1
2

query I rowsort
SELECT + 94 * col2 FROM tab0 AS cor0
----
3102
7708
94

query I rowsort
SELECT tab1.col0 - - 45 FROM tab1
----
109
125
48

query I rowsort
SELECT + 73 - col2 * col0 AS col1 FROM tab2 cor0
----
-116
-1955
-2929

query I rowsort
SELECT - cor0.col2 * - col1 + 34 * - 70 FROM tab1 AS cor0
----
-1132
-1810
-976

query I rowsort
SELECT + col1 * - col0 + col2 + - col2 * - col1 AS col2 FROM tab2
----
-3042
-659
647

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 39 + + col1 + 95 col0 FROM tab2
----
115
73
87

query I rowsort
SELECT 36 * - col2 + ( - col0 * - col2 ) FROM tab2
----
-783
1092
1634

query I rowsort
SELECT DISTINCT col2 * - col2 + - col0 AS col1 FROM tab0
----
-1113
-36
-6813

query I rowsort
SELECT + col2 + - col0 + 66 * - col2 AS col0 FROM tab1
----
-3513
-3769
-6320

query I rowsort
SELECT 24 * col0 * + tab1.col2 FROM tab1
----
184320
3888
87552

query I rowsort
SELECT DISTINCT + col2 * col0 * - ( col2 ) + col1 AS col0 FROM tab0
----
-26050
-598345
62

query I rowsort
SELECT + - col1 * + col0 * - cor0.col0 AS col1 FROM tab2 cor0
----
106097
1519
358956

query I rowsort
SELECT col1 + col1 * col2 FROM tab2 cor0
----
1593
663
868

query I rowsort
SELECT ALL + - 39 + col2 FROM tab0 AS cor0
----
-38
-6
43

query I rowsort
SELECT ALL - + 49 * col1 FROM tab0 cor0
----
-4214
-4459
-4753

query I rowsort
SELECT ALL - col2 * - col0 * - col2 + + col1 AS col1 FROM tab0 AS cor0
----
-26050
-598345
62

query I rowsort
SELECT ALL - 32 * col2 + col1 AS col0 FROM tab0 AS cor0
----
-2533
-970
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-4897
SELECT + 61 DIV col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4897
SELECT + 61 / col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL - 5 * - col2 + - col2 FROM tab1 AS cor0
----
216
228
384

query I rowsort
SELECT DISTINCT - col2 + - cor0.col0 * - col0 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT - - col2 * - col1 - col0 AS col2 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT - - col1 * col1 + col1 - col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT col0 * col0 + + col2 + + col1 AS col2 FROM tab1 AS cor0
----
4163
6509
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4903
SELECT - col1 DIV - col0 - - cor0.col2 * + col2 DIV col2 FROM tab0 AS cor0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-4903
SELECT - col1 / - col0 - - cor0.col2 * + col2 / col2 FROM tab0 AS cor0
----
3
36
83

query I rowsort
SELECT ALL + + col2 * col2 + col1 FROM tab1 cor0
----
2942
3259
9229

query I rowsort
SELECT DISTINCT cor0.col2 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-4906
SELECT + col1 + col2 + - col2 DIV col1 FROM tab2 AS cor0
----
53
58
85

skipif mysql # not compatible
query I rowsort label-4906
SELECT + col1 + col2 + - col2 / col1 FROM tab2 AS cor0
----
53
58
85

query I rowsort
SELECT DISTINCT col1 * 80 AS col1 FROM tab2 AS cor0
----
1360
2480
4720

query I rowsort
SELECT ALL cor0.col2 * - col1 + - cor0.col0 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT DISTINCT + - 48 + col1 FROM tab0 AS cor0
----
38
43
49

query I rowsort
SELECT DISTINCT - + col0 * - ( + col0 ) + - col1 * cor0.col2 * col2 AS col2 FROM tab2 AS cor0
----
-18307
-22550
-33800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4911
SELECT DISTINCT + CAST( col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-4911
SELECT DISTINCT + CAST ( col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL 74 + 11 FROM tab0 AS cor0
----
85
85
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4913
SELECT DISTINCT - col2 + - CAST( + col1 AS SIGNED ) * + col2 col2 FROM tab1
----
-1344
-1458
-627

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4913
SELECT DISTINCT - col2 + - CAST ( + col1 AS INTEGER ) * + col2 col2 FROM tab1
----
-1344
-1458
-627

query I rowsort
SELECT ALL ( - 4 ) * + col1 AS col1 FROM tab1 cor0
----
-104
-40
-52

query I rowsort
SELECT DISTINCT - 35 + col2 FROM tab2 AS cor0
----
-8
-9
3

query I rowsort
SELECT ( 67 ) FROM tab0 AS cor0
----
67
67
67

query I rowsort
SELECT DISTINCT - - ( 65 ) FROM tab0 AS cor0
----
65

query I rowsort
SELECT - 93 AS col0 FROM tab2 cor0
----
-93
-93
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col1 col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL ( ( tab0.col1 ) + - col0 ) * - col2 AS col0 FROM tab0
----
-164
-2046
-62

query I rowsort
SELECT ALL - ( + col0 + tab0.col1 ) AS col2 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT + 79 + col2 AS col1 FROM tab2 AS cor0
----
105
106
117

query I rowsort
SELECT DISTINCT - col2 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL col0 + col0 AS col2 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT + + 70 AS col2 FROM tab2 cor0
----
70
70
70

query I rowsort
SELECT DISTINCT - ( - col2 ) * col1 + - col0 * col1 FROM tab0 AS cor0
----
-3298
-637
774

onlyif mysql # use DIV operator for integer division
query I rowsort label-4927
SELECT DISTINCT + + 59 + col2 DIV col0 AS col2 FROM tab0 AS cor0
----
59
60

skipif mysql # not compatible
query I rowsort label-4927
SELECT DISTINCT + + 59 + col2 / col0 AS col2 FROM tab0 AS cor0
----
59
60

query I rowsort
SELECT ALL + 96 AS col1 FROM tab0
----
96
96
96

query I rowsort
SELECT col0 + ( col0 ) * - col0 * + col2 AS col2 FROM tab2
----
-1316
-158106
-237079

query I rowsort
SELECT DISTINCT - 36 + + col0 AS col0 FROM tab2 AS cor0
----
-29
42
43

query I rowsort
SELECT DISTINCT col0 * + col1 + col2 * - 45 + - col2 FROM tab1 AS cor0
----
-1982
-2406
-3376

query I rowsort
SELECT ALL ( tab0.col1 ) AS col2 FROM tab0
----
86
91
97

query I rowsort
SELECT - + 1 * + col1 + - col2 * ( + col1 ) FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT DISTINCT + cor0.col2 AS col2 FROM tab1, tab2 cor0
----
26
27
38

query I rowsort
SELECT ( - col2 ) * - col0 + 55 AS col0 FROM tab0 AS cor0
----
7353
847
90

query I rowsort
SELECT - + 21 FROM tab2 cor0
----
-21
-21
-21

query I rowsort
SELECT - 81 * col1 + 26 * col0 + col2 * ( col2 ) FROM tab0 AS cor0
----
-5253
-6946
1667

query I rowsort
SELECT + 19 AS col1 FROM tab0 AS cor0
----
19
19
19

onlyif mysql # use DIV operator for integer division
query I rowsort label-4939
SELECT - col2 DIV col0 AS col2 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4939
SELECT - col2 / col0 AS col2 FROM tab0 cor0
----
-1
0
0

query I rowsort
SELECT - ( + tab1.col0 ) FROM tab1
----
-3
-64
-80

query I rowsort
SELECT col1 + ( col2 * col0 + 32 ) AS col0 FROM tab2 AS cor0
----
2119
252
3051

query I rowsort
SELECT - col1 * 47 - - col0 AS col0 FROM tab1 AS cor0
----
-1219
-406
-531

query I rowsort
SELECT col1 + - col2 AS col0 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT + - col1 * 74 AS col1 FROM tab1 cor0
----
-1924
-740
-962

query I rowsort
SELECT - col1 + 88 + col2 FROM tab1 AS cor0
----
116
135
171

query I rowsort
SELECT DISTINCT - col0 * + 0 + - col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT - col2 + col2 * col1 AS col1 FROM tab1 AS cor0
----
1152
1350
513

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 + 85 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
85

query I rowsort
SELECT ALL tab1.col0 - + col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT - 71 * cor0.col1 + 58 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 269843d527de047fcb85c0de61c11218

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4952
SELECT ALL col1 * CAST( col2 AS SIGNED ) + - col2 * - col2 AS col1 FROM tab2
----
1566
2090
2210

skipif mysql # not compatible
query I rowsort label-4952
SELECT ALL col1 * CAST ( col2 AS INTEGER ) + - col2 * - col2 AS col1 FROM tab2
----
1566
2090
2210

query I rowsort
SELECT - cor0.col0 + - col0 * - 64 FROM tab1 AS cor0
----
189
4032
5040

query I rowsort
SELECT DISTINCT - col2 - col2 * col0 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT ALL col1 * - col0 + col1 + - col0 * col2 AS col0 FROM tab2 AS cor0
----
-375
-4328
-6571

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4956
SELECT ALL col1 + CAST( col0 AS SIGNED ) * - col0 FROM tab1 AS cor0
----
-4086
-6387
17

skipif mysql # not compatible
query I rowsort label-4956
SELECT ALL col1 + CAST ( col0 AS INTEGER ) * - col0 FROM tab1 AS cor0
----
-4086
-6387
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-4957
SELECT ALL + - col1 * CAST( col2 AS SIGNED ) DIV + col0 FROM tab1 cor0
----
-15
-468
-8

skipif mysql # not compatible
query I rowsort label-4957
SELECT ALL + - col1 * CAST ( col2 AS INTEGER ) / + col0 FROM tab1 cor0
----
-15
-468
-8

query I rowsort
SELECT + + col2 * col0 + + col0 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-4959
SELECT + col1 DIV col1 - col0 DIV col2 AS col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-4959
SELECT + col1 / col1 - col0 / col2 AS col2 FROM tab1 AS cor0
----
0
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4960
SELECT CAST( NULL AS SIGNED ) + + cor0.col2 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4960
SELECT CAST ( NULL AS INTEGER ) + + cor0.col2 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + tab1.col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4962
SELECT + CAST( + 77 AS SIGNED ) * col0 - + col2 AS col2 FROM tab1 AS cor0
----
177
4871
6064

skipif mysql # not compatible
query I rowsort label-4962
SELECT + CAST ( + 77 AS INTEGER ) * col0 - + col2 AS col2 FROM tab1 AS cor0
----
177
4871
6064

query I rowsort
SELECT DISTINCT col2 + 51 * cor0.col2 AS col0 FROM tab0 AS cor0
----
1716
4264
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4964
SELECT ALL - CAST( NULL AS SIGNED ) * - col0 + - col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4964
SELECT ALL - CAST ( NULL AS INTEGER ) * - col0 + - col2 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4965
SELECT DISTINCT + + CAST( NULL AS DECIMAL ) - col1 * - col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4965
SELECT DISTINCT + + CAST ( NULL AS REAL ) - col1 * - col1 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 97 col2 FROM tab0 AS cor0
----
-97
-97
-97

query I rowsort
SELECT ALL 53 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

onlyif mysql # use DIV operator for integer division
query I rowsort label-4968
SELECT + col2 DIV 72 AS col0 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4968
SELECT + col2 / 72 AS col0 FROM tab1
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 4 col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

query I rowsort
SELECT - col2 * ( + col1 + col2 ) FROM tab2
----
-1566
-2090
-2210

query I rowsort
SELECT col2 * + col1 * col2 AS col1 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT + 56 - 22 FROM tab1 AS cor0
----
34
34
34

query I rowsort
SELECT - - col0 * col2 + col0 AS col0 FROM tab2 cor0
----
196
2106
3081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 col1 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT 50 + + cor0.col1 AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c046523cc02bdd2c024ad88715748c1b

query I rowsort
SELECT 61 * col1 FROM tab2 AS cor0
----
1037
1891
3599

query I rowsort
SELECT DISTINCT + 77 * col0 FROM tab0 AS cor0
----
1848
2695
6853

query I rowsort
SELECT + 71 * col0 FROM tab0 AS cor0
----
1704
2485
6319

onlyif mysql # use DIV operator for integer division
query I rowsort label-4979
SELECT DISTINCT 89 DIV - col0 FROM tab2
----
-1
-12

skipif mysql # not compatible
query I rowsort label-4979
SELECT DISTINCT 89 / - col0 FROM tab2
----
-1
-12

query I rowsort
SELECT DISTINCT - - 49 * - col1 + ( col1 ) FROM tab1 AS cor0
----
-1248
-480
-624

query I rowsort
SELECT ALL ( col2 ) * + ( - col2 ) + cor0.col2 + cor0.col0 * cor0.col1 FROM tab2 AS cor0
----
-485
-63
3952

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * cor0.col1 col2 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4983
SELECT ALL - - col2 * - cor0.col1 + - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4983
SELECT ALL - - col2 * - cor0.col1 + - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + cor0.col1 * - col2 * - col2 + - col2 + col0 AS col2 FROM tab2 AS cor0
----
22579
24589
39936

query I rowsort
SELECT cor0.col0 * - col2 + + col0 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT ALL + col2 + col1 * col2 * - 65 FROM tab2 AS cor0
----
-41952
-54378
-99684

query I rowsort
SELECT ALL + ( + col0 ) AS col1 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT ALL + col0 + + col0 * col1 AS col2 FROM tab2 AS cor0
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4989
SELECT DISTINCT - col0 DIV - cor0.col0 + - col1 col1 FROM tab2 AS cor0
----
-16
-30
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4989
SELECT DISTINCT - col0 / - cor0.col0 + - col1 col1 FROM tab2 AS cor0
----
-16
-30
-58

query I rowsort
SELECT ALL 42 * col2 FROM tab1 cor0
----
2268
2394
4032

query I rowsort
SELECT ALL + + col1 * - col2 * ( col2 ) AS col0 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT 57 FROM tab0, tab0 cor0
----
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-4993
SELECT ALL + + col0 DIV + 30 AS col1 FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-4993
SELECT ALL + + col0 / + 30 AS col1 FROM tab0 AS cor0
----
0
1
2

query I rowsort
SELECT DISTINCT col2 - + tab2.col1 FROM tab2
----
-33
-4
21

query I rowsort
SELECT ALL + ( + col1 ) + col1 * col1 AS col0 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT + 43 + - col1 FROM tab0 cor0
----
-43
-48
-54

query I rowsort
SELECT ALL - 97 + + 91 FROM tab2 AS cor0
----
-6
-6
-6

query I rowsort
SELECT col1 * - 61 FROM tab0 AS cor0
----
-5246
-5551
-5917

query I rowsort
SELECT DISTINCT col1 * ( col2 ) FROM tab2
----
1534
646
837

query I rowsort
SELECT DISTINCT + + 92 * + cor0.col2 + + col2 FROM tab2 AS cor0
----
2418
2511
3534

query I rowsort
SELECT - 66 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to a408108d423d7784b7d610cb779e515a

query I rowsort
SELECT + 37 * + 22 FROM tab2 AS cor0
----
814
814
814

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5003
SELECT - cor0.col2 / CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5003
SELECT - cor0.col2 / CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ( col2 ) + + col2 FROM tab0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col2 * col1 col1 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT - - 38 * ( col0 ) * col2 AS col1 FROM tab1 AS cor0
----
138624
291840
6156

onlyif mysql # use DIV operator for integer division
query I rowsort label-5007
SELECT 75 DIV col0 AS col0 FROM tab2 AS cor0
----
0
0
10

skipif mysql # not compatible
query I rowsort label-5007
SELECT 75 / col0 AS col0 FROM tab2 AS cor0
----
0
0
10

query I rowsort
SELECT 26 + - 54 AS col2 FROM tab0
----
-28
-28
-28

query I rowsort
SELECT DISTINCT ( + col1 ) * col2 + col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT - ( + cor0.col2 ) AS col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + - ( col0 ) * + 85 FROM tab1 cor0
----
-255
-5440
-6800

query I rowsort
SELECT - - 61 * - cor0.col0 FROM tab2 AS cor0
----
-427
-4758
-4819

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5013
SELECT 64 * col0 * + CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
-40960
-4992
-66560

skipif mysql # not compatible
query I rowsort label-5013
SELECT 64 * col0 * + CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
-40960
-4992
-66560

query I rowsort
SELECT ( + 17 ) FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 14 col0 FROM tab1, tab0 AS cor0
----
-14

query I rowsort
SELECT - cor1.col2 FROM tab2, tab2 cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT ALL - col0 + col0 + 27 * col0 FROM tab2
----
189
2106
2133

query I rowsort
SELECT ALL col2 + + col1 * col0 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT DISTINCT - col0 + col1 * col0 FROM tab2
----
1264
210
4524

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col1 + col2 col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT DISTINCT col0 + ( - col1 ) * - col0 * - tab0.col1 AS col1 FROM tab0
----
-177480
-329280
-736920

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5022
SELECT - col1 * + CAST( NULL AS DECIMAL ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5022
SELECT - col1 * + CAST ( NULL AS REAL ) FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5023
SELECT DISTINCT col0 + - col2 DIV col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-5023
SELECT DISTINCT col0 + - col2 / col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + cor0.col2 + col2 * + 81 FROM tab2 AS cor0
----
2132
2214
3116

query I rowsort
SELECT ALL - + cor0.col1 - ( - 28 ) FROM tab0 AS cor0
----
-58
-63
-69

query I rowsort
SELECT - cor0.col2 * - 85 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 542cfc09926ca2de32e19f57770d6dc1

query I rowsort
SELECT - col0 * - ( - cor0.col0 ) + col1 FROM tab2 cor0
----
-18
-6025
-6224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + 13 + - col0 col1 FROM tab0 AS cor0
----
1094
1094
1226

query I rowsort
SELECT + col1 + col1 * cor0.col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT + + 26 * + 81 AS col0 FROM tab0 AS cor0
----
2106

query I rowsort
SELECT DISTINCT + + col0 + col0 * - col2 FROM tab0 AS cor0
----
-7209
-768
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 67 * col1 col2 FROM tab0 cor0
----
5762
6097
6499

query I rowsort
SELECT col1 * ( col1 ) * - cor0.col1 FROM tab1 AS cor0
----
-1000
-17576
-2197

query I rowsort
SELECT ALL + col2 * - 21 + + cor0.col0 FROM tab0 cor0
----
-1633
-669
14

query I rowsort
SELECT cor0.col2 + 84 FROM tab0 AS cor0
----
117
166
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 + - col2 col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT col1 + - 68 + + col2 FROM tab0
----
105
30
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-5038
SELECT col0 - - col2 DIV + col0 AS col2 FROM tab0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-5038
SELECT col0 - - col2 / + col0 AS col2 FROM tab0
----
25
35
89

query I rowsort
SELECT col0 + + 52 * - col0 FROM tab0
----
-1224
-1785
-4539

query I rowsort
SELECT col0 * - 25 AS col2 FROM tab1 AS cor0
----
-1600
-2000
-75

query I rowsort
SELECT ALL - col1 + col1 * col1 + - tab0.col0 AS col1 FROM tab0
----
7286
8101
9277

query I rowsort
SELECT 19 * col0 AS col0 FROM tab1
----
1216
1520
57

query I rowsort
SELECT DISTINCT cor0.col2 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
54
57
96

query I rowsort
SELECT - col2 * + cor0.col0 - + 37 AS col1 FROM tab2 AS cor0
----
-2065
-226
-3039

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 78 * col0 col2 FROM tab0 AS cor0
----
1872
2730
6942

query I rowsort
SELECT + - cor0.col0 * col0 - col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 cor0, tab2 AS cor1, tab1 cor2
----
972 values hashing to 9364ef7545b07c67767dceb70f02c643

query I rowsort
SELECT + col0 + + cor0.col1 AS col2 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT col2 * - tab2.col1 * - 92 FROM tab2
----
141128
59432
77004

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col1 * + col1 * + tab0.col1 + col2 * col0 col0 FROM tab0
----
636848
760869
912708

onlyif mysql # use DIV operator for integer division
query I rowsort label-5051
SELECT - col1 - 1 DIV 70 AS col1 FROM tab1 cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-5051
SELECT - col1 - 1 / 70 AS col1 FROM tab1 cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-5052
SELECT col0 + + 37 DIV + cor0.col0 FROM tab2 AS cor0
----
12
78
79

skipif mysql # not compatible
query I rowsort label-5052
SELECT col0 + + 37 / + cor0.col0 FROM tab2 AS cor0
----
12
78
79

query I rowsort
SELECT ALL - + 95 FROM tab1 AS cor0
----
-95
-95
-95

query I rowsort
SELECT + cor0.col0 * + 46 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to aad324d5c53ae7220bcc25e3528db1e0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 46 col2 FROM tab0
----
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5056
SELECT - CAST( 35 + col1 AS SIGNED ) FROM tab1
----
-45
-48
-61

skipif mysql # not compatible
query I rowsort label-5056
SELECT - CAST ( 35 + col1 AS INTEGER ) FROM tab1
----
-45
-48
-61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 59 col0 FROM tab1 AS cor0
----
59
59
59

query I rowsort
SELECT ALL - cor0.col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT DISTINCT ( - col2 ) AS col2 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT col1 * + col0 + col2 AS col0 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-5061
SELECT - + cor0.col0 + + col1 + + 55 * col1 DIV col2 FROM tab1 cor0
----
-45
-60
49

skipif mysql # not compatible
query I rowsort label-5061
SELECT - + cor0.col0 + + col1 + + 55 * col1 / col2 FROM tab1 cor0
----
-45
-60
49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5062
SELECT + CAST( NULL AS SIGNED ) + - tab0.col1 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5062
SELECT + CAST ( NULL AS INTEGER ) + - tab0.col1 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( + col1 + col1 ) AS col2 FROM tab0
----
-172
-182
-194

onlyif mysql # use DIV operator for integer division
query I rowsort label-5064
SELECT DISTINCT - col1 + col2 DIV col0 AS col2 FROM tab0 AS cor0
----
-85
-91
-97

skipif mysql # not compatible
query I rowsort label-5064
SELECT DISTINCT - col1 + col2 / col0 AS col2 FROM tab0 AS cor0
----
-85
-91
-97

query I rowsort
SELECT + 57 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

query I rowsort
SELECT DISTINCT - tab2.col1 * - col2 AS col1 FROM tab2
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 89 col2 FROM tab1
----
89
89
89

query I rowsort
SELECT ALL + - col0 * + ( - col0 ) FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT col0 * + col0 AS col2 FROM tab1 cor0
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5070
SELECT ALL + col0 * + CAST( col1 AS SIGNED ) + col2 + - col1 AS col2 FROM tab0 AS cor0
----
2011
3299
8090

skipif mysql # not compatible
query I rowsort label-5070
SELECT ALL + col0 * + CAST ( col1 AS INTEGER ) + col2 + - col1 AS col2 FROM tab0 AS cor0
----
2011
3299
8090

query I rowsort
SELECT DISTINCT + col1 * col2 * col1 + + col2 FROM tab1 AS cor0
----
16320
36558
5757

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5072
SELECT DISTINCT cor0.col0 - + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5072
SELECT DISTINCT cor0.col0 - + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col1 * - col2 col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT - col1 - - cor0.col2 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT - - ( ( - col0 ) ) AS col2 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL - col0 + 0 AS col0 FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-5077
SELECT DISTINCT - 83 DIV + col2 FROM tab1 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-5077
SELECT DISTINCT - 83 / + col2 FROM tab1 cor0
----
-1
0

query I rowsort
SELECT DISTINCT - ( 94 ) FROM tab0 cor0
----
-94

query I rowsort
SELECT + ( - cor0.col0 ) * + col0 * - 3 + col0 AS col1 FROM tab2 cor0
----
154
18330
18802

query I rowsort
SELECT ALL - - 5 + + col2 FROM tab0 AS cor0
----
38
6
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-5081
SELECT - + ( + col0 ) + cor0.col1 DIV 66 AS col0 FROM tab0 AS cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-5081
SELECT - + ( + col0 ) + cor0.col1 / 66 AS col0 FROM tab0 AS cor0
----
-23
-34
-88

query I rowsort
SELECT ALL tab2.col1 * ( 54 ) * + tab2.col2 AS col0 FROM tab2
----
34884
45198
82836

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 71 col2 FROM tab2 AS cor0
----
-71
-71
-71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5084
SELECT + + ( 63 ) + - col0 * + CAST( 4 * cor0.col2 AS SIGNED ) col0 FROM tab0 AS cor0
----
-29129
-3105
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5084
SELECT + + ( 63 ) + - col0 * + CAST ( 4 * cor0.col2 AS INTEGER ) col0 FROM tab0 AS cor0
----
-29129
-3105
-77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5085
SELECT - + CAST( + ( + col0 ) AS SIGNED ) * 60 FROM tab2 AS cor0
----
-420
-4680
-4740

skipif mysql # not compatible
query I rowsort label-5085
SELECT - + CAST ( + ( + col0 ) AS INTEGER ) * 60 FROM tab2 AS cor0
----
-420
-4680
-4740

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 43 col0 FROM tab0 AS cor0
----
-43
-43
-43

query I rowsort
SELECT DISTINCT - cor0.col0 FROM tab1, tab2, tab0 cor0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5088
SELECT - CAST( - tab0.col1 AS SIGNED ) AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

skipif mysql # not compatible
query I rowsort label-5088
SELECT - CAST ( - tab0.col1 AS INTEGER ) AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0, tab2 AS cor1, tab2, tab0 cor2
----
3645 values hashing to 5ec52b92c3c8d78cc0a61df3fc16f18b

query I rowsort
SELECT ALL + - cor0.col0 * 87 FROM tab1 AS cor0
----
-261
-5568
-6960

onlyif mysql # use DIV operator for integer division
query I rowsort label-5091
SELECT col0 DIV - 25 FROM tab1 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-5091
SELECT col0 / - 25 FROM tab1 AS cor0
----
-2
-3
0

query I rowsort
SELECT DISTINCT + + 99 * 82 - cor0.col0 AS col0 FROM tab1 AS cor0
----
8038
8054
8115

query I rowsort
SELECT DISTINCT - col1 + col2 * - col2 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT ALL + col2 * - col2 - col2 AS col2 FROM tab2 AS cor0
----
-1482
-702
-756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( ( - col1 ) ) col0 FROM tab1 cor0
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5096
SELECT + - CAST( NULL AS SIGNED ) * 69 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5096
SELECT + - CAST ( NULL AS INTEGER ) * 69 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - 11 - + col2 * col1 FROM tab0 cor0
----
-108
-2849
-7473

query I rowsort
SELECT DISTINCT - + ( 30 ) * col1 AS col1 FROM tab0 AS cor0
----
-2580
-2730
-2910

query I rowsort
SELECT ALL - cor0.col2 + col1 * - col0 FROM tab2 AS cor0
----
-1381
-244
-4628

skipif mysql # not compatible
query I rowsort
SELECT CAST ( 37 AS REAL ) FROM tab1 AS cor0
----
37
37
37

query I rowsort
SELECT DISTINCT + 4 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-22
-6
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * + col2 + col0 col1 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT + col0 * - ( col1 * + ( - col1 ) ) FROM tab1 cor0
----
13520
2028
6400

query I rowsort
SELECT - col1 + 28 FROM tab0
----
-58
-63
-69

query I rowsort
SELECT 19 * col2 * col0 AS col0 FROM tab2 AS cor0
----
3591
38532
57038

query I rowsort
SELECT DISTINCT + 68 + - col2 AS col2 FROM tab0 AS cor0
----
-14
35
67

query I rowsort
SELECT ALL + - 4 * - col1 AS col0 FROM tab1 cor0
----
104
40
52

query I rowsort
SELECT DISTINCT - 72 * ( col2 ) AS col2 FROM tab2 AS cor0
----
-1872
-1944
-2736

query I rowsort
SELECT + - 22 * cor0.col1 FROM tab1 AS cor0
----
-220
-286
-572

query I rowsort
SELECT DISTINCT - 71 * 65 AS col0 FROM tab2 AS cor0
----
-4615

onlyif mysql # use DIV operator for integer division
query I rowsort label-5111
SELECT + 17 + - col2 + + col0 DIV col0 FROM tab0 AS cor0
----
-15
-64
17

skipif mysql # not compatible
query I rowsort label-5111
SELECT + 17 + - col2 + + col0 / col0 FROM tab0 AS cor0
----
-15
-64
17

query I rowsort
SELECT col1 * - col0 * - ( - col2 * - col1 ) AS col2 FROM tab1 cor0
----
109512
1297920
364800

query I rowsort
SELECT 2 * + col2 AS col2 FROM tab0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-5114
SELECT + col0 + - col1 + col0 DIV - 38 FROM tab0
----
-4
-62
-62

skipif mysql # not compatible
query I rowsort label-5114
SELECT + col0 + - col1 + col0 / - 38 FROM tab0
----
-4
-62
-62

query I rowsort
SELECT + 63 * + col1 + ( + col1 ) FROM tab1 AS cor0
----
1664
640
832

query I rowsort
SELECT - + col1 + col0 * - 7 FROM tab1 cor0
----
-458
-47
-573

onlyif mysql # use DIV operator for integer division
query I rowsort label-5117
SELECT DISTINCT + - 84 + + col0 DIV + cor0.col2 + col2 AS col2 FROM tab1 AS cor0
----
-26
-30
12

skipif mysql # not compatible
query I rowsort label-5117
SELECT DISTINCT + - 84 + + col0 / + cor0.col2 + col2 AS col2 FROM tab1 AS cor0
----
-26
-30
12

onlyif mysql # use DIV operator for integer division
query I rowsort label-5118
SELECT - 81 + - cor0.col1 DIV - ( + col2 * col0 ) AS col2 FROM tab0 AS cor0
----
-79
-81
-81

skipif mysql # not compatible
query I rowsort label-5118
SELECT - 81 + - cor0.col1 / - ( + col2 * col0 ) AS col2 FROM tab0 AS cor0
----
-79
-81
-81

query I rowsort
SELECT ALL - col0 + col2 * col1 AS col1 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) * col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + + col1 * + cor0.col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + col1 col0 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5123
SELECT ALL 75 DIV cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5123
SELECT ALL 75 / cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 32 * col1 AS col0 FROM tab1 AS cor0
----
320
416
832

onlyif mysql # use DIV operator for integer division
query I rowsort label-5125
SELECT DISTINCT + cor0.col0 DIV col1 + 15 col0 FROM tab0 cor0
----
15

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5125
SELECT DISTINCT + cor0.col0 / col1 + 15 col0 FROM tab0 cor0
----
15

query I rowsort
SELECT DISTINCT 33 AS col0 FROM tab0, tab0 cor0, tab1 AS cor1, tab2, tab1 AS cor2
----
33

query I rowsort
SELECT DISTINCT + col2 * ( col0 ) AS col1 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT - col0 * col2 * + col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0, tab0 AS cor1, tab1, tab2 cor2
----
3645 values hashing to 81a27955147133c47c9e8e63dacc5c37

query I rowsort
SELECT ALL tab1.col0 * col2 * col2 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT DISTINCT - col0 + - ( - col2 ) FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL + - col2 * ( - ( col1 ) ) AS col0 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5133
SELECT DISTINCT + col1 + - 1 DIV 11 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-5133
SELECT DISTINCT + col1 + - 1 / 11 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + - col1 * - ( + col2 ) + - col0 FROM tab1 cor0
----
1168
1401
506

query I rowsort
SELECT DISTINCT cor0.col0 * + col1 + col1 FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-5136
SELECT DISTINCT + col0 + - col2 DIV col1 AS col2 FROM tab1 AS cor0
----
1
59
73

skipif mysql # not compatible
query I rowsort label-5136
SELECT DISTINCT + col0 + - col2 / col1 AS col2 FROM tab1 AS cor0
----
1
59
73

query I rowsort
SELECT DISTINCT + col1 * col2 + ( - col2 + + col2 ) * 7 AS col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT col1 + + 22 * + col2 AS col2 FROM tab2 AS cor0
----
625
631
853

query I rowsort
SELECT + col2 * - ( 53 ) FROM tab0
----
-1749
-4346
-53

onlyif mysql # use DIV operator for integer division
query I rowsort label-5140
SELECT DISTINCT + - col0 DIV - col2 + - 20 - cor0.col1 AS col0 FROM tab0 cor0
----
-106
-110
-82

skipif mysql # not compatible
query I rowsort label-5140
SELECT DISTINCT + - col0 / - col2 + - 20 - cor0.col1 AS col0 FROM tab0 cor0
----
-106
-110
-82

query I rowsort
SELECT + + cor0.col2 + + col2 AS col0 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT DISTINCT tab1.col0 - col0 AS col1 FROM tab1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col0 * col1 col2 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT + 84 * col2 * - col0 AS col2 FROM tab2 AS cor0
----
-15876
-170352
-252168

query I rowsort
SELECT 41 AS col0 FROM tab1, tab0 AS cor0, tab0, tab2 AS cor1
----
81 values hashing to 0733f496a5445ffeac9d19797afe4831

query I rowsort
SELECT DISTINCT + - 26 + - col1 * + col2 FROM tab2 AS cor0
----
-1560
-672
-863

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 21 + tab0.col2 col2 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to f550e60836debdddf8caf6203d5337f9

query I rowsort
SELECT DISTINCT - ( - tab1.col0 ) * - col0 + col0 AS col0 FROM tab1
----
-4032
-6
-6320

query I rowsort
SELECT DISTINCT - - col2 * + col0 + col1 AS col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT - col0 + col0 * - col0 AS col2 FROM tab2 AS cor0
----
-56
-6162
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-5151
SELECT DISTINCT - col2 DIV col0 - col0 * 36 AS col2 FROM tab0 cor0
----
-1260
-3204
-865

skipif mysql # not compatible
query I rowsort label-5151
SELECT DISTINCT - col2 / col0 - col0 * 36 AS col2 FROM tab0 cor0
----
-1260
-3204
-865

query I rowsort
SELECT 88 AS col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

query I rowsort
SELECT ALL - - col0 * cor0.col1 * 67 FROM tab0 AS cor0
----
138288
227465
542633

query I rowsort
SELECT ALL + - cor0.col2 - - col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT 51 * col2 - cor0.col1 AS col2 FROM tab2 AS cor0
----
1267
1346
1921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + ( - ( + col2 ) ) col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT - - col2 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + cor0.col0 FROM tab2, tab2 cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT + 2 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT ALL + 60 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

query I rowsort
SELECT ALL ( - tab0.col1 ) AS col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT + col1 * - 19 AS col2 FROM tab0
----
-1634
-1729
-1843

query I rowsort
SELECT + ( 96 ) * + cor0.col1 FROM tab0 AS cor0
----
8256
8736
9312

query I rowsort
SELECT - ( - 77 ) FROM tab1 AS cor0
----
77
77
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5165
SELECT ALL col1 * col0 * - CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5165
SELECT ALL col1 * col0 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 32 * - col0 FROM tab2
----
-224
-2496
-2528

onlyif mysql # use DIV operator for integer division
query I rowsort label-5167
SELECT 45 + - col1 DIV + 46 FROM tab2
----
44
45
45

skipif mysql # not compatible
query I rowsort label-5167
SELECT 45 + - col1 / + 46 FROM tab2
----
44
45
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-5168
SELECT - col2 DIV + col1 + col0 col2 FROM tab1
----
1
59
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5168
SELECT - col2 / + col1 + col0 col2 FROM tab1
----
1
59
73

query I rowsort
SELECT ALL + ( - tab1.col1 ) * ( - tab1.col2 ) AS col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + 43 + col2 AS col1 FROM tab1 AS cor0
----
100
139
97

query I rowsort
SELECT ALL - cor0.col0 * col2 + 44 AS col0 FROM tab1 AS cor0
----
-118
-3604
-7636

query I rowsort
SELECT ALL + cor0.col0 + - col0 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 99 * col2 FROM tab2
----
-2574
-2673
-3762

onlyif mysql # use DIV operator for integer division
query I rowsort label-5174
SELECT col0 + col2 DIV - ( col1 ) AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-5174
SELECT col0 + col2 / - ( col1 ) AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + cor0.col2 * 13 + cor0.col0 AS col2 FROM tab0 AS cor0
----
1155
453
48

query I rowsort
SELECT + col0 * 47 FROM tab2 AS cor0
----
329
3666
3713

query I rowsort
SELECT - cor0.col1 + 66 * 44 AS col0 FROM tab1 cor0
----
2878
2891
2894

onlyif mysql # use DIV operator for integer division
query I rowsort label-5178
SELECT col1 DIV ( col0 ) FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-5178
SELECT col1 / ( col0 ) FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT + col0 * - 29 AS col2 FROM tab2 AS cor0
----
-203
-2262
-2291

query I rowsort
SELECT ALL col0 + col0 * - col0 FROM tab2
----
-42
-6006
-6162

query I rowsort
SELECT col2 + + col2 * col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT - col2 * + col1 * - col2 + + col1 * col2 FROM tab1
----
121056
33060
77220

query I rowsort
SELECT DISTINCT col1 + + col0 * tab2.col0 AS col1 FROM tab2
----
6143
6258
80

query I rowsort
SELECT DISTINCT - + col0 * ( + cor0.col1 ) + - col1 * - 95 FROM tab2 AS cor0
----
1003
272
2728

query I rowsort
SELECT + 63 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query I rowsort
SELECT DISTINCT - cor0.col0 * 17 AS col0 FROM tab0 AS cor0
----
-1513
-408
-595

query I rowsort
SELECT ALL - col2 + ( col1 ) * 54 AS col2 FROM tab2 AS cor0
----
1647
3160
880

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5188
SELECT ALL CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-5188
SELECT ALL CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5189
SELECT + - ( col2 ) + col1 * + CAST( + col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
2805
7380
96

skipif mysql # not compatible
query I rowsort label-5189
SELECT + - ( col2 ) + col1 * + CAST ( + col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT - + cor0.col0 * + 10 * + col0 AS col2 FROM tab1 AS cor0
----
-40960
-64000
-90

query I rowsort
SELECT DISTINCT - 43 FROM tab1, tab0 AS cor0
----
-43

query I rowsort
SELECT DISTINCT + 33 FROM tab2, tab2 AS cor0
----
33

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5193
SELECT ALL - col0 * CAST( NULL AS SIGNED ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5193
SELECT ALL - col0 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col1 col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT col1 + col0 * col0 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT - 85 * col0 + - 13 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-192
-5863
-6494

query I rowsort
SELECT + - 1 + - col2 AS col2 FROM tab2 AS cor0
----
-27
-28
-39

query I rowsort
SELECT DISTINCT 61 * 51 + col0 * col0 FROM tab1
----
3120
7207
9511

query I rowsort
SELECT ALL - ( 49 ) AS col0 FROM tab1
----
-49
-49
-49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5200
SELECT + CAST( NULL AS SIGNED ) + - 97 + tab2.col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5200
SELECT + CAST ( NULL AS INTEGER ) + - 97 + tab2.col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + - 76 - col2 * 15 AS col1 FROM tab0 AS cor0
----
-1306
-571
-91

query I rowsort
SELECT DISTINCT - col0 * + col1 * - ( + 32 + col2 ) FROM tab2
----
12803
266916
94010

query I rowsort
SELECT DISTINCT - col2 * 21 FROM tab0 cor0
----
-1722
-21
-693

query I rowsort
SELECT ALL - col0 + - col0 * + col0 AS col1 FROM tab0
----
-1260
-600
-8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5205
SELECT DISTINCT CAST( NULL AS SIGNED ) + + ( + tab0.col0 ) * ( - col1 ) * - col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5205
SELECT DISTINCT CAST ( NULL AS INTEGER ) + + ( + tab0.col0 ) * ( - col1 ) * - col0 FROM tab0
----
NULL

query I rowsort
SELECT col1 * col2 - col0 * col2 FROM tab1
----
-3078
-6432
1242

query I rowsort
SELECT DISTINCT + tab0.col1 * - col1 + - col2 AS col0 FROM tab0
----
-7429
-8363
-9410

query I rowsort
SELECT - 2 * - ( + col1 ) - 19 FROM tab2
----
15
43
99

query I rowsort
SELECT 8 * + col2 FROM tab1 AS cor0
----
432
456
768

query I rowsort
SELECT cor0.col2 + col0 * - 48 FROM tab2 AS cor0
----
-309
-3718
-3754

onlyif mysql # use DIV operator for integer division
query I rowsort label-5211
SELECT + col1 DIV + col1 + cor0.col1 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-5211
SELECT + col1 / + col1 + cor0.col1 FROM tab2 AS cor0
----
18
32
60

query I rowsort
SELECT ALL tab1.col1 * + 64 FROM tab1
----
1664
640
832

query I rowsort
SELECT ( ( + col2 ) ) FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT + tab1.col1 + cor0.col0 * + 13 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 90f4328b84866142ed2fe7c72543edb2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + tab0.col2 * + col1 col2 FROM tab0
----
2871
7544
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + col0 * - tab0.col0 + col2 col2 FROM tab0
----
-1189
-519
-7750

query I rowsort
SELECT - cor0.col0 * 94 FROM tab2, tab1 AS cor0
----
9 values hashing to b307cea94f8b4b3db747ff167e582c6c

query I rowsort
SELECT ALL ( col2 ) + - col1 * ( + 24 * col1 ) FROM tab1
----
-16170
-2343
-3960

query I rowsort
SELECT ALL - - col0 * - col2 + - col2 + - col2 FROM tab0 cor0
----
-37
-7462
-858

query I rowsort
SELECT ALL + - 11 + - col0 FROM tab1 AS cor0
----
-14
-75
-91

query I rowsort
SELECT DISTINCT + ( - col0 ) * + 44 - + cor0.col2 FROM tab2 AS cor0
----
-335
-3458
-3514

query I rowsort
SELECT ALL + col2 * col1 + ( col1 ) FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-5223
SELECT col0 * - col0 + ( col0 ) DIV + col0 FROM tab0
----
-1224
-575
-7920

skipif mysql # not compatible
query I rowsort label-5223
SELECT col0 * - col0 + ( col0 ) / + col0 FROM tab0
----
-1224
-575
-7920

query I rowsort
SELECT ALL + - 12 FROM tab2 AS cor0
----
-12
-12
-12

query I rowsort
SELECT DISTINCT - + 48 - col0 FROM tab2 AS cor0
----
-126
-127
-55

query I rowsort
SELECT + ( col2 ) + 74 FROM tab2 AS cor0
----
100
101
112

query I rowsort
SELECT ALL tab2.col1 - + 41 FROM tab2
----
-10
-24
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5228
SELECT ALL - col1 + - CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5228
SELECT ALL - col1 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 * col1 - tab0.col2 FROM tab0
----
7363
8199
9408

query I rowsort
SELECT - + col2 * - col0 + 45 FROM tab0 AS cor0
----
7343
80
837

query I rowsort
SELECT - col1 * + 22 * + col1 + + col1 * + col0 * + 8 FROM tab1 AS cor0
----
-14248
2920
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5232
SELECT DISTINCT col1 + cor0.col2 + - 74 DIV + col1 FROM tab1 AS cor0
----
104
60
78

skipif mysql # not compatible
query I rowsort label-5232
SELECT DISTINCT col1 + cor0.col2 + - 74 / + col1 FROM tab1 AS cor0
----
104
60
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5233
SELECT + col2 DIV - 86 + + col2 - + cor0.col2 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
1122
2
6806

skipif mysql # not compatible
query I rowsort label-5233
SELECT + col2 / - 86 + + col2 - + cor0.col2 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT - col1 + 92 + + ( + col0 ) FROM tab1 cor0
----
146
159
69

query I rowsort
SELECT ( + 57 ) * + col2 AS col1 FROM tab2 AS cor0
----
1482
1539
2166

query I rowsort
SELECT ALL + + 7 * + col2 * col1 AS col2 FROM tab1 AS cor0
----
3990
8736
9828

query I rowsort
SELECT - 76 + + col2 * col0 FROM tab1 AS cor0
----
3572
7604
86

query I rowsort
SELECT DISTINCT - 99 + + 84 AS col2 FROM tab0 AS cor0
----
-15

query I rowsort
SELECT ALL - - col2 + - col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - - col2 * - ( - col1 * - cor0.col1 ) + + ( - col2 ) * 58 + 15 AS col0 FROM tab2 AS cor0
----
-13171
-27498
-91999

query I rowsort
SELECT - col0 + - ( col0 ) AS col0 FROM tab1
----
-128
-160
-6

query I rowsort
SELECT - - ( - 57 ) - - col2 FROM tab1 AS cor0
----
-3
0
39

query I rowsort
SELECT cor0.col2 * 75 AS col2 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 5bf2b1779a144dbf1398dbcf3862e627

query I rowsort
SELECT ALL + - ( - col1 ) * col2 * - 50 AS col0 FROM tab0 AS cor0
----
-141900
-373100
-4850

query I rowsort
SELECT + col2 + 91 AS col0 FROM tab1 AS cor0
----
145
148
187

onlyif mysql # use DIV operator for integer division
query I rowsort label-5246
SELECT DISTINCT - + 26 DIV - col1 AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5246
SELECT DISTINCT - + 26 / - col1 AS col0 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 23 * - col1 + + col2 * col2 col2 FROM tab0 AS cor0
----
2232
3067
8817

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5248
SELECT + CAST( NULL AS DECIMAL ) * - col1 + col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5248
SELECT + CAST ( NULL AS REAL ) * - col1 + col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( + 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 + + 36 + + cor0.col0 col1 FROM tab0 AS cor0
----
125
60
71

query I rowsort
SELECT + - cor0.col1 + ( col1 ) FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT - 20 + + col0 * col1 FROM tab0 AS cor0
----
2044
3375
8079

query I rowsort
SELECT ALL + 33 * + col1 AS col2 FROM tab0 AS cor0
----
2838
3003
3201

onlyif mysql # use DIV operator for integer division
query I rowsort label-5254
SELECT ( - cor0.col1 ) DIV - col0 FROM tab2 cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-5254
SELECT ( - cor0.col1 ) / - col0 FROM tab2 cor0
----
0
0
4

query I rowsort
SELECT DISTINCT - + 2 + + 37 AS col0 FROM tab1 cor0
----
35

query I rowsort
SELECT ALL + ( 27 ) AS col0 FROM tab1 AS cor0
----
27
27
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-5257
SELECT + - 86 - - cor0.col2 DIV + col1 FROM tab0 AS cor0
----
-86
-86
-86

skipif mysql # not compatible
query I rowsort label-5257
SELECT + - 86 - - cor0.col2 / + col1 FROM tab0 AS cor0
----
-86
-86
-86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5258
SELECT + CAST( NULL AS DECIMAL ) + + cor0.col0 * + col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5258
SELECT + CAST ( NULL AS REAL ) + + cor0.col0 * + col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - 65 FROM tab2 cor0
----
-65
-65
-65

query I rowsort
SELECT DISTINCT - - ( 98 ) * col2 + - 25 FROM tab1 AS cor0
----
5267
5561
9383

query I rowsort
SELECT - ( col0 ) * 86 FROM tab2 AS cor0
----
-602
-6708
-6794

query I rowsort
SELECT - ( col1 ) + + col2 * col2 FROM tab2 cor0
----
1427
617
698

query I rowsort
SELECT + + 33 + + col2 AS col1 FROM tab1 AS cor0
----
129
87
90

query I rowsort
SELECT ALL tab0.col1 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ALL - + col1 * - col0 + - col1 + - col2 * 33 FROM tab0 cor0
----
3265
5302
889

query I rowsort
SELECT - col1 + - col0 * ( col2 ) AS col1 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT DISTINCT - col0 * cor0.col2 * - col0 FROM tab2 AS cor0
----
1323
158184
237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-5268
SELECT - ( col1 * 52 ) - col0 * tab0.col2 DIV - tab0.col0 AS col2 FROM tab0
----
-4439
-4650
-5043

skipif mysql # not compatible
query I rowsort label-5268
SELECT - ( col1 * 52 ) - col0 * tab0.col2 / - tab0.col0 AS col2 FROM tab0
----
-4439
-4650
-5043

query I rowsort
SELECT 19 + col0 FROM tab1
----
22
83
99

query I rowsort
SELECT - col0 * - 77 AS col2 FROM tab2
----
539
6006
6083

query I rowsort
SELECT DISTINCT + col2 - ( - col0 ) FROM tab1
----
121
176
57

query I rowsort
SELECT ALL col0 * col1 + ( col0 ) FROM tab0
----
2088
3430
8188

query I rowsort
SELECT ALL cor0.col2 * 40 + + 76 FROM tab1, tab2, tab1 cor0
----
27 values hashing to 7869f97c6e4dcc05bd2f7b46782c3ca5

onlyif mysql # use DIV operator for integer division
query I rowsort label-5274
SELECT col0 DIV ( 30 ) FROM tab2
----
0
2
2

skipif mysql # not compatible
query I rowsort label-5274
SELECT col0 / ( 30 ) FROM tab2
----
0
2
2

query I rowsort
SELECT ALL tab1.col2 + 18 AS col0 FROM tab1
----
114
72
75

query I rowsort
SELECT col0 + + col1 + col2 * col2 FROM tab0
----
1199
133
6904

query I rowsort
SELECT col2 + + ( + 80 ) AS col1 FROM tab2 cor0
----
106
107
118

query I rowsort
SELECT DISTINCT + col0 * + ( + col2 ) + - cor0.col1 + ( col1 ) AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - cor0.col1 + 58 FROM tab0 AS cor0
----
-28
-33
-39

onlyif mysql # use DIV operator for integer division
query I rowsort label-5280
SELECT DISTINCT - col0 + cor0.col0 DIV + 58 AS col1 FROM tab2 AS cor0
----
-7
-77
-78

skipif mysql # not compatible
query I rowsort label-5280
SELECT DISTINCT - col0 + cor0.col0 / + 58 AS col1 FROM tab2 AS cor0
----
-7
-77
-78

query I rowsort
SELECT - - col0 + + col1 * - col0 FROM tab1 AS cor0
----
-576
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * col0 * col2 col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT col1 * + ( 36 ) * col2 + + cor0.col1 * col2 AS col2 FROM tab1 AS cor0
----
21090
46176
51948

query I rowsort
SELECT + col0 * + col1 * 18 FROM tab2 AS cor0
----
24174
3906
82836

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 87 col0 FROM tab1 AS cor0
----
87

query I rowsort
SELECT DISTINCT 36 AS col1 FROM tab1, tab2 AS cor0
----
36

query I rowsort
SELECT DISTINCT 71 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab0 AS cor2
----
71

query I rowsort
SELECT DISTINCT - col2 + + 5 * + col2 AS col1 FROM tab2 AS cor0
----
104
108
152

query I rowsort
SELECT + 12 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0, tab1 AS cor2, tab2
----
13122 values hashing to f0ffd3c82753160c41277864f42b73c1

query I rowsort
SELECT - + 27 + col0 FROM tab2 AS cor0
----
-20
51
52

query I rowsort
SELECT ( - col2 * col1 ) + col1 + - tab0.col0 FROM tab0
----
-2776
-35
-7460

onlyif mysql # use DIV operator for integer division
query I rowsort label-5293
SELECT cor0.col2 DIV + 53 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

skipif mysql # not compatible
query I rowsort label-5293
SELECT cor0.col2 / + 53 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 56 + col2 * col0 col2 FROM tab0 AS cor0
----
7354
848
91

query I rowsort
SELECT - - cor1.col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT ALL - + col2 * - 33 AS col1 FROM tab0 AS cor0
----
1089
2706
33

query I rowsort
SELECT - col2 * tab0.col2 - col2 * 14 FROM tab0
----
-15
-1551
-7872

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5298
SELECT col2 + - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5298
SELECT col2 + - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5299
SELECT col0 / - CAST( NULL AS SIGNED ) + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5299
SELECT col0 / - CAST ( NULL AS INTEGER ) + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * - col1 + + col2 AS col2 FROM tab1
----
1344
1458
627

query I rowsort
SELECT - col0 + ( cor0.col0 ) * col2 FROM tab0 AS cor0
----
0
7209
768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + cor0.col0 * col2 col2 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-5303
SELECT DISTINCT + + col1 DIV - col1 AS col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5303
SELECT DISTINCT + + col1 / - col1 AS col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT DISTINCT - 27 FROM tab1, tab2 AS cor0
----
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-5305
SELECT DISTINCT + cor0.col1 DIV - tab2.col0 FROM tab2, tab2 cor0
----
-2
-4
-8
0

skipif mysql # not compatible
query I rowsort label-5305
SELECT DISTINCT + cor0.col1 / - tab2.col0 FROM tab2, tab2 cor0
----
-2
-4
-8
0

query I rowsort
SELECT ALL + 77 AS col0 FROM tab2
----
77
77
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5307
SELECT + + CAST( + 42 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
42
42
42

skipif mysql # not compatible
query I rowsort label-5307
SELECT + + CAST ( + 42 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
42
42
42

query I rowsort
SELECT 43 * - col0 * - 3 AS col1 FROM tab1 AS cor0
----
10320
387
8256

query I rowsort
SELECT - + 46 * col1 AS col0 FROM tab2 AS cor0
----
-1426
-2714
-782

query I rowsort
SELECT + col1 - + col0 * col2 AS col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT + cor0.col2 - cor0.col0 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5312
SELECT + 29 + - col1 + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5312
SELECT + 29 + - col1 + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5313
SELECT col2 + - col0 + + 90 * + col2 DIV + col2 col0 FROM tab0 AS cor0
----
56
83
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5313
SELECT col2 + - col0 + + 90 * + col2 / + col2 col0 FROM tab0 AS cor0
----
56
83
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-5314
SELECT - col0 DIV - 75 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5314
SELECT - col0 / - 75 FROM tab0
----
0
0
1

query I rowsort
SELECT - 9 * col0 FROM tab2
----
-63
-702
-711

query I rowsort
SELECT DISTINCT col1 * 27 FROM tab2
----
1593
459
837

query I rowsort
SELECT ALL col0 - col1 AS col2 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT - 44 + - col1 FROM tab1 AS cor0
----
-54
-57
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 59 col1 FROM tab1 AS cor0
----
59
59
59

query I rowsort
SELECT col1 * col0 + 17 AS col0 FROM tab2 AS cor0
----
1360
234
4619

query I rowsort
SELECT DISTINCT ( - col2 ) + + col2 AS col2 FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5322
SELECT DISTINCT + - 47 * 17 - col1 DIV - ( col0 + cor0.col2 ) AS col0 FROM tab0 AS cor0
----
-797
-798
-799

skipif mysql # not compatible
query I rowsort label-5322
SELECT DISTINCT + - 47 * 17 - col1 / - ( col0 + cor0.col2 ) AS col0 FROM tab0 AS cor0
----
-797
-798
-799

query I rowsort
SELECT + 73 - col0 FROM tab2 AS cor0
----
-5
-6
66

query I rowsort
SELECT DISTINCT + 41 - + col1 FROM tab1 AS cor0
----
15
28
31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5325
SELECT ALL + - col0 * cor0.col0 + col1 / CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5325
SELECT ALL + - col0 * cor0.col0 + col1 / CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5326
SELECT DISTINCT - + col1 + 86 DIV col0 AS col1 FROM tab1 AS cor0
----
-12
-9
2

skipif mysql # not compatible
query I rowsort label-5326
SELECT DISTINCT - + col1 + 86 / col0 AS col1 FROM tab1 AS cor0
----
-12
-9
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-5327
SELECT DISTINCT + + col1 DIV col1 AS col2 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-5327
SELECT DISTINCT + + col1 / col1 AS col2 FROM tab1 AS cor0
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5328
SELECT + - CAST( - ( col2 ) AS SIGNED ) - - col1 * 11 AS col0 FROM tab0 AS cor0
----
1068
1083
979

skipif mysql # not compatible
query I rowsort label-5328
SELECT + - CAST ( - ( col2 ) AS INTEGER ) - - col1 * 11 AS col0 FROM tab0 AS cor0
----
1068
1083
979

query I rowsort
SELECT - cor0.col2 * - ( - 64 ) FROM tab1, tab2 AS cor0
----
9 values hashing to 82ce522d279c092dedf37bdd561697d3

query I rowsort
SELECT - 2 * + tab2.col1 FROM tab2
----
-118
-34
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5331
SELECT CAST( col0 AS SIGNED ) * - tab1.col0 + ( col2 + col0 ) AS col1 FROM tab1
----
-3975
-6224
48

skipif mysql # not compatible
query I rowsort label-5331
SELECT CAST ( col0 AS INTEGER ) * - tab1.col0 + ( col2 + col0 ) AS col1 FROM tab1
----
-3975
-6224
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5332
SELECT - CAST( NULL AS DECIMAL ) * 94 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5332
SELECT - CAST ( NULL AS REAL ) * 94 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ( - 10 ) + col2 AS col2 FROM tab1
----
44
47
86

query I rowsort
SELECT DISTINCT + ( + col2 ) * col2 + col2 FROM tab2
----
1482
702
756

query I rowsort
SELECT col1 + 15 * - col2 * - 18 AS col2 FROM tab1
----
14606
15400
25933

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5336
SELECT + CAST( NULL AS SIGNED ) * col2 + tab2.col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5336
SELECT + CAST ( NULL AS INTEGER ) * col2 + tab2.col0 FROM tab2
----
NULL
NULL
NULL

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0, tab2 AS cor1, tab1 AS cor2
----
972 values hashing to 75a813ebd5ec5ec2e67a66d0593ff763

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5338
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + 25 + + col1 * tab0.col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5338
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + 25 + + col1 * tab0.col0 FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5339
SELECT ALL + col0 DIV - tab1.col0 + - col0 + col2 AS col0 FROM tab1
----
-8
15
50

skipif mysql # not compatible
query I rowsort label-5339
SELECT ALL + col0 / - tab1.col0 + - col0 + col2 AS col0 FROM tab1
----
-8
15
50

query I rowsort
SELECT ( - 15 + - col1 ) AS col0 FROM tab1
----
-25
-28
-41

query I rowsort
SELECT DISTINCT + + 19 FROM tab1, tab2, tab1 AS cor0
----
19

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5342
SELECT DISTINCT - cor0.col1 + CAST( - ( + col1 ) AS SIGNED ) * col0 AS col0 FROM tab1 cor0
----
-104
-1053
-650

skipif mysql # not compatible
query I rowsort label-5342
SELECT DISTINCT - cor0.col1 + CAST ( - ( + col1 ) AS INTEGER ) * col0 AS col0 FROM tab1 cor0
----
-104
-1053
-650

query I rowsort
SELECT tab1.col0 - - col2 * 24 FROM tab1
----
1299
1432
2384

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 - 72 col1 FROM tab0 AS cor0
----
-105
-154
-73

query I rowsort
SELECT ALL col2 + + col2 - + cor0.col0 AS col2 FROM tab1 AS cor0
----
105
112
50

query I rowsort
SELECT ALL + col2 + - 27 * col0 FROM tab1 AS cor0
----
-1671
-2064
-27

query I rowsort
SELECT + cor0.col2 * + ( col1 ) AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - col2 + - 40 * - 18 AS col0 FROM tab1 AS cor0
----
624
663
666

query I rowsort
SELECT col1 - + cor0.col0 * col0 FROM tab0 AS cor0
----
-1128
-490
-7830

onlyif mysql # use DIV operator for integer division
query I rowsort label-5350
SELECT ALL + + col2 DIV ( - 98 ) col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5350
SELECT ALL + + col2 / ( - 98 ) col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * + 97 + col1 col0 FROM tab1 AS cor0
----
1274
2548
980

query I rowsort
SELECT DISTINCT + col0 * cor0.col1 + col2 AS col0 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT ALL - + col1 + ( 99 ) * - col1 * col1 AS col0 FROM tab1 AS cor0
----
-16744
-66950
-9910

query I rowsort
SELECT - col0 + + col0 * + cor0.col0 FROM tab0 AS cor0
----
1190
552
7832

query I rowsort
SELECT DISTINCT + col2 * + 84 + + cor0.col2 FROM tab2 cor0
----
2210
2295
3230

query I rowsort
SELECT ALL col1 * - col0 * + col2 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT - 20 + tab2.col1 AS col2 FROM tab2, tab2 AS cor0
----
-3
11
39

query I rowsort
SELECT ALL 15 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

onlyif mysql # use DIV operator for integer division
query I rowsort label-5359
SELECT ALL - - col2 + + col1 DIV col1 AS col0 FROM tab2 cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-5359
SELECT ALL - - col2 + + col1 / col1 AS col0 FROM tab2 cor0
----
27
28
39

query I rowsort
SELECT - - 58 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
-1914
-4756
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-5361
SELECT + ( + 79 ) + col2 + - 77 DIV + col2 FROM tab0 cor0
----
110
161
3

skipif mysql # not compatible
query I rowsort label-5361
SELECT + ( + 79 ) + col2 + - 77 / + col2 FROM tab0 cor0
----
110
161
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5362
SELECT - CAST( NULL AS SIGNED ) * + ( + col0 ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5362
SELECT - CAST ( NULL AS INTEGER ) * + ( + col0 ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( col0 ) + col2 AS col1 FROM tab2 cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-5364
SELECT + + col1 + ( col2 ) DIV - cor0.col1 FROM tab1 AS cor0
----
24
5
6

skipif mysql # not compatible
query I rowsort label-5364
SELECT + + col1 + ( col2 ) / - cor0.col1 FROM tab1 AS cor0
----
24
5
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - 15 col2 FROM tab0 AS cor0
----
-101
-106
-112

query I rowsort
SELECT - col2 * - col2 - col2 * - 56 AS col0 FROM tab1 AS cor0
----
14592
5940
6441

query I rowsort
SELECT col1 + col2 * + col2 AS col2 FROM tab1 cor0
----
2942
3259
9229

query I rowsort
SELECT + + col0 * 0 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 66 - + col2 FROM tab0 AS cor0
----
-16
33
65

query I rowsort
SELECT DISTINCT - 21 + col0 * col0 FROM tab2 AS cor0
----
28
6063
6220

query I rowsort
SELECT ALL 76 * col2 AS col2 FROM tab2 AS cor0
----
1976
2052
2888

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 + cor0.col0 * + col1 * col2 col1 FROM tab0 cor0
----
3396
664200
68145

query I rowsort
SELECT + 70 * col1 + 32 + col2 FROM tab0 AS cor0
----
6085
6484
6823

query I rowsort
SELECT - 5 * col2 + col1 AS col2 FROM tab2 AS cor0
----
-104
-173
-71

query I rowsort
SELECT + col2 + - col0 + ( - col0 ) AS col1 FROM tab0 AS cor0
----
-15
-69
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5376
SELECT + - col0 + + col2 * col0 DIV col1 AS col1 FROM tab0 AS cor0
----
-15
-35
-9

skipif mysql # not compatible
query I rowsort label-5376
SELECT + - col0 + + col2 * col0 / col1 AS col1 FROM tab0 AS cor0
----
-15
-35
-9

query I rowsort
SELECT + 32 + - col2 * cor0.col2 FROM tab1 AS cor0
----
-2884
-3217
-9184

query I rowsort
SELECT cor0.col2 * + col2 + ( - col0 ) * + cor0.col1 * + ( + col2 + col2 ) AS col1 FROM tab0 AS cor0
----
-1321512
-135135
-6789

query I rowsort
SELECT + - col1 + + col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT + 29 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col0 * cor0.col2 col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT - ( 69 ) * + col2 FROM tab2
----
-1794
-1863
-2622

query I rowsort
SELECT + - col1 * - col0 * col1 + col1 AS col2 FROM tab1 AS cor0
----
13533
2054
6410

query I rowsort
SELECT + - ( + col2 ) * + col2 AS col0 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT cor0.col2 * col0 * col1 AS col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT - + col2 * cor0.col1 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT cor0.col0 - + col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL - - col1 * 50 + - ( col1 ) FROM tab2 AS cor0
----
1519
2891
833

query I rowsort
SELECT + col0 - - ( 45 ) FROM tab0 AS cor0
----
134
69
80

query I rowsort
SELECT col0 + col2 * - tab2.col0 AS col2 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT tab0.col2 * + ( col0 ) AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT col2 * 46 + col0 + col2 FROM tab0
----
1575
3943
82

query I rowsort
SELECT col0 - + 33 AS col1 FROM tab0 AS cor0
----
-9
2
56

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5394
SELECT + col0 * CAST( - col2 AS SIGNED ) AS col0 FROM tab1
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-5394
SELECT + col0 * CAST ( - col2 AS INTEGER ) AS col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL + - cor0.col2 * col1 + + col1 + cor0.col0 AS col1 FROM tab2 AS cor0
----
-1397
-550
-799

query I rowsort
SELECT ALL - - ( col0 ) * cor0.col0 - col0 * + 13 AS col1 FROM tab2 AS cor0
----
-42
5070
5214

query I rowsort
SELECT ALL 8 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

query I rowsort
SELECT ( tab1.col2 ) * + col1 * + col0 AS col2 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT DISTINCT + 47 - tab2.col1 AS col1 FROM tab2
----
-12
16
30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5400
SELECT - + CAST( col1 AS SIGNED ) + - col2 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-5400
SELECT - + CAST ( col1 AS INTEGER ) + - col2 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT - - col0 * col1 * cor0.col1 - + col0 AS col0 FROM tab0 AS cor0
----
177480
329280
736920

onlyif mysql # use DIV operator for integer division
query I rowsort label-5402
SELECT + ( + col0 ) DIV - col1 + - col0 * 16 FROM tab1 AS cor0
----
-1030
-1286
-48

skipif mysql # not compatible
query I rowsort label-5402
SELECT + ( + col0 ) / - col1 + - col0 * 16 FROM tab1 AS cor0
----
-1030
-1286
-48

query I rowsort
SELECT DISTINCT 55 + - 22 * col1 FROM tab1
----
-165
-231
-517

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 53 ) * col2 col0 FROM tab1
----
2862
3021
5088

query I rowsort
SELECT - 4 + col1 FROM tab0
----
82
87
93

query I rowsort
SELECT + ( - col1 ) * col1 + 78 FROM tab2
----
-211
-3403
-883

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5407
SELECT DISTINCT col0 + + 78 * col0 * + CAST( col0 AS SIGNED ) FROM tab1
----
319552
499280
705

skipif mysql # not compatible
query I rowsort label-5407
SELECT DISTINCT col0 + + 78 * col0 * + CAST ( col0 AS INTEGER ) FROM tab1
----
319552
499280
705

query I rowsort
SELECT ALL + 1 + - 5 * + col1 AS col1 FROM tab1
----
-129
-49
-64

query I rowsort
SELECT 11 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 69116737f3f57e2e3273f6dbb04d036c

query I rowsort
SELECT DISTINCT col1 + col1 * col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT + ( cor1.col1 ) FROM tab1, tab2 AS cor0, tab2 AS cor1
----
17
31
59

query I rowsort
SELECT 60 + col2 AS col2 FROM tab2
----
86
87
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5413
SELECT col0 + CAST( NULL AS SIGNED ) * - col0 col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5413
SELECT col0 + CAST ( NULL AS INTEGER ) * - col0 col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + ( + col2 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 + - col1 * 30 FROM tab1 cor0
----
-357
-486
-834

query I rowsort
SELECT col1 * - 21 AS col0 FROM tab1 cor0
----
-210
-273
-546

query I rowsort
SELECT DISTINCT - 46 FROM tab0, tab1 AS cor0
----
-46

query I rowsort
SELECT DISTINCT 30 + + col0 AS col1 FROM tab2 AS cor0
----
108
109
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-5419
SELECT + col2 * cor0.col0 DIV 57 AS col0 FROM tab1 AS cor0
----
134
2
64

skipif mysql # not compatible
query I rowsort label-5419
SELECT + col2 * cor0.col0 / 57 AS col0 FROM tab1 AS cor0
----
134
2
64

query I rowsort
SELECT col0 * - col0 + 78 FROM tab1
----
-4018
-6322
69

query I rowsort
SELECT ALL - col2 * + col1 + + col0 FROM tab2 cor0
----
-1456
-567
-830

query I rowsort
SELECT ALL + col1 * - col0 + - ( - 21 * - col0 ) FROM tab1 AS cor0
----
-141
-1984
-2720

query I rowsort
SELECT ALL - 37 * col1 AS col2 FROM tab1 AS cor0
----
-370
-481
-962

query I rowsort
SELECT cor0.col1 + 89 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to b7bf47df7cd081a7c785a01312a198e9

query I rowsort
SELECT - - 90 + col2 AS col0 FROM tab1 AS cor0
----
144
147
186

query I rowsort
SELECT DISTINCT - + col2 + - col0 AS col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT ALL + - col0 + col0 * cor0.col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT ALL + col1 + + 34 AS col0 FROM tab0 AS cor0
----
120
125
131

query I rowsort
SELECT DISTINCT - + col2 * 47 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-2592
-2736
-4608

query I rowsort
SELECT + + col0 - + col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + col1 + 98 - cor0.col1 * + col0 FROM tab1 AS cor0
----
-532
-929
46

query I rowsort
SELECT ALL - col1 * 61 FROM tab2 cor0
----
-1037
-1891
-3599

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5433
SELECT - col0 * + CAST( NULL AS DECIMAL ) + + cor0.col2 * + col0 - - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5433
SELECT - col0 * + CAST ( NULL AS REAL ) + + cor0.col2 * + col0 - - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col1 + + col0 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + col1 * col0 + col2 + cor0.col0 AS col2 FROM tab2 AS cor0
----
1460
251
4706

query I rowsort
SELECT + col0 * cor0.col1 + cor0.col2 + col1 * col2 FROM tab1 AS cor0
----
1267
1536
2384

query I rowsort
SELECT - - col0 + col0 - + col0 * col0 * ( - col1 ) FROM tab0 AS cor0
----
118895
49584
720989

query I rowsort
SELECT DISTINCT col0 * 74 AS col2 FROM tab2 AS cor0
----
518
5772
5846

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 15 + - col1 * col1 - ( - tab0.col0 ) col1 FROM tab0
----
-7387
-8207
-9389

query I rowsort
SELECT ALL 47 + col0 AS col0 FROM tab1
----
111
127
50

query I rowsort
SELECT col1 + col1 + col2 * + col2 AS col2 FROM tab2
----
1478
791
794

query I rowsort
SELECT DISTINCT col1 - + 35 FROM tab0 AS cor0
----
51
56
62

query I rowsort
SELECT ALL + 36 * col1 AS col2 FROM tab0 AS cor0
----
3096
3276
3492

query I rowsort
SELECT DISTINCT 51 * - cor0.col2 + col1 AS col2 FROM tab1 AS cor0
----
-2728
-2897
-4883

query I rowsort
SELECT DISTINCT - 93 + col1 AS col0 FROM tab1 AS cor0
----
-67
-80
-83

query I rowsort
SELECT DISTINCT + ( + cor0.col0 ) - - col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - 8 * col2 + - col1 * col1 FROM tab1 AS cor0
----
-1108
-556
-937

query I rowsort
SELECT ALL - 82 * - col0 + col2 + - col0 * + 2 FROM tab1 AS cor0
----
294
5177
6496

onlyif mysql # use DIV operator for integer division
query I rowsort label-5449
SELECT DISTINCT col1 * + ( col1 ) DIV - col1 + tab1.col0 AS col2 FROM tab1
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-5449
SELECT DISTINCT col1 * + ( col1 ) / - col1 + tab1.col0 AS col2 FROM tab1
----
-23
54
67

query I rowsort
SELECT DISTINCT + ( 24 ) FROM tab0 cor0
----
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-5451
SELECT DISTINCT + CAST( + col1 AS SIGNED ) DIV col1 + col2 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-5451
SELECT DISTINCT + CAST ( + col1 AS INTEGER ) / col1 + col2 FROM tab0 AS cor0
----
2
34
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5452
SELECT ALL CAST( cor0.col1 AS SIGNED ) * - col2 + + ( col0 ) FROM tab0 AS cor0
----
-2814
-62
-7373

skipif mysql # not compatible
query I rowsort label-5452
SELECT ALL CAST ( cor0.col1 AS INTEGER ) * - col2 + + ( col0 ) FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5453
SELECT DISTINCT + CAST( col0 AS SIGNED ) * col0 + - CAST( col0 + - col2 AS SIGNED ) FROM tab1 AS cor0
----
4089
60
6416

skipif mysql # not compatible
query I rowsort label-5453
SELECT DISTINCT + CAST ( col0 AS INTEGER ) * col0 + - CAST ( col0 + - col2 AS INTEGER ) FROM tab1 AS cor0
----
4089
60
6416

query I rowsort
SELECT - 84 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 975e2ef2a3bf1ee2622362f4e435752f

onlyif mysql # use DIV operator for integer division
query I rowsort label-5455
SELECT ALL - cor0.col0 DIV + col2 + ( + col2 ) AS col1 FROM tab1 AS cor0
----
54
56
96

skipif mysql # not compatible
query I rowsort label-5455
SELECT ALL - cor0.col0 / + col2 + ( + col2 ) AS col1 FROM tab1 AS cor0
----
54
56
96

query I rowsort
SELECT ( 70 ) AS col0 FROM tab2
----
70
70
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5458
SELECT DISTINCT - - 54 * - col1 * + CAST( col0 AS SIGNED ) + col0 * + ( cor0.col2 ) + - col1 FROM tab2 AS cor0
----
-11560
-246539
-69537

skipif mysql # not compatible
query I rowsort label-5458
SELECT DISTINCT - - 54 * - col1 * + CAST ( col0 AS INTEGER ) + col0 * + ( cor0.col2 ) + - col1 FROM tab2 AS cor0
----
-11560
-246539
-69537

query I rowsort
SELECT DISTINCT + col1 + - col0 + + ( col1 ) * - cor0.col1 FROM tab0 cor0
----
-7334
-8279
-9347

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5460
SELECT ALL - col0 - col2 * - CAST( - col2 AS SIGNED ) * + col0 FROM tab0 AS cor0
----
-26160
-598525
-70

skipif mysql # not compatible
query I rowsort label-5460
SELECT ALL - col0 - col2 * - CAST ( - col2 AS INTEGER ) * + col0 FROM tab0 AS cor0
----
-26160
-598525
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 88 + col0 col0 FROM tab0 AS cor0
----
112
123
177

query I rowsort
SELECT DISTINCT + + cor0.col0 * + col2 + col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL 63 - col0 FROM tab0 AS cor0
----
-26
28
39

query I rowsort
SELECT DISTINCT col1 * 0 + + ( - col0 + 6 ) * - col0 * - col0 AS col2 FROM tab0
----
-10368
-35525
-657443

query I rowsort
SELECT + col1 + + 97 AS col0 FROM tab0 AS cor0
----
183
188
194

query I rowsort
SELECT - col0 + ( 91 ) - col0 FROM tab2 AS cor0
----
-65
-67
77

query I rowsort
SELECT ALL cor0.col0 * 19 AS col1 FROM tab0 AS cor0
----
1691
456
665

query I rowsort
SELECT col2 + - col1 + col2 FROM tab2
----
-7
23
59

query I rowsort
SELECT col2 * + ( tab1.col1 ) AS col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL col1 * 30 FROM tab1 cor0
----
300
390
780

query I rowsort
SELECT cor0.col1 * + cor0.col1 FROM tab2, tab1 AS cor0
----
9 values hashing to ae5946db6904798b8afac35f5777bb79

onlyif mysql # use DIV operator for integer division
query I rowsort label-5472
SELECT ALL - cor0.col0 DIV col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5472
SELECT ALL - cor0.col0 / col2 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT col2 * + col1 + + col1 * col2 AS col1 FROM tab1 AS cor0
----
1140
2496
2808

onlyif mysql # use DIV operator for integer division
query I rowsort label-5474
SELECT DISTINCT - + cor0.col2 DIV col0 - - col0 FROM tab0 AS cor0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-5474
SELECT DISTINCT - + cor0.col2 / col0 - - col0 FROM tab0 AS cor0
----
23
35
89

query I rowsort
SELECT ( col0 + col1 ) * col0 AS col0 FROM tab2
----
10686
266
7584

query I rowsort
SELECT + col2 * ( cor0.col1 ) FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5477
SELECT CAST( - col1 AS SIGNED ) + col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5477
SELECT CAST ( - col1 AS INTEGER ) + col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( 48 ) * - col2 col2 FROM tab2 AS cor0
----
-1248
-1296
-1824

query I rowsort
SELECT DISTINCT + col0 + 97 * col2 FROM tab0 cor0
----
132
3225
8043

query I rowsort
SELECT + 95 + - 90 AS col0 FROM tab2 AS cor0
----
5
5
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-5481
SELECT 93 DIV + col2 AS col0 FROM tab0
----
1
2
93

skipif mysql # not compatible
query I rowsort label-5481
SELECT 93 / + col2 AS col0 FROM tab0
----
1
2
93

query I rowsort
SELECT - col2 + + ( col0 ) * col2 FROM tab2 cor0
----
162
2002
2964

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5483
SELECT DISTINCT - col2 + CAST( col0 AS SIGNED ) + + col2 AS col1 FROM tab1 cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-5483
SELECT DISTINCT - col2 + CAST ( col0 AS INTEGER ) + + col2 AS col1 FROM tab1 cor0
----
3
64
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5484
SELECT ALL + + col1 * - CAST( col1 AS SIGNED ) - - cor0.col0 FROM tab1 AS cor0
----
-36
-673
-89

skipif mysql # not compatible
query I rowsort label-5484
SELECT ALL + + col1 * - CAST ( col1 AS INTEGER ) - - cor0.col0 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT DISTINCT col1 + ( + col1 * + cor0.col1 ) AS col2 FROM tab0 AS cor0
----
7482
8372
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-5486
SELECT DISTINCT - + col0 DIV col0 + + 27 FROM tab1 AS cor0
----
26

skipif mysql # not compatible
query I rowsort label-5486
SELECT DISTINCT - + col0 / col0 + + 27 FROM tab1 AS cor0
----
26

query I rowsort
SELECT ALL + + col1 - - 94 AS col2 FROM tab1 AS cor0
----
104
107
120

query I rowsort
SELECT ALL - cor0.col0 - - col1 AS col2 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT - 17 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 28cd5b4c959cb41fbc56389ab43d167e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 74 * col1 - + 36 col1 FROM tab1
----
1888
704
926

onlyif mysql # use DIV operator for integer division
query I rowsort label-5491
SELECT ( col0 + 29 ) DIV + tab1.col2 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-5491
SELECT ( col0 + 29 ) / + tab1.col2 FROM tab1
----
0
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5492
SELECT DISTINCT col0 DIV 62 + ( tab0.col1 * + 60 ) AS col1 FROM tab0
----
5160
5461
5820

skipif mysql # not compatible
query I rowsort label-5492
SELECT DISTINCT col0 / 62 + ( tab0.col1 * + 60 ) AS col1 FROM tab0
----
5160
5461
5820

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5493
SELECT - + col2 - CAST( - 13 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-20
-69
12

skipif mysql # not compatible
query I rowsort label-5493
SELECT - + col2 - CAST ( - 13 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-20
-69
12

query I rowsort
SELECT - - ( cor0.col2 ) * + cor0.col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 18 col2 FROM tab1, tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
81 values hashing to a13db73ec93475d2821cb4a6d0eff298

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5496
SELECT + - CAST( NULL AS SIGNED ) + col2 * cor0.col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5496
SELECT + - CAST ( NULL AS INTEGER ) + col2 * cor0.col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 * cor0.col1 - 97 FROM tab2 AS cor0
----
-1440
-314
-4699

query I rowsort
SELECT - + cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT cor0.col0 * + col0 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT - 81 * 9 AS col1 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f0f8f6ee47c5d2be7dc381d05f631eda

query I rowsort
SELECT ALL - + cor0.col2 * col1 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + col2 * + col0 * + col0 AS col1 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT ALL + 57 AS col0 FROM tab0 AS cor0
----
57
57
57

query I rowsort
SELECT DISTINCT col0 + col0 * - 27 AS col0 FROM tab0 AS cor0
----
-2314
-624
-910

query I rowsort
SELECT col0 * col0 + col2 FROM tab0 cor0
----
1226
609
8003

query I rowsort
SELECT DISTINCT - + col0 * - ( 41 ) + - col1 FROM tab0 AS cor0
----
1338
3558
898

query I rowsort
SELECT + + col1 - ( col0 ) * - col0 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT + col2 - ( ( + col1 ) ) FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5509
SELECT DISTINCT col0 DIV + 35 AS col0 FROM tab1 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-5509
SELECT DISTINCT col0 / + 35 AS col0 FROM tab1 AS cor0
----
0
1
2

query I rowsort
SELECT DISTINCT + col1 + col0 * + col0 AS col2 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT - cor0.col0 + 98 AS col1 FROM tab2 AS cor0
----
19
20
91

query I rowsort
SELECT DISTINCT + - ( + 32 ) * + col0 + col2 * cor0.col1 AS col0 FROM tab1 AS cor0
----
-1312
-1478
1308

query I rowsort
SELECT ALL cor0.col2 * - 36 FROM tab2 AS cor0
----
-1368
-936
-972

query I rowsort
SELECT + ( - col1 ) * col1 AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - cor0.col1 + + cor0.col0 * 31 AS col1 FROM tab0, tab0 AS cor0
----
2668
658
988

onlyif mysql # use DIV operator for integer division
query I rowsort label-5516
SELECT DISTINCT - 67 + 93 * col0 + tab0.col1 DIV col0 AS col2 FROM tab0
----
2168
3190
8211

skipif mysql # not compatible
query I rowsort label-5516
SELECT DISTINCT - 67 + 93 * col0 + tab0.col1 / col0 AS col2 FROM tab0
----
2168
3190
8211

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * col0 * 13 col1 FROM tab1 cor0
----
1014
13520
8320

onlyif mysql # use DIV operator for integer division
query I rowsort label-5518
SELECT + col2 DIV - 41 + + col0 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-5518
SELECT + col2 / - 41 + + col0 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT + col2 + 24 FROM tab0
----
106
25
57

query I rowsort
SELECT - tab2.col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT - 42 - 13 AS col0 FROM tab2
----
-55
-55
-55

query I rowsort
SELECT DISTINCT 1 + + 67 * col1 AS col1 FROM tab1
----
1743
671
872

query I rowsort
SELECT 26 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT DISTINCT + + col1 * - col1 + col2 * cor0.col2 * + ( 0 ) AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT - + col2 * + 69 FROM tab1 cor0
----
-3726
-3933
-6624

query I rowsort
SELECT ALL + col0 * + col0 + + col0 FROM tab0 AS cor0
----
1260
600
8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5527
SELECT ALL - - CAST( cor0.col0 AS SIGNED ) FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-5527
SELECT ALL - - CAST ( cor0.col0 AS INTEGER ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT col0 + + col1 * cor0.col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT + - col1 * 25 FROM tab1 AS cor0
----
-250
-325
-650

query I rowsort
SELECT ( 44 ) FROM tab0
----
44
44
44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5531
SELECT ALL CAST( - col2 * col1 AS SIGNED ) FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-5531
SELECT ALL CAST ( - col2 * col1 AS INTEGER ) FROM tab1
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 * + cor0.col0 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 41d4c126bfd4bfab59ba5e83427c98e0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5533
SELECT DISTINCT + + 54 DIV + ( col2 ) + 49 AS col0 FROM tab0 AS cor0
----
103
49
50

skipif mysql # not compatible
query I rowsort label-5533
SELECT DISTINCT + + 54 / + ( col2 ) + 49 AS col0 FROM tab0 AS cor0
----
103
49
50

query I rowsort
SELECT DISTINCT cor0.col0 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
24
35
89

query I rowsort
SELECT + 56 AS col0 FROM tab2 cor0
----
56
56
56

query I rowsort
SELECT DISTINCT - ( + cor0.col1 ) + col2 * col0 + - ( col1 ) * col1 AS col0 FROM tab0 AS cor0
----
-1074
-6690
-9471

onlyif mysql # use DIV operator for integer division
query I rowsort label-5537
SELECT ALL - - ( - cor0.col0 ) DIV - col0 + col2 * col1 + - col0 FROM tab1 AS cor0
----
1169
1402
507

skipif mysql # not compatible
query I rowsort label-5537
SELECT ALL - - ( - cor0.col0 ) / - col0 + col2 * col1 + - col0 FROM tab1 AS cor0
----
1169
1402
507

query I rowsort
SELECT DISTINCT col2 * col1 + + tab1.col2 + col2 FROM tab1
----
1440
1512
684

query I rowsort
SELECT + 80 AS col2 FROM tab0
----
80
80
80

query I rowsort
SELECT + - ( + col0 ) + ( col2 ) FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL tab0.col1 * + col0 + - col1 * - col1 FROM tab0
----
12804
16380
9460

query I rowsort
SELECT + 30 + + cor0.col0 AS col0 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to dc39546f39c4994da9dfa92c4ba7685f

query I rowsort
SELECT DISTINCT - 97 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
-97

query I rowsort
SELECT + + cor0.col1 * - col0 + 92 AS col1 FROM tab0 AS cor0
----
-1972
-3303
-8007

query I rowsort
SELECT + - col0 * - col2 * ( + 3 ) + col2 AS col2 FROM tab1 AS cor0
----
11001
23136
540

query I rowsort
SELECT ALL + cor0.col2 * 48 AS col0 FROM tab2 AS cor0
----
1248
1296
1824

query I rowsort
SELECT ALL + cor0.col2 * + ( + col0 + + col1 * - col2 ) AS col1 FROM tab0 AS cor0
----
-604586
-62
-92862

query I rowsort
SELECT col0 * + 71 AS col2 FROM tab1 AS cor0
----
213
4544
5680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - ( - col1 * cor0.col2 ) col0 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT DISTINCT - col2 * + 49 AS col2 FROM tab1 AS cor0
----
-2646
-2793
-4704

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5551
SELECT + col2 + - CAST( col1 AS SIGNED ) * + col2 FROM tab0 cor0
----
-2805
-7380
-96

skipif mysql # not compatible
query I rowsort label-5551
SELECT + col2 + - CAST ( col1 AS INTEGER ) * + col2 FROM tab0 cor0
----
-2805
-7380
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5552
SELECT DISTINCT - col1 * CAST( NULL AS SIGNED ) + 83 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5552
SELECT DISTINCT - col1 * CAST ( NULL AS INTEGER ) + 83 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - tab2.col2 + + col0 AS col1 FROM tab2
----
-20
41
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5554
SELECT DISTINCT - col0 - CAST( - col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-5554
SELECT DISTINCT - col0 - CAST ( - col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col0 + col0 col2 FROM tab0 AS cor0
----
2088
3430
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-5556
SELECT - + cor0.col0 DIV - col1 + + col1 * col2 AS col0 FROM tab1 AS cor0
----
1254
1404
576

skipif mysql # not compatible
query I rowsort label-5556
SELECT - + cor0.col0 / - col1 + + col1 * col2 AS col0 FROM tab1 AS cor0
----
1254
1404
576

onlyif mysql # use DIV operator for integer division
query I rowsort label-5557
SELECT col0 + + col1 DIV - col1 FROM tab0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-5557
SELECT col0 + + col1 / - col1 FROM tab0
----
23
34
88

query I rowsort
SELECT DISTINCT + col2 + col0 * col1 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT col2 * - tab2.col1 * col1 AS col0 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT + 18 FROM tab0, tab2 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

onlyif mysql # use DIV operator for integer division
query I rowsort label-5561
SELECT - - col2 DIV - 93 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5561
SELECT - - col2 / - 93 AS col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5562
SELECT + + col1 + CAST( 54 AS SIGNED ) * col2 * col2 AS col2 FROM tab2 AS cor0
----
36563
39397
77993

skipif mysql # not compatible
query I rowsort label-5562
SELECT + + col1 + CAST ( 54 AS INTEGER ) * col2 * col2 AS col2 FROM tab2 AS cor0
----
36563
39397
77993

query I rowsort
SELECT col0 * col2 * - 11 FROM tab0 AS cor0
----
-385
-80278
-8712

onlyif mysql # use DIV operator for integer division
query I rowsort label-5564
SELECT col0 DIV cor0.col1 + + col0 * + col0 col0 FROM tab2 AS cor0
----
49
6085
6245

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5564
SELECT col0 / cor0.col1 + + col0 * + col0 col0 FROM tab2 AS cor0
----
49
6085
6245

query I rowsort
SELECT 77 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT ALL 17 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT ( ( col1 ) ) + col0 * - col1 FROM tab2 AS cor0
----
-1326
-186
-4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + 73 col1 FROM tab2 AS cor0
----
104
132
90

query I rowsort
SELECT + col0 + 11 * + col2 FROM tab2 cor0
----
304
364
497

query I rowsort
SELECT tab0.col2 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT 8 + - col2 FROM tab1 AS cor0
----
-46
-49
-88

query I rowsort
SELECT col1 + - col2 * + 23 * col1 AS col0 FROM tab1 AS cor0
----
-13100
-28691
-32266

query I rowsort
SELECT + 98 * + col1 + - ( col0 ) AS col1 FROM tab2 AS cor0
----
1587
3031
5704

query I rowsort
SELECT ALL + col0 * + col2 + + col0 AS col2 FROM tab1
----
165
3712
7760

query I rowsort
SELECT ( ( col1 ) + 44 ) AS col1 FROM tab1
----
54
57
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5576
SELECT col1 + + col2 - CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5576
SELECT col1 + + col2 - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * - col0 + - 97 FROM tab1 AS cor0
----
-106
-4193
-6497

query I rowsort
SELECT DISTINCT + - 53 + cor0.col2 AS col2 FROM tab2 AS cor0
----
-15
-26
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-5579
SELECT + col2 DIV - col1 + 77 AS col0 FROM tab2 AS cor0
----
75
77
77

skipif mysql # not compatible
query I rowsort label-5579
SELECT + col2 / - col1 + 77 AS col0 FROM tab2 AS cor0
----
75
77
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-5580
SELECT ALL + - cor0.col1 DIV col1 + + col1 col0 FROM tab2 AS cor0
----
16
30
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5580
SELECT ALL + - cor0.col1 / col1 + + col1 col0 FROM tab2 AS cor0
----
16
30
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - cor0.col1 col1 FROM tab2 cor0
----
-137
-38
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5582
SELECT DISTINCT - col0 DIV col2 + col0 DIV + cor0.col0 FROM tab0 AS cor0
----
-34
0
1

skipif mysql # not compatible
query I rowsort label-5582
SELECT DISTINCT - col0 / col2 + col0 / + cor0.col0 FROM tab0 AS cor0
----
-34
0
1

query I rowsort
SELECT DISTINCT - col1 + col2 * col1 AS col1 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT DISTINCT + col2 AS col0 FROM tab1 WHERE + col1 NOT IN ( col2 )
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col2 * + col0 * col2 - + col2 col1 FROM tab1
----
207889
737197
8720

query I rowsort
SELECT - 94 AS col0 FROM tab0
----
-94
-94
-94

onlyif mysql # use DIV operator for integer division
query I rowsort label-5587
SELECT + col2 - + tab1.col2 DIV + col2 AS col2 FROM tab1
----
53
56
95

skipif mysql # not compatible
query I rowsort label-5587
SELECT + col2 - + tab1.col2 / + col2 AS col2 FROM tab1
----
53
56
95

query I rowsort
SELECT ALL tab1.col2 * col2 * col1 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT - col2 * + col2 + + col2 + - col2 AS col1 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT col0 + col2 * col0 - tab1.col0 FROM tab1
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + tab1.col1 * tab1.col0 col2 FROM tab1
----
1136
132
697

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL IN ( col0 + tab2.col2 * col1 )
----

query III rowsort
SELECT ALL * FROM tab0 WHERE col2 NOT BETWEEN col0 AND ( col1 )
----
35
97
1
89
91
82

query I rowsort
SELECT col1 * col0 + - col1 AS col1 FROM tab1
----
1027
52
630

query III rowsort
SELECT ALL * FROM tab0 WHERE ( col2 ) <> ( NULL )
----

query I rowsort
SELECT col2 * - col1 AS col1 FROM tab1 WHERE ( col1 * col0 ) BETWEEN + col1 AND NULL
----

query I rowsort
SELECT DISTINCT + tab2.col2 * - col2 AS col1 FROM tab2
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col2 + col2 col2 FROM tab0
----
1122
2
6806

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( NULL ) IN ( col1 * col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5600
SELECT DISTINCT - col1 * + col2 * ( + col1 ) + + col2 DIV + 45 FROM tab0 cor0
----
-244068
-679041
-9409

skipif mysql # not compatible
query I rowsort label-5600
SELECT DISTINCT - col1 * + col2 * ( + col1 ) + + col2 / + 45 FROM tab0 cor0
----
-244068
-679041
-9409

query I rowsort
SELECT 60 * col0 AS col2 FROM tab1 AS cor0
----
180
3840
4800

query I rowsort
SELECT col2 + cor0.col1 * + 83 * - 67 FROM tab0 AS cor0
----
-478213
-505969
-539416

query I rowsort
SELECT DISTINCT - 76 + col0 * col2 FROM tab2 AS cor0
----
113
1952
2926

query I rowsort
SELECT ALL - 15 * col0 + - 68 * - col2 AS col2 FROM tab2 AS cor0
----
1399
1731
598

query I rowsort
SELECT - + 48 AS col2 FROM tab0 AS cor0
----
-48
-48
-48

query I rowsort
SELECT ALL cor0.col1 + + col0 * + ( - 23 ) FROM tab0 AS cor0
----
-1956
-466
-708

query I rowsort
SELECT ALL - + col1 + col2 AS col2 FROM tab2 cor0
----
-33
-4
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col1 + cor0.col1 col2 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT col0 - col1 * cor0.col0 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT + col2 + col2 * col2 - - col1 * + col0 FROM tab2 AS cor0
----
2825
5304
973

query I rowsort
SELECT - col0 + col2 + - col0 AS col0 FROM tab2
----
-120
-130
13

query I rowsort
SELECT tab0.col2 * - col0 * + col2 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT ALL col0 + col1 + - col0 AS col0 FROM tab2 AS cor0
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-5614
SELECT - cor0.col2 DIV + col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5614
SELECT - cor0.col2 / + col2 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT col0 * + col2 + col1 * - col1 * + col2 - - col1 AS col0 FROM tab2 AS cor0
----
-25727
-7963
-88419

query I rowsort
SELECT - col0 * + col1 + col0 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL - tab0.col2 + tab0.col2 FROM tab0
----
0
0
0

query I rowsort
SELECT col0 * - col2 + - col0 FROM tab2
----
-196
-2106
-3081

query I rowsort
SELECT ALL + col2 + col1 * - col2 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT ALL tab0.col0 * + col2 FROM tab0 WHERE + col0 = - col0
----

query I rowsort
SELECT DISTINCT - tab0.col0 + + col2 AS col2 FROM tab0
----
-34
-7
9

query I rowsort
SELECT col1 + - col2 AS col1 FROM tab1 WHERE NOT NULL BETWEEN col1 AND + col1
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL NOT BETWEEN NULL AND NULL
----

query III rowsort
SELECT * FROM tab0 WHERE + col0 + + col0 - - col2 BETWEEN col2 AND - col0 * col0 / - col2 + col1
----
24
86
33
35
97
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5625
SELECT col1 * col1 * + tab1.col1 + + col2 DIV col0 + col0 * col2 DIV col1 col2 FROM tab1
----
1364
17600
2788

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5625
SELECT col1 * col1 * + tab1.col1 + + col2 / col0 + col0 * col2 / col1 col2 FROM tab1
----
1364
17600
2788

query I rowsort
SELECT + col0 * col0 + col1 FROM tab1
----
35
4106
6413

query I rowsort
SELECT DISTINCT col0 * + col1 - col0 FROM tab2 WHERE NULL > + col2 + col0
----

query I rowsort
SELECT + tab0.col1 FROM tab0 WHERE NOT NULL = NULL
----

query I rowsort
SELECT col2 + + col2 * col1 * - col0 AS col1 FROM tab0
----
-3394
-664036
-68079

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE + col0 <> NULL
----

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-5632
SELECT DISTINCT + - col0 DIV + col1 + col0 * col2 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-5632
SELECT DISTINCT + - col0 / + col1 + col0 * col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL 62 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5634
SELECT ALL col2 DIV - col2 AS col1 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5634
SELECT ALL col2 / - col2 AS col1 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT 69 * col0 + - ( + col2 ) FROM tab2
----
456
5356
5413

query I rowsort
SELECT + 75 + - col0 FROM tab0
----
-14
40
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-5637
SELECT DISTINCT - 74 DIV - cor0.col1 FROM tab0, tab1, tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5637
SELECT DISTINCT - 74 / - cor0.col1 FROM tab0, tab1, tab0 AS cor0
----
0

query I rowsort
SELECT ALL cor0.col1 + + col2 * - 92 FROM tab1 AS cor0
----
-4942
-5234
-8819

query I rowsort
SELECT ALL ( col1 ) * - col0 + + col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5641
SELECT ALL + col2 / - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5641
SELECT ALL + col2 / - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 + + col1 + 84 FROM tab2
----
108
22
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5643
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - 70 FROM tab1, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5643
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - 70 FROM tab1, tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col1 * + col0 * 60 + - col0 AS col1 FROM tab1
----
38336
4677
62320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col1 + 41 col2 FROM tab0
----
7437
8322
9450

query I rowsort
SELECT ALL - - col1 * 84 FROM tab2 AS cor0
----
1428
2604
4956

query I rowsort
SELECT DISTINCT + ( 28 ) * col2 AS col1 FROM tab1 AS cor0
----
1512
1596
2688

query I rowsort
SELECT DISTINCT + ( - 94 ) + col2 FROM tab1 AS cor0
----
-37
-40
2

query I rowsort
SELECT ALL + col2 - + 7 FROM tab1 AS cor0
----
47
50
89

query I rowsort
SELECT ALL ( col0 ) * tab2.col2 * col2 + - 13 AS col1 FROM tab2
----
114063
5090
52715

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 15 col1 FROM tab0, tab0 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT DISTINCT + cor0.col0 * + ( col0 ) FROM tab1 cor0
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5653
SELECT ALL CAST( NULL AS SIGNED ) - col1 * - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5653
SELECT ALL CAST ( NULL AS INTEGER ) - col1 * - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + 52 AS col1 FROM tab0 AS cor0
----
-52

query I rowsort
SELECT DISTINCT + 76 FROM tab2 cor0
----
76

query I rowsort
SELECT DISTINCT + 84 * 70 + + col0 FROM tab1 AS cor0
----
5883
5944
5960

query I rowsort
SELECT ALL + + col1 * 83 + col0 * col1 FROM tab1 AS cor0
----
1470
2119
2236

query I rowsort
SELECT ALL col0 * + col2 + - col2 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT DISTINCT + 81 AS col2 FROM tab0 AS cor0
----
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5660
SELECT DISTINCT + + CAST( NULL AS SIGNED ) * - col1 + col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5660
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) * - col1 + col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT 10 * col0 + col0 FROM tab0 AS cor0
----
264
385
979

query I rowsort
SELECT ALL - 40 + col1 - - col0 * col0 * - cor0.col2 AS col0 FROM tab1 AS cor0
----
-233502
-500
-614427

query I rowsort
SELECT DISTINCT col0 + 70 AS col0 FROM tab2 cor0
----
148
149
77

query I rowsort
SELECT DISTINCT - - col1 * - 13 * + col2 + - 55 * - cor0.col1 * col1 FROM tab1 AS cor0
----
-1910
-6929
18928

query I rowsort
SELECT - ( 54 ) AS col2 FROM tab2
----
-54
-54
-54

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col2 * col2 * - col2 col0 FROM tab2
----
-17576
-19683
-54872

query I rowsort
SELECT + col1 * + 82 AS col1 FROM tab0
----
7052
7462
7954

onlyif mysql # use DIV operator for integer division
query I rowsort label-5668
SELECT - col0 DIV - cor0.col0 - - col1 AS col1 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-5668
SELECT - col0 / - cor0.col0 - - col1 AS col1 FROM tab2 AS cor0
----
18
32
60

query I rowsort
SELECT DISTINCT + - col2 * col1 * col1 AS col2 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT cor0.col2 + - cor0.col2 * col1 - + col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - - cor0.col2 * + cor0.col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - cor0.col0 * - col1 + - col2 AS col2 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT - + col2 + - col2 * + cor0.col0 FROM tab0 cor0
----
-36
-7380
-825

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5674
SELECT CAST( NULL AS SIGNED ) + - col2 + col1 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5674
SELECT CAST ( NULL AS INTEGER ) + - col2 + col1 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT 37 * col2 AS col2 FROM tab0
----
1221
3034
37

query I rowsort
SELECT - 60 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 067a4b5daf8747042e3b07ca8459859f

query I rowsort
SELECT DISTINCT + col2 + col0 + col0 FROM tab0
----
260
71
81

query I rowsort
SELECT 94 * + col1 + + col2 FROM tab0 AS cor0
----
8117
8636
9119

query I rowsort
SELECT DISTINCT - col1 + - 22 FROM tab2 AS cor0
----
-39
-53
-81

query I rowsort
SELECT + col1 * - 5 + - col0 * + col1 AS col1 FROM tab2 AS cor0
----
-1428
-372
-4897

query I rowsort
SELECT DISTINCT + col1 * ( + 14 ) FROM tab1 cor0
----
140
182
364

query I rowsort
SELECT DISTINCT + col0 * col1 * col0 AS col2 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT ALL cor0.col0 * - 34 * col2 FROM tab1 AS cor0
----
-124032
-261120
-5508

onlyif mysql # use DIV operator for integer division
query I rowsort label-5684
SELECT DISTINCT - col1 + ( col1 ) DIV + col1 FROM tab1 cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-5684
SELECT DISTINCT - col1 + ( col1 ) / + col1 FROM tab1 cor0
----
-12
-25
-9

query I rowsort
SELECT ALL - col2 + - 97 AS col2 FROM tab2 AS cor0
----
-123
-124
-135

query I rowsort
SELECT col1 * - col0 + + 14 * + col2 AS col2 FROM tab1
----
158
304
678

query I rowsort
SELECT DISTINCT col2 - - ( col2 ) * tab1.col0 FROM tab1
----
216
3705
7776

query I rowsort
SELECT + ( col0 ) * + col2 - col0 AS col1 FROM tab2 AS cor0
----
182
1950
2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-5689
SELECT 98 DIV + col2 - col1 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-5689
SELECT 98 / + col2 - col1 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col1 * CAST ( - col0 AS REAL ) FROM tab0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 col1 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5692
SELECT DISTINCT + col1 * - CAST( - col1 AS SIGNED ) AS col2 FROM tab1
----
100
169
676

skipif mysql # not compatible
query I rowsort label-5692
SELECT DISTINCT + col1 * - CAST ( - col1 AS INTEGER ) AS col2 FROM tab1
----
100
169
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5693
SELECT + - col0 * - CAST( NULL AS DECIMAL ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5693
SELECT + - col0 * - CAST ( NULL AS REAL ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 7 * + cor0.col1 * col1 FROM tab2 AS cor0
----
2023
24367
6727

query I rowsort
SELECT ALL + + ( - 34 ) FROM tab1 AS cor0
----
-34
-34
-34

query I rowsort
SELECT DISTINCT + + 45 * col1 AS col1 FROM tab0 AS cor0
----
3870
4095
4365

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5697
SELECT + + CAST( cor0.col2 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-5697
SELECT + + CAST ( cor0.col2 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + + col2 + - ( col1 ) AS col2 FROM tab1 AS cor0
----
28
47
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5699
SELECT - CAST( + 15 AS SIGNED ) AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

skipif mysql # not compatible
query I rowsort label-5699
SELECT - CAST ( + 15 AS INTEGER ) AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

query I rowsort
SELECT ALL 20 + col0 AS col1 FROM tab2 AS cor0
----
27
98
99

query I rowsort
SELECT + 22 FROM tab2, tab2 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT col2 + col1 * + ( + 18 ) AS col1 FROM tab2 AS cor0
----
1088
344
585

query I rowsort
SELECT + col2 - + cor0.col0 FROM tab2 cor0
----
-41
-52
20

skipif mysql # not compatible
query I rowsort
SELECT col0 * - col2 * - CAST ( - col2 AS REAL ) FROM tab1 AS cor0
----
-207936
-737280
-8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-5705
SELECT - + col1 DIV - col1 col1 FROM tab0 cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5705
SELECT - + col1 / - col1 col1 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - col0 * + col2 + col0 AS col2 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT ( - tab2.col0 + col0 ) FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5708
SELECT DISTINCT 57 DIV + 73 AS col2 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-5708
SELECT DISTINCT 57 / + 73 AS col2 FROM tab0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5709
SELECT + - col0 * + col1 * + CAST( - cor0.col0 AS SIGNED ) + + col2 FROM tab0 AS cor0
----
118826
49569
720893

skipif mysql # not compatible
query I rowsort label-5709
SELECT + - col0 * + col1 * + CAST ( - cor0.col0 AS INTEGER ) + + col2 FROM tab0 AS cor0
----
118826
49569
720893

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 - cor0.col1 col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - + 6 AS col0 FROM tab0 AS cor0
----
-6
-6
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-5712
SELECT DISTINCT col2 DIV - ( + col0 ) FROM tab1 cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-5712
SELECT DISTINCT col2 / - ( + col0 ) FROM tab1 cor0
----
-1
-18
0

query I rowsort
SELECT DISTINCT col2 * col1 + ( col1 ) AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT - ( + col0 ) * tab1.col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT col2 * - 61 AS col2 FROM tab2 AS cor0
----
-1586
-1647
-2318

query I rowsort
SELECT ALL - - col0 + + 18 + + col1 FROM tab2 AS cor0
----
114
155
56

query I rowsort
SELECT ALL - col1 * col2 + + col2 * col0 AS col1 FROM tab1 cor0
----
-1242
3078
6432

query I rowsort
SELECT ALL col1 * - col2 + col0 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT - + col1 + 77 + 10 AS col0 FROM tab1 AS cor0
----
61
74
77

query I rowsort
SELECT ALL + + col1 * ( + col1 ) + col0 AS col2 FROM tab1 cor0
----
164
249
679

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5721
SELECT ALL + cor0.col0 + + CAST( + col0 AS SIGNED ) col1 FROM tab2 AS cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5721
SELECT ALL + cor0.col0 + + CAST ( + col0 AS INTEGER ) col1 FROM tab2 AS cor0
----
14
156
158

skipif mysql # not compatible
query I rowsort
SELECT ALL col2 + + CAST ( + col1 AS REAL ) AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT col1 * 7 FROM tab2 AS cor0
----
119
217
413

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * col2 col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5725
SELECT ALL col2 * col2 - CAST( NULL AS SIGNED ) * - ( + tab2.col0 ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5725
SELECT ALL col2 * col2 - CAST ( NULL AS INTEGER ) * - ( + tab2.col0 ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 42 - - col2 FROM tab2
----
-15
-16
-4

query I rowsort
SELECT DISTINCT - 90 - + col0 FROM tab0
----
-114
-125
-179

query I rowsort
SELECT DISTINCT + + 50 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col2 * col2 + cor0.col1 col1 FROM tab0 AS cor0
----
36023
551459
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5730
SELECT ALL + cor0.col0 DIV col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-5730
SELECT ALL + cor0.col0 / col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT + - col1 * 45 AS col2 FROM tab2 AS cor0
----
-1395
-2655
-765

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + col0 col0 FROM tab1 AS cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 + + 62 col0 FROM tab2 AS cor0
----
-16
-17
55

query I rowsort
SELECT ALL + + col1 * ( col1 ) * + col0 AS col0 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT DISTINCT - - col1 + + 29 FROM tab2 AS cor0
----
46
60
88

query I rowsort
SELECT + tab1.col1 * tab1.col1 FROM tab1
----
100
169
676

query I rowsort
SELECT ALL - 95 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 1c7934db0632c123332c43f17b661d6c

query I rowsort
SELECT - - col2 * ( col1 ) AS col2 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 col0 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
24
35
89

query I rowsort
SELECT - + col1 - cor0.col1 AS col0 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT + col1 * + col2 * + 19 - 86 FROM tab2 cor0
----
12188
15817
29060

query I rowsort
SELECT + col0 - col0 * ( - col0 ) FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT + col1 * + col2 - col1 * col2 AS col0 FROM tab2 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5744
SELECT DISTINCT - + cor0.col1 DIV col1 + - col0 FROM tab1 AS cor0
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-5744
SELECT DISTINCT - + cor0.col1 / col1 + - col0 FROM tab1 AS cor0
----
-4
-65
-81

query I rowsort
SELECT - col0 - - col0 * + col1 FROM tab2 cor0
----
1264
210
4524

query I rowsort
SELECT ALL + - 22 + cor0.col2 AS col2 FROM tab1 AS cor0
----
32
35
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-5747
SELECT DISTINCT + col1 + + col1 * col2 DIV + 73 AS col2 FROM tab2 AS cor0
----
25
42
80

skipif mysql # not compatible
query I rowsort label-5747
SELECT DISTINCT + col1 + + col1 * col2 / + 73 AS col2 FROM tab2 AS cor0
----
25
42
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - cor0.col2 col2 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT - cor0.col2 + + cor0.col0 AS col2 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT ALL + 32 * - 68 FROM tab1 AS cor0
----
-2176
-2176
-2176

query I rowsort
SELECT col2 * + ( - col2 ) FROM tab0 AS cor0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col0 + col0 col2 FROM tab2 cor0
----
1422
224
4680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5753
SELECT ALL - - cor0.col1 * + cor0.col0 + + col2 / CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5753
SELECT ALL - - cor0.col1 * + cor0.col0 + + col2 / CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * col0 + - col2 AS col0 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT + ( 31 ) * col1 FROM tab0 AS cor0
----
2666
2821
3007

query I rowsort
SELECT DISTINCT - col0 + - col1 AS col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT 93 + + col2 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-6631
-996
92

query I rowsort
SELECT ALL col2 + + col1 AS col0 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-5759
SELECT + + 48 DIV - ( + col1 ) + 24 * + col1 FROM tab0 AS cor0
----
2064
2184
2328

skipif mysql # not compatible
query I rowsort label-5759
SELECT + + 48 / - ( + col1 ) + 24 * + col1 FROM tab0 AS cor0
----
2064
2184
2328

query I rowsort
SELECT ALL + + 58 AS col0 FROM tab2 cor0
----
58
58
58

query I rowsort
SELECT DISTINCT + ( col1 ) + + col2 * col2 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT - - col2 + - col1 * + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT - 57 * - col0 FROM tab0 cor0
----
1368
1995
5073

query I rowsort
SELECT + 88 * + col1 FROM tab0 AS cor0
----
7568
8008
8536

query I rowsort
SELECT ALL - col1 + ( + col0 ) * col2 FROM tab1
----
136
3638
7667

query I rowsort
SELECT DISTINCT + col1 + 18 + ( + col0 ) FROM tab1 AS cor0
----
111
47
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5767
SELECT DISTINCT + col0 * CAST( 81 AS SIGNED ) + + col2 FROM tab0 AS cor0
----
1977
2836
7291

skipif mysql # not compatible
query I rowsort label-5767
SELECT DISTINCT + col0 * CAST ( 81 AS INTEGER ) + + col2 FROM tab0 AS cor0
----
1977
2836
7291

query I rowsort
SELECT DISTINCT + 40 FROM tab2, tab1 AS cor0
----
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-5769
SELECT ALL col0 + + ( - 28 ) DIV col2 AS col1 FROM tab0 AS cor0
----
24
7
89

skipif mysql # not compatible
query I rowsort label-5769
SELECT ALL col0 + + ( - 28 ) / col2 AS col1 FROM tab0 AS cor0
----
24
7
89

query I rowsort
SELECT ALL col0 * 30 + cor0.col1 FROM tab1 AS cor0
----
116
1930
2413

query I rowsort
SELECT DISTINCT - - cor0.col0 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5772
SELECT ALL - col0 + CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5772
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-5773
SELECT DISTINCT - tab0.col0 DIV ( col1 ) + col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-5773
SELECT DISTINCT - tab0.col0 / ( col1 ) + col2 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL - col2 + + col0 - col0 * col2 FROM tab2
----
-1976
-209
-2961

query I rowsort
SELECT ALL - col1 - + ( - tab0.col0 + col2 ) FROM tab0
----
-63
-84
-95

query I rowsort
SELECT + + col0 * - 34 * 66 AS col0 FROM tab2 AS cor0
----
-15708
-175032
-177276

query I rowsort
SELECT ALL - col2 * col1 * + col2 AS col1 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT cor1.col0 AS col1 FROM tab2, tab1 cor0, tab1 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT - tab1.col2 + - 54 AS col0 FROM tab1
----
-108
-111
-150

query I rowsort
SELECT - col1 + - col1 + + col1 * + col0 FROM tab2
----
1309
155
4484

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 26 * + cor0.col0 + col2 col2 FROM tab2 cor0
----
-155
-2002
-2016

onlyif mysql # use DIV operator for integer division
query I rowsort label-5782
SELECT + cor1.col2 DIV 6 col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 0a5013ecd593af532af9de6be67cf023

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5782
SELECT + cor1.col2 / 6 col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 0a5013ecd593af532af9de6be67cf023

query I rowsort
SELECT ALL col2 * - ( + col0 * - col1 ) AS col1 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT + 4 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

onlyif mysql # use DIV operator for integer division
query I rowsort label-5785
SELECT 43 DIV tab0.col2 FROM tab0
----
0
1
43

skipif mysql # not compatible
query I rowsort label-5785
SELECT 43 / tab0.col2 FROM tab0
----
0
1
43

query I rowsort
SELECT - col1 * ( - col2 * 5 ) FROM tab2
----
3230
4185
7670

query I rowsort
SELECT ALL cor1.col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5788
SELECT - CAST( NULL AS SIGNED ) + + 90 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5788
SELECT - CAST ( NULL AS INTEGER ) + + 90 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 70 - - col2 col2 FROM tab2 AS cor0
----
108
96
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + - col0 col1 FROM tab0 AS cor0
----
-171
-36
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-5791
SELECT - col1 DIV + 15 + col0 FROM tab2 cor0
----
5
75
78

skipif mysql # not compatible
query I rowsort label-5791
SELECT - col1 / + 15 + col0 FROM tab2 cor0
----
5
75
78

query I rowsort
SELECT 43 * cor0.col0 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to fd9e4d7fa173954e648d0b9de8c21c65

query I rowsort
SELECT ALL ( - col0 ) * + 32 AS col2 FROM tab2
----
-224
-2496
-2528

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5794
SELECT ALL + col1 * col1 - - CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
7310
8190
9312

skipif mysql # not compatible
query I rowsort label-5794
SELECT ALL + col1 * col1 - - CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT ALL - 30 * + col2 AS col2 FROM tab1 AS cor0
----
-1620
-1710
-2880

query I rowsort
SELECT + 56 + col0 * col2 AS col1 FROM tab1 AS cor0
----
218
3704
7736

query I rowsort
SELECT cor0.col2 * 88 FROM tab2 AS cor0
----
2288
2376
3344

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col2 col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT - col1 * ( + 74 + col2 * + col1 ) FROM tab2 AS cor0
----
-12240
-28241
-94872

query I rowsort
SELECT DISTINCT col1 * col0 - - cor0.col0 AS col2 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT - col2 + + 50 FROM tab1 AS cor0
----
-4
-46
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5802
SELECT DISTINCT - col0 * col0 + + cor0.col2 * + cor0.col1 * CAST( NULL AS DECIMAL ) - + 74 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5802
SELECT DISTINCT - col0 * col0 + + cor0.col2 * + cor0.col1 * CAST ( NULL AS REAL ) - + 74 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 81 * + col2 * + col1 AS col1 FROM tab1
----
101088
113724
46170

query I rowsort
SELECT ( + tab2.col1 ) * col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT 30 AS col0 FROM tab2, tab0 cor0
----
30

query I rowsort
SELECT col2 * col2 - + tab0.col1 AS col2 FROM tab0
----
-96
1003
6633

onlyif mysql # use DIV operator for integer division
query I rowsort label-5807
SELECT ( - col1 ) * col1 - - col0 DIV - 88 AS col1 FROM tab0
----
-7396
-8282
-9409

skipif mysql # not compatible
query I rowsort label-5807
SELECT ( - col1 ) * col1 - - col0 / - 88 AS col1 FROM tab0
----
-7396
-8282
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - ( + col1 * ( col2 ) ) col0 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT - col0 * 4 + - col0 FROM tab2
----
-35
-390
-395

query I rowsort
SELECT + 61 * col0 AS col1 FROM tab2 cor0
----
427
4758
4819

query I rowsort
SELECT 78 + + col2 FROM tab0 AS cor0
----
111
160
79

query I rowsort
SELECT DISTINCT + col0 + - cor0.col0 * col2 AS col0 FROM tab1 cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL - + 50 * - col2 - col1 FROM tab1 AS cor0
----
2674
2840
4787

query I rowsort
SELECT ALL col0 - col2 AS col2 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5815
SELECT + col2 * - col0 * CAST( + col2 AS SIGNED ) FROM tab0 AS cor0
----
-26136
-35
-598436

skipif mysql # not compatible
query I rowsort label-5815
SELECT + col2 * - col0 * CAST ( + col2 AS INTEGER ) FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT ( + col0 ) + + col1 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5817
SELECT DISTINCT + 75 * + col2 + - CAST( NULL AS SIGNED ) * 35 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5817
SELECT DISTINCT + 75 * + col2 + - CAST ( NULL AS INTEGER ) * 35 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - + 0 + + col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + 41 * + 36 FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 cor2
----
81 values hashing to 5c6b0687aeba0be0885a4a48108f73e2

onlyif mysql # use DIV operator for integer division
query I rowsort label-5820
SELECT tab2.col0 * - 62 + + 74 + col0 DIV col1 FROM tab2
----
-360
-4761
-4820

skipif mysql # not compatible
query I rowsort label-5820
SELECT tab2.col0 * - 62 + + 74 + col0 / col1 FROM tab2
----
-360
-4761
-4820

onlyif mysql # use DIV operator for integer division
query I rowsort label-5821
SELECT - + col0 * - 79 + - col0 DIV col0 + 4 FROM tab1 AS cor0
----
240
5059
6323

skipif mysql # not compatible
query I rowsort label-5821
SELECT - + col0 * - 79 + - col0 / col0 + 4 FROM tab1 AS cor0
----
240
5059
6323

query I rowsort
SELECT + cor0.col1 + col0 * - 2 AS col0 FROM tab0 cor0
----
-87
27
38

query I rowsort
SELECT col2 + ( ( col2 ) ) * 26 * + col1 AS col2 FROM tab0 AS cor0
----
194094
2523
73821

query I rowsort
SELECT cor0.col0 * + 89 AS col1 FROM tab2 AS cor0
----
623
6942
7031

query I rowsort
SELECT col0 * - cor0.col0 * - col1 AS col2 FROM tab2 AS cor0
----
106097
1519
358956

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5826
SELECT CAST( - col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-5826
SELECT CAST ( - col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5827
SELECT ALL - + col1 DIV + cor0.col2 + + col0 AS col0 FROM tab0 AS cor0
----
-62
22
88

skipif mysql # not compatible
query I rowsort label-5827
SELECT ALL - + col1 / + cor0.col2 + + col0 AS col0 FROM tab0 AS cor0
----
-62
22
88

query I rowsort
SELECT - col1 * col0 * - col2 + ( col1 ) - col0 * col0 FROM tab1 AS cor0
----
32394
4229
93453

query I rowsort
SELECT - col0 + 81 * col2 + 3 AS col0 FROM tab1 AS cor0
----
4374
4556
7699

query I rowsort
SELECT + col1 * col2 - cor0.col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT ALL - - 66 * + col2 + col0 FROM tab0 cor0
----
101
2202
5501

query I rowsort
SELECT DISTINCT - cor0.col1 * + col2 + + col1 AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 27 * - col1 col2 FROM tab0 AS cor0
----
-2322
-2457
-2619

query I rowsort
SELECT ALL - 42 + - col1 + col1 AS col2 FROM tab1 AS cor0
----
-42
-42
-42

query I rowsort
SELECT cor0.col0 + - col0 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 - cor0.col1 AS col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT ALL - 18 AS col0 FROM tab2 AS cor0
----
-18
-18
-18

query I rowsort
SELECT DISTINCT - col1 + 58 + - col2 * col0 FROM tab2 AS cor0
----
-162
-2029
-2961

query I rowsort
SELECT DISTINCT + + cor0.col2 AS col0 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT DISTINCT 87 FROM tab0, tab2 cor0
----
87

query I rowsort
SELECT - col2 + col0 - col1 FROM tab2 AS cor0
----
-51
-7
24

query I rowsort
SELECT + ( - col1 ) * col2 * + 56 + - 7 * col1 * ( + col0 ) + col0 * 45 AS col0 FROM tab1 cor0
----
-33520
-73568
-79035

query I rowsort
SELECT DISTINCT + + ( col2 ) * - col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5844
SELECT - CAST( NULL AS SIGNED ) / + cor0.col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5844
SELECT - CAST ( NULL AS INTEGER ) / + cor0.col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - tab2.col2 + + ( col2 * 42 ) FROM tab2
----
1066
1107
1558

onlyif mysql # use DIV operator for integer division
query I rowsort label-5846
SELECT DISTINCT - col2 DIV - col1 col1 FROM tab1 AS cor0
----
2
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5846
SELECT DISTINCT - col2 / - col1 col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT + ( 47 ) FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

onlyif mysql # use DIV operator for integer division
query I rowsort label-5848
SELECT - - ( col1 ) * col2 DIV col2 AS col2 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-5848
SELECT - - ( col1 ) * col2 / col2 AS col2 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5849
SELECT - 5 DIV + col0 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5849
SELECT - 5 / + col0 AS col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5850
SELECT CAST( NULL AS SIGNED ) + col1 * + col1 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5850
SELECT CAST ( NULL AS INTEGER ) + col1 * + col1 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT DISTINCT + col2 + cor0.col2 + ( col2 * + 16 + col2 ) FROM tab2 AS cor0
----
494
513
722

query I rowsort
SELECT - - col2 + - 24 * + col0 FROM tab1 AS cor0
----
-1479
-18
-1824

query I rowsort
SELECT ALL + cor0.col2 + + col1 + col1 * - col0 FROM tab0 AS cor0
----
-1945
-3297
-7926

query I rowsort
SELECT DISTINCT col0 * - col1 + col1 FROM tab1 cor0
----
-1027
-52
-630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5856
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-5856
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
NULL

query I rowsort
SELECT - col0 * col0 + tab0.col0 * + col0 * - 53 FROM tab0
----
-31104
-427734
-66150

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 98 col2 FROM tab2, tab1 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT + + col0 + 90 FROM tab1 AS cor0
----
154
170
93

query I rowsort
SELECT ALL + 4 * tab0.col0 FROM tab0
----
140
356
96

query I rowsort
SELECT + tab1.col0 * col2 + - 38 * col2 FROM tab1
----
-1890
1482
4032

query I rowsort
SELECT DISTINCT + ( - 92 ) AS col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-5863
SELECT DISTINCT - col0 DIV col1 + - col1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-5863
SELECT DISTINCT - col0 / col1 + - col1 FROM tab0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( col2 ) col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT + 28 AS col0 FROM tab2 cor0
----
28

query I rowsort
SELECT DISTINCT - col2 + col0 * - col0 FROM tab1 AS cor0
----
-4153
-63
-6496

query I rowsort
SELECT ALL + col0 + col2 * - 34 FROM tab1 AS cor0
----
-1833
-1874
-3184

query I rowsort
SELECT - - 56 + + col1 * ( 19 ) AS col1 FROM tab0 AS cor0
----
1690
1785
1899

query I rowsort
SELECT ALL - col2 * - col2 * - col1 FROM tab0 AS cor0
----
-611884
-93654
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 31 col2 FROM tab1 AS cor0
----
-31
-31
-31

query I rowsort
SELECT ALL 80 + col2 AS col2 FROM tab0 AS cor0
----
113
162
81

query I rowsort
SELECT 73 + cor0.col2 * col1 AS col1 FROM tab0 AS cor0
----
170
2911
7535

query I rowsort
SELECT DISTINCT - col0 * + ( col0 ) - col1 * cor0.col2 AS col0 FROM tab2 AS cor0
----
-6887
-7618
-886

query I rowsort
SELECT + - col2 + 9 * - 13 AS col1 FROM tab1 AS cor0
----
-171
-174
-213

query I rowsort
SELECT + - col0 + - col0 * col1 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT ALL - col0 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + + col2 * + 29 FROM tab0 AS cor0
----
2378
29
957

query I rowsort
SELECT ALL + 98 * ( + col1 ) FROM tab2 AS cor0
----
1666
3038
5782

query I rowsort
SELECT DISTINCT - cor0.col2 + 27 * - 70 FROM tab1, tab0 AS cor0, tab2 cor1
----
-1891
-1923
-1972

query I rowsort
SELECT + 12 * cor0.col1 AS col0 FROM tab2 AS cor0
----
204
372
708

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5881
SELECT DISTINCT + CAST( col0 AS SIGNED ) col1 FROM tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5881
SELECT DISTINCT + CAST ( col0 AS INTEGER ) col1 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-5882
SELECT + - col2 DIV cor0.col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-5882
SELECT + - col2 / cor0.col1 FROM tab1 AS cor0
----
-2
-5
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5883
SELECT ALL CAST( NULL AS SIGNED ) / - 47 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5883
SELECT ALL CAST ( NULL AS INTEGER ) / - 47 AS col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5884
SELECT DISTINCT - CAST( 99 AS SIGNED ) AS col2 FROM tab1
----
-99

skipif mysql # not compatible
query I rowsort label-5884
SELECT DISTINCT - CAST ( 99 AS INTEGER ) AS col2 FROM tab1
----
-99

query I rowsort
SELECT + - cor0.col0 * - col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL + ( + 84 ) * + col2 FROM tab0
----
2772
6888
84

query I rowsort
SELECT ( - tab0.col1 ) + col0 AS col2 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT 94 + col2 AS col1 FROM tab1
----
148
151
190

query I rowsort
SELECT DISTINCT + + 50 FROM tab2, tab0, tab1 AS cor0
----
50

query I rowsort
SELECT ALL 51 AS col1 FROM tab2
----
51
51
51

query I rowsort
SELECT - col0 * + 56 + - 94 FROM tab2
----
-4462
-4518
-486

query I rowsort
SELECT - col0 + + ( + 35 ) FROM tab1
----
-29
-45
32

query I rowsort
SELECT DISTINCT - tab2.col1 + 65 FROM tab2
----
34
48
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-5894
SELECT + col1 * - 18 + 63 DIV + col0 AS col1 FROM tab1
----
-180
-234
-447

skipif mysql # not compatible
query I rowsort label-5894
SELECT + col1 * - 18 + 63 / + col0 AS col1 FROM tab1
----
-180
-234
-447

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 55 col2 FROM tab0, tab1, tab0 AS cor0, tab2
----
81 values hashing to c59acfbb70996777fa5053195838c3d6

query I rowsort
SELECT - col2 * + col1 + - col1 AS col1 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT DISTINCT col1 * ( - col2 ) + - col1 FROM tab0
----
-194
-2924
-7553

query I rowsort
SELECT cor0.col2 + - col1 * col1 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT col1 * ( + col1 ) * col1 AS col0 FROM tab1
----
1000
17576
2197

query I rowsort
SELECT DISTINCT col2 * - ( col2 ) + - tab2.col1 AS col0 FROM tab2
----
-1461
-735
-760

query I rowsort
SELECT ALL - col2 * - 62 * - col0 + - col1 * col0 - - col1 FROM tab2 AS cor0
----
-11904
-130279
-187450

query I rowsort
SELECT + 55 * col1 AS col0 FROM tab2
----
1705
3245
935

query I rowsort
SELECT col0 * + tab2.col1 * - col2 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT - ( 92 ) FROM tab1 AS cor0
----
-92
-92
-92

query I rowsort
SELECT ALL - + col2 + - ( col1 * col0 ) + - col2 FROM tab2 cor0
----
-1419
-271
-4654

query I rowsort
SELECT ( 50 ) FROM tab1 AS cor0
----
50
50
50

query I rowsort
SELECT ALL + + ( col1 ) + - col0 AS col0 FROM tab1 AS cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 16 * col0 col1 FROM tab1 AS cor0
----
-1024
-1280
-48

query I rowsort
SELECT DISTINCT col2 + - col0 * col1 + col1 FROM tab2 AS cor0
----
-1288
-159
-4517

query I rowsort
SELECT - - col0 - col2 AS col2 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-5911
SELECT ALL cor0.col1 DIV - col0 AS col0 FROM tab0 cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-5911
SELECT ALL cor0.col1 / - col0 AS col0 FROM tab0 cor0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 - col2 * cor0.col1 col2 FROM tab2 AS cor0
----
-1456
-567
-830

onlyif mysql # use DIV operator for integer division
query I rowsort label-5913
SELECT DISTINCT cor0.col0 DIV col2 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-5913
SELECT DISTINCT cor0.col0 / col2 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT - col1 * - col2 + col2 AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ( + col1 ) + tab2.col2 * - col1 AS col1 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT - col1 - + col0 * col2 FROM tab2
----
-2087
-220
-3019

query I rowsort
SELECT ALL - col0 * - col2 + + col1 FROM tab0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-5918
SELECT ALL tab1.col1 DIV + col0 FROM tab1
----
0
0
8

skipif mysql # not compatible
query I rowsort label-5918
SELECT ALL tab1.col1 / + col0 FROM tab1
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * - col0 + - col2 col1 FROM tab1 AS cor0
----
-4153
-63
-6496

query I rowsort
SELECT - col2 * - col1 * col0 + col0 AS col1 FROM tab0 cor0
----
3430
664207
68136

query I rowsort
SELECT DISTINCT col0 + - tab1.col1 * col1 * - col1 AS col2 FROM tab1
----
1064
17579
2277

onlyif mysql # use DIV operator for integer division
query I rowsort label-5922
SELECT col0 + + col1 DIV + col0 - col1 * col2 AS col0 FROM tab0
----
-2811
-60
-7372

skipif mysql # not compatible
query I rowsort label-5922
SELECT col0 + + col1 / + col0 - col1 * col2 AS col0 FROM tab0
----
-2811
-60
-7372

query I rowsort
SELECT + col0 * + tab0.col0 + col2 AS col1 FROM tab0
----
1226
609
8003

query I rowsort
SELECT ALL + col2 + col1 + + col1 FROM tab0
----
195
205
264

query I rowsort
SELECT DISTINCT 29 AS col1 FROM tab2 AS cor0
----
29

onlyif mysql # use DIV operator for integer division
query I rowsort label-5926
SELECT ALL - 5 * col0 + cor0.col1 DIV - cor0.col1 AS col2 FROM tab0 AS cor0
----
-121
-176
-446

skipif mysql # not compatible
query I rowsort label-5926
SELECT ALL - 5 * col0 + cor0.col1 / - cor0.col1 AS col2 FROM tab0 AS cor0
----
-121
-176
-446

query I rowsort
SELECT - cor0.col1 * - ( + col2 ) + cor0.col0 FROM tab0 AS cor0
----
132
2862
7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 6 col1 FROM tab0
----
6

query I rowsort
SELECT - 83 + + col2 AS col2 FROM tab1
----
-26
-29
13

query I rowsort
SELECT ALL + col1 * - cor0.col0 + + col2 * col1 * + col1 AS col1 FROM tab2 AS cor0
----
25730
85904
9639

query I rowsort
SELECT ALL ( col1 ) * - col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT + ( col0 ) + - col2 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL - col2 + + col1 * col2 * col0 FROM tab0 WHERE col1 NOT IN ( - col0 + col2 )
----
3394
664036
68079

query I rowsort
SELECT col1 + + col1 * tab2.col2 FROM tab2
----
1593
663
868

query I rowsort
SELECT col1 + - col0 + col2 AS col0 FROM tab0
----
63
84
95

query I rowsort
SELECT DISTINCT - tab0.col1 * - col2 + - col2 AS col0 FROM tab0 WHERE NOT + col0 * - col0 * col2 NOT BETWEEN NULL AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + col0 * col2 col0 FROM tab0
----
70
7387
816

query I rowsort
SELECT DISTINCT cor0.col2 + cor0.col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT col0 * + col2 FROM tab2 AS cor0 WHERE col0 NOT BETWEEN col0 AND NULL
----

query I rowsort
SELECT DISTINCT + col0 * col2 + + col2 * + cor0.col0 * + col1 AS col1 FROM tab0 cor0
----
3430
671416
68904

query IIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 WHERE NULL >= ( NULL )
----

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE NOT NULL < ( NULL )
----

query I rowsort
SELECT + tab0.col0 + col2 - col1 AS col1 FROM tab0
----
-29
-61
80

query I rowsort
SELECT ALL - col1 AS col0 FROM tab0 WHERE NULL NOT IN ( + col1 + + col1 - tab0.col1 )
----

query I rowsort
SELECT ALL col1 * col1 + - col1 * tab1.col2 AS col0 FROM tab1
----
-1079
-470
-728

query I rowsort
SELECT + col1 * - col1 - - col2 AS col1 FROM tab2
----
-251
-3455
-934

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT - col1 + + col1 BETWEEN ( NULL ) AND ( col2 )
----

query I rowsort
SELECT DISTINCT col0 * - col2 * col0 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT - col2 + - col0 + col0 FROM tab2
----
-26
-27
-38

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( col0 ) NOT BETWEEN - col1 AND ( NULL )
----

query I rowsort
SELECT + + col0 * - cor0.col2 + - cor0.col2 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT - col0 * + col0 + cor0.col2 AS col1 FROM tab1 cor0
----
-4039
-6304
45

query I rowsort
SELECT DISTINCT + col0 * col2 + col2 AS col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT + - col2 + - col0 * col0 FROM tab1 AS cor0
----
-4153
-63
-6496

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE NULL < NULL OR ( NULL ) NOT IN ( + col1 * + col0 )
----

query I rowsort
SELECT DISTINCT + - col0 * + cor0.col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT + - col0 * col0 + - col1 FROM tab1 AS cor0
----
-35
-4106
-6413

query I rowsort
SELECT ALL - cor0.col0 + col2 AS col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT col1 * + col0 * + col1 + col2 FROM tab0 AS cor0
----
177537
329316
737091

onlyif mysql # use DIV operator for integer division
query I rowsort label-5960
SELECT ALL - - col2 DIV + col1 + + col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-5960
SELECT ALL - - col2 / + col1 + + col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL - - col2 * col0 + + col0 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-5962
SELECT DISTINCT + col1 + col0 DIV col1 FROM tab1 AS cor0
----
16
19
26

skipif mysql # not compatible
query I rowsort label-5962
SELECT DISTINCT + col1 + col0 / col1 FROM tab1 AS cor0
----
16
19
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * cor0.col2 * + col0 col1 FROM tab0 cor0
----
-1225
-19008
-649522

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE NULL IN ( + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5965
SELECT + col1 * col2 + col1 DIV + col1 AS col2 FROM tab2
----
1535
647
838

skipif mysql # not compatible
query I rowsort label-5965
SELECT + col1 * col2 + col1 / + col1 AS col2 FROM tab2
----
1535
647
838

query I rowsort
SELECT ALL + tab1.col2 * + col0 + + col0 + col1 * col0 AS col1 FROM tab1
----
243
4352
8800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5967
SELECT ALL - col0 * - CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5967
SELECT ALL - col0 * - CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 61 AS col2 FROM tab0
----
61
61
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 40 col0 FROM tab2 cor0
----
40
40
40

query I rowsort
SELECT ALL + cor0.col0 + 94 + col1 FROM tab0 AS cor0
----
204
226
274

query I rowsort
SELECT DISTINCT + 4 - + col2 FROM tab0 AS cor0
----
-29
-78
3

query I rowsort
SELECT ALL - - 37 AS col1 FROM tab0 AS cor0
----
37
37
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-5973
SELECT ALL + 24 * col1 * col2 + col1 DIV col1 AS col2 FROM tab0
----
179089
2329
68113

skipif mysql # not compatible
query I rowsort label-5973
SELECT ALL + 24 * col1 * col2 + col1 / col1 AS col2 FROM tab0
----
179089
2329
68113

query I rowsort
SELECT - cor0.col2 - 33 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e028dd25384b3af1d422a9d0a770120c

query I rowsort
SELECT - ( + col2 ) * - col1 AS col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT col1 * col2 * + ( col0 ) FROM tab2
----
119652
51034
5859

query I rowsort
SELECT - + cor0.col1 + cor0.col0 * col2 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5978
SELECT DISTINCT cor0.col2 * + CAST( + 47 + - col2 AS SIGNED ) * + CAST( NULL AS SIGNED ) AS col2 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5978
SELECT DISTINCT cor0.col2 * + CAST ( + 47 + - col2 AS INTEGER ) * + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5979
SELECT DISTINCT - + col1 * CAST( 56 AS SIGNED ) + col0 col2 FROM tab2 AS cor0
----
-1729
-3226
-873

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5979
SELECT DISTINCT - + col1 * CAST ( 56 AS INTEGER ) + col0 col2 FROM tab2 AS cor0
----
-1729
-3226
-873

query I rowsort
SELECT col1 + - 74 * col0 FROM tab1 cor0
----
-196
-4726
-5907

query I rowsort
SELECT - col1 * 93 AS col1 FROM tab2 AS cor0
----
-1581
-2883
-5487

query I rowsort
SELECT col2 + cor0.col2 * + col1 AS col0 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + col2 + col1 * - ( col1 ) FROM tab2 cor0
----
-251
-3455
-934

query I rowsort
SELECT - col0 * + ( - 24 * + col2 ) AS col1 FROM tab2 AS cor0
----
4536
48672
72048

onlyif mysql # use DIV operator for integer division
query I rowsort label-5985
SELECT + cor0.col0 DIV + col0 AS col2 FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5985
SELECT + cor0.col0 / + col0 AS col2 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT - + col1 + 6 FROM tab1 AS cor0
----
-20
-4
-7

query I rowsort
SELECT - cor0.col0 + 0 * - col2 * - col0 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT col2 * + ( + col1 ) AS col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT + 57 AS col2 FROM tab1, tab0 AS cor0
----
57

query I rowsort
SELECT + 92 * ( col0 + col1 ) AS col1 FROM tab1 AS cor0
----
2668
6808
8556

query I rowsort
SELECT DISTINCT - 60 + + col1 AS col0 FROM tab2 cor0
----
-1
-29
-43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * - col1 + + ( col1 ) * - cor0.col1 + + col1 col0 FROM tab0 AS cor0
----
-14706
-16471
-18721

query I rowsort
SELECT + cor0.col2 + col2 * cor0.col0 - 44 FROM tab1 cor0
----
172
3661
7732

query I rowsort
SELECT 48 + col1 - col1 AS col1 FROM tab0 AS cor0
----
48
48
48

query I rowsort
SELECT DISTINCT + 97 * + cor0.col1 FROM tab1 AS cor0
----
1261
2522
970

onlyif mysql # use DIV operator for integer division
query I rowsort label-5996
SELECT DISTINCT col2 + col1 DIV - col1 + col2 FROM tab0
----
1
163
65

skipif mysql # not compatible
query I rowsort label-5996
SELECT DISTINCT col2 + col1 / - col1 + col2 FROM tab0
----
1
163
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 71 * + col2 col0 FROM tab0
----
-2343
-5822
-71

onlyif mysql # use DIV operator for integer division
query I rowsort label-5998
SELECT ALL - col1 DIV tab1.col2 AS col0 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5998
SELECT ALL - col1 / tab1.col2 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT + 2 * col1 AS col2 FROM tab2
----
118
34
62

query I rowsort
SELECT - cor0.col2 * + col1 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6001
SELECT + col1 * - CAST( NULL AS SIGNED ) / col0 - + col0 * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6001
SELECT + col1 * - CAST ( NULL AS INTEGER ) / col0 - + col0 * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + ( col0 ) FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - - col0 * + col2 + cor0.col1 * + cor0.col0 FROM tab1 AS cor0
----
240
4288
8720

query I rowsort
SELECT + 11 * + col2 AS col0 FROM tab1
----
1056
594
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-6005
SELECT ( + col0 ) * 21 DIV + 65 FROM tab2 AS cor0
----
2
25
25

skipif mysql # not compatible
query I rowsort label-6005
SELECT ( + col0 ) * 21 / + 65 FROM tab2 AS cor0
----
2
25
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-6006
SELECT DISTINCT tab0.col2 DIV + col1 AS col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-6006
SELECT DISTINCT tab0.col2 / + col1 AS col1 FROM tab0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6007
SELECT DISTINCT + col2 * - col1 + + CAST( + col0 AS SIGNED ) DIV + col0 FROM tab0 AS cor0
----
-2837
-7461
-96

skipif mysql # not compatible
query I rowsort label-6007
SELECT DISTINCT + col2 * - col1 + + CAST ( + col0 AS INTEGER ) / + col0 FROM tab0 AS cor0
----
-2837
-7461
-96

query I rowsort
SELECT DISTINCT 2 * col0 + ( - col0 ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - cor0.col1 * + col0 FROM tab1 cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-6010
SELECT col0 DIV - 82 + - col1 + cor0.col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6010
SELECT col0 / - 82 + - col1 + cor0.col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT col0 * - col2 - + col0 AS col0 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT + + col0 * - col2 + - col2 - col0 FROM tab1 AS cor0
----
-219
-3769
-7856

query I rowsort
SELECT DISTINCT + col0 + + 27 * col1 AS col1 FROM tab1 AS cor0
----
334
431
705

query I rowsort
SELECT DISTINCT + col2 + + ( 78 ) AS col2 FROM tab1 AS cor0
----
132
135
174

query I rowsort
SELECT + col0 + col1 * + 71 FROM tab2
----
1286
2208
4267

query I rowsort
SELECT ALL col0 * col2 * col2 AS col0 FROM tab0
----
26136
35
598436

query I rowsort
SELECT DISTINCT + cor0.col1 + + col1 FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT ALL - ( 68 ) + - col1 FROM tab0 AS cor0
----
-154
-159
-165

query I rowsort
SELECT ALL + + 25 - - col1 * - col1 FROM tab2 AS cor0
----
-264
-3456
-936

query I rowsort
SELECT - col2 * cor0.col0 + - col2 FROM tab1 AS cor0
----
-216
-3705
-7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6021
SELECT - CAST( col0 AS SIGNED ) + col2 AS col2 FROM tab2 cor0
----
-41
-52
20

skipif mysql # not compatible
query I rowsort label-6021
SELECT - CAST ( col0 AS INTEGER ) + col2 AS col2 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT ALL - 33 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to bbc05afe7eb6fed16e9d75f7f74d1948

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 69 col2 FROM tab2, tab2 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to dfada1ee7a4e3e5c74a063a1282769f9

query I rowsort
SELECT + - col0 + col0 + col2 * col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-6025
SELECT DISTINCT cor1.col2 DIV 43 + + 47 FROM tab1, tab1 AS cor0, tab2 cor1
----
47

skipif mysql # not compatible
query I rowsort label-6025
SELECT DISTINCT cor1.col2 / 43 + + 47 FROM tab1, tab1 AS cor0, tab2 cor1
----
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-6026
SELECT - col2 DIV - 98 AS col0 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6026
SELECT - col2 / - 98 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT tab0.col2 + - col2 AS col1 FROM tab0
----
0

query I rowsort
SELECT col1 + 17 AS col0 FROM tab1
----
27
30
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 - col1 * + col1 col2 FROM tab2 AS cor0
----
-306
-3540
-992

query I rowsort
SELECT - tab1.col0 * tab1.col2 AS col1 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to 91af1085835c3ef572d2dbd91480f658

onlyif mysql # use DIV operator for integer division
query I rowsort label-6031
SELECT ALL - col0 DIV - cor0.col1 AS col2 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-6031
SELECT ALL - col0 / - cor0.col1 AS col2 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT ( col2 ) * + ( col0 ) FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT 30 - ( + col1 ) * ( col1 * + col0 ) FROM tab2
----
-22801
-271488
-6697

query I rowsort
SELECT ALL 18 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT DISTINCT tab1.col1 + col1 * col0 FROM tab1
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-6036
SELECT DISTINCT col2 DIV 85 + - col1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6036
SELECT DISTINCT col2 / 85 + - col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT 98 + col2 AS col0 FROM tab2
----
124
125
136

query I rowsort
SELECT DISTINCT ( cor0.col2 ) + col1 * - cor0.col0 + col1 FROM tab2 AS cor0
----
-1288
-159
-4517

onlyif mysql # use DIV operator for integer division
query I rowsort label-6039
SELECT ALL - 57 DIV - col0 - + 3 * 93 AS col2 FROM tab2 AS cor0
----
-271
-279
-279

skipif mysql # not compatible
query I rowsort label-6039
SELECT ALL - 57 / - col0 - + 3 * 93 AS col2 FROM tab2 AS cor0
----
-271
-279
-279

query I rowsort
SELECT DISTINCT - cor0.col1 * + col2 * + ( col0 ) AS col0 FROM tab2 AS cor0
----
-119652
-51034
-5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 81 col0 FROM tab1
----
81
81
81

query I rowsort
SELECT DISTINCT - 74 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
-74

query I rowsort
SELECT ALL - 58 * col0 AS col1 FROM tab2 AS cor0
----
-406
-4524
-4582

query I rowsort
SELECT ALL - 27 * col0 + col0 FROM tab2 AS cor0
----
-182
-2028
-2054

query I rowsort
SELECT DISTINCT - - 65 AS col2 FROM tab0 cor0
----
65

query I rowsort
SELECT ALL + 62 + col0 * + col1 * + col1 FROM tab1 AS cor0
----
13582
2090
6462

query I rowsort
SELECT ALL cor0.col2 + col2 * col0 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6048
SELECT + col1 + col0 * + CAST( - col0 AS SIGNED ) * - col0 FROM tab2 AS cor0
----
374
474611
493056

skipif mysql # not compatible
query I rowsort label-6048
SELECT + col1 + col0 * + CAST ( - col0 AS INTEGER ) * - col0 FROM tab2 AS cor0
----
374
474611
493056

query I rowsort
SELECT ALL ( col1 ) * - col0 - - col2 FROM tab1 AS cor0
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-6050
SELECT ALL + 26 * + col1 - col1 DIV col0 AS col0 FROM tab2 AS cor0
----
1534
442
802

skipif mysql # not compatible
query I rowsort label-6050
SELECT ALL + 26 * + col1 - col1 / col0 AS col0 FROM tab2 AS cor0
----
1534
442
802

query I rowsort
SELECT col2 * - col1 * cor0.col1 AS col1 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT col1 * - col0 * + cor0.col0 + col2 AS col0 FROM tab1 cor0
----
-180
-40903
-83104

query I rowsort
SELECT ALL col2 + - col1 + col2 * + col2 FROM tab1
----
2944
3296
9299

query I rowsort
SELECT + + cor0.col1 + - 1 AS col2 FROM tab0 AS cor0
----
85
90
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6055
SELECT - col2 + 18 DIV - col0 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-6055
SELECT - col2 + 18 / - col0 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6056
SELECT DISTINCT 94 DIV - col1 FROM tab1 AS cor0
----
-3
-7
-9

skipif mysql # not compatible
query I rowsort label-6056
SELECT DISTINCT 94 / - col1 FROM tab1 AS cor0
----
-3
-7
-9

query I rowsort
SELECT DISTINCT 40 * + col1 - - col0 FROM tab2 AS cor0
----
1247
2438
759

query I rowsort
SELECT DISTINCT col1 - 84 AS col2 FROM tab1
----
-58
-71
-74

query I rowsort
SELECT DISTINCT + col1 * cor0.col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + 67 AS col0 FROM tab1, tab0 AS cor0
----
67

query I rowsort
SELECT + 27 + 75 AS col1 FROM tab0 AS cor0
----
102
102
102

query I rowsort
SELECT col1 + + 28 * + 51 FROM tab0 AS cor0
----
1514
1519
1525

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * + col1 * + 88 col1 FROM tab2 cor0
----
-25432
-306328
-84568

query I rowsort
SELECT DISTINCT cor0.col0 + + col0 AS col1 FROM tab0 cor0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - 3 * - col2 col0 FROM tab0 AS cor0
----
132
328
4

query I rowsort
SELECT col2 * - col0 + 21 FROM tab2
----
-168
-2007
-2981

query I rowsort
SELECT DISTINCT - 74 + col2 AS col1 FROM tab2
----
-36
-47
-48

query I rowsort
SELECT col2 * + tab0.col1 + col0 + ( + col0 ) * ( col0 ) AS col1 FROM tab0
----
1357
15472
3438

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6069
SELECT - 31 * col0 * CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6069
SELECT - 31 * col0 * CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6070
SELECT - col1 * col1 + 58 DIV + col0 AS col2 FROM tab2 AS cor0
----
-289
-3481
-953

skipif mysql # not compatible
query I rowsort label-6070
SELECT - col1 * col1 + 58 / + col0 AS col2 FROM tab2 AS cor0
----
-289
-3481
-953

onlyif mysql # use DIV operator for integer division
query I rowsort label-6071
SELECT DISTINCT + col0 * 98 DIV + 2 FROM tab1
----
147
3136
3920

skipif mysql # not compatible
query I rowsort label-6071
SELECT DISTINCT + col0 * 98 / + 2 FROM tab1
----
147
3136
3920

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2, tab2 cor2
----
3645 values hashing to 5a114c3d024b82b28eeddb04849c8215

query I rowsort
SELECT + ( + col1 ) + col0 * - 50 AS col2 FROM tab1 AS cor0
----
-124
-3190
-3987

query I rowsort
SELECT ALL - col0 * - col1 AS col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT - col2 * - 59 + col2 + + col0 AS col0 FROM tab0 AS cor0
----
2004
5009
95

query I rowsort
SELECT DISTINCT - col0 + 0 * - col0 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6077
SELECT DISTINCT col1 DIV - col1 col2 FROM tab2 AS cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6077
SELECT DISTINCT col1 / - col1 col2 FROM tab2 AS cor0
----
-1

query I rowsort
SELECT - col2 * ( ( - col1 ) + + col2 ) AS col1 FROM tab0 AS cor0
----
1749
738
96

query I rowsort
SELECT 38 * + cor0.col2 + + 95 AS col0 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 238a2e8d6e886f1e0a92e12c7b935856

query I rowsort
SELECT DISTINCT col1 * 32 * col2 FROM tab2
----
20672
26784
49088

query I rowsort
SELECT ALL - tab1.col0 * + col1 + col1 - + col2 * - col1 FROM tab1
----
-60
1352
221

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) NOT IN ( + col1 )
----

query I rowsort
SELECT DISTINCT col2 * + tab0.col2 AS col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT - + 90 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to f6f26b9a04da14807208b93d507095c5

query I rowsort
SELECT DISTINCT col2 * col1 + + tab0.col1 FROM tab0
----
194
2924
7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * tab2.col1 * col0 col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT DISTINCT tab2.col1 FROM tab2 WHERE NULL IN ( + col1 )
----

query I rowsort
SELECT ALL col0 FROM tab0 WHERE NULL <> ( col1 )
----

query I rowsort
SELECT + col1 * tab2.col0 * - tab2.col1 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT - - 98 * - col0 + ( + col0 ) FROM tab1 cor0
----
-291
-6208
-7760

query I rowsort
SELECT DISTINCT - ( col0 ) + + col1 * - col1 + + tab2.col2 FROM tab2
----
-330
-3533
-941

query I rowsort
SELECT tab1.col1 * col1 * col1 + col2 AS col1 FROM tab1
----
1057
17630
2293

query I rowsort
SELECT DISTINCT 91 + col0 * + col1 AS col0 FROM tab0 AS cor0
----
2155
3486
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-6094
SELECT col0 DIV + col1 + + cor0.col1 AS col1 FROM tab1 AS cor0
----
16
19
26

skipif mysql # not compatible
query I rowsort label-6094
SELECT col0 / + col1 + + cor0.col1 AS col1 FROM tab1 AS cor0
----
16
19
26

query I rowsort
SELECT DISTINCT ( + col2 ) + - cor0.col2 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - ( + col1 ) + + col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 * + col2 * + col2 FROM tab0
----
611884
93654
97

query I rowsort
SELECT + - 78 - col2 FROM tab1 AS cor0
----
-132
-135
-174

query I rowsort
SELECT - col1 * cor0.col1 + + col1 AS col2 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT ALL - 10 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

query I rowsort
SELECT ALL + col2 * + col2 + + ( col0 * col0 ) AS col0 FROM tab2
----
6760
7685
778

onlyif mysql # use DIV operator for integer division
query I rowsort label-6102
SELECT - col1 + ( - 24 ) DIV col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6102
SELECT - col1 + ( - 24 ) / col1 AS col0 FROM tab0 AS cor0
----
-86
-91
-97

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 cor0, tab2 AS cor1, tab0 AS cor2
----
972 values hashing to 58757c5bbbd4217c03cf2ac0b6126e55

query I rowsort
SELECT ALL + 14 * - cor0.col1 + col1 AS col2 FROM tab1 AS cor0
----
-130
-169
-338

query I rowsort
SELECT ALL tab2.col0 * - col2 AS col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - ( + col2 * + col0 ) FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ALL 82 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

query I rowsort
SELECT + - ( - 43 ) FROM tab1 AS cor0
----
43
43
43

query I rowsort
SELECT - + 0 * - col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + - cor0.col1 * + col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - + col1 * col1 + cor0.col0 * + col1 FROM tab2 AS cor0
----
-744
1054
1121

onlyif mysql # use DIV operator for integer division
query I rowsort label-6112
SELECT + 39 + col0 DIV + col2 FROM tab1 AS cor0
----
39
39
40

skipif mysql # not compatible
query I rowsort label-6112
SELECT + 39 + col0 / + col2 FROM tab1 AS cor0
----
39
39
40

query I rowsort
SELECT ( cor0.col0 ) + - col2 * - col1 + col1 AS col0 FROM tab2 AS cor0
----
1671
742
875

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) AS col0 FROM tab1, tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL 28 * col0 AS col1 FROM tab2
----
196
2184
2212

query I rowsort
SELECT ALL + ( + 62 * + col0 + + col0 ) FROM tab0
----
1512
2205
5607

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6117
SELECT + col2 * CAST( col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-6117
SELECT + col2 * CAST ( col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + col2 + - col1 col0 FROM tab1 AS cor0
----
1235
1378
560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 84 + col0 * col1 col0 FROM tab1 AS cor0
----
-6
556
956

query I rowsort
SELECT - 93 * 82 FROM tab0 AS cor0
----
-7626
-7626
-7626

query I rowsort
SELECT DISTINCT + ( - 99 ) * col2 + - cor0.col0 * - 11 + col1 FROM tab1 AS cor0
----
-4929
-5287
-8611

onlyif mysql # use DIV operator for integer division
query I rowsort label-6122
SELECT DISTINCT col1 DIV col1 + + col1 AS col2 FROM tab0 cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-6122
SELECT DISTINCT col1 / col1 + + col1 AS col2 FROM tab0 cor0
----
87
92
98

query I rowsort
SELECT ( - ( col0 ) ) FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT ALL cor0.col2 * - col0 + + col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT - col2 * 12 AS col1 FROM tab0 AS cor0
----
-12
-396
-984

query I rowsort
SELECT ALL 78 + col2 AS col0 FROM tab0 AS cor0
----
111
160
79

query I rowsort
SELECT ALL - + cor0.col0 * col1 - col2 * - 3 AS col1 FROM tab2 cor0
----
-1229
-136
-4524

query I rowsort
SELECT - col1 * 83 AS col1 FROM tab0 AS cor0
----
-7138
-7553
-8051

query I rowsort
SELECT ALL + cor0.col1 + + col0 * + cor0.col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT + col1 + - col0 * + 53 FROM tab2 AS cor0
----
-340
-4075
-4170

query I rowsort
SELECT - 89 + - col1 * 27 FROM tab2
----
-1682
-548
-926

query I rowsort
SELECT ALL col1 + + col0 AS col0 FROM tab2
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6133
SELECT ALL + col1 + - col2 * CAST( col1 AS SIGNED ) AS col1 FROM tab2
----
-1475
-629
-806

skipif mysql # not compatible
query I rowsort label-6133
SELECT ALL + col1 + - col2 * CAST ( col1 AS INTEGER ) AS col1 FROM tab2
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-6134
SELECT + ( - col0 ) DIV + cor0.col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6134
SELECT + ( - col0 ) / + cor0.col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6135
SELECT ALL CAST( NULL AS SIGNED ) AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6135
SELECT ALL CAST ( NULL AS INTEGER ) AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + 78 * - col0 AS col1 FROM tab0 AS cor0
----
-1872
-2730
-6942

query I rowsort
SELECT ALL + col1 * 50 FROM tab0 AS cor0
----
4300
4550
4850

query I rowsort
SELECT + col0 + 57 AS col2 FROM tab2 AS cor0
----
135
136
64

query I rowsort
SELECT DISTINCT + col2 + cor0.col2 * - cor0.col1 AS col1 FROM tab2 cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL tab2.col0 * - col0 FROM tab2
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * cor0.col0 + + ( + col0 ) col1 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT - + col0 * - ( + col2 ) AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT col1 - - col1 * - col2 AS col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT + + col1 + - 33 AS col1 FROM tab2 AS cor0
----
-16
-2
26

query I rowsort
SELECT ALL - col1 * col1 + 37 * col0 AS col2 FROM tab1 AS cor0
----
-565
2268
2791

query I rowsort
SELECT cor0.col1 * + col0 + col0 FROM tab1 cor0
----
1120
704
81

query I rowsort
SELECT DISTINCT col0 * - col2 - + col2 * - col0 FROM tab2 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6148
SELECT DISTINCT tab1.col2 DIV - tab1.col1 col2 FROM tab1
----
-2
-5
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6148
SELECT DISTINCT tab1.col2 / - tab1.col1 col2 FROM tab1
----
-2
-5
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6149
SELECT ALL col1 DIV - col1 + col2 FROM tab2
----
25
26
37

skipif mysql # not compatible
query I rowsort label-6149
SELECT ALL col1 / - col1 + col2 FROM tab2
----
25
26
37

query I rowsort
SELECT ALL ( + col0 * + 39 ) AS col0 FROM tab0
----
1365
3471
936

query I rowsort
SELECT ALL 30 * + col0 AS col1 FROM tab2
----
210
2340
2370

query I rowsort
SELECT 45 * 72 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 9a6d07112855e91d3a628e2f3335efac

query I rowsort
SELECT ALL + - col1 * - ( - col2 ) AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + col2 + 24 * col2 AS col2 FROM tab1 cor0
----
1350
1425
2400

query I rowsort
SELECT + col1 * col2 + - 34 FROM tab2 AS cor0
----
1500
612
803

onlyif mysql # use DIV operator for integer division
query I rowsort label-6156
SELECT 35 DIV - col0 + - 7 AS col2 FROM tab0
----
-7
-8
-8

skipif mysql # not compatible
query I rowsort label-6156
SELECT 35 / - col0 + - 7 AS col2 FROM tab0
----
-7
-8
-8

query I rowsort
SELECT tab1.col1 - + ( ( - col0 ) ) * col0 * tab1.col1 FROM tab1
----
260
40970
83213

query I rowsort
SELECT + tab1.col2 * - 95 * + col1 + col0 FROM tab1
----
-118480
-133377
-54086

query I rowsort
SELECT DISTINCT col2 * col0 + col0 + + col0 * + ( + ( tab0.col0 ) ) FROM tab0
----
1295
1392
15308

query I rowsort
SELECT + 87 * col2 * + col1 FROM tab2 AS cor0
----
133458
56202
72819

query I rowsort
SELECT + col2 + 36 FROM tab1 AS cor0
----
132
90
93

query I rowsort
SELECT DISTINCT 87 AS col1 FROM tab0, tab1 cor0
----
87

query I rowsort
SELECT - col0 + ( col1 ) FROM tab1
----
-54
-67
23

query I rowsort
SELECT + col1 * + col1 + col1 AS col1 FROM tab1
----
110
182
702

query I rowsort
SELECT DISTINCT + tab1.col1 * 34 + tab1.col1 * + col0 AS col1 FROM tab1
----
1482
962
980

query I rowsort
SELECT col0 * + col2 + + col0 AS col1 FROM tab1
----
165
3712
7760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6167
SELECT DISTINCT - + col1 + - col1 * CAST( - col1 AS SIGNED ) + - col1 * + 33 * - ( + col0 ) FROM tab1 AS cor0
----
21210
3224
34476

skipif mysql # not compatible
query I rowsort label-6167
SELECT DISTINCT - + col1 + - col1 * CAST ( - col1 AS INTEGER ) + - col1 * + 33 * - ( + col0 ) FROM tab1 AS cor0
----
21210
3224
34476

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col1 ) * + col0 - - tab0.col1 col1 FROM tab0
----
-1978
-3298
-8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-6169
SELECT ALL + 88 DIV col0 + 17 AS col1 FROM tab1 AS cor0
----
18
18
46

skipif mysql # not compatible
query I rowsort label-6169
SELECT ALL + 88 / col0 + 17 AS col1 FROM tab1 AS cor0
----
18
18
46

query I rowsort
SELECT 46 * col1 FROM tab1 AS cor0
----
1196
460
598

onlyif mysql # use DIV operator for integer division
query I rowsort label-6171
SELECT DISTINCT + col1 DIV col0 + col1 * + ( col1 * 31 ) + + col2 AS col2 FROM tab0 AS cor0
----
229312
256794
291682

skipif mysql # not compatible
query I rowsort label-6171
SELECT DISTINCT + col1 / col0 + col1 * + ( col1 * 31 ) + + col2 AS col2 FROM tab0 AS cor0
----
229312
256794
291682

onlyif mysql # use DIV operator for integer division
query I rowsort label-6172
SELECT ALL 29 DIV - col0 AS col2 FROM tab2
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-6172
SELECT ALL 29 / - col0 AS col2 FROM tab2
----
-4
0
0

query I rowsort
SELECT + ( ( - col1 ) ) * col2 + - col0 AS col2 FROM tab1
----
-1328
-1407
-634

query I rowsort
SELECT ALL + ( tab0.col1 ) + + tab0.col1 AS col0 FROM tab0
----
172
182
194

query I rowsort
SELECT DISTINCT - 46 * - col0 AS col2 FROM tab1 AS cor0
----
138
2944
3680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6176
SELECT - col0 DIV col0 + ( col2 ) * col0 AS col1 FROM tab1 AS cor0
----
161
3647
7679

skipif mysql # not compatible
query I rowsort label-6176
SELECT - col0 / col0 + ( col2 ) * col0 AS col1 FROM tab1 AS cor0
----
161
3647
7679

query I rowsort
SELECT ALL + 50 * cor0.col1 FROM tab0 AS cor0
----
4300
4550
4850

query I rowsort
SELECT ALL col0 + + cor0.col2 * + col0 + + col2 FROM tab1 AS cor0
----
219
3769
7856

query I rowsort
SELECT DISTINCT + + 38 AS col1 FROM tab2 AS cor0
----
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6180
SELECT col2 * col2 + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6180
SELECT col2 * col2 + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 * + col2 + col2 * col0 + col1 * 94 FROM tab0 AS cor0
----
23150
9188
9668

onlyif mysql # use DIV operator for integer division
query I rowsort label-6182
SELECT ALL + + col2 DIV col1 + col0 * - col1 * col0 col2 FROM tab1 AS cor0
----
-232
-40955
-83193

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6182
SELECT ALL + + col2 / col1 + col0 * - col1 * col0 col2 FROM tab1 AS cor0
----
-232
-40955
-83193

query I rowsort
SELECT - tab0.col2 * + ( col1 ) AS col0 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT - ( - 24 ) * col2 FROM tab2
----
624
648
912

query I rowsort
SELECT - ( 17 + - col2 * ( - col1 ) ) AS col2 FROM tab0
----
-114
-2855
-7479

query I rowsort
SELECT - ( - ( col2 ) ) * + tab2.col1 * - col0 AS col1 FROM tab2
----
-119652
-51034
-5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col2 ) - + cor0.col2 col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL col0 + - 18 AS col2 FROM tab2 AS cor0
----
-11
60
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 76 + - 82 + - col1 col0 FROM tab2 AS cor0
----
-175
-189
-217

query I rowsort
SELECT - 42 + - col1 FROM tab2 AS cor0
----
-101
-59
-73

query I rowsort
SELECT - 92 + - col0 AS col0 FROM tab0 cor0
----
-116
-127
-181

query I rowsort
SELECT - - cor0.col2 * + col0 * - col0 + col1 FROM tab0 AS cor0
----
-1128
-18922
-649431

query I rowsort
SELECT col2 + - col0 * col1 AS col2 FROM tab0 cor0
----
-2031
-3394
-8017

query I rowsort
SELECT col2 * - col0 + + 90 * - col0 FROM tab0 AS cor0
----
-15308
-2952
-3185

query I rowsort
SELECT - ( 57 ) + col2 FROM tab0
----
-24
-56
25

query I rowsort
SELECT DISTINCT 37 * + ( - col2 ) + - col1 AS col1 FROM tab2
----
-1021
-1030
-1423

query I rowsort
SELECT - ( + col1 ) * col0 + cor0.col2 * - cor0.col2 + 35 AS col0 FROM tab2 AS cor0
----
-2752
-5243
-911

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * ( + col2 ) col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + cor0.col0 * 47 AS col1 FROM tab1 AS cor0
----
141
3008
3760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6200
SELECT DISTINCT + cor0.col2 * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6200
SELECT DISTINCT + cor0.col2 * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6201
SELECT - - col2 * + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6201
SELECT - - col2 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col0 * - ( col1 ) FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT col1 + col1 * col1 * col2 AS col0 FROM tab1 AS cor0
----
16237
36530
5710

query I rowsort
SELECT DISTINCT - col0 + - 47 AS col2 FROM tab1
----
-111
-127
-50

query I rowsort
SELECT + col1 * col1 - col0 * - col0 AS col1 FROM tab1 AS cor0
----
4196
6569
685

query I rowsort
SELECT - col1 - - 35 FROM tab2 AS cor0
----
-24
18
4

query I rowsort
SELECT DISTINCT + col2 * - col0 * - col0 + - col2 AS col1 FROM tab1
----
233415
432
614304

query I rowsort
SELECT + col1 * col1 + - col2 * + col2 AS col0 FROM tab1
----
-2240
-3149
-9047

query I rowsort
SELECT + + 68 AS col2 FROM tab1 AS cor0
----
68
68
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6210
SELECT ALL CAST( NULL AS SIGNED ) + col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6210
SELECT ALL CAST ( NULL AS INTEGER ) + col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col2 * - 2 * + col2 AS col1 FROM tab0 AS cor0
----
-13448
-2
-2178

query I rowsort
SELECT ALL + cor0.col1 + + 90 * + col1 * 55 FROM tab1 cor0
----
128726
49510
64363

query I rowsort
SELECT ALL ( - 76 + + col0 ) FROM tab0
----
-41
-52
13

query I rowsort
SELECT + 25 * ( + col1 * - col1 ) AS col0 FROM tab1 cor0
----
-16900
-2500
-4225

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6215
SELECT DISTINCT - col0 * + col0 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-6215
SELECT DISTINCT - col0 * + col0 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6216
SELECT - CAST( 21 AS SIGNED ) AS col1 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 631fbd1fd929405aba54a22c2a06c757

skipif mysql # not compatible
query I rowsort label-6216
SELECT - CAST ( 21 AS INTEGER ) AS col1 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 631fbd1fd929405aba54a22c2a06c757

query I rowsort
SELECT DISTINCT - - 83 + + col1 + 21 * + col1 * col0 AS col0 FROM tab0 AS cor0
----
170253
43513
71475

query I rowsort
SELECT cor0.col1 * col0 + ( col1 ) * col2 FROM tab1 cor0
----
1210
1482
2288

query I rowsort
SELECT col2 - tab0.col2 * 91 AS col2 FROM tab0
----
-2970
-7380
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + col2 col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT DISTINCT - 13 AS col2 FROM tab2
----
-13

query I rowsort
SELECT ALL + 43 AS col0 FROM tab0, tab2 AS cor0 CROSS JOIN tab2
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6223
SELECT DISTINCT + col1 DIV cor0.col2 + 3 + col1 FROM tab0 AS cor0
----
197
91
95

skipif mysql # not compatible
query I rowsort label-6223
SELECT DISTINCT + col1 / cor0.col2 + 3 + col1 FROM tab0 AS cor0
----
197
91
95

query I rowsort
SELECT DISTINCT - col1 * 94 + - col1 AS col1 FROM tab1
----
-1235
-2470
-950

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 cor0 CROSS JOIN tab1, tab2 cor1
----
972 values hashing to e610acd60f342127e6cdba18673d9f0e

onlyif mysql # use DIV operator for integer division
query I rowsort label-6226
SELECT col0 DIV - ( col2 ) - - 87 FROM tab1
----
86
87
87

skipif mysql # not compatible
query I rowsort label-6226
SELECT col0 / - ( col2 ) - - 87 FROM tab1
----
86
87
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6227
SELECT - col1 + - col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6227
SELECT - col1 + - col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 + - col2 col0 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6229
SELECT col2 DIV + col2 - - col2 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-6229
SELECT col2 / + col2 - - col2 FROM tab0
----
2
34
83

query I rowsort
SELECT - col1 * col2 + + 84 AS col0 FROM tab1
----
-1164
-1320
-486

query I rowsort
SELECT DISTINCT col1 * - tab2.col1 + col0 * + col2 FROM tab2
----
-1453
-772
2713

onlyif mysql # use DIV operator for integer division
query I rowsort label-6232
SELECT - col1 + col0 DIV 29 FROM tab0
----
-86
-88
-96

skipif mysql # not compatible
query I rowsort label-6232
SELECT - col1 + col0 / 29 FROM tab0
----
-86
-88
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6233
SELECT col0 DIV - col2 + + cor0.col2 * + cor0.col0 FROM tab0 AS cor0
----
0
7297
792

skipif mysql # not compatible
query I rowsort label-6233
SELECT col0 / - col2 + + cor0.col2 * + cor0.col0 FROM tab0 AS cor0
----
0
7297
792

query I rowsort
SELECT + 85 + + col0 AS col1 FROM tab1 AS cor0
----
149
165
88

query I rowsort
SELECT DISTINCT - 20 + - 40 AS col1 FROM tab0, tab0 cor0
----
-60

query I rowsort
SELECT ALL 47 + cor0.col0 * - col2 * 26 FROM tab0 AS cor0
----
-189701
-20545
-863

query I rowsort
SELECT + col2 * col1 - col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT DISTINCT + col2 - 69 FROM tab2 AS cor0
----
-31
-42
-43

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 - col0 * + ( col1 * + col0 ) col1 FROM tab2
----
-106097
-1519
-358956

query I rowsort
SELECT ALL ( col0 ) * - col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT col0 - - 84 FROM tab2 AS cor0
----
162
163
91

query I rowsort
SELECT ALL + col2 + + col2 * + col1 AS col1 FROM tab2 cor0
----
1560
684
864

query I rowsort
SELECT - col2 * + cor0.col2 + col2 AS col0 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT + + 23 * - 6 * - col2 + + 51 * - col0 + col1 * cor0.col2 FROM tab2 AS cor0
----
1144
1861
4206

query I rowsort
SELECT ALL - + cor0.col0 + - 34 FROM tab2 AS cor0
----
-112
-113
-41

onlyif mysql # use DIV operator for integer division
query I rowsort label-6247
SELECT DISTINCT + + col0 DIV col0 AS col0 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-6247
SELECT DISTINCT + + col0 / col0 AS col0 FROM tab1 AS cor0
----
1

query I rowsort
SELECT - - 24 * ( - col0 ) + col0 + 30 FROM tab0 AS cor0
----
-2017
-522
-775

query I rowsort
SELECT ALL - 69 * col1 * col0 FROM tab1 AS cor0
----
-44160
-5382
-71760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6250
SELECT CAST( - 21 AS SIGNED ) + - col1 col0 FROM tab1
----
-31
-34
-47

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6250
SELECT CAST ( - 21 AS INTEGER ) + - col1 col0 FROM tab1
----
-31
-34
-47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( tab0.col2 ) + col2 col1 FROM tab0
----
164
2
66

query I rowsort
SELECT DISTINCT + 27 + - col1 * - col2 FROM tab0
----
124
2865
7489

query I rowsort
SELECT col1 * 28 * + col1 FROM tab1
----
18928
2800
4732

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 22 col2 FROM tab2 AS cor0
----
-22
-22
-22

query I rowsort
SELECT ALL + + ( + ( col2 ) ) AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - 59 - - col0 FROM tab1 AS cor0
----
-56
21
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-6257
SELECT ALL + - col0 DIV cor0.col0 AS col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6257
SELECT ALL + - col0 / cor0.col0 AS col1 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - - col1 + + 37 * col2 FROM tab2 AS cor0
----
1021
1030
1423

query I rowsort
SELECT DISTINCT - - col1 * col1 * col1 AS col0 FROM tab2 cor0
----
205379
29791
4913

query I rowsort
SELECT + - ( - col2 ) AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + cor0.col0 + col0 * 25 AS col1 FROM tab2 AS cor0
----
182
2028
2054

query I rowsort
SELECT DISTINCT col1 - - col0 AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - + col1 * + col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT + col0 + + col0 * 57 FROM tab0 AS cor0
----
1392
2030
5162

query I rowsort
SELECT ALL - 29 * col0 AS col1 FROM tab0 AS cor0
----
-1015
-2581
-696

query I rowsort
SELECT DISTINCT col0 + + col2 * - col2 AS col2 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT + + 39 * + col1 + 5 AS col1 FROM tab0 AS cor0
----
3359
3554
3788

onlyif mysql # use DIV operator for integer division
query I rowsort label-6268
SELECT ALL ( - col2 ) + col2 DIV col1 AS col1 FROM tab2
----
-26
-27
-36

skipif mysql # not compatible
query I rowsort label-6268
SELECT ALL ( - col2 ) + col2 / col1 AS col1 FROM tab2
----
-26
-27
-36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 87 + 55 + col1 col0 FROM tab1
----
152
155
168

query I rowsort
SELECT col2 * + col0 + + col0 AS col2 FROM tab2
----
196
2106
3081

query I rowsort
SELECT cor1.col2 * cor1.col2 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to f2f8e77c5ad4f2e8fce9fd33f828ee72

query I rowsort
SELECT ALL 88 * + cor0.col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to f2bf9d2afb953e8f39da3489bde82ce7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6273
SELECT ALL + col2 * - CAST( NULL AS SIGNED ) + - 3 * + col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6273
SELECT ALL + col2 * - CAST ( NULL AS INTEGER ) + - 3 * + col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * + ( 77 ) + - col0 AS col2 FROM tab0 AS cor0
----
-112
-2565
-6403

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + col0 * col0 col2 FROM tab1 AS cor0
----
4032
6
6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6276
SELECT + col1 * CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
-7396
-8281
-9409

skipif mysql # not compatible
query I rowsort label-6276
SELECT + col1 * CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
-7396
-8281
-9409

skipif mysql # not compatible
query I rowsort
SELECT ALL + - col2 * + CAST ( - col2 AS REAL ) FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL - col0 + 60 * 5 FROM tab1 AS cor0
----
220
236
297

query I rowsort
SELECT ALL 25 * col0 * 85 AS col1 FROM tab1
----
136000
170000
6375

query I rowsort
SELECT DISTINCT + cor0.col1 * - 34 AS col2 FROM tab1, tab2 AS cor0
----
-1054
-2006
-578

query I rowsort
SELECT ALL + col2 + + col0 AS col0 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT ( col1 ) + + ( + 19 ) + - col2 AS col2 FROM tab1
----
-28
-64
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 + col1 col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + cor0.col0 * - 80 + + col2 AS col2 FROM tab1 cor0
----
-186
-5063
-6304

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6285
SELECT ALL col2 * + CAST( 29 AS SIGNED ) FROM tab2 AS cor0
----
1102
754
783

skipif mysql # not compatible
query I rowsort label-6285
SELECT ALL col2 * + CAST ( 29 AS INTEGER ) FROM tab2 AS cor0
----
1102
754
783

query I rowsort
SELECT DISTINCT + col0 + 88 * + col0 AS col1 FROM tab0 AS cor0
----
2136
3115
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 76 col1 FROM tab1 cor0
----
76
76
76

query I rowsort
SELECT ALL - 11 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 05cc989122d7724c7abefaba9625ef3d

query I rowsort
SELECT ALL + cor0.col2 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT col2 + - 56 * - 3 FROM tab1 AS cor0
----
222
225
264

query I rowsort
SELECT DISTINCT + cor0.col1 * 86 AS col2 FROM tab2 cor0
----
1462
2666
5074

onlyif mysql # use DIV operator for integer division
query I rowsort label-6292
SELECT tab1.col1 - + col1 DIV + ( + col1 ) col0 FROM tab1
----
12
25
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6292
SELECT tab1.col1 - + col1 / + ( + col1 ) col0 FROM tab1
----
12
25
9

query I rowsort
SELECT 20 AS col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col1 col2 FROM tab0, tab1, tab2 AS cor0
----
86
91
97

query I rowsort
SELECT - col2 + - col2 * 91 FROM tab0 AS cor0
----
-3036
-7544
-92

query IIIIIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab1, tab0 AS cor2, tab0 AS cor3
----
13122 values hashing to 8718ce71186c0fb3b188ed4f5cf992d1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6297
SELECT ALL + col0 * CAST( col1 AS SIGNED ) FROM tab2 cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-6297
SELECT ALL + col0 * CAST ( col1 AS INTEGER ) FROM tab2 cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6298
SELECT ALL cor0.col0 DIV 38 + + col0 AS col2 FROM tab1 AS cor0
----
3
65
82

skipif mysql # not compatible
query I rowsort label-6298
SELECT ALL cor0.col0 / 38 + + col0 AS col2 FROM tab1 AS cor0
----
3
65
82

query I rowsort
SELECT DISTINCT + + col0 * + col1 + cor0.col0 AS col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT DISTINCT col0 * - col0 + col2 AS col2 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT col0 + - ( + 28 ) * cor0.col1 FROM tab2 AS cor0
----
-1574
-397
-861

query I rowsort
SELECT - cor0.col0 * 63 + - 37 * + col2 FROM tab1 cor0
----
-2187
-6141
-8592

query I rowsort
SELECT cor0.col0 - 40 AS col2 FROM tab2 AS cor0
----
-33
38
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-6304
SELECT - col2 * - col1 * + col0 - col1 DIV 78 AS col2 FROM tab0 cor0
----
3394
664117
68111

skipif mysql # not compatible
query I rowsort label-6304
SELECT - col2 * - col1 * + col0 - col1 / 78 AS col2 FROM tab0 cor0
----
3394
664117
68111

query I rowsort
SELECT - - col1 + - ( 54 ) AS col0 FROM tab2 AS cor0
----
-23
-37
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-6306
SELECT + col0 DIV col1 - col2 * col0 * + col2 AS col1 FROM tab1 AS cor0
----
-207930
-737274
-8748

skipif mysql # not compatible
query I rowsort label-6306
SELECT + col0 / col1 - col2 * col0 * + col2 AS col1 FROM tab1 AS cor0
----
-207930
-737274
-8748

query I rowsort
SELECT DISTINCT - 89 FROM tab1, tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
-89

query I rowsort
SELECT + 10 * - cor0.col0 FROM tab2 AS cor0
----
-70
-780
-790

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6309
SELECT DISTINCT + 70 + + col0 * col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6309
SELECT DISTINCT + 70 + + col0 * col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + + cor0.col0 AS col1 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6311
SELECT + col0 + 44 * col1 * CAST( col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
325448
364453
414031

skipif mysql # not compatible
query I rowsort label-6311
SELECT + col0 + 44 * col1 * CAST ( col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
325448
364453
414031

query I rowsort
SELECT DISTINCT + col1 * + col1 * col2 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT + ( - 23 ) + col1 * - col1 FROM tab1 AS cor0
----
-123
-192
-699

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6314
SELECT + + CAST( NULL AS SIGNED ) + + 11 / + col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6314
SELECT + + CAST ( NULL AS INTEGER ) + + 11 / + col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + ( ( + col0 ) ) AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT 89 * ( col0 ) AS col1 FROM tab2 AS cor0
----
623
6942
7031

query I rowsort
SELECT ALL 6 * col2 AS col0 FROM tab1 AS cor0
----
324
342
576

query I rowsort
SELECT + 91 * + col1 FROM tab0 AS cor0
----
7826
8281
8827

query I rowsort
SELECT ALL - 37 + col2 AS col0 FROM tab2 cor0
----
-10
-11
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6320
SELECT - CAST( NULL AS SIGNED ) / col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6320
SELECT - CAST ( NULL AS INTEGER ) / col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + col1 * + ( ( col0 ) ) FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL col2 + col2 + - 56 * col2 * col1 FROM tab2 AS cor0
----
-36100
-46818
-85852

query I rowsort
SELECT ( - col1 ) * 67 FROM tab0 AS cor0
----
-5762
-6097
-6499

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6324
SELECT - CAST( NULL AS SIGNED ) AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6324
SELECT - CAST ( NULL AS INTEGER ) AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - - cor0.col1 * - col0 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - 41 * - col1 AS col1 FROM tab2 AS cor0
----
1271
2419
697

query I rowsort
SELECT DISTINCT col0 * + tab1.col1 * col2 FROM tab1
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-6328
SELECT + - 61 + + col1 DIV + 1 AS col2 FROM tab2 AS cor0
----
-2
-30
-44

skipif mysql # not compatible
query I rowsort label-6328
SELECT + - 61 + + col1 / + 1 AS col2 FROM tab2 AS cor0
----
-2
-30
-44

query I rowsort
SELECT 79 * - col2 FROM tab1 AS cor0
----
-4266
-4503
-7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 83 col1 FROM tab1 AS cor0
----
-83

query I rowsort
SELECT + col2 * + col0 * + col1 AS col0 FROM tab0 AS cor0
----
3395
664118
68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6332
SELECT - col2 * - ( - col0 * - CAST( + col1 AS SIGNED ) ) AS col2 FROM tab0
----
3395
664118
68112

skipif mysql # not compatible
query I rowsort label-6332
SELECT - col2 * - ( - col0 * - CAST ( + col1 AS INTEGER ) ) AS col2 FROM tab0
----
3395
664118
68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * cor0.col2 * - col1 col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT + + 70 + cor0.col1 AS col2 FROM tab1 AS cor0
----
80
83
96

query I rowsort
SELECT + col0 + + col1 * 93 FROM tab2 AS cor0
----
1660
2890
5565

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 41 col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT ALL + + col0 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-6338
SELECT DISTINCT - col2 DIV - col2 AS col2 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-6338
SELECT DISTINCT - col2 / - col2 AS col2 FROM tab0
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6339
SELECT - CAST( NULL AS SIGNED ) * 24 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6339
SELECT - CAST ( NULL AS INTEGER ) * 24 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + cor0.col2 + col0 * + col2 FROM tab0 AS cor0
----
34
7216
759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6341
SELECT DISTINCT + CAST( NULL AS SIGNED ) FROM tab0, tab2 AS cor0, tab2, tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-6341
SELECT DISTINCT + CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0, tab2, tab1 AS cor1
----
NULL

query I rowsort
SELECT - col0 * cor0.col1 + - col1 * col0 FROM tab0 AS cor0
----
-16198
-4128
-6790

onlyif mysql # use DIV operator for integer division
query I rowsort label-6343
SELECT + + tab0.col2 * ( + cor0.col1 ) + - ( + 32 ) DIV cor0.col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to f5496d2b1dfb5ac3f480caf7b5553a8a

skipif mysql # not compatible
query I rowsort label-6343
SELECT + + tab0.col2 * ( + cor0.col1 ) + - ( + 32 ) / cor0.col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to f5496d2b1dfb5ac3f480caf7b5553a8a

query I rowsort
SELECT + + 36 + - 21 - col2 AS col0 FROM tab0 AS cor0
----
-18
-67
14

query I rowsort
SELECT + cor0.col0 * col0 + col1 * + col2 + + col1 AS col2 FROM tab2 AS cor0
----
6904
7677
917

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6346
SELECT ALL - ( 40 ) * - col0 + CAST( col0 AS SIGNED ) col0 FROM tab2 AS cor0
----
287
3198
3239

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6346
SELECT ALL - ( 40 ) * - col0 + CAST ( col0 AS INTEGER ) col0 FROM tab2 AS cor0
----
287
3198
3239

query I rowsort
SELECT + + col2 - + 83 AS col0 FROM tab0 cor0
----
-1
-50
-82

query I rowsort
SELECT + 8 + + 80 FROM tab2 AS cor0
----
88
88
88

query I rowsort
SELECT col1 - + 47 * col1 FROM tab1 AS cor0
----
-1196
-460
-598

query I rowsort
SELECT DISTINCT ( - 94 ) * + col0 + 73 AS col2 FROM tab2 AS cor0
----
-585
-7259
-7353

query I rowsort
SELECT ALL - col2 * 36 FROM tab2
----
-1368
-936
-972

query I rowsort
SELECT DISTINCT 28 FROM tab1, tab1 cor0
----
28

query I rowsort
SELECT + 72 + + col0 + - col0 FROM tab2 AS cor0
----
72
72
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 37 col0 FROM tab1 cor0
----
-37

query I rowsort
SELECT col2 * 32 - - col0 * col0 AS col2 FROM tab1 AS cor0
----
1737
5920
9472

query I rowsort
SELECT ALL - 60 * 10 * col1 AS col0 FROM tab2 AS cor0
----
-10200
-18600
-35400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 17 col1 FROM tab1 cor0
----
17
17
17

query I rowsort
SELECT + 65 * col0 - col1 FROM tab2 cor0
----
424
5011
5118

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 AS cor2
----
3645 values hashing to 5acb69cde71208fe580e10b8b669428e

query I rowsort
SELECT ALL - 31 * + col1 + cor0.col1 * - 68 AS col2 FROM tab0 AS cor0
----
-8514
-9009
-9603

query I rowsort
SELECT + cor0.col2 * + 87 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 36dcd02dc5b81910bca290f034031f6a

query I rowsort
SELECT ALL + + cor0.col0 * col1 + 84 FROM tab0 AS cor0
----
2148
3479
8183

query I rowsort
SELECT cor1.col0 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT + col0 * ( col2 ) + col1 FROM tab1 AS cor0
----
188
3658
7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-6365
SELECT ALL col1 + - col0 DIV + col1 AS col0 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6365
SELECT ALL col1 + - col0 / + col1 AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - 66 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
-66

query I rowsort
SELECT + - 43 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ab0c314d2b589ccedb9a875beeb1f86a

query I rowsort
SELECT - col1 - tab0.col0 AS col0 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT 54 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 81150d59d6c3fc48b4ef5a4a5495bc7a

query I rowsort
SELECT DISTINCT 58 + cor0.col1 AS col0 FROM tab2, tab0 AS cor0
----
144
149
155

query I rowsort
SELECT col2 + + 61 AS col0 FROM tab0
----
143
62
94

query I rowsort
SELECT DISTINCT - + col0 * ( - ( cor0.col2 ) ) AS col1 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6373
SELECT - col1 + + CAST( + col1 AS SIGNED ) FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6373
SELECT - col1 + + CAST ( + col1 AS INTEGER ) FROM tab2
----
0
0
0

query I rowsort
SELECT ALL + col1 * + 48 + 60 FROM tab0 AS cor0
----
4188
4428
4716

query I rowsort
SELECT DISTINCT + col1 * ( 15 * + col0 ) AS col0 FROM tab0 AS cor0
----
121485
30960
50925

query I rowsort
SELECT ALL + - col1 + + col2 * + col2 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT DISTINCT + 55 * 11 AS col2 FROM tab2 AS cor0
----
605

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 6 * 4 + + col1 col0 FROM tab1 AS cor0
----
34
37
50

query I rowsort
SELECT DISTINCT + col2 * col2 + - col1 + col1 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT + ( - col0 ) * + col0 AS col0 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT - 69 FROM tab1, tab0 AS cor0
----
-69

query I rowsort
SELECT ALL ( - col2 ) + col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT + cor0.col1 + - 96 FROM tab1 cor0
----
-70
-83
-86

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( - col1 AS REAL ) + col2 FROM tab1 AS cor0
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 30 + - ( col2 ) * + 24 + + 93 col1 FROM tab2 AS cor0
----
-561
-585
-849

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6386
SELECT DISTINCT ( + col0 * CAST( + col2 AS SIGNED ) ) FROM tab1
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-6386
SELECT DISTINCT ( + col0 * CAST ( + col2 AS INTEGER ) ) FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT col1 * col2 + col1 AS col0 FROM tab1
----
1261
1430
580

onlyif mysql # use DIV operator for integer division
query I rowsort label-6388
SELECT DISTINCT + 28 + - col1 * col0 DIV 75 FROM tab0 AS cor0
----
-17
-79
1

skipif mysql # not compatible
query I rowsort label-6388
SELECT DISTINCT + 28 + - col1 * col0 / 75 FROM tab0 AS cor0
----
-17
-79
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6389
SELECT - 29 + col1 DIV - 35 + ( col0 + - cor0.col1 ) AS col1 FROM tab0 AS cor0
----
-33
-93
-93

skipif mysql # not compatible
query I rowsort label-6389
SELECT - 29 + col1 / - 35 + ( col0 + - cor0.col1 ) AS col1 FROM tab0 AS cor0
----
-33
-93
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 86 col2 FROM tab2 cor0
----
86

query I rowsort
SELECT col1 * - col2 + ( + col2 + + col0 ) FROM tab0 AS cor0
----
-2781
-61
-7291

onlyif mysql # use DIV operator for integer division
query I rowsort label-6392
SELECT DISTINCT + - 58 * col0 DIV - col1 FROM tab2 AS cor0
----
13
269
76

skipif mysql # not compatible
query I rowsort label-6392
SELECT DISTINCT + - 58 * col0 / - col1 FROM tab2 AS cor0
----
13
269
76

query I rowsort
SELECT cor0.col2 * + col0 + ( cor0.col2 ) * cor0.col0 FROM tab2 cor0
----
378
4056
6004

query I rowsort
SELECT DISTINCT cor2.col0 + + cor1.col0 AS col0 FROM tab2, tab2 AS cor0, tab0 cor1, tab1 AS cor2
----
9 values hashing to 727cf91885da1564b9eb8c57fe9a5d27

query I rowsort
SELECT - 12 * + col2 AS col0 FROM tab0 AS cor0
----
-12
-396
-984

query I rowsort
SELECT DISTINCT + + col0 + col1 * col0 AS col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT - + col0 - - 50 * 66 AS col1 FROM tab1 AS cor0
----
3220
3236
3297

query I rowsort
SELECT DISTINCT col1 * - 80 FROM tab0 AS cor0
----
-6880
-7280
-7760

query I rowsort
SELECT DISTINCT col0 * + col1 + + 68 AS col2 FROM tab0 AS cor0
----
2132
3463
8167

query I rowsort
SELECT ALL - col0 * - col0 - 19 * - col2 FROM tab0 AS cor0
----
1203
1244
9479

onlyif mysql # use DIV operator for integer division
query I rowsort label-6401
SELECT ALL - col1 + - col0 DIV + col0 AS col1 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-6401
SELECT ALL - col1 + - col0 / + col0 AS col1 FROM tab1 AS cor0
----
-11
-14
-27

query I rowsort
SELECT - - col2 + 80 FROM tab1 AS cor0
----
134
137
176

query I rowsort
SELECT ALL + - col2 * 11 + col2 FROM tab0 AS cor0
----
-10
-330
-820

query I rowsort
SELECT DISTINCT + - col0 * + 30 - - col0 FROM tab1 AS cor0
----
-1856
-2320
-87

query I rowsort
SELECT ALL - col1 + - cor0.col0 * col1 AS col0 FROM tab1 cor0
----
-104
-1053
-650

query I rowsort
SELECT ALL + tab1.col0 + - col1 + tab1.col1 AS col0 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL ( - tab0.col2 ) + - col0 AS col2 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT + tab1.col0 * col1 + - 46 AS col1 FROM tab1
----
32
594
994

onlyif mysql # use DIV operator for integer division
query I rowsort label-6409
SELECT ALL col2 DIV + col0 + + 90 * + tab0.col0 AS col1 FROM tab0
----
2161
3150
8010

skipif mysql # not compatible
query I rowsort label-6409
SELECT ALL col2 / + col0 + + 90 * + tab0.col0 AS col1 FROM tab0
----
2161
3150
8010

query I rowsort
SELECT col2 / tab2.col0 AS col0 FROM tab2 WHERE NOT NULL NOT IN ( - col0 )
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6411
SELECT - CAST( 87 AS SIGNED ) col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c0011cd00aa3e86f06bebc13678997f9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6411
SELECT - CAST ( 87 AS INTEGER ) col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to c0011cd00aa3e86f06bebc13678997f9

query I rowsort
SELECT ALL + cor0.col2 - col2 * col0 FROM tab1 AS cor0
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-6413
SELECT - cor1.col2 DIV - cor1.col2 FROM tab1, tab1 cor0, tab1 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

skipif mysql # not compatible
query I rowsort label-6413
SELECT - cor1.col2 / - cor1.col2 FROM tab1, tab1 cor0, tab1 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6414
SELECT DISTINCT tab0.col1 DIV - col0 AS col1 FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-6414
SELECT DISTINCT tab0.col1 / - col0 AS col1 FROM tab0
----
-1
-2
-3

query I rowsort
SELECT tab1.col2 * tab1.col2 * - col0 AS col2 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT ALL + tab0.col0 * - tab0.col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT col0 / + col1 + - tab0.col1 * col0 + - col2 * + tab0.col1 AS col2 FROM tab0 WHERE NOT ( - col2 + - col2 * col1 * col2 ) NOT IN ( tab0.col2 )
----

query I rowsort
SELECT DISTINCT + col0 * + col2 * col0 AS col0 FROM tab1
----
233472
486
614400

query I rowsort
SELECT DISTINCT + tab0.col0 + col2 * + col2 AS col0 FROM tab0
----
1113
36
6813

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT col2 + + col1 / tab2.col0 <= NULL
----

query I rowsort
SELECT ALL col0 + col1 FROM tab0 WHERE NULL < ( col0 )
----

query I rowsort
SELECT DISTINCT - col0 + - col0 * col1 AS col1 FROM tab0
----
-2088
-3430
-8188

query I rowsort
SELECT ALL + col2 * - tab2.col0 * + col1 + - col2 * - col1 FROM tab2
----
-118118
-5022
-50388

query I rowsort
SELECT + col0 - + tab0.col0 AS col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col1 * + col2 + col2 col2 FROM tab0
----
-244035
-678960
-9408

query I rowsort
SELECT DISTINCT - col1 FROM tab0 WHERE NOT ( col1 ) NOT IN ( col1 )
----
-86
-91
-97

query III rowsort
SELECT ALL * FROM tab2 WHERE col0 * + col0 < NULL
----

query I rowsort
SELECT - col1 FROM tab2 WHERE NOT NULL <= NULL
----

onlyif mysql # use DIV operator for integer division
query III rowsort label-6429
SELECT DISTINCT * FROM tab0 WHERE ( + col0 DIV - tab0.col1 ) IN ( col1 * + col2 + - col2 * tab0.col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

skipif mysql # not compatible
query III rowsort label-6429
SELECT DISTINCT * FROM tab0 WHERE ( + col0 / - tab0.col1 ) IN ( col1 * + col2 + - col2 * tab0.col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT col0 FROM tab2 WHERE NULL <= ( col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 * + col1 + col2 * col0 + - col2 col1 FROM tab0
----
15315
2823
3429

query I rowsort
SELECT + col1 * - col1 / col0 AS col2 FROM tab0 WHERE NULL NOT IN ( col2 )
----

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL <> ( NULL )
----

query I rowsort
SELECT DISTINCT col2 * col2 * + col2 FROM tab1
----
157464
185193
884736

query I rowsort
SELECT DISTINCT col2 * - col1 + col0 * col1 AS col0 FROM tab2
----
-620
3068
697

query I rowsort
SELECT - col1 * 98 FROM tab2
----
-1666
-3038
-5782

query I rowsort
SELECT - + 47 + ( col0 ) AS col0 FROM tab1 AS cor0
----
-44
17
33

query I rowsort
SELECT 50 * 73 + col1 FROM tab0 cor0
----
3736
3741
3747

onlyif mysql # use DIV operator for integer division
query I rowsort label-6439
SELECT ALL 54 + + col0 * col0 DIV col1 AS col0 FROM tab1
----
463
54
546

skipif mysql # not compatible
query I rowsort label-6439
SELECT ALL 54 + + col0 * col0 / col1 AS col0 FROM tab1
----
463
54
546

query I rowsort
SELECT ALL - ( - 74 ) + col2 FROM tab1
----
128
131
170

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6441
SELECT 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-6441
SELECT CAST ( NULL AS INTEGER ) AS col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 36 col2 FROM tab2 cor0
----
36
36
36

query I rowsort
SELECT + 94 * + col2 FROM tab0 AS cor0
----
3102
7708
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col0 - col1 col0 FROM tab1 AS cor0
----
-20
118
147

onlyif mysql # use DIV operator for integer division
query I rowsort label-6445
SELECT DISTINCT - col2 DIV - col1 + 25 FROM tab0 AS cor0
----
25

skipif mysql # not compatible
query I rowsort label-6445
SELECT DISTINCT - col2 / - col1 + 25 FROM tab0 AS cor0
----
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-6446
SELECT ALL - + col2 * - col1 * + col1 - - ( - cor0.col1 ) DIV + col1 col1 FROM tab0 AS cor0
----
244067
679041
9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6446
SELECT ALL - + col2 * - col1 * + col1 - - ( - cor0.col1 ) / + col1 col1 FROM tab0 AS cor0
----
244067
679041
9408

query I rowsort
SELECT ALL + ( col2 ) + col0 * + 46 AS col0 FROM tab2 AS cor0
----
349
3614
3672

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6448
SELECT DISTINCT - col0 * - col0 - - CAST( 96 AS SIGNED ) FROM tab1 AS cor0
----
105
4192
6496

skipif mysql # not compatible
query I rowsort label-6448
SELECT DISTINCT - col0 * - col0 - - CAST ( 96 AS INTEGER ) FROM tab1 AS cor0
----
105
4192
6496

query I rowsort
SELECT cor0.col2 * col2 + + col0 FROM tab2 AS cor0
----
1523
736
754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 88 + - col2 col2 FROM tab1 cor0
----
-142
-145
-184

query I rowsort
SELECT DISTINCT 54 * - cor0.col2 + cor0.col1 * col1 AS col2 FROM tab0 AS cor0
----
3853
5614
9355

onlyif mysql # use DIV operator for integer division
query I rowsort label-6452
SELECT - + col2 + + col0 * 8 DIV - 78 FROM tab1 AS cor0
----
-104
-54
-63

skipif mysql # not compatible
query I rowsort label-6452
SELECT - + col2 + + col0 * 8 / - 78 FROM tab1 AS cor0
----
-104
-54
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-6453
SELECT ALL + cor0.col2 DIV + col0 AS col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-6453
SELECT ALL + cor0.col2 / + col0 AS col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT - 56 + col1 AS col2 FROM tab2 AS cor0
----
-25
-39
3

query I rowsort
SELECT + col0 - - 34 FROM tab0 AS cor0
----
123
58
69

query I rowsort
SELECT + col0 * 51 FROM tab0 AS cor0
----
1224
1785
4539

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6457
SELECT + col0 * + CAST( + col2 AS SIGNED ) * + tab0.col0 FROM tab0
----
1225
19008
649522

skipif mysql # not compatible
query I rowsort label-6457
SELECT + col0 * + CAST ( + col2 AS INTEGER ) * + tab0.col0 FROM tab0
----
1225
19008
649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - 4 ) col2 FROM tab1, tab1 AS cor0
----
4

query I rowsort
SELECT - col1 * 91 * + ( tab2.col0 ) AS col1 FROM tab2
----
-122213
-19747
-418782

query I rowsort
SELECT - col1 - cor0.col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT - col0 * ( 47 ) - col1 FROM tab0 AS cor0
----
-1214
-1742
-4274

query I rowsort
SELECT - col0 + + ( + col1 ) FROM tab2 AS cor0
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( 24 ) * col2 col2 FROM tab2 cor0
----
-624
-648
-912

query I rowsort
SELECT ALL - cor0.col2 + + cor0.col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 363494b33b4d1826f58e179e26d91c4a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 99 col2 FROM tab0 AS cor0
----
99
99
99

query I rowsort
SELECT ALL - ( col1 ) - col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ALL - + col2 * + col2 AS col0 FROM tab1 cor0
----
-2916
-3249
-9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6468
SELECT + col2 + + col1 * + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6468
SELECT + col2 + + col1 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - 58 + col1 AS col1 FROM tab0 cor0
----
144
149
155

query I rowsort
SELECT DISTINCT + 79 - - col1 FROM tab0 AS cor0
----
165
170
176

query I rowsort
SELECT + + 32 * - col2 AS col0 FROM tab0 AS cor0
----
-1056
-2624
-32

query I rowsort
SELECT DISTINCT + col0 + col2 * 0 * + col1 AS col1 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT ALL + ( col0 ) + - col2 - 78 AS col1 FROM tab2 AS cor0
----
-26
-37
-98

query I rowsort
SELECT + - cor0.col1 * - col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT + col2 + - cor0.col2 * + col2 FROM tab2 AS cor0
----
-1406
-650
-702

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 * col2 + + cor0.col1 * + col1 col2 FROM tab0 AS cor0
----
10234
15743
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-6477
SELECT DISTINCT - col1 DIV ( col0 + + cor0.col0 ) AS col0 FROM tab1 AS cor0
----
-4
0

skipif mysql # not compatible
query I rowsort label-6477
SELECT DISTINCT - col1 / ( col0 + + cor0.col0 ) AS col0 FROM tab1 AS cor0
----
-4
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6478
SELECT + col0 + + CAST( col2 AS SIGNED ) * col1 AS col1 FROM tab0 AS cor0
----
132
2862
7551

skipif mysql # not compatible
query I rowsort label-6478
SELECT + col0 + + CAST ( col2 AS INTEGER ) * col1 AS col1 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT + col2 - cor0.col1 AS col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT col1 * col1 - - cor0.col2 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT + - col2 * cor0.col0 + col1 * + col0 AS col2 FROM tab2 AS cor0
----
-1659
2574
28

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6482
SELECT + col2 + + CAST( + col1 AS SIGNED ) * + col0 AS col2 FROM tab0 AS cor0
----
2097
3396
8181

skipif mysql # not compatible
query I rowsort label-6482
SELECT + col2 + + CAST ( + col1 AS INTEGER ) * + col0 AS col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL - + col0 - + cor0.col0 FROM tab0 AS cor0
----
-178
-48
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - ( + col2 ) * col1 col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT + - col2 * 92 AS col2 FROM tab0 AS cor0
----
-3036
-7544
-92

query I rowsort
SELECT col0 * tab0.col2 + + col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT DISTINCT - col2 * col0 + - col2 * - col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL ( col1 ) * + col0 * + col2 AS col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT - + col1 * + ( col1 ) FROM tab2 AS cor0
----
-289
-3481
-961

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0, tab2, tab2 cor1
----
972 values hashing to f9adf26f20dc8fcc43c2de18a5fd4859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col0 * + col2 col2 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT DISTINCT + col2 * + 93 AS col1 FROM tab0 AS cor0
----
3069
7626
93

query I rowsort
SELECT DISTINCT + col1 * col1 + - col1 + 17 AS col0 FROM tab1 cor0
----
107
173
667

query I rowsort
SELECT ( col2 + col2 ) AS col2 FROM tab1
----
108
114
192

query I rowsort
SELECT + col2 + - col1 * + 17 AS col2 FROM tab2 AS cor0
----
-251
-500
-977

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6496
SELECT ALL ( - col0 ) * - CAST( NULL AS SIGNED ) * + col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6496
SELECT ALL ( - col0 ) * - CAST ( NULL AS INTEGER ) * + col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 52 * col0 AS col1 FROM tab2
----
364
4056
4108

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6498
SELECT CAST( + col2 AS SIGNED ) + - col0 FROM tab0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-6498
SELECT CAST ( + col2 AS INTEGER ) + - col0 FROM tab0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6499
SELECT ALL + tab1.col1 * col2 DIV + col1 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6499
SELECT ALL + tab1.col1 * col2 / + col1 FROM tab1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6500
SELECT + col0 DIV + col2 + col1 AS col1 FROM tab0
----
132
86
92

skipif mysql # not compatible
query I rowsort label-6500
SELECT + col0 / + col2 + col1 AS col1 FROM tab0
----
132
86
92

query I rowsort
SELECT DISTINCT + 63 * 15 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
945

query I rowsort
SELECT 68 + col1 AS col1 FROM tab1 AS cor0
----
78
81
94

query I rowsort
SELECT ALL - - ( + cor0.col2 ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT col0 * cor0.col2 + + col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT tab2.col2 * 82 + 84 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 422a0f6e25dfcaf7d8bf4f66b309ba1e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 64 col1 FROM tab1 AS cor0
----
-64
-64
-64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6507
SELECT ALL col1 + + CAST( col2 AS SIGNED ) AS col0 FROM tab1
----
109
67
80

skipif mysql # not compatible
query I rowsort label-6507
SELECT ALL col1 + + CAST ( col2 AS INTEGER ) AS col0 FROM tab1
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col0 + + ( - col1 ) col1 FROM tab1
----
-29
-74
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - + 32 * - col2 col2 FROM tab0 AS cor0
----
1080
2713
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-6510
SELECT - col2 DIV col0 - + col2 AS col2 FROM tab1 cor0
----
-57
-72
-97

skipif mysql # not compatible
query I rowsort label-6510
SELECT - col2 / col0 - + col2 AS col2 FROM tab1 cor0
----
-57
-72
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6511
SELECT DISTINCT col0 + + 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-6511
SELECT DISTINCT col0 + + CAST ( NULL AS INTEGER ) col1 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + col0 col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT col1 + col0 * tab0.col1 + col1 FROM tab0
----
2236
3589
8281

query I rowsort
SELECT ALL + 99 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query I rowsort
SELECT DISTINCT + col2 * - 4 AS col2 FROM tab1 AS cor0
----
-216
-228
-384

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 69 col1 FROM tab1 AS cor0
----
-69
-69
-69

query I rowsort
SELECT ALL col0 + + 24 AS col2 FROM tab0 AS cor0
----
113
48
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6518
SELECT ALL 84 + col0 DIV col0 + - ( cor0.col0 ) col2 FROM tab2 AS cor0
----
6
7
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6518
SELECT ALL 84 + col0 / col0 + - ( cor0.col0 ) col2 FROM tab2 AS cor0
----
6
7
78

query I rowsort
SELECT DISTINCT - + col2 * + cor0.col1 + col1 FROM tab1 cor0
----
-1235
-1378
-560

query I rowsort
SELECT - - 7 FROM tab0 cor0
----
7
7
7

query I rowsort
SELECT ALL - 70 - - col0 * + col0 FROM tab1 AS cor0
----
-61
4026
6330

query I rowsort
SELECT - + ( col0 ) + + cor0.col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + + 72 + - col1 AS col0 FROM tab0 AS cor0
----
-14
-19
-25

onlyif mysql # use DIV operator for integer division
query I rowsort label-6524
SELECT ALL - col2 DIV + 71 AS col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6524
SELECT ALL - col2 / + 71 AS col2 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT col2 * 34 AS col1 FROM tab0 AS cor0
----
1122
2788
34

query I rowsort
SELECT + 75 * cor0.col2 AS col2 FROM tab2 AS cor0
----
1950
2025
2850

query I rowsort
SELECT DISTINCT col1 * col1 + - cor0.col1 * col1 AS col1 FROM tab1 cor0
----
0

query I rowsort
SELECT DISTINCT + - 50 + col0 FROM tab0 AS cor0
----
-15
-26
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6529
SELECT ALL + CAST( NULL AS SIGNED ) * cor0.col0 + - col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6529
SELECT ALL + CAST ( NULL AS INTEGER ) * cor0.col0 + - col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 33 + ( col0 + ( ( cor0.col0 ) ) ) AS col2 FROM tab0 AS cor0
----
103
211
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-6531
SELECT ALL + + 85 DIV - 87 + col0 * col0 FROM tab2 cor0
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-6531
SELECT ALL + + 85 / - 87 + col0 * col0 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT ALL - - 60 * + col1 FROM tab0 AS cor0
----
5160
5460
5820

query I rowsort
SELECT DISTINCT + - col1 - - 43 * - col2 FROM tab0 AS cor0
----
-140
-1505
-3617

query I rowsort
SELECT + col0 + - 50 FROM tab1 AS cor0
----
-47
14
30

query I rowsort
SELECT DISTINCT + 42 + + 20 AS col2 FROM tab2, tab1 AS cor0
----
62

query I rowsort
SELECT ALL - col2 * 28 FROM tab0
----
-2296
-28
-924

onlyif mysql # use DIV operator for integer division
query I rowsort label-6537
SELECT - + col2 * + col0 DIV - col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-6537
SELECT - + col2 * + col0 / - col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT col0 + - 30 * - 54 FROM tab1 AS cor0
----
1623
1684
1700

query I rowsort
SELECT + col2 + - col1 * + ( cor0.col1 ) * + ( + col2 + - col1 * col1 ) FROM tab1 AS cor0
----
12433
420526
4357

query I rowsort
SELECT + 5 + - 30 * col0 AS col0 FROM tab2 AS cor0
----
-205
-2335
-2365

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 col2 FROM tab1, tab2 cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT + col2 * - 66 AS col1 FROM tab2
----
-1716
-1782
-2508

query I rowsort
SELECT + - 6 AS col2 FROM tab0 cor0
----
-6
-6
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + - col0 col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col1 * ( + col0 ) FROM tab0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6546
SELECT DISTINCT CAST( NULL AS SIGNED ) / 11 AS col2 FROM tab1, tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6546
SELECT DISTINCT CAST ( NULL AS INTEGER ) / 11 AS col2 FROM tab1, tab0 cor0
----
NULL

query I rowsort
SELECT DISTINCT ( tab1.col0 ) AS col1 FROM tab1, tab0 cor0
----
3
64
80

query I rowsort
SELECT ALL + 84 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e8cd683fe8cea77b4326d9b80f21c74a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6549
SELECT col2 * - col2 + CAST( NULL AS SIGNED ) - - col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6549
SELECT col2 * - col2 + CAST ( NULL AS INTEGER ) - - col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6550
SELECT - 58 DIV col1 + + col0 + + 20 AS col0 FROM tab0 AS cor0
----
109
44
55

skipif mysql # not compatible
query I rowsort label-6550
SELECT - 58 / col1 + + col0 + + 20 AS col0 FROM tab0 AS cor0
----
109
44
55

query I rowsort
SELECT + col0 + + col0 + + col1 AS col2 FROM tab0 AS cor0
----
134
167
269

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6552
SELECT col0 * col2 * CAST( NULL AS SIGNED ) col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6552
SELECT col0 * col2 * CAST ( NULL AS INTEGER ) col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 55 + col0 AS col0 FROM tab1 cor0
----
119
135
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-6554
SELECT + 6 DIV col1 AS col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6554
SELECT + 6 / col1 AS col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6555
SELECT + ( + col2 ) DIV - ( cor0.col0 * col1 ) + 12 - - cor0.col2 AS col0 FROM tab0 AS cor0
----
13
45
94

skipif mysql # not compatible
query I rowsort label-6555
SELECT + ( + col2 ) / - ( cor0.col0 * col1 ) + 12 - - cor0.col2 AS col0 FROM tab0 AS cor0
----
13
45
94

query I rowsort
SELECT DISTINCT 91 * + ( + col2 * ( - 42 ) ) + - col1 + - col0 FROM tab0
----
-126236
-313584
-3954

query I rowsort
SELECT ALL col2 + + tab2.col1 AS col1 FROM tab2
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col0 + - col1 col1 FROM tab2
----
-2087
-220
-3019

query I rowsort
SELECT DISTINCT + 44 + + col2 + col2 AS col0 FROM tab2
----
120
96
98

query I rowsort
SELECT ALL + col1 * + col2 + 89 * - 89 * col1 AS col0 FROM tab2 AS cor0
----
-134011
-244714
-465805

query I rowsort
SELECT ALL - + col1 * + col1 * 87 AS col1 FROM tab2 AS cor0
----
-25143
-302847
-83607

query I rowsort
SELECT ALL + + 42 * col2 AS col1 FROM tab2 AS cor0
----
1092
1134
1596

onlyif mysql # use DIV operator for integer division
query I rowsort label-6563
SELECT ALL col1 DIV - col0 col2 FROM tab1 AS cor0
----
-8
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6563
SELECT ALL col1 / - col0 col2 FROM tab1 AS cor0
----
-8
0
0

query I rowsort
SELECT ALL + col0 * cor0.col2 + 96 * col2 FROM tab1 AS cor0
----
16896
5346
9120

query I rowsort
SELECT DISTINCT - - col1 * 31 AS col0 FROM tab1 AS cor0
----
310
403
806

onlyif mysql # use DIV operator for integer division
query I rowsort label-6566
SELECT 75 DIV tab1.col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-6566
SELECT 75 / tab1.col1 FROM tab1
----
2
5
7

query I rowsort
SELECT ALL + - col2 + + col0 * + col1 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT DISTINCT col0 * + col2 * - col0 + - col2 AS col0 FROM tab2 AS cor0
----
-1350
-158210
-237196

query I rowsort
SELECT DISTINCT - col1 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - col2 * - ( + cor0.col0 ) - + col1 AS col0 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT ALL 99 - + tab1.col1 * tab1.col1 AS col1 FROM tab1
----
-1
-577
-70

query I rowsort
SELECT cor0.col2 FROM tab2, tab1, tab1 AS cor0, tab1 AS cor1
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

query I rowsort
SELECT 44 * - col2 FROM tab1
----
-2376
-2508
-4224

onlyif mysql # use DIV operator for integer division
query I rowsort label-6574
SELECT + 37 * col2 DIV + 1 AS col1 FROM tab0
----
1221
3034
37

skipif mysql # not compatible
query I rowsort label-6574
SELECT + 37 * col2 / + 1 AS col1 FROM tab0
----
1221
3034
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + 53 * col0 col0 FROM tab1
----
133
3382
4227

query I rowsort
SELECT DISTINCT col1 * + 65 FROM tab0
----
5590
5915
6305

query I rowsort
SELECT col1 * + col2 + - col1 FROM tab1 AS cor0
----
1235
1378
560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6578
SELECT - cor0.col0 / CAST( NULL AS SIGNED ) + + col1 * - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6578
SELECT - cor0.col0 / CAST ( NULL AS INTEGER ) + + col1 * - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col1 + 30 AS col1 FROM tab1 AS cor0
----
40
43
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + col0 col1 FROM tab0 cor0
----
178
48
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6581
SELECT CAST( NULL AS SIGNED ) + 56 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6581
SELECT CAST ( NULL AS INTEGER ) + 56 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6582
SELECT - 0 DIV col2 + - 43 FROM tab1 AS cor0
----
-43
-43
-43

skipif mysql # not compatible
query I rowsort label-6582
SELECT - 0 / col2 + - 43 FROM tab1 AS cor0
----
-43
-43
-43

query I rowsort
SELECT - + col2 - - cor0.col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL + ( - cor0.col0 ) * - ( col0 ) FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + ( - 8 ) + tab2.col2 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to bab94cc73df61875a2103f4dcc388131

query I rowsort
SELECT - 24 + + col0 * col2 AS col2 FROM tab0 AS cor0
----
11
7274
768

query I rowsort
SELECT col1 * + col2 + + ( col2 ) FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT col2 + - 37 * + col1 * col1 + ( col1 ) AS col1 FROM tab1
----
-24932
-3633
-6144

onlyif mysql # use DIV operator for integer division
query I rowsort label-6589
SELECT + col1 + 6 * tab1.col0 DIV - col0 AS col2 FROM tab1
----
20
4
7

skipif mysql # not compatible
query I rowsort label-6589
SELECT + col1 + 6 * tab1.col0 / - col0 AS col2 FROM tab1
----
20
4
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6590
SELECT CAST( + 25 AS SIGNED ) * col2 FROM tab2 cor0
----
650
675
950

skipif mysql # not compatible
query I rowsort label-6590
SELECT CAST ( + 25 AS INTEGER ) * col2 FROM tab2 cor0
----
650
675
950

query I rowsort
SELECT DISTINCT - + col0 + + ( col0 ) FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6592
SELECT col0 - + 14 DIV col0 AS col2 FROM tab1
----
-1
64
80

skipif mysql # not compatible
query I rowsort label-6592
SELECT col0 - + 14 / col0 AS col2 FROM tab1
----
-1
64
80

query I rowsort
SELECT ALL col1 + 86 FROM tab2
----
103
117
145

query I rowsort
SELECT ALL - ( + 94 ) FROM tab2 AS cor0
----
-94
-94
-94

onlyif mysql # use DIV operator for integer division
query I rowsort label-6595
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-6595
SELECT - col2 / - col0 col1 FROM tab0 AS cor0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6596
SELECT DISTINCT - CAST( NULL AS SIGNED ) + - col2 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6596
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + - col2 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + 59 + 63 * col0 FROM tab1 cor0
----
248
4091
5099

query I rowsort
SELECT DISTINCT + col2 * - 5 * - col2 + col0 * col0 FROM tab2 AS cor0
----
13461
3694
9464

query I rowsort
SELECT DISTINCT + + col1 * - 74 + col0 FROM tab0 AS cor0
----
-6340
-6645
-7143

query I rowsort
SELECT DISTINCT + - col0 * col2 * + col2 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT ALL + + 88 * col1 + cor0.col1 FROM tab0 cor0
----
7654
8099
8633

query I rowsort
SELECT ALL + col1 * - col0 + - col2 AS col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT DISTINCT + ( + col1 ) * col2 AS col0 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT ALL - 58 AS col2 FROM tab2 AS cor0
----
-58
-58
-58

query I rowsort
SELECT + ( - 67 ) FROM tab0 AS cor0
----
-67
-67
-67

query I rowsort
SELECT + - 29 AS col2 FROM tab2 cor0
----
-29
-29
-29

query I rowsort
SELECT DISTINCT ( - col1 ) + - col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT DISTINCT - + cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
-10
-13
-26

query I rowsort
SELECT + col2 * col2 - + 32 * col2 FROM tab0
----
-31
33
4100

query I rowsort
SELECT DISTINCT ( - col0 ) * 11 + + col0 FROM tab2
----
-70
-780
-790

query I rowsort
SELECT - 44 + + cor0.col0 * + cor0.col1 FROM tab0 AS cor0
----
2020
3351
8055

query I rowsort
SELECT DISTINCT - cor0.col2 * col1 * 7 FROM tab2 AS cor0
----
-10738
-4522
-5859

query I rowsort
SELECT DISTINCT - + ( - cor0.col1 ) FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * - cor0.col0 + + ( cor0.col0 ) + - col1 * col0 * 22 col0 FROM tab1 AS cor0
----
-13376
-1635
-21760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col2 col0 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT DISTINCT col1 * col0 * col1 + - col0 AS col0 FROM tab0
----
177480
329280
736920

query I rowsort
SELECT DISTINCT + + col1 * + 94 - + cor0.col2 * - col0 FROM tab0 AS cor0
----
15852
8876
9153

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - 24 col0 FROM tab1 AS cor0
----
-11
-14
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 67 col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

query I rowsort
SELECT col1 * - col0 + + cor0.col2 * col0 - col1 FROM tab0 AS cor0
----
-1358
-3457
-892

query I rowsort
SELECT + - col2 * ( col1 ) + col0 + + 46 AS col2 FROM tab1 cor0
----
-1122
-1355
-460

query I rowsort
SELECT col1 - - cor0.col0 * col1 AS col0 FROM tab2 AS cor0
----
1360
248
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col0 + - col1 col0 FROM tab0 AS cor0
----
-29
-61
80

query I rowsort
SELECT ALL + col1 * 14 AS col0 FROM tab0 AS cor0
----
1204
1274
1358

onlyif mysql # use DIV operator for integer division
query I rowsort label-6625
SELECT ALL col1 DIV - 71 AS col2 FROM tab0 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6625
SELECT ALL col1 / - 71 AS col2 FROM tab0 cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - 82 col0 FROM tab0 AS cor0
----
-168
-173
-179

query I rowsort
SELECT ALL cor0.col2 + + 88 FROM tab2 AS cor0
----
114
115
126

query I rowsort
SELECT ALL - tab1.col2 * + col0 + + tab1.col1 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT ALL + + 32 * + col1 FROM tab0 cor0
----
2752
2912
3104

query I rowsort
SELECT - col2 * col0 * col1 AS col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col2 + + col1 * col0 col2 FROM tab2 AS cor0
----
1305
190
4576

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6632
SELECT ALL - CAST( - col2 + + col1 AS SIGNED ) AS col2 FROM tab2
----
-33
-4
21

skipif mysql # not compatible
query I rowsort label-6632
SELECT ALL - CAST ( - col2 + + col1 AS INTEGER ) AS col2 FROM tab2
----
-33
-4
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col1 col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL - col1 * col0 + 27 FROM tab1
----
-1013
-51
-613

query I rowsort
SELECT ALL - ( - col2 ) + + col0 AS col2 FROM tab1
----
121
176
57

query I rowsort
SELECT ALL ( col0 ) + ( + col2 ) * - col0 * 19 FROM tab2
----
-3584
-38454
-56959

onlyif mysql # use DIV operator for integer division
query I rowsort label-6637
SELECT ALL col1 + col1 DIV + ( 61 * + col0 ) col2 FROM tab0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6637
SELECT ALL col1 + col1 / + ( 61 * + col0 ) col2 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT - col2 + col1 * + 59 AS col1 FROM tab1
----
1480
533
671

onlyif mysql # use DIV operator for integer division
query I rowsort label-6639
SELECT DISTINCT col1 + col0 DIV + 30 + - 74 FROM tab1
----
-48
-59
-62

skipif mysql # not compatible
query I rowsort label-6639
SELECT DISTINCT col1 + col0 / + 30 + - 74 FROM tab1
----
-48
-59
-62

query I rowsort
SELECT DISTINCT - + col1 * col2 + + 94 * ( + col1 ) AS col1 FROM tab2 AS cor0
----
2077
4012
952

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + cor0.col1 + + col2 col1 FROM tab1 AS cor0
----
-43
-622
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 45 col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

query I rowsort
SELECT - - col2 * + 23 AS col0 FROM tab2 AS cor0
----
598
621
874

query I rowsort
SELECT tab1.col2 * + col1 * - 59 FROM tab1
----
-33630
-73632
-82836

query I rowsort
SELECT ALL + 78 + + tab2.col0 FROM tab2
----
156
157
85

query I rowsort
SELECT DISTINCT + col0 * col2 + 20 AS col1 FROM tab0
----
55
7318
812

onlyif mysql # use DIV operator for integer division
query I rowsort label-6647
SELECT col2 - + col0 DIV - tab1.col1 AS col1 FROM tab1
----
102
54
63

skipif mysql # not compatible
query I rowsort label-6647
SELECT col2 - + col0 / - tab1.col1 AS col1 FROM tab1
----
102
54
63

query I rowsort
SELECT - 78 * col2 AS col1 FROM tab2 AS cor0
----
-2028
-2106
-2964

query I rowsort
SELECT DISTINCT 63 * + col0 AS col2 FROM tab2 AS cor0
----
441
4914
4977

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0 WHERE NULL <> ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6651
SELECT + col0 * col1 DIV + col1 + ( - col0 ) FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6651
SELECT + col0 * col1 / + col1 + ( - col0 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT 48 + col0 * col1 FROM tab0 AS cor0
----
2112
3443
8147

query I rowsort
SELECT ALL - ( + 31 ) FROM tab0, tab1 AS cor0
----
9 values hashing to f4b05206ee2fc0cf8007d9c3514885fa

query I rowsort
SELECT ALL + + col1 + - 14 AS col2 FROM tab1 AS cor0
----
-1
-4
12

query I rowsort
SELECT DISTINCT + col1 * + col1 + col0 * + col1 FROM tab2 AS cor0
----
1178
1632
8083

query I rowsort
SELECT - col1 * - 56 FROM tab0 AS cor0
----
4816
5096
5432

query I rowsort
SELECT - - col0 * col2 + + 66 FROM tab0 AS cor0
----
101
7364
858

query I rowsort
SELECT - - 95 * 48 - cor0.col0 * + col2 FROM tab0 AS cor0
----
-2738
3768
4525

onlyif mysql # use DIV operator for integer division
query I rowsort label-6659
SELECT 89 - + col1 DIV - col1 FROM tab2 AS cor0
----
90
90
90

skipif mysql # not compatible
query I rowsort label-6659
SELECT 89 - + col1 / - col1 FROM tab2 AS cor0
----
90
90
90

query I rowsort
SELECT - col2 * col0 + - col0 AS col1 FROM tab2 cor0
----
-196
-2106
-3081

query I rowsort
SELECT + 72 + + col2 AS col2 FROM tab1 AS cor0
----
126
129
168

query I rowsort
SELECT ALL col0 * 74 * ( tab2.col0 + col2 ) AS col1 FROM tab2
----
17612
600288
683982

query I rowsort
SELECT + col1 + cor0.col2 * col2 AS col0 FROM tab2 cor0
----
1461
735
760

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 AS cor0, tab1, tab2 cor1
----
972 values hashing to 0fcd8d0934383dd58863be894b07a6ed

query I rowsort
SELECT ALL col1 * - 7 * col2 FROM tab1 AS cor0
----
-3990
-8736
-9828

query I rowsort
SELECT DISTINCT - ( + col2 ) * + col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + + col2 * - cor0.col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT + 91 * col0 FROM tab2 cor0
----
637
7098
7189

query I rowsort
SELECT + - 37 + - cor0.col2 AS col2 FROM tab0 AS cor0
----
-119
-38
-70

query I rowsort
SELECT + + ( col2 ) * 30 AS col2 FROM tab0 AS cor0
----
2460
30
990

query I rowsort
SELECT - 42 * + 66 * - col1 FROM tab0
----
238392
252252
268884

query I rowsort
SELECT ( + 20 + - col2 ) * + 14 FROM tab2
----
-252
-84
-98

query I rowsort
SELECT DISTINCT ( 41 ) * col2 FROM tab1
----
2214
2337
3936

query I rowsort
SELECT ALL 87 + - col1 * + 43 AS col1 FROM tab1 AS cor0
----
-1031
-343
-472

onlyif mysql # use DIV operator for integer division
query I rowsort label-6675
SELECT DISTINCT - + 27 DIV - col0 + - 43 AS col2 FROM tab1 AS cor0
----
-34
-43

skipif mysql # not compatible
query I rowsort label-6675
SELECT DISTINCT - + 27 / - col0 + - 43 AS col2 FROM tab1 AS cor0
----
-34
-43

query I rowsort
SELECT DISTINCT + + col0 * col2 + + col0 * col1 + + col2 AS col2 FROM tab0 AS cor0
----
15479
2889
3431

onlyif mysql # use DIV operator for integer division
query I rowsort label-6677
SELECT ALL - ( col0 ) DIV - col1 + + tab0.col2 - 57 AS col0 FROM tab0
----
-24
-56
25

skipif mysql # not compatible
query I rowsort label-6677
SELECT ALL - ( col0 ) / - col1 + + tab0.col2 - 57 AS col0 FROM tab0
----
-24
-56
25

query I rowsort
SELECT + + ( cor0.col2 ) AS col0 FROM tab1, tab2, tab2 cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6679
SELECT - CAST( NULL AS SIGNED ) / 67 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6679
SELECT - CAST ( NULL AS INTEGER ) / 67 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6680
SELECT - 56 * col2 + - col1 - + CAST( + col1 AS SIGNED ) AS col0 FROM tab2
----
-1574
-1574
-2162

skipif mysql # not compatible
query I rowsort label-6680
SELECT - 56 * col2 + - col1 - + CAST ( + col1 AS INTEGER ) AS col0 FROM tab2
----
-1574
-1574
-2162

query I rowsort
SELECT tab1.col2 * - col0 + col1 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT + ( - col2 ) * - col2 - tab2.col0 FROM tab2
----
1365
598
722

query I rowsort
SELECT - col2 + col0 + 12 AS col2 FROM tab2 cor0
----
-8
53
64

query I rowsort
SELECT DISTINCT - col2 * + 55 * + col0 AS col0 FROM tab1 cor0
----
-200640
-422400
-8910

query I rowsort
SELECT + cor0.col1 * ( + ( - col1 ) ) AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL - - col1 * + col1 + + cor0.col2 FROM tab1 cor0
----
157
265
730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col0 col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL - col0 * 97 AS col2 FROM tab0 AS cor0
----
-2328
-3395
-8633

query I rowsort
SELECT - col0 * + ( - col2 ) FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col2 * + col1 col2 FROM tab2 cor0
----
22599
24548
39884

query I rowsort
SELECT + col0 + cor0.col0 * - col1 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT + + col0 * col2 + col0 * + col2 * + col2 AS col2 FROM tab2 AS cor0
----
117078
5292
54756

query I rowsort
SELECT DISTINCT + - 54 * + col2 FROM tab0 cor0
----
-1782
-4428
-54

query I rowsort
SELECT + col2 + + col0 AS col1 FROM tab2 cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * col2 * - cor0.col1 col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT + - 77 * + col2 * - col2 FROM tab1 cor0
----
224532
250173
709632

query I rowsort
SELECT ALL + ( + col0 ) * col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT 0 + col0 * - col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + 83 + + col0 * cor0.col0 FROM tab2 AS cor0
----
132
6167
6324

query I rowsort
SELECT 21 * col1 + col2 + col1 AS col2 FROM tab1
----
277
382
626

query I rowsort
SELECT ALL ( 78 ) + col0 * - col2 FROM tab0
----
-714
-7220
43

query I rowsort
SELECT ALL - tab2.col0 * col1 * + col2 - col1 FROM tab2
----
-119711
-51051
-5890

query I rowsort
SELECT ALL + col2 * col0 + - col1 + + col2 AS col2 FROM tab2
----
185
1995
3023

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col1 + col2 col2 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT cor0.col2 * - cor1.col0 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 99e52647357b835698a6730896ff820d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + cor0.col2 * + col0 + col1 col0 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ALL ( + cor0.col0 ) + col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + - ( - cor0.col0 ) * col0 FROM tab2 AS cor0
----
49
6084
6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - ( + col1 ) col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + - col0 * cor0.col1 AS col2 FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6711
SELECT col2 + col2 DIV col1 FROM tab1 AS cor0
----
103
56
62

skipif mysql # not compatible
query I rowsort label-6711
SELECT col2 + col2 / col1 FROM tab1 AS cor0
----
103
56
62

query I rowsort
SELECT col2 - 54 AS col1 FROM tab0
----
-21
-53
28

query I rowsort
SELECT - - col0 + - col1 * + 52 AS col0 FROM tab0 AS cor0
----
-4448
-4643
-5009

query I rowsort
SELECT col1 * 0 + 30 FROM tab0
----
30
30
30

query I rowsort
SELECT - 26 - col2 * col1 AS col1 FROM tab2 cor0
----
-1560
-672
-863

query I rowsort
SELECT DISTINCT 11 + ( cor0.col1 ) FROM tab2 AS cor0
----
28
42
70

query I rowsort
SELECT ( ( - col0 ) ) * - col1 + col1 AS col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT col1 * col1 - - col2 FROM tab1 AS cor0
----
157
265
730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + + ( - col1 ) + - col0 col1 FROM tab1
----
-131
-189
-83

query I rowsort
SELECT col1 * 30 + + col2 FROM tab1
----
357
486
834

query I rowsort
SELECT ALL ( + col2 ) + - col1 + tab2.col0 AS col1 FROM tab2
----
100
3
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6722
SELECT + CAST( + 55 AS SIGNED ) - - col0 AS col0 FROM tab1 AS cor0
----
119
135
58

skipif mysql # not compatible
query I rowsort label-6722
SELECT + CAST ( + 55 AS INTEGER ) - - col0 AS col0 FROM tab1 AS cor0
----
119
135
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-6723
SELECT DISTINCT + + ( + col1 ) DIV col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6723
SELECT DISTINCT + + ( + col1 ) / col2 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6724
SELECT ALL + CAST( NULL AS SIGNED ) * - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6724
SELECT ALL + CAST ( NULL AS INTEGER ) * - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - 21 * col2 + - col1 * col1 * - col1 AS col2 FROM tab0 AS cor0
----
636749
755293
912694

onlyif mysql # use DIV operator for integer division
query I rowsort label-6726
SELECT + + col0 DIV col1 + - col1 col1 FROM tab2 AS cor0
----
-13
-31
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6726
SELECT + + col0 / col1 + - col1 col1 FROM tab2 AS cor0
----
-13
-31
-58

query I rowsort
SELECT ALL + + col0 * - 19 * - col0 FROM tab2 AS cor0
----
115596
118579
931

query I rowsort
SELECT ALL - + 81 + col2 FROM tab2 AS cor0
----
-43
-54
-55

query I rowsort
SELECT ALL col1 + + col2 * col1 FROM tab1 AS cor0
----
1261
1430
580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col2 col2 FROM tab1
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-6731
SELECT ALL + col2 DIV col1 + - col0 AS col1 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-6731
SELECT ALL + col2 / col1 + - col0 AS col1 FROM tab0
----
-24
-35
-89

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL >= col1
----

query I rowsort
SELECT DISTINCT col2 + tab1.col1 AS col2 FROM tab1 WHERE NULL NOT BETWEEN ( col0 * - col1 ) AND col2
----

query I rowsort
SELECT - + col1 * + col0 + col1 AS col2 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT col0 * + col0 + - tab2.col0 FROM tab2
----
42
6006
6162

query I rowsort
SELECT col1 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-6737
SELECT DISTINCT + col2 * + col1 * col1 + col1 DIV col2 FROM tab0 AS cor0
----
244070
679043
9506

skipif mysql # not compatible
query I rowsort label-6737
SELECT DISTINCT + col2 * + col1 * col1 + col1 / col2 FROM tab0 AS cor0
----
244070
679043
9506

query I rowsort
SELECT ALL - cor0.col1 * col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT - col0 * cor0.col1 * cor0.col1 AS col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT - col2 * col2 * - col1 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT DISTINCT + col0 * - col1 * + col0 FROM tab0
----
-118825
-49536
-720811

onlyif mysql # use DIV operator for integer division
query I rowsort label-6742
SELECT DISTINCT - cor0.col1 DIV + col1 + col0 AS col1 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-6742
SELECT DISTINCT - cor0.col1 / + col1 + col0 AS col1 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT DISTINCT col1 * + col1 + col0 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT col2 * - col2 + + col2 * col0 * - col0 AS col0 FROM tab1
----
-236721
-3402
-623616

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col2 * - col1 - col0 col0 FROM tab1
----
1168
1401
506

query I rowsort
SELECT + col2 + col1 * + col1 FROM tab1
----
157
265
730

query I rowsort
SELECT + 87 + tab2.col2 FROM tab2
----
113
114
125

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT + 53 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 866ae1b4ab9e5b4043ac1bcfd413aaa6

query I rowsort
SELECT + col0 + ( - col1 ) - cor0.col1 AS col1 FROM tab1 AS cor0
----
-49
44
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-6751
SELECT + col0 DIV ( + 90 * col1 ) FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6751
SELECT + col0 / ( + 90 * col1 ) FROM tab0
----
0
0
0

query I rowsort
SELECT + col0 - col1 * - 73 FROM tab0 AS cor0
----
6302
6732
7116

onlyif mysql # use DIV operator for integer division
query I rowsort label-6753
SELECT ALL - col0 + col0 - + col1 DIV col0 FROM tab1
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-6753
SELECT ALL - col0 + col0 - + col1 / col0 FROM tab1
----
-8
0
0

query I rowsort
SELECT + cor0.col0 + + 89 FROM tab0 AS cor0
----
113
124
178

query I rowsort
SELECT DISTINCT + 3 AS col1 FROM tab1 AS cor0
----
3

query I rowsort
SELECT ALL + - 41 * + col1 FROM tab0 cor0
----
-3526
-3731
-3977

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6758
SELECT + - CAST( NULL AS SIGNED ) * cor0.col2 * cor0.col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6758
SELECT + - CAST ( NULL AS INTEGER ) * cor0.col2 * cor0.col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 25 + + cor0.col0 * - col2 FROM tab2 AS cor0
----
-164
-2003
-2977

query I rowsort
SELECT - tab2.col2 + - col1 * + tab2.col2 FROM tab2
----
-1560
-684
-864

query I rowsort
SELECT + cor0.col1 + + col1 AS col0 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT DISTINCT + 63 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
63

query I rowsort
SELECT DISTINCT ( - col0 + + col0 ) AS col1 FROM tab2
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 72 col0 FROM tab0
----
72
72
72

query I rowsort
SELECT DISTINCT 44 + - col0 * - col2 FROM tab0 AS cor0
----
7342
79
836

query I rowsort
SELECT + - 64 * + col1 AS col1 FROM tab2 AS cor0
----
-1088
-1984
-3776

query I rowsort
SELECT DISTINCT - col2 * - 78 + col0 FROM tab0 AS cor0
----
113
2598
6485

query I rowsort
SELECT ALL col2 + + cor0.col2 * + 45 FROM tab0 AS cor0
----
1518
3772
46

query I rowsort
SELECT - col1 * - 12 + col0 AS col2 FROM tab2 AS cor0
----
283
379
786

onlyif mysql # use DIV operator for integer division
query I rowsort label-6770
SELECT ALL - - col2 DIV - col0 + - cor0.col1 FROM tab1 AS cor0
----
-10
-14
-44

skipif mysql # not compatible
query I rowsort label-6770
SELECT ALL - - col2 / - col0 + - cor0.col1 FROM tab1 AS cor0
----
-10
-14
-44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 + 66 col0 FROM tab0 AS cor0
----
-20
-25
-31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6772
SELECT ALL - col1 * + col0 * - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6772
SELECT ALL - col1 * + col0 * - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6773
SELECT DISTINCT col1 * cor0.col0 DIV col1 + + col1 AS col0 FROM tab1 AS cor0
----
29
74
93

skipif mysql # not compatible
query I rowsort label-6773
SELECT DISTINCT col1 * cor0.col0 / col1 + + col1 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + + col0 + 15 * col0 FROM tab1 AS cor0
----
1024
1280
48

query I rowsort
SELECT ALL - col0 - - 29 FROM tab2 AS cor0
----
-49
-50
22

query I rowsort
SELECT ALL col1 * tab0.col1 * 37 FROM tab0
----
273652
306397
348133

query I rowsort
SELECT + - ( cor0.col1 ) * - col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT 85 * col0 FROM tab1 AS cor0
----
255
5440
6800

query I rowsort
SELECT - - col0 * cor0.col0 + + col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT + col0 * col1 + + col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL tab1.col1 * ( + col2 ) AS col0 FROM tab1
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6782
SELECT DISTINCT - ( - col0 ) DIV - cor0.col2 FROM tab1 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-6782
SELECT DISTINCT - ( - col0 ) / - cor0.col2 FROM tab1 cor0
----
-1
0

query I rowsort
SELECT ALL col0 * + 48 FROM tab0 AS cor0
----
1152
1680
4272

query I rowsort
SELECT DISTINCT - cor0.col0 * col2 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 * col1 + col1 col2 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT ALL - ( - col2 ) * - col1 + col2 + col0 * col2 FROM tab0 AS cor0
----
-2013
-61
-82

query I rowsort
SELECT - col1 * + 26 AS col0 FROM tab0
----
-2236
-2366
-2522

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 CROSS JOIN tab2, tab1, tab1 AS cor1
----
3645 values hashing to 6156c969b7e054b8a333fdb86aee82f2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6789
SELECT 96 DIV - col2 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6789
SELECT 96 / - col2 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT col1 * - 26 AS col1 FROM tab2
----
-1534
-442
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-6791
SELECT ALL + 77 + col1 DIV col1 FROM tab1 AS cor0
----
78
78
78

skipif mysql # not compatible
query I rowsort label-6791
SELECT ALL + 77 + col1 / col1 FROM tab1 AS cor0
----
78
78
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-6792
SELECT ALL - + cor0.col0 DIV - 74 - cor0.col2 * 92 FROM tab0 cor0
----
-3036
-7543
-92

skipif mysql # not compatible
query I rowsort label-6792
SELECT ALL - + cor0.col0 / - 74 - cor0.col2 * 92 FROM tab0 cor0
----
-3036
-7543
-92

query I rowsort
SELECT ALL - col2 + + 34 FROM tab1
----
-20
-23
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6794
SELECT col0 DIV + 47 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6794
SELECT col0 / + 47 FROM tab1
----
0
1
1

query I rowsort
SELECT ALL + ( col0 ) * tab1.col2 + 41 * 23 FROM tab1
----
1105
4591
8623

query I rowsort
SELECT - 14 * col2 AS col0 FROM tab1 cor0
----
-1344
-756
-798

query I rowsort
SELECT ALL + 31 AS col2 FROM tab0 AS cor0
----
31
31
31

skipif mysql # not compatible
query I rowsort
SELECT ALL + ( 71 ) * col2 + + CAST ( col2 AS REAL ) FROM tab1 AS cor0
----
3888
4104
6912

query I rowsort
SELECT + cor0.col0 AS col1 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT + cor0.col0 * - 55 - + col0 * cor0.col2 FROM tab1 AS cor0
----
-12080
-327
-7168

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6801
SELECT DISTINCT 93 * - 31 - col0 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6801
SELECT DISTINCT 93 * - 31 - col0 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6802
SELECT CAST( NULL AS SIGNED ) * col1 + col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6802
SELECT CAST ( NULL AS INTEGER ) * col1 + col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( col0 ) - col1 FROM tab1 AS cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( 22 AS REAL ) + cor0.col0 AS col1 FROM tab0 cor0
----
13
2
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( + col2 ) col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL ( ( + col0 ) ) * - 83 FROM tab1 AS cor0
----
-249
-5312
-6640

query I rowsort
SELECT cor0.col2 - + col0 * + col2 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT - col1 - - col2 FROM tab1 cor0
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 60 col1 FROM tab0 AS cor0
----
60
60
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 * cor0.col0 col2 FROM tab1 cor0
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6811
SELECT ALL + col2 * + col2 + + ( 79 ) * - cor0.col1 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6811
SELECT ALL + col2 * + col2 + + ( 79 ) * - cor0.col1 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col1 * cor0.col1 + col2 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
-1453
-772
2713

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6813
SELECT CAST( - col2 AS SIGNED ) + + col2 * - 4 + col1 FROM tab2
----
-104
-173
-71

skipif mysql # not compatible
query I rowsort label-6813
SELECT CAST ( - col2 AS INTEGER ) + + col2 * - 4 + col1 FROM tab2
----
-104
-173
-71

query I rowsort
SELECT col1 + 0 FROM tab1
----
10
13
26

query I rowsort
SELECT + tab1.col1 + + 88 FROM tab1
----
101
114
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6816
SELECT ALL + CAST( NULL AS SIGNED ) + - col0 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6816
SELECT ALL + CAST ( NULL AS INTEGER ) + - col0 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + tab2.col0 + + col0 AS col0 FROM tab2
----
14
156
158

query I rowsort
SELECT ALL + col0 * ( + cor0.col2 + col2 ) AS col1 FROM tab1 AS cor0
----
15360
324
7296

query I rowsort
SELECT DISTINCT - col2 + + col1 * - col0 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT - col2 + - cor0.col1 * col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT ALL - col0 * + ( - 4 ) * + cor0.col0 FROM tab0 cor0
----
2304
31684
4900

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6822
SELECT DISTINCT col0 + CAST( col0 AS SIGNED ) FROM tab2 AS cor0
----
14
156
158

skipif mysql # not compatible
query I rowsort label-6822
SELECT DISTINCT col0 + CAST ( col0 AS INTEGER ) FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT - col0 * col0 + col1 AS col1 FROM tab1 cor0
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT - + col2 + col0 * + 74 * col0 FROM tab2 AS cor0
----
3599
450190
461796

query I rowsort
SELECT ALL col1 * col2 * - cor0.col2 - + col1 FROM tab0 cor0
----
-194
-611975
-93740

query I rowsort
SELECT + tab0.col1 FROM tab0, tab2, tab2 cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT - + col2 * - 46 * 2 AS col2 FROM tab1 AS cor0
----
4968
5244
8832

query I rowsort
SELECT ALL + col2 * + col0 + + col2 AS col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT cor0.col2 * - ( ( - cor0.col1 ) ) AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - col0 * col1 * - 71 AS col2 FROM tab1 AS cor0
----
45440
5538
73840

query I rowsort
SELECT ALL + + 61 AS col0 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 07149905a72bd87553381f34d19ed290

query I rowsort
SELECT - 10 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6833
SELECT DISTINCT + - col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6833
SELECT DISTINCT + - col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6834
SELECT + - col1 DIV 31 col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6834
SELECT + - col1 / 31 col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 + - 98 * col0 FROM tab0
----
-2266
-3333
-8631

onlyif mysql # use DIV operator for integer division
query I rowsort label-6836
SELECT + ( + 67 ) + col1 DIV + ( + 10 ) FROM tab1 AS cor0
----
68
68
69

skipif mysql # not compatible
query I rowsort label-6836
SELECT + ( + 67 ) + col1 / + ( + 10 ) FROM tab1 AS cor0
----
68
68
69

query I rowsort
SELECT ( col0 ) AS col2 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT + ( ( + col0 ) ) * - col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + tab1.col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT - cor1.col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
-24
-35
-89

query I rowsort
SELECT + col0 + 38 FROM tab0
----
127
62
73

query I rowsort
SELECT col1 + 67 AS col2 FROM tab1
----
77
80
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6843
SELECT ALL - 3 + 53 DIV col1 AS col1 FROM tab1 AS cor0
----
-1
1
2

skipif mysql # not compatible
query I rowsort label-6843
SELECT ALL - 3 + 53 / col1 AS col1 FROM tab1 AS cor0
----
-1
1
2

query I rowsort
SELECT ALL - 64 * + col0 FROM tab2 AS cor0
----
-448
-4992
-5056

query I rowsort
SELECT 31 * + cor0.col1 + 67 FROM tab1, tab0 AS cor0, tab0, tab1 cor1
----
81 values hashing to 5892f40ed96191a71387f8a01be42882

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * 97 col2 FROM tab1 AS cor0
----
-291
-6208
-7760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6847
SELECT CAST( NULL AS SIGNED ) FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6847
SELECT CAST ( NULL AS INTEGER ) FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL - 3 + col2 + tab0.col1 * + ( col2 ) FROM tab0
----
2868
7541
95

query I rowsort
SELECT 49 * + col1 AS col2 FROM tab0
----
4214
4459
4753

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 80 col2 FROM tab2 AS cor0
----
-80
-80
-80

query I rowsort
SELECT DISTINCT - 21 + cor0.col0 * col1 AS col2 FROM tab1 AS cor0
----
1019
57
619

query I rowsort
SELECT DISTINCT - col0 - col0 * 13 FROM tab0 AS cor0
----
-1246
-336
-490

query I rowsort
SELECT DISTINCT + - ( + col2 ) * + ( + col2 ) + col0 + - 83 FROM tab2 AS cor0
----
-1448
-681
-805

query I rowsort
SELECT ALL - + col0 - col0 FROM tab2 cor0
----
-14
-156
-158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col0 + + col0 col1 FROM tab1 AS cor0
----
-4032
-6
-6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * col0 col1 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6857
SELECT + tab2.col0 DIV 76 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 43a387ef4ba85927dc3d9d573afc12c9

skipif mysql # not compatible
query I rowsort label-6857
SELECT + tab2.col0 / 76 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 43a387ef4ba85927dc3d9d573afc12c9

query I rowsort
SELECT ALL + 12 FROM tab1, tab2 cor0, tab2 cor1
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0, tab0 AS cor1, tab2, tab1 cor2
----
3645 values hashing to b2cff03af5bc7306c5e3322cc78563c1

query I rowsort
SELECT - - cor0.col0 * 1 + + col2 AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - - 59 AS col0 FROM tab1 AS cor0
----
59
59
59

query I rowsort
SELECT 17 + - cor0.col0 * ( - col0 * col2 ) FROM tab2 AS cor0
----
1340
158201
237175

query I rowsort
SELECT ( + col0 ) * + ( - col0 ) FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT + + 7 * + col2 * + ( - 2 ) FROM tab1 AS cor0
----
-1344
-756
-798

query I rowsort
SELECT - ( + col2 ) * ( - col1 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - - 78 AS col0 FROM tab0 AS cor0
----
78
78
78

query I rowsort
SELECT 34 + + col0 FROM tab1 AS cor0
----
114
37
98

query I rowsort
SELECT DISTINCT 97 AS col1 FROM tab1, tab0 AS cor0
----
97

query I rowsort
SELECT + col1 + + col2 * - 80 AS col2 FROM tab1 AS cor0
----
-4294
-4550
-7667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6870
SELECT DISTINCT - col2 * + col1 + + 71 - cor0.col2 * + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6870
SELECT DISTINCT - col2 * + col1 + + 71 - cor0.col2 * + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6871
SELECT DISTINCT - col2 DIV + col1 + col0 + col0 FROM tab1 AS cor0
----
123
153
4

skipif mysql # not compatible
query I rowsort label-6871
SELECT DISTINCT - col2 / + col1 + col0 + col0 FROM tab1 AS cor0
----
123
153
4

query I rowsort
SELECT ALL + cor0.col1 * col0 + col2 * col2 + - ( cor0.col2 ) * cor0.col1 AS col0 FROM tab2 AS cor0
----
109
2141
3744

query I rowsort
SELECT - - 36 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

query I rowsort
SELECT col2 + - col0 * col0 FROM tab1 cor0
----
-4039
-6304
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-6875
SELECT + 99 + ( - col2 ) * 12 DIV - 99 FROM tab0 AS cor0
----
103
108
99

skipif mysql # not compatible
query I rowsort label-6875
SELECT + 99 + ( - col2 ) * 12 / - 99 FROM tab0 AS cor0
----
103
108
99

query I rowsort
SELECT ALL 71 FROM tab2, tab0 AS cor0, tab2 cor1, tab0 AS cor2
----
81 values hashing to 39b7515708f32e28b7b5a1bfec0df356

query I rowsort
SELECT 34 + + cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to fbd01480278adb64a5ab327eab8bf382

query I rowsort
SELECT + col0 * 95 AS col1 FROM tab2
----
665
7410
7505

query I rowsort
SELECT ALL - 73 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 2931474b870c05694e446771031a6949

query I rowsort
SELECT DISTINCT + 15 AS col1 FROM tab0, tab0 cor0
----
15

query I rowsort
SELECT - + 43 AS col0 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 2f72bd9cab68c8d8c38874510a290a3c

query I rowsort
SELECT - 90 * - col2 AS col2 FROM tab1
----
4860
5130
8640

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6883
SELECT DISTINCT CAST( + col2 AS SIGNED ) * + tab0.col2 AS col2 FROM tab0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-6883
SELECT DISTINCT CAST ( + col2 AS INTEGER ) * + tab0.col2 AS col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL - cor0.col1 AS col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT DISTINCT + cor0.col2 * 62 FROM tab0, tab0 AS cor0
----
2046
5084
62

query I rowsort
SELECT + col1 * 86 AS col1 FROM tab0 cor0
----
7396
7826
8342

query I rowsort
SELECT ALL + col0 + - col1 * tab1.col1 + 69 FROM tab1
----
-20
-604
33

query I rowsort
SELECT - tab0.col2 * 83 * col0 FROM tab0
----
-2905
-605734
-65736

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6889
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6889
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - col0 FROM tab1
----
NULL

query I rowsort
SELECT 97 * col0 AS col1 FROM tab1 cor0
----
291
6208
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 46 + col0 + + col2 col2 FROM tab2 AS cor0
----
150
163
80

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col2 + col0 * + CAST ( col2 AS REAL ) AS col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT 8 AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
8

query I rowsort
SELECT DISTINCT col0 + + 52 FROM tab2
----
130
131
59

query I rowsort
SELECT - 2 * + tab2.col2 FROM tab2
----
-52
-54
-76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6896
SELECT - CAST( NULL AS SIGNED ) * + col1 - col1 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6896
SELECT - CAST ( NULL AS INTEGER ) * + col1 - col1 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 + + 3 FROM tab0
----
36
4
85

query I rowsort
SELECT DISTINCT - 22 * tab0.col2 FROM tab0
----
-1804
-22
-726

query I rowsort
SELECT ALL + tab2.col0 * col1 AS col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT - - cor0.col0 + + cor0.col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT col0 * + col0 * 96 AS col1 FROM tab1
----
393216
614400
864

query I rowsort
SELECT + col2 + col2 * col0 AS col1 FROM tab1
----
216
3705
7776

query I rowsort
SELECT DISTINCT 95 * - col1 AS col1 FROM tab1 AS cor0
----
-1235
-2470
-950

query I rowsort
SELECT - col1 + ( col1 + tab0.col2 ) AS col2 FROM tab0
----
1
33
82

query I rowsort
SELECT - col0 + col1 * col2 * col1 - col2 FROM tab2
----
10865
25913
90402

onlyif mysql # use DIV operator for integer division
query I rowsort label-6906
SELECT col2 DIV + 66 AS col1 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6906
SELECT col2 / + 66 AS col1 FROM tab0
----
0
0
1

query I rowsort
SELECT col2 + col1 * + col1 - col1 AS col0 FROM tab2
----
310
3448
957

onlyif mysql # use DIV operator for integer division
query I rowsort label-6908
SELECT DISTINCT col0 - ( + col2 ) DIV + col0 AS col1 FROM tab2
----
4
78
79

skipif mysql # not compatible
query I rowsort label-6908
SELECT DISTINCT col0 - ( + col2 ) / + col0 AS col1 FROM tab2
----
4
78
79

query I rowsort
SELECT + - col0 * ( + col2 ) + cor0.col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT + col2 * + 80 AS col0 FROM tab1 AS cor0
----
4320
4560
7680

query I rowsort
SELECT DISTINCT + col1 * cor0.col1 + col0 * ( col1 * - col0 ) FROM tab0 cor0
----
-109416
-42140
-712530

query I rowsort
SELECT ALL + 8 * + col1 AS col2 FROM tab0 AS cor0
----
688
728
776

query I rowsort
SELECT 82 + - col2 * col0 AS col2 FROM tab0 cor0
----
-710
-7216
47

query I rowsort
SELECT + col0 * + cor0.col1 + col1 * ( col0 ) + + col1 FROM tab0 AS cor0
----
16289
4214
6887

query I rowsort
SELECT 86 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-2064
-3010
-7654

onlyif mysql # use DIV operator for integer division
query I rowsort label-6916
SELECT + - ( col0 ) DIV col1 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-6916
SELECT + - ( col0 ) / col1 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT ALL - col0 + + 56 AS col1 FROM tab0 AS cor0
----
-33
21
32

query I rowsort
SELECT + 7 + - col2 AS col1 FROM tab2 AS cor0
----
-19
-20
-31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6919
SELECT DISTINCT col1 + - col2 * - cor0.col1 / - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6919
SELECT DISTINCT col1 + - col2 * - cor0.col1 / - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 61 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 51f53697966a79d306a4570537cd91a1

query I rowsort
SELECT col2 * col0 - col2 * ( + col0 + - col0 ) FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col2 ) * cor0.col2 + col2 col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT DISTINCT col2 * 81 * col2 AS col2 FROM tab1 AS cor0
----
236196
263169
746496

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6924
SELECT ALL - CAST( NULL AS SIGNED ) * - ( col2 ) * - 96 + - col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6924
SELECT ALL - CAST ( NULL AS INTEGER ) * - ( col2 ) * - 96 + - col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + col0 * - ( - cor0.col0 + - col1 ) FROM tab2 AS cor0
----
-10686
-266
-7584

skipif mysql # not compatible
query I rowsort
SELECT + ( - col2 + - CAST ( + col0 AS REAL ) ) AS col0 FROM tab2
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-6927
SELECT DISTINCT + 26 DIV col1 FROM tab1 AS cor0
----
1
2

skipif mysql # not compatible
query I rowsort label-6927
SELECT DISTINCT + 26 / col1 FROM tab1 AS cor0
----
1
2

query I rowsort
SELECT - + 75 * col0 AS col2 FROM tab2 AS cor0
----
-525
-5850
-5925

query I rowsort
SELECT ALL - col0 + col0 * + ( col2 * + col1 ) FROM tab1 AS cor0
----
36416
4209
99760

query I rowsort
SELECT + 7 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

query I rowsort
SELECT DISTINCT + col0 + cor0.col2 * 81 FROM tab2 AS cor0
----
2184
2194
3157

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6932
SELECT - - cor0.col1 * CAST( col2 AS SIGNED ) + col2 - ( cor0.col0 ) AS col2 FROM tab2 AS cor0
----
1482
605
857

skipif mysql # not compatible
query I rowsort label-6932
SELECT - - cor0.col1 * CAST ( col2 AS INTEGER ) + col2 - ( cor0.col0 ) AS col2 FROM tab2 AS cor0
----
1482
605
857

query I rowsort
SELECT DISTINCT + col2 + col2 * 41 FROM tab1 cor0
----
2268
2394
4032

onlyif mysql # use DIV operator for integer division
query I rowsort label-6934
SELECT DISTINCT - col2 + + col2 + - col1 * col0 DIV + cor0.col1 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-6934
SELECT DISTINCT - col2 + + col2 + - col1 * col0 / + cor0.col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT - - cor0.col1 - + 42 * col1 AS col0 FROM tab0 AS cor0
----
-3526
-3731
-3977

query I rowsort
SELECT DISTINCT cor0.col0 * cor0.col2 + col2 + - col1 AS col0 FROM tab1 AS cor0
----
190
3695
7763

query I rowsort
SELECT ALL - col0 * + ( 11 ) * + col0 FROM tab2 AS cor0
----
-539
-66924
-68651

query I rowsort
SELECT - col1 + col0 - + col1 AS col0 FROM tab0 AS cor0
----
-148
-159
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6939
SELECT - col1 * CAST( NULL AS SIGNED ) col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6939
SELECT - col1 * CAST ( NULL AS INTEGER ) col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 52 - - tab0.col1 AS col0 FROM tab0
----
138
143
149

onlyif mysql # use DIV operator for integer division
query I rowsort label-6941
SELECT col2 * - col1 DIV + ( col1 ) + col1 FROM tab0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-6941
SELECT col2 * - col1 / + ( col1 ) + col1 FROM tab0
----
53
9
96

query I rowsort
SELECT ALL + cor0.col0 + col2 + + col1 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT ALL - - col2 + - 31 * col1 AS col1 FROM tab2 AS cor0
----
-1803
-489
-934

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6944
SELECT DISTINCT col2 * CAST( NULL AS SIGNED ) + col0 col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6944
SELECT DISTINCT col2 * CAST ( NULL AS INTEGER ) + col0 col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + 61 + + col2 FROM tab1 AS cor0
----
115
118
157

query I rowsort
SELECT ALL - + 29 - col2 FROM tab1 AS cor0
----
-125
-83
-86

query I rowsort
SELECT - 91 + 76 FROM tab1 AS cor0
----
-15
-15
-15

onlyif mysql # use DIV operator for integer division
query I rowsort label-6948
SELECT DISTINCT + + col1 DIV col0 - + col2 AS col0 FROM tab2 AS cor0
----
-23
-26
-38

skipif mysql # not compatible
query I rowsort label-6948
SELECT DISTINCT + + col1 / col0 - + col2 AS col0 FROM tab2 AS cor0
----
-23
-26
-38

query I rowsort
SELECT - cor0.col0 * + 35 * - col0 FROM tab1 AS cor0
----
143360
224000
315

query I rowsort
SELECT ALL ( - col1 ) * cor0.col2 FROM tab0 cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6951
SELECT DISTINCT - cor0.col2 DIV + col1 col1 FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6951
SELECT DISTINCT - cor0.col2 / + col1 col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - 11 * - col2 + - col1 * - col0 FROM tab2 AS cor0
----
1761
4888
514

query I rowsort
SELECT - col2 * - col2 + col0 + col1 AS col2 FROM tab1 AS cor0
----
2945
3323
9309

query I rowsort
SELECT ALL - 98 + cor0.col1 * col2 * + 30 AS col2 FROM tab0 AS cor0
----
223762
2812
85042

query I rowsort
SELECT ALL + + 46 + + col1 * col0 AS col1 FROM tab2 cor0
----
1389
263
4648

query I rowsort
SELECT ALL + - 77 AS col1 FROM tab1 AS cor0
----
-77
-77
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 ) * + cor0.col0 col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + 59 * cor0.col2 + col1 FROM tab1 AS cor0
----
3212
3373
5677

query I rowsort
SELECT ALL - ( 37 ) FROM tab2 AS cor0
----
-37
-37
-37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6960
SELECT - - CAST( NULL AS SIGNED ) * - cor0.col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6960
SELECT - - CAST ( NULL AS INTEGER ) * - cor0.col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 + 23 * col1 * col1 FROM tab1 AS cor0
----
15551
2364
3967

onlyif mysql # use DIV operator for integer division
query I rowsort label-6962
SELECT - col1 DIV + col0 + - col1 * - 31 FROM tab2 AS cor0
----
1829
527
957

skipif mysql # not compatible
query I rowsort label-6962
SELECT - col1 / + col0 + - col1 * - 31 FROM tab2 AS cor0
----
1829
527
957

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 * + col0 col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - 88 + col2 FROM tab2 AS cor0
----
-50
-61
-62

query I rowsort
SELECT DISTINCT - - 78 - + col2 FROM tab1 AS cor0
----
-18
21
24

query I rowsort
SELECT DISTINCT - ( 34 ) AS col2 FROM tab0, tab0 AS cor0
----
-34

query I rowsort
SELECT DISTINCT 84 + col2 * - col2 FROM tab1
----
-2832
-3165
-9132

query I rowsort
SELECT - col2 * col1 + - col1 AS col2 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT ALL col2 + col0 - 51 AS col0 FROM tab0 AS cor0
----
-15
120
6

query I rowsort
SELECT ALL + + col2 * + col2 AS col1 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ( - tab0.col1 * - col1 ) + col1 AS col1 FROM tab0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT + ( col1 * + col1 ) + + col2 + ( col0 ) FROM tab1
----
221
345
733

query I rowsort
SELECT - - col0 * - col2 + + cor0.col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT + 40 * cor0.col0 FROM tab0 AS cor0
----
1400
3560
960

query I rowsort
SELECT + col2 * - 10 AS col1 FROM tab1 AS cor0
----
-540
-570
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-6976
SELECT ALL - - ( col0 ) DIV col2 AS col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-6976
SELECT ALL - - ( col0 ) / col2 AS col2 FROM tab0 AS cor0
----
0
1
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-6977
SELECT + col1 DIV cor0.col1 - + col1 * + col0 FROM tab1 AS cor0
----
-1039
-639
-77

skipif mysql # not compatible
query I rowsort label-6977
SELECT + col1 / cor0.col1 - + col1 * + col0 FROM tab1 AS cor0
----
-1039
-639
-77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6978
SELECT + + CAST( + col2 AS SIGNED ) * cor0.col1 col2 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6978
SELECT + + CAST ( + col2 AS INTEGER ) * cor0.col1 col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + 45 * + col1 AS col0 FROM tab0 AS cor0
----
3870
4095
4365

query I rowsort
SELECT DISTINCT tab1.col0 + + ( col1 + col2 ) FROM tab1
----
131
189
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + tab2.col1 * col0 col1 FROM tab2
----
1381
244
4628

query I rowsort
SELECT DISTINCT - 52 FROM tab1, tab2 AS cor0
----
-52

query I rowsort
SELECT - ( tab2.col0 ) * + col2 AS col0 FROM tab2
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col0 col0 FROM tab0
----
178
48
70

query I rowsort
SELECT DISTINCT - 81 * - col2 FROM tab2
----
2106
2187
3078

query I rowsort
SELECT ( - tab0.col1 * - col0 ) + col1 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT - 84 FROM tab2, tab0, tab1 AS cor0, tab1
----
81 values hashing to aaabc1266a1bb4f477091ffbc243c849

query I rowsort
SELECT DISTINCT + 62 * - col1 AS col0 FROM tab2 AS cor0
----
-1054
-1922
-3658

query I rowsort
SELECT DISTINCT - col2 + + 71 FROM tab0 AS cor0
----
-11
38
70

query I rowsort
SELECT ALL + col0 * - ( - col2 ) AS col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - - ( 21 ) + + col1 FROM tab2 AS cor0
----
38
52
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6992
SELECT ALL - + cor0.col2 DIV 90 + col1 * col1 AS col0 FROM tab1 AS cor0
----
100
168
676

skipif mysql # not compatible
query I rowsort label-6992
SELECT ALL - + cor0.col2 / 90 + col1 * col1 AS col0 FROM tab1 AS cor0
----
100
168
676

query I rowsort
SELECT ALL + ( - col1 ) * col1 + 4 FROM tab0 cor0
----
-7392
-8277
-9405

onlyif mysql # use DIV operator for integer division
query I rowsort label-6994
SELECT tab2.col0 - - 11 DIV col0 FROM tab2
----
78
79
8

skipif mysql # not compatible
query I rowsort label-6994
SELECT tab2.col0 - - 11 / col0 FROM tab2
----
78
79
8

query I rowsort
SELECT col1 + 77 AS col1 FROM tab2 AS cor0
----
108
136
94

query I rowsort
SELECT - - col1 * ( 32 ) FROM tab1 AS cor0
----
320
416
832

query I rowsort
SELECT + col2 * - 23 AS col0 FROM tab2 AS cor0
----
-598
-621
-874

query I rowsort
SELECT - - col2 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT + ( 47 * tab0.col2 ) + 0 AS col1 FROM tab0, tab1 AS cor0
----
1551
3854
47

query I rowsort
SELECT ALL - col1 * col0 + - col2 FROM tab2 AS cor0
----
-1381
-244
-4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7001
SELECT col1 * CAST( 63 AS SIGNED ) + col0 col0 FROM tab2
----
1150
1960
3795

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7001
SELECT col1 * CAST ( 63 AS INTEGER ) + col0 col0 FROM tab2
----
1150
1960
3795

query I rowsort
SELECT - col2 * col0 + - cor0.col1 * col1 AS col2 FROM tab0 AS cor0
----
-15579
-8188
-9444

query I rowsort
SELECT col1 * col0 * + ( col0 ) - - col2 AS col1 FROM tab2 AS cor0
----
106135
1546
358982

query I rowsort
SELECT + tab1.col1 * - col1 * + col2 FROM tab1
----
-16224
-36504
-5700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 48 col0 FROM tab0
----
48

query I rowsort
SELECT + col2 + col1 * + col0 AS col1 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT + + col0 + - col2 AS col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT + col2 * + tab1.col0 * col0 FROM tab1
----
233472
486
614400

query I rowsort
SELECT + 86 * + col2 FROM tab0
----
2838
7052
86

query I rowsort
SELECT - - col1 + col2 - ( - col0 + - 24 ) AS col1 FROM tab0 AS cor0
----
157
167
286

query I rowsort
SELECT ALL - col1 * + 85 + + col2 AS col2 FROM tab0 AS cor0
----
-7277
-7653
-8244

query I rowsort
SELECT cor0.col1 * 84 + - col0 + + col0 FROM tab0 AS cor0
----
7224
7644
8148

query I rowsort
SELECT DISTINCT + - col1 + cor0.col1 * - col1 FROM tab1 cor0
----
-110
-182
-702

query I rowsort
SELECT - + cor0.col0 - + col1 AS col1 FROM tab0 AS cor0
----
-110
-132
-180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7015
SELECT DISTINCT - + col2 / CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7015
SELECT DISTINCT - + col2 / CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 85 AS col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
85

query I rowsort
SELECT + col1 + col2 * + col2 * col2 FROM tab0
----
36023
551459
98

query I rowsort
SELECT + col2 + + 66 * tab0.col0 * + col1 + 89 * col0 * col2 AS col0 FROM tab0
----
1184138
206745
227186

query I rowsort
SELECT - col0 * + 83 + + 8 * + col2 * ( col1 * cor0.col2 ) - - ( col0 ) FROM tab0 AS cor0
----
-2094
4887774
747264

query I rowsort
SELECT ALL + ( - 21 ) FROM tab2, tab1 cor0
----
9 values hashing to 631fbd1fd929405aba54a22c2a06c757

query I rowsort
SELECT ALL - + col1 + col1 * col1 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT DISTINCT + + col2 * + col1 AS col1 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - cor0.col2 col0 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT - 30 AS col1 FROM tab2
----
-30
-30
-30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( 79 ) col2 FROM tab1
----
79

query I rowsort
SELECT ALL col1 * + col0 * + col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ALL - 48 + - col0 AS col0 FROM tab2 AS cor0
----
-126
-127
-55

query I rowsort
SELECT DISTINCT + col1 * - col0 + col2 * col1 * cor0.col1 + + col0 FROM tab0 AS cor0
----
242028
6049
671032

query I rowsort
SELECT ALL 8 * - col1 FROM tab2 AS cor0
----
-136
-248
-472

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 67 col0 FROM tab1 AS cor0
----
67
67
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-7031
SELECT col0 * 30 + - col0 DIV - col0 FROM tab0
----
1051
2671
721

skipif mysql # not compatible
query I rowsort label-7031
SELECT col0 * 30 + - col0 / - col0 FROM tab0
----
1051
2671
721

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7032
SELECT ALL + tab0.col0 * + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7032
SELECT ALL + tab0.col0 * + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( 44 ) FROM tab1
----
44
44
44

query I rowsort
SELECT DISTINCT 50 AS col0 FROM tab1, tab2 cor0
----
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-7035
SELECT DISTINCT col1 DIV - 34 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-7035
SELECT DISTINCT col1 / - 34 FROM tab1
----
0

query I rowsort
SELECT + col0 * - col0 + col2 * tab2.col0 * + col1 FROM tab2
----
113568
44793
5810

query I rowsort
SELECT DISTINCT ( 51 ) * + col2 AS col2 FROM tab0 AS cor0
----
1683
4182
51

query I rowsort
SELECT DISTINCT - - 86 + - col2 AS col1 FROM tab2 AS cor0
----
48
59
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7039
SELECT ALL - ( - col1 ) * + CAST( NULL AS SIGNED ) + col2 + col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7039
SELECT ALL - ( - col1 ) * + CAST ( NULL AS INTEGER ) + col2 + col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7040
SELECT ALL + col0 * - col1 + tab1.col2 DIV col0 FROM tab1
----
-1039
-60
-640

skipif mysql # not compatible
query I rowsort label-7040
SELECT ALL + col0 * - col1 + tab1.col2 / col0 FROM tab1
----
-1039
-60
-640

query I rowsort
SELECT tab0.col0 * col2 + col1 * - tab0.col2 FROM tab0
----
-164
-2046
-62

query I rowsort
SELECT cor0.col2 * + col1 + - col2 * col0 AS col1 FROM tab2 cor0
----
-2356
-494
648

query I rowsort
SELECT + 56 - + col2 AS col0 FROM tab0
----
-26
23
55

query I rowsort
SELECT ALL - col2 + + col1 * + 75 * - col0 AS col2 FROM tab2 cor0
----
-100763
-16302
-345176

query I rowsort
SELECT DISTINCT - - col1 - + cor0.col0 AS col0 FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT + - 5 AS col0 FROM tab0 AS cor0
----
-5
-5
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-7047
SELECT ALL - - ( - cor0.col1 ) DIV cor0.col2 + + 40 FROM tab1 AS cor0
----
40
40
40

skipif mysql # not compatible
query I rowsort label-7047
SELECT ALL - - ( - cor0.col1 ) / cor0.col2 + + 40 FROM tab1 AS cor0
----
40
40
40

query I rowsort
SELECT ALL - col2 * ( 96 * + col2 ) AS col1 FROM tab1 AS cor0
----
-279936
-311904
-884736

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7049
SELECT - + col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7049
SELECT - + col0 + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + + col0 * col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT col2 * 40 + - cor0.col0 FROM tab1 AS cor0
----
2157
2216
3760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7052
SELECT ALL + col2 + + CAST( + col2 + col0 AS SIGNED ) AS col2 FROM tab1 cor0
----
111
178
272

skipif mysql # not compatible
query I rowsort label-7052
SELECT ALL + col2 + + CAST ( + col2 + col0 AS INTEGER ) AS col2 FROM tab1 cor0
----
111
178
272

query I rowsort
SELECT + cor0.col0 + 65 AS col0 FROM tab0 AS cor0
----
100
154
89

query I rowsort
SELECT DISTINCT + col2 * 56 FROM tab1 AS cor0
----
3024
3192
5376

query I rowsort
SELECT DISTINCT col2 * 51 FROM tab2 AS cor0
----
1326
1377
1938

onlyif mysql # use DIV operator for integer division
query I rowsort label-7056
SELECT + col0 DIV col0 + + col1 * col1 * col0 col2 FROM tab0 AS cor0
----
177505
329316
737010

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7056
SE