sqllogictest
Artifact Content
Not logged in

Artifact 5d4e7dbeec645bdeb9dba786f53ca252e48fd12b:


hash-threshold 8

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

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

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

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

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

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-0
SELECT ALL ( 17 ) DIV col0 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-0
SELECT ALL ( 17 ) / col0 FROM tab2
----
0
0
2

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2
SELECT ALL - CAST( col1 + col0 AS SIGNED ) AS col0 FROM tab2
----
-137
-38
-96

skipif mysql # not compatible
query I rowsort label-2
SELECT ALL - CAST ( col1 + col0 AS INTEGER ) AS col0 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT ( + 53 ) AS col2 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT ALL - 36 * col2 AS col1 FROM tab1
----
-1944
-2052
-3456

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + 72 * - col0 + - ( - col0 + - col2 ) AS col2 FROM tab1 cor0
----
-159
-4487
-5584

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + 69 + + col0 * + 88 col0 FROM tab0 AS cor0
----
1691
456
665

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

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

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

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

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

query I rowsort
SELECT + col1 * col2 + col0 + - cor0.col2 * cor0.col2 FROM tab0 AS cor0
----
131
1773
827

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( 19 ) * - col1 + + col0 col0 FROM tab2 cor0
----
1199
402
596

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

query I rowsort
SELECT ALL ( - 43 ) + col0 AS col1 FROM tab2 cor0
----
-36
35
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-21
SELECT ALL 41 + - col2 DIV - col0 + + col1 AS col1 FROM tab1 cor0
----
51
55
85

skipif mysql # not compatible
query I rowsort label-21
SELECT ALL 41 + - col2 / - col0 + + col1 AS col1 FROM tab1 cor0
----
51
55
85

query I rowsort
SELECT col2 * - 26 * cor0.col2 AS col0 FROM tab2 AS cor0
----
-17576
-18954
-37544

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

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

query I rowsort
SELECT 30 + 43 AS col0 FROM tab2 AS cor0
----
73
73
73

query I rowsort
SELECT ALL col0 * - col0 * + col0 + col0 * col0 FROM tab1 AS cor0
----
-18
-258048
-505600

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

query I rowsort
SELECT ALL col1 * 20 + col2 FROM tab1 AS cor0
----
257
356
574

query I rowsort
SELECT - col2 + + ( - 0 ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

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

query I rowsort
SELECT - 3 + cor1.col1 + - 6 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 671edd7473937b2d9e0f34abbb673997

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + col1 col2 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT + col0 + - ( + 17 ) * col1 FROM tab0 AS cor0
----
-1438
-1458
-1614

query I rowsort
SELECT - col1 + + 36 AS col1 FROM tab0 AS cor0
----
-50
-55
-61

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

query I rowsort
SELECT - 93 + col2 AS col1 FROM tab1 AS cor0
----
-36
-39
3

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-37
SELECT col1 + + 53 DIV + 51 AS col0 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-37
SELECT col1 + + 53 / + 51 AS col0 FROM tab1
----
11
14
27

query I rowsort
SELECT DISTINCT col2 + col0 * - col1 * + tab2.col2 FROM tab2
----
-119626
-50996
-5832

query I rowsort
SELECT 89 + - cor0.col2 * - col0 - col1 FROM tab2 AS cor0
----
2058
247
3074

onlyif mysql # use DIV operator for integer division
query I rowsort label-40
SELECT + cor0.col2 DIV 12 + col2 AS col2 FROM tab1 AS cor0
----
104
58
61

skipif mysql # not compatible
query I rowsort label-40
SELECT + cor0.col2 / 12 + col2 AS col2 FROM tab1 AS cor0
----
104
58
61

query I rowsort
SELECT - + ( col2 ) + - col1 + 62 FROM tab2 AS cor0
----
-23
4
7

query I rowsort
SELECT ALL 88 FROM tab0, tab0 cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

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

query I rowsort
SELECT DISTINCT + col2 * + 58 AS col0 FROM tab1
----
3132
3306
5568

query I rowsort
SELECT + col0 - - col0 FROM tab1
----
128
160
6

query I rowsort
SELECT DISTINCT + col1 * ( col2 + - col2 ) * ( - 73 * + col1 ) FROM tab2
----
0

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

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

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

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

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

query I rowsort
SELECT - + col2 + cor0.col1 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + - col0 * ( - 9 ) FROM tab2 AS cor0
----
63
702
711

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

skipif mysql # not compatible
query I rowsort label-54
SELECT - col2 + CAST ( col1 AS INTEGER ) AS col0 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT ALL + col1 + 90 FROM tab2 AS cor0
----
107
121
149

onlyif mysql # use DIV operator for integer division
query I rowsort label-56
SELECT + 45 * - col1 DIV - col1 FROM tab0 cor0
----
45
45
45

skipif mysql # not compatible
query I rowsort label-56
SELECT + 45 * - col1 / - col1 FROM tab0 cor0
----
45
45
45

query I rowsort
SELECT DISTINCT + - col0 * + 94 + - col1 FROM tab1 cor0
----
-308
-6026
-7533

query I rowsort
SELECT + + 65 * - col2 + col0 AS col2 FROM tab2 cor0
----
-1612
-1748
-2391

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

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

query I rowsort
SELECT 42 AS col0 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * ( + cor0.col0 + + col1 ) * col2 col2 FROM tab2 AS cor0
----
-277836
-288192
-7182

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

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

query I rowsort
SELECT ALL 39 + col1 AS col2 FROM tab1
----
49
52
65

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

skipif mysql # not compatible
query I rowsort label-67
SELECT col2 * + tab2.col1 / + tab2.col0 - - tab2.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 ALL col0 + col2 + col1 * col1 col0 FROM tab1 AS cor0
----
221
345
733

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

query I rowsort
SELECT ALL + col2 * - col1 + col2 + col2 AS col0 FROM tab2 AS cor0
----
-1482
-570
-783

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

query I rowsort
SELECT + 68 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

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

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

skipif mysql # not compatible
query I rowsort label-74
SELECT ALL - col1 / CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

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

query I rowsort
SELECT col2 * + col2 + col2 * col1 FROM tab2
----
1566
2090
2210

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

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

query I rowsort
SELECT col0 * col1 * - ( - col0 * col2 ) AS col0 FROM tab0 AS cor0
----
118825
1634688
59106502

query I rowsort
SELECT DISTINCT + col1 * col1 * - col1 FROM tab0
----
-636056
-753571
-912673

query I rowsort
SELECT col2 * 63 + - col1 FROM tab2
----
1579
1670
2377

onlyif mysql # use DIV operator for integer division
query I rowsort label-82
SELECT ALL 54 DIV 42 - - tab0.col2 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-82
SELECT ALL 54 / 42 - - tab0.col2 FROM tab0
----
2
34
83

query I rowsort
SELECT DISTINCT col1 * + 43 * col2 - + 4 FROM tab2
----
27774
35987
65958

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

query I rowsort
SELECT DISTINCT + + 52 * + col0 FROM tab0 AS cor0
----
1248
1820
4628

query I rowsort
SELECT ALL 91 * + cor0.col0 + col1 * col2 FROM tab0 AS cor0
----
15561
3282
5022

query I rowsort
SELECT DISTINCT + 37 + + 65 * - col2 * - col1 FROM tab2
----
42027
54442
99747

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

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

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT col1 * + col2 + col1 FROM tab2 AS cor0
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 25 + col1 col0 FROM tab1 AS cor0
----
-12
-15
1

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

query I rowsort
SELECT - - ( + col0 ) * 34 AS col2 FROM tab0 AS cor0
----
1190
3026
816

query I rowsort
SELECT DISTINCT + - 54 + - col2 * col2 AS col2 FROM tab0 AS cor0
----
-1143
-55
-6778

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT - col2 * - col0 + - col1 * - cor0.col1 - - col2 FROM tab2 cor0
----
1177
3329
5535

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

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

query I rowsort
SELECT DISTINCT + 32 AS col1 FROM tab0 AS cor0
----
32

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

query I rowsort
SELECT DISTINCT + 87 * cor0.col2 FROM tab1 AS cor0
----
4698
4959
8352

query I rowsort
SELECT + col2 * col1 + + cor0.col2 * col0 - col2 FROM tab1 AS cor0
----
1512
4161
8832

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

query I rowsort
SELECT 8 + - col2 * col1 AS col1 FROM tab2 AS cor0
----
-1526
-638
-829

query I rowsort
SELECT + 99 * col0 AS col2 FROM tab1
----
297
6336
7920

query I rowsort
SELECT DISTINCT 40 + + col0 AS col2 FROM tab2
----
118
119
47

query I rowsort
SELECT + col0 + col2 + - col0 * + col2 FROM tab1
----
-105
-3527
-7504

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

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

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

query I rowsort
SELECT DISTINCT - col2 * col2 - + col1 * - col0 FROM tab0
----
1375
3394
975

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

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

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

query I rowsort
SELECT ALL + + 15 * col2 * col1 AS col2 FROM tab2 AS cor0
----
12555
23010
9690

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-133
SELECT - col0 DIV - col0 + col0 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-133
SELECT - col0 / - col0 + col0 FROM tab0
----
25
36
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-134
SELECT DISTINCT col2 * col2 - tab1.col0 DIV col2 FROM tab1
----
2916
3248
9216

skipif mysql # not compatible
query I rowsort label-134
SELECT DISTINCT col2 * col2 - tab1.col0 / col2 FROM tab1
----
2916
3248
9216

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE - col1 IN ( col0 * col1 / - col1 )
----

query I rowsort
SELECT DISTINCT - col1 * col0 * col2 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT col0 + + col1 * - col0 * col1 AS col2 FROM tab1
----
-13440
-2025
-6336

onlyif mysql # use DIV operator for integer division
query I rowsort label-138
SELECT + col2 * col2 DIV - col0 + col0 FROM tab1
----
-35
-969
14

skipif mysql # not compatible
query I rowsort label-138
SELECT + col2 * col2 / - col0 + col0 FROM tab1
----
-35
-969
14

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-142
SELECT + col0 DIV + col2 + + col2 FROM tab0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-142
SELECT + col0 / + col2 + + col2 FROM tab0
----
33
36
83

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

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL < - col1 * col2
----

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

query I rowsort
SELECT col2 FROM tab1 WHERE NOT NULL >= NULL
----

query I rowsort
SELECT col1 * tab1.col1 + col1 AS col2 FROM tab1
----
110
182
702

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

query I rowsort
SELECT + col1 AS col2 FROM tab2 WHERE NOT NULL <= ( - col2 )
----

query I rowsort
SELECT col1 * - col1 + tab2.col1 + - tab2.col2 * + col0 FROM tab2
----
-1119
-3274
-5450

query I rowsort
SELECT ALL col2 + tab0.col2 - + col0 * - col1 FROM tab0
----
2130
3397
8263

query I rowsort
SELECT DISTINCT + col1 * col2 + tab0.col0 + - col1 AS col0 FROM tab0
----
2776
35
7460

query I rowsort
SELECT col0 + col2 * + col2 * + col1 FROM tab0
----
132
611973
93678

query I rowsort
SELECT DISTINCT tab0.col2 * tab0.col0 - col0 * col1 FROM tab0
----
-1272
-3360
-801

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

query I rowsort
SELECT DISTINCT - col2 * col2 * col1 AS col2 FROM tab1
----
-119808
-32490
-75816

query I rowsort
SELECT ALL + tab0.col2 * - col1 * col2 FROM tab0
----
-611884
-93654
-97

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-160
SELECT - col2 * - tab1.col0 DIV col0 AS col0 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-160
SELECT - col2 * - tab1.col0 / col0 AS col0 FROM tab1
----
54
57
96

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

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

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

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL = NULL
----

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

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

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

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

query I rowsort
SELECT ALL cor0.col2 FROM tab1, tab2 AS cor0 WHERE NOT NULL = ( NULL )
----

query III rowsort
SELECT * FROM tab1 WHERE NULL IN ( + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-171
SELECT col1 DIV + col1 - col2 col1 FROM tab0
----
-32
-81
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-171
SELECT col1 / + col1 - col2 col1 FROM tab0
----
-32
-81
0

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - col2 + col1 col1 FROM tab1
----
-2
-37
-70

query I rowsort
SELECT col0 FROM tab2 AS cor0 WHERE NULL < col0 + col2
----

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

query I rowsort
SELECT + 33 * col1 AS col1 FROM tab1 AS cor0
----
330
429
858

onlyif mysql # use DIV operator for integer division
query I rowsort label-177
SELECT DISTINCT - - col2 * - cor0.col0 + ( - cor0.col2 ) DIV cor0.col2 FROM tab1 cor0
----
-163
-3649
-7681

skipif mysql # not compatible
query I rowsort label-177
SELECT DISTINCT - - col2 * - cor0.col0 + ( - cor0.col2 ) / cor0.col2 FROM tab1 cor0
----
-163
-3649
-7681

onlyif mysql # use DIV operator for integer division
query I rowsort label-178
SELECT DISTINCT - cor0.col1 * 34 - + 75 DIV + cor0.col0 AS col0 FROM tab2, tab0 AS cor0
----
-2927
-3094
-3300

skipif mysql # not compatible
query I rowsort label-178
SELECT DISTINCT - cor0.col1 * 34 - + 75 / + cor0.col0 AS col0 FROM tab2, tab0 AS cor0
----
-2927
-3094
-3300

query I rowsort
SELECT ALL - + 12 * col1 * - ( - cor0.col1 ) + + col0 * col2 FROM tab0 AS cor0
----
-112873
-87960
-92074

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

query I rowsort
SELECT - 21 * + col0 + cor0.col1 FROM tab2 AS cor0
----
-116
-1579
-1642

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 42 * - col0 col2 FROM tab2 AS cor0
----
294
3276
3318

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

skipif mysql # not compatible
query I rowsort label-183
SELECT DISTINCT col1 + CAST ( col0 * - col2 + col2 AS INTEGER ) FROM tab1
----
-3581
-7571
-82

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

query I rowsort
SELECT col0 * 62 + + col1 AS col1 FROM tab0 AS cor0
----
1574
2267
5609

query I rowsort
SELECT - - col1 * - 30 + + col2 * cor0.col0 FROM tab2 AS cor0
----
-741
2492
258

query I rowsort
SELECT + col2 * - 45 + col1 * 49 FROM tab0 AS cor0
----
2729
4708
769

query I rowsort
SELECT ALL + + col0 - 20 AS col1 FROM tab0 cor0
----
15
4
69

query I rowsort
SELECT + col2 * - col2 * col1 + col2 * + 11 AS col1 FROM tab2 cor0
----
-22302
-24130
-39598

onlyif mysql # use DIV operator for integer division
query I rowsort label-190
SELECT DISTINCT - - col1 * col2 + col1 DIV + 88 FROM tab2 cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-190
SELECT DISTINCT - - col1 * col2 + col1 / + 88 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT - + 36 FROM tab2 AS cor0
----
-36
-36
-36

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

query I rowsort
SELECT + + 94 + + col0 AS col2 FROM tab0 cor0
----
118
129
183

onlyif mysql # use DIV operator for integer division
query I rowsort label-194
SELECT ALL 64 + + 90 DIV - col1 FROM tab0 AS cor0
----
63
64
64

skipif mysql # not compatible
query I rowsort label-194
SELECT ALL 64 + + 90 / - col1 FROM tab0 AS cor0
----
63
64
64

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

query I rowsort
SELECT DISTINCT + cor0.col1 + - tab1.col2 AS col1 FROM tab1, tab1 AS cor0
----
-28
-31
-41
-44
-47
-70
-83
-86

query I rowsort
SELECT ALL + 93 AS col2 FROM tab0 AS cor0
----
93
93
93

query I rowsort
SELECT - 36 + - col1 FROM tab2 AS cor0
----
-53
-67
-95

query I rowsort
SELECT - cor0.col2 + 96 AS col1 FROM tab0 AS cor0
----
14
63
95

query I rowsort
SELECT DISTINCT - - 87 * + col2 + + col0 * + col0 FROM tab2 AS cor0
----
2398
8346
9547

query I rowsort
SELECT ALL col0 + ( col1 ) * cor0.col0 - - col0 FROM tab2 AS cor0
----
1501
231
4758

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-206
SELECT ALL 40 DIV col1 + + col0 AS col1 FROM tab1 AS cor0
----
4
68
83

skipif mysql # not compatible
query I rowsort label-206
SELECT ALL 40 / col1 + + col0 AS col1 FROM tab1 AS cor0
----
4
68
83

query I rowsort
SELECT ALL 2 FROM tab1, tab0 cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

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

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

query I rowsort
SELECT DISTINCT + - ( col0 ) AS col2 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT ALL + 88 + + ( col1 ) AS col2 FROM tab1 AS cor0
----
101
114
98

query I rowsort
SELECT + - 37 + + ( + cor0.col0 + + col2 ) * 51 FROM tab2 AS cor0
----
1697
5267
5930

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

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

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

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

query I rowsort
SELECT + 46 * + 96 + + col2 AS col0 FROM tab1 AS cor0
----
4470
4473
4512

query I rowsort
SELECT DISTINCT + 84 * - col2 FROM tab2 AS cor0
----
-2184
-2268
-3192

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

query I rowsort
SELECT - + 35 * - 31 FROM tab1 AS cor0
----
1085
1085
1085

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

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

query I rowsort
SELECT ( 74 ) + - col2 AS col0 FROM tab2
----
36
47
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-222
SELECT ALL + - 40 * col1 DIV col2 FROM tab1 cor0
----
-19
-5
-7

skipif mysql # not compatible
query I rowsort label-222
SELECT ALL + - 40 * col1 / col2 FROM tab1 cor0
----
-19
-5
-7

query I rowsort
SELECT + cor0.col1 + - col1 * 83 FROM tab2 AS cor0
----
-1394
-2542
-4838

onlyif mysql # use DIV operator for integer division
query I rowsort label-224
SELECT - - col1 * cor0.col0 DIV + col1 + 70 AS col0 FROM tab1 AS cor0
----
134
150
73

skipif mysql # not compatible
query I rowsort label-224
SELECT - - col1 * cor0.col0 / + col1 + 70 AS col0 FROM tab1 AS cor0
----
134
150
73

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

query I rowsort
SELECT ALL + col2 * - 53 * tab2.col0 + - col2 AS col2 FROM tab2
----
-10044
-107510
-159144

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

query I rowsort
SELECT ALL + + 5 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 77 * col2 * - tab2.col1 col0 FROM tab2
----
118118
49742
64449

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

query I rowsort
SELECT col2 + ( + col2 * col2 ) - + 77 AS col0 FROM tab1 AS cor0
----
2893
3229
9235

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

query I rowsort
SELECT ALL - col0 * + cor0.col1 * + ( col0 + cor0.col1 * + col0 ) FROM tab1 AS cor0
----
-1164800
-450560
-6318

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

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

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

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

query I rowsort
SELECT - + col2 * + 84 + 77 FROM tab1 AS cor0
----
-4459
-4711
-7987

query I rowsort
SELECT - + col1 + 95 FROM tab0 AS cor0
----
-2
4
9

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

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0, tab1 cor1, tab0 cor2
----
972 values hashing to 95920403df268a272c4e933cd0bbe0be

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-242
SELECT cor0.col1 * CAST( 66 AS SIGNED ) AS col0 FROM tab2 cor0
----
1122
2046
3894

skipif mysql # not compatible
query I rowsort label-242
SELECT cor0.col1 * CAST ( 66 AS INTEGER ) AS col0 FROM tab2 cor0
----
1122
2046
3894

query I rowsort
SELECT + col2 + col1 * col2 + - col1 AS col0 FROM tab2 AS cor0
----
1501
667
833

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

query I rowsort
SELECT DISTINCT - - col1 * 83 + + 67 + - col1 * col0 FROM tab0 cor0
----
-479
4723
5141

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

query I rowsort
SELECT + col2 * ( 23 ) + col0 AS col0 FROM tab1 AS cor0
----
1245
1375
2288

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

query I rowsort
SELECT + col2 + - 35 FROM tab1 AS cor0
----
19
22
61

query I rowsort
SELECT ALL 49 AS col1 FROM tab2 AS cor0
----
49
49
49

query I rowsort
SELECT DISTINCT - + 14 * 61 AS col0 FROM tab1 AS cor0
----
-854

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

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

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

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

skipif mysql # not compatible
query I rowsort label-255
SELECT DISTINCT + CAST ( cor0.col1 AS INTEGER ) + + col0 * + col2 * col0 AS col1 FROM tab1 AS cor0
----
233482
512
614413

query I rowsort
SELECT 89 * col1 AS col0 FROM tab0 AS cor0
----
7654
8099
8633

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - 56 col2 FROM tab2 cor0
----
392
4368
4424

query I rowsort
SELECT ALL + 66 * + 23 + - col2 - 24 AS col2 FROM tab1 AS cor0
----
1398
1437
1440

query I rowsort
SELECT DISTINCT col0 * + 41 FROM tab1 cor0
----
123
2624
3280

query I rowsort
SELECT - 34 * cor0.col0 * + cor0.col2 FROM tab0 cor0
----
-1190
-248132
-26928

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

query I rowsort
SELECT - col1 * col1 * col1 + cor0.col0 * col1 FROM tab0 cor0
----
-633992
-745472
-909278

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 91 * - col1 + col2 col1 FROM tab2 AS cor0
----
1585
2848
5395

query I rowsort
SELECT - 89 + col0 * col1 FROM tab2 AS cor0
----
1254
128
4513

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-269
SELECT DISTINCT + + 83 / - col0 col1 FROM tab0 AS cor0
----
-2
-3
0

query I rowsort
SELECT + + ( col1 ) * + ( 34 ) FROM tab1 cor0
----
340
442
884

query I rowsort
SELECT ALL - 64 AS col2 FROM tab1 AS cor0
----
-64
-64
-64

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

query I rowsort
SELECT - - col2 * ( col2 ) + - cor0.col2 - - col1 FROM tab2 AS cor0
----
1423
709
733

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 52 col1 FROM tab0, tab2 AS cor0, tab0 AS cor1, tab1, tab1 AS cor2
----
243 values hashing to d8cc00265be49df5e89f33bc08ab6f6d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col2 + col0 + + col2 col0 FROM tab2
----
2132
223
3119

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 + + cor0.col1 col2 FROM tab1, tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - cor1.col1 FROM tab0, tab2 cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to 786a240f80bef6f9c6a190e92cd4f9e8

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

skipif mysql # not compatible
query I rowsort label-280
SELECT DISTINCT + CAST ( col2 * tab0.col2 AS INTEGER ) AS col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT 59 * col0 FROM tab0 cor0
----
1416
2065
5251

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

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

query I rowsort
SELECT + col1 + + 26 FROM tab1 AS cor0
----
36
39
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * ( col0 ) + - col1 col2 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT ALL + col2 + 46 AS col1 FROM tab2 AS cor0
----
72
73
84

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-287
SELECT - + col2 + col1 DIV col1 AS col2 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-287
SELECT - + col2 + col1 / col1 AS col2 FROM tab1 AS cor0
----
-53
-56
-95

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

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

skipif mysql # not compatible
query I rowsort label-289
SELECT DISTINCT + col0 / - 36 AS col2 FROM tab1 AS cor0
----
-1
-2
0

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-292
SELECT + + col1 + CAST( + 16 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
33
47
75

skipif mysql # not compatible
query I rowsort label-292
SELECT + + col1 + CAST ( + 16 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
33
47
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col0 * tab2.col1 - + col2 col1 FROM tab2
----
22793
271492
6700

query I rowsort
SELECT - 9 + - tab1.col2 * - col2 + ( col0 * + ( col0 ) ) AS col2 FROM tab1
----
15607
2916
7336

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

query I rowsort
SELECT DISTINCT - - col1 - cor0.col2 FROM tab2 AS cor0
----
-21
33
4

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

skipif mysql # not compatible
query I rowsort label-297
SELECT + - col2 - + CAST ( col1 AS INTEGER ) * - col0 AS col1 FROM tab2 AS cor0
----
1305
190
4576

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

query I rowsort
SELECT DISTINCT + 33 FROM tab0, tab2 AS cor0, tab2 AS cor1, tab1 AS cor2
----
33

query I rowsort
SELECT ALL col1 * - col0 * tab0.col2 + + tab0.col0 FROM tab0
----
-3360
-664029
-68088

query I rowsort
SELECT DISTINCT + + 46 + cor0.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
56
59
72

query I rowsort
SELECT ALL 58 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

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

query I rowsort
SELECT DISTINCT + col2 * 37 AS col0 FROM tab2 AS cor0
----
1406
962
999

query I rowsort
SELECT ALL - 33 * + cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 42dfc5922d37b929c26236266da289e0

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

query I rowsort
SELECT ALL - 96 FROM tab0, tab1 cor0
----
9 values hashing to c89b545346f99713888a7934e4caa539

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-309
SELECT DISTINCT 64 DIV + col1 + - tab2.col2 + + col0 * col0 AS col2 FROM tab2
----
24
6059
6206

skipif mysql # not compatible
query I rowsort label-309
SELECT DISTINCT 64 / + col1 + - tab2.col2 + + col0 * col0 AS col2 FROM tab2
----
24
6059
6206

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-311
SELECT DISTINCT - col1 DIV col0 + 59 FROM tab0
----
56
57
58

skipif mysql # not compatible
query I rowsort label-311
SELECT DISTINCT - col1 / col0 + 59 FROM tab0
----
56
57
58

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-313
SELECT ALL 79 * + col1 * CAST( - col2 AS SIGNED ) + - col1 AS col2 FROM tab0
----
-224288
-589589
-7760

skipif mysql # not compatible
query I rowsort label-313
SELECT ALL 79 * + col1 * CAST ( - col2 AS INTEGER ) + - col1 AS col2 FROM tab0
----
-224288
-589589
-7760

query I rowsort
SELECT DISTINCT 33 + + col1 FROM tab1
----
43
46
59

query I rowsort
SELECT DISTINCT - ( col0 ) + - col1 + + col2 * - col0 FROM tab0
----
-167
-7478
-902

onlyif mysql # use DIV operator for integer division
query I rowsort label-316
SELECT + + ( - col0 ) DIV - col1 - col0 * + col2 * - col2 AS col1 FROM tab1 AS cor0
----
207942
737286
8748

skipif mysql # not compatible
query I rowsort label-316
SELECT + + ( - col0 ) / - col1 - col0 * + col2 * - col2 AS col1 FROM tab1 AS cor0
----
207942
737286
8748

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

query I rowsort
SELECT ALL - col2 + - col1 * - col1 AS col1 FROM tab2 AS cor0
----
251
3455
934

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

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

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

query I rowsort
SELECT ALL + col2 * col0 + + 49 FROM tab0 AS cor0
----
7347
84
841

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

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

query I rowsort
SELECT DISTINCT col0 * - 36 AS col2 FROM tab1 AS cor0
----
-108
-2304
-2880

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-325
SELECT + + col2 DIV 38 + - cor0.col0 FROM tab1 cor0
----
-2
-63
-78

skipif mysql # not compatible
query I rowsort label-325
SELECT + + col2 / 38 + - cor0.col0 FROM tab1 cor0
----
-2
-63
-78

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

query I rowsort
SELECT cor0.col1 - 75 AS col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to fbce4dd3093bba7bdbab6b1fbb473c21

query I rowsort
SELECT DISTINCT 65 * col1 AS col1 FROM tab2 AS cor0
----
1105
2015
3835

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

query I rowsort
SELECT - 97 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to e4a6bd848a69226cbb7ad3d154be321b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-331
SELECT ALL - CAST( 18 + col1 AS SIGNED ) * - col0 FROM tab0
----
2496
4025
9701

skipif mysql # not compatible
query I rowsort label-331
SELECT ALL - CAST ( 18 + col1 AS INTEGER ) * - col0 FROM tab0
----
2496
4025
9701

onlyif mysql # use DIV operator for integer division
query I rowsort label-332
SELECT DISTINCT + cor0.col0 - ( - col0 ) DIV - 48 AS col2 FROM tab2 AS cor0
----
7
77
78

skipif mysql # not compatible
query I rowsort label-332
SELECT DISTINCT + cor0.col0 - ( - col0 ) / - 48 AS col2 FROM tab2 AS cor0
----
7
77
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-333
SELECT ALL col0 * - 61 - - cor0.col1 DIV cor0.col2 FROM tab0 AS cor0
----
-1462
-2038
-5428

skipif mysql # not compatible
query I rowsort label-333
SELECT ALL col0 * - 61 - - cor0.col1 / cor0.col2 FROM tab0 AS cor0
----
-1462
-2038
-5428

query I rowsort
SELECT DISTINCT + 70 + + col2 AS col2 FROM tab0 AS cor0
----
103
152
71

query I rowsort
SELECT 88 + cor0.col1 FROM tab2 cor0
----
105
119
147

query I rowsort
SELECT ALL ( col1 ) * - col0 + + 41 AS col0 FROM tab1 AS cor0
----
-37
-599
-999

query I rowsort
SELECT ALL + + col1 * 32 + - col1 AS col1 FROM tab0 cor0
----
2666
2821
3007

query I rowsort
SELECT DISTINCT + col2 + + 20 AS col0 FROM tab0 AS cor0
----
102
21
53

query I rowsort
SELECT + - 50 * + cor0.col0 + - ( - cor0.col1 ) AS col0 FROM tab1 AS cor0
----
-124
-3190
-3987

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

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

query I rowsort
SELECT DISTINCT cor0.col0 + + col0 - - col1 AS col1 FROM tab0 AS cor0
----
134
167
269

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

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

query I rowsort
SELECT ALL + 98 FROM tab1
----
98
98
98

query I rowsort
SELECT col0 * 2 FROM tab2 AS cor0
----
14
156
158

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

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

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

query I rowsort
SELECT ALL + 53 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT - 90 * - tab2.col0 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 8624d337b50d843925771a840f6703e1

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-351
SELECT - CAST( 19 AS SIGNED ) AS col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 0fbbff28a7b63c37b01cf369f9325662

skipif mysql # not compatible
query I rowsort label-351
SELECT - CAST ( 19 AS INTEGER ) AS col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 0fbbff28a7b63c37b01cf369f9325662

query I rowsort
SELECT + col2 * 76 AS col2 FROM tab0 AS cor0
----
2508
6232
76

query I rowsort
SELECT 56 * - 55 FROM tab2 AS cor0
----
-3080
-3080
-3080

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

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

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

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

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

query I rowsort
SELECT - + 94 * - col1 + - 93 FROM tab1 cor0
----
1129
2351
847

onlyif mysql # use DIV operator for integer division
query I rowsort label-360
SELECT DISTINCT + col0 * col0 DIV col2 FROM tab0
----
1225
17
96

skipif mysql # not compatible
query I rowsort label-360
SELECT DISTINCT + col0 * col0 / col2 FROM tab0
----
1225
17
96

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

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

query I rowsort
SELECT DISTINCT col0 * 95 + + cor0.col2 * cor0.col1 AS col2 FROM tab2 cor0
----
1502
8151
8944

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-366
SELECT + + cor0.col0 / + 71 FROM tab2 AS cor0
----
0
1
1

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

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

query I rowsort
SELECT + col0 + 26 FROM tab2
----
104
105
33

query I rowsort
SELECT col1 + + 76 FROM tab1
----
102
86
89

query I rowsort
SELECT - 14 FROM tab0, tab0 AS cor0
----
9 values hashing to d321461994ba49c3a70fa6373032fc94

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

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

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

query I rowsort
SELECT DISTINCT + - col2 * cor0.col2 * + col2 + 87 * - col1 AS col2 FROM tab1 AS cor0
----
-159726
-186063
-885867

query I rowsort
SELECT 30 AS col2 FROM tab1 AS cor0
----
30
30
30

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

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

query I rowsort
SELECT ALL - - col1 * + ( - col2 + col1 ) AS col1 FROM tab2 AS cor0
----
-357
124
1947

query I rowsort
SELECT cor0.col1 * + cor0.col2 AS col0 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to 00f153c5d80e692faff5018d8701b92d

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-381
SELECT + 69 DIV - cor0.col1 FROM tab1 AS cor0
----
-2
-5
-6

skipif mysql # not compatible
query I rowsort label-381
SELECT + 69 / - cor0.col1 FROM tab1 AS cor0
----
-2
-5
-6

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

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

query I rowsort
SELECT DISTINCT - 5 + 68 * cor0.col0 FROM tab1 AS cor0
----
199
4347
5435

query I rowsort
SELECT + 16 * - col0 + 95 AS col0 FROM tab0 AS cor0
----
-1329
-289
-465

query I rowsort
SELECT + 10 * - col0 FROM tab2 AS cor0
----
-70
-780
-790

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 16 + + col2 col0 FROM tab0
----
17
49
98

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

query I rowsort
SELECT col0 * col2 + 75 FROM tab1 cor0
----
237
3723
7755

query I rowsort
SELECT ALL + col1 * - col2 + - col2 - col1 AS col2 FROM tab0 cor0
----
-195
-2957
-7635

onlyif mysql # use DIV operator for integer division
query I rowsort label-390
SELECT DISTINCT + col1 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-390
SELECT DISTINCT + col1 / - col2 col2 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT DISTINCT - - 29 + + col0 FROM tab0 AS cor0
----
118
53
64

query I rowsort
SELECT + + col1 + col0 * + 82 AS col0 FROM tab1 cor0
----
272
5258
6573

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

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

query I rowsort
SELECT DISTINCT col0 * - col0 + 43 AS col0 FROM tab0 AS cor0
----
-1182
-533
-7878

query I rowsort
SELECT 97 AS col1 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

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

query I rowsort
SELECT ALL 59 + - col0 * col0 * tab0.col1 FROM tab0
----
-118766
-49477
-720752

query I rowsort
SELECT - col2 * ( + col0 ) + - col2 * ( col1 ) FROM tab2 cor0
----
-1026
-3562
-3648

query I rowsort
SELECT ALL col2 * 87 * + col1 AS col2 FROM tab1 AS cor0
----
108576
122148
49590

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

query I rowsort
SELECT DISTINCT - 66 + cor0.col2 FROM tab2 AS cor0
----
-28
-39
-40

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

query I rowsort
SELECT ALL + + 88 * 33 AS col2 FROM tab2 cor0
----
2904
2904
2904

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-406
SELECT - - 84 DIV + 76 + - cor0.col2 - - 44 col2 FROM tab0 AS cor0
----
-37
12
44

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-406
SELECT - - 84 / + 76 + - cor0.col2 - - 44 col2 FROM tab0 AS cor0
----
-37
12
44

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

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

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

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

query I rowsort
SELECT cor0.col0 - 75 FROM tab2 cor0
----
-68
3
4

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

query I rowsort
SELECT DISTINCT - + 44 * 52 + cor0.col2 + - ( + 75 ) * + col0 * - col0 AS col1 FROM tab0 AS cor0
----
40945
591869
89588

query I rowsort
SELECT + col0 * col0 * + col1 + - col1 AS col0 FROM tab0 AS cor0
----
118728
49450
720720

onlyif mysql # use DIV operator for integer division
query I rowsort label-414
SELECT ALL - + col0 DIV - 22 - - col2 FROM tab1 AS cor0
----
54
59
99

skipif mysql # not compatible
query I rowsort label-414
SELECT ALL - + col0 / - 22 - - col2 FROM tab1 AS cor0
----
54
59
99

query I rowsort
SELECT DISTINCT 10 + col2 FROM tab2 AS cor0
----
36
37
48

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

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

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

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

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

query I rowsort
SELECT ALL + ( col1 ) * + col1 + - col1 AS col0 FROM tab0 AS cor0
----
7310
8190
9312

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col2 col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT DISTINCT 97 AS col1 FROM tab1 AS cor0
----
97

query I rowsort
SELECT DISTINCT - col1 * - col2 - + tab2.col1 * + col1 AS col0 FROM tab2
----
-124
-1947
357

query I rowsort
SELECT DISTINCT + 15 - col1 FROM tab1 AS cor0
----
-11
2
5

query I rowsort
SELECT - - 3 * - col1 + ( + col1 * - cor0.col1 ) AS col1 FROM tab0 AS cor0
----
-7654
-8554
-9700

query I rowsort
SELECT DISTINCT + 18 + col0 FROM tab0 AS cor0
----
107
42
53

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + col0 * col2 col2 FROM tab0 AS cor0
----
34
7216
759

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

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

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

query I rowsort
SELECT - 98 FROM tab0, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to 9b0655947ad21e0b95a137a474fa6a1f

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

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

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

query I rowsort
SELECT - cor1.col0 * + cor0.col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to fa8f09039d622159cb79f83c1d68bd00

query I rowsort
SELECT ALL - - cor0.col0 * 19 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to bb00ad656ecb1f86e668d1fef0b986f3

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

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

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

query I rowsort
SELECT + - col1 * + ( col1 + + col0 ) * + ( + 7 * col2 ) AS col0 FROM tab1 AS cor0
----
-285012
-295260
-812448

query I rowsort
SELECT DISTINCT + tab2.col1 * 76 FROM tab2
----
1292
2356
4484

query I rowsort
SELECT ALL + ( ( - col0 ) ) FROM tab1
----
-3
-64
-80

query I rowsort
SELECT 56 AS col0 FROM tab1
----
56
56
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 77 * + col1 + col1 col2 FROM tab2
----
1326
2418
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-444
SELECT DISTINCT - col1 * 79 + col2 + col2 DIV col2 AS col0 FROM tab0
----
-6760
-7106
-7661

skipif mysql # not compatible
query I rowsort label-444
SELECT DISTINCT - col1 * 79 + col2 + col2 / col2 AS col0 FROM tab0
----
-6760
-7106
-7661

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-447
SELECT - CAST( col0 AS SIGNED ) FROM tab2 cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-447
SELECT - CAST ( col0 AS INTEGER ) FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + 55 + 21 AS col0 FROM tab1 AS cor0
----
76

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

query I rowsort
SELECT ALL - 84 AS col2 FROM tab1 cor0
----
-84
-84
-84

query I rowsort
SELECT + 39 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT col1 + + col0 + - ( + 96 ) FROM tab1
----
-22
-3
-67

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

query I rowsort
SELECT DISTINCT tab0.col2 * col1 + 7 AS col2 FROM tab0
----
104
2845
7469

query I rowsort
SELECT ALL 82 + col2 * col0 AS col2 FROM tab1
----
244
3730
7762

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 66 * col1 + 91 * col1 * - col2 col2 FROM tab0 cor0
----
-2425
-252582
-673036

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

query I rowsort
SELECT DISTINCT - - cor0.col2 * col2 + + 95 AS col2 FROM tab0 cor0
----
1184
6819
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-460
SELECT DISTINCT cor0.col2 DIV + 42 + 87 * + col2 col0 FROM tab1 AS cor0
----
4699
4960
8354

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-460
SELECT DISTINCT cor0.col2 / + 42 + 87 * + col2 col0 FROM tab1 AS cor0
----
4699
4960
8354

query I rowsort
SELECT ALL - - col0 - + cor0.col2 * 33 * col0 AS col0 FROM tab0 AS cor0
----
-1120
-240745
-26112

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

skipif mysql # not compatible
query I rowsort label-462
SELECT DISTINCT col0 * - CAST ( col0 * col2 AS INTEGER ) + - col1 * + col2 AS col2 FROM tab0 AS cor0
----
-1322
-21846
-656984

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

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

query I rowsort
SELECT DISTINCT - col2 * 52 + - col0 AS col1 FROM tab1 AS cor0
----
-2811
-3028
-5072

query I rowsort
SELECT DISTINCT + col1 + - ( + col0 + col2 ) * + col2 FROM tab0 AS cor0
----
-13931
-1795
61

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

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

query I rowsort
SELECT + + col0 * 22 FROM tab1 AS cor0
----
1408
1760
66

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

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

query I rowsort
SELECT DISTINCT col2 * - 89 FROM tab1 AS cor0
----
-4806
-5073
-8544

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

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

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

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

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

query I rowsort
SELECT DISTINCT - 69 * + col1 AS col2 FROM tab0
----
-5934
-6279
-6693

query I rowsort
SELECT ALL tab2.col2 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

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

query I rowsort
SELECT DISTINCT ( col1 + 44 ) AS col0 FROM tab2
----
103
61
75

query I rowsort
SELECT - - col1 * 54 + - col2 * - 15 * col2 FROM tab1 AS cor0
----
138942
45144
49275

query I rowsort
SELECT DISTINCT - tab0.col0 + - 38 AS col0 FROM tab0
----
-127
-62
-73

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-485
SELECT + col1 * CAST ( - col1 + + col1 * col0 AS INTEGER ) FROM tab1
----
13351
1352
6300

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-487
SELECT ALL col2 + col1 * col1 DIV col2 FROM tab1
----
58
66
97

skipif mysql # not compatible
query I rowsort label-487
SELECT ALL col2 + col1 * col1 / col2 FROM tab1
----
58
66
97

query I rowsort
SELECT DISTINCT 86 + + cor0.col2 FROM tab1, tab2 cor0
----
112
113
124

query I rowsort
SELECT - col1 * cor0.col2 + col1 + + col1 AS col2 FROM tab2 cor0
----
-1416
-612
-775

query I rowsort
SELECT - 4 * col2 FROM tab0 AS cor0
----
-132
-328
-4

query I rowsort
SELECT + col0 * 40 FROM tab1 AS cor0
----
120
2560
3200

query I rowsort
SELECT DISTINCT + 82 + - col0 * col2 AS col1 FROM tab2 AS cor0
----
-107
-1946
-2920

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

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

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

query I rowsort
SELECT + - 95 * + col2 AS col2 FROM tab1 AS cor0
----
-5130
-5415
-9120

query I rowsort
SELECT ALL 0 + - cor0.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT - col0 + 23 FROM tab0
----
-1
-12
-66

query I rowsort
SELECT ALL col1 + 73 AS col1 FROM tab2
----
104
132
90

query I rowsort
SELECT DISTINCT - ( - 84 + - col0 ) * 97 AS col1 FROM tab2
----
15714
15811
8827

query I rowsort
SELECT - cor1.col0 AS col2 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT 6 * + col1 * col0 FROM tab0
----
12384
20370
48594

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-504
SELECT - 9 + 43 DIV - col0 + + CAST( + 37 AS SIGNED ) * + col1 FROM tab2
----
1132
2174
620

skipif mysql # not compatible
query I rowsort label-504
SELECT - 9 + 43 / - col0 + + CAST ( + 37 AS INTEGER ) * + col1 FROM tab2
----
1132
2174
620

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-506
SELECT - - cor1.col1 + ( - cor1.col2 ) * cor1.col1 DIV - cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 993162448d72b066e1ac9ba4caa8d8d7

skipif mysql # not compatible
query I rowsort label-506
SELECT - - cor1.col1 + ( - cor1.col2 ) * cor1.col1 / - cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 993162448d72b066e1ac9ba4caa8d8d7

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

query I rowsort
SELECT ALL + col1 + - col1 * - 11 AS col1 FROM tab1 AS cor0
----
120
156
312

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

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

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

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

query I rowsort
SELECT - 6 + cor0.col0 + col2 * col2 AS col1 FROM tab1 AS cor0
----
2913
3307
9290

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 73 * col2 + - col2 + - col2 * + col0 * col1 col2 FROM tab2 AS cor0
----
-117780
-3915
-48298

query I rowsort
SELECT DISTINCT col0 + cor0.col1 + 45 AS col2 FROM tab1 AS cor0
----
119
138
74

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

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

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

skipif mysql # not compatible
query I rowsort label-515
SELECT ALL - CAST ( NULL AS INTEGER ) AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

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

query I rowsort
SELECT + col2 + - 66 AS col1 FROM tab1 AS cor0
----
-12
-9
30

onlyif mysql # use DIV operator for integer division
query I rowsort label-518
SELECT cor0.col2 - - col1 DIV col1 AS col1 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-518
SELECT cor0.col2 - - col1 / col1 AS col1 FROM tab0 AS cor0
----
2
34
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( col1 AS REAL ) * - cor0.col2 col0 FROM tab0 AS cor0
----
-2838
-7462
-97

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

query I rowsort
SELECT cor1.col2 FROM tab1, tab2 AS cor0, tab2 AS cor1, tab0, tab1 cor2
----
243 values hashing to 3dcd863493ac16ce594c62d4ac8b0412

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-522
SELECT col2 + cor0.col2 / col0 col1 FROM tab1 cor0
----
57
72
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-523
SELECT col2 DIV - 24 AS col2 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-523
SELECT col2 / - 24 AS col2 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT col0 + 54 * 62 FROM tab2
----
3355
3426
3427

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

query I rowsort
SELECT ALL - col0 + 57 * + col0 * col2 FROM tab1 AS cor0
----
207872
437680
9231

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

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

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

query I rowsort
SELECT ALL + - 69 + col2 AS col0 FROM tab0 AS cor0
----
-36
-68
13

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

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

query I rowsort
SELECT DISTINCT - 41 * - col2 FROM tab0 AS cor0
----
1353
3362
41

query I rowsort
SELECT - - 64 * + col0 + col0 * - 84 - - col0 AS col1 FROM tab2 AS cor0
----
-133
-1482
-1501

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

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

query I rowsort
SELECT ( col1 ) * - col1 AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - ( col1 ) + - col1 * ( - 88 ) FROM tab2 AS cor0
----
1479
2697
5133

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-542
SELECT ALL - 7 / - col2 AS col0 FROM tab1 AS cor0
----
0
0
0

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

query I rowsort
SELECT + + 9 * col1 * - col1 AS col0 FROM tab0 cor0
----
-66564
-74529
-84681

query I rowsort
SELECT ALL col1 + col2 * 87 AS col0 FROM tab1 AS cor0
----
4724
4969
8365

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

query I rowsort
SELECT ALL + col2 * + col0 + 35 AS col1 FROM tab0 AS cor0
----
70
7333
827

query I rowsort
SELECT + - 23 + col0 AS col0 FROM tab0 AS cor0
----
1
12
66

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-550
SELECT ALL - + col1 DIV col1 + - cor0.col2 * 33 * col1 AS col2 FROM tab1 AS cor0
----
-18811
-41185
-46333

skipif mysql # not compatible
query I rowsort label-550
SELECT ALL - + col1 / col1 + - cor0.col2 * 33 * col1 AS col2 FROM tab1 AS cor0
----
-18811
-41185
-46333

query I rowsort
SELECT DISTINCT + cor0.col0 + - 68 AS col0 FROM tab0, tab0 cor0
----
-33
-44
21

query I rowsort
SELECT ALL + - col2 * - 97 FROM tab2 cor0
----
2522
2619
3686

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

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

query I rowsort
SELECT DISTINCT + - col1 * col2 + + 90 FROM tab1 AS cor0
----
-1158
-1314
-480

query I rowsort
SELECT ALL - - col1 * ( 58 ) - + col0 * + 68 AS col0 FROM tab0 AS cor0
----
-774
3246
3356

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

skipif mysql # not compatible
query I rowsort label-557
SELECT DISTINCT - col2 / col2 AS col1 FROM tab1 AS cor0
----
-1

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

query I rowsort
SELECT - - col2 * - 26 AS col0 FROM tab0 cor0
----
-2132
-26
-858

query I rowsort
SELECT ALL + col1 * col0 + col2 + col2 AS col2 FROM tab2 cor0
----
1419
271
4654

query I rowsort
SELECT DISTINCT - col2 * + col0 - col2 * - col2 AS col2 FROM tab0 AS cor0
----
-34
-574
297

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

query I rowsort
SELECT ( col2 + - 80 ) * - col2 AS col1 FROM tab0
----
-164
1551
79

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

query I rowsort
SELECT + cor0.col2 + col0 * - col0 * col1 AS col2 FROM tab1 AS cor0
----
-180
-40903
-83104

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-567
SELECT col1 DIV + 12 + + 46 AS col0 FROM tab0 AS cor0
----
53
53
54

skipif mysql # not compatible
query I rowsort label-567
SELECT col1 / + 12 + + 46 AS col0 FROM tab0 AS cor0
----
53
53
54

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

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

query I rowsort
SELECT 42 + - col2 FROM tab2 AS cor0
----
15
16
4

query I rowsort
SELECT 65 + + col2 * col0 + - 0 * 71 AS col1 FROM tab0
----
100
7363
857

query I rowsort
SELECT ALL + ( col1 ) + - ( - 36 ) FROM tab2 cor0
----
53
67
95

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

query I rowsort
SELECT ALL - 25 + + col0 * - col2 + col0 FROM tab2
----
-1975
-207
-2948

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-575
SELECT ALL - - cor0.col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-575
SELECT ALL - - cor0.col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - 92 * - col1 + + col0 AS col1 FROM tab2
----
1643
2859
5506

query I rowsort
SELECT + 62 AS col2 FROM tab0, tab2, tab1 cor0
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

query I rowsort
SELECT DISTINCT + 25 + col2 FROM tab2
----
51
52
63

query I rowsort
SELECT DISTINCT 47 + + col0 FROM tab0
----
136
71
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-580
SELECT - col0 DIV col0 + - 46 + + 57 FROM tab0
----
10
10
10

skipif mysql # not compatible
query I rowsort label-580
SELECT - col0 / col0 + - 46 + + 57 FROM tab0
----
10
10
10

query I rowsort
SELECT ALL + 43 FROM tab0, tab1, tab1 cor0
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

query I rowsort
SELECT ALL 4 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT ( - col0 ) * - col0 * col1 + cor0.col2 FROM tab1 cor0
----
288
41017
83296

query I rowsort
SELECT DISTINCT - - 6 * col1 FROM tab0 AS cor0
----
516
546
582

query I rowsort
SELECT cor0.col2 * tab1.col2 FROM tab1, tab0 cor0
----
9 values hashing to 1e358219bf03c93d7085a65107d13cf1

query I rowsort
SELECT ALL + - col0 + + col0 * col1 * col2 AS col1 FROM tab1 AS cor0
----
36416
4209
99760

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

query I rowsort
SELECT ALL 64 AS col1 FROM tab1
----
64
64
64

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

query I rowsort
SELECT - 29 * - col1 + col1 FROM tab1 cor0
----
300
390
780

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

query I rowsort
SELECT DISTINCT + 74 * + col0 + - col1 FROM tab0 AS cor0
----
1690
2493
6495

query I rowsort
SELECT - ( + 66 ) FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to cd4a3594ee8b45223ebf9f25840cd112

query I rowsort
SELECT - 84 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to 975e2ef2a3bf1ee2622362f4e435752f

query I rowsort
SELECT DISTINCT - - 75 + col1 FROM tab1 AS cor0
----
101
85
88

query I rowsort
SELECT + - 8 * col0 + + 42 * - col0 AS col2 FROM tab2 AS cor0
----
-350
-3900
-3950

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

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

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

skipif mysql # not compatible
query I rowsort label-598
SELECT DISTINCT + + ( col1 ) / cor0.col0 FROM tab2 AS cor0
----
0
4

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

query I rowsort
SELECT - - 94 * col0 + + col2 FROM tab2 AS cor0
----
685
7358
7464

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

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

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

query I rowsort
SELECT 89 + - col2 AS col0 FROM tab0 AS cor0
----
56
7
88

query I rowsort
SELECT DISTINCT - 72 + + col0 FROM tab0 cor0
----
-37
-48
17

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

query I rowsort
SELECT - - 20 + + col1 AS col1 FROM tab0 AS cor0
----
106
111
117

query I rowsort
SELECT DISTINCT - 91 FROM tab2, tab1 cor0
----
-91

query I rowsort
SELECT + col1 + + 4 AS col0 FROM tab2 AS cor0
----
21
35
63

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

query I rowsort
SELECT DISTINCT col2 + 56 FROM tab2 AS cor0
----
82
83
94

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0, tab0 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND ( NULL )
----

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

query I rowsort
SELECT DISTINCT ( cor0.col1 ) * + 8 FROM tab0 AS cor0
----
688
728
776

query I rowsort
SELECT DISTINCT + col1 * cor0.col0 * - 36 - col1 AS col2 FROM tab1 AS cor0
----
-23050
-2834
-37453

query I rowsort
SELECT ALL - col1 * col2 + + 2 * + ( col1 ) FROM tab1 AS cor0
----
-1222
-1352
-550

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

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

query I rowsort
SELECT ( + 97 ) + col0 * 74 FROM tab1
----
319
4833
6017

onlyif mysql # use DIV operator for integer division
query I rowsort label-620
SELECT DISTINCT + 50 + + col1 DIV + tab0.col0 FROM tab0
----
51
52
53

skipif mysql # not compatible
query I rowsort label-620
SELECT DISTINCT + 50 + + col1 / + tab0.col0 FROM tab0
----
51
52
53

query I rowsort
SELECT DISTINCT - col2 * cor0.col1 * col2 AS col1 FROM tab1 AS cor0
----
-119808
-32490
-75816

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

skipif mysql # not compatible
query I rowsort label-622
SELECT DISTINCT - col2 / - col0 FROM tab1
----
0
1
18

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

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

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

query I rowsort
SELECT ALL + 6 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to f1e8f0199f3714ee8fcc24ce0cc3ea04

query I rowsort
SELECT + 62 FROM tab2
----
62
62
62

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

query I rowsort
SELECT 4 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT + col1 * tab0.col0 * - 33 AS col1 FROM tab0
----
-112035
-267267
-68112

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

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

skipif mysql # not compatible
query I rowsort label-632
SELECT - col0 / tab0.col0 FROM tab0
----
-1
-1
-1

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

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

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

query I rowsort
SELECT col1 + + col1 * col0 * + col1 FROM tab0 cor0
----
177590
329412
737100

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

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

query I rowsort
SELECT col1 * cor0.col1 * col1 FROM tab1 AS cor0
----
1000
17576
2197

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 56 + cor0.col1 col0 FROM tab1 AS cor0
----
66
69
82

query I rowsort
SELECT 5 + col1 FROM tab0
----
102
91
96

query I rowsort
SELECT DISTINCT ( + 15 ) FROM tab1, tab0, tab1 AS cor0
----
15

onlyif mysql # use DIV operator for integer division
query I rowsort label-642
SELECT + ( 14 ) * col1 - - col1 * ( col1 ) DIV ( col0 ) FROM tab1
----
141
184
589

skipif mysql # not compatible
query I rowsort label-642
SELECT + ( 14 ) * col1 - - col1 * ( col1 ) / ( col0 ) FROM tab1
----
141
184
589

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

query I rowsort
SELECT DISTINCT - 52 * col1 * 31 AS col1 FROM tab0 AS cor0
----
-138632
-146692
-156364

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col1 ) + col2 col0 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT - col1 + 24 FROM tab2
----
-35
-7
7

query I rowsort
SELECT DISTINCT + ( col0 ) * - col2 + 86 * tab0.col1 AS col0 FROM tab0
----
528
6604
8307

query I rowsort
SELECT ALL - tab2.col1 + col2 + col2 AS col1 FROM tab2
----
-7
23
59

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

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

query I rowsort
SELECT + 54 * + col0 FROM tab2 cor0
----
378
4212
4266

query I rowsort
SELECT + cor0.col1 + - col2 * ( col0 ) FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT - 37 * col1 FROM tab1 AS cor0
----
-370
-481
-962

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

query I rowsort
SELECT DISTINCT - - cor0.col1 * + cor0.col2 * 99 FROM tab2 AS cor0
----
151866
63954
82863

query I rowsort
SELECT ALL 74 FROM tab2 AS cor0
----
74
74
74

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

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

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

skipif mysql # not compatible
query I rowsort label-660
SELECT DISTINCT - col1 / col0 AS col0 FROM tab1 cor0
----
-8
0

query I rowsort
SELECT ALL + col2 * + col0 * - 80 AS col1 FROM tab0 AS cor0
----
-2800
-583840
-63360

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col1 * - ( col1 ) + - col0 col1 FROM tab2
----
-3559
-368
-968

query I rowsort
SELECT tab1.col0 + + col2 - col0 FROM tab1
----
54
57
96

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

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

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

query I rowsort
SELECT ALL col0 * col1 + col1 * ( - col2 ) + col0 FROM tab2 AS cor0
----
-613
3146
776

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

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

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

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

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

query I rowsort
SELECT DISTINCT - col1 + - 34 FROM tab2 AS cor0
----
-51
-65
-93

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-675
SELECT DISTINCT + col0 DIV + col0 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-675
SELECT DISTINCT + col0 / + col0 FROM tab0
----
1

query I rowsort
SELECT - + 97 * 40 + - col1 + col1 AS col2 FROM tab2 AS cor0
----
-3880
-3880
-3880

query I rowsort
SELECT 40 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-679
SELECT ALL col2 DIV - 6 FROM tab1 AS cor0
----
-16
-9
-9

skipif mysql # not compatible
query I rowsort label-679
SELECT ALL col2 / - 6 FROM tab1 AS cor0
----
-16
-9
-9

query I rowsort
SELECT ALL - - col0 + 2 * + col1 FROM tab1 AS cor0
----
106
55
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-681
SELECT ALL + + col2 DIV + col0 + + col1 * col0 FROM tab1 AS cor0
----
1041
640
96

skipif mysql # not compatible
query I rowsort label-681
SELECT ALL + + col2 / + col0 + + col1 * col0 FROM tab1 AS cor0
----
1041
640
96

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

skipif mysql # not compatible
query I rowsort label-682
SELECT DISTINCT - + CAST ( col1 AS INTEGER ) - col0 AS col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT + col2 + ( - cor0.col2 + - cor0.col2 ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * 37 + col0 * cor0.col2 col2 FROM tab0 cor0
----
10591
1330
1680

query I rowsort
SELECT - - 97 FROM tab2 AS cor0
----
97
97
97

query I rowsort
SELECT - col1 + - 69 * - col0 FROM tab2 cor0
----
452
5323
5434

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-687
SELECT ALL - 25 * + cor0.col1 + + col2 * + CAST( col1 AS SIGNED ) + + col1 FROM tab0 cor0
----
-2231
5278
774

skipif mysql # not compatible
query I rowsort label-687
SELECT ALL - 25 * + cor0.col1 + + col2 * + CAST ( col1 AS INTEGER ) + + col1 FROM tab0 cor0
----
-2231
5278
774

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

query I rowsort
SELECT DISTINCT - col2 * 9 FROM tab0 AS cor0
----
-297
-738
-9

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-690
SELECT DISTINCT + - col2 / col1 + 64 col2 FROM tab1 AS cor0
----
57
59
62

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

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

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

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

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0, tab2 cor1, tab1 cor2
----
972 values hashing to 4c0813b2179303fdf58f082d81d6d03c

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

query I rowsort
SELECT + 76 * - cor0.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to ca8e051800d63941b6ac2ce7339fd068

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

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

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

query I rowsort
SELECT + 80 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 6dd5038be71dffa82f5ceba787caab91

onlyif mysql # use DIV operator for integer division
query I rowsort label-700
SELECT col1 * ( - col1 ) - col0 DIV 14 AS col2 FROM tab1 AS cor0
----
-104
-174
-676

skipif mysql # not compatible
query I rowsort label-700
SELECT col1 * ( - col1 ) - col0 / 14 AS col2 FROM tab1 AS cor0
----
-104
-174
-676

query I rowsort
SELECT col1 + 37 * col2 * - col2 FROM tab2
----
-24953
-26942
-53411

query I rowsort
SELECT col2 * - ( col0 + + col0 ) * 57 AS col2 FROM tab2
----
-21546
-231192
-342228

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

skipif mysql # not compatible
query I rowsort label-703
SELECT ALL col1 + - CAST ( - col2 AS INTEGER ) * col0 FROM tab0
----
132
7389
878

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

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0, tab0 AS cor0, tab0 cor1
----
972 values hashing to 3406497351e4789c89a295ee9b64b201

query I rowsort
SELECT 8 FROM tab2, tab2 AS cor0
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

query I rowsort
SELECT - col1 + col0 + col2 * - col1 FROM tab2 AS cor0
----
-1515
-584
-861

query I rowsort
SELECT DISTINCT - ( + 63 ) AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
-63

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

query I rowsort
SELECT DISTINCT + 11 FROM tab1
----
11

query I rowsort
SELECT col0 + 53 * - col1 AS col2 FROM tab0
----
-4534
-4734
-5106

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-713
SELECT ALL col0 DIV ( col2 + col2 ) FROM tab0
----
0
0
17

skipif mysql # not compatible
query I rowsort label-713
SELECT ALL col0 / ( col2 + col2 ) FROM tab0
----
0
0
17

query I rowsort
SELECT + col0 * 28 FROM tab1
----
1792
2240
84

query I rowsort
SELECT col1 * 54 FROM tab0
----
4644
4914
5238

query I rowsort
SELECT + 33 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

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

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

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

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-721
SELECT + CAST( - col0 + col2 AS SIGNED ) FROM tab2
----
-41
-52
20

skipif mysql # not compatible
query I rowsort label-721
SELECT + CAST ( - col0 + col2 AS INTEGER ) FROM tab2
----
-41
-52
20

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

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

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

query I rowsort
SELECT DISTINCT + ( + 54 ) + + cor2.col2 AS col2 FROM tab0, tab2 cor0, tab0 cor1, tab2 AS cor2
----
80
81
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-726
SELECT ALL + col0 + + 93 - col0 DIV col2 FROM tab1 cor0
----
156
173
96

skipif mysql # not compatible
query I rowsort label-726
SELECT ALL + col0 + + 93 - col0 / col2 FROM tab1 cor0
----
156
173
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-727
SELECT DISTINCT + col0 DIV + 60 + - col1 * + col0 FROM tab1 AS cor0
----
-1039
-639
-78

skipif mysql # not compatible
query I rowsort label-727
SELECT DISTINCT + col0 / + 60 + - col1 * + col0 FROM tab1 AS cor0
----
-1039
-639
-78

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

query I rowsort
SELECT DISTINCT - 75 * col0 AS col0 FROM tab1 AS cor0
----
-225
-4800
-6000

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-730
SELECT DISTINCT CAST ( + 58 AS INTEGER ) + - col0 + ( + col0 ) * + cor0.col0 col1 FROM tab2 AS cor0
----
100
6064
6220

query I rowsort
SELECT ( - col2 ) - col0 * col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT - col1 * + col2 + 23 * - 27 AS col2 FROM tab2 AS cor0
----
-1267
-1458
-2155

query I rowsort
SELECT - - 34 * + col1 - 44 FROM tab2 AS cor0
----
1010
1962
534

query I rowsort
SELECT + 84 * cor0.col2 + 56 AS col1 FROM tab1 AS cor0
----
4592
4844
8120

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

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

query I rowsort
SELECT ALL 78 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

onlyif mysql # use DIV operator for integer division
query I rowsort label-737
SELECT - cor0.col1 DIV col2 + + col1 - 30 AS col2 FROM tab1 cor0
----
-17
-20
-4

skipif mysql # not compatible
query I rowsort label-737
SELECT - cor0.col1 / col2 + + col1 - 30 AS col2 FROM tab1 cor0
----
-17
-20
-4

query I rowsort
SELECT 2 + cor0.col0 FROM tab0 AS cor0
----
26
37
91

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

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

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

query I rowsort
SELECT ALL - 5 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 4f346dd2f65047c836c6957f80f0ef9e

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

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

query I rowsort
SELECT ALL + cor0.col2 * + col2 + + 57 * - col1 FROM tab2 cor0
----
-1038
-2687
475

onlyif mysql # use DIV operator for integer division
query I rowsort label-744
SELECT DISTINCT - col2 * - 32 - - 68 DIV col1 FROM tab0 AS cor0
----
1056
2624
32

skipif mysql # not compatible
query I rowsort label-744
SELECT DISTINCT - col2 * - 32 - - 68 / col1 FROM tab0 AS cor0
----
1056
2624
32

query I rowsort
SELECT ALL cor0.col2 * col0 + cor0.col1 * - cor0.col2 AS col1 FROM tab2 cor0
----
-648
2356
494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 * - col2 * col0 - col2 col1 FROM tab0 AS cor0
----
-3396
-664200
-68145

query I rowsort
SELECT ALL - col0 * 23 AS col2 FROM tab0 AS cor0
----
-2047
-552
-805

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-749
SELECT + col2 + col0 DIV col2 AS col0 FROM tab0 AS cor0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-749
SELECT + col2 + col0 / col2 AS col0 FROM tab0 AS cor0
----
33
36
83

query I rowsort
SELECT DISTINCT + + col0 * col0 + col0 + + col1 FROM tab0 AS cor0
----
1357
686
8101

query I rowsort
SELECT ALL col2 * 97 + - col1 AS col0 FROM tab2 cor0
----
2463
2588
3669

query I rowsort
SELECT - - cor0.col2 * col1 + - 85 FROM tab1 AS cor0
----
1163
1319
485

query I rowsort
SELECT DISTINCT - col2 + 99 + col0 * col2 FROM tab1 AS cor0
----
207
3690
7683

query I rowsort
SELECT ALL - cor0.col2 * - 83 - + col2 AS col1 FROM tab1 AS cor0
----
4428
4674
7872

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

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

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

query I rowsort
SELECT col1 * col1 + - col0 + + ( - col1 ) AS col1 FROM tab2 AS cor0
----
193
3344
923

query I rowsort
SELECT - 88 + + col2 AS col1 FROM tab0 cor0
----
-55
-6
-87

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

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

query I rowsort
SELECT + - ( 82 ) * - col0 AS col2 FROM tab0 AS cor0
----
1968
2870
7298

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

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

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

query I rowsort
SELECT ALL + 40 + col0 * + col1 FROM tab0 AS cor0
----
2104
3435
8139

onlyif mysql # use DIV operator for integer division
query I rowsort label-766
SELECT ALL - - col0 * cor0.col0 + + col0 DIV + col0 AS col1 FROM tab0 cor0
----
1226
577
7922

skipif mysql # not compatible
query I rowsort label-766
SELECT ALL - - col0 * cor0.col0 + + col0 / + col0 AS col1 FROM tab0 cor0
----
1226
577
7922

query I rowsort
SELECT ( 93 ) FROM tab2 AS cor0
----
93
93
93

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-769
SELECT DISTINCT + 30 DIV tab1.col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
0
10

skipif mysql # not compatible
query I rowsort label-769
SELECT DISTINCT + 30 / tab1.col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
0
10

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

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

query I rowsort
SELECT + col0 * 86 AS col0 FROM tab1 AS cor0
----
258
5504
6880

query I rowsort
SELECT DISTINCT - + col2 + - 99 FROM tab2 AS cor0
----
-125
-126
-137

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

skipif mysql # not compatible
query I rowsort label-774
SELECT col0 + 27 / col1 AS col1 FROM tab1 AS cor0
----
4
66
82

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

query I rowsort
SELECT col1 * - col2 * + 35 AS col1 FROM tab1
----
-19950
-43680
-49140

query I rowsort
SELECT DISTINCT + 51 * + cor0.col1 AS col0 FROM tab2, tab2 AS cor0
----
1581
3009
867

query I rowsort
SELECT ALL - + cor0.col2 * 19 * + col1 FROM tab2 AS cor0
----
-12274
-15903
-29146

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

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( - 59 AS REAL ) * - col2 FROM tab2 AS cor0
----
1534
1593
2242

query I rowsort
SELECT + col2 * 85 + - cor0.col2 * - col2 * col2 FROM tab2 cor0
----
19786
21978
58102

query I rowsort
SELECT tab2.col1 - - 34 FROM tab2
----
51
65
93

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

query I rowsort
SELECT - tab0.col2 + + 20 AS col0 FROM tab0
----
-13
-62
19

query I rowsort
SELECT DISTINCT - col1 + col2 * 10 AS col0 FROM tab2
----
201
239
363

query I rowsort
SELECT DISTINCT col1 * col0 + 67 AS col2 FROM tab0
----
2131
3462
8166

query I rowsort
SELECT ALL - col2 * 89 * + 31 + - col2 FROM tab2
----
-104880
-71760
-74520

query I rowsort
SELECT ALL 62 AS col2 FROM tab1 cor0
----
62
62
62

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

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

query I rowsort
SELECT - col1 * col2 + col2 * col1 * - col1 FROM tab1 AS cor0
----
-17472
-37908
-6270

query I rowsort
SELECT - 50 * + col0 - - col1 FROM tab1 AS cor0
----
-124
-3190
-3987

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

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

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

query I rowsort
SELECT + 38 + + col0 * + cor0.col2 FROM tab1 AS cor0
----
200
3686
7718

query I rowsort
SELECT DISTINCT + cor0.col0 + col1 * - ( 88 ) FROM tab0 AS cor0
----
-7544
-7919
-8501

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

query I rowsort
SELECT ALL + 19 * + 47 AS col2 FROM tab0
----
893
893
893

query I rowsort
SELECT ALL col1 + col2 + col0 AS col2 FROM tab1
----
131
189
83

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * - cor0.col0 - + ( 87 ) * col2 col2 FROM tab0 AS cor0
----
-122
-14432
-3663

onlyif mysql # use DIV operator for integer division
query I rowsort label-803
SELECT ALL + - col1 * - col1 + + col1 DIV + 69 AS col2 FROM tab1 AS cor0
----
100
169
676

skipif mysql # not compatible
query I rowsort label-803
SELECT ALL + - col1 * - col1 + + col1 / + 69 AS col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL - col2 * + col2 - + 45 FROM tab1 AS cor0
----
-2961
-3294
-9261

onlyif mysql # use DIV operator for integer division
query I rowsort label-805
SELECT ALL + col2 DIV + col1 + 31 col1 FROM tab0 AS cor0
----
31
31
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-805
SELECT ALL + col2 / + col1 + 31 col1 FROM tab0 AS cor0
----
31
31
31

query I rowsort
SELECT ALL + - col1 * col2 - 71 * + col0 FROM tab0 AS cor0
----
-13781
-2582
-4542

query I rowsort
SELECT ALL col0 * col2 + + tab2.col0 + + col2 AS col1 FROM tab2
----
2132
223
3119

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 15 + col1 * + 61 col1 FROM tab0
----
5261
5566
5932

query I rowsort
SELECT - 1 + col1 * 57 * col0 FROM tab0
----
117647
193514
461642

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

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

query I rowsort
SELECT + col1 + - col0 * + col0 - - col1 * col2 * - col1 AS col1 FROM tab0 AS cor0
----
-10537
-244558
-686872

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

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

query I rowsort
SELECT + 3 FROM tab0
----
3
3
3

query I rowsort
SELECT ALL - + cor0.col1 * ( 18 ) FROM tab1 cor0
----
-180
-234
-468

query I rowsort
SELECT - col2 * ( - 41 ) + + col0 AS col1 FROM tab2 AS cor0
----
1114
1144
1637

onlyif mysql # use DIV operator for integer division
query I rowsort label-816
SELECT ALL col1 DIV + CAST( col0 AS SIGNED ) + + cor0.col0 * - col0 FROM tab0 AS cor0
----
-1223
-573
-7920

skipif mysql # not compatible
query I rowsort label-816
SELECT ALL col1 / + CAST ( col0 AS INTEGER ) + + cor0.col0 * - col0 FROM tab0 AS cor0
----
-1223
-573
-7920

onlyif mysql # use DIV operator for integer division
query I rowsort label-817
SELECT - + col1 * 69 + + col0 DIV + col0 AS col0 FROM tab1 AS cor0
----
-1793
-689
-896

skipif mysql # not compatible
query I rowsort label-817
SELECT - + col1 * 69 + + col0 / + col0 AS col0 FROM tab1 AS cor0
----
-1793
-689
-896

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col2 * - 84 * + col2 col1 FROM tab1
----
244944
272916
774144

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

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

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

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

query I rowsort
SELECT DISTINCT - + ( - 9 ) * col1 FROM tab1 AS cor0
----
117
234
90

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

skipif mysql # not compatible
query I rowsort label-825
SELECT DISTINCT + + ( ( col1 ) ) + - col1 / + 94 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - 78 AS col0 FROM tab0 cor0
----
-78
-78
-78

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

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

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

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

query I rowsort
SELECT + 34 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
1292
884
918

query I rowsort
SELECT - ( - 20 ) * col1 FROM tab1 AS cor0
----
200
260
520

query I rowsort
SELECT + ( + 90 ) + - col1 FROM tab1 cor0
----
64
77
80

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

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

skipif mysql # not compatible
query I rowsort label-835
SELECT ALL + CAST ( - col2 AS INTEGER ) * + col2 * col2 FROM tab1 AS cor0
----
-157464
-185193
-884736

skipif mysql # not compatible
query I rowsort
SELECT ALL ( ( col0 ) ) * + CAST ( + 65 AS REAL ) FROM tab0 AS cor0
----
1560
2275
5785

query I rowsort
SELECT ALL - + col1 + - 49 AS col0 FROM tab0 AS cor0
----
-135
-140
-146

query I rowsort
SELECT + + 25 * cor0.col2 AS col1 FROM tab2 cor0
----
650
675
950

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

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

query I rowsort
SELECT + col0 * - col1 + - 1 FROM tab2 AS cor0
----
-1344
-218
-4603

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-843
SELECT DISTINCT + + 11 + + cor0.col0 * col2 DIV col0 col2 FROM tab2 cor0
----
37
38
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-843
SELECT DISTINCT + + 11 + + cor0.col0 * col2 / col0 col2 FROM tab2 cor0
----
37
38
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-844
SELECT col1 DIV - col2 + 76 * col1 FROM tab1 AS cor0
----
1976
760
988

skipif mysql # not compatible
query I rowsort label-844
SELECT col1 / - col2 + 76 * col1 FROM tab1 AS cor0
----
1976
760
988

query I rowsort
SELECT DISTINCT col2 + col2 + 94 AS col0 FROM tab0 AS cor0
----
160
258
96

query I rowsort
SELECT + 43 FROM tab0, tab1 cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col0 * col1 col2 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT + cor0.col1 + cor0.col0 - cor1.col0 AS col1 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 2914a293b910aadb84664ffd131e4b5b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-850
SELECT ALL + CAST( NULL AS DECIMAL ) + - 15 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-850
SELECT ALL + CAST ( NULL AS REAL ) + - 15 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - col0 * 79 AS col2 FROM tab0
----
-1896
-2765
-7031

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

query I rowsort
SELECT col2 - - col1 * tab1.col1 FROM tab1
----
157
265
730

query I rowsort
SELECT DISTINCT + 79 * tab1.col1 AS col0 FROM tab1, tab0 AS cor0
----
1027
2054
790

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

query I rowsort
SELECT ALL 46 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2f97924b57b73102233df7c9ce8ad602

query I rowsort
SELECT ALL - col0 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
4096
6400
9

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

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

query I rowsort
SELECT + 81 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

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

query I rowsort
SELECT DISTINCT - col0 * col0 * - cor0.col0 FROM tab0 AS cor0
----
13824
42875
704969

query I rowsort
SELECT + ( 22 ) * col0 AS col1 FROM tab2 AS cor0
----
154
1716
1738

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

query I rowsort
SELECT DISTINCT - + 83 + 91 * col2 FROM tab0 AS cor0
----
2920
7379
8

query I rowsort
SELECT DISTINCT + 44 * col2 FROM tab1 cor0
----
2376
2508
4224

query I rowsort
SELECT - 8 * + 25 AS col2 FROM tab0 AS cor0
----
-200
-200
-200

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

query I rowsort
SELECT + tab0.col0 + col1 + 17 AS col2 FROM tab0
----
127
149
197

query I rowsort
SELECT 50 + + col2 FROM tab0
----
132
51
83

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

query I rowsort
SELECT col1 + - col2 + - 84 FROM tab1
----
-112
-131
-167

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 + + ( ( - col0 ) ) - - col1 col0 FROM tab0
----
-2776
-35
-7460

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-875
SELECT ALL + 10 * + col0 + col1 + 37 DIV - col1 AS col1 FROM tab2 AS cor0
----
100
805
839

skipif mysql # not compatible
query I rowsort label-875
SELECT ALL + 10 * + col0 + col1 + 37 / - col1 AS col1 FROM tab2 AS cor0
----
100
805
839

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

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

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

query I rowsort
SELECT ALL - col1 + + ( + 32 ) + - col0 FROM tab2 AS cor0
----
-105
-6
-64

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

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

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

query I rowsort
SELECT - + col0 * ( - 68 ) FROM tab0 cor0
----
1632
2380
6052

query I rowsort
SELECT - col0 + col0 * 24 + + col2 AS col1 FROM tab2 AS cor0
----
1820
1855
188

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

query I rowsort
SELECT ALL + cor0.col0 * + 44 + + col2 FROM tab2 AS cor0
----
335
3458
3514

query I rowsort
SELECT DISTINCT + + col1 + ( - 16 ) AS col1 FROM tab2 AS cor0
----
1
15
43

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - - col0 col1 FROM tab1 AS cor0
----
121
176
57

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

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

query I rowsort
SELECT ALL - col1 + 81 * 52 FROM tab2 AS cor0
----
4153
4181
4195

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

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

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1, tab2 cor0, tab0 AS cor1
----
972 values hashing to 9a5ab925af18e11f7748f3b2e722ff3d

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

skipif mysql # not compatible
query I rowsort label-894
SELECT DISTINCT col2 / - tab1.col0 + col1 FROM tab1
----
10
12
8

query I rowsort
SELECT ALL + col2 * - col0 + + 75 FROM tab2
----
-114
-1953
-2927

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 * 33 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 14d68499bf9184f50465fc607f8cd230

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

query I rowsort
SELECT ALL + 74 * - col2 AS col0 FROM tab1 AS cor0
----
-3996
-4218
-7104

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

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

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

query I rowsort
SELECT 81 - cor0.col0 AS col0 FROM tab1 AS cor0
----
1
17
78

query I rowsort
SELECT ( - col1 ) + col0 - 64 AS col1 FROM tab1 AS cor0
----
-10
-87
3

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

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

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

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

query I rowsort
SELECT ALL + cor0.col2 * + col2 + col0 * col1 AS col2 FROM tab0 AS cor0
----
14823
3153
3396

query I rowsort
SELECT ALL col0 * + col1 * col2 + col1 FROM tab2 AS cor0
----
119711
51051
5890

query I rowsort
SELECT - col1 * + 18 AS col0 FROM tab2 AS cor0
----
-1062
-306
-558

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * 42 - 83 * col1 col1 FROM tab1 AS cor0
----
-1250
-1625
-3250

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

query I rowsort
SELECT ALL - - cor0.col2 + 36 FROM tab2 AS cor0
----
62
63
74

query I rowsort
SELECT + col2 * + 78 + col1 + col0 FROM tab0 cor0
----
210
2684
6576

query I rowsort
SELECT ALL col1 + + 91 FROM tab0 AS cor0
----
177
182
188

query I rowsort
SELECT ALL - + col2 + cor0.col1 AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT col1 * - col2 + 19 - col2 FROM tab1
----
-1325
-1439
-608

query I rowsort
SELECT ALL col2 * col1 + 95 + - 59 FROM tab1
----
1284
1440
606

query I rowsort
SELECT - col0 * + col0 + 63 AS col0 FROM tab2 AS cor0
----
-6021
-6178
14

query I rowsort
SELECT - cor0.col1 + - 86 FROM tab1 AS cor0
----
-112
-96
-99

query I rowsort
SELECT - col0 - + tab2.col0 FROM tab2
----
-14
-156
-158

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-924
SELECT DISTINCT col0 DIV - col2 + + col0 col0 FROM tab1
----
3
63
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-924
SELECT DISTINCT col0 / - col2 + + col0 col0 FROM tab1
----
3
63
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-925
SELECT col1 DIV - col1 + col2 - col0 AS col1 FROM tab1
----
-8
15
50

skipif mysql # not compatible
query I rowsort label-925
SELECT col1 / - col1 + col2 - col0 AS col1 FROM tab1
----
-8
15
50

query I rowsort
SELECT DISTINCT tab0.col2 + - tab0.col2 AS col0 FROM tab0 WHERE - col0 > - col1 + + col0
----
0

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-929
SELECT col1 DIV col2 + - tab1.col0 - col2 FROM tab1
----
-121
-176
-57

skipif mysql # not compatible
query I rowsort label-929
SELECT col1 / col2 + - tab1.col0 - col2 FROM tab1
----
-121
-176
-57

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

query I rowsort
SELECT ALL - - 51 + cor0.col0 FROM tab1 AS cor0
----
115
131
54

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

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

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

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

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

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

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

query I rowsort
SELECT - 88 * col0 FROM tab0 AS cor0
----
-2112
-3080
-7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-939
SELECT 14 + col2 DIV + cor0.col1 AS col2 FROM tab1 AS cor0
----
16
19
21

skipif mysql # not compatible
query I rowsort label-939
SELECT 14 + col2 / + cor0.col1 AS col2 FROM tab1 AS cor0
----
16
19
21

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 24 col2 FROM tab0
----
-24

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

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

query I rowsort
SELECT ALL - ( tab1.col2 + + col1 ) * + col1 AS col2 FROM tab1
----
-1417
-2080
-670

query I rowsort
SELECT ALL + col0 + col1 + 58 AS col1 FROM tab0 cor0
----
168
190
238

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

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

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

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

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

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

query I rowsort
SELECT ALL + col1 + + 46 AS col1 FROM tab0
----
132
137
143

query I rowsort
SELECT ALL + col0 + - 68 AS col1 FROM tab2
----
-61
10
11

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-952
SELECT col1 * CAST( 91 * col2 AS SIGNED ) FROM tab2 AS cor0
----
139594
58786
76167

skipif mysql # not compatible
query I rowsort label-952
SELECT col1 * CAST ( 91 * col2 AS INTEGER ) FROM tab2 AS cor0
----
139594
58786
76167

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-954
SELECT + col0 DIV ( 10 ) + - col0 * ( - col0 ) FROM tab2 AS cor0
----
49
6091
6248

skipif mysql # not compatible
query I rowsort label-954
SELECT + col0 / ( 10 ) + - col0 * ( - col0 ) FROM tab2 AS cor0
----
49
6091
6248

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 49 col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
49

query I rowsort
SELECT DISTINCT - + 9 FROM tab0, tab2, tab1 AS cor0
----
-9

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

query I rowsort
SELECT + 95 * 87 * col1 + - col2 + - 8 FROM tab2 AS cor0
----
140459
256180
487601

query I rowsort
SELECT - 53 + col1 + col0 FROM tab0 cor0
----
127
57
79

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

query I rowsort
SELECT 73 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 9f0f371d979e70a792c8597c6559f0e2

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

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

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

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

query I rowsort
SELECT + 16 + 88 + - col1 AS col2 FROM tab2 AS cor0
----
45
73
87

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

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-972
SELECT + CAST ( ( + col1 ) AS INTEGER ) + + col2 * col2 AS col0 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT + cor0.col0 + + cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to f65167375aa80cc8b3f3f8987d2662a3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-974
SELECT ALL col2 * + CAST( 6 AS SIGNED ) * + col1 FROM tab0
----
17028
44772
582

skipif mysql # not compatible
query I rowsort label-974
SELECT ALL col2 * + CAST ( 6 AS INTEGER ) * + col1 FROM tab0
----
17028
44772
582

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

query I rowsort
SELECT ALL + 48 * + col1 - cor0.col0 FROM tab1 AS cor0
----
1245
416
544

query I rowsort
SELECT DISTINCT + + 86 + cor0.col1 * cor0.col1 AS col1 FROM tab1 AS cor0
----
186
255
762

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

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

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

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

skipif mysql # not compatible
query I rowsort label-981
SELECT ALL + col1 / + cor0.col0 + col0 FROM tab1 AS cor0
----
11
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * ( - col0 ) col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ( + 91 * + col1 ) FROM tab1
----
1183
2366
910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 99 + - ( col1 ) * - tab0.col2 col1 FROM tab0
----
196
2937
7561

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-985
SELECT CAST( + col0 + col0 AS SIGNED ) AS col2 FROM tab1
----
128
160
6

skipif mysql # not compatible
query I rowsort label-985
SELECT CAST ( + col0 + col0 AS INTEGER ) AS col2 FROM tab1
----
128
160
6

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

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NULL IN ( col0 )
----

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col0 * - col1 col1 FROM tab1
----
-576
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + - tab0.col0 * + col2 * - col0 col1 FROM tab0
----
1322
19094
649613

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

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

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

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

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

query I rowsort
SELECT + col0 + - col1 + - col2 FROM tab1 AS cor0
----
-29
-3
-77

query I rowsort
SELECT ALL - col0 + col1 AS col2 FROM tab0 cor0 WHERE NULL >= ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-999
SELECT + tab1.col1 DIV col2 AS col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-999
SELECT + tab1.col1 / col2 AS col2 FROM tab1
----
0
0
0

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

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

query I rowsort
SELECT cor0.col2 + tab1.col0 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 8ccec472ba030beef859f936b43eb646

onlyif mysql # use DIV operator for integer division
query I rowsort label-1003
SELECT DISTINCT + col0 * col0 DIV col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-1003
SELECT DISTINCT + col0 * col0 / col0 FROM tab1
----
3
64
80

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

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

query I rowsort
SELECT ALL col1 * - col2 - col1 AS col2 FROM tab0
----
-194
-2924
-7553

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

query I rowsort
SELECT col1 - - col1 * col2 * + col1 AS col1 FROM tab2
----
10999
25978
90565

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

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

query I rowsort
SELECT - cor0.col2 * - col0 + + col0 * + col2 AS col0 FROM tab0 AS cor0
----
14596
1584
70

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1016
SELECT ALL + - col0 DIV + col0 + col1 + + col2 * - col1 col2 FROM tab0 AS cor0
----
-1
-2753
-7372

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1016
SELECT ALL + - col0 / + col0 + col1 + + col2 * - col1 col2 FROM tab0 AS cor0
----
-1
-2753
-7372

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1017
SELECT ALL + col1 + - col0 / col1 col0 FROM tab2 AS cor0
----
13
31
58

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

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

query I rowsort
SELECT DISTINCT - cor0.col1 AS col2 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT 93 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( cor1.col1 * - ( + 97 ) ) col2 FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2, tab0 AS cor3
----
243 values hashing to 33ae6414330128de5d9d93bab55c0088

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

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

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

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

query I rowsort
SELECT ALL - 11 * - 28 + col2 AS col2 FROM tab1 AS cor0
----
362
365
404

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

query I rowsort
SELECT DISTINCT + 49 * + 50 FROM tab2 AS cor0
----
2450

query I rowsort
SELECT + col2 * - 49 FROM tab1 cor0
----
-2646
-2793
-4704

query I rowsort
SELECT ALL - col2 + col2 + + ( - col0 * - tab2.col0 ) FROM tab2
----
49
6084
6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * 38 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 56dfb4c5869893e99a71a276d82f782e

query I rowsort
SELECT + 46 * + col2 AS col2 FROM tab0
----
1518
3772
46

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

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

skipif mysql # not compatible
query I rowsort label-1035
SELECT DISTINCT + - col1 / - col1 + + cor0.col0 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT ALL - + 51 * + col1 FROM tab0 AS cor0
----
-4386
-4641
-4947

query I rowsort
SELECT + col0 + - col2 * col2 + col1 * col1 AS col1 FROM tab0 cor0
----
1646
6331
9443

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

query I rowsort
SELECT ALL - - col0 + + col2 * 4 AS col0 FROM tab0 AS cor0
----
156
39
417

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

query I rowsort
SELECT ALL col2 * 58 AS col0 FROM tab0 cor0
----
1914
4756
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + ( 33 ) col1 FROM tab1 AS cor0
----
-31
-47
30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * ( + col0 ) col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT 10 * + col2 AS col0 FROM tab2
----
260
270
380

onlyif mysql # use DIV operator for integer division
query I rowsort label-1045
SELECT + col0 DIV 26 FROM tab0 AS cor0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-1045
SELECT + col0 / 26 FROM tab0 AS cor0
----
0
1
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-1046
SELECT DISTINCT + col0 DIV + col0 + - 66 * + col0 AS col1 FROM tab1 AS cor0
----
-197
-4223
-5279

skipif mysql # not compatible
query I rowsort label-1046
SELECT DISTINCT + col0 / + col0 + - 66 * + col0 AS col1 FROM tab1 AS cor0
----
-197
-4223
-5279

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

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

query I rowsort
SELECT + cor0.col1 * - 26 + col0 FROM tab0 AS cor0
----
-2212
-2277
-2487

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1051
SELECT - + col0 * CAST( - 70 AS SIGNED ) + col2 * 79 + col2 FROM tab2 AS cor0
----
2650
7540
8570

skipif mysql # not compatible
query I rowsort label-1051
SELECT - + col0 * CAST ( - 70 AS INTEGER ) + col2 * 79 + col2 FROM tab2 AS cor0
----
2650
7540
8570

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

query I rowsort
SELECT - col2 * col1 * col2 + - col2 * 1 * col1 AS col0 FROM tab2 AS cor0
----
-23436
-25194
-41418

query I rowsort
SELECT + col0 * 85 + col2 * + col0 * 62 FROM tab1 AS cor0
----
10299
231616
482960

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

query I rowsort
SELECT col1 * 54 AS col1 FROM tab0 AS cor0
----
4644
4914
5238

onlyif mysql # use DIV operator for integer division
query I rowsort label-1057
SELECT - - 40 DIV 57 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1057
SELECT - - 40 / 57 AS col2 FROM tab2 AS cor0
----
0
0
0

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1061
SELECT + + 91 * + col2 + + CAST ( - col0 AS INTEGER ) * - col2 AS col0 FROM tab2 AS cor0
----
2646
4394
6460

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

query I rowsort
SELECT ( col1 ) + ( col2 + col0 ) * - cor0.col0 FROM tab0 AS cor0
----
-1163
-1282
-15128

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1064
SELECT - 26 * - col1 + CAST( - cor0.col1 AS SIGNED ) * + col2 AS col0 FROM tab0 AS cor0
----
-5096
-602
2425

skipif mysql # not compatible
query I rowsort label-1064
SELECT - 26 * - col1 + CAST ( - cor0.col1 AS INTEGER ) * + col2 AS col0 FROM tab0 AS cor0
----
-5096
-602
2425

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

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

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

skipif mysql # not compatible
query I rowsort label-1067
SELECT DISTINCT col0 + - cor0.col0 * + CAST ( - col1 AS INTEGER ) AS col1 FROM tab1 cor0
----
1120
704
81

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

skipif mysql # not compatible
query I rowsort label-1068
SELECT DISTINCT 14 + tab0.col0 / col2 AS col2 FROM tab0
----
14
15
49

query I rowsort
SELECT 56 FROM tab0, tab0 cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT ALL 81 + col2 AS col0 FROM tab1
----
135
138
177

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

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

query I rowsort
SELECT + + col0 * + col0 * cor0.col1 + + col0 + + col1 AS col2 FROM tab2 AS cor0
----
106193
1557
359093

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + ( cor0.col2 ) + col2 col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT 56 + - col2 AS col1 FROM tab0
----
-26
23
55

query I rowsort
SELECT + - ( - ( + cor1.col2 ) ) + 98 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 361b41105b151168e8276a6bd02bec55

query I rowsort
SELECT + col2 * col1 + 14 + + col0 FROM tab2 AS cor0
----
1626
739
858

query I rowsort
SELECT DISTINCT - 86 + col0 * - col2 FROM tab0
----
-121
-7384
-878

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

query I rowsort
SELECT col1 + + col0 * + col0 - ( col1 ) * col1 FROM tab1
----
-641
4006
6244

query I rowsort
SELECT - ( - col0 ) * - col1 - 86 AS col0 FROM tab0
----
-2150
-3481
-8185

query I rowsort
SELECT col1 * col1 + + tab1.col0 * - col2 * + 56 FROM tab1
----
-204188
-429911
-8396

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 9 * + col2 col0 FROM tab2 AS cor0
----
-234
-243
-342

query I rowsort
SELECT + + col0 * col0 + + 91 * - col2 + - col0 FROM tab1 AS cor0
----
-1155
-2416
-4908

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

query I rowsort
SELECT DISTINCT + 91 - - col2 * + 34 FROM tab1 AS cor0
----
1927
2029
3355

query I rowsort
SELECT - - 41 + col0 * col0 FROM tab2 cor0
----
6125
6282
90

query I rowsort
SELECT DISTINCT + ( col1 ) + col2 + + col2 * col1 FROM tab1 cor0
----
1357
1484
637

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 47 * col1 + col1 * - 93 col0 FROM tab2 AS cor0
----
-1426
-2714
-782

query I rowsort
SELECT cor0.col0 * col0 * col0 AS col2 FROM tab2 AS cor0
----
343
474552
493039

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

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

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

query I rowsort
SELECT + - 88 * cor0.col1 FROM tab2 AS cor0
----
-1496
-2728
-5192

query I rowsort
SELECT ALL + col1 - + 14 FROM tab0
----
72
77
83

query I rowsort
SELECT 51 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

onlyif mysql # use DIV operator for integer division
query I rowsort label-1095
SELECT DISTINCT col1 DIV 42 FROM tab0
----
2

skipif mysql # not compatible
query I rowsort label-1095
SELECT DISTINCT col1 / 42 FROM tab0
----
2

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

query I rowsort
SELECT col1 + + 81 AS col2 FROM tab1 AS cor0
----
107
91
94

query I rowsort
SELECT + col2 * 22 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-13
1715
702

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1102
SELECT ( col2 ) + - col1 + + 14 DIV col1 FROM tab1 AS cor0
----
28
48
84

skipif mysql # not compatible
query I rowsort label-1102
SELECT ( col2 ) + - col1 + + 14 / col1 FROM tab1 AS cor0
----
28
48
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-1103
SELECT - col2 * col0 DIV col1 FROM tab0 AS cor0
----
-80
-9
0

skipif mysql # not compatible
query I rowsort label-1103
SELECT - col2 * col0 / col1 FROM tab0 AS cor0
----
-80
-9
0

query I rowsort
SELECT DISTINCT - col0 * + 39 FROM tab1 AS cor0
----
-117
-2496
-3120

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

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col1 AS REAL ) * col2 + + 41 AS col0 FROM tab1 cor0
----
1289
1445
611

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

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

query I rowsort
SELECT ALL - - 5 * 37 + cor0.col1 FROM tab2 AS cor0
----
202
216
244

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 97 * 31 col1 FROM tab1 AS cor0
----
3007

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1112
SELECT - - 25 DIV - 57 + - col1 * - CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-1112
SELECT - - 25 / - 57 + - col1 * - CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
1040
640
78

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT + CAST ( - 23 AS REAL ) + col0 * col1 col0 FROM tab2 AS cor0
----
1320
194
4579

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( - 79 ) * + cor0.col0 * + col0 col2 FROM tab1 cor0
----
323584
505600
711

query I rowsort
SELECT DISTINCT + col1 * - 72 - col2 * ( col0 * col2 ) FROM tab0 cor0
----
-32328
-604988
-7019

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

query I rowsort
SELECT DISTINCT 73 * - col1 - - col2 AS col1 FROM tab2 AS cor0
----
-1203
-2236
-4281

query I rowsort
SELECT + 93 + + col1 AS col2 FROM tab1 AS cor0
----
103
106
119

query I rowsort
SELECT ALL + 19 + - col2 * - col1 FROM tab2 AS cor0
----
1553
665
856

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( 1 ) + col0 col0 FROM tab0 cor0
----
23
34
88

query I rowsort
SELECT + + 3 * + col0 + + col0 FROM tab2 AS cor0
----
28
312
316

query I rowsort
SELECT ALL - ( - col0 ) * ( - col0 ) * col1 + 21 AS col1 FROM tab2 AS cor0
----
-106076
-1498
-358935

query I rowsort
SELECT ALL + - col0 * + col1 + + ( ( + col1 ) * - cor0.col2 ) + + col0 FROM tab0 AS cor0
----
-15472
-3457
-4878

query I rowsort
SELECT tab2.col1 + + 15 - col1 FROM tab2
----
15
15
15

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

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

query I rowsort
SELECT 67 + - cor0.col2 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 2128718b768142fbe0582d966ab6502a

query I rowsort
SELECT ALL - col2 * - cor0.col2 + 84 + + col2 FROM tab2 AS cor0
----
1566
786
840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1135
SELECT - - col0 * - col0 * CAST( col1 AS SIGNED ) + col2 + + 68 * - 20 FROM tab0 AS cor0
----
-120184
-50863
-722089

skipif mysql # not compatible
query I rowsort label-1135
SELECT - - col0 * - col0 * CAST ( col1 AS INTEGER ) + col2 + + 68 * - 20 FROM tab0 AS cor0
----
-120184
-50863
-722089

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 42 + - 76 * + tab2.col1 col2 FROM tab2
----
-1250
-2314
-4442

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

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

query I rowsort
SELECT DISTINCT 56 + col1 * - col0 FROM tab1
----
-22
-584
-984

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

skipif mysql # not compatible
query I rowsort label-1140
SELECT DISTINCT - col2 / - cor0.col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT DISTINCT col0 + - 36 AS col0 FROM tab2 AS cor0
----
-29
42
43

query I rowsort
SELECT - - cor0.col2 + + col0 * cor0.col0 * + col1 FROM tab0 AS cor0
----
118826
49569
720893

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

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

query I rowsort
SELECT cor0.col2 + + ( 50 ) * + col1 AS col2 FROM tab0 AS cor0
----
4333
4632
4851

onlyif mysql # use DIV operator for integer division
query I rowsort label-1146
SELECT ALL cor0.col0 + ( + cor0.col0 ) DIV - col1 AS col2 FROM tab2 AS cor0
----
7
75
77

skipif mysql # not compatible
query I rowsort label-1146
SELECT ALL cor0.col0 + ( + cor0.col0 ) / - col1 AS col2 FROM tab2 AS cor0
----
7
75
77

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

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2, tab0 cor0, tab1 cor1
----
972 values hashing to 0210050fb1701e2797a9b17e1ebac91e

query I rowsort
SELECT ALL cor0.col2 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

onlyif mysql # use DIV operator for integer division
query I rowsort label-1150
SELECT col0 + col0 DIV + 38 FROM tab2
----
7
80
81

skipif mysql # not compatible
query I rowsort label-1150
SELECT col0 + col0 / + 38 FROM tab2
----
7
80
81

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

query I rowsort
SELECT ALL col0 * 99 AS col0 FROM tab1
----
297
6336
7920

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

query I rowsort
SELECT - col1 * + col1 + + col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT - cor0.col0 * col2 + ( col0 + + col1 ) FROM tab2 AS cor0
----
-151
-1891
-2906

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col2 + col1 col2 FROM tab2 AS cor0
----
-1475
-629
-806

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

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

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

query I rowsort
SELECT ALL - 65 + - col2 AS col0 FROM tab2
----
-103
-91
-92

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

query I rowsort
SELECT col2 + + tab0.col2 * col1 * 38 FROM tab0
----
107877
283638
3687

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

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

query I rowsort
SELECT + 8 + col0 * + col1 FROM tab1 AS cor0
----
1048
648
86

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 + col0 + col1 FROM tab1 AS cor0
----
-1155
-1375
-496

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

query I rowsort
SELECT DISTINCT 66 AS col0 FROM tab2
----
66

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

query I rowsort
SELECT ALL col2 * col0 + + 36 FROM tab0
----
71
7334
828

onlyif mysql # use DIV operator for integer division
query I rowsort label-1171
SELECT DISTINCT + tab1.col2 + - col2 DIV - ( col0 ) + col1 FROM tab1
----
110
67
98

skipif mysql # not compatible
query I rowsort label-1171
SELECT DISTINCT + tab1.col2 + - col2 / - ( col0 ) + col1 FROM tab1
----
110
67
98

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

query I rowsort
SELECT DISTINCT 87 - + tab0.col0 AS col2 FROM tab0, tab1 AS cor0
----
-2
52
63

query I rowsort
SELECT col1 + 86 + + 24 AS col1 FROM tab0
----
196
201
207

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

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

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

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

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

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

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

query I rowsort
SELECT col2 + + 97 + col1 AS col1 FROM tab1
----
164
177
206

query I rowsort
SELECT col2 + + 82 * col2 FROM tab1
----
4482
4731
7968

query I rowsort
SELECT - 48 + col0 AS col2 FROM tab2 AS cor0
----
-41
30
31

query I rowsort
SELECT ALL + ( - 70 ) * col1 FROM tab1 AS cor0
----
-1820
-700
-910

query I rowsort
SELECT cor0.col0 * - 44 + col2 * - 45 FROM tab0 AS cor0
----
-1585
-2541
-7606

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT - 42 * 78 FROM tab0 AS cor0
----
-3276

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

skipif mysql # not compatible
query I rowsort label-1190
SELECT - ( 90 ) / col2 AS col2 FROM tab1 AS cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 37 * + cor0.col2 col1 FROM tab1 AS cor0
----
-1998
-2109
-3552

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

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

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

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

query I rowsort
SELECT ALL 64 * col1 + col1 FROM tab0 cor0
----
5590
5915
6305

query I rowsort
SELECT DISTINCT col1 * + 62 FROM tab2 AS cor0
----
1054
1922
3658

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1197
SELECT ALL - CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-1197
SELECT ALL - CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
86
91
97

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

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

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

query I rowsort
SELECT ALL 94 FROM tab1, tab0 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

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

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

query I rowsort
SELECT ( + 83 ) AS col1 FROM tab2
----
83
83
83

query I rowsort
SELECT ALL cor0.col1 * 28 FROM tab1 AS cor0
----
280
364
728

query I rowsort
SELECT DISTINCT + cor0.col1 AS col2 FROM tab0, tab2 cor0
----
17
31
59

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

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

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

query I rowsort
SELECT - 26 + col1 * 90 FROM tab2 AS cor0
----
1504
2764
5284

query I rowsort
SELECT - - 89 * - col2 * - cor0.col0 FROM tab1 AS cor0
----
14418
324672
683520

query I rowsort
SELECT - col2 * + col2 * col0 + + 70 * col1 + col2 AS col2 FROM tab1 AS cor0
----
-207179
-6874
-736274

query I rowsort
SELECT + col0 * col1 + - 19 * - col2 AS col1 FROM tab0 AS cor0
----
2691
3414
9657

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

query I rowsort
SELECT + 20 * - col0 + 24 * - col2 AS col2 FROM tab2 AS cor0
----
-2184
-2492
-788

query I rowsort
SELECT 18 + - col2 AS col1 FROM tab0 AS cor0
----
-15
-64
17

query I rowsort
SELECT - - 83 + - col2 * + col1 AS col1 FROM tab2 AS cor0
----
-1451
-563
-754

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

skipif mysql # not compatible
query I rowsort label-1217
SELECT ALL + 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-1218
SELECT DISTINCT col2 DIV ( 8 ) AS col0 FROM tab0 cor0
----
0
10
4

skipif mysql # not compatible
query I rowsort label-1218
SELECT DISTINCT col2 / ( 8 ) AS col0 FROM tab0 cor0
----
0
10
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-1219
SELECT ALL + col2 + col2 * col1 DIV col2 AS col1 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-1219
SELECT ALL + col2 + col2 * col1 / col2 AS col1 FROM tab1 AS cor0
----
109
67
80

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

skipif mysql # not compatible
query I rowsort label-1220
SELECT DISTINCT cor0.col0 + - CAST ( col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-20
41
52

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1224
SELECT ALL cor0.col1 DIV - 61 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1224
SELECT ALL cor0.col1 / - 61 FROM tab2 AS cor0
----
0
0
0

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

query I rowsort
SELECT + 73 * 87 FROM tab1 AS cor0
----
6351
6351
6351

onlyif mysql # use DIV operator for integer division
query I rowsort label-1227
SELECT + col2 DIV + 4 FROM tab0
----
0
20
8

skipif mysql # not compatible
query I rowsort label-1227
SELECT + col2 / + 4 FROM tab0
----
0
20
8

query I rowsort
SELECT + col1 + 39 * 53 + + col0 FROM tab0
----
2177
2199
2247

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 cor0, tab0, tab2 cor1
----
972 values hashing to 1e9d01970ae508486ddabec967bb176c

query I rowsort
SELECT ALL + 36 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 4d1892e880125dc90345721151acb22c

query I rowsort
SELECT ALL 60 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to a97561e17ecaa618227c75a57b268f33

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

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

query I rowsort
SELECT ALL col2 + - 87 AS col2 FROM tab2 AS cor0
----
-49
-60
-61

query I rowsort
SELECT - - col0 + - ( 46 ) * + col2 FROM tab2 cor0
----
-1118
-1235
-1669

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1237
SELECT - col2 DIV col1 - cor0.col1 AS col2 FROM tab1 AS cor0
----
-15
-20
-28

skipif mysql # not compatible
query I rowsort label-1237
SELECT - col2 / col1 - cor0.col1 AS col2 FROM tab1 AS cor0
----
-15
-20
-28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col2 * 48 col0 FROM tab2
----
31008
40176
73632

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col1 col2 FROM tab1
----
100
169
676

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col2 + 3 col1 FROM tab1 AS cor0
----
-2913
-3246
-9213

onlyif mysql # use DIV operator for integer division
query I rowsort label-1243
SELECT + + cor0.col0 DIV + col2 + cor0.col0 DIV - col1 AS col2 FROM tab1 AS cor0
----
-5
-6
0

skipif mysql # not compatible
query I rowsort label-1243
SELECT + + cor0.col0 / + col2 + cor0.col0 / - col1 AS col2 FROM tab1 AS cor0
----
-5
-6
0

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

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

query I rowsort
SELECT + - 80 + ( + col1 ) * col0 AS col2 FROM tab1 AS cor0
----
-2
560
960

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

query I rowsort
SELECT ALL + col1 + col1 * ( 52 ) - col2 AS col0 FROM tab2
----
1616
3101
863

query I rowsort
SELECT DISTINCT 12 - col2 FROM tab2
----
-14
-15
-26

query I rowsort
SELECT - - 53 + + cor0.col2 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-1195
-1351
-517

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 12 * cor1.col0 col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
84
936
948

onlyif mysql # use DIV operator for integer division
query I rowsort label-1252
SELECT + tab0.col2 DIV - col1 + 50 * col0 AS col2 FROM tab0
----
1200
1750
4450

skipif mysql # not compatible
query I rowsort label-1252
SELECT + tab0.col2 / - col1 + 50 * col0 AS col2 FROM tab0
----
1200
1750
4450

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

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

skipif mysql # not compatible
query I rowsort label-1254
SELECT col0 / col0 AS col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL + col1 + col1 * - 79 AS col0 FROM tab1 cor0
----
-1014
-2028
-780

query I rowsort
SELECT ALL - 65 * cor0.col0 + - 68 FROM tab1 AS cor0
----
-263
-4228
-5268

query I rowsort
SELECT - 88 AS col2 FROM tab2 cor0
----
-88
-88
-88

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

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

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

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

query I rowsort
SELECT + - col2 * + 57 + col1 AS col1 FROM tab0 AS cor0
----
-1795
-4583
40

query I rowsort
SELECT DISTINCT + 10 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
10

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

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0, tab0 AS cor1, tab0, tab1 cor2
----
3645 values hashing to 5d64bf87effa587b137e9591cd2c54bf

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0, tab0 AS cor1, tab0, tab2 cor2
----
3645 values hashing to 61c64d7c972af4105004f57e1913df08

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

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

query I rowsort
SELECT + col2 * - cor0.col1 * col1 + + col0 AS col0 FROM tab0 AS cor0
----
-244044
-678953
-9374

query I rowsort
SELECT 55 * col2 FROM tab2 AS cor0
----
1430
1485
2090

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1270
SELECT DISTINCT + CAST( + 7 AS SIGNED ) + - col0 AS col0 FROM tab2 AS cor0
----
-71
-72
0

skipif mysql # not compatible
query I rowsort label-1270
SELECT DISTINCT + CAST ( + 7 AS INTEGER ) + - col0 AS col0 FROM tab2 AS cor0
----
-71
-72
0

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

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

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

query I rowsort
SELECT ALL col2 + col1 * - col0 * + 33 AS col0 FROM tab2 AS cor0
----
-151840
-44281
-7134

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

query I rowsort
SELECT DISTINCT col2 * col1 + 24 * 21 FROM tab2 AS cor0
----
1150
1341
2038

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1278
SELECT DISTINCT + ( col0 ) * - col2 + + col0 DIV col0 FROM tab2 AS cor0
----
-188
-2027
-3001

skipif mysql # not compatible
query I rowsort label-1278
SELECT DISTINCT + ( col0 ) * - col2 + + col0 / col0 FROM tab2 AS cor0
----
-188
-2027
-3001

query I rowsort
SELECT DISTINCT ( col0 ) + + 81 * col1 FROM tab0 AS cor0
----
6990
7460
7892

query I rowsort
SELECT 92 * - col0 AS col0 FROM tab1 AS cor0
----
-276
-5888
-7360

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - cor0.col0 + + col1 * + col2 + col2 col1 FROM tab1 cor0
----
1267
1536
2384

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

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

skipif mysql # not compatible
query I rowsort label-1283
SELECT col1 * col0 + CAST ( 93 AS INTEGER ) FROM tab2 AS cor0
----
1436
310
4695

query I rowsort
SELECT DISTINCT 55 AS col2 FROM tab0
----
55

query I rowsort
SELECT + ( 2 ) + col0 FROM tab2
----
80
81
9

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1287
SELECT + ( col1 ) DIV - col1 + tab2.col1 FROM tab2
----
16
30
58

skipif mysql # not compatible
query I rowsort label-1287
SELECT + ( col1 ) / - col1 + tab2.col1 FROM tab2
----
16
30
58

query I rowsort
SELECT 45 - col1 FROM tab1
----
19
32
35

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

query III rowsort
SELECT ALL * FROM tab2 WHERE ( + col2 ) BETWEEN NULL AND + col0
----

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab1.col2 col1 FROM tab1
----
-54
-57
-96

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

query I rowsort
SELECT col0 * col2 * + col0 - + col2 AS col1 FROM tab0
----
1224
18975
649440

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

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

query I rowsort
SELECT + col0 * col2 * - col1 - - col1 * + tab2.col1 FROM tab2
----
-116171
-4898
-50745

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

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

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

query I rowsort
SELECT tab2.col2 * + col2 * - col1 - - col1 FROM tab2
----
-22568
-24531
-39825

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

query I rowsort
SELECT ALL + col0 + + col0 AS col2 FROM tab0 WHERE NOT col1 * - col0 IN ( + col1 * col1 + col1 )
----
178
48
70

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1305
SELECT - col2 + col1 DIV 17 FROM tab2 AS cor0
----
-23
-26
-37

skipif mysql # not compatible
query I rowsort label-1305
SELECT - col2 + col1 / 17 FROM tab2 AS cor0
----
-23
-26
-37

onlyif mysql # use DIV operator for integer division
query I rowsort label-1306
SELECT DISTINCT - col0 - col1 DIV - col0 FROM tab1 AS cor0
----
-64
-80
5

skipif mysql # not compatible
query I rowsort label-1306
SELECT DISTINCT - col0 - col1 / - col0 FROM tab1 AS cor0
----
-64
-80
5

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

query I rowsort
SELECT DISTINCT + cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab0
----
24
35
89

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

query I rowsort
SELECT + col2 + col0 + + col2 FROM tab1 AS cor0 WHERE NULL >= NULL
----

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

query I rowsort
SELECT + col0 + + col1 * - col0 + col1 * tab2.col0 AS col2 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT col1 + tab2.col2 + + col2 AS col0 FROM tab2
----
111
85
93

query I rowsort
SELECT ALL - col0 * - col0 AS col2 FROM tab0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col0 * - col1 col2 FROM tab0
----
-2064
-3395
-8099

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

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

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

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

query I rowsort
SELECT DISTINCT + col0 + col0 * + col2 + col1 AS col0 FROM tab1
----
191
3722
7773

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

query I rowsort
SELECT ALL col2 * col1 + + col0 + - col1 * col2 AS col1 FROM tab2
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-1322
SELECT + tab0.col0 DIV col2 + + col0 * + col0 * + col0 AS col0 FROM tab0
----
13824
42910
704970

skipif mysql # not compatible
query I rowsort label-1322
SELECT + tab0.col0 / col2 + + col0 * + col0 * + col0 AS col0 FROM tab0
----
13824
42910
704970

query I rowsort
SELECT + col1 AS col2 FROM tab2 WHERE NULL IN ( tab2.col1 + + col2 )
----

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * tab2.col1 + col1 col0 FROM tab2
----
-1326
-186
-4543

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

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

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

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

query I rowsort
SELECT + col1 * + col1 * tab1.col0 + tab1.col2 AS col0 FROM tab1
----
13616
2082
6457

query I rowsort
SELECT col0 / col2 + - col2 AS col1 FROM tab0 WHERE NOT col1 <> NULL
----

query I rowsort
SELECT ALL col2 + col2 + tab1.col1 FROM tab1
----
124
134
205

onlyif mysql # use DIV operator for integer division
query I rowsort label-1332
SELECT col2 DIV tab0.col2 + col2 + col1 AS col0 FROM tab0
----
120
174
99

skipif mysql # not compatible
query I rowsort label-1332
SELECT col2 / tab0.col2 + col2 + col1 AS col0 FROM tab0
----
120
174
99

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

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

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

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

query I rowsort
SELECT DISTINCT col2 * + ( tab0.col1 + + col1 * 51 ) FROM tab0
----
147576
388024
5044

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

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

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

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

query I rowsort
SELECT + 18 * ( - col2 ) AS col2 FROM tab0
----
-1476
-18
-594

query I rowsort
SELECT ALL 8 * col0 - + col0 * - ( - 55 ) FROM tab0
----
-1128
-1645
-4183

query I rowsort
SELECT ALL ( tab1.col0 + + col1 ) * + 13 AS col0 FROM tab1
----
1209
377
962

query I rowsort
SELECT DISTINCT cor0.col1 + 39 AS col0 FROM tab2, tab2 AS cor0, tab1 cor1
----
56
70
98

query I rowsort
SELECT + + 18 * col2 AS col1 FROM tab0 AS cor0
----
1476
18
594

query I rowsort
SELECT DISTINCT + 99 * col2 AS col1 FROM tab0
----
3267
8118
99

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col1 * cor0.col1 col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT + col1 * + 19 * + col0 FROM tab1 cor0
----
12160
1482
19760

query I rowsort
SELECT - col1 + ( - 99 ) AS col1 FROM tab2 AS cor0
----
-116
-130
-158

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

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

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

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

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

query I rowsort
SELECT + tab0.col1 * 77 * - col0 + col0 * + col0 FROM tab0
----
-158352
-260190
-615702

query I rowsort
SELECT DISTINCT 31 * + col0 + - col2 FROM tab0 AS cor0
----
1084
2677
711

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1358
SELECT ALL - CAST( + 73 AS SIGNED ) * - col1 + col2 AS col1 FROM tab1 AS cor0
----
1045
1952
787

skipif mysql # not compatible
query I rowsort label-1358
SELECT ALL - CAST ( + 73 AS INTEGER ) * - col1 + col2 AS col1 FROM tab1 AS cor0
----
1045
1952
787

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

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

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

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

query I rowsort
SELECT ALL 48 AS col2 FROM tab1 AS cor0
----
48
48
48

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

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

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

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

query I rowsort
SELECT - + 12 * + col2 AS col0 FROM tab1 AS cor0
----
-1152
-648
-684

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

query I rowsort
SELECT - cor0.col2 * col0 - - col1 * + col0 * + col0 FROM tab2 AS cor0
----
103095
1330
356928

query I rowsort
SELECT DISTINCT col1 * col2 - col2 * col0 * tab0.col0 FROM tab0
----
-1128
-16170
-642060

query I rowsort
SELECT ALL + 91 - ( col0 * col2 ) FROM tab1
----
-3557
-71
-7589

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1373
SELECT ALL CAST( - 47 AS SIGNED ) - col2 col1 FROM tab1
----
-101
-104
-143

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1373
SELECT ALL CAST ( - 47 AS INTEGER ) - col2 col1 FROM tab1
----
-101
-104
-143

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

skipif mysql # not compatible
query I rowsort label-1374
SELECT ALL - CAST ( + ( col0 ) AS INTEGER ) * - col0 + col2 - col0 FROM tab1
----
4089
60
6416

query I rowsort
SELECT - col0 * 45 FROM tab2
----
-315
-3510
-3555

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - 73 * 72 col0 FROM tab2 cor0
----
-5197
-5225
-5239

query I rowsort
SELECT DISTINCT + - col0 * - col1 + - col2 + - col0 AS col1 FROM tab1 AS cor0
----
21
519
864

query I rowsort
SELECT ALL + col0 * col2 - 7 AS col2 FROM tab2 AS cor0
----
182
2021
2995

query I rowsort
SELECT DISTINCT - col1 * col0 - 86 AS col2 FROM tab0 AS cor0
----
-2150
-3481
-8185

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

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

query I rowsort
SELECT DISTINCT 58 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
58

query I rowsort
SELECT ALL + col2 * 74 FROM tab1
----
3996
4218
7104

query I rowsort
SELECT col0 * + ( col2 ) - - col0 AS col1 FROM tab0
----
70
7387
816

query I rowsort
SELECT - col1 + + col2 + + col2 FROM tab2 AS cor0
----
-7
23
59

query I rowsort
SELECT DISTINCT col2 + col0 * + col0 FROM tab0
----
1226
609
8003

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

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

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

query I rowsort
SELECT col1 * col2 + - col2 * - col2 AS col2 FROM tab2
----
1566
2090
2210

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col1 * - tab1.col0 col0 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT - col2 - - tab1.col2 FROM tab1
----
0
0
0

query I rowsort
SELECT - col0 - col1 * + col1 * + col2 FROM tab1
----
-16304
-36507
-5764

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

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

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col0 ) * col1 col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT 45 + - col0 FROM tab1
----
-19
-35
42

query I rowsort
SELECT DISTINCT - 10 + + col2 AS col0 FROM tab2
----
16
17
28

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

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

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

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

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

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

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

query I rowsort
SELECT col1 + + col2 + 4 FROM tab2
----
59
62
89

query I rowsort
SELECT + 78 - + col2 * 11 AS col0 FROM tab1 AS cor0
----
-516
-549
-978

query I rowsort
SELECT ALL - 11 + col1 FROM tab0 AS cor0
----
75
80
86

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

query I rowsort
SELECT ALL + 66 * col0 FROM tab1 AS cor0
----
198
4224
5280

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

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

query I rowsort
SELECT - col1 + + col1 * col2 * + col1 AS col1 FROM tab2 AS cor0
----
10965
25916
90447

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

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

query I rowsort
SELECT 6 FROM tab1, tab2 AS cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

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

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

query I rowsort
SELECT + - col1 + - 3 * col2 FROM tab1 AS cor0
----
-181
-188
-301

query I rowsort
SELECT + col2 + 62 * 28 FROM tab2 cor0
----
1762
1763
1774

onlyif mysql # use DIV operator for integer division
query I rowsort label-1427
SELECT - col1 DIV - col0 + + 89 * - col0 AS col1 FROM tab1 AS cor0
----
-259
-5696
-7120

skipif mysql # not compatible
query I rowsort label-1427
SELECT - col1 / - col0 + + 89 * - col0 AS col1 FROM tab1 AS cor0
----
-259
-5696
-7120

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

query I rowsort
SELECT DISTINCT 85 + col2 + + col1 FROM tab0 cor0
----
183
204
258

query I rowsort
SELECT DISTINCT + 7 * - cor0.col1 + cor0.col0 FROM tab2 AS cor0
----
-210
-335
-40

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

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

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

query I rowsort
SELECT col1 + - 58 FROM tab2
----
-27
-41
1

query I rowsort
SELECT ALL - 76 AS col0 FROM tab0
----
-76
-76
-76

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

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

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

query I rowsort
SELECT ALL + 85 * + 37 FROM tab0 AS cor0
----
3145
3145
3145

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - 96 + + cor0.col2 * - 96 col0 FROM tab2 AS cor0
----
-5280
-5568
-8160

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

query I rowsort
SELECT ALL ( - col0 ) - cor0.col1 * 49 FROM tab1 AS cor0
----
-1277
-554
-717

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * + 75 col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 591d58ec249ef092a80b24db3c0a3f82

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

query I rowsort
SELECT ALL + ( col0 ) * cor0.col1 - col1 * - ( col2 ) AS col1 FROM tab1 AS cor0
----
1210
1482
2288

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + 78 FROM tab1 cor0
----
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-1451
SELECT col0 + cor0.col0 DIV col0 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-1451
SELECT col0 + cor0.col0 / col0 FROM tab0 AS cor0
----
25
36
90

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

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

query I rowsort
SELECT DISTINCT 84 AS col1 FROM tab0 AS cor0
----
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + col2 * - col1 col1 FROM tab0
----
-611884
-93654
-97

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

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

query I rowsort
SELECT DISTINCT - ( + 89 ) + cor1.col0 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
-25
-86
-9

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

query I rowsort
SELECT DISTINCT - col1 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT tab0.col0 * + tab0.col1 + + 91 AS col0 FROM tab0, tab2, tab2 AS cor0, tab2 AS cor1
----
81 values hashing to d8c438aba0ae69462447a197c222553c

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

query I rowsort
SELECT + + 73 + col0 FROM tab1 AS cor0
----
137
153
76

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

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

query I rowsort
SELECT ALL col0 * + ( ( - col2 ) + 93 ) AS col2 FROM tab2
----
4345
462
5226

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

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

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

query I rowsort
SELECT ALL - + ( cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 4 + + col0 col1 FROM tab2 AS cor0
----
3
74
75

query I rowsort
SELECT + cor0.col0 + 37 * col1 FROM tab2 cor0
----
1154
2261
708

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

query I rowsort
SELECT + col1 - 2 * col1 AS col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT + 31 FROM tab2, tab0 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

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

query I rowsort
SELECT - + col0 * + 47 AS col0 FROM tab2 AS cor0
----
-329
-3666
-3713

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

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

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

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

query I rowsort
SELECT - col2 + - 79 * - col1 AS col2 FROM tab1 AS cor0
----
2000
733
931

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

query I rowsort
SELECT + 56 * col1 AS col0 FROM tab1 AS cor0
----
1456
560
728

onlyif mysql # use DIV operator for integer division
query I rowsort label-1482
SELECT DISTINCT - cor0.col2 DIV - col1 + cor0.col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1482
SELECT DISTINCT - cor0.col2 / - col1 + cor0.col2 FROM tab0 AS cor0
----
1
33
82

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

query I rowsort
SELECT DISTINCT col2 * + 54 FROM tab2
----
1404
1458
2052

query I rowsort
SELECT 44 FROM tab2, tab0, tab0 AS cor0, tab2 AS cor1
----
81 values hashing to 19a2b9512177749564ba22ea2213fe3f

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

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

query I rowsort
SELECT ALL ( + 74 ) FROM tab2 cor0
----
74
74
74

query I rowsort
SELECT - col0 * 15 AS col2 FROM tab1 cor0
----
-1200
-45
-960

query I rowsort
SELECT DISTINCT + col0 * - cor0.col1 + - col1 * cor0.col1 FROM tab0 AS cor0
----
-12804
-16380
-9460

query I rowsort
SELECT DISTINCT - - cor0.col2 * + 77 + - col0 AS col1 FROM tab1 AS cor0
----
4155
4325
7312

query I rowsort
SELECT + - col1 + col2 * - 82 * + cor0.col1 FROM tab0 AS cor0
----
-232802
-611975
-8051

query I rowsort
SELECT - - col2 * + col2 + - 68 FROM tab2 AS cor0
----
1376
608
661

query I rowsort
SELECT + - 99 * - col0 AS col0 FROM tab0 AS cor0
----
2376
3465
8811

query I rowsort
SELECT + col1 + col2 * - cor0.col2 FROM tab0 AS cor0
----
-1003
-6633
96

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

query I rowsort
SELECT ALL + - 70 AS col2 FROM tab0 AS cor0
----
-70
-70
-70

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

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

query I rowsort
SELECT ALL + - 55 FROM tab0 AS cor0
----
-55
-55
-55

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * col1 + col0 col2 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT - col2 * - col1 - col1 * - col0 AS col2 FROM tab0 AS cor0
----
15561
3492
4902

query I rowsort
SELECT ALL - 19 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 339c9d62143bf2f7566b89a1b56eeeb4

query I rowsort
SELECT DISTINCT - col2 * 87 FROM tab1 AS cor0
----
-4698
-4959
-8352

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

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

query I rowsort
SELECT DISTINCT col2 - col1 * 45 * - col2 AS col0 FROM tab0 AS cor0
----
127743
335872
4366

onlyif mysql # use DIV operator for integer division
query I rowsort label-1508
SELECT + cor0.col1 DIV ( col1 ) + col2 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-1508
SELECT + cor0.col1 / ( col1 ) + col2 FROM tab1 AS cor0
----
55
58
97

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1511
SELECT cor0.col2 + CAST( + 38 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
64
65
76

skipif mysql # not compatible
query I rowsort label-1511
SELECT cor0.col2 + CAST ( + 38 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
64
65
76

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1514
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-1514
SELECT DISTINCT - col0 / - col0 col1 FROM tab2 AS cor0
----
1

query I rowsort
SELECT ALL + col1 * 45 * - col0 AS col0 FROM tab1 cor0
----
-28800
-3510
-46800

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

query I rowsort
SELECT ALL + - col2 * - 29 + + col2 AS col2 FROM tab0 cor0
----
2460
30
990

query I rowsort
SELECT DISTINCT col2 * + 31 - - 73 FROM tab0 AS cor0
----
104
1096
2615

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

query I rowsort
SELECT ALL + + cor0.col2 + 60 * + col2 FROM tab2 AS cor0
----
1586
1647
2318

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

query I rowsort
SELECT + 69 - col2 * ( - col2 ) AS col2 FROM tab1
----
2985
3318
9285

query I rowsort
SELECT 42 + col1 FROM tab2
----
101
59
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col2 * ( + col2 ) col2 FROM tab0 AS cor0
----
-1
-1089
-6724

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

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

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

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

query I rowsort
SELECT DISTINCT - col0 * + col1 AS col1 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - col0 + + 68 * - cor0.col2 FROM tab2 AS cor0
----
-1843
-1846
-2663

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * - col0 col0 FROM tab0 AS cor0
----
-35
-7298
-792

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0 CROSS JOIN tab1, tab1 cor1
----
972 values hashing to 7864aada86bf5bf5e1621c7905de8dcd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 41 col0 FROM tab2, tab2 AS cor0, tab1 AS cor1, tab1, tab2 AS cor2
----
243 values hashing to 945348bfd1b34283993fff3a1279f1bd

query I rowsort
SELECT ALL - col1 + - col2 * + col2 + 32 * + col1 FROM tab2 AS cor0
----
-917
1153
232

onlyif mysql # use DIV operator for integer division
query I rowsort label-1535
SELECT DISTINCT + 44 DIV 1 FROM tab1
----
44

skipif mysql # not compatible
query I rowsort label-1535
SELECT DISTINCT + 44 / 1 FROM tab1
----
44

query I rowsort
SELECT col1 + tab1.col1 * tab1.col1 AS col1 FROM tab1
----
110
182
702

query I rowsort
SELECT tab2.col1 * - col1 + ( col2 ) + col1 * col0 FROM tab2
----
-717
1092
1147

query I rowsort
SELECT + + col2 * col0 AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT 26 + - tab1.col2 AS col2 FROM tab1
----
-28
-31
-70

query I rowsort
SELECT - 98 AS col1 FROM tab2
----
-98
-98
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-1541
SELECT - col2 + col0 DIV ( col1 ) + col2 * - col1 AS col0 FROM tab1
----
-1338
-1458
-621

skipif mysql # not compatible
query I rowsort label-1541
SELECT - col2 + col0 / ( col1 ) + col2 * - col1 AS col0 FROM tab1
----
-1338
-1458
-621

query I rowsort
SELECT col2 + col2 + 75 FROM tab0 cor0
----
141
239
77

query I rowsort
SELECT ALL - - 86 FROM tab2 AS cor0
----
86
86
86

query I rowsort
SELECT 45 * col1 + ( - col0 + + col0 ) * cor0.col0 AS col0 FROM tab1 AS cor0
----
1170
450
585

query I rowsort
SELECT + ( cor0.col2 ) FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0 WHERE NOT NULL IN ( - cor0.col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + - col1 col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT col0 * col0 + col1 * 45 FROM tab0 AS cor0
----
12016
4446
5590

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 58 * col0 + - col1 col1 FROM tab1 AS cor0
----
148
3702
4627

query I rowsort
SELECT + - 18 AS col1 FROM tab0 AS cor0
----
-18
-18
-18

query I rowsort
SELECT ALL + tab0.col2 * - col2 AS col2 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT + + cor0.col1 + + col1 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT DISTINCT - col2 * 75 * - col2 FROM tab1
----
218700
243675
691200

query I rowsort
SELECT DISTINCT - cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
-54
-57
-96

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0 CROSS JOIN tab2, tab0 cor1, tab0 AS cor2
----
3645 values hashing to 7e665e04e6102323f69d70091871d1d2

query I rowsort
SELECT + ( col0 ) * col2 FROM tab2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-1557
SELECT DISTINCT + - 42 DIV - cor0.col2 FROM tab1 cor0
----
0

skipif mysql # not compatible
query I rowsort label-1557
SELECT DISTINCT + - 42 / - cor0.col2 FROM tab1 cor0
----
0

query I rowsort
SELECT DISTINCT - + 3 + cor0.col0 * col1 FROM tab1 AS cor0
----
1037
637
75

query I rowsort
SELECT + col1 * 48 FROM tab0 AS cor0
----
4128
4368
4656

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1560
SELECT + CAST( + col2 AS SIGNED ) * - col2 AS col0 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif mysql # not compatible
query I rowsort label-1560
SELECT + CAST ( + col2 AS INTEGER ) * - col2 AS col0 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-1561
SELECT - cor0.col2 DIV + tab0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to ed538cbca92822d47113f4edcd5b4b6e

skipif mysql # not compatible
query I rowsort label-1561
SELECT - cor0.col2 / + tab0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to ed538cbca92822d47113f4edcd5b4b6e

query I rowsort
SELECT cor0.col1 + 47 FROM tab1, tab0 AS cor0
----
9 values hashing to 1ea78ec4befe62254397cde19f57a80f

onlyif mysql # use DIV operator for integer division
query I rowsort label-1563
SELECT col0 DIV + col1 + tab2.col0 AS col1 FROM tab2
----
7
79
83

skipif mysql # not compatible
query I rowsort label-1563
SELECT col0 / + col1 + tab2.col0 AS col1 FROM tab2
----
7
79
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1564
SELECT - - 95 * col2 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1564
SELECT - - 95 * col2 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - 44 * col0 + col0 AS col1 FROM tab1 AS cor0
----
135
2880
3600

query I rowsort
SELECT ALL - ( col0 * col0 + + col0 ) AS col2 FROM tab0
----
-1260
-600
-8010

query I rowsort
SELECT col1 * + 66 AS col1 FROM tab0 AS cor0
----
5676
6006
6402

query I rowsort
SELECT DISTINCT - 6 * cor0.col1 * 63 AS col0 FROM tab1, tab0 AS cor0, tab1 cor1
----
-32508
-34398
-36666

query I rowsort
SELECT DISTINCT col1 - col1 FROM tab2 cor0
----
0

query I rowsort
SELECT - - col2 * 18 FROM tab2 AS cor0
----
468
486
684

query I rowsort
SELECT - col0 * 93 + col2 * - col1 FROM tab2 AS cor0
----
-1488
-7993
-8788

query I rowsort
SELECT col1 * + col2 * col0 FROM tab0 cor0
----
3395
664118
68112

query I rowsort
SELECT ALL + cor0.col1 + + cor0.col1 AS col0 FROM tab0, tab2 cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 3c5705a9f276442a483a9ba456734eae

query I rowsort
SELECT DISTINCT - - col1 + + 74 * col1 FROM tab0 AS cor0
----
6450
6825
7275

query I rowsort
SELECT - + col0 * + col0 FROM tab0 cor0
----
-1225
-576
-7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1576
SELECT CAST( 92 AS SIGNED ) AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

skipif mysql # not compatible
query I rowsort label-1576
SELECT CAST ( 92 AS INTEGER ) AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT col0 * + 30 FROM tab1 AS cor0
----
1920
2400
90

query I rowsort
SELECT - col2 + - 13 + col1 FROM tab1 AS cor0
----
-41
-60
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1579
SELECT - CAST( + cor0.col1 AS SIGNED ) * col0 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-1579
SELECT - CAST ( + cor0.col1 AS INTEGER ) * col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL ( 78 ) FROM tab2
----
78
78
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-1581
SELECT ALL - + col2 DIV + 13 + col2 + - 59 * col0 AS col0 FROM tab1 AS cor0
----
-127
-3723
-4631

skipif mysql # not compatible
query I rowsort label-1581
SELECT ALL - + col2 / + 13 + col2 + - 59 * col0 AS col0 FROM tab1 AS cor0
----
-127
-3723
-4631

query I rowsort
SELECT ALL cor1.col1 + 55 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 70d0bccb2d55c423358c1381a3225405

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1583
SELECT ALL CAST( col2 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-1583
SELECT ALL CAST ( col2 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL cor0.col1 * 62 FROM tab2 AS cor0
----
1054
1922
3658

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0, tab0 AS cor0, tab1 cor1
----
972 values hashing to 5621675b1bd32b061d284d0444c76601

query I rowsort
SELECT + col0 * col1 + + 53 FROM tab1 AS cor0
----
1093
131
693

query I rowsort
SELECT 48 + col2 FROM tab1 AS cor0
----
102
105
144

query I rowsort
SELECT - cor0.col1 * col0 + - 43 FROM tab2 AS cor0
----
-1386
-260
-4645

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1589
SELECT + col1 + CAST( col1 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-1589
SELECT + col1 + CAST ( col1 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
172
182
194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1590
SELECT ALL col2 * + CAST( NULL AS SIGNED ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1590
SELECT ALL col2 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col1 * + col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ALL + ( col2 ) FROM tab1
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1593
SELECT - + col0 * - cor0.col2 + + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1593
SELECT - + col0 * - cor0.col2 + + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col0 - - cor0.col2 AS col2 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-1595
SELECT ALL - - 16 + + cor0.col1 DIV col1 FROM tab2 AS cor0
----
17
17
17

skipif mysql # not compatible
query I rowsort label-1595
SELECT ALL - - 16 + + cor0.col1 / col1 FROM tab2 AS cor0
----
17
17
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1596
SELECT ALL - col2 / + cor0.col0 + + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1596
SELECT ALL - col2 / + cor0.col0 + + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 22 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT cor0.col2 + - col1 * ( - 61 ) FROM tab0 AS cor0
----
5279
5633
5918

query I rowsort
SELECT DISTINCT + + 98 * - col2 + + col1 * - col2 AS col2 FROM tab2 AS cor0
----
-3483
-4082
-4370

onlyif mysql # use DIV operator for integer division
query I rowsort label-1600
SELECT 66 DIV - ( - col1 ) + 7 FROM tab1
----
12
13
9

skipif mysql # not compatible
query I rowsort label-1600
SELECT 66 / - ( - col1 ) + 7 FROM tab1
----
12
13
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 24 + cor0.col2 col1 FROM tab0, tab2 AS cor0
----
50
51
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-1602
SELECT ALL tab2.col0 DIV + col0 + tab2.col1 AS col1 FROM tab2
----
18
32
60

skipif mysql # not compatible
query I rowsort label-1602
SELECT ALL tab2.col0 / + col0 + tab2.col1 AS col1 FROM tab2
----
18
32
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 71 col0 FROM tab1
----
71
71
71

query I rowsort
SELECT - 22 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 647e567609c5ada1d3454d2102819bfe

query I rowsort
SELECT 83 + tab0.col0 * col2 FROM tab0
----
118
7381
875

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1606
SELECT - + 59 * + col0 * CAST( col0 AS SIGNED ) + + col0 FROM tab0 cor0
----
-33960
-467250
-72240

skipif mysql # not compatible
query I rowsort label-1606
SELECT - + 59 * + col0 * CAST ( col0 AS INTEGER ) + + col0 FROM tab0 cor0
----
-33960
-467250
-72240

query I rowsort
SELECT col0 + col1 * col2 AS col1 FROM tab1 AS cor0
----
1328
1407
634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab2.col0 - - ( + col1 + - col2 ) * ( + col0 ) col1 FROM tab2
----
-1580
2652
35

query I rowsort
SELECT ALL - col0 - - col0 AS col2 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1610
SELECT col0 * CAST( NULL AS SIGNED ) / tab0.col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1610
SELECT col0 * CAST ( NULL AS INTEGER ) / tab0.col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT tab0.col1 * col1 AS col0 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT col1 * col2 * + col1 AS col1 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT col0 * - ( - col2 * + tab0.col1 ) AS col1 FROM tab0
----
3395
664118
68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 33 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 8035c665a75d22be5922be1a4e574e03

query I rowsort
SELECT ALL + col2 + col0 - + 96 * col2 FROM tab2
----
-2392
-2558
-3531

onlyif mysql # use DIV operator for integer division
query I rowsort label-1616
SELECT + col2 DIV col0 + - col0 FROM tab0 AS cor0
----
-23
-35
-89

skipif mysql # not compatible
query I rowsort label-1616
SELECT + col2 / col0 + - col0 FROM tab0 AS cor0
----
-23
-35
-89

query I rowsort
SELECT - 88 * - col0 + + col0 FROM tab0 AS cor0
----
2136
3115
7921

query I rowsort
SELECT ALL 14 + + 49 FROM tab0
----
63
63
63

query I rowsort
SELECT + 12 * - col0 - + cor0.col0 * - 59 AS col0 FROM tab2 AS cor0
----
329
3666
3713

query I rowsort
SELECT DISTINCT - 2 + 41 FROM tab0 AS cor0
----
39

query I rowsort
SELECT + + col0 * + col2 + - col2 * + col2 - cor0.col1 * + col0 FROM tab2 AS cor0
----
-3250
-757
215

query I rowsort
SELECT DISTINCT - + 76 FROM tab1 AS cor0
----
-76

query I rowsort
SELECT + 39 * col2 + + col0 - col1 AS col1 FROM tab0 AS cor0
----
-23
1225
3196

query I rowsort
SELECT ALL tab1.col1 AS col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL col0 + - col0 * col2 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT - - 73 + 67 + col2 FROM tab2 AS cor0
----
166
167
178

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1627
SELECT ALL + + CAST( NULL AS SIGNED ) * + cor0.col1 col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1627
SELECT ALL + + CAST ( NULL AS INTEGER ) * + cor0.col1 col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + ( + cor0.col0 ) + + cor0.col1 AS col2 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1629
SELECT ALL - + CAST( NULL AS SIGNED ) * col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1629
SELECT ALL - + CAST ( NULL AS INTEGER ) * col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( col0 ) * - col0 FROM tab2 AS cor0
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-1631
SELECT - - 50 DIV + col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1631
SELECT - - 50 / + col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - - col1 * - col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT 28 + - tab1.col0 * - col0 + 10 FROM tab1
----
4134
47
6438

query I rowsort
SELECT 37 + ( col2 ) AS col0 FROM tab2
----
63
64
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-1635
SELECT ( col1 * col2 ) + col0 DIV - col0 AS col1 FROM tab2
----
1533
645
836

skipif mysql # not compatible
query I rowsort label-1635
SELECT ( col1 * col2 ) + col0 / - col0 AS col1 FROM tab2
----
1533
645
836

query I rowsort
SELECT DISTINCT 47 + + tab0.col0 + col1 * - col1 AS col2 FROM tab0
----
-7325
-8145
-9327

query I rowsort
SELECT DISTINCT + 74 * - col2 FROM tab0 AS cor0
----
-2442
-6068
-74

query I rowsort
SELECT ALL + 68 + + col1 AS col2 FROM tab2 cor0
----
127
85
99

query I rowsort
SELECT ALL 47 FROM tab2, tab1 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col1 col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ( + cor0.col1 ) + cor0.col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT - + 95 * + col2 * col1 FROM tab1 AS cor0
----
-118560
-133380
-54150

query I rowsort
SELECT - cor0.col0 + - cor0.col2 * col1 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT DISTINCT - 70 * cor0.col0 FROM tab2 cor0
----
-490
-5460
-5530

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 21 + + cor0.col1 col2 FROM tab1 AS cor0
----
31
34
47

query I rowsort
SELECT ALL + 85 FROM tab0 AS cor0
----
85
85
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 53 col2 FROM tab1 AS cor0
----
53

query I rowsort
SELECT 91 + + col2 FROM tab1 AS cor0
----
145
148
187

query I rowsort
SELECT + + col1 - - col0 AS col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL + col0 * cor0.col2 AS col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - cor0.col1 + col0 * - col1 FROM tab2 AS cor0
----
-1360
-248
-4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * col1 col0 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1653
SELECT - col2 + - col1 * CAST( + col2 AS SIGNED ) * col2 AS col1 FROM tab0 AS cor0
----
-611966
-93687
-98

skipif mysql # not compatible
query I rowsort label-1653
SELECT - col2 + - col1 * CAST ( + col2 AS INTEGER ) * col2 AS col1 FROM tab0 AS cor0
----
-611966
-93687
-98

query I rowsort
SELECT ALL + 34 + col2 * + col1 AS col1 FROM tab1 AS cor0
----
1282
1438
604

query I rowsort
SELECT - + col2 + col0 * 43 AS col1 FROM tab2 AS cor0
----
274
3328
3359

onlyif mysql # use DIV operator for integer division
query I rowsort label-1656
SELECT + col1 + col2 DIV - 90 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-1656
SELECT + col1 + col2 / - 90 FROM tab2 AS cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 66 * col2 col0 FROM tab1 cor0
----
3564
3762
6336

query I rowsort
SELECT DISTINCT + col0 + - 71 FROM tab1 AS cor0
----
-68
-7
9

query I rowsort
SELECT ALL + col2 * 99 AS col0 FROM tab0 AS cor0
----
3267
8118
99

query I rowsort
SELECT DISTINCT + col1 * col1 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT + col1 + - 95 * + col1 + + col0 * - col1 AS col1 FROM tab0 AS cor0
----
-10148
-12513
-16653

query I rowsort
SELECT DISTINCT 93 FROM tab0, tab2 AS cor0
----
93

query I rowsort
SELECT DISTINCT - col1 * col0 * col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-1664
SELECT ALL + col2 DIV cor0.col1 AS col2 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-1664
SELECT ALL + col2 / cor0.col1 AS col2 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT + - col2 + 3 AS col0 FROM tab2 AS cor0
----
-23
-24
-35

query I rowsort
SELECT ALL + cor0.col1 * - col1 + 54 AS col2 FROM tab2 AS cor0
----
-235
-3427
-907

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1667
SELECT DISTINCT col1 * + CAST( NULL AS SIGNED ) + ( col2 * - col2 ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1667
SELECT DISTINCT col1 * + CAST ( NULL AS INTEGER ) + ( col2 * - col2 ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - col0 * ( 48 ) + col0 FROM tab2 AS cor0
----
-329
-3666
-3713

onlyif mysql # use DIV operator for integer division
query I rowsort label-1669
SELECT ALL cor0.col1 * + 22 + - col2 * col1 DIV + col0 FROM tab2 AS cor0
----
1279
366
563

skipif mysql # not compatible
query I rowsort label-1669
SELECT ALL cor0.col1 * + 22 + - col2 * col1 / + col0 FROM tab2 AS cor0
----
1279
366
563

query I rowsort
SELECT + 26 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT - ( - 5 ) + col0 FROM tab1 cor0
----
69
8
85

query I rowsort
SELECT ALL 59 * col2 FROM tab1 AS cor0
----
3186
3363
5664

query I rowsort
SELECT DISTINCT + col0 * ( - col1 ) + - col0 AS col1 FROM tab1 AS cor0
----
-1120
-704
-81

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 AS cor2, tab1 AS cor3
----
3645 values hashing to 7ccb6e2515d95809a8c30b73a5cf5f46

query I rowsort
SELECT ALL - - 68 * + col0 FROM tab1 AS cor0
----
204
4352
5440

query I rowsort
SELECT cor0.col0 * - col1 + ( + 87 ) FROM tab0 AS cor0
----
-1977
-3308
-8012

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col0 col1 FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col0 ) + + 49 * col0 col0 FROM tab2 AS cor0
----
350
3900
3950

query I rowsort
SELECT - - col0 + + col2 * - col1 AS col1 FROM tab1 cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT + col2 + + col2 AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ( - col0 ) * + col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT ( col2 ) + + col0 * + 99 AS col1 FROM tab1
----
351
6393
8016

query I rowsort
SELECT + 27 AS col0 FROM tab1
----
27
27
27

query I rowsort
SELECT - + ( + 24 ) FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 797d0f7c145f8ac623924448c714bbcc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col0 ) * col2 + cor0.col1 col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT + ( col2 ) * col0 + 81 FROM tab2 AS cor0
----
2109
270
3083

query I rowsort
SELECT ALL + ( col2 ) + + cor0.col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT + - 54 + - 75 FROM tab0 AS cor0
----
-129
-129
-129

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + cor0.col1 * - col0 * - col2 col2 FROM tab2 AS cor0
----
119711
51051
5890

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 68 col2 FROM tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 AS cor2
----
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1691
SELECT CAST( NULL AS SIGNED ) + tab1.col1 FROM tab1, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1691
SELECT CAST ( NULL AS INTEGER ) + tab1.col1 FROM tab1, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1692
SELECT DISTINCT col2 + + col0 * - col0 + - col2 / - CAST( NULL AS SIGNED ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-1692
SELECT DISTINCT col2 + + col0 * - col0 + - col2 / - CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

query I rowsort
SELECT ALL col2 + col0 * - 75 FROM tab2
----
-498
-5824
-5887

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col2 ) * col0 col0 FROM tab0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col1 + + ( - tab2.col1 ) * tab2.col2 col1 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT ( col0 ) + - col1 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT 54 AS col1 FROM tab1 AS cor0
----
54
54
54

query I rowsort
SELECT DISTINCT 44 + col2 AS col1 FROM tab0 AS cor0
----
126
45
77

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 DISTINCT col1 * + 9 AS col1 FROM tab1
----
117
234
90

query I rowsort
SELECT DISTINCT + - cor0.col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1702
SELECT DISTINCT tab1.col1 + + col0 DIV - 94 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-1702
SELECT DISTINCT tab1.col1 + + col0 / - 94 FROM tab1
----
10
13
26

query I rowsort
SELECT + ( col0 ) * - 39 FROM tab0
----
-1365
-3471
-936

query I rowsort
SELECT DISTINCT ( col0 ) + col0 AS col2 FROM tab0
----
178
48
70

query I rowsort
SELECT + - 68 + + col2 AS col0 FROM tab2 AS cor0
----
-30
-41
-42

query I rowsort
SELECT - + col1 * col2 + - 80 FROM tab0 cor0
----
-177
-2918
-7542

query I rowsort
SELECT ALL 35 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

onlyif mysql # use DIV operator for integer division
query I rowsort label-1708
SELECT DISTINCT + col0 DIV - 23 AS col1 FROM tab0
----
-1
-3

skipif mysql # not compatible
query I rowsort label-1708
SELECT DISTINCT + col0 / - 23 AS col1 FROM tab0
----
-1
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col0 * 88 col0 FROM tab0
----
-3080
-642224
-69696

query I rowsort
SELECT col1 * - ( + col1 ) AS col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - + col1 * + col2 + + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT col1 + 8 - col0 * col2 FROM tab2 AS cor0
----
-150
-1961
-2977

query I rowsort
SELECT + ( + col1 ) + col1 AS col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT + 46 + 81 + + col1 FROM tab2 AS cor0
----
144
158
186

query I rowsort
SELECT + col0 * col2 + col0 AS col1 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT + col0 - + cor0.col2 AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + 57 + + col1 FROM tab0 AS cor0
----
143
148
154

query I rowsort
SELECT 5 * - col0 AS col0 FROM tab1 AS cor0
----
-15
-320
-400

query I rowsort
SELECT ALL - col0 + 49 AS col0 FROM tab2
----
-29
-30
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col2 + + CAST ( - 42 AS REAL ) * - tab0.col1 col0 FROM tab0
----
3645
3904
4075

query I rowsort
SELECT DISTINCT cor0.col2 * + 60 FROM tab2, tab1 AS cor0
----
3240
3420
5760

query I rowsort
SELECT + col1 + + cor0.col1 AS col1 FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT - + 45 + col0 AS col0 FROM tab0 AS cor0
----
-10
-21
44

query I rowsort
SELECT - col1 * - cor0.col1 + - col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT ALL col2 * col1 + col0 + - col2 AS col2 FROM tab0 AS cor0
----
131
2829
7469

query I rowsort
SELECT + col0 * + col0 + + col2 * col0 FROM tab1 cor0
----
14080
171
7744

query I rowsort
SELECT ALL - 53 * + tab0.col0 FROM tab0
----
-1272
-1855
-4717

query I rowsort
SELECT ALL cor0.col2 * cor0.col0 FROM tab0, tab0 AS cor0, tab2, tab2 AS cor1
----
81 values hashing to 0766594af6c38a1f4021dd93bcfb67c3

query I rowsort
SELECT ALL + col2 * 26 * + ( col1 ) + - 43 FROM tab0 AS cor0
----
193969
2479
73745

query I rowsort
SELECT DISTINCT - - col0 * col2 - - col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL - col0 + - col1 + col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + col1 + cor0.col0 AS col2 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1733
SELECT ( - col2 ) + - col2 * CAST( - col2 AS SIGNED ) * + col0 + col2 * col1 FROM tab1 cor0
----
10098
208449
738432

skipif mysql # not compatible
query I rowsort label-1733
SELECT ( - col2 ) + - col2 * CAST ( - col2 AS INTEGER ) * + col0 + col2 * col1 FROM tab1 cor0
----
10098
208449
738432

query I rowsort
SELECT cor0.col2 * ( - col1 ) + col0 + col0 FROM tab2 AS cor0
----
-1378
-488
-823

query I rowsort
SELECT DISTINCT + 35 AS col0 FROM tab1 AS cor0
----
35

query I rowsort
SELECT DISTINCT - tab2.col2 + 22 * col2 AS col0 FROM tab2
----
546
567
798

query I rowsort
SELECT + col1 * - 89 FROM tab1
----
-1157
-2314
-890

query I rowsort
SELECT ALL + col1 * + tab1.col1 + + tab1.col1 FROM tab1
----
110
182
702

query I rowsort
SELECT - tab0.col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT DISTINCT col0 + ( - tab0.col0 + col2 ) FROM tab0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1741
SELECT + CAST( - col0 AS SIGNED ) FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-1741
SELECT + CAST ( - col0 AS INTEGER ) FROM tab0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-1742
SELECT DISTINCT 74 + + col2 DIV + col2 AS col2 FROM tab0 AS cor0
----
75

skipif mysql # not compatible
query I rowsort label-1742
SELECT DISTINCT 74 + + col2 / + col2 AS col2 FROM tab0 AS cor0
----
75

query I rowsort
SELECT ALL + 13 * - col1 * 94 FROM tab2 AS cor0
----
-20774
-37882
-72098

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 11 + - col2 col0 FROM tab0 AS cor0
----
-12
-44
-93

query I rowsort
SELECT ALL + ( col1 ) - col2 * ( col1 ) FROM tab0 cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT + col0 * col0 + + 49 + + col1 FROM tab2 AS cor0
----
129
6192
6307

query I rowsort
SELECT DISTINCT - ( - col1 ) * col0 + col2 * cor0.col0 AS col1 FROM tab2 AS cor0
----
406
4345
6630

query I rowsort
SELECT tab2.col2 + 20 FROM tab2
----
46
47
58

query I rowsort
SELECT DISTINCT - 53 * 12 FROM tab0
----
-636

query I rowsort
SELECT DISTINCT + col2 - + col1 * ( col1 + col0 ) AS col2 FROM tab1
----
-1113
-683
-700

query I rowsort
SELECT + - ( - col2 ) * - col2 + + col1 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT + cor0.col1 * - col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + 17 AS col0 FROM tab2 AS cor0
----
17

query I rowsort
SELECT DISTINCT - tab0.col1 AS col1 FROM tab0, tab2 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1755
SELECT ALL + CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-1755
SELECT ALL + CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + + cor0.col1 * + ( - col0 ) - col2 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT DISTINCT col0 * - col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col2 + 35 FROM tab2 cor0
----
-3
8
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1759
SELECT ALL col1 DIV + 78 AS col1 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1759
SELECT ALL col1 / + 78 AS col1 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1760
SELECT + CAST( NULL AS DECIMAL ) + cor0.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1760
SELECT + CAST ( NULL AS REAL ) + cor0.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL + + col0 * 54 FROM tab2 AS cor0
----
378
4212
4266

onlyif mysql # use DIV operator for integer division
query I rowsort label-1762
SELECT + cor0.col0 DIV col0 col2 FROM tab2 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1762
SELECT + cor0.col0 / col0 col2 FROM tab2 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1763
SELECT + - col2 + + cor0.col2 DIV 28 FROM tab1 cor0
----
-53
-55
-93

skipif mysql # not compatible
query I rowsort label-1763
SELECT + - col2 + + cor0.col2 / 28 FROM tab1 cor0
----
-53
-55
-93

query I rowsort
SELECT + col2 * col1 + col0 * - cor0.col0 FROM tab0 AS cor0
----
-1128
-459
2262

onlyif mysql # use DIV operator for integer division
query I rowsort label-1765
SELECT ALL col2 + + 83 * col1 DIV col1 AS col2 FROM tab2 AS cor0
----
109
110
121

skipif mysql # not compatible
query I rowsort label-1765
SELECT ALL col2 + + 83 * col1 / col1 AS col2 FROM tab2 AS cor0
----
109
110
121

query I rowsort
SELECT DISTINCT + - col2 * + cor0.col2 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT + 78 + - 80 AS col2 FROM tab0
----
-2
-2
-2

query I rowsort
SELECT 11 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

query I rowsort
SELECT + 19 FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
81 values hashing to 39241ace4c29d5a55052e1665aa36823

onlyif mysql # use DIV operator for integer division
query I rowsort label-1770
SELECT ALL + cor0.col2 DIV col1 AS col1 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-1770
SELECT ALL + cor0.col2 / col1 AS col1 FROM tab2 AS cor0
----
0
0
2

query I rowsort
SELECT 50 + ( - col0 ) AS col0 FROM tab1 AS cor0
----
-14
-30
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1772
SELECT DISTINCT CAST( NULL AS SIGNED ) + - 58 * + col1 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1772
SELECT DISTINCT CAST ( NULL AS INTEGER ) + - 58 * + col1 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 19 * 17 + - col2 * ( 31 ) FROM tab2 AS cor0
----
-483
-514
-855

query I rowsort
SELECT ALL - cor0.col2 - - cor0.col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL col1 + col0 * col0 AS col0 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT ALL + + col2 - ( cor0.col0 ) FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-1777
SELECT DISTINCT ( col1 ) DIV + col1 AS col0 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-1777
SELECT DISTINCT ( col1 ) / + col1 AS col0 FROM tab1 AS cor0
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1778
SELECT DISTINCT + col1 + ( - col1 ) * CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1778
SELECT DISTINCT + col1 + ( - col1 ) * CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL ( col1 ) * + cor0.col1 + - ( col1 + - col2 ) FROM tab0 AS cor0
----
7343
8272
9313

query I rowsort
SELECT DISTINCT - 70 + 65 AS col1 FROM tab1 AS cor0
----
-5

query I rowsort
SELECT DISTINCT + + col2 + 68 * + col0 FROM tab1 AS cor0
----
258
4409
5536

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col0 + - col0 col2 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT ALL 21 * + col0 AS col1 FROM tab1 AS cor0
----
1344
1680
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 55 * - col1 col1 FROM tab2 cor0
----
1705
3245
935

onlyif mysql # use DIV operator for integer division
query I rowsort label-1785
SELECT - - cor0.col0 + - cor0.col0 DIV - col1 col1 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1785
SELECT - - cor0.col0 + - cor0.col0 / - col1 col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + - 26 + col2 FROM tab2 AS cor0
----
0
1
12

query I rowsort
SELECT DISTINCT + ( + col2 ) * - col0 * 42 FROM tab2 AS cor0
----
-126084
-7938
-85176

query I rowsort
SELECT - col1 + col2 * col0 * + col1 FROM tab1 AS cor0
----
36470
4186
99827

onlyif mysql # use DIV operator for integer division
query I rowsort label-1789
SELECT col0 DIV + col0 col1 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1789
SELECT col0 / + col0 col1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT - 81 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d0bfe8494f52235d9fcafb5ac5de3f81

query I rowsort
SELECT DISTINCT - - 92 * - col0 AS col2 FROM tab1 AS cor0
----
-276
-5888
-7360

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( col2 ) + col0 col0 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1793
SELECT + CAST( NULL AS DECIMAL ) * + col0 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1793
SELECT + CAST ( NULL AS REAL ) * + col0 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + 7 FROM tab2, tab1, tab1 cor0
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

query I rowsort
SELECT ALL - col2 * + col2 AS col0 FROM tab0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col1 ) * tab2.col2 + col0 * col1 col2 FROM tab2
----
-620
3068
697

query I rowsort
SELECT DISTINCT + ( - col0 ) * col2 AS col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL 48 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT DISTINCT 50 AS col2 FROM tab2, tab2 AS cor0
----
50

query I rowsort
SELECT DISTINCT 65 * - col1 AS col0 FROM tab2 AS cor0
----
-1105
-2015
-3835

onlyif mysql # use DIV operator for integer division
query I rowsort label-1801
SELECT + col0 DIV col0 + col1 * col2 FROM tab1 AS cor0
----
1249
1405
571

skipif mysql # not compatible
query I rowsort label-1801
SELECT + col0 / col0 + col1 * col2 FROM tab1 AS cor0
----
1249
1405
571

query I rowsort
SELECT + col2 * col0 + + col0 AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT + 64 AS col2 FROM tab1
----
64
64
64

query I rowsort
SELECT cor0.col1 + - cor0.col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + 71 * col0 AS col2 FROM tab0 AS cor0
----
1704
2485
6319

onlyif mysql # use DIV operator for integer division
query I rowsort label-1806
SELECT + cor0.col1 + - col2 * col1 + + cor0.col0 DIV - col1 FROM tab0 cor0
----
-2752
-7371
0

skipif mysql # not compatible
query I rowsort label-1806
SELECT + cor0.col1 + - col2 * col1 + + cor0.col0 / - col1 FROM tab0 cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT - col0 * col1 + - cor0.col1 * col1 FROM tab2 AS cor0
----
-1178
-1632
-8083

onlyif mysql # use DIV operator for integer division
query I rowsort label-1808
SELECT cor0.col1 DIV 28 FROM tab2 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-1808
SELECT cor0.col1 / 28 FROM tab2 AS cor0
----
0
1
2

query I rowsort
SELECT - 86 FROM tab1, tab0 AS cor0
----
9 values hashing to 9ac806793c03d3a6b5e3a3029d20e4da

query I rowsort
SELECT + col0 + ( cor0.col2 ) AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT 14 + cor0.col2 FROM tab0 cor0
----
15
47
96

query I rowsort
SELECT + col0 * + col0 + cor0.col1 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT + 11 + col2 FROM tab2 AS cor0
----
37
38
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-1814
SELECT + col0 DIV - 73 AS col2 FROM tab2
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-1814
SELECT + col0 / - 73 AS col2 FROM tab2
----
-1
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1815
SELECT - col2 + - CAST( NULL AS SIGNED ) + 87 / + col1 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1815
SELECT - col2 + - CAST ( NULL AS INTEGER ) + 87 / + col1 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ( - cor0.col1 ) AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + col1 + cor0.col1 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT - - cor0.col0 * + col0 + col1 AS col0 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT + + col2 * + ( - col2 ) - col1 FROM tab1 AS cor0
----
-2942
-3259
-9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-1820
SELECT - 73 DIV + 2 AS col1 FROM tab1 AS cor0
----
-36
-36
-36

skipif mysql # not compatible
query I rowsort label-1820
SELECT - 73 / + 2 AS col1 FROM tab1 AS cor0
----
-36
-36
-36

onlyif mysql # use DIV operator for integer division
query I rowsort label-1821
SELECT + col2 DIV + 31 FROM tab2 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1821
SELECT + col2 / + 31 FROM tab2 AS cor0
----
0
0
1

query I rowsort
SELECT - + 64 + + 41 FROM tab2 AS cor0
----
-23
-23
-23

query I rowsort
SELECT ALL - 58 * col1 * - col0 AS col0 FROM tab1 AS cor0
----
37120
4524
60320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 64 col2 FROM tab2 AS cor0
----
64
64
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-1825
SELECT ALL + - ( + col0 ) DIV + col1 - - col2 col1 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1825
SELECT ALL + - ( + col0 ) / + col1 - - col2 col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + col0 + col0 * col1 AS col0 FROM tab2 cor0
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-1827
SELECT ALL + col0 DIV + 85 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1827
SELECT ALL + col0 / + 85 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL + - col1 * + col2 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-1829
SELECT DISTINCT - col1 DIV col1 AS col0 FROM tab2 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-1829
SELECT DISTINCT - col1 / col1 AS col0 FROM tab2 AS cor0
----
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1830
SELECT ALL + col1 * + cor0.col1 + - CAST( col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
210
3403
954

skipif mysql # not compatible
query I rowsort label-1830
SELECT ALL + col1 * + cor0.col1 + - CAST ( col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
210
3403
954

query I rowsort
SELECT DISTINCT ( ( - col1 ) ) * + 62 - ( col0 ) FROM tab0
----
-5356
-5731
-6049

query I rowsort
SELECT tab1.col1 * col1 * col2 - 41 FROM tab1
----
16183
36463
5659

query I rowsort
SELECT - + col0 * col1 AS col2 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + cor0.col1 * + 10 FROM tab2, tab2 AS cor0
----
170
310
590

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1835
SELECT - col0 * + CAST( col1 AS SIGNED ) + cor0.col1 AS col0 FROM tab1 AS cor0
----
-1027
-52
-630

skipif mysql # not compatible
query I rowsort label-1835
SELECT - col0 * + CAST ( col1 AS INTEGER ) + cor0.col1 AS col0 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT ALL tab2.col2 * tab2.col1 AS col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT 78 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

query I rowsort
SELECT - col0 - - col2 AS col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT + col0 * 7 - - tab0.col0 AS col1 FROM tab0
----
192
280
712

query I rowsort
SELECT ALL + cor0.col2 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT - 27 + - col1 AS col1 FROM tab1
----
-37
-40
-53

query I rowsort
SELECT ALL + col1 * + col2 + col1 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-1843
SELECT + + col2 DIV col0 AS col2 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-1843
SELECT + + col2 / col0 AS col2 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT DISTINCT + 28 * col2 + col0 FROM tab0 cor0
----
2385
63
948

query I rowsort
SELECT DISTINCT - 68 + col1 FROM tab2 AS cor0
----
-37
-51
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 67 * + col1 col1 FROM tab2 AS cor0
----
1139
2077
3953

query I rowsort
SELECT ALL + cor0.col0 * - col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - col1 * - col2 + cor0.col0 * - 88 + + col1 AS col0 FROM tab0 AS cor0
----
-279
-2886
812

query I rowsort
SELECT DISTINCT - + cor0.col0 * col0 FROM tab1 AS cor0
----
-4096
-6400
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 89 * cor0.col2 col0 FROM tab1 AS cor0
----
-4806
-5073
-8544

onlyif mysql # use DIV operator for integer division
query I rowsort label-1851
SELECT ALL - col2 + + col1 * 62 DIV col1 FROM tab2 AS cor0
----
24
35
36

skipif mysql # not compatible
query I rowsort label-1851
SELECT ALL - col2 + + col1 * 62 / col1 FROM tab2 AS cor0
----
24
35
36

query I rowsort
SELECT DISTINCT - - col1 * ( col0 ) AS col0 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - cor0.col1 col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col2 * ( col2 ) + col2 * + col2 * - 77 FROM tab0 AS cor0
----
-524472
-78
-84942

query I rowsort
SELECT DISTINCT + col2 * - 89 AS col2 FROM tab0 AS cor0
----
-2937
-7298
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col0 col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - 71 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

query I rowsort
SELECT ALL - col0 * + ( 97 + col2 ) FROM tab0 AS cor0
----
-15931
-3120
-3430

query I rowsort
SELECT 18 FROM tab2, tab2 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT ALL cor0.col1 * - col1 + + col2 AS col0 FROM tab2 AS cor0
----
-251
-3455
-934

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 26 + col0 * col2 col2 FROM tab0
----
61
7324
818

query I rowsort
SELECT col2 + + 23 FROM tab1 AS cor0
----
119
77
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 54 * - col0 + + col2 col2 FROM tab2 AS cor0
----
-351
-4186
-4228

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1864
SELECT ALL + CAST( NULL AS SIGNED ) + col2 * cor0.col2 * ( col1 + + col2 ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1864
SELECT ALL + CAST ( NULL AS INTEGER ) + col2 * cor0.col2 * ( col1 + + col2 ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 51 + col0 AS col0 FROM tab0 AS cor0
----
140
75
86

query I rowsort
SELECT - ( 3 ) FROM tab1 AS cor0
----
-3
-3
-3

query I rowsort
SELECT + 5 * + col1 + col0 FROM tab1 AS cor0
----
114
133
145

query I rowsort
SELECT + - cor0.col0 * + col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT + 3 FROM tab2 cor0
----
3
3
3

query I rowsort
SELECT ALL - 71 * col0 FROM tab1 AS cor0
----
-213
-4544
-5680

query I rowsort
SELECT 94 + ( + tab0.col2 ) AS col0 FROM tab0
----
127
176
95

query I rowsort
SELECT - 74 AS col0 FROM tab0
----
-74
-74
-74

query I rowsort
SELECT + 29 - col2 AS col1 FROM tab2
----
-9
2
3

query I rowsort
SELECT + ( - 61 + - col0 ) AS col2 FROM tab0
----
-150
-85
-96

query I rowsort
SELECT DISTINCT 62 * col2 AS col0 FROM tab1
----
3348
3534
5952

query I rowsort
SELECT col1 + - 46 FROM tab2
----
-15
-29
13

query I rowsort
SELECT DISTINCT + - 12 * - col1 + ( + col0 + col2 ) AS col0 FROM tab0 AS cor0
----
1089
1200
1263

query I rowsort
SELECT + cor0.col2 * + col2 + 89 FROM tab1 AS cor0
----
3005
3338
9305

query I rowsort
SELECT 10 * col0 FROM tab1 cor0
----
30
640
800

query I rowsort
SELECT DISTINCT 61 * col0 - col1 * + col1 FROM tab2 AS cor0
----
-534
1277
4530

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0, tab2 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to b803f2d602a28da5cf35ddc7c7fa2eeb

query I rowsort
SELECT DISTINCT + + col0 + + col0 FROM tab1 AS cor0
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-1883
SELECT ALL + col0 * col1 DIV - col2 AS col1 FROM tab1
----
-1
-10
-11

skipif mysql # not compatible
query I rowsort label-1883
SELECT ALL + col0 * col1 / - col2 AS col1 FROM tab1
----
-1
-10
-11

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 cor0, tab1 cor1, tab2 AS cor2
----
972 values hashing to 72eb3d4d523f5d0c69d1b855edd18f4a

query I rowsort
SELECT ALL - 39 + cor0.col0 AS col0 FROM tab1 cor0
----
-36
25
41

query I rowsort
SELECT ALL 10 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

onlyif mysql # use DIV operator for integer division
query I rowsort label-1887
SELECT ALL col1 DIV - col1 + tab0.col2 * col0 AS col2 FROM tab0
----
34
7297
791

skipif mysql # not compatible
query I rowsort label-1887
SELECT ALL col1 / - col1 + tab0.col2 * col0 AS col2 FROM tab0
----
34
7297
791

query I rowsort
SELECT DISTINCT ( col1 ) + + col1 * 89 FROM tab1 cor0
----
1170
2340
900

query I rowsort
SELECT col1 + 77 FROM tab2 AS cor0
----
108
136
94

query I rowsort
SELECT ALL + + 69 FROM tab1 AS cor0
----
69
69
69

query I rowsort
SELECT DISTINCT col1 + col1 * - 88 AS col2 FROM tab2
----
-1479
-2697
-5133

query I rowsort
SELECT - tab2.col0 + + tab2.col1 FROM tab2
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-1893
SELECT + tab0.col0 DIV col2 + + col1 FROM tab0
----
132
86
92

skipif mysql # not compatible
query I rowsort label-1893
SELECT + tab0.col0 / col2 + + col1 FROM tab0
----
132
86
92

query I rowsort
SELECT DISTINCT - ( - col0 ) AS col1 FROM tab2
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 11 - 72 col1 FROM tab0 AS cor0
----
-83
-83
-83

query I rowsort
SELECT 87 FROM tab1, tab0 AS cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

onlyif mysql # use DIV operator for integer division
query I rowsort label-1897
SELECT col1 DIV cor0.col1 + + col2 * + 7 FROM tab1 AS cor0
----
379
400
673

skipif mysql # not compatible
query I rowsort label-1897
SELECT col1 / cor0.col1 + + col2 * + 7 FROM tab1 AS cor0
----
379
400
673

query I rowsort
SELECT ALL + ( col2 ) AS col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT cor0.col1 + col0 * - col2 AS col2 FROM tab0 cor0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT + + col1 + - col2 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + col2 + - cor0.col1 * + col1 AS col2 FROM tab1 cor0
----
-43
-622
-73

query I rowsort
SELECT + + 57 + col1 FROM tab0 AS cor0
----
143
148
154

query I rowsort
SELECT + 94 * col2 + col2 FROM tab1 AS cor0
----
5130
5415
9120

query I rowsort
SELECT DISTINCT - + col2 * - col0 + + col2 AS col1 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT - col1 * col1 * col1 AS col2 FROM tab0 AS cor0
----
-636056
-753571
-912673

query I rowsort
SELECT ALL - - ( 34 ) - + col2 AS col0 FROM tab0 AS cor0
----
-48
1
33

skipif mysql # not compatible
query I rowsort
SELECT ALL - + ( - 41 ) + col1 * - CAST ( col1 AS REAL ) FROM tab2 AS cor0
----
-248
-3440
-920

query I rowsort
SELECT DISTINCT + - 21 + col0 FROM tab0 AS cor0
----
14
3
68

query I rowsort
SELECT + 93 + - 39 FROM tab1 AS cor0
----
54
54
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-1910
SELECT DISTINCT + col2 + - 66 DIV + col2 FROM tab1 AS cor0
----
53
56
96

skipif mysql # not compatible
query I rowsort label-1910
SELECT DISTINCT + col2 + - 66 / + col2 FROM tab1 AS cor0
----
53
56
96

query I rowsort
SELECT + ( + 18 ) * col1 AS col1 FROM tab0 AS cor0
----
1548
1638
1746

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1912
SELECT DISTINCT - ( col2 ) + + CAST( NULL AS SIGNED ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-1912
SELECT DISTINCT - ( col2 ) + + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1913
SELECT + col0 DIV - ( cor0.col1 ) - col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-1913
SELECT + col0 / - ( cor0.col1 ) - col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - col1 + ( col1 ) AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1915
SELECT col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1915
SELECT col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 * - col1 AS col1 FROM tab2
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-1917
SELECT + 6 DIV + col1 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1917
SELECT + 6 / + col1 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT - cor0.col2 + - 9 - - 85 AS col1 FROM tab2 AS cor0
----
38
49
50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1919
SELECT + + col1 * col1 * ( col0 ) + CAST( col0 + col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
177552
329385
737187

skipif mysql # not compatible
query I rowsort label-1919
SELECT + + col1 * col1 * ( col0 ) + CAST ( col0 + col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
177552
329385
737187

onlyif mysql # use DIV operator for integer division
query I rowsort label-1920
SELECT ALL - col1 - + cor0.col1 DIV - 29 FROM tab1 cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-1920
SELECT ALL - col1 - + cor0.col1 / - 29 FROM tab1 cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * + 69 + 97 col1 FROM tab2 cor0
----
-386
-5285
-5354

query I rowsort
SELECT + - cor0.col2 * col2 + + col1 * - col0 - col0 * - col1 AS col2 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-1923
SELECT - col0 DIV col2 + 90 col1 FROM tab0 AS cor0
----
55
89
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1923
SELECT - col0 / col2 + 90 col1 FROM tab0 AS cor0
----
55
89
90

query I rowsort
SELECT ALL cor0.col1 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT - col2 * cor0.col2 * cor0.col2 AS col0 FROM tab0 AS cor0
----
-1
-35937
-551368

query I rowsort
SELECT DISTINCT ( - col0 ) * - col0 + col2 AS col0 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT ALL col0 * + 38 FROM tab2 AS cor0
----
266
2964
3002

query I rowsort
SELECT ALL + + 71 * col2 + + col1 FROM tab0 AS cor0
----
168
2429
5913

query I rowsort
SELECT DISTINCT - 41 * 37 + col0 FROM tab1 cor0
----
-1437
-1453
-1514

query I rowsort
SELECT ALL + - 88 * 23 AS col1 FROM tab2 AS cor0
----
-2024
-2024
-2024

query I rowsort
SELECT DISTINCT - - ( col0 ) + col1 AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - + col2 * + 48 FROM tab0 AS cor0
----
-1584
-3936
-48

query I rowsort
SELECT ALL - - ( 76 ) FROM tab1 AS cor0
----
76
76
76

query I rowsort
SELECT + + 25 * - col2 FROM tab2 AS cor0
----
-650
-675
-950

onlyif mysql # use DIV operator for integer division
query I rowsort label-1935
SELECT + - 69 + col0 DIV cor0.col1 FROM tab1 AS cor0
----
-63
-63
-69

skipif mysql # not compatible
query I rowsort label-1935
SELECT + - 69 + col0 / cor0.col1 FROM tab1 AS cor0
----
-63
-63
-69

query I rowsort
SELECT + 75 * cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to def3e3462a30391d0f5badf02970f402

query I rowsort
SELECT tab0.col1 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT - 2 FROM tab2 cor0
----
-2
-2
-2

query I rowsort
SELECT ALL col1 + 42 * cor0.col0 FROM tab0 AS cor0
----
1094
1567
3829

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * ( + col2 ) col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + cor0.col2 * 50 AS col0 FROM tab0 AS cor0
----
1650
4100
50

query I rowsort
SELECT + col2 * + cor0.col1 + col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT + 92 + + 10 AS col1 FROM tab0 AS cor0
----
102
102
102

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1944
SELECT - - CAST( NULL AS DECIMAL ) * - 76 + + col2 * ( - ( col0 ) ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1944
SELECT - - CAST ( NULL AS REAL ) * - 76 + + col2 * ( - ( col0 ) ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + - cor0.col2 AS col2 FROM tab1 cor0
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-1946
SELECT ALL - cor0.col1 - - col1 * ( + col2 ) DIV col1 AS col0 FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-1946
SELECT ALL - cor0.col1 - - col1 * ( + col2 ) / col1 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT - 18 FROM tab2, tab0 AS cor0
----
-18

query I rowsort
SELECT ALL tab1.col0 * 66 + + col0 FROM tab1
----
201
4288
5360

query I rowsort
SELECT ALL + 42 FROM tab2
----
42
42
42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1950
SELECT ALL + CAST( + col0 + + col0 AS SIGNED ) AS col1 FROM tab2
----
14
156
158

skipif mysql # not compatible
query I rowsort label-1950
SELECT ALL + CAST ( + col0 + + col0 AS INTEGER ) AS col1 FROM tab2
----
14
156
158

query I rowsort
SELECT 31 * + col0 AS col2 FROM tab1
----
1984
2480
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 38 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to e571541ae40cb0ddaca16e11f4359507

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 40 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT - ( 77 ) + + col1 AS col0 FROM tab0 AS cor0
----
14
20
9

query I rowsort
SELECT + col0 * + col2 + + 86 FROM tab0
----
121
7384
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-1956
SELECT DISTINCT col1 DIV tab1.col1 AS col2 FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-1956
SELECT DISTINCT col1 / tab1.col1 AS col2 FROM tab1
----
1

query I rowsort
SELECT + - col0 + - 8 FROM tab0 AS cor0
----
-32
-43
-97

query I rowsort
SELECT ALL - col1 * ( + tab0.col2 * col1 ) AS col0 FROM tab0
----
-244068
-679042
-9409

query I rowsort
SELECT DISTINCT + col0 * 30 FROM tab1
----
1920
2400
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-1960
SELECT col2 DIV tab0.col0 + col1 AS col0 FROM tab0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-1960
SELECT col2 / tab0.col0 + col1 AS col0 FROM tab0
----
87
91
97

query I rowsort
SELECT ( ( + col2 ) * col0 ) FROM tab2
----
189
2028
3002

query I rowsort
SELECT DISTINCT - col1 - + col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL + 8 AS col2 FROM tab0
----
8
8
8

query I rowsort
SELECT DISTINCT - ( - col1 ) AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - + 64 + - col1 * cor0.col0 * col0 AS col0 FROM tab2 AS cor0
----
-106161
-1583
-359020

query I rowsort
SELECT + 23 * - col1 FROM tab1 AS cor0
----
-230
-299
-598

query I rowsort
SELECT DISTINCT + cor0.col0 - col1 AS col0 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT + 3 + col2 * col1 * - ( cor0.col1 ) FROM tab1 AS cor0
----
-16221
-36501
-5697

query I rowsort
SELECT DISTINCT + ( col0 ) * + col2 AS col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-1970
SELECT ALL col1 * col2 DIV + col0 FROM tab2 AS cor0
----
119
19
8

skipif mysql # not compatible
query I rowsort label-1970
SELECT ALL col1 * col2 / + col0 FROM tab2 AS cor0
----
119
19
8

query I rowsort
SELECT 66 * + col2 AS col2 FROM tab0 AS cor0
----
2178
5412
66

query I rowsort
SELECT DISTINCT - tab1.col2 + - col1 * + col1 * - col0 AS col0 FROM tab1
----
13424
1974
6343

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1973
SELECT DISTINCT - 34 * col1 + CAST( col1 AS SIGNED ) * + col0 + - col0 * + col1 * + tab1.col2 FROM tab1
----
-36180
-5018
-99242

skipif mysql # not compatible
query I rowsort label-1973
SELECT DISTINCT - 34 * col1 + CAST ( col1 AS INTEGER ) * + col0 + - col0 * + col1 * + tab1.col2 FROM tab1
----
-36180
-5018
-99242

query I rowsort
SELECT - 99 + col2 * ( ( + col2 ) ) + - col0 AS col2 FROM tab2
----
1266
499
623

query I rowsort
SELECT DISTINCT tab1.col1 AS col1 FROM tab1, tab0 AS cor0
----
10
13
26

query I rowsort
SELECT + col2 * - col0 + 96 + ( - col0 + col0 ) * 11 FROM tab2 AS cor0
----
-1932
-2906
-93

query I rowsort
SELECT - - 10 + col2 * col0 FROM tab0 AS cor0
----
45
7308
802

query I rowsort
SELECT DISTINCT - + col2 + 22 FROM tab2 AS cor0
----
-16
-4
-5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1979
SELECT DISTINCT - + col1 * CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-1979
SELECT DISTINCT - + col1 * CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - col0 + - 60 AS col0 FROM tab2 AS cor0
----
-138
-139
-67

query I rowsort
SELECT cor0.col0 * col2 + col1 + + col0 FROM tab0 AS cor0
----
167
7478
902

query I rowsort
SELECT ALL + - cor0.col1 - - cor0.col0 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT + col0 + + ( ( col2 ) ) FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-1984
SELECT ALL - + col1 * 9 DIV - 44 FROM tab1 cor0
----
2
2
5

skipif mysql # not compatible
query I rowsort label-1984
SELECT ALL - + col1 * 9 / - 44 FROM tab1 cor0
----
2
2
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-1985
SELECT - cor0.col2 DIV - 33 FROM tab0, tab2 AS cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

skipif mysql # not compatible
query I rowsort label-1985
SELECT - cor0.col2 / - 33 FROM tab0, tab2 AS cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col0 + 53 * - col2 col0 FROM tab0 AS cor0
----
-1758
-19
-4339

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col1 col0 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT ALL col1 + ( col1 ) * col0 * - col2 AS col2 FROM tab1 AS cor0
----
-36470
-4186
-99827

query I rowsort
SELECT + col1 + col0 * - 84 FROM tab1 AS cor0
----
-226
-5366
-6707

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1990
SELECT cor0.col0 * - CAST( NULL AS DECIMAL ) + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1990
SELECT cor0.col0 * - CAST ( NULL AS REAL ) + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * + col0 + 23 FROM tab0 AS cor0
----
58
7321
815

query I rowsort
SELECT ALL + + col0 * col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT + col2 + - cor0.col0 + col1 AS col0 FROM tab1 AS cor0
----
29
3
77

query I rowsort
SELECT 73 + cor0.col0 AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to e675d8fc91595e7018a4f39b620fca86

query I rowsort
SELECT DISTINCT + col2 + cor0.col1 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-1996
SELECT + ( 96 ) DIV col0 FROM tab2 AS cor0
----
1
1
13

skipif mysql # not compatible
query I rowsort label-1996
SELECT + ( 96 ) / col0 FROM tab2 AS cor0
----
1
1
13

query I rowsort
SELECT - col2 * 37 AS col0 FROM tab2
----
-1406
-962
-999

query I rowsort
SELECT ALL col0 + col1 + - col1 AS col2 FROM tab2
----
7
78
79

query I rowsort
SELECT - 87 FROM tab2 cor0
----
-87
-87
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-2000
SELECT ALL 85 + col0 DIV - cor0.col2 AS col2 FROM tab0 AS cor0
----
50
84
85

skipif mysql # not compatible
query I rowsort label-2000
SELECT ALL 85 + col0 / - cor0.col2 AS col2 FROM tab0 AS cor0
----
50
84
85

query I rowsort
SELECT - 55 FROM tab2 AS cor0
----
-55
-55
-55

query I rowsort
SELECT tab0.col1 * 68 * col0 FROM tab0
----
140352
230860
550732

onlyif mysql # use DIV operator for integer division
query I rowsort label-2003
SELECT + col1 + col0 DIV 69 FROM tab2
----
18
31
60

skipif mysql # not compatible
query I rowsort label-2003
SELECT + col1 + col0 / 69 FROM tab2
----
18
31
60

query I rowsort
SELECT col0 * - col1 + col1 * col2 FROM tab1 AS cor0
----
-70
1326
208

query I rowsort
SELECT DISTINCT + 1 + col2 FROM tab0 AS cor0
----
2
34
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col1 col2 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT ALL - col1 * col1 + col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT ALL 74 * col2 * + col0 + - col2 * - col0 AS col1 FROM tab1 AS cor0
----
12150
273600
576000

query I rowsort
SELECT + + 95 AS col0 FROM tab0 AS cor0
----
95
95
95

query I rowsort
SELECT ALL - + col2 + col2 * - 85 FROM tab0 AS cor0
----
-2838
-7052
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * cor0.col1 col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT 15 + col1 FROM tab1 AS cor0
----
25
28
41

query I rowsort
SELECT DISTINCT 36 * + cor0.col2 AS col2 FROM tab0 cor0
----
1188
2952
36

query I rowsort
SELECT DISTINCT ( col0 ) * - col0 + 29 FROM tab2 cor0
----
-20
-6055
-6212

query I rowsort
SELECT ALL + col2 + col2 * - col1 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT + + col1 + - col2 * - col2 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT ALL - ( col0 ) * 43 FROM tab1 AS cor0
----
-129
-2752
-3440

onlyif mysql # use DIV operator for integer division
query I rowsort label-2018
SELECT DISTINCT + col1 DIV col0 AS col0 FROM tab1 cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-2018
SELECT DISTINCT + col1 / col0 AS col0 FROM tab1 cor0
----
0
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2019
SELECT CAST( NULL AS DECIMAL ) - - col0 * col2 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2019
SELECT CAST ( NULL AS REAL ) - - col0 * col2 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 18 FROM tab1
----
18
18
18

query I rowsort
SELECT ALL - 52 AS col1 FROM tab1
----
-52
-52
-52

query I rowsort
SELECT DISTINCT - 28 AS col0 FROM tab2
----
-28

query I rowsort
SELECT + col2 + col0 + ( + col2 ) * col2 FROM tab1
----
2973
3370
9392

query I rowsort
SELECT ALL 54 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT DISTINCT + 38 * - col0 + + 9 + col2 * + col2 AS col0 FROM tab1 AS cor0
----
2811
6185
826

onlyif mysql # use DIV operator for integer division
query I rowsort label-2026
SELECT ALL + - cor0.col2 - col0 DIV 12 AS col1 FROM tab1 cor0
----
-102
-54
-62

skipif mysql # not compatible
query I rowsort label-2026
SELECT ALL + - cor0.col2 - col0 / 12 AS col1 FROM tab1 cor0
----
-102
-54
-62

query I rowsort
SELECT + - 82 + - col0 AS col0 FROM tab0 AS cor0
----
-106
-117
-171

onlyif mysql # use DIV operator for integer division
query I rowsort label-2028
SELECT + col0 + - cor0.col2 DIV - CAST( + col1 AS SIGNED ) FROM tab1 AS cor0
----
5
69
87

skipif mysql # not compatible
query I rowsort label-2028
SELECT + col0 + - cor0.col2 / - CAST ( + col1 AS INTEGER ) FROM tab1 AS cor0
----
5
69
87

query I rowsort
SELECT + 11 * col0 + cor0.col0 AS col1 FROM tab1 AS cor0
----
36
768
960

query I rowsort
SELECT DISTINCT col1 + col1 + - col0 * col0 AS col1 FROM tab2 AS cor0
----
-5966
-6207
13

query I rowsort
SELECT ALL - cor0.col0 * col1 - col1 AS col0 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT cor0.col2 * - col2 + 95 * - col0 AS col0 FROM tab0 AS cor0
----
-15179
-3326
-3369

query I rowsort
SELECT + 27 AS col1 FROM tab0 AS cor0
----
27
27
27

query I rowsort
SELECT - 42 * - col0 + - tab0.col2 AS col0 FROM tab0
----
1469
3656
975

query I rowsort
SELECT + - col0 + col2 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - 1 FROM tab2, tab2 AS cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2037
SELECT + + tab0.col1 DIV 24 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to ce898d2808cdffab0ba202253268d952

skipif mysql # not compatible
query I rowsort label-2037
SELECT + + tab0.col1 / 24 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to ce898d2808cdffab0ba202253268d952

query I rowsort
SELECT cor0.col2 + - col1 * 93 FROM tab0 AS cor0
----
-7965
-8381
-9020

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2039
SELECT + col1 * col0 + + CAST( NULL AS SIGNED ) * 27 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2039
SELECT + col1 * col0 + + CAST ( NULL AS INTEGER ) * 27 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 0 col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT col2 * - col2 + 5 AS col0 FROM tab2 AS cor0
----
-1439
-671
-724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2042
SELECT - col2 + CAST( NULL AS SIGNED ) * + col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2042
SELECT - col2 + CAST ( NULL AS INTEGER ) * + col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2043
SELECT + - col0 + + col1 DIV - col2 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-2043
SELECT + - col0 + + col1 / - col2 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT col2 + cor0.col0 AS col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT col2 * - 52 * - col2 FROM tab2 AS cor0
----
35152
37908
75088

query I rowsort
SELECT 11 AS col2 FROM tab1
----
11
11
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 20 col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to eb3a66728062963cccbd15bd2f5c9eee

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2048
SELECT ALL + col1 + CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
55
58
85

skipif mysql # not compatible
query I rowsort label-2048
SELECT ALL + col1 + CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT - col0 * col0 + - 54 FROM tab2 cor0
----
-103
-6138
-6295

query I rowsort
SELECT + col1 * - col1 + col1 AS col2 FROM tab1 AS cor0
----
-156
-650
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 * 10 col0 FROM tab0 cor0
----
-240
-350
-890

query I rowsort
SELECT ALL + - col1 * col2 * + col2 AS col0 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT ALL - + col1 * ( col1 ) FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT - 66 AS col1 FROM tab0 cor0
----
-66

query I rowsort
SELECT ALL col1 + cor0.col1 * col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT ALL col1 + - col0 * - col1 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-2057
SELECT - col1 - + col1 DIV ( col2 ) FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-2057
SELECT - col1 - + col1 / ( col2 ) FROM tab1
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-2058
SELECT tab1.col1 DIV - col2 + tab1.col1 + + col1 AS col0 FROM tab1
----
20
26
52

skipif mysql # not compatible
query I rowsort label-2058
SELECT tab1.col1 / - col2 + tab1.col1 + + col1 AS col0 FROM tab1
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2059
SELECT + CAST( NULL AS SIGNED ) + cor0.col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2059
SELECT + CAST ( NULL AS INTEGER ) + cor0.col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 + - col2 * - col1 AS col2 FROM tab1 AS cor0
----
1168
1401
506

onlyif mysql # use DIV operator for integer division
query I rowsort label-2061
SELECT ALL + cor0.col1 DIV 78 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2061
SELECT ALL + cor0.col1 / 78 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2062
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + col0 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2062
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + col0 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col2 * col1 + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - 51 ) col0 FROM tab2 cor0
----
-51
-51
-51

query I rowsort
SELECT - col2 + - col2 - + 0 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT + 49 * col0 AS col1 FROM tab1 AS cor0
----
147
3136
3920

query I rowsort
SELECT cor0.col1 * - col0 * + 89 + - ( col1 ) - - ( col1 ) FROM tab0 AS cor0
----
-183696
-302155
-720811

query I rowsort
SELECT - - col2 - col1 FROM tab2 AS cor0
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-2069
SELECT + + col2 + cor0.col2 DIV + col0 AS col2 FROM tab2 AS cor0
----
26
30
38

skipif mysql # not compatible
query I rowsort label-2069
SELECT + + col2 + cor0.col2 / + col0 AS col2 FROM tab2 AS cor0
----
26
30
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-2070
SELECT - col0 DIV col2 + + cor0.col2 FROM tab1 AS cor0
----
54
56
96

skipif mysql # not compatible
query I rowsort label-2070
SELECT - col0 / col2 + + cor0.col2 FROM tab1 AS cor0
----
54
56
96

query I rowsort
SELECT - + col1 + + col2 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT col0 + + col1 * col1 AS col2 FROM tab1 AS cor0
----
164
249
679

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2073
SELECT - col2 + - CAST( NULL AS SIGNED ) col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2073
SELECT - col2 + - CAST ( NULL AS INTEGER ) col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col1 * - 30 + col2 FROM tab0 AS cor0
----
-2547
-2648
-2909

onlyif mysql # use DIV operator for integer division
query I rowsort label-2075
SELECT - col0 * - col2 + - cor0.col0 DIV - cor0.col0 FROM tab0 AS cor0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-2075
SELECT - col0 * - col2 + - cor0.col0 / - cor0.col0 FROM tab0 AS cor0
----
36
7299
793

query I rowsort
SELECT DISTINCT + + ( col1 ) * 99 AS col2 FROM tab0 AS cor0
----
8514
9009
9603

onlyif mysql # use DIV operator for integer division
query I rowsort label-2077
SELECT ALL + col2 * + col0 + cor0.col1 DIV + ( col0 * + col1 ) + cor0.col2 FROM tab1 AS cor0
----
216
3705
7776

skipif mysql # not compatible
query I rowsort label-2077
SELECT ALL + col2 * + col0 + cor0.col1 / + ( col0 * + col1 ) + cor0.col2 FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-2078
SELECT ALL + 60 + col2 * ( + col2 ) * col2 + 12 DIV - col1 FROM tab1 cor0
----
157524
185252
884796

skipif mysql # not compatible
query I rowsort label-2078
SELECT ALL + 60 + col2 * ( + col2 ) * col2 + 12 / - col1 FROM tab1 cor0
----
157524
185252
884796

query I rowsort
SELECT ALL + 19 * col0 + col1 + col0 FROM tab2 AS cor0
----
1597
1619
171

query I rowsort
SELECT ALL - col0 + - col2 * 56 AS col2 FROM tab1 AS cor0
----
-3027
-3256
-5456

query I rowsort
SELECT ALL - col1 - col1 AS col2 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT - - 3 AS col0 FROM tab2 AS cor0
----
3
3
3

query I rowsort
SELECT - + 35 FROM tab2 cor0
----
-35
-35
-35

query I rowsort
SELECT ALL + - col0 * - cor0.col0 + ( col1 ) * col1 AS col0 FROM tab2 AS cor0
----
1010
6530
9565

query I rowsort
SELECT DISTINCT - - col0 + + col2 * - 93 FROM tab2 AS cor0
----
-2340
-2504
-3455

onlyif mysql # use DIV operator for integer division
query I rowsort label-2086
SELECT DISTINCT + col1 * col1 DIV - cor0.col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-2086
SELECT DISTINCT + col1 * col1 / - cor0.col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - 69 * + col1 FROM tab2 AS cor0
----
-1173
-2139
-4071

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 - col0 col2 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT cor0.col1 * tab0.col1 AS col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 5ea193ba73427313aa6d66d856b32bc7

query I rowsort
SELECT ALL + 78 + tab1.col2 AS col0 FROM tab1
----
132
135
174

query I rowsort
SELECT + cor0.col2 AS col1 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

onlyif mysql # use DIV operator for integer division
query I rowsort label-2092
SELECT col1 + - col0 DIV + col0 AS col0 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-2092
SELECT col1 + - col0 / + col0 AS col0 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT ALL + - col1 * col0 + - col2 * col2 FROM tab2 AS cor0
----
-2787
-5278
-946

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2094
SELECT DISTINCT + col1 + col0 + + CAST( + col0 AS SIGNED ) col2 FROM tab0 AS cor0
----
134
167
269

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2094
SELECT DISTINCT + col1 + col0 + + CAST ( + col0 AS INTEGER ) col2 FROM tab0 AS cor0
----
134
167
269

query I rowsort
SELECT ALL 99 * col1 * col2 + col2 FROM tab0
----
280995
738820
9604

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2096
SELECT ALL + CAST( NULL AS SIGNED ) + + 63 * + cor0.col1 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2096
SELECT ALL + CAST ( NULL AS INTEGER ) + + 63 * + cor0.col1 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT cor1.col0 + + cor0.col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
106
13
16
29
74
77
90
93

query I rowsort
SELECT DISTINCT + - 37 * + col0 + ( + 2 ) AS col1 FROM tab2 AS cor0
----
-257
-2884
-2921

query I rowsort
SELECT + col1 * - 8 + cor0.col1 FROM tab0 AS cor0
----
-602
-637
-679

query I rowsort
SELECT ALL - 4 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

query I rowsort
SELECT DISTINCT ( - col0 ) + col1 FROM tab0
----
2
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2102
SELECT ALL - 56 * col1 * - col0 + CAST( NULL AS DECIMAL ) / tab0.col0 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2102
SELECT ALL - 56 * col1 * - col0 + CAST ( NULL AS REAL ) / tab0.col0 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 + 31 FROM tab1
----
127
85
88

query I rowsort
SELECT 40 AS col2 FROM tab2
----
40
40
40

query I rowsort
SELECT ALL + 42 * ( col0 ) + + 41 AS col0 FROM tab0
----
1049
1511
3779

query I rowsort
SELECT ALL - + 70 AS col1 FROM tab1 AS cor0
----
-70
-70
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - col1 + col0 col1 FROM tab1 AS cor0
----
-49
44
54

query I rowsort
SELECT 95 + cor0.col1 FROM tab2 AS cor0
----
112
126
154

query I rowsort
SELECT DISTINCT + + col1 + + col2 + col2 FROM tab2 AS cor0
----
111
85
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-2110
SELECT DISTINCT + col2 + - col0 DIV - col2 FROM tab1 AS cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-2110
SELECT DISTINCT + col2 + - col0 / - col2 FROM tab1 AS cor0
----
54
58
96

query I rowsort
SELECT ( cor0.col0 ) * col2 * - 77 + - 24 AS col1 FROM tab2 AS cor0
----
-14577
-156180
-231178

query I rowsort
SELECT ALL + 89 * - col0 FROM tab1 AS cor0
----
-267
-5696
-7120

query I rowsort
SELECT ALL + col2 + col2 * - col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT 22 * col1 FROM tab1
----
220
286
572

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + cor0.col0 - col2 * - col1 col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - + col2 + 50 - + col0 * + col1 AS col2 FROM tab0 AS cor0
----
-2047
-3346
-8131

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2117
SELECT DISTINCT - + CAST( NULL AS SIGNED ) / + 75 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2117
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) / + 75 AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - cor0.col1 + 73 FROM tab1 AS cor0
----
47
60
63

query I rowsort
SELECT - col0 + + col1 * col2 AS col1 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT ALL - - 7 AS col1 FROM tab0 AS cor0
----
7
7
7

query I rowsort
SELECT DISTINCT - col0 * 48 FROM tab2 AS cor0
----
-336
-3744
-3792

query I rowsort
SELECT DISTINCT cor0.col1 + + cor0.col1 * col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT + col0 + - col0 * - cor0.col2 * - col0 FROM tab1 AS cor0
----
-233408
-483
-614320

query I rowsort
SELECT DISTINCT 94 * col0 + + col2 FROM tab1 AS cor0
----
336
6073
7616

query I rowsort
SELECT ( - col2 ) + col2 * 8 AS col0 FROM tab2 AS cor0
----
182
189
266

query I rowsort
SELECT ALL col2 * col0 * - ( col1 ) FROM tab2
----
-119652
-51034
-5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-2127
SELECT cor0.col0 * col2 + col0 * col1 - col2 DIV + col0 FROM tab2 AS cor0
----
403
4345
6630

skipif mysql # not compatible
query I rowsort label-2127
SELECT cor0.col0 * col2 + col0 * col1 - col2 / + col0 FROM tab2 AS cor0
----
403
4345
6630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + ( 41 ) col2 FROM tab1 AS cor0
----
105
121
44

query I rowsort
SELECT - 30 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 56fa25f9fb8040460fe3c894000ea8fb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 96 col0 FROM tab1, tab1 cor0
----
-96

query I rowsort
SELECT - col1 + - col0 * tab2.col0 * - col0 AS col2 FROM tab2
----
312
474493
493022

query I rowsort
SELECT DISTINCT + cor0.col0 * + cor0.col0 + col1 * col0 FROM tab1 AS cor0
----
4736
7440
87

query I rowsort
SELECT ALL - col0 + + col0 * - col1 AS col0 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT cor0.col0 * - 7 FROM tab0 AS cor0
----
-168
-245
-623

query I rowsort
SELECT DISTINCT - 15 AS col1 FROM tab0, tab0 cor0, tab2 AS cor1
----
-15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2136
SELECT - col1 * CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2136
SELECT - col1 * CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - 71 + + 11 * - col2 FROM tab0 cor0
----
-434
-82
-973

query I rowsort
SELECT + ( + col1 ) * + col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - ( - 11 ) + col2 FROM tab1 AS cor0
----
107
65
68

query I rowsort
SELECT ALL + col0 * col0 + - col0 FROM tab0 AS cor0
----
1190
552
7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-2141
SELECT ALL + - col0 DIV - col1 AS col0 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2141
SELECT ALL + - col0 / - col1 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT col2 * 80 + - col0 AS col2 FROM tab1
----
4317
4496
7600

query I rowsort
SELECT tab0.col2 * + 75 + - col2 AS col0 FROM tab0
----
2442
6068
74

query I rowsort
SELECT - 24 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 797d0f7c145f8ac623924448c714bbcc

query I rowsort
SELECT ALL col1 * 7 * - 55 FROM tab1
----
-10010
-3850
-5005

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + ( 41 ) * col2 col1 FROM tab1
----
2240
2347
3949

query I rowsort
SELECT col1 + + col0 * + col1 AS col0 FROM tab1
----
104
1053
650

query I rowsort
SELECT ALL - col0 + col1 * + col0 * col0 FROM tab2
----
106018
1512
358878

query I rowsort
SELECT + col1 - - tab2.col2 AS col1 FROM tab2
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col1 * - col1 col2 FROM tab0 WHERE NOT NULL <> - col2 * col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2151
SELECT DISTINCT col1 + col1 DIV + tab2.col1 FROM tab2
----
18
32
60

skipif mysql # not compatible
query I rowsort label-2151
SELECT DISTINCT col1 + col1 / + tab2.col1 FROM tab2
----
18
32
60

query I rowsort
SELECT cor0.col1 + col0 * col2 + - col0 * - col2 AS col1 FROM tab0 cor0
----
14687
167
1670

query I rowsort
SELECT + tab0.col2 * - col2 FROM tab0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col0 + col2 * col1 * tab0.col1 col2 FROM tab0
----
244178
679222
9541

query III rowsort
SELECT ALL * FROM tab1 WHERE ( NULL ) IN ( col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2156
SELECT ALL col1 DIV + col2 AS col0 FROM tab0 WHERE + col1 NOT BETWEEN + col0 * col0 * col2 + col0 + - col2 AND - col1 * col0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-2156
SELECT ALL col1 / + col2 AS col0 FROM tab0 WHERE + col1 NOT BETWEEN + col0 * col0 * col2 + col0 + - col2 AND - col1 * col0
----
1
2
97

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL >= col0 / + col2
----

query I rowsort
SELECT ALL - col0 - col0 AS col1 FROM tab1 WHERE ( NULL ) IN ( tab1.col0 * col2 )
----

query I rowsort
SELECT DISTINCT + tab1.col2 - + col1 * col1 AS col2 FROM tab1
----
-43
-622
-73

query I rowsort
SELECT ALL - col0 * + col0 + - col2 FROM tab0
----
-1226
-609
-8003

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT ( NULL ) NOT IN ( col0 * - col0 + - col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2162
SELECT + col2 * tab1.col1 + - col2 DIV col1 - - col2 * + col2 FROM tab1
----
10457
3814
4318

skipif mysql # not compatible
query I rowsort label-2162
SELECT + col2 * tab1.col1 + - col2 / col1 - - col2 * + col2 FROM tab1
----
10457
3814
4318

query I rowsort
SELECT DISTINCT col2 FROM tab1 WHERE NOT ( NULL ) <> col1
----

query I rowsort
SELECT + col0 + - col1 * col2 AS col1 FROM tab0 WHERE NULL IN ( col0 )
----

query I rowsort
SELECT tab1.col2 * + col0 FROM tab1
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col2 col2 FROM tab0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 + - col1 col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + tab0.col0 col2 FROM tab0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-2169
SELECT - tab1.col0 + - tab1.col2 DIV col2 + - tab1.col1 FROM tab1
----
-30
-75
-94

skipif mysql # not compatible
query I rowsort label-2169
SELECT - tab1.col0 + - tab1.col2 / col2 + - tab1.col1 FROM tab1
----
-30
-75
-94

query I rowsort
SELECT DISTINCT col2 AS col1 FROM tab2 WHERE col0 IN ( col0 )
----
26
27
38

query I rowsort
SELECT + tab0.col1 AS col1 FROM tab0 WHERE NOT + col1 * col2 NOT BETWEEN NULL AND tab0.col0 + + col1
----

query I rowsort
SELECT + - col2 + col2 * cor0.col1 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT + + col0 * - col1 - col2 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT ALL - col2 + - col1 + col0 * col0 AS col2 FROM tab2 AS cor0
----
-9
5999
6186

query I rowsort
SELECT ALL + col2 + col0 * cor0.col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL col0 + col2 * - col1 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT + col2 + + col0 * + col1 FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-2178
SELECT - col1 DIV + col0 + + col0 + col1 FROM tab2 AS cor0
----
137
34
96

skipif mysql # not compatible
query I rowsort label-2178
SELECT - col1 / + col0 + + col0 + col1 FROM tab2 AS cor0
----
137
34
96

query I rowsort
SELECT ALL col1 * + col0 + col1 AS col1 FROM tab1
----
104
1053
650

query I rowsort
SELECT ALL tab1.col2 + col0 AS col2 FROM tab1
----
121
176
57

query I rowsort
SELECT col1 * cor0.col2 - col2 AS col1 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT + col0 * - cor0.col0 + col2 FROM tab2 cor0
----
-22
-6058
-6203

query III rowsort
SELECT * FROM tab2 WHERE ( NULL ) > - col0
----

query III rowsort
SELECT * FROM tab2 WHERE ( NULL ) > col2
----

query III rowsort
SELECT * FROM tab1 WHERE NOT - col0 * + col0 <> + col2
----

query I rowsort
SELECT ALL - col1 * col2 + ( col1 ) AS col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT col1 + - ( col2 * - col1 ) FROM tab1 cor0
----
1261
1430
580

onlyif mysql # use DIV operator for integer division
query I rowsort label-2188
SELECT ALL + + col2 DIV + 40 + cor0.col2 FROM tab1 AS cor0
----
55
58
98

skipif mysql # not compatible
query I rowsort label-2188
SELECT ALL + + col2 / + 40 + cor0.col2 FROM tab1 AS cor0
----
55
58
98

query I rowsort
SELECT ALL + + col1 + 11 AS col2 FROM tab0 AS cor0
----
102
108
97

query I rowsort
SELECT + - col2 * - col0 + + 12 AS col0 FROM tab1 AS cor0
----
174
3660
7692

query I rowsort
SELECT + - col2 - cor0.col1 FROM tab2 AS cor0
----
-55
-58
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 + + 64 * - col2 col2 FROM tab1 AS cor0
----
-3459
-3712
-6224

query I rowsort
SELECT DISTINCT - - col1 + 46 * - col1 AS col0 FROM tab0 AS cor0
----
-3870
-4095
-4365

query I rowsort
SELECT 87 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - tab1.col1 * 48 col0 FROM tab1
----
-27360
-59904
-67392

onlyif mysql # use DIV operator for integer division
query I rowsort label-2196
SELECT col2 * col0 DIV tab1.col0 AS col0 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2196
SELECT col2 * col0 / tab1.col0 AS col0 FROM tab1
----
54
57
96

query I rowsort
SELECT - col0 + + ( - col2 ) * col2 FROM tab2
----
-1523
-736
-754

query I rowsort
SELECT DISTINCT + 81 * 96 - tab1.col1 FROM tab1, tab0 AS cor0
----
7750
7763
7766

query III rowsort
SELECT * FROM tab0 WHERE + col0 * - col0 NOT BETWEEN NULL AND col0
----

query I rowsort
SELECT - col1 + + col0 * col1 * + col2 FROM tab1
----
36470
4186
99827

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col2 col1 FROM tab2
----
104
117
34

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL NOT IN ( col1 * - col2 * tab0.col2 - + col2 * col2 )
----

query III rowsort
SELECT ALL * FROM tab2 WHERE + col1 * col2 BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL col1 - - tab1.col1 FROM tab1
----
20
26
52

query I rowsort
SELECT + 69 FROM tab0 cor0
----
69
69
69

query I rowsort
SELECT ALL col2 * col0 * ( + 77 ) + col2 * + 13 - + 97 FROM tab1
----
13079
281540
592511

query I rowsort
SELECT ALL col2 * col1 - - col0 FROM tab1
----
1328
1407
634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col2 col0 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2209
SELECT ALL col2 * + cor0.col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2209
SELECT ALL col2 * + cor0.col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 - ( ( + col0 ) + col1 * + col2 ) FROM tab0 AS cor0
----
-131
-2829
-7469

query I rowsort
SELECT DISTINCT + col0 * - 51 AS col0 FROM tab2 AS cor0
----
-357
-3978
-4029

query I rowsort
SELECT + cor0.col2 - col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 + + col2 * + col0 FROM tab2 AS cor0
----
2054
216
3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2214
SELECT + + col0 + CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2214
SELECT + + col0 + CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col1 * ( + col1 ) AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT col1 + 10 FROM tab1
----
20
23
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-2217
SELECT - col1 + - col0 DIV + 76 col1 FROM tab2 AS cor0
----
-18
-31
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2217
SELECT - col1 + - col0 / + 76 col1 FROM tab2 AS cor0
----
-18
-31
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * + col1 + col2 col0 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT - col2 * ( - col2 ) - + col2 * - cor0.col1 AS col2 FROM tab2 cor0
----
1566
2090
2210

query I rowsort
SELECT ALL + col2 + + 12 * - 51 AS col2 FROM tab0 cor0
----
-530
-579
-611

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2221
SELECT DISTINCT + col0 + CAST( + col0 AS SIGNED ) FROM tab1 AS cor0
----
128
160
6

skipif mysql # not compatible
query I rowsort label-2221
SELECT DISTINCT + col0 + CAST ( + col0 AS INTEGER ) FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL + col0 * - col1 + col0 * col0 FROM tab2 AS cor0
----
-168
1482
4898

query I rowsort
SELECT DISTINCT - col1 + + ( 53 ) AS col0 FROM tab0 AS cor0
----
-33
-38
-44

query I rowsort
SELECT + col2 * - 41 + 17 * col2 AS col1 FROM tab2 AS cor0
----
-624
-648
-912

query I rowsort
SELECT ALL + col2 + - 48 FROM tab2 AS cor0
----
-10
-21
-22

query I rowsort
SELECT DISTINCT - cor0.col0 * ( col2 ) * + col1 AS col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL col0 * + col2 * - col2 + col0 * col0 AS col1 FROM tab0 AS cor0
----
-25560
-590515
1190

query I rowsort
SELECT ALL + cor0.col2 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT cor0.col1 + + 43 FROM tab1 AS cor0
----
53
56
69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2230
SELECT DISTINCT - col2 + CAST( NULL AS SIGNED ) / ( + col0 ) + col2 * - col0 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-2230
SELECT DISTINCT - col2 + CAST ( NULL AS INTEGER ) / ( + col0 ) + col2 * - col0 FROM tab2
----
NULL

query I rowsort
SELECT - col0 + 56 FROM tab0 AS cor0
----
-33
21
32

query I rowsort
SELECT ALL 56 * + cor0.col0 FROM tab2 AS cor0
----
392
4368
4424

query I rowsort
SELECT + 42 + - 59 AS col2 FROM tab1 AS cor0
----
-17
-17
-17

query I rowsort
SELECT + - 28 + 16 FROM tab2 cor0
----
-12
-12
-12

query I rowsort
SELECT DISTINCT - + col1 * - col1 + col0 FROM tab0 cor0
----
7420
8370
9444

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0 WHERE NOT NULL < ( NULL )
----

query I rowsort
SELECT + col1 - - 21 AS col0 FROM tab1
----
31
34
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + ( 95 ) - + col2 col2 FROM tab2
----
1577
2918
5579

query I rowsort
SELECT DISTINCT col1 + + 59 FROM tab2
----
118
76
90

query I rowsort
SELECT DISTINCT + col1 * + cor0.col0 - col2 * + ( - cor0.col1 ) AS col1 FROM tab1 AS cor0
----
1210
1482
2288

query I rowsort
SELECT ALL + 34 * col2 AS col0 FROM tab2 AS cor0
----
1292
884
918

query I rowsort
SELECT + col0 + - cor0.col0 * 55 AS col0 FROM tab1 AS cor0
----
-162
-3456
-4320

onlyif mysql # use DIV operator for integer division
query I rowsort label-2243
SELECT - - col1 DIV cor0.col2 AS col0 FROM tab0 cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-2243
SELECT - - col1 / cor0.col2 AS col0 FROM tab0 cor0
----
1
2
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2244
SELECT ALL + CAST( col0 + col2 AS SIGNED ) AS col0 FROM tab2
----
104
117
34

skipif mysql # not compatible
query I rowsort label-2244
SELECT ALL + CAST ( col0 + col2 AS INTEGER ) AS col0 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL tab2.col1 + + col2 - tab2.col0 AS col0 FROM tab2
----
-24
51
7

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2, tab0 cor0, tab1
----
972 values hashing to 82e15d5967b272804e574774895a0222

query I rowsort
SELECT ALL + - col1 * - cor0.col2 + 93 FROM tab2 AS cor0
----
1627
739
930

query I rowsort
SELECT - 14 * - col2 + 45 * 56 + col0 FROM tab0
----
2569
3006
3757

query I rowsort
SELECT - 87 * + col1 FROM tab1 AS cor0
----
-1131
-2262
-870

query I rowsort
SELECT + - col1 * col1 * col2 AS col0 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT DISTINCT col1 FROM tab2 WHERE ( ( col0 ) NOT BETWEEN NULL AND NULL ) AND tab2.col1 + - col2 IN ( tab2.col0 * col0 + + col1 )
----

query I rowsort
SELECT DISTINCT 19 * tab2.col2 FROM tab2
----
494
513
722

query I rowsort
SELECT DISTINCT 78 * col1 AS col0 FROM tab0
----
6708
7098
7566

query I rowsort
SELECT tab2.col1 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL col0 * col0 * col0 + col0 AS col0 FROM tab2
----
350
474630
493118

query I rowsort
SELECT DISTINCT - col2 + + tab0.col1 FROM tab0
----
53
9
96

query I rowsort
SELECT - col1 + + tab1.col0 * + col2 + col0 AS col0 FROM tab1
----
139
3702
7747

query I rowsort
SELECT DISTINCT col1 + - col0 + col1 FROM tab0 AS cor0
----
148
159
93

query I rowsort
SELECT ALL + + col1 * cor0.col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT + col0 + - col0 * col2 * + col1 FROM tab1 AS cor0
----
-36416
-4209
-99760

query I rowsort
SELECT ALL - - col0 * col2 * + col0 AS col2 FROM tab2 AS cor0
----
1323
158184
237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-2262
SELECT - col1 * - col2 - cor0.col1 DIV - cor0.col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-2262
SELECT - col1 * - col2 - cor0.col1 / - cor0.col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - col1 * col1 - cor0.col2 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT - col0 * + col0 * - col0 AS col0 FROM tab1 AS cor0
----
262144
27
512000

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2265
SELECT CAST( col2 AS SIGNED ) * + col1 + col1 * tab0.col1 FROM tab0
----
10234
15743
9506

skipif mysql # not compatible
query I rowsort label-2265
SELECT CAST ( col2 AS INTEGER ) * + col1 + col1 * tab0.col1 FROM tab0
----
10234
15743
9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 82 col0 FROM tab1
----
82
82
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + col0 col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT - col0 * + 43 FROM tab2
----
-301
-3354
-3397

query I rowsort
SELECT + col2 - tab0.col2 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2270
SELECT - CAST( NULL AS SIGNED ) * + col0 + + col2 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2270
SELECT - CAST ( NULL AS INTEGER ) * + col0 + + col2 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + + col1 * tab1.col1 * col2 FROM tab1
----
16237
36530
5710

query I rowsort
SELECT 50 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

onlyif mysql # use DIV operator for integer division
query I rowsort label-2273
SELECT DISTINCT - ( + tab1.col2 ) DIV - tab1.col0 AS col1 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-2273
SELECT DISTINCT - ( + tab1.col2 ) / - tab1.col0 AS col1 FROM tab1
----
0
1
18

query I rowsort
SELECT DISTINCT + 55 AS col1 FROM tab2
----
55

query I rowsort
SELECT DISTINCT col0 * + 39 * tab0.col1 AS col0 FROM tab0
----
132405
315861
80496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 * col2 col2 FROM tab1 AS cor0
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col1 * col0 col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT - + col2 * - col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT ALL + - 97 + cor0.col2 AS col1 FROM tab1 AS cor0
----
-1
-40
-43

onlyif mysql # use DIV operator for integer division
query I rowsort label-2280
SELECT ALL - col1 DIV col2 + - col0 * + col0 * + col2 FROM tab0 AS cor0
----
-1322
-19010
-649523

skipif mysql # not compatible
query I rowsort label-2280
SELECT ALL - col1 / col2 + - col0 * + col0 * + col2 FROM tab0 AS cor0
----
-1322
-19010
-649523

query I rowsort
SELECT DISTINCT + col2 * - col0 - col1 * col0 * - col0 AS col0 FROM tab1 AS cor0
----
37312
72
75520

query I rowsort
SELECT - + ( col2 ) + col0 AS col2 FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2283
SELECT ALL - 56 + cor0.col0 DIV cor0.col0 AS col1 FROM tab1 AS cor0
----
-55
-55
-55

skipif mysql # not compatible
query I rowsort label-2283
SELECT ALL - 56 + cor0.col0 / cor0.col0 AS col1 FROM tab1 AS cor0
----
-55
-55
-55

query I rowsort
SELECT DISTINCT + 69 FROM tab1 cor0
----
69

query I rowsort
SELECT + col2 + col2 * col1 AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL tab2.col1 + tab2.col0 FROM tab2
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2287
SELECT DISTINCT 87 DIV - col1 + col0 + tab2.col1 FROM tab2
----
136
36
91

skipif mysql # not compatible
query I rowsort label-2287
SELECT DISTINCT 87 / - col1 + col0 + tab2.col1 FROM tab2
----
136
36
91

query I rowsort
SELECT DISTINCT + 57 AS col1 FROM tab2, tab1 cor0
----
57

query I rowsort
SELECT ALL - cor0.col2 + col0 * col2 AS col0 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT DISTINCT - 84 AS col0 FROM tab0 AS cor0
----
-84

query I rowsort
SELECT - + cor0.col0 * - col1 * cor0.col2 AS col0 FROM tab0 cor0
----
3395
664118
68112

query I rowsort
SELECT ALL ( col2 ) + cor0.col1 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT - 26 FROM tab2, tab2 cor0
----
9 values hashing to 47d0574274146de273829785364ada39

query I rowsort
SELECT + col2 * tab2.col2 AS col0 FROM tab2
----
1444
676
729

query I rowsort
SELECT DISTINCT 44 AS col1 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
44

query I rowsort
SELECT ALL 14 * col2 * + 91 + + 26 FROM tab1
----
122330
68822
72644

query I rowsort
SELECT 34 * cor0.col0 + col1 * + 18 FROM tab0 AS cor0
----
2364
2936
4664

query I rowsort
SELECT + + 32 + cor0.col1 AS col1 FROM tab2 AS cor0
----
49
63
91

query I rowsort
SELECT + col1 * - 18 AS col2 FROM tab1
----
-180
-234
-468

query I rowsort
SELECT + cor1.col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2301
SELECT - col2 + - CAST( col0 AS DECIMAL ) * tab0.col1 + CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2301
SELECT - col2 + - CAST ( col0 AS REAL ) * tab0.col1 + CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - 77 + + cor0.col0 * + col2 - col2 * col2 col2 FROM tab0 AS cor0
----
-2838
-43
-5740

query I rowsort
SELECT + - 91 + col0 AS col1 FROM tab1 AS cor0
----
-11
-27
-88

query I rowsort
SELECT + col1 * + col1 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT - + col2 + cor0.col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + + 37 FROM tab1 cor0
----
37
37
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-2307
SELECT - col2 DIV col0 col2 FROM tab0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2307
SELECT - col2 / col0 col2 FROM tab0
----
-1
0
0

query I rowsort
SELECT ALL - col0 * col1 + ( col1 * 62 ) AS col1 FROM tab2
----
-289
-944
1705

query I rowsort
SELECT - - cor0.col2 * col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + col0 + - 94 AS col0 FROM tab2 AS cor0
----
-15
-16
-87

query I rowsort
SELECT ALL 79 FROM tab2, tab1 AS cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT col1 * - 34 * + col0 FROM tab1 AS cor0
----
-21760
-2652
-35360

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-2314
SELECT ALL - ( col2 ) DIV col0 - col2 * ( col2 ) FROM tab1
----
-2934
-3249
-9217

skipif mysql # not compatible
query I rowsort label-2314
SELECT ALL - ( col2 ) / col0 - col2 * ( col2 ) FROM tab1
----
-2934
-3249
-9217

onlyif mysql # use DIV operator for integer division
query I rowsort label-2315
SELECT ALL cor0.col1 DIV + 10 FROM tab1, tab1 AS cor0, tab2 cor1
----
27 values hashing to df9f0ac5e607decc6626359024d41263

skipif mysql # not compatible
query I rowsort label-2315
SELECT ALL cor0.col1 / + 10 FROM tab1, tab1 AS cor0, tab2 cor1
----
27 values hashing to df9f0ac5e607decc6626359024d41263

query I rowsort
SELECT DISTINCT - - 99 AS col2 FROM tab0 cor0
----
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-2317
SELECT DISTINCT - 22 DIV col1 FROM tab1 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-2317
SELECT DISTINCT - 22 / col1 FROM tab1 AS cor0
----
-1
-2
0

query I rowsort
SELECT ALL col1 * col0 + + 32 AS col1 FROM tab2 cor0
----
1375
249
4634

query I rowsort
SELECT ALL + cor0.col0 * col2 + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ALL 84 * col2 AS col0 FROM tab2 AS cor0
----
2184
2268
3192

query I rowsort
SELECT - - 64 * col2 * - ( cor0.col2 ) + + cor0.col1 * - col2 FROM tab1 cor0
----
-188028
-208506
-591072

query I rowsort
SELECT ALL col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 28 * col0 col1 FROM tab1 AS cor0
----
1792
2240
84

query I rowsort
SELECT ALL + cor0.col1 + cor0.col2 * col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL + - 45 * + col0 FROM tab1 AS cor0
----
-135
-2880
-3600

query I rowsort
SELECT - 3 + + col2 FROM tab1 cor0
----
51
54
93

query I rowsort
SELECT DISTINCT + 17 AS col1 FROM tab0 AS cor0
----
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2328
SELECT ALL - + cor0.col2 + col1 * + col1 * ( col2 ) + + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2328
SELECT ALL - + cor0.col2 + col1 * + col1 * ( col2 ) + + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col2 + col0 * ( col2 + cor0.col1 ) AS col2 FROM tab2 AS cor0
----
379
4307
6604

query I rowsort
SELECT 77 + tab2.col2 - col1 AS col1 FROM tab2
----
44
73
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2331
SELECT DISTINCT - col0 * - col0 * + col1 + - col2 - + col1 DIV col1 FROM tab0
----
118823
49502
720728

skipif mysql # not compatible
query I rowsort label-2331
SELECT DISTINCT - col0 * - col0 * + col1 + - col2 - + col1 / col1 FROM tab0
----
118823
49502
720728

query I rowsort
SELECT ALL - 21 * + ( col2 ) * 84 + col1 - - col2 AS col0 FROM tab0
----
-144475
-1666
-58093

query I rowsort
SELECT col2 * + 96 + - col2 AS col2 FROM tab2
----
2470
2565
3610

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 66 * + col2 col2 FROM tab1
----
3564
3762
6336

query I rowsort
SELECT ALL + col0 - 90 AS col2 FROM tab1
----
-10
-26
-87

query I rowsort
SELECT + col2 + ( - ( + cor0.col1 ) ) AS col0 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT ALL + col2 * + 57 AS col2 FROM tab2 AS cor0
----
1482
1539
2166

query I rowsort
SELECT DISTINCT + + col1 * 40 FROM tab1 AS cor0
----
1040
400
520

query I rowsort
SELECT DISTINCT cor0.col1 * + col1 + ( + col2 ) AS col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT col2 * - cor0.col1 AS col2 FROM tab0 cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2341
SELECT - col0 DIV + 42 FROM tab2 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-2341
SELECT - col0 / + 42 FROM tab2 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL col2 * 98 + + col0 * col2 FROM tab0 AS cor0
----
133
15334
4026

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * + 52 col0 FROM tab2 cor0
----
-1352
-1404
-1976

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2344
SELECT col0 * + CAST( NULL AS SIGNED ) + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2344
SELECT col0 * + CAST ( NULL AS INTEGER ) + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * + col0 * + col2 + cor0.col2 AS col1 FROM tab0 AS cor0
----
-3394
-664036
-68079

query I rowsort
SELECT DISTINCT - - col1 * ( + cor0.col0 * - col0 ) FROM tab0 cor0
----
-118825
-49536
-720811

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 65 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + + col0 * cor0.col0 col1 FROM tab0 cor0
----
1190
552
7832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 53 col0 FROM tab0
----
53
53
53

query I rowsort
SELECT + 2 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

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 + - cor0.col1 FROM tab0, tab1, tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT col1 * 62 + - col0 * - col1 AS col1 FROM tab0
----
13741
7396
9409

query I rowsort
SELECT - col1 - col2 * col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT - col1 + + ( col1 ) * - col0 AS col2 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT col1 * - col1 * + col2 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT ALL col0 + col2 * 4 * + col2 + + 90 * cor0.col2 AS col1 FROM tab2 AS cor0
----
5122
5353
9275

query I rowsort
SELECT DISTINCT - col0 + 10 FROM tab2 AS cor0
----
-68
-69
3

query I rowsort
SELECT ALL + + col1 * cor0.col2 * - col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT DISTINCT - + col1 - - col1 * col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT - col1 * - ( - col1 ) + col2 FROM tab2 AS cor0
----
-251
-3455
-934

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab2, tab1 AS cor1
----
3645 values hashing to d8caf2ef7d9c405db0aec8c013a5107c

query I rowsort
SELECT DISTINCT col1 * 15 FROM tab2
----
255
465
885

query I rowsort
SELECT ALL 4 AS col1 FROM tab1 AS cor0
----
4
4
4

query I rowsort
SELECT + col0 + - 79 + col2 * + col0 AS col2 FROM tab0 AS cor0
----
-9
7308
737

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( cor0.col0 ) col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - + 79 * col1 AS col2 FROM tab1 cor0
----
-1027
-2054
-790

query I rowsort
SELECT ALL - + col0 * - col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT 91 * col1 AS col2 FROM tab2 AS cor0
----
1547
2821
5369

query I rowsort
SELECT ALL - col2 * 43 * col2 + col2 + col1 FROM tab1 AS cor0
----
-125308
-139640
-396179

query I rowsort
SELECT + 9 + + ( + cor0.col0 ) * col1 AS col2 FROM tab1 cor0
----
1049
649
87

query I rowsort
SELECT ALL - - cor0.col1 + col1 AS col2 FROM tab0 AS cor0
----
172
182
194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2373
SELECT + - 54 * - col2 + - col2 + + CAST( ( cor0.col0 ) AS SIGNED ) * - col2 FROM tab0 AS cor0
----
-2952
18
957

skipif mysql # not compatible
query I rowsort label-2373
SELECT + - 54 * - col2 + - col2 + + CAST ( ( cor0.col0 ) AS INTEGER ) * - col2 FROM tab0 AS cor0
----
-2952
18
957

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2374
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + 81 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2374
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + 81 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + - col2 * ( - cor0.col2 ) AS col0 FROM tab2 cor0
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-2376
SELECT DISTINCT - col1 DIV ( + col0 + 76 ) AS col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2376
SELECT DISTINCT - col1 / ( + col0 + 76 ) AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT col2 + cor0.col1 * + 76 AS col1 FROM tab0 AS cor0
----
6569
6998
7373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2378
SELECT + col2 * + col1 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2378
SELECT + col2 * + col1 * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col0 * cor0.col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 815fccd4c3d372b28d3f3fb103025775

query I rowsort
SELECT - - cor0.col1 * cor0.col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL cor2.col0 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab2 cor2
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query I rowsort
SELECT DISTINCT + 29 * + cor0.col1 FROM tab1 AS cor0
----
290
377
754

query I rowsort
SELECT - ( - cor0.col0 ) * col1 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - cor0.col2 * - cor0.col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + - 99 * + col1 FROM tab2 AS cor0
----
-1683
-3069
-5841

onlyif mysql # use DIV operator for integer division
query I rowsort label-2386
SELECT DISTINCT - ( + col0 ) DIV - col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2386
SELECT DISTINCT - ( + col0 ) / - col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - 41 * + col2 FROM tab1 cor0
----
-2214
-2337
-3936

query I rowsort
SELECT DISTINCT col0 * col2 - + 5 FROM tab1 AS cor0
----
157
3643
7675

query I rowsort
SELECT DISTINCT + + 19 + col1 AS col1 FROM tab1 AS cor0
----
29
32
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2390
SELECT + col1 + - col1 DIV col2 FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2390
SELECT + col1 + - col1 / col2 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT ALL + col1 * cor0.col0 + 23 FROM tab0 AS cor0
----
2087
3418
8122

query I rowsort
SELECT DISTINCT - 41 + col0 * col0 FROM tab0 AS cor0
----
1184
535
7880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + - col1 col2 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2394
SELECT + col1 * + col2 + CAST( + 80 AS SIGNED ) * col1 AS col1 FROM tab0 AS cor0
----
14742
7857
9718

skipif mysql # not compatible
query I rowsort label-2394
SELECT + col1 * + col2 + CAST ( + 80 AS INTEGER ) * col1 AS col1 FROM tab0 AS cor0
----
14742
7857
9718

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( + 68 AS REAL ) FROM tab1
----
68
68
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-2396
SELECT col2 + - col0 DIV + col0 FROM tab1 cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-2396
SELECT col2 + - col0 / + col0 FROM tab1 cor0
----
53
56
95

query I rowsort
SELECT + - col0 * col0 * col2 + cor0.col2 + - cor0.col1 * + col2 FROM tab0 AS cor0
----
-1321
-21813
-656902

onlyif mysql # use DIV operator for integer division
query I rowsort label-2398
SELECT col0 DIV 17 FROM tab2 AS cor0
----
0
4
4

skipif mysql # not compatible
query I rowsort label-2398
SELECT col0 / 17 FROM tab2 AS cor0
----
0
4
4

query I rowsort
SELECT + + col1 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT - 1 AS col1 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT ( 61 ) AS col2 FROM tab2 AS cor0
----
61

query I rowsort
SELECT ALL cor0.col0 + - 40 + col1 FROM tab2 AS cor0
----
-2
56
97

query I rowsort
SELECT - ( + col0 ) * + col2 FROM tab0 cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 68 col0 FROM tab1 AS cor0
----
-68
-68
-68

query I rowsort
SELECT ( + 89 ) + col0 AS col0 FROM tab0 AS cor0
----
113
124
178

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab1 cor2, tab2 AS cor3
----
3645 values hashing to 48b1d5d88e8ac6a6daea5a8e5606f112

query I rowsort
SELECT DISTINCT + col1 + + col0 FROM tab2
----
137
38
96

query I rowsort
SELECT + col0 + - 59 FROM tab2
----
-52
19
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-2409
SELECT DISTINCT ( - col1 ) * col0 DIV tab1.col2 AS col1 FROM tab1
----
-1
-10
-11

skipif mysql # not compatible
query I rowsort label-2409
SELECT DISTINCT ( - col1 ) * col0 / tab1.col2 AS col1 FROM tab1
----
-1
-10
-11

query I rowsort
SELECT DISTINCT 84 FROM tab1, tab0 AS cor0
----
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-2411
SELECT col0 DIV col1 + + col2 * + 87 AS col2 FROM tab1
----
4698
4965
8358

skipif mysql # not compatible
query I rowsort label-2411
SELECT col0 / col1 + + col2 * + 87 AS col2 FROM tab1
----
4698
4965
8358

query I rowsort
SELECT + - 68 * - col1 + cor0.col1 FROM tab1 cor0
----
1794
690
897

query I rowsort
SELECT ALL ( 15 ) FROM tab0 AS cor0
----
15
15
15

query I rowsort
SELECT DISTINCT col2 * col0 + + col2 * col1 AS col1 FROM tab0 AS cor0
----
132
14760
3630

query I rowsort
SELECT + col0 + 31 AS col0 FROM tab0 AS cor0
----
120
55
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-2416
SELECT DISTINCT tab1.col2 DIV - ( col2 ) col2 FROM tab1
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2416
SELECT DISTINCT tab1.col2 / - ( col2 ) col2 FROM tab1
----
-1

query I rowsort
SELECT + 90 FROM tab1, tab2 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT - col0 * + 11 * col0 FROM tab2
----
-539
-66924
-68651

query I rowsort
SELECT cor0.col1 * 6 + + col1 AS col0 FROM tab2 cor0
----
119
217
413

query I rowsort
SELECT ALL - col2 - - 8 * col1 FROM tab2
----
221
446
98

query I rowsort
SELECT ALL tab0.col1 - 48 FROM tab0
----
38
43
49

query I rowsort
SELECT - + col1 * col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT 27 AS col0 FROM tab2
----
27

query I rowsort
SELECT - cor0.col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT ALL - 46 AS col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 5a5d45989dcc6a06d9ee5a08945518f9

query I rowsort
SELECT DISTINCT - cor0.col1 * + cor0.col1 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL 65 * - 9 FROM tab2
----
-585
-585
-585

query I rowsort
SELECT + + col2 + + col2 * cor0.col1 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2429
SELECT col0 - col1 DIV - 60 AS col2 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-2429
SELECT col0 - col1 / - 60 AS col2 FROM tab0
----
25
36
90

query I rowsort
SELECT 76 AS col2 FROM tab2
----
76
76
76

query I rowsort
SELECT 2 * + col2 * - col2 FROM tab2 AS cor0
----
-1352
-1458
-2888

query I rowsort
SELECT DISTINCT - 73 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
-73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2433
SELECT + - col2 * col2 * CAST( NULL AS DECIMAL ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2433
SELECT + - col2 * col2 * CAST ( NULL AS REAL ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - tab2.col1 FROM tab2, tab2 cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT - cor0.col2 + col2 * ( col0 ) AS col2 FROM tab2 AS cor0
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-2436
SELECT ALL + - col2 DIV ( - 9 ) - col2 FROM tab0 AS cor0
----
-1
-30
-73

skipif mysql # not compatible
query I rowsort label-2436
SELECT ALL + - col2 / ( - 9 ) - col2 FROM tab0 AS cor0
----
-1
-30
-73

query I rowsort
SELECT DISTINCT - col1 + col1 * + 46 FROM tab1 AS cor0
----
1170
450
585

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * col0 col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL col0 * - col1 + ( cor0.col2 * - col2 ) FROM tab1 AS cor0
----
-10256
-2994
-3889

query I rowsort
SELECT ALL - col0 * + col0 + col2 + + col0 * cor0.col1 FROM tab2 AS cor0
----
-1456
-4860
195

query I rowsort
SELECT - col0 * + col2 + col2 AS col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT - - col0 + + col0 * col0 AS col2 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT - col0 * 87 FROM tab2 AS cor0
----
-609
-6786
-6873

query I rowsort
SELECT col0 * ( col2 ) * col2 FROM tab1 cor0
----
207936
737280
8748

query I rowsort
SELECT - - col0 * + col0 FROM tab1 cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2446
SELECT ALL + col2 DIV + cor0.col0 + cor0.col0 AS col2 FROM tab1 AS cor0
----
21
64
81

skipif mysql # not compatible
query I rowsort label-2446
SELECT ALL + col2 / + cor0.col0 + cor0.col0 AS col2 FROM tab1 AS cor0
----
21
64
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * 42 col2 FROM tab2 AS cor0
----
1302
2478
714

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * 99 col1 FROM tab2 AS cor0
----
2574
2673
3762

query I rowsort
SELECT - ( col1 ) * + col2 + col2 FROM tab0 cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL + col0 + col0 AS col0 FROM tab2
----
14
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-2451
SELECT + col2 + col1 DIV cor0.col2 col1 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2451
SELECT + col2 + col1 / cor0.col2 col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + - 74 + col1 FROM tab0 AS cor0
----
12
17
23

query I rowsort
SELECT DISTINCT + + cor0.col2 * + 15 AS col1 FROM tab2 AS cor0
----
390
405
570

query I rowsort
SELECT DISTINCT - - 11 * + 99 + col2 + - col0 FROM tab1 AS cor0
----
1082
1105
1140

onlyif mysql # use DIV operator for integer division
query I rowsort label-2455
SELECT ALL + - 6 DIV - col0 + col0 AS col1 FROM tab0 cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2455
SELECT ALL + - 6 / - col0 + col0 AS col1 FROM tab0 cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col0 col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL col0 * - col0 + - col2 AS col0 FROM tab2 AS cor0
----
-6110
-6279
-76

query I rowsort
SELECT - 92 FROM tab2 cor0
----
-92
-92
-92

query I rowsort
SELECT + 22 * col2 + + col0 + - ( col0 ) FROM tab0 AS cor0
----
1804
22
726

query I rowsort
SELECT - cor0.col1 + - col2 + col0 FROM tab2 AS cor0
----
-51
-7
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-2461
SELECT + + col2 DIV - col2 AS col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2461
SELECT + + col2 / - col2 AS col2 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - col1 + - col0 * - col1 * ( col2 ) AS col0 FROM tab0 cor0
----
3298
664027
68026

query I rowsort
SELECT DISTINCT + col1 + col1 + 9 FROM tab2 AS cor0
----
127
43
71

query I rowsort
SELECT DISTINCT - col2 * 99 AS col1 FROM tab2
----
-2574
-2673
-3762

query I rowsort
SELECT - ( 14 ) FROM tab1
----
-14
-14
-14

query I rowsort
SELECT DISTINCT + ( - 36 ) * col0 FROM tab1
----
-108
-2304
-2880

query I rowsort
SELECT + col2 * col1 + + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT + + col2 - + col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT 78 FROM tab1 cor0
----
78
78
78

query I rowsort
SELECT DISTINCT + col1 * + col1 - col0 AS col2 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT col0 + 2 * cor0.col2 * col2 AS col0 FROM tab1 cor0
----
18512
5835
6562

query I rowsort
SELECT ALL - 64 AS col2 FROM tab2 cor0
----
-64
-64
-64

query I rowsort
SELECT DISTINCT + col1 * - cor0.col2 AS col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT col0 - ( + col2 ) AS col1 FROM tab1
----
-16
-51
7

query I rowsort
SELECT ALL + cor0.col1 AS col1 FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT + col0 * - col1 + col2 AS col2 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT + + ( 20 ) + col2 * ( 2 ) * col2 FROM tab1 AS cor0
----
18452
5852
6518

query I rowsort
SELECT ALL + 99 * col1 + cor0.col1 * ( 22 ) + - col0 AS col0 FROM tab0 AS cor0
----
10382
10922
11702

query I rowsort
SELECT ALL cor0.col2 + + 63 * - col2 AS col2 FROM tab2 AS cor0
----
-1612
-1674
-2356

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + col0 + + col1 * + 8 col1 FROM tab0 cor0
----
-449
-7193
112

query I rowsort
SELECT DISTINCT - col1 - col0 * + col0 AS col2 FROM tab0 AS cor0
----
-1322
-662
-8012

query I rowsort
SELECT 75 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

query I rowsort
SELECT ALL + + 57 + + cor0.col0 * col1 * ( 3 + cor0.col1 ) AS col0 FROM tab0 AS cor0
----
183753
339557
761363

query I rowsort
SELECT + + 68 AS col1 FROM tab0 AS cor0
----
68
68
68

query I rowsort
SELECT ALL - 27 * + col1 + + col1 FROM tab2 AS cor0
----
-1534
-442
-806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2486
SELECT - + CAST( NULL AS SIGNED ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2486
SELECT - + CAST ( NULL AS INTEGER ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * + ( - col0 ) AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + cor0.col0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2489
SELECT DISTINCT cor0.col1 - CAST( NULL AS SIGNED ) FROM tab2, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2489
SELECT DISTINCT cor0.col1 - CAST ( NULL AS INTEGER ) FROM tab2, tab0 AS cor0
----
NULL

query I rowsort
SELECT - col2 * col0 + 41 AS col2 FROM tab2
----
-148
-1987
-2961

query I rowsort
SELECT col2 + + col0 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-1224
-543
-7839

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 18 + + col1 * col1 col2 FROM tab2 cor0
----
307
3499
979

query I rowsort
SELECT - col2 * + col2 - + col1 * 36 FROM tab1 cor0
----
-3609
-3852
-9684

query I rowsort
SELECT ALL 11 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

query I rowsort
SELECT - + col2 * - 97 + - col0 FROM tab2 cor0
----
2444
2612
3607

query I rowsort
SELECT ALL col0 + + col2 + - col0 AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT + cor0.col2 - col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT - col1 + + col0 * + col1 FROM tab1 cor0
----
1027
52
630

query I rowsort
SELECT col0 + ( ( col0 ) ) AS col2 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT 91 * tab2.col1 AS col1 FROM tab2, tab2 AS cor0
----
1547
2821
5369

query I rowsort
SELECT ALL 13 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT + + col2 * 55 AS col1 FROM tab1 AS cor0
----
2970
3135
5280

onlyif mysql # use DIV operator for integer division
query I rowsort label-2503
SELECT col0 + 51 DIV - col2 col0 FROM tab1 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2503
SELECT col0 + 51 / - col2 col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - col1 + ( - cor0.col2 ) FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ALL - col1 * + col0 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-2506
SELECT ALL col0 DIV + ( col0 ) - + col1 AS col2 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-2506
SELECT ALL col0 / + ( col0 ) - + col1 AS col2 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT DISTINCT - + col1 * 28 FROM tab1 AS cor0
----
-280
-364
-728

query I rowsort
SELECT + - col1 * - col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT - col0 * + ( - col0 ) AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT col2 * + 43 + - 53 FROM tab1 AS cor0
----
2269
2398
4075

query I rowsort
SELECT DISTINCT - - col2 * col1 * + col1 AS col2 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT + col0 + + ( + col0 ) FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT DISTINCT col2 * 82 AS col0 FROM tab1 AS cor0
----
4428
4674
7872

query I rowsort
SELECT - col0 + 89 + - 15 AS col2 FROM tab2 cor0
----
-4
-5
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-2515
SELECT DISTINCT + col0 DIV + cor0.col0 FROM tab0 cor0
----
1

skipif mysql # not compatible
query I rowsort label-2515
SELECT DISTINCT + col0 / + cor0.col0 FROM tab0 cor0
----
1

query I rowsort
SELECT col2 + 53 FROM tab2 AS cor0
----
79
80
91

query I rowsort
SELECT - ( 97 ) + + col0 FROM tab1 AS cor0
----
-17
-33
-94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2518
SELECT DISTINCT - CAST( NULL AS SIGNED ) + col0 * + cor0.col2 col0 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2518
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + col0 * + cor0.col2 col0 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2519
SELECT col2 + col0 + col1 DIV + col2 AS col1 FROM tab0 AS cor0
----
133
172
59

skipif mysql # not compatible
query I rowsort label-2519
SELECT col2 + col0 + col1 / + col2 AS col1 FROM tab0 AS cor0
----
133
172
59

query I rowsort
SELECT + ( col0 ) * col0 AS col2 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT 33 + 47 + - cor0.col0 FROM tab2 AS cor0
----
1
2
73

query I rowsort
SELECT - 40 FROM tab0 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to 01aad4539198a6509248e086869f90a6

query I rowsort
SELECT + - cor0.col1 + ( - col1 * ( + col0 ) ) FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT DISTINCT + + col0 * + col2 + col0 AS col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + - cor0.col2 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT - cor0.col2 - col0 AS col0 FROM tab1 cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-2527
SELECT ALL + - cor0.col2 DIV col0 AS col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2527
SELECT ALL + - cor0.col2 / col0 AS col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT col1 - col2 AS col0 FROM tab2
----
-21
33
4

query I rowsort
SELECT DISTINCT - tab2.col0 AS col1 FROM tab2, tab1, tab2 AS cor0, tab1 AS cor1
----
-7
-78
-79

query I rowsort
SELECT ALL 49 + col0 FROM tab1
----
113
129
52

query I rowsort
SELECT 91 * + col1 AS col1 FROM tab2
----
1547
2821
5369

query I rowsort
SELECT DISTINCT 95 FROM tab1, tab0, tab1 AS cor0
----
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2533
SELECT - col1 - + col1 DIV + 77 AS col1 FROM tab0 AS cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-2533
SELECT - col1 - + col1 / + 77 AS col1 FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT + col2 * ( ( - cor0.col1 ) ) + - 20 FROM tab0 AS cor0
----
-117
-2858
-7482

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 33 + + col2 col0 FROM tab1
----
129
87
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 82 * + col1 col1 FROM tab0
----
7052
7462
7954

onlyif mysql # use DIV operator for integer division
query I rowsort label-2537
SELECT - col1 DIV tab1.col1 AS col0 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2537
SELECT - col1 / tab1.col1 AS col0 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT - 55 AS col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to b90e74bece5521b514096c5b6e105fde

query I rowsort
SELECT DISTINCT col0 * + col1 * - ( + col2 * - col2 ) + ( col1 * col0 ) AS col2 FROM tab2
----
158410
1940635
3115554

query I rowsort
SELECT + col1 * col0 * cor0.col1 AS col1 FROM tab1 AS cor0
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-2541
SELECT ALL - col1 + + col2 DIV cor0.col1 AS col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-2541
SELECT ALL - col1 + + col2 / cor0.col1 AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT cor0.col0 + + col0 * - col0 <= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 * col2 col1 FROM tab1 cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col0 + col0 + col0 * + col2 col0 FROM tab2 AS cor0
----
-3160
-3978
147

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NOT ( col2 ) NOT IN ( col0 )
----

query I rowsort
SELECT col1 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col0 col1 FROM tab2 cor0 WHERE NULL IN ( col1 / cor0.col0 )
----

query III rowsort
SELECT ALL * FROM tab2 WHERE - tab2.col1 + - col0 * col1 IN ( - col1 * - col2 * + tab2.col2 + tab2.col0 * col0 )
----

query I rowsort
SELECT col1 * + col0 FROM tab1 WHERE ( + col0 ) > NULL
----

query I rowsort
SELECT + cor0.col0 * col1 * - col1 + col1 AS col1 FROM tab1 AS cor0
----
-13507
-2002
-6390

query I rowsort
SELECT - cor0.col2 + + cor0.col0 * col1 AS col2 FROM tab0 AS cor0
----
2031
3394
8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-2552
SELECT + - col2 DIV + col1 col2 FROM tab1 AS cor0
----
-2
-5
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2552
SELECT + - col2 / + col1 col2 FROM tab1 AS cor0
----
-2
-5
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2553
SELECT - - cor0.col2 DIV - col0 AS col0 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2553
SELECT - - cor0.col2 / - col0 AS col0 FROM tab0 cor0
----
-1
0
0

query I rowsort
SELECT ALL col2 * col1 + col0 + - col2 AS col1 FROM tab2
----
1586
687
817

query I rowsort
SELECT ALL tab1.col2 + + tab1.col1 + + col2 FROM tab1
----
124
134
205

query I rowsort
SELECT DISTINCT col1 * tab2.col0 AS col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT col0 - cor0.col0 FROM tab2 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2558
SELECT - col0 * col2 + + col0 * col1 DIV col0 FROM tab0 cor0
----
-706
-7207
62

skipif mysql # not compatible
query I rowsort label-2558
SELECT - col0 * col2 + + col0 * col1 / col0 FROM tab0 cor0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2559
SELECT DISTINCT + + col1 DIV col0 + 27 * + col0 FROM tab0 AS cor0
----
2404
651
947

skipif mysql # not compatible
query I rowsort label-2559
SELECT DISTINCT + + col1 / col0 + 27 * + col0 FROM tab0 AS cor0
----
2404
651
947

query I rowsort
SELECT col2 * col2 * col0 + tab1.col1 * + col1 FROM tab1
----
208036
737449
9424

query I rowsort
SELECT col0 * - col0 * col0 + + col0 * + col0 * col0 - col0 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT - col0 * + col1 * tab1.col2 AS col2 FROM tab1
----
-36480
-4212
-99840

query III rowsort
SELECT * FROM tab1 WHERE NOT col0 BETWEEN NULL AND NULL
----

query I rowsort
SELECT - col0 * + col2 + col2 * + col2 + col1 * col0 FROM tab2
----
-215
3250
757

query III rowsort
SELECT * FROM tab2 WHERE NOT ( NULL ) NOT IN ( + col1 / + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2566
SELECT ALL + col1 DIV col0 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-2566
SELECT ALL + col1 / col0 FROM tab0
----
1
2
3

query I rowsort
SELECT 44 * - col0 - + col1 * + 11 FROM tab0
----
-2002
-2607
-4917

onlyif mysql # use DIV operator for integer division
query I rowsort label-2568
SELECT ALL cor0.col1 + + col1 DIV - col0 FROM tab1 AS cor0
----
10
13
18

skipif mysql # not compatible
query I rowsort label-2568
SELECT ALL cor0.col1 + + col1 / - col0 FROM tab1 AS cor0
----
10
13
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-2569
SELECT DISTINCT + col0 DIV - cor0.col2 + col1 * + 34 FROM tab1 AS cor0
----
339
442
884

skipif mysql # not compatible
query I rowsort label-2569
SELECT DISTINCT + col0 / - cor0.col2 + col1 * + 34 FROM tab1 AS cor0
----
339
442
884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col0 + ( - col0 + + col0 ) col0 FROM tab2 AS cor0
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 8 + cor0.col2 col0 FROM tab1 AS cor0
----
104
62
65

query I rowsort
SELECT DISTINCT - 79 * col1 * - 40 FROM tab2
----
186440
53720
97960

onlyif mysql # use DIV operator for integer division
query I rowsort label-2573
SELECT ALL - col1 DIV col2 AS col2 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-2573
SELECT ALL - col1 / col2 AS col2 FROM tab0
----
-1
-2
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2574
SELECT DISTINCT + col0 DIV col0 AS col2 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-2574
SELECT DISTINCT + col0 / col0 AS col2 FROM tab2
----
1

query I rowsort
SELECT + col1 + + col1 - col2 AS col2 FROM tab1
----
-2
-37
-70

query I rowsort
SELECT ALL + col1 + tab1.col2 * tab1.col2 * - col1 + tab1.col2 AS col1 FROM tab1
----
-119699
-32423
-75736

query I rowsort
SELECT col0 * + col0 * col2 FROM tab1
----
233472
486
614400

query I rowsort
SELECT tab1.col2 * col2 + col2 AS col0 FROM tab1
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-2579
SELECT DISTINCT col0 DIV - col1 AS col1 FROM tab1
----
-6
0

skipif mysql # not compatible
query I rowsort label-2579
SELECT DISTINCT col0 / - col1 AS col1 FROM tab1
----
-6
0

query I rowsort
SELECT DISTINCT - col1 FROM tab1 WHERE + col1 - col2 NOT IN ( col1 )
----
-10
-13
-26

query I rowsort
SELECT DISTINCT col2 + col0 AS col2 FROM tab1 WHERE col2 - - col1 > NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2582
SELECT ALL tab0.col1 DIV + col2 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-2582
SELECT ALL tab0.col1 / + col2 FROM tab0
----
1
2
97

query I rowsort
SELECT col0 * + col2 * + col1 + col0 AS col2 FROM tab1
----
36544
4215
99920

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT - col0 * + col2 - + col1 <= ( NULL )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL IN ( tab0.col0 )
----

query I rowsort
SELECT col0 + + col2 * col2 * - col2 FROM tab1
----
-157461
-185129
-884656

query I rowsort
SELECT - col0 + - col2 * col1 AS col0 FROM tab2
----
-1612
-725
-844

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL >= ( col2 )
----

query I rowsort
SELECT - col0 * - tab2.col1 * + col0 AS col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT - col2 * - col0 FROM tab2 WHERE NOT + col1 + + col2 * col2 IN ( - tab2.col2 - - col2 )
----
189
2028
3002

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE col1 + - col0 * - col2 NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT + tab0.col0 * + col2 * tab0.col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT - tab1.col0 + col0 * - col2 AS col2 FROM tab1
----
-165
-3712
-7760

query I rowsort
SELECT ALL col1 * tab2.col0 * + tab2.col1 FROM tab2
----
22831
271518
6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-2595
SELECT DISTINCT col2 DIV col1 + + col0 AS col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2595
SELECT DISTINCT col2 / col1 + + col0 AS col1 FROM tab0
----
24
35
89

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT col1 >= ( col0 + - col1 )
----
79
17
38

query I rowsort
SELECT - col1 * - col0 * - col1 AS col2 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT - col1 + - col0 * 19 * - col2 FROM tab1 AS cor0
----
145907
3052
69302

query I rowsort
SELECT DISTINCT - col2 * col0 + col1 * col1 * + col0 + + col2 FROM tab1 AS cor0
----
1920
2809
5936

query I rowsort
SELECT - + ( col0 ) + col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT - - col2 * col2 + 61 + + col0 AS col2 FROM tab2 AS cor0
----
1584
797
815

query I rowsort
SELECT DISTINCT + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 40 + - 97 col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 57be89f6acab32fa37737fa186dc6512

query I rowsort
SELECT + cor0.col0 * col1 + col1 + col1 AS col0 FROM tab1 AS cor0
----
1066
130
660

query I rowsort
SELECT DISTINCT + - col2 * - col1 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + cor0.col0 * - col2 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT col1 + col0 * + col2 + col1 AS col1 FROM tab2 AS cor0
----
2146
251
3036

query I rowsort
SELECT - cor0.col2 + + col0 AS col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + cor0.col1 * 95 AS col2 FROM tab1 AS cor0
----
1235
2470
950

onlyif mysql # use DIV operator for integer division
query I rowsort label-2610
SELECT DISTINCT col1 * col2 DIV 51 FROM tab0
----
1
146
55

skipif mysql # not compatible
query I rowsort label-2610
SELECT DISTINCT col1 * col2 / 51 FROM tab0
----
1
146
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col1 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT + tab2.col2 * tab2.col1 AS col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 00f153c5d80e692faff5018d8701b92d

query I rowsort
SELECT col2 + - col2 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT 33 * col1 + - col2 * - ( col0 ) FROM tab2
----
1212
3563
3975

query I rowsort
SELECT DISTINCT + 4 + + ( + col0 ) * col0 AS col0 FROM tab0 AS cor0
----
1229
580
7925

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + col0 * cor0.col2 col2 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT ALL - col1 * + col0 - - col1 FROM tab1 cor0
----
-1027
-52
-630

query I rowsort
SELECT col0 * cor0.col0 + col0 AS col0 FROM tab2 cor0
----
56
6162
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-2619
SELECT + + col1 * col0 DIV col2 + 68 FROM tab1 AS cor0
----
69
78
79

skipif mysql # not compatible
query I rowsort label-2619
SELECT + + col1 * col0 / col2 + 68 FROM tab1 AS cor0
----
69
78
79

query I rowsort
SELECT - col0 * - col2 - - col0 AS col1 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL - col2 * - ( col2 ) + col1 * - 2 FROM tab0 AS cor0
----
-193
6542
917

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( ( col1 ) ) + + 57 * - 41 col0 FROM tab0 AS cor0
----
-2423
-2428
-2434

query I rowsort
SELECT ALL + cor0.col2 + + col1 * - col0 * - col2 FROM tab0 AS cor0
----
3396
664200
68145

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - cor0.col2 * + col2 col1 FROM tab1 AS cor0
----
-2890
-3239
-9203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col0 * - col1 col2 FROM tab1
----
1120
704
81

query I rowsort
SELECT col1 + + 28 FROM tab2
----
45
59
87

query I rowsort
SELECT col1 + + 28 * + col0 + + col2 AS col0 FROM tab1
----
164
1859
2349

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + col2 - col2 col1 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT col0 * ( col1 * tab2.col2 ) - - 43 FROM tab2
----
119695
51077
5902

query I rowsort
SELECT DISTINCT + col1 - + col2 FROM tab2
----
-21
33
4

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( - col2 AS REAL ) + - col1 AS col1 FROM tab1
----
28
47
83

query I rowsort
SELECT DISTINCT - 77 + + col2 * col2 FROM tab2
----
1367
599
652

query I rowsort
SELECT DISTINCT - ( ( + col2 ) ) FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2634
SELECT - CAST( NULL AS SIGNED ) / col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2634
SELECT - CAST ( NULL AS INTEGER ) / col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 52 * col0 + + col1 * + col0 FROM tab0 AS cor0
----
12727
3312
5215

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( cor0.col0 AS REAL ) * col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL - ( 26 ) + col0 FROM tab1 AS cor0
----
-23
38
54

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 75 + + col0 col2 FROM tab1
----
139
155
78

query I rowsort
SELECT ALL + col2 + - 92 FROM tab1
----
-35
-38
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-2640
SELECT 37 DIV - col1 - + col2 FROM tab1 AS cor0
----
-55
-60
-98

skipif mysql # not compatible
query I rowsort label-2640
SELECT 37 / - col1 - + col2 FROM tab1 AS cor0
----
-55
-60
-98

query I rowsort
SELECT DISTINCT - 15 FROM tab2, tab1 AS cor0
----
-15

query I rowsort
SELECT ( + 72 ) * - col2 * - col1 AS col2 FROM tab0
----
204336
537264
6984

onlyif mysql # use DIV operator for integer division
query I rowsort label-2643
SELECT ALL - 86 DIV 95 + + col2 AS col0 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2643
SELECT ALL - 86 / 95 + + col2 AS col0 FROM tab1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2644
SELECT + col2 DIV + col1 AS col2 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-2644
SELECT + col2 / + col1 AS col2 FROM tab1
----
2
5
7

query I rowsort
SELECT col1 * tab0.col0 AS col2 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT + - 22 + col1 AS col1 FROM tab0 AS cor0
----
64
69
75

query I rowsort
SELECT - col2 + cor0.col0 AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL + col2 + col2 + + col0 FROM tab0 AS cor0
----
253
37
90

query I rowsort
SELECT - 50 * + col2 + col2 * cor0.col0 + cor0.col0 * col2 AS col1 FROM tab2 AS cor0
----
-972
2756
4104

query I rowsort
SELECT + 66 - col2 AS col0 FROM tab1 AS cor0
----
-30
12
9

query I rowsort
SELECT - col1 * cor0.col0 + cor0.col0 * col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col0 + + 62 AS col2 FROM tab0
----
151
86
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2653
SELECT DISTINCT + col0 * - CAST( NULL AS SIGNED ) col1 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2653
SELECT DISTINCT + col0 * - CAST ( NULL AS INTEGER ) col1 FROM tab0
----
NULL

query I rowsort
SELECT + 91 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

query I rowsort
SELECT DISTINCT col1 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT col0 * 85 + - col0 * - col0 FROM tab0 AS cor0
----
15486
2616
4200

query I rowsort
SELECT - col1 * + 83 FROM tab2 AS cor0
----
-1411
-2573
-4897

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col2 + col0 col0 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT + 26 FROM tab1, tab2 AS cor0
----
26

query I rowsort
SELECT DISTINCT + + 97 + col0 FROM tab2 AS cor0
----
104
175
176

query I rowsort
SELECT + - cor0.col0 + - 47 * + col1 AS col0 FROM tab0 cor0
----
-4066
-4366
-4594

query I rowsort
SELECT DISTINCT - 31 * + 24 - col2 FROM tab2 AS cor0
----
-770
-771
-782

query I rowsort
SELECT - - 93 + + ( - col1 ) FROM tab2 AS cor0
----
34
62
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 - - tab1.col2 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to f2656d9e76ae2d6dc568bba21c85e398

query I rowsort
SELECT + col2 + col2 * col1 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2666
SELECT - col0 * + CAST( 7 AS SIGNED ) * + col0 AS col2 FROM tab2 AS cor0
----
-343
-42588
-43687

skipif mysql # not compatible
query I rowsort label-2666
SELECT - col0 * + CAST ( 7 AS INTEGER ) * + col0 AS col2 FROM tab2 AS cor0
----
-343
-42588
-43687

query I rowsort
SELECT col2 + + cor0.col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT + col2 * - col0 + - col0 * col0 AS col0 FROM tab1 AS cor0
----
-14080
-171
-7744

query I rowsort
SELECT ALL + cor0.col0 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT col1 * col0 * + col0 FROM tab0 AS cor0
----
118825
49536
720811

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 86 * col1 col1 FROM tab2 AS cor0
----
1462
2666
5074

query I rowsort
SELECT ALL - ( + col1 ) * - col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT - cor0.col1 * 88 AS col0 FROM tab0 AS cor0
----
-7568
-8008
-8536

query I rowsort
SELECT ALL - 10 AS col0 FROM tab1 AS cor0
----
-10
-10
-10

query I rowsort
SELECT 62 AS col2 FROM tab0 cor0
----
62
62
62

query I rowsort
SELECT col1 + cor0.col1 AS col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ( col2 ) * tab2.col2 AS col2 FROM tab2
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-2678
SELECT DISTINCT - col1 DIV col1 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-2678
SELECT DISTINCT - col1 / col1 FROM tab0
----
-1

query I rowsort
SELECT - col1 + - col0 * - col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT + col2 + - ( col1 ) * - col1 + 31 FROM tab2 AS cor0
----
1019
3538
358

onlyif mysql # use DIV operator for integer division
query I rowsort label-2681
SELECT - col0 DIV - col0 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2681
SELECT - col0 / - col0 AS col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT - col0 * - 37 + - col2 AS col2 FROM tab2 AS cor0
----
232
2860
2885

query I rowsort
SELECT + 4 * col1 FROM tab2
----
124
236
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-2684
SELECT + - cor0.col0 DIV - col0 + 52 FROM tab1 AS cor0
----
53
53
53

skipif mysql # not compatible
query I rowsort label-2684
SELECT + - cor0.col0 / - col0 + 52 FROM tab1 AS cor0
----
53
53
53

query I rowsort
SELECT - - col1 * 38 + - col0 * col1 AS col2 FROM tab1 AS cor0
----
-260
-546
910

query I rowsort
SELECT - tab1.col2 * + tab1.col1 AS col0 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT ( + col1 * - 92 ) FROM tab1
----
-1196
-2392
-920

query I rowsort
SELECT ALL - col2 + cor0.col2 * cor0.col2 AS col2 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT DISTINCT + - col1 * - col0 + 92 * + cor0.col0 * - 56 AS col2 FROM tab2 AS cor0
----
-35847
-397254
-405665

query I rowsort
SELECT + + col1 * - col2 + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT - + col0 * col2 + - col0 FROM tab0 AS cor0
----
-70
-7387
-816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2692
SELECT ALL + + col2 * + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2692
SELECT ALL + + col2 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * + 79 + col1 * - cor0.col2 * ( - col2 ) FROM tab0 AS cor0
----
-7566
604695
86860

query I rowsort
SELECT + + col0 - - 51 * col0 FROM tab1 AS cor0
----
156
3328
4160

onlyif mysql # use DIV operator for integer division
query I rowsort label-2695
SELECT DISTINCT - cor0.col2 DIV col1 AS col2 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2695
SELECT DISTINCT - cor0.col2 / col1 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + + col0 * - 12 + 15 * + col2 * + ( 16 * + cor0.col0 ) AS col1 FROM tab0 AS cor0
----
1750452
189792
7980

query I rowsort
SELECT ALL col0 + - ( ( - col1 ) ) FROM tab2
----
137
38
96

query I rowsort
SELECT ALL + tab0.col0 + col2 + + 80 AS col2 FROM tab0
----
116
137
251

onlyif mysql # use DIV operator for integer division
query I rowsort label-2699
SELECT ALL col1 DIV - col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2699
SELECT ALL col1 / - col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2700
SELECT - CAST( NULL AS DECIMAL ) * cor0.col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2700
SELECT - CAST ( NULL AS REAL ) * cor0.col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * - ( - col0 ) * tab1.col0 FROM tab1
----
-233472
-486
-614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + tab1.col1 + col2 + tab1.col1 col0 FROM tab1
----
1357
1484
637

query I rowsort
SELECT DISTINCT + col1 + - col0 * tab1.col2 FROM tab1
----
-136
-3638
-7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-2704
SELECT DISTINCT col1 * 24 + - col0 + + col0 DIV 25 col2 FROM tab2
----
1341
332
737

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2704
SELECT DISTINCT col1 * 24 + - col0 + + col0 / 25 col2 FROM tab2
----
1341
332
737

onlyif mysql # use DIV operator for integer division
query I rowsort label-2705
SELECT DISTINCT col0 + + col2 DIV + col1 AS col1 FROM tab2
----
7
78
81

skipif mysql # not compatible
query I rowsort label-2705
SELECT DISTINCT col0 + + col2 / + col1 AS col1 FROM tab2
----
7
78
81

query I rowsort
SELECT ALL - + cor0.col2 + col2 * - col1 * col1 FROM tab0 AS cor0
----
-244101
-679124
-9410

query I rowsort
SELECT ALL - ( + col2 ) * col1 + 51 * col1 FROM tab0 AS cor0
----
-2821
1548
4850

query I rowsort
SELECT DISTINCT + 94 - + cor0.col0 * col1 * col1 FROM tab0 AS cor0
----
-177410
-329221
-736915

query I rowsort
SELECT - 57 + - col1 FROM tab2 AS cor0
----
-116
-74
-88

query I rowsort
SELECT DISTINCT - + 30 - + col2 FROM tab1 AS cor0
----
-126
-84
-87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 30 col2 FROM tab2 cor0
----
-30
-30
-30

query I rowsort
SELECT DISTINCT - col2 - cor0.col2 AS col0 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT DISTINCT - 93 * col0 + 52 AS col1 FROM tab2 AS cor0
----
-599
-7202
-7295

query I rowsort
SELECT DISTINCT + 60 AS col1 FROM tab1
----
60

query I rowsort
SELECT - 48 FROM tab1, tab2 AS cor0
----
9 values hashing to 31c94943c073954e4ca20b170ab61f8c

query I rowsort
SELECT ALL - ( + 28 ) AS col1 FROM tab1 cor0 CROSS JOIN tab2 cor1
----
9 values hashing to c3e7fa3d059fc708f03c60e9cef0c115

query I rowsort
SELECT 44 * col2 + - 86 * 41 FROM tab1
----
-1018
-1150
698

query I rowsort
SELECT DISTINCT - 83 AS col1 FROM tab0 AS cor0
----
-83

query I rowsort
SELECT ALL + 89 + cor0.col0 FROM tab0 AS cor0
----
113
124
178

query I rowsort
SELECT DISTINCT - cor0.col0 * col1 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 - col2 col2 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT + col0 * col0 + - 89 * - col1 FROM tab0 AS cor0
----
16020
8230
9858

query I rowsort
SELECT - cor0.col2 * - col1 + ( 14 ) FROM tab1 AS cor0
----
1262
1418
584

query I rowsort
SELECT ( 85 ) + col2 * - col2 + 94 AS col1 FROM tab0
----
-6545
-910
178

query I rowsort
SELECT - ( - 64 ) FROM tab1
----
64
64
64

query I rowsort
SELECT + 94 FROM tab1, tab0 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 cor0, tab1 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to 803a5565701c4ced6bba69940782c17a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 39 col0 FROM tab2 AS cor0
----
-39
-39
-39

query I rowsort
SELECT - + ( 97 ) * - col0 + + ( + 67 ) FROM tab1 cor0
----
358
6275
7827

onlyif mysql # use DIV operator for integer division
query I rowsort label-2730
SELECT DISTINCT - col1 DIV col2 AS col0 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-2730
SELECT DISTINCT - col1 / col2 AS col0 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT DISTINCT ( - ( col0 ) ) FROM tab2 cor0
----
-7
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2732
SELECT ALL CAST( + col2 AS SIGNED ) + - col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2732
SELECT ALL CAST ( + col2 AS INTEGER ) + - col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 + col2 * cor0.col1 col1 FROM tab1 AS cor0
----
1168
1401
506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 46 * col1 col0 FROM tab0 AS cor0
----
3956
4186
4462

onlyif mysql # use DIV operator for integer division
query I rowsort label-2735
SELECT DISTINCT - + cor0.col2 + - cor0.col0 DIV - 19 FROM tab0 AS cor0
----
-32
-78
0

skipif mysql # not compatible
query I rowsort label-2735
SELECT DISTINCT - + cor0.col2 + - cor0.col0 / - 19 FROM tab0 AS cor0
----
-32
-78
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 + - col2 col0 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT ALL 63 * col2 * + 89 FROM tab0 AS cor0
----
185031
459774
5607

query I rowsort
SELECT - + col2 * col1 + col0 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT col2 * cor0.col0 + - cor0.col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT DISTINCT - cor0.col1 + col0 * - col1 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
-119711
-51051
-5890

query I rowsort
SELECT - cor0.col0 * col2 + + 78 FROM tab0 cor0
----
-714
-7220
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-2742
SELECT ALL + + 70 + col0 DIV col1 AS col2 FROM tab2 cor0
----
70
71
74

skipif mysql # not compatible
query I rowsort label-2742
SELECT ALL + + 70 + col0 / col1 AS col2 FROM tab2 cor0
----
70
71
74

query I rowsort
SELECT col0 * + col0 * - 74 FROM tab2 AS cor0
----
-3626
-450216
-461834

query I rowsort
SELECT + col2 * col1 + - 62 * ( + col1 + col0 ) AS col1 FROM tab2 AS cor0
----
-1519
-5306
-6960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2745
SELECT ALL - CAST( NULL AS SIGNED ) + 93 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2745
SELECT ALL - CAST ( NULL AS INTEGER ) + 93 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + + col2 * + col2 + - col2 * col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + + cor0.col2 * + col1 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + col1 + - ( col1 ) AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col2 * + col0 + + col2 * + col0 FROM tab0 AS cor0
----
14596
1584
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col1 col1 FROM tab2 cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-2751
SELECT + col0 DIV 23 FROM tab1 AS cor0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-2751
SELECT + col0 / 23 FROM tab1 AS cor0
----
0
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-2752
SELECT ALL - + cor0.col0 DIV col0 + col1 * col2 + - 3 FROM tab0 AS cor0
----
2834
7458
93

skipif mysql # not compatible
query I rowsort label-2752
SELECT ALL - + cor0.col0 / col0 + col1 * col2 + - 3 FROM tab0 AS cor0
----
2834
7458
93

query I rowsort
SELECT - - col2 * + col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - col0 + ( 19 ) FROM tab1 AS cor0
----
-45
-61
16

query I rowsort
SELECT - col2 * 8 FROM tab1 AS cor0
----
-432
-456
-768

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2756
SELECT cor0.col0 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2756
SELECT cor0.col0 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + - ( col0 ) * + col1 FROM tab1 cor0
----
-1027
-52
-630

query I rowsort
SELECT ALL col1 * + ( + col0 ) * - col2 AS col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT ALL - + 67 FROM tab2 AS cor0
----
-67
-67
-67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 40 * - col0 col0 FROM tab1 AS cor0
----
-120
-2560
-3200

query I rowsort
SELECT - - col2 * col1 + + col0 + - ( - col1 ) * cor0.col1 AS col0 FROM tab1 AS cor0
----
1497
2083
734

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 cor0 CROSS JOIN tab2, tab1 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to 577401eb866f52e8954d694a867c38d2

query I rowsort
SELECT ALL tab2.col0 * ( col2 ) * col1 AS col1 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT + - 70 * - 74 FROM tab0 AS cor0
----
5180
5180
5180

onlyif mysql # use DIV operator for integer division
query I rowsort label-2765
SELECT - + col1 DIV - col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2765
SELECT - + col1 / - col2 FROM tab1 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2766
SELECT 32 DIV - col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2766
SELECT 32 / - col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT + + cor0.col1 * - 51 * cor0.col1 AS col0 FROM tab0 AS cor0
----
-377196
-422331
-479859

query I rowsort
SELECT + + cor0.col2 * - col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-2769
SELECT - 36 DIV col1 FROM tab1 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-2769
SELECT - 36 / col1 FROM tab1 AS cor0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 62 col1 FROM tab1
----
-62
-62
-62

query I rowsort
SELECT ALL col2 * col2 + - cor0.col0 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT ALL ( + col0 ) + col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL 92 * - cor0.col0 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to fc22e1592150a651a8f14a7df8117da4

query I rowsort
SELECT DISTINCT + 77 * - cor0.col2 FROM tab0, tab0 cor0
----
-2541
-6314
-77

query I rowsort
SELECT 45 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT tab1.col2 * tab1.col0 AS col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL cor0.col0 * - col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + ( + ( - cor1.col1 ) ) FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT DISTINCT + col0 * col1 + col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL + 69 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT DISTINCT - col0 + + 51 FROM tab2 AS cor0
----
-27
-28
44

query I rowsort
SELECT DISTINCT + cor0.col2 * tab1.col2 FROM tab1, tab1 AS cor0
----
2916
3078
3249
5184
5472
9216

query I rowsort
SELECT ALL + cor0.col0 FROM tab2, tab0 cor0, tab2 cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + - col1 * col0 + - col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT - 48 FROM tab0, tab1 AS cor0, tab0 cor1, tab2, tab2 AS cor2
----
243 values hashing to ad601a7a5a65b244f1d1159b03e3e25c

query I rowsort
SELECT DISTINCT - col0 * - col2 * 92 + - col1 * - cor0.col1 FROM tab0 AS cor0
----
12629
679697
80260

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 AS cor0, tab2 AS cor1, tab1, tab1 AS cor2
----
3645 values hashing to ca91d1f523a87017f672304548e91a77

query I rowsort
SELECT ALL - + col2 * 88 * col0 + col0 AS col2 FROM tab0 cor0
----
-3045
-642135
-69672

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( + col2 ) + - 65 + 52 col0 FROM tab1 cor0
----
-109
-67
-70

query I rowsort
SELECT ALL + 93 * - col2 AS col0 FROM tab1 AS cor0
----
-5022
-5301
-8928

query I rowsort
SELECT - col0 * col0 * col2 + - col2 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
-237120
-622080
-648

query I rowsort
SELECT DISTINCT + ( col1 ) * col0 + + 88 AS col2 FROM tab2 AS cor0
----
1431
305
4690

query I rowsort
SELECT DISTINCT - 32 * - col0 - 68 * 22 AS col0 FROM tab0 AS cor0
----
-376
-728
1352

onlyif mysql # use DIV operator for integer division
query I rowsort label-2794
SELECT - cor0.col1 DIV - col2 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-2794
SELECT - cor0.col1 / - col2 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL - ( + cor0.col2 ) FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - + 63 + col2 * 43 + + col2 AS col1 FROM tab1 AS cor0
----
2313
2445
4161

query I rowsort
SELECT DISTINCT - col0 * col1 + cor0.col2 * - 3 FROM tab1 cor0
----
-1328
-240
-811

query I rowsort
SELECT DISTINCT - cor0.col2 * cor0.col1 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( ( col1 ) ) col2 FROM tab0
----
86
91
97

query I rowsort
SELECT - tab1.col0 * 73 AS col2 FROM tab1
----
-219
-4672
-5840

query I rowsort
SELECT ( + col1 ) * + tab2.col1 AS col0 FROM tab2
----
289
3481
961

query I rowsort
SELECT - 10 * - col1 + col0 * - ( + tab2.col2 + - tab2.col1 ) AS col2 FROM tab2
----
-1489
3164
338

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2803
SELECT - CAST( NULL AS SIGNED ) * col0 * - col2 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2803
SELECT - CAST ( NULL AS INTEGER ) * col0 * - col2 AS col1 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2804
SELECT CAST( NULL AS SIGNED ) * 27 * col0 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2804
SELECT CAST ( NULL AS INTEGER ) * 27 * col0 AS col0 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2805
SELECT - col1 + + cor0.col0 + - CAST( col2 + + col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-128
-166
-64

skipif mysql # not compatible
query I rowsort label-2805
SELECT - col1 + + cor0.col0 + - CAST ( col2 + + col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-128
-166
-64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2806
SELECT + col1 + + col1 + CAST( + 60 AS SIGNED ) * - col1 FROM tab1 AS cor0
----
-1508
-580
-754

skipif mysql # not compatible
query I rowsort label-2806
SELECT + col1 + + col1 + CAST ( + 60 AS INTEGER ) * - col1 FROM tab1 AS cor0
----
-1508
-580
-754

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab1, tab0 cor1, tab0 AS cor2
----
972 values hashing to 8b4fcda7f1ca76bad7c7d728f54a51e0

query I rowsort
SELECT ALL - col0 * + 19 AS col0 FROM tab0
----
-1691
-456
-665

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2809
SELECT ALL CAST( NULL AS DECIMAL ) FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2809
SELECT ALL CAST ( NULL AS REAL ) FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT cor1.col2 FROM tab1 cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT ALL - col2 * - 66 * + col2 + - col0 + + col2 FROM tab2 cor0
----
44564
48134
95263

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2812
SELECT col1 + - CAST( - tab0.col1 AS SIGNED ) FROM tab0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-2812
SELECT col1 + - CAST ( - tab0.col1 AS INTEGER ) FROM tab0
----
172
182
194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 89 col1 FROM tab1, tab0 AS cor0
----
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2814
SELECT + col0 - - 89 DIV col1 col0 FROM tab1 AS cor0
----
6
72
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2814
SELECT + col0 - - 89 / col1 col0 FROM tab1 AS cor0
----
6
72
86

query I rowsort
SELECT + 46 * + col0 + - col2 * 8 FROM tab0 AS cor0
----
1602
3438
840

query I rowsort
SELECT DISTINCT + 10 * - 19 - col0 FROM tab2
----
-197
-268
-269

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - col1 ) - col1 col2 FROM tab1
----
-20
-26
-52

query I rowsort
SELECT 93 * tab2.col2 * col1 AS col0 FROM tab2
----
142662
60078
77841

query I rowsort
SELECT ALL 32 - col0 FROM tab1
----
-32
-48
29

query I rowsort
SELECT - 56 + col1 * - col0 FROM tab1 AS cor0
----
-1096
-134
-696

query I rowsort
SELECT + + 99 + ( col1 ) FROM tab0 AS cor0
----
185
190
196

query I rowsort
SELECT ALL + cor0.col2 + 37 * - col0 AS col1 FROM tab2 AS cor0
----
-232
-2860
-2885

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col2 + - col1 * - ( col0 ) col0 FROM tab1 AS cor0
----
-2609
-2838
-8176

query I rowsort
SELECT DISTINCT + 50 + col1 FROM tab2 cor0
----
109
67
81

query I rowsort
SELECT 70 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to c07fb58c935d7dd3a559c80465f90463

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab0 AS cor2
----
3645 values hashing to 38dccc9c32724260ec175f754830d863

query I rowsort
SELECT ALL - 17 + 59 AS col0 FROM tab2 AS cor0
----
42
42
42

query I rowsort
SELECT ALL col2 + - 76 * col1 * ( - col2 ) AS col1 FROM tab0 AS cor0
----
215721
567194
7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-2829
SELECT DISTINCT + 20 DIV + col0 AS col2 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2829
SELECT DISTINCT + 20 / + col0 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + 84 AS col0 FROM tab2 AS cor0
----
84

query I rowsort
SELECT + ( + cor0.col0 ) * - col1 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + - 87 FROM tab0 AS cor0
----
-87
-87
-87

query I rowsort
SELECT DISTINCT + - col1 + - 14 AS col2 FROM tab0 AS cor0
----
-100
-105
-111

query I rowsort
SELECT DISTINCT 48 + + col1 AS col2 FROM tab0 AS cor0
----
134
139
145

query I rowsort
SELECT ALL - 64 * + col0 AS col0 FROM tab0 AS cor0
----
-1536
-2240
-5696

query I rowsort
SELECT + col0 + + cor0.col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - col1 * - col1 * 90 + col0 AS col2 FROM tab1 AS cor0
----
15290
60843
9064

query I rowsort
SELECT + + col1 + col1 * - col1 * col0 AS col2 FROM tab0 cor0
----
-177418
-329218
-736918

query I rowsort
SELECT ALL 25 AS col2 FROM tab1 cor0
----
25
25
25

query I rowsort
SELECT DISTINCT 82 * - col0 FROM tab0 AS cor0
----
-1968
-2870
-7298

query I rowsort
SELECT ALL - cor0.col0 + - cor0.col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT + + ( + col0 ) * col1 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + col1 * - 51 + col0 + tab0.col1 * col2 FROM tab0
----
-1524
-4815
2910

query I rowsort
SELECT DISTINCT col0 + col1 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT col2 * cor0.col0 - - ( ( col1 ) ) AS col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL - col2 * col2 + col2 AS col2 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT col2 * col1 + - col2 * - col1 + 46 FROM tab2 AS cor0
----
1338
1720
3114

query I rowsort
SELECT ALL + cor0.col0 * ( + ( col2 ) ) + ( - ( col2 ) ) AS col0 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT - 25 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to 2e7a33467ee3a4d9570560d60302b35a

query I rowsort
SELECT - tab2.col2 + - col1 AS col0 FROM tab2
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-2851
SELECT ALL + - col0 DIV col2 AS col0 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2851
SELECT ALL + - col0 / col2 AS col0 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT + col0 + + ( cor0.col1 ) * + col0 FROM tab1 cor0
----
1120
704
81

query I rowsort
SELECT ALL + - col0 * 99 FROM tab2 cor0
----
-693
-7722
-7821

query I rowsort
SELECT + cor0.col2 + + 55 * ( cor0.col2 * 89 ) + col2 AS col0 FROM tab0 AS cor0
----
161601
401554
4897

query I rowsort
SELECT DISTINCT - + 60 FROM tab2 AS cor0
----
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + cor0.col1 col0 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2857
SELECT - ( ( col0 ) ) * + CAST( col2 * col2 AS SIGNED ) col2 FROM tab0 AS cor0
----
-26136
-35
-598436

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2857
SELECT - ( ( col0 ) ) * + CAST ( col2 * col2 AS INTEGER ) col2 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT DISTINCT 79 * col0 FROM tab0 AS cor0
----
1896
2765
7031

query I rowsort
SELECT DISTINCT + col0 * col2 * cor0.col2 AS col0 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT ( - col2 ) * col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT col1 + - ( 96 ) FROM tab1
----
-70
-83
-86

query I rowsort
SELECT + col1 * + ( - 26 ) - col0 AS col2 FROM tab2
----
-1612
-521
-813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2863
SELECT CAST( NULL AS DECIMAL ) FROM tab1, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2863
SELECT CAST ( NULL AS REAL ) FROM tab1, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + col0 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT cor1.col0 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT ALL col2 + - col0 + 20 AS col1 FROM tab0
----
-14
13
29

query I rowsort
SELECT + col1 + + tab2.col1 + - col2 FROM tab2
----
-4
35
92

query I rowsort
SELECT DISTINCT - col1 * + col2 + - col1 * + tab0.col1 AS col2 FROM tab0
----
-10234
-15743
-9506

query I rowsort
SELECT tab2.col0 * - 16 AS col2 FROM tab2
----
-112
-1248
-1264

query I rowsort
SELECT DISTINCT + - cor0.col0 AS col1 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT 13 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query I rowsort
SELECT ALL + + col2 * + cor0.col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT + ( - col0 ) * col2 AS col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT + col2 + + 5 FROM tab1
----
101
59
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2875
SELECT ALL cor0.col2 * 34 + col1 + - col2 DIV col0 FROM tab2 AS cor0
----
1309
943
946

skipif mysql # not compatible
query I rowsort label-2875
SELECT ALL cor0.col2 * 34 + col1 + - col2 / col0 FROM tab2 AS cor0
----
1309
943
946

query I rowsort
SELECT ALL + col0 * + col1 - - col2 AS col0 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT ALL + + 59 + - col0 * - cor0.col2 AS col0 FROM tab1 cor0
----
221
3707
7739

query I rowsort
SELECT DISTINCT - 92 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1, tab1 AS cor2
----
-92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2879
SELECT DISTINCT - CAST( NULL AS SIGNED ) * - col2 AS col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-2879
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * - col2 AS col1 FROM tab0
----
NULL

query I rowsort
SELECT ALL - col0 - + col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT + - col2 + col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + cor0.col0 + cor0.col2 * 90 AS col1 FROM tab2 AS cor0
----
2418
2437
3499

query I rowsort
SELECT ALL - col2 * - col2 - + col0 * col1 AS col0 FROM tab1 AS cor0
----
2609
2838
8176

query I rowsort
SELECT DISTINCT 92 AS col1 FROM tab2 AS cor0
----
92

query I rowsort
SELECT DISTINCT col2 + col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT + + 34 FROM tab0 AS cor0
----
34
34
34

query I rowsort
SELECT ( col0 ) + ( col0 ) * col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT ALL + - col0 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ( - col2 ) AS col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT 19 + - col2 FROM tab0 AS cor0
----
-14
-63
18

query I rowsort
SELECT - 5 + col1 * - col2 FROM tab0 cor0
----
-102
-2843
-7467

query I rowsort
SELECT - - cor0.col2 * + col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - 45 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab1 AS cor2
----
-45

query I rowsort
SELECT - + col1 + + cor0.col0 AS col2 FROM tab0 cor0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2895
SELECT - col0 + + col1 DIV col0 col0 FROM tab2 AS cor0
----
-3
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2895
SELECT - col0 + + col1 / col0 col0 FROM tab2 AS cor0
----
-3
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2896
SELECT + - col1 * + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2896
SELECT + - col1 * + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 + cor0.col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + cor0.col2 * - 52 FROM tab2 AS cor0
----
-1352
-1404
-1976

query I rowsort
SELECT + col2 * ( 2 ) FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL ( col1 ) * - col0 * col2 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT cor1.col0 - + cor0.col0 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to a9e8a660067ce14822c0936e144e190d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + ( + 54 ) col2 FROM tab0 AS cor0
----
-35
19
30

query I rowsort
SELECT ALL - col1 * ( 99 ) FROM tab1 AS cor0
----
-1287
-2574
-990

query I rowsort
SELECT DISTINCT col2 + col1 * col2 FROM tab2 cor0
----
1560
684
864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col0 * + col2 ) col1 FROM tab0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2906
SELECT CAST( NULL AS SIGNED ) + col2 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2906
SELECT CAST ( NULL AS INTEGER ) + col2 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col0 * - col0 + + col1 * cor0.col2 FROM tab0 AS cor0
----
1322
15383
3414

query I rowsort
SELECT + + cor0.col0 + - ( + cor0.col1 ) * + col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT - col0 + col0 * col2 FROM tab1 AS cor0
----
159
3584
7600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2910
SELECT - CAST( + col2 AS SIGNED ) + + col1 AS col0 FROM tab2 cor0
----
-21
33
4

skipif mysql # not compatible
query I rowsort label-2910
SELECT - CAST ( + col2 AS INTEGER ) + + col1 AS col0 FROM tab2 cor0
----
-21
33
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-2911
SELECT ALL col1 DIV col1 col2 FROM tab1 cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2911
SELECT ALL col1 / col1 col2 FROM tab1 cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2912
SELECT + - col0 * col1 * col1 - col1 * cor0.col0 DIV col2 AS col0 FROM tab1 AS cor0
----
-13530
-2029
-6411

skipif mysql # not compatible
query I rowsort label-2912
SELECT + - col0 * col1 * col1 - col1 * cor0.col0 / col2 AS col0 FROM tab1 AS cor0
----
-13530
-2029
-6411

query I rowsort
SELECT + - col2 * col2 + col0 + 88 AS col1 FROM tab0 AS cor0
----
-6547
-977
122

query I rowsort
SELECT col0 * 36 FROM tab2 AS cor0
----
252
2808
2844

onlyif mysql # use DIV operator for integer division
query I rowsort label-2915
SELECT ALL + col1 DIV col2 + col0 + + col0 * - col1 col1 FROM tab0
----
-2038
-3263
-8009

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2915
SELECT ALL + col1 / col2 + col0 + + col0 * - col1 col1 FROM tab0
----
-2038
-3263
-8009

onlyif mysql # use DIV operator for integer division
query I rowsort label-2916
SELECT ALL - col2 DIV 76 + col2 * col2 * - col1 FROM tab2
----
-22599
-24548
-39884

skipif mysql # not compatible
query I rowsort label-2916
SELECT ALL - col2 / 76 + col2 * col2 * - col1 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT - 93 + cor0.col1 * col0 FROM tab2 AS cor0
----
124
1250
4509

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 53 * - cor0.col1 + + cor0.col2 + 91 col0 FROM tab1 AS cor0
----
-1233
-382
-502

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 cor0, tab1, tab1 AS cor1
----
972 values hashing to d222ba302bd1ddd1c8b2ddf1a4d0b07a

query I rowsort
SELECT 70 AS col1 FROM tab2, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

query I rowsort
SELECT ALL 96 FROM tab1
----
96
96
96

query I rowsort
SELECT - - cor0.col0 + col0 + - ( 20 + - col2 ) FROM tab2 AS cor0
----
162
176
21

query I rowsort
SELECT 84 + - col0 FROM tab0 AS cor0
----
-5
49
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2924
SELECT DISTINCT + CAST( + tab1.col1 AS SIGNED ) AS col2 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2924
SELECT DISTINCT + CAST ( + tab1.col1 AS INTEGER ) AS col2 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT 56 FROM tab1, tab1 cor0
----
56

query I rowsort
SELECT col1 + - ( 35 ) AS col1 FROM tab1 AS cor0
----
-22
-25
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2927
SELECT - - col2 + ( - 25 * + col0 ) - CAST( NULL AS SIGNED ) * + cor0.col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2927
SELECT - - col2 + ( - 25 * + col0 ) - CAST ( NULL AS INTEGER ) * + cor0.col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( tab0.col0 * col0 + - col2 ) AS col1 FROM tab0
----
1224
543
7839

query I rowsort
SELECT col0 - + 92 FROM tab1 AS cor0
----
-12
-28
-89

query I rowsort
SELECT DISTINCT col1 + + 35 FROM tab2 AS cor0
----
52
66
94

query I rowsort
SELECT + cor0.col1 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ALL - col2 + 14 AS col0 FROM tab1 cor0
----
-40
-43
-82

query I rowsort
SELECT - + ( - cor0.col1 ) + - col2 AS col1 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT - ( - col2 ) * + col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT col2 - - ( - 80 ) FROM tab2
----
-42
-53
-54

query I rowsort
SELECT DISTINCT + col1 + col1 + ( col2 ) * - col1 AS col2 FROM tab1 AS cor0
----
-1222
-1352
-550

query I rowsort
SELECT - col2 * col0 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
-34
-7216
-759

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col0 col2 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT + ( col2 + + col1 ) FROM tab0
----
119
173
98

query I rowsort
SELECT ALL cor0.col1 FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT 22 AS col2 FROM tab1, tab2, tab0 AS cor0
----
22

query I rowsort
SELECT + col1 + + col2 * ( col2 ) AS col0 FROM tab1
----
2942
3259
9229

query I rowsort
SELECT DISTINCT - 76 AS col2 FROM tab0
----
-76

query I rowsort
SELECT - ( col0 * + col2 ) FROM tab0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-2945
SELECT - col2 DIV col0 + - cor0.col1 FROM tab1 AS cor0
----
-10
-14
-44

skipif mysql # not compatible
query I rowsort label-2945
SELECT - col2 / col0 + - cor0.col1 FROM tab1 AS cor0
----
-10
-14
-44

query I rowsort
SELECT ALL - cor0.col1 * 26 FROM tab0 AS cor0
----
-2236
-2366
-2522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 * ( - 77 ) - cor0.col1 col2 FROM tab0 AS cor0
----
1762
2598
6762

onlyif mysql # use DIV operator for integer division
query I rowsort label-2948
SELECT DISTINCT - col2 DIV - col2 + col2 * + col0 FROM tab0 AS cor0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-2948
SELECT DISTINCT - col2 / - col2 + col2 * + col0 FROM tab0 AS cor0
----
36
7299
793

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col1 * + ( + col0 ) col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT col0 + 8 FROM tab2
----
15
86
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2951
SELECT + CAST( NULL AS SIGNED ) * 81 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2951
SELECT + CAST ( NULL AS INTEGER ) * 81 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-2952
SELECT ALL col2 + col0 DIV cor0.col0 col1 FROM tab0 AS cor0
----
2
34
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2952
SELECT ALL col2 + col0 / cor0.col0 col1 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT ALL + col2 * 73 + tab0.col1 AS col1 FROM tab0
----
170
2495
6077

query I rowsort
SELECT + col1 * col0 * - col1 AS col2 FROM tab0 cor0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL - + ( 67 ) FROM tab0 AS cor0
----
-67
-67
-67

query I rowsort
SELECT ALL - 6 AS col1 FROM tab2 AS cor0
----
-6
-6
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2957
SELECT + col2 DIV + col1 + col1 + ( - col1 + col1 ) AS col1 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2957
SELECT + col2 / + col1 + col1 + ( - col1 + col1 ) AS col1 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - + 57 * + col0 FROM tab0 AS cor0
----
-1368
-1995
-5073

onlyif mysql # use DIV operator for integer division
query I rowsort label-2959
SELECT DISTINCT + - col0 DIV col0 AS col2 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-2959
SELECT DISTINCT + - col0 / col0 AS col2 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT - col0 + + col1 * + 75 * - col1 FROM tab1 AS cor0
----
-12755
-50703
-7564

query I rowsort
SELECT ALL - cor0.col2 * cor0.col2 AS col1 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - col0 * col2 * - col1 + + 62 FROM tab0 AS cor0
----
3457
664180
68174

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2963
SELECT ALL + CAST( NULL AS SIGNED ) FROM tab0, tab1, tab0 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2963
SELECT ALL + CAST ( NULL AS INTEGER ) FROM tab0, tab1, tab0 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL - col0 - - col0 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 22 * + col0 AS col2 FROM tab2 AS cor0
----
-154
-1716
-1738

query I rowsort
SELECT DISTINCT + col0 + - col2 * ( col2 ) AS col1 FROM tab2 cor0
----
-1365
-598
-722

query I rowsort
SELECT ALL - col0 * col1 - + ( col1 ) FROM tab2 cor0
----
-1360
-248
-4661

query I rowsort
SELECT 13 FROM tab2, tab0 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to b092e3fa17e78608cf120e97d1bfff67

query I rowsort
SELECT + 52 * - col0 AS col1 FROM tab1 AS cor0
----
-156
-3328
-4160

query I rowsort
SELECT ALL + 91 AS col1 FROM tab2 AS cor0
----
91
91
91

query I rowsort
SELECT + + col0 * col1 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - 4 FROM tab1, tab1 AS cor0
----
-4

query I rowsort
SELECT DISTINCT cor0.col2 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
54
57
96

query I rowsort
SELECT ALL + 5 + 57 FROM tab2 AS cor0
----
62
62
62

query I rowsort
SELECT cor0.col2 + - 94 * + col2 FROM tab0 AS cor0
----
-3069
-7626
-93

query I rowsort
SELECT - - col0 + col2 * cor0.col2 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT ( - 77 ) FROM tab1
----
-77
-77
-77

query I rowsort
SELECT DISTINCT + + ( col0 ) AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - + tab1.col0 FROM tab1, tab0, tab0 cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT + tab2.col2 * tab2.col1 AS col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT tab1.col0 * - 92 FROM tab1, tab2 AS cor0
----
9 values hashing to fc22e1592150a651a8f14a7df8117da4

query I rowsort
SELECT ALL + col1 * col0 + col1 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT - col2 + 49 FROM tab2 cor0
----
11
22
23

query I rowsort
SELECT DISTINCT + cor0.col2 + col0 * - 46 * col1 FROM tab0 AS cor0
----
-156169
-372472
-94911

query I rowsort
SELECT ALL + col1 + col2 AS col1 FROM tab1
----
109
67
80

query I rowsort
SELECT ALL + col1 * + tab1.col0 + col1 * col0 FROM tab1
----
1280
156
2080

query I rowsort
SELECT col1 + - col1 * + 77 FROM tab1
----
-1976
-760
-988

query I rowsort
SELECT - col0 * - col0 * ( 84 ) AS col2 FROM tab0
----
102900
48384
665364

query I rowsort
SELECT DISTINCT 90 AS col0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2990
SELECT ALL col1 * col1 + tab0.col0 DIV - col2 AS col2 FROM tab0
----
7396
8280
9374

skipif mysql # not compatible
query I rowsort label-2990
SELECT ALL col1 * col1 + tab0.col0 / - col2 AS col2 FROM tab0
----
7396
8280
9374

query I rowsort
SELECT - 69 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to ca5f4bc365dc2c6b14187d6ffc83a01d

query I rowsort
SELECT col0 + - tab0.col1 * + col2 * - col0 AS col1 FROM tab0
----
3430
664207
68136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2993
SELECT CAST( cor0.col0 AS SIGNED ) AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

skipif mysql # not compatible
query I rowsort label-2993
SELECT CAST ( cor0.col0 AS INTEGER ) AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT col1 + + ( col0 ) AS col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT - col1 + col1 * + 58 FROM tab1 AS cor0
----
1482
570
741

query I rowsort
SELECT DISTINCT + + col0 * - col0 - - 84 * col1 FROM tab1 cor0
----
-3256
-5308
2175

query I rowsort
SELECT DISTINCT col2 + + 91 + col1 AS col2 FROM tab0 AS cor0
----
189
210
264

query I rowsort
SELECT DISTINCT col0 + + col0 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT DISTINCT + - cor0.col1 + col0 * + col0 AS col1 FROM tab1 cor0
----
-17
4086
6387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * cor0.col2 + + cor0.col2 * col1 col0 FROM tab0 cor0
----
1749
738
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3001
SELECT ALL col1 * CAST( - col1 AS SIGNED ) + - cor0.col2 FROM tab2 AS cor0
----
-327
-3507
-988

skipif mysql # not compatible
query I rowsort label-3001
SELECT ALL col1 * CAST ( - col1 AS INTEGER ) + - cor0.col2 FROM tab2 AS cor0
----
-327
-3507
-988

onlyif mysql # use DIV operator for integer division
query I rowsort label-3002
SELECT + cor0.col2 DIV col2 + + ( + cor0.col2 ) AS col2 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-3002
SELECT + cor0.col2 / col2 + + ( + cor0.col2 ) AS col2 FROM tab1 AS cor0
----
55
58
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - ( cor0.col2 ) col2 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-3004
SELECT - - col0 DIV + cor0.col0 AS col2 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3004
SELECT - - col0 / + cor0.col0 AS col2 FROM tab0 cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 * 60 + 21 * + col1 col2 FROM tab1 AS cor0
----
-2694
-3210
-5487

query I rowsort
SELECT DISTINCT + col2 + 34 FROM tab2 AS cor0
----
60
61
72

query I rowsort
SELECT + col2 * col0 + col1 AS col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ALL - col0 + - 25 * + 42 AS col0 FROM tab0 AS cor0
----
-1074
-1085
-1139

onlyif mysql # use DIV operator for integer division
query I rowsort label-3009
SELECT - col0 + CAST( + col0 AS SIGNED ) DIV cor0.col0 FROM tab0 cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-3009
SELECT - col0 + CAST ( + col0 AS INTEGER ) / cor0.col0 FROM tab0 cor0
----
-23
-34
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 + 98 col1 FROM tab1 AS cor0
----
2
41
44

query I rowsort
SELECT col1 * 29 FROM tab2
----
1711
493
899

query I rowsort
SELECT + col0 * - col0 + + col2 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT - ( 3 ) * - col0 FROM tab0 AS cor0
----
105
267
72

query I rowsort
SELECT - 68 * 67 FROM tab0 AS cor0
----
-4556
-4556
-4556

query I rowsort
SELECT col2 + - col2 AS col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - 55 + 31 FROM tab1 AS cor0
----
-24
-24
-24

query I rowsort
SELECT + col0 * - col1 + col0 AS col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT + + cor0.col2 AS col0 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort
SELECT - + cor0.col1 * col2 + CAST ( + 18 + + col2 AS REAL ) AS col1 FROM tab1 AS cor0
----
-1134
-1332
-495

query I rowsort
SELECT ALL - 27 * + col0 + - 40 AS col1 FROM tab0 AS cor0
----
-2443
-688
-985

query I rowsort
SELECT ALL + 6 AS col1 FROM tab2 AS cor0
----
6
6
6

query I rowsort
SELECT - 61 * - col0 AS col0 FROM tab1 AS cor0
----
183
3904
4880

query I rowsort
SELECT - col1 * cor0.col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-3024
SELECT col1 DIV cor0.col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3024
SELECT col1 / cor0.col1 FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 45 * + col2 + col1 * col1 col1 FROM tab1
----
2665
3106
4489

onlyif mysql # use DIV operator for integer division
query I rowsort label-3026
SELECT - tab0.col1 * col1 DIV - ( - tab0.col0 ) AS col0 FROM tab0
----
-268
-308
-93

skipif mysql # not compatible
query I rowsort label-3026
SELECT - tab0.col1 * col1 / - ( - tab0.col0 ) AS col0 FROM tab0
----
-268
-308
-93

skipif mysql # not compatible
query I rowsort
SELECT - col1 * col0 / - CAST ( - col1 AS REAL ) AS col2 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT DISTINCT col2 + col2 * ( col0 + col1 ) AS col1 FROM tab2
----
1053
3588
3686

query I rowsort
SELECT 26 * col2 * - col0 + + col0 AS col2 FROM tab0
----
-189659
-20568
-875

onlyif mysql # use DIV operator for integer division
query I rowsort label-3030
SELECT col2 * tab1.col0 - 36 DIV col0 AS col0 FROM tab1
----
150
3648
7680

skipif mysql # not compatible
query I rowsort label-3030
SELECT col2 * tab1.col0 - 36 / col0 AS col0 FROM tab1
----
150
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col1 ) col1 FROM tab1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 67 * + col0 col0 FROM tab1 AS cor0
----
201
4288
5360

query I rowsort
SELECT - 10 AS col1 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to bb7f754a7a056e665155ed52a63f5bc0

query I rowsort
SELECT + cor0.col0 * col2 + - cor0.col0 FROM tab1 AS cor0
----
159
3584
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 * ( - 17 ) * + cor0.col2 col0 FROM tab0, tab2 AS cor0
----
-3213
-34476
-51034

query I rowsort
SELECT DISTINCT + cor0.col0 + ( + cor0.col2 + col0 ) * 39 FROM tab1 AS cor0
----
2226
4783
6944

query I rowsort
SELECT DISTINCT + col2 * col0 + col2 FROM tab0 cor0
----
36
7380
825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + ( + cor0.col2 ) col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT + + col0 + 88 AS col0 FROM tab1 cor0
----
152
168
91

query I rowsort
SELECT ALL - col2 * + ( col0 * + col0 ) FROM tab2 AS cor0
----
-1323
-158184
-237158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3041
SELECT DISTINCT + col2 - - CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3041
SELECT DISTINCT + col2 - - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + - col1 * 83 AS col1 FROM tab2 cor0
----
-1411
-2573
-4897

query I rowsort
SELECT ALL - - col1 * ( col0 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT col0 * 93 AS col2 FROM tab1 AS cor0
----
279
5952
7440

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * - ( + col1 ) + + col1 col2 FROM tab1 cor0
----
110
182
702

query I rowsort
SELECT DISTINCT - + col1 + + 36 AS col0 FROM tab2 AS cor0
----
-23
19
5

query I rowsort
SELECT ( col1 ) * cor0.col0 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + + 62 * - 80 AS col2 FROM tab2 AS cor0
----
-4960
-4960
-4960

query I rowsort
SELECT 75 * 58 AS col1 FROM tab0 AS cor0
----
4350
4350
4350

query I rowsort
SELECT 20 * ( + col0 ) * - ( 31 ) + + col0 + + col0 AS col2 FROM tab2 cor0
----
-4326
-48204
-48822

query I rowsort
SELECT 31 * col1 FROM tab0 AS cor0
----
2666
2821
3007

query I rowsort
SELECT DISTINCT - ( + col0 ) * col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + - ( + 60 ) * col1 AS col2 FROM tab2 cor0
----
-1020
-1860
-3540

query I rowsort
SELECT DISTINCT ( ( cor0.col1 ) ) * col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - - col1 * col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT + 61 * 67 * - col2 AS col2 FROM tab1 AS cor0
----
-220698
-232959
-392352

query I rowsort
SELECT ( 46 ) + col0 FROM tab0 AS cor0
----
135
70
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-3058
SELECT DISTINCT + + 40 + - col0 DIV - col2 AS col0 FROM tab0 AS cor0
----
40
41
75

skipif mysql # not compatible
query I rowsort label-3058
SELECT DISTINCT + + 40 + - col0 / - col2 AS col0 FROM tab0 AS cor0
----
40
41
75

query I rowsort
SELECT + col2 * 34 FROM tab2 AS cor0
----
1292
884
918

query I rowsort
SELECT DISTINCT + + col0 + - col0 FROM tab0 cor0
----
0

query I rowsort
SELECT DISTINCT - 70 AS col1 FROM tab1 AS cor0
----
-70

query I rowsort
SELECT DISTINCT + 15 - col2 * 53 AS col2 FROM tab0 AS cor0
----
-1734
-38
-4331

query I rowsort
SELECT DISTINCT - 69 AS col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
-69

query I rowsort
SELECT ALL + 83 FROM tab1, tab2 AS cor0
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

query I rowsort
SELECT DISTINCT + ( col2 ) + 99 + col1 FROM tab2 AS cor0
----
154
157
184

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3066
SELECT + - ( cor0.col2 ) + CAST( NULL AS SIGNED ) * col2 * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3066
SELECT + - ( cor0.col2 ) + CAST ( NULL AS INTEGER ) * col2 * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col2 + col0 * col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT col2 * + col1 + col1 + + cor0.col0 AS col2 FROM tab0 AS cor0
----
229
2948
7642

onlyif mysql # use DIV operator for integer division
query I rowsort label-3069
SELECT + + col2 + col1 DIV 40 FROM tab2 AS cor0
----
27
27
38

skipif mysql # not compatible
query I rowsort label-3069
SELECT + + col2 + col1 / 40 FROM tab2 AS cor0
----
27
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col0 col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + 32 * - col0 + + col1 FROM tab2 AS cor0
----
-193
-2437
-2511

query I rowsort
SELECT DISTINCT + cor0.col1 * + col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 * + col0 col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - col1 + col1 * + cor0.col2 + col1 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-3075
SELECT ALL - cor0.col1 DIV col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3075
SELECT ALL - cor0.col1 / col1 FROM tab2 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3076
SELECT cor0.col1 DIV col0 + col0 + col2 DIV + col2 AS col1 FROM tab1 AS cor0
----
12
65
81

skipif mysql # not compatible
query I rowsort label-3076
SELECT cor0.col1 / col0 + col0 + col2 / + col2 AS col1 FROM tab1 AS cor0
----
12
65
81

query I rowsort
SELECT ALL 41 + + col2 + + col0 FROM tab1
----
162
217
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 31 + - col1 col0 FROM tab2
----
-28
0
14

query I rowsort
SELECT ALL + tab1.col0 + - ( - col0 ) + col0 AS col0 FROM tab1
----
192
240
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3080
SELECT ALL - col2 * - col1 + - col1 DIV - 38 FROM tab2 AS cor0
----
1535
646
837

skipif mysql # not compatible
query I rowsort label-3080
SELECT ALL - col2 * - col1 + - col1 / - 38 FROM tab2 AS cor0
----
1535
646
837

query I rowsort
SELECT DISTINCT + 62 AS col0 FROM tab2 AS cor0
----
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 42 + col1 * col1 col2 FROM tab2 cor0
----
1003
331
3523

query I rowsort
SELECT - 69 * col0 * + 61 + 94 FROM tab0 AS cor0
----
-100922
-147221
-374507

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0, tab2 cor1, tab1, tab0 cor2
----
3645 values hashing to 9d746e15fdb5adcb43a7518cd9743eb3

query I rowsort
SELECT - tab2.col0 * col2 + + ( col0 * col0 ) AS col2 FROM tab2
----
-140
3239
4056

query I rowsort
SELECT ALL - 49 * + col0 AS col1 FROM tab2
----
-343
-3822
-3871

query I rowsort
SELECT ALL - + col1 + - col1 + col2 * col0 AS col2 FROM tab1 AS cor0
----
110
3628
7654

query I rowsort
SELECT DISTINCT - col0 + ( + col2 ) FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT - tab2.col2 + ( - col1 * - col1 ) AS col1 FROM tab2
----
251
3455
934

onlyif mysql # use DIV operator for integer division
query I rowsort label-3090
SELECT + col1 + - 49 - 52 DIV col0 FROM tab0
----
35
42
47

skipif mysql # not compatible
query I rowsort label-3090
SELECT + col1 + - 49 - 52 / col0 FROM tab0
----
35
42
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3091
SELECT DISTINCT - col2 + - CAST( NULL AS SIGNED ) - - col1 * col1 * col1 AS col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-3091
SELECT DISTINCT - col2 + - CAST ( NULL AS INTEGER ) - - col1 * col1 * col1 AS col0 FROM tab0
----
NULL

query I rowsort
SELECT DISTINCT + 30 + 32 FROM tab2
----
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3093
SELECT DISTINCT - col0 * tab0.col2 + + col1 DIV - ( 40 ) FROM tab0
----
-37
-7300
-794

skipif mysql # not compatible
query I rowsort label-3093
SELECT DISTINCT - col0 * tab0.col2 + + col1 / - ( 40 ) FROM tab0
----
-37
-7300
-794

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - col0 col0 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT ALL col1 + col1 + + col2 * - col0 AS col1 FROM tab2
----
-127
-1910
-2968

query I rowsort
SELECT - 95 * col2 AS col1 FROM tab2
----
-2470
-2565
-3610

query I rowsort
SELECT - 2 FROM tab0, tab2 cor0, tab0 AS cor1, tab0 cor2
----
81 values hashing to fbbdc69ed4bc9a68f44d1ba867b620b3

onlyif mysql # use DIV operator for integer division
query I rowsort label-3098
SELECT DISTINCT + - ( col2 ) * col0 DIV cor0.col0 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-3098
SELECT DISTINCT + - ( col2 ) * col0 / cor0.col0 FROM tab2 AS cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col2 ) col0 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT ALL + + col0 * - col2 + col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT + col2 * cor0.col0 AS col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT - col2 * col2 + cor0.col1 * - ( col2 ) + col0 * + ( + col2 + - col1 ) AS col1 FROM tab2 AS cor0
----
-1594
-431
-4784

query I rowsort
SELECT ALL - + 89 * col1 + cor0.col2 AS col1 FROM tab2 AS cor0
----
-1475
-2732
-5225

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col1 + col0 col0 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT - cor0.col2 * 15 FROM tab0 AS cor0
----
-1230
-15
-495

query I rowsort
SELECT DISTINCT - + col0 * + col1 AS col2 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL 55 FROM tab2, tab1 cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT + - col2 + ( 42 ) FROM tab1 AS cor0
----
-12
-15
-54

query I rowsort
SELECT col1 - ( + ( col1 ) ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - col0 + + 4 AS col2 FROM tab1 AS cor0
----
68
7
84

query I rowsort
SELECT - col1 * - 11 AS col1 FROM tab1 cor0
----
110
143
286

onlyif mysql # use DIV operator for integer division
query I rowsort label-3112
SELECT DISTINCT col1 DIV - 16 FROM tab0 cor0
----
-5
-6

skipif mysql # not compatible
query I rowsort label-3112
SELECT DISTINCT col1 / - 16 FROM tab0 cor0
----
-5
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3113
SELECT - col1 * - CAST( + col2 AS SIGNED ) + + col0 * + col1 AS col2 FROM tab1 AS cor0
----
1210
1482
2288

skipif mysql # not compatible
query I rowsort label-3113
SELECT - col1 * - CAST ( + col2 AS INTEGER ) + + col0 * + col1 AS col2 FROM tab1 AS cor0
----
1210
1482
2288

query I rowsort
SELECT + - cor0.col0 + - col1 AS col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL - + cor0.col1 * 43 FROM tab1 AS cor0
----
-1118
-430
-559

onlyif mysql # use DIV operator for integer division
query I rowsort label-3116
SELECT DISTINCT + cor0.col0 + + ( col1 + - col0 ) DIV - cor0.col2 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3116
SELECT DISTINCT + cor0.col0 + + ( col1 + - col0 ) / - cor0.col2 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3117
SELECT ALL + col0 * - CAST( NULL AS DECIMAL ) - 22 * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3117
SELECT ALL + col0 * - CAST ( NULL AS REAL ) - 22 * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( 16 ) FROM tab1 AS cor0
----
-16
-16
-16

query I rowsort
SELECT DISTINCT - col1 - - col0 * col0 * col0 AS col0 FROM tab2 AS cor0
----
312
474493
493022

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3120
SELECT - CAST( NULL AS SIGNED ) + - cor0.col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3120
SELECT - CAST ( NULL AS INTEGER ) + - cor0.col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 53 AS col0 FROM tab2 AS cor0
----
-53
-53
-53

query I rowsort
SELECT DISTINCT + - col1 + - cor0.col2 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3123
SELECT ALL + col2 + col0 * - CAST( - col0 AS SIGNED ) FROM tab0 AS cor0
----
1226
609
8003

skipif mysql # not compatible
query I rowsort label-3123
SELECT ALL + col2 + col0 * - CAST ( - col0 AS INTEGER ) FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT - + cor0.col0 * col0 + ( - 90 ) AS col0 FROM tab2 cor0
----
-139
-6174
-6331

query I rowsort
SELECT DISTINCT + 71 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
71

query I rowsort
SELECT DISTINCT + 10 AS col0 FROM tab1, tab0 AS cor0
----
10

query I rowsort
SELECT DISTINCT - col0 + col0 AS col1 FROM tab1
----
0

query III rowsort
SELECT * FROM tab2 WHERE col1 IN ( + col1 - + col0 )
----

query I rowsort
SELECT tab0.col0 * - col1 AS col0 FROM tab0
----
-2064
-3395
-8099

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT - col1 * - col0 <> - col1 + - col1 + col2 / col0
----

query I rowsort
SELECT - col2 + + col2 * col0 FROM tab1 cor0
----
108
3591
7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-3132
SELECT ALL + col2 DIV col1 + 5 col1 FROM tab2
----
5
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3132
SELECT ALL + col2 / col1 + 5 col1 FROM tab2
----
5
5
7

query I rowsort
SELECT col2 * col2 + col1 FROM tab1 cor0
----
2942
3259
9229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + col0 col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT + col0 * + ( + 64 ) + col0 FROM tab1 AS cor0
----
195
4160
5200

query I rowsort
SELECT col1 + ( 9 * - col0 ) AS col1 FROM tab2 AS cor0
----
-32
-643
-694

query I rowsort
SELECT + col0 + - 35 AS col1 FROM tab1 AS cor0
----
-32
29
45

query I rowsort
SELECT + col2 + 32 AS col0 FROM tab2 AS cor0
----
58
59
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-3139
SELECT + 5 DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3139
SELECT + 5 / col1 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3140
SELECT - tab1.col0 * + CAST( 58 * + col2 AS SIGNED ) col1 FROM tab1
----
-211584
-445440
-9396

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3140
SELECT - tab1.col0 * + CAST ( 58 * + col2 AS INTEGER ) col1 FROM tab1
----
-211584
-445440
-9396

query I rowsort
SELECT col1 * 13 * col2 AS col2 FROM tab0
----
1261
36894
97006

query I rowsort
SELECT DISTINCT 9 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
9

query I rowsort
SELECT ALL + col2 * tab2.col1 + col0 - + col0 AS col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT ALL col0 * col1 * - col2 AS col2 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT + cor1.col1 + + 87 + 38 AS col1 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to e5e52dfade01fe774840a589558a24ca

query I rowsort
SELECT + ( + 61 ) FROM tab1
----
61
61
61

query I rowsort
SELECT + 81 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT DISTINCT - 84 FROM tab1
----
-84

query I rowsort
SELECT + - 95 AS col0 FROM tab1 AS cor0
----
-95
-95
-95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3150
SELECT - cor0.col2 + + col0 * CAST( + col2 AS SIGNED ) FROM tab0 AS cor0
----
34
7216
759

skipif mysql # not compatible
query I rowsort label-3150
SELECT - cor0.col2 + + col0 * CAST ( + col2 AS INTEGER ) FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT ALL - 52 * - col2 + - col1 AS col1 FROM tab1 AS cor0
----
2782
2954
4979

query I rowsort
SELECT + - 6 + + cor0.col0 FROM tab2 AS cor0
----
1
72
73

query I rowsort
SELECT DISTINCT - col1 + + col2 * col1 + col2 * col0 FROM tab1 cor0
----
1540
4208
8915

query I rowsort
SELECT ALL ( + cor0.col0 ) * + cor0.col1 * - 8 AS col1 FROM tab2 AS cor0
----
-10744
-1736
-36816

query I rowsort
SELECT ALL - - 39 - 4 AS col1 FROM tab0 AS cor0
----
35
35
35

query I rowsort
SELECT - tab1.col2 * - 16 - col1 AS col1 FROM tab1
----
1523
838
902

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3157
SELECT ALL tab1.col0 + CAST( 24 AS SIGNED ) FROM tab1
----
104
27
88

skipif mysql # not compatible
query I rowsort label-3157
SELECT ALL tab1.col0 + CAST ( 24 AS INTEGER ) FROM tab1
----
104
27
88

query I rowsort
SELECT ALL + - col2 * col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT 52 + - col2 AS col2 FROM tab0 AS cor0
----
-30
19
51

query I rowsort
SELECT ALL - 8 * col1 + col2 FROM tab1 cor0
----
-154
-23
-8

query I rowsort
SELECT DISTINCT + col1 * col0 + - col0 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT ALL + ( col2 ) * col0 * - col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT col0 + + 2 FROM tab2 AS cor0
----
80
81
9

query I rowsort
SELECT DISTINCT - 53 + 91 FROM tab2 AS cor0
----
38

query I rowsort
SELECT - - col2 * 96 AS col0 FROM tab1 AS cor0
----
5184
5472
9216

query I rowsort
SELECT col1 + 73 * col0 AS col1 FROM tab1 AS cor0
----
245
4682
5853

query I rowsort
SELECT + col2 * col0 * - col0 FROM tab2 cor0
----
-1323
-158184
-237158

query I rowsort
SELECT ALL + 40 * col0 + cor0.col2 FROM tab1 cor0
----
174
2617
3296

onlyif mysql # use DIV operator for integer division
query I rowsort label-3169
SELECT ( col0 ) DIV col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3169
SELECT ( col0 ) / col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 24 AS col1 FROM tab1
----
24
24
24

query I rowsort
SELECT ( col0 * 59 ) FROM tab0
----
1416
2065
5251

onlyif mysql # use DIV operator for integer division
query I rowsort label-3172
SELECT + + 50 DIV col1 - - 28 DIV - cor0.col0 col2 FROM tab0 cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3172
SELECT + + 50 / col1 - - 28 / - cor0.col0 col2 FROM tab0 cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3173
SELECT 71 DIV + col0 + - cor0.col2 + col0 col0 FROM tab1 AS cor0
----
-16
-28
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3173
SELECT 71 / + col0 + - cor0.col2 + col0 col0 FROM tab1 AS cor0
----
-16
-28
8

query I rowsort
SELECT + col1 + - ( 16 ) FROM tab0 AS cor0
----
70
75
81

query I rowsort
SELECT + cor0.col1 * - 5 FROM tab1 AS cor0
----
-130
-50
-65

onlyif mysql # use DIV operator for integer division
query I rowsort label-3176
SELECT - col1 DIV + tab1.col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3176
SELECT - col1 / + tab1.col2 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3177
SELECT + col0 + - CAST( col1 + + col2 AS SIGNED ) * 87 AS col2 FROM tab0 AS cor0
----
-10329
-14962
-8491

skipif mysql # not compatible
query I rowsort label-3177
SELECT + col0 + - CAST ( col1 + + col2 AS INTEGER ) * 87 AS col2 FROM tab0 AS cor0
----
-10329
-14962
-8491

query I rowsort
SELECT DISTINCT + + cor0.col0 + col1 * 85 FROM tab1 AS cor0
----
1185
2213
914

query I rowsort
SELECT ALL + - col1 * 58 - col0 FROM tab1 AS cor0
----
-1511
-644
-834

query I rowsort
SELECT ALL col1 * ( - ( + cor0.col0 ) ) + - 59 FROM tab1 cor0
----
-1099
-137
-699

query I rowsort
SELECT ALL cor0.col0 * - col0 + ( - cor0.col2 ) FROM tab0 AS cor0
----
-1226
-609
-8003

query I rowsort
SELECT - cor1.col0 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT ALL - - cor0.col1 * 5 + 97 + - col0 * + 69 FROM tab0 cor0
----
-1129
-1833
-5589

query I rowsort
SELECT + 4 AS col1 FROM tab1, tab0 cor0, tab2 cor1
----
27 values hashing to 730dff78e83112374961ea711f98ebaa

query I rowsort
SELECT + - col1 * 39 AS col1 FROM tab2 AS cor0
----
-1209
-2301
-663

query I rowsort
SELECT DISTINCT - col0 * col2 AS col1 FROM tab2 cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort
SELECT + + col0 * - CAST ( + col2 * - col0 AS REAL ) - - 16 FROM tab0 AS cor0
----
1241
19024
649538

query I rowsort
SELECT - col0 * 89 AS col1 FROM tab2 cor0
----
-623
-6942
-7031

query I rowsort
SELECT DISTINCT - + col1 + col1 * + col2 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT + col0 + 99 - + 27 FROM tab2 AS cor0
----
150
151
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3191
SELECT + + col1 DIV + 52 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3191
SELECT + + col1 / + 52 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col2 + col2 * 11 FROM tab1 AS cor0
----
1152
648
684

query I rowsort
SELECT - + col2 + 63 * col0 FROM tab0 AS cor0
----
1479
2204
5525

query I rowsort
SELECT ALL col0 * - ( col1 ) AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 85 col1 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 5e8deeabad7bbbaf313fcdcb4adc75eb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 56 col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT DISTINCT - col2 + 88 * + col1 FROM tab1 AS cor0
----
1048
2234
823

query I rowsort
SELECT - 22 + + cor0.col2 * col2 AS col1 FROM tab0 AS cor0
----
-21
1067
6702

query I rowsort
SELECT - ( + 13 ) * col0 + ( + ( col2 ) ) FROM tab0 AS cor0
----
-1075
-279
-454

onlyif mysql # use DIV operator for integer division
query I rowsort label-3200
SELECT CAST( col2 AS SIGNED ) * cor0.col0 DIV - 63 + + 48 FROM tab2 AS cor0
----
1
16
45

skipif mysql # not compatible
query I rowsort label-3200
SELECT CAST ( col2 AS INTEGER ) * cor0.col0 / - 63 + + 48 FROM tab2 AS cor0
----
1
16
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-3201
SELECT col1 + col2 DIV tab2.col0 AS col2 FROM tab2
----
17
34
59

skipif mysql # not compatible
query I rowsort label-3201
SELECT col1 + col2 / tab2.col0 AS col2 FROM tab2
----
17
34
59

query I rowsort
SELECT col2 * col1 + + ( tab1.col1 ) FROM tab1
----
1261
1430
580

query I rowsort
SELECT + 29 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT + 24 FROM tab2 cor0
----
24
24
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + col1 * col2 col0 FROM tab1 AS cor0
----
-16224
-36504
-5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-3206
SELECT + 57 DIV + 96 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-3206
SELECT + 57 / + 96 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT ALL + 57 AS col0 FROM tab2 AS cor0
----
57
57
57

query I rowsort
SELECT DISTINCT + col0 + col2 * - col2 * + 73 FROM tab2 AS cor0
----
-105333
-49270
-53210

query I rowsort
SELECT - 60 + + col1 FROM tab0
----
26
31
37

query I rowsort
SELECT ALL cor0.col0 * - col0 + cor0.col1 AS col0 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT - + 86 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 9d2e1e8eda15b3b83dd7136dfc4f19af

query I rowsort
SELECT DISTINCT 19 + + col0 * + col2 * 64 - tab1.col2 AS col0 FROM tab1
----
10333
233434
491443

query I rowsort
SELECT ( + col2 ) + + col0 * - 18 - + col0 FROM tab0
----
-1609
-423
-664

query I rowsort
SELECT DISTINCT + tab1.col1 - + tab1.col1 FROM tab1
----
0

query I rowsort
SELECT + col2 + + col0 AS col0 FROM tab2
----
104
117
34

query I rowsort
SELECT col0 + tab2.col0 - 1 FROM tab2
----
13
155
157

query I rowsort
SELECT 88 * col0 AS col2 FROM tab0
----
2112
3080
7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-3218
SELECT + col2 DIV col0 AS col2 FROM tab2
----
0
0
3

skipif mysql # not compatible
query I rowsort label-3218
SELECT + col2 / col0 AS col2 FROM tab2
----
0
0
3

query I rowsort
SELECT + 70 * col0 FROM tab2 cor0
----
490
5460
5530

query I rowsort
SELECT DISTINCT - col0 - - tab2.col1 AS col2 FROM tab2
----
-19
-62
24

query I rowsort
SELECT ALL - 24 - col0 FROM tab2
----
-102
-103
-31

query I rowsort
SELECT ALL col0 * - tab0.col2 * - col0 + + col1 + tab0.col2 FROM tab0
----
1323
19127
649695

query I rowsort
SELECT ALL + col1 + 69 * col1 FROM tab1
----
1820
700
910

query I rowsort
SELECT DISTINCT col2 + 93 AS col1 FROM tab0
----
126
175
94

query I rowsort
SELECT col2 * + 45 * + col2 AS col2 FROM tab0
----
302580
45
49005

query I rowsort
SELECT - col2 + - 27 * + col0 + ( ( + col1 ) + - col2 ) AS col0 FROM tab2
----
-2099
-212
-2192

query I rowsort
SELECT ALL + col1 - cor0.col2 AS col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL + 22 * col2 FROM tab2 AS cor0
----
572
594
836

query I rowsort
SELECT 74 * - ( col0 ) + - 99 AS col1 FROM tab2 AS cor0
----
-5871
-5945
-617

onlyif mysql # use DIV operator for integer division
query I rowsort label-3230
SELECT ALL + + ( - col1 ) * col0 DIV + 33 + col0 FROM tab1 AS cor0
----
1
45
49

skipif mysql # not compatible
query I rowsort label-3230
SELECT ALL + + ( - col1 ) * col0 / + 33 + col0 FROM tab1 AS cor0
----
1
45
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-3231
SELECT - - col0 DIV col0 + cor0.col0 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-3231
SELECT - - col0 / col0 + cor0.col0 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT ALL - + col1 * + col0 + 44 * col2 * - col0 AS col0 FROM tab1 AS cor0
----
-161152
-338960
-7206

query I rowsort
SELECT ( cor0.col1 ) + - ( + col2 ) FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + 27 * col2 + ( - col2 * col1 ) FROM tab2 cor0
----
-108
-832
380

query I rowsort
SELECT DISTINCT 61 AS col1 FROM tab0, tab0 cor0, tab0 AS cor1
----
61

query I rowsort
SELECT ALL col1 * + col1 + - col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT ALL cor0.col2 * col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + - col1 * - col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL col1 * 94 FROM tab0 AS cor0
----
8084
8554
9118

query I rowsort
SELECT DISTINCT - + col0 - ( + col1 ) FROM tab0 AS cor0
----
-110
-132
-180

onlyif mysql # use DIV operator for integer division
query I rowsort label-3241
SELECT ALL - col0 + col0 DIV - col0 AS col0 FROM tab2 AS cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-3241
SELECT ALL - col0 + col0 / - col0 AS col0 FROM tab2 AS cor0
----
-79
-8
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 24 col2 FROM tab0 AS cor0
----
24
24
24

query I rowsort
SELECT + ( col0 ) + - cor0.col0 * ( col0 ) AS col0 FROM tab1 cor0
----
-4032
-6
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-3244
SELECT ALL - col1 * - 37 - col0 DIV col2 AS col0 FROM tab0 AS cor0
----
3182
3366
3554

skipif mysql # not compatible
query I rowsort label-3244
SELECT ALL - col1 * - 37 - col0 / col2 AS col0 FROM tab0 AS cor0
----
3182
3366
3554

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3245
SELECT - CAST( NULL AS DECIMAL ) + ( - col1 ) / - CAST( - 36 AS SIGNED ) col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3245
SELECT - CAST ( NULL AS REAL ) + ( - col1 ) / - CAST ( - 36 AS INTEGER ) col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 5 + + col1 + col2 AS col0 FROM tab0 AS cor0
----
114
168
93

query I rowsort
SELECT ALL + + 40 + col2 * + cor0.col1 * 16 AS col0 FROM tab1 AS cor0
----
20008
22504
9160

query I rowsort
SELECT DISTINCT col2 * 90 - + col1 FROM tab1 AS cor0
----
4834
5120
8627

query I rowsort
SELECT ALL - cor1.col1 AS col2 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT + 62 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3251
SELECT + col0 + - 80 DIV + col0 FROM tab1
----
-23
63
79

skipif mysql # not compatible
query I rowsort label-3251
SELECT + col0 + - 80 / + col0 FROM tab1
----
-23
63
79

query I rowsort
SELECT 54 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT - + 63 * + col2 AS col1 FROM tab0 AS cor0
----
-2079
-5166
-63

query I rowsort
SELECT - - 65 * + col1 AS col2 FROM tab1 cor0
----
1690
650
845

query I rowsort
SELECT 82 * + col2 AS col2 FROM tab1 AS cor0
----
4428
4674
7872

query I rowsort
SELECT cor1.col0 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL ( - col0 ) + col2 AS col0 FROM tab2
----
-41
-52
20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3258
SELECT DISTINCT CAST( - 33 AS SIGNED ) + col2 + + col2 AS col1 FROM tab0
----
-31
131
33

skipif mysql # not compatible
query I rowsort label-3258
SELECT DISTINCT CAST ( - 33 AS INTEGER ) + col2 + + col2 AS col1 FROM tab0
----
-31
131
33

query I rowsort
SELECT - + 41 * col0 + + col2 FROM tab2 AS cor0
----
-260
-3172
-3201

query I rowsort
SELECT + 24 * + col1 AS col0 FROM tab0 AS cor0
----
2064
2184
2328

onlyif mysql # use DIV operator for integer division
query I rowsort label-3261
SELECT ALL - col1 + - col0 DIV + 83 AS col1 FROM tab0 cor0
----
-86
-92
-97

skipif mysql # not compatible
query I rowsort label-3261
SELECT ALL - col1 + - col0 / + 83 AS col1 FROM tab0 cor0
----
-86
-92
-97

query I rowsort
SELECT 56 AS col2 FROM tab0
----
56
56
56

query I rowsort
SELECT + 85 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

query I rowsort
SELECT DISTINCT - col2 * + 5 * - col0 AS col1 FROM tab2
----
10140
15010
945

onlyif mysql # use DIV operator for integer division
query I rowsort label-3265
SELECT - col0 DIV + 40 + - 26 FROM tab2 AS cor0
----
-26
-27
-27

skipif mysql # not compatible
query I rowsort label-3265
SELECT - col0 / + 40 + - 26 FROM tab2 AS cor0
----
-26
-27
-27

query I rowsort
SELECT ALL + 94 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to a4d239626cf0546ac1b2f57bb8407089

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - ( - col2 ) col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT col0 + 31 AS col1 FROM tab2 AS cor0
----
109
110
38

query I rowsort
SELECT 71 + col2 FROM tab2
----
109
97
98

query I rowsort
SELECT col1 * tab1.col0 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT - ( col1 * 38 ) FROM tab2
----
-1178
-2242
-646

query I rowsort
SELECT + - 62 AS col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to d2579f9395350eda865ff3a2d38a74f6

query I rowsort
SELECT - col1 + col0 AS col2 FROM tab2
----
-24
19
62

query I rowsort
SELECT col0 + + 82 FROM tab2 AS cor0
----
160
161
89

query I rowsort
SELECT DISTINCT col1 * 35 AS col1 FROM tab0 AS cor0
----
3010
3185
3395

onlyif mysql # use DIV operator for integer division
query I rowsort label-3276
SELECT ALL + col1 DIV + col1 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3276
SELECT ALL + col1 / + col1 AS col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT - col1 * ( col0 + - cor0.col0 ) AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 79 * - col2 FROM tab1 AS cor0
----
-4266
-4503
-7584

query I rowsort
SELECT DISTINCT + ( + cor0.col1 ) * - cor0.col0 + 38 AS col2 FROM tab1, tab1 AS cor0
----
-1002
-40
-602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3280
SELECT col1 DIV + col2 AS col0 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-3280
SELECT col1 / + col2 AS col0 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT ALL - 59 AS col1 FROM tab2 cor0
----
-59
-59
-59

query I rowsort
SELECT + + 32 * col2 FROM tab1 AS cor0
----
1728
1824
3072

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 AS cor0, tab2 AS cor1, tab1 cor2
----
972 values hashing to 75a813ebd5ec5ec2e67a66d0593ff763

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 35 col2 FROM tab0, tab2 AS cor0
----
35

query I rowsort
SELECT ALL ( + col0 ) + ( - cor0.col1 ) AS col1 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT + ( col2 ) * + col1 + col1 AS col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT col1 - - cor0.col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL ( - col0 ) * + 32 + cor0.col2 AS col2 FROM tab1 AS cor0
----
-1991
-2464
-42

query I rowsort
SELECT col1 * + col2 + + 90 AS col0 FROM tab1 AS cor0
----
1338
1494
660

onlyif mysql # use DIV operator for integer division
query I rowsort label-3290
SELECT ALL - 17 DIV + col0 + ( col2 ) * - col2 * col0 FROM tab1
----
-207936
-737280
-8753

skipif mysql # not compatible
query I rowsort label-3290
SELECT ALL - 17 / + col0 + ( col2 ) * - col2 * col0 FROM tab1
----
-207936
-737280
-8753

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3291
SELECT ALL col1 + + col0 * - CAST( col1 AS SIGNED ) AS col2 FROM tab0
----
-1978
-3298
-8008

skipif mysql # not compatible
query I rowsort label-3291
SELECT ALL col1 + + col0 * - CAST ( col1 AS INTEGER ) AS col2 FROM tab0
----
-1978
-3298
-8008

query IIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2, tab2 AS cor0 WHERE ( NULL ) <= NULL
----

query I rowsort
SELECT ALL tab0.col1 * col2 + col2 AS col2 FROM tab0
----
2871
7544
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3294
SELECT - 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-3294
SELECT - col2 * + 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-3295
SELECT ALL - cor0.col1 * + CAST( 48 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-1248
-480
-624

skipif mysql # not compatible
query I rowsort label-3295
SELECT ALL - cor0.col1 * + CAST ( 48 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-1248
-480
-624

query I rowsort
SELECT + col0 + - col1 + ( 49 ) FROM tab0
----
-13
-13
47

query I rowsort
SELECT col2 + col0 * - col1 AS col0 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL + ( - cor0.col1 ) + - col0 AS col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT ( 61 ) FROM tab1 AS cor0
----
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-3300
SELECT DISTINCT - 47 DIV 59 + col0 * - col0 FROM tab1 AS cor0
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-3300
SELECT DISTINCT - 47 / 59 + col0 * - col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL - + 9 + col2 FROM tab2 AS cor0
----
17
18
29

query I rowsort
SELECT - + col1 * + col2 * - col2 FROM tab2 AS cor0
----
22599
24548
39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-3303
SELECT ALL + col1 DIV - col0 AS col2 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-3303
SELECT ALL + col1 / - col0 AS col2 FROM tab2 AS cor0
----
-4
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3304
SELECT + CAST( - cor0.col1 AS SIGNED ) AS col0 FROM tab0 cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3304
SELECT + CAST ( - cor0.col1 AS INTEGER ) AS col0 FROM tab0 cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * - ( col1 ) + col0 col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT - col1 * - 82 + col2 AS col2 FROM tab0 AS cor0
----
7085
7544
7955

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + ( 69 ) * + col2 col0 FROM tab2
----
-105846
-44574
-57753

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + 29 col2 FROM tab0
----
-57
-62
-68

onlyif mysql # use DIV operator for integer division
query I rowsort label-3309
SELECT tab2.col2 DIV + ( col0 ) + - col2 AS col0 FROM tab2
----
-24
-26
-38

skipif mysql # not compatible
query I rowsort label-3309
SELECT tab2.col2 / + ( col0 ) + - col2 AS col0 FROM tab2
----
-24
-26
-38

query I rowsort
SELECT ALL + tab2.col2 + 72 + 88 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to d43d1bd46f4e2308daad72deaba52478

query I rowsort
SELECT ALL - 63 AS col2 FROM tab0, tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
27 values hashing to fc0b533c2773a0a802e1fc8317dcebf2

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2
----
3645 values hashing to 2270901c73a658a63f841c68db8155ba

query I rowsort
SELECT ( + 52 + - cor0.col2 ) FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to c1f0f0f6ba3e746d2ac1c7860817d938

query I rowsort
SELECT - - 91 * col1 FROM tab0 AS cor0
----
7826
8281
8827

query I rowsort
SELECT DISTINCT + - col1 * ( + col2 ) FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - 10 * + 69 FROM tab0 AS cor0
----
-690
-690
-690

query I rowsort
SELECT ALL - ( - 71 ) FROM tab2 AS cor0
----
71
71
71

query I rowsort
SELECT ALL ( 5 ) FROM tab0 AS cor0
----
5
5
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3319
SELECT DISTINCT 95 DIV col0 AS col2 FROM tab0 cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-3319
SELECT DISTINCT 95 / col0 AS col2 FROM tab0 cor0
----
1
2
3

query I rowsort
SELECT - ( + cor0.col1 ) + + cor0.col1 * - cor0.col0 AS col0 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT - tab2.col1 + col0 AS col0 FROM tab2
----
-24
19
62

query I rowsort
SELECT + ( 17 ) AS col1 FROM tab0
----
17
17
17

query I rowsort
SELECT col2 - + col0 AS col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT col2 + 41 + col2 AS col1 FROM tab2
----
117
93
95

query I rowsort
SELECT ALL + tab1.col2 * col0 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT col0 - - col1 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT + + col1 * - cor0.col2 + ( + 2 ) FROM tab2 AS cor0
----
-1532
-644
-835

query I rowsort
SELECT - 71 + + col0 FROM tab0 AS cor0
----
-36
-47
18

query I rowsort
SELECT DISTINCT - - 17 AS col2 FROM tab0 AS cor0
----
17

query I rowsort
SELECT DISTINCT + - 63 FROM tab0 cor0
----
-63

query I rowsort
SELECT ALL + 23 * + col1 FROM tab1 AS cor0
----
230
299
598

onlyif mysql # use DIV operator for integer division
query I rowsort label-3332
SELECT col1 + col0 DIV cor0.col1 + + 73 FROM tab1 AS cor0
----
89
92
99

skipif mysql # not compatible
query I rowsort label-3332
SELECT col1 + col0 / cor0.col1 + + 73 FROM tab1 AS cor0
----
89
92
99

query I rowsort
SELECT + 58 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
117
75
89

query I rowsort
SELECT ALL cor0.col0 * col1 + ( + ( - col1 ) ) AS col1 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT - 2 + col1 FROM tab0 AS cor0
----
84
89
95

query I rowsort
SELECT DISTINCT - ( - col2 ) + - col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT - - cor0.col2 + col1 * - col1 * 25 FROM tab0 AS cor0
----
-184867
-206943
-235224

query I rowsort
SELECT ALL + + 91 * + col0 + + col1 AS col2 FROM tab1 AS cor0
----
299
5834
7293

query I rowsort
SELECT DISTINCT - 13 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
-13

query I rowsort
SELECT ALL + col2 * + ( + col2 ) FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - col2 * 1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL col0 * tab2.col0 AS col2 FROM tab2
----
49
6084
6241

query I rowsort
SELECT DISTINCT + cor0.col1 + + 34 FROM tab1 AS cor0
----
44
47
60

query I rowsort
SELECT ALL + + col1 * col1 * col0 + col1 - col1 AS col2 FROM tab1 cor0
----
13520
2028
6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * + col0 col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + col1 + + col1 * + col0 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL + col0 * + ( - col2 ) - col1 FROM tab0 cor0
----
-132
-7389
-878

query I rowsort
SELECT ALL + col0 + + col0 * - 21 FROM tab1 AS cor0
----
-1280
-1600
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - 74 col1 FROM tab0 AS cor0
----
-41
-73
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-3350
SELECT - cor0.col1 DIV - col0 + col0 AS col1 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-3350
SELECT - cor0.col1 / - col0 + col0 AS col1 FROM tab1 AS cor0
----
11
64
80

query I rowsort
SELECT + + col2 + cor0.col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL - col0 + + ( col1 ) FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT DISTINCT cor0.col1 + col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - cor0.col1 + + col0 * col2 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT DISTINCT + ( col1 ) + col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - 23 - + 46 * col1 FROM tab2 cor0
----
-1449
-2737
-805

query I rowsort
SELECT ALL - + ( ( + col0 ) ) FROM tab1 AS cor0
----
-3
-64
-80

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0 AS cor2, tab2 AS cor3
----
3645 values hashing to 773bb916e463ebc075d701108532badb

query I rowsort
SELECT col2 * cor0.col0 + - col0 FROM tab1 cor0
----
159
3584
7600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3360
SELECT + col1 - CAST( NULL AS SIGNED ) * col2 col1 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3360
SELECT + col1 - CAST ( NULL AS INTEGER ) * col2 col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3361
SELECT - col1 DIV - CAST( + col2 + col1 AS SIGNED ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3361
SELECT - col1 / - CAST ( + col2 + col1 AS INTEGER ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - + col2 * col1 AS col2 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT + - col2 + - col2 * 38 AS col1 FROM tab0 AS cor0
----
-1287
-3198
-39

query I rowsort
SELECT col2 * - col0 + 42 FROM tab0
----
-7256
-750
7

query I rowsort
SELECT - tab1.col1 + - col1 * - col0 AS col0 FROM tab1
----
1027
52
630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 22 col2 FROM tab2, tab1 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT - col0 - cor0.col2 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT + col1 * + col2 + col2 AS col0 FROM tab2
----
1560
684
864

query I rowsort
SELECT DISTINCT - col1 + ( - col2 ) + + col1 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT ALL col0 * - col2 * + col0 AS col2 FROM tab1 AS cor0
----
-233472
-486
-614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-3371
SELECT ALL + tab1.col1 DIV 45 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3371
SELECT ALL + tab1.col1 / 45 AS col1 FROM tab1
----
0
0
0

query IIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0 CROSS JOIN tab0 cor1
----
243 values hashing to 3a953203ced079e372111d61dbd9e35f

query I rowsort
SELECT - 89 AS col1 FROM tab0
----
-89
-89
-89

query I rowsort
SELECT - 39 AS col1 FROM tab2, tab0 cor0, tab1, tab1 AS cor1
----
81 values hashing to fe3460a5258986a2d83e1ea75c1e275e

query I rowsort
SELECT ALL - 19 AS col0 FROM tab0
----
-19
-19
-19

query I rowsort
SELECT DISTINCT + 58 * + col1 + cor0.col0 AS col0 FROM tab0 AS cor0
----
5012
5367
5661

onlyif mysql # use DIV operator for integer division
query I rowsort label-3377
SELECT 80 * - col1 + + col0 DIV - 13 AS col2 FROM tab2 AS cor0
----
-1366
-2480
-4726

skipif mysql # not compatible
query I rowsort label-3377
SELECT 80 * - col1 + + col0 / - 13 AS col2 FROM tab2 AS cor0
----
-1366
-2480
-4726

query I rowsort
SELECT DISTINCT + 80 * - col0 + ( 11 ) * col0 FROM tab2 cor0
----
-483
-5382
-5451

query I rowsort
SELECT + ( col1 ) * col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT 72 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT + cor0.col2 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT - + 45 + col2 * - 33 FROM tab1 AS cor0
----
-1827
-1926
-3213

query I rowsort
SELECT DISTINCT tab2.col1 FROM tab2, tab0 cor0
----
17
31
59

query I rowsort
SELECT ALL - ( - col2 ) - col0 AS col1 FROM tab1
----
-7
16
51

query I rowsort
SELECT + ( col0 ) * - col1 * col1 AS col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-3386
SELECT - 18 * + col2 DIV + col2 AS col1 FROM tab1 AS cor0
----
-18
-18
-18

skipif mysql # not compatible
query I rowsort label-3386
SELECT - 18 * + col2 / + col2 AS col1 FROM tab1 AS cor0
----
-18
-18
-18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - col1 col0 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT cor0.col2 + - col1 AS col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL + - col0 * col1 * 61 AS col0 FROM tab0 AS cor0
----
-125904
-207095
-494039

query I rowsort
SELECT + 58 * + col2 AS col0 FROM tab1 AS cor0
----
3132
3306
5568

query I rowsort
SELECT - - col2 * col0 + col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT + - col0 + - col1 * + col1 * 63 AS col1 FROM tab2 AS cor0
----
-18286
-219381
-60550

query I rowsort
SELECT DISTINCT 57 * + col2 FROM tab2
----
1482
1539
2166

query I rowsort
SELECT ALL - tab2.col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT ALL tab1.col2 + + col0 AS col1 FROM tab1
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3396
SELECT ALL + col2 + - col1 DIV + col2 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3396
SELECT ALL + col2 + - col1 / + col2 FROM tab1
----
54
57
96

query I rowsort
SELECT + col2 * col2 - cor0.col2 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT + col2 * - col0 + + col1 * - col1 * - col1 + col2 FROM tab1
----
-2591
-5387
17468

query I rowsort
SELECT ALL col1 + tab0.col1 AS col0 FROM tab0
----
172
182
194

onlyif mysql # use DIV operator for integer division
query I rowsort label-3400
SELECT ALL + cor0.col1 + - col1 DIV col1 AS col1 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-3400
SELECT ALL + cor0.col1 + - col1 / col1 AS col1 FROM tab1 AS cor0
----
12
25
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 * + col0 col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT cor0.col1 * - col1 AS col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL - cor0.col1 * col2 AS col2 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT col0 + + col0 * col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT - col2 + col1 - col2 AS col0 FROM tab1 cor0
----
-104
-179
-82

query I rowsort
SELECT ALL + col0 + - cor0.col1 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT - - col2 * col2 * col2 + - col2 - + cor0.col1 * col2 FROM tab0 AS cor0
----
-97
33066
543824

query I rowsort
SELECT DISTINCT col2 * col1 + + col2 - col1 FROM tab1 AS cor0
----
1331
1432
617

query I rowsort
SELECT - - col1 * col2 + - col0 AS col0 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT DISTINCT + col1 + + col1 * + col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL + col1 * + col0 - col0 AS col0 FROM tab1 AS cor0
----
576
75
960

onlyif mysql # use DIV operator for integer division
query I rowsort label-3412
SELECT col2 DIV + col1 + + col0 * col0 - + col1 * - col0 AS col2 FROM tab2
----
10686
266
7586

skipif mysql # not compatible
query I rowsort label-3412
SELECT col2 / + col1 + + col0 * col0 - + col1 * - col0 AS col2 FROM tab2
----
10686
266
7586

query I rowsort
SELECT DISTINCT + col2 * col2 * tab0.col0 - + col2 FROM tab0
----
26103
34
598354

onlyif mysql # use DIV operator for integer division
query I rowsort label-3414
SELECT DISTINCT - tab0.col2 DIV col2 - + col2 * tab0.col2 FROM tab0
----
-1090
-2
-6725

skipif mysql # not compatible
query I rowsort label-3414
SELECT DISTINCT - tab0.col2 / col2 - + col2 * tab0.col2 FROM tab0
----
-1090
-2
-6725

query I rowsort
SELECT ALL col1 - col2 * col0 AS col1 FROM tab1
----
-136
-3638
-7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col2 col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + 43 * col1 AS col0 FROM tab0 AS cor0
----
3698
3913
4171

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 * col0 col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT + + col2 + - col0 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 95 * col0 col0 FROM tab0 AS cor0
----
-2280
-3325
-8455

query I rowsort
SELECT + - col0 + + col0 * - col0 FROM tab2 AS cor0
----
-56
-6162
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-3422
SELECT - + col2 DIV - col0 FROM tab1 cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-3422
SELECT - + col2 / - col0 FROM tab1 cor0
----
0
1
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-3423
SELECT + col0 + - cor0.col2 DIV cor0.col0 AS col1 FROM tab0 AS cor0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-3423
SELECT + col0 + - cor0.col2 / cor0.col0 AS col1 FROM tab0 AS cor0
----
23
35
89

query I rowsort
SELECT 31 + cor0.col1 * - col1 FROM tab2 AS cor0
----
-258
-3450
-930

query I rowsort
SELECT - 64 AS col2 FROM tab1
----
-64
-64
-64

query I rowsort
SELECT DISTINCT 5 * cor0.col2 + cor0.col2 FROM tab0 AS cor0
----
198
492
6

query I rowsort
SELECT ALL - cor0.col0 + - col1 * col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT - 80 FROM tab2 cor0
----
-80
-80
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - ( + col0 ) * cor0.col0 col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL - ( - col0 ) * - col0 + col1 * cor0.col2 FROM tab1 AS cor0
----
-3526
-5152
1395

onlyif mysql # use DIV operator for integer division
query I rowsort label-3431
SELECT ALL + 93 DIV - col1 AS col2 FROM tab2
----
-1
-3
-5

skipif mysql # not compatible
query I rowsort label-3431
SELECT ALL + 93 / - col1 AS col2 FROM tab2
----
-1
-3
-5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col1 * col2 * col0 col1 FROM tab0
----
3492
664209
68198

query III rowsort
SELECT ALL * FROM tab1 WHERE + col1 <> NULL
----

query I rowsort
SELECT - col2 * - col1 + col0 - col0 * col1 AS col1 FROM tab2
----
-2990
-618
627

query I rowsort
SELECT - col0 + tab2.col0 + + col1 * col1 * + col0 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT ALL + col2 * - col1 + - tab2.col2 * - tab2.col1 * - tab2.col1 FROM tab2
----
-11628
-26784
-92040

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL NOT IN ( col0 * - col2 + - col0 )
----

query I rowsort
SELECT DISTINCT - col2 / - tab2.col2 - + col0 FROM tab2 WHERE NULL > NULL
----

query I rowsort
SELECT - tab0.col1 + col2 + tab0.col2 FROM tab0
----
-20
-95
73

query I rowsort
SELECT ALL col1 + + col1 FROM tab0 WHERE NOT ( NULL ) IN ( - col1 )
----

query I rowsort
SELECT DISTINCT col0 + - col0 AS col0 FROM tab2
----
0

query I rowsort
SELECT tab1.col0 + - col0 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 * + tab1.col0 - + col2 * - col0 FROM tab1
----
0

query I rowsort
SELECT - tab0.col2 * tab0.col2 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT col0 + col1 * - tab0.col0 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT tab0.col0 + tab0.col1 AS col1 FROM tab0
----
110
132
180

query I rowsort
SELECT ALL - col0 + - col0 FROM tab1 WHERE NULL NOT BETWEEN - col0 AND ( NULL )
----

query I rowsort
SELECT ALL tab2.col0 FROM tab2 WHERE NOT NULL BETWEEN NULL AND NULL
----

query III rowsort
SELECT * FROM tab0 WHERE NOT col1 / col0 > NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col1 col0 FROM tab0 WHERE NULL > NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - col2 * - col1 col1 FROM tab2
----
1475
629
806

onlyif mysql # use DIV operator for integer division
query I rowsort label-3452
SELECT ALL col2 DIV - col1 + + col1 * - col2 * + tab1.col0 FROM tab1
----
-36485
-4214
-99847

skipif mysql # not compatible
query I rowsort label-3452
SELECT ALL col2 / - col1 + + col1 * - col2 * + tab1.col0 FROM tab1
----
-36485
-4214
-99847

query I rowsort
SELECT - col1 + tab1.col1 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT col2 + + tab0.col0 AS col2 FROM tab0
----
171
36
57

query I rowsort
SELECT - cor0.col2 * - cor0.col2 - - col0 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT ALL + col1 * cor0.col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT col2 * col1 + col2 * col1 FROM tab2 AS cor0
----
1292
1674
3068

query I rowsort
SELECT DISTINCT col1 - + col1 * col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT ALL - cor0.col1 * col2 + + col1 AS col0 FROM tab2 cor0
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-3460
SELECT ALL + col0 + + col0 DIV + col2 FROM tab1 AS cor0
----
3
65
80

skipif mysql # not compatible
query I rowsort label-3460
SELECT ALL + col0 + + col0 / + col2 FROM tab1 AS cor0
----
3
65
80

query I rowsort
SELECT + col1 + - tab0.col1 * - col1 AS col2 FROM tab0
----
7482
8372
9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 + - col2 col0 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT - cor0.col1 + - col0 * col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-207946
-737293
-8774

query I rowsort
SELECT DISTINCT - col1 + col2 * - col2 AS col2 FROM tab1 AS cor0
----
-2942
-3259
-9229

query I rowsort
SELECT - col1 * + col1 + - col0 FROM tab2 AS cor0
----
-3559
-368
-968

query I rowsort
SELECT ALL col0 FROM tab0 AS cor0 WHERE NOT col0 * col0 + col1 * - col1 = ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * - col1 + - col2 col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT DISTINCT + + 67 * + col1 FROM tab0 cor0
----
5762
6097
6499

query I rowsort
SELECT - col1 * + 12 FROM tab0 AS cor0
----
-1032
-1092
-1164

query I rowsort
SELECT DISTINCT col2 * 59 AS col2 FROM tab1
----
3186
3363
5664

query I rowsort
SELECT + 93 * 35 * - col2 FROM tab0 AS cor0
----
-107415
-266910
-3255

query I rowsort
SELECT - - 16 * + ( col0 ) AS col0 FROM tab0 AS cor0
----
1424
384
560

query I rowsort
SELECT + + 18 + col1 * - col1 AS col1 FROM tab1 cor0
----
-151
-658
-82

query I rowsort
SELECT - col1 + cor0.col0 * - col0 AS col2 FROM tab1 cor0
----
-35
-4106
-6413

query I rowsort
SELECT col0 + ( col1 ) * ( - 23 + tab1.col2 ) FROM tab1
----
1029
404
809

query I rowsort
SELECT - col1 * - col0 + cor0.col0 * + col2 + + col0 * + 6 AS col1 FROM tab0 AS cor0
----
15931
3000
3640

query I rowsort
SELECT - cor0.col2 * - 88 + col1 AS col1 FROM tab2 AS cor0
----
2347
2407
3361

query I rowsort
SELECT - - 1 * cor0.col2 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

onlyif mysql # use DIV operator for integer division
query I rowsort label-3479
SELECT DISTINCT - col0 DIV ( 36 ) FROM tab2
----
-2
0

skipif mysql # not compatible
query I rowsort label-3479
SELECT DISTINCT - col0 / ( 36 ) FROM tab2
----
-2
0

query I rowsort
SELECT - tab1.col2 * + tab1.col2 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT col2 * + col1 * 39 AS col1 FROM tab0
----
110682
291018
3783

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3482
SELECT + col1 * CAST( - col0 AS SIGNED ) FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-3482
SELECT + col1 * CAST ( - col0 AS INTEGER ) FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - + col2 * ( - 93 ) AS col0 FROM tab0 AS cor0
----
3069
7626
93

query I rowsort
SELECT - tab1.col2 * 41 * cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 0e7c190be52eb88cd8201d8f2f80ec90

query I rowsort
SELECT col0 * ( + col2 ) AS col0 FROM tab1
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3486
SELECT col0 * col2 + 31 DIV col0 FROM tab0 AS cor0
----
35
7298
793

skipif mysql # not compatible
query I rowsort label-3486
SELECT col0 * col2 + 31 / col0 FROM tab0 AS cor0
----
35
7298
793

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + tab2.col2 ) col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col0 + - col2 * - col1 + col0 col1 FROM tab2 AS cor0
----
6966
7696
893

query I rowsort
SELECT ALL 47 + 39 FROM tab0
----
86
86
86

query I rowsort
SELECT - ( - ( col0 ) ) AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT ALL ( - col0 * col1 ) + col0 AS col0 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT ALL + col1 + col0 AS col1 FROM tab0
----
110
132
180

query I rowsort
SELECT ALL - col2 + - tab1.col2 FROM tab1
----
-108
-114
-192

query I rowsort
SELECT - + col0 * + col1 + + col0 * - cor0.col0 + - col0 * - col0 * col2 FROM tab2 AS cor0
----
1057
147498
229574

query I rowsort
SELECT DISTINCT + 52 FROM tab2, tab0 AS cor0
----
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3496
SELECT CAST( NULL AS SIGNED ) * 87 + col2 + col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3496
SELECT CAST ( NULL AS INTEGER ) * 87 + col2 + col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3497
SELECT + + CAST( - col0 AS SIGNED ) + + col0 + - cor0.col1 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-3497
SELECT + + CAST ( - col0 AS INTEGER ) + + col0 + - cor0.col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - col1 + 62 FROM tab0 cor0
----
-24
-29
-35

query I rowsort
SELECT DISTINCT - 63 * col2 AS col2 FROM tab0
----
-2079
-5166
-63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 95 + + col1 col2 FROM tab2 AS cor0
----
112
126
154

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 88 col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

query I rowsort
SELECT - - col2 * - 15 * - 22 + - col1 FROM tab0 cor0
----
10804
233
26969

query I rowsort
SELECT - + cor0.col2 * 42 * cor0.col0 - col1 FROM tab1 AS cor0
----
-153226
-322573
-6830

query I rowsort
SELECT + col2 + 41 * + cor0.col1 FROM tab2 AS cor0
----
1298
2445
735

query I rowsort
SELECT DISTINCT - - col2 * - cor0.col0 + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT ALL + col2 + + col2 * col1 AS col0 FROM tab2
----
1560
684
864

query I rowsort
SELECT ALL - 40 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 01aad4539198a6509248e086869f90a6

query I rowsort
SELECT + col1 * - cor0.col1 * col0 + col0 AS col0 FROM tab2 AS cor0
----
-22752
-271440
-6720

query I rowsort
SELECT + col2 * 15 FROM tab2 cor0
----
390
405
570

query I rowsort
SELECT - cor0.col2 * - ( - 33 ) FROM tab1 AS cor0
----
-1782
-1881
-3168

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3511
SELECT ALL + col2 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3511
SELECT ALL + col2 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 77 * + 96 AS col1 FROM tab1, tab0 AS cor0, tab1 cor1
----
-7392

query I rowsort
SELECT DISTINCT + - 42 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
-42

query I rowsort
SELECT DISTINCT + tab1.col0 AS col0 FROM tab1, tab0 AS cor0
----
3
64
80

query I rowsort
SELECT ALL - + col2 + + ( + col2 ) * col0 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT DISTINCT + col0 * col2 + 2 * - col1 FROM tab0 AS cor0
----
-159
620
7116

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0, tab2 AS cor1, tab2, tab1 cor2
----
3645 values hashing to 1b06ddc48fd89ff2b1df6d82072316da

query I rowsort
SELECT ALL col0 * - tab0.col2 AS col1 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + 41 - - 14 FROM tab1, tab1 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3520
SELECT ALL - col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3520
SELECT ALL - col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 * ( + 59 ) FROM tab0 AS cor0
----
5074
5369
5723

query I rowsort
SELECT ALL + cor1.col1 AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 cor0, tab1 cor1, tab2 AS cor2
----
972 values hashing to e610acd60f342127e6cdba18673d9f0e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3524
SELECT ALL + + col0 + + CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-3524
SELECT ALL + + col0 + + CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL + col2 * 53 FROM tab1 AS cor0
----
2862
3021
5088

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * ( col0 ) col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL - ( - 6 ) + + col0 * - col1 AS col0 FROM tab2
----
-1337
-211
-4596

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + 18 col0 FROM tab2
----
25
96
97

query I rowsort
SELECT ALL + ( + col0 ) + + col1 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT 23 * + cor0.col2 + col0 FROM tab1 AS cor0
----
1245
1375
2288

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + cor0.col2 * col0 col2 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT 25 * - col0 + col1 * - col0 FROM tab2 AS cor0
----
-3318
-392
-6552

query I rowsort
SELECT ALL + cor0.col2 * 60 + + col1 FROM tab0 AS cor0
----
157
2066
5011

query I rowsort
SELECT DISTINCT - + col2 * + 77 - + col1 FROM tab1 AS cor0
----
-4184
-4399
-7405

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3535
SELECT + CAST( NULL AS SIGNED ) FROM tab0, tab0 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-3535
SELECT + CAST ( NULL AS INTEGER ) FROM tab0, tab0 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT + cor0.col2 - cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 3b143560120db39ddcee311b43b28291

query I rowsort
SELECT + col2 + col1 * col2 AS col2 FROM tab2 AS cor0
----
1560
684
864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 20 + 52 col0 FROM tab0 AS cor0
----
72
72
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col2 + 46 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 896cbdc25e4329fc43bd1afc74bbdddb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col2 + col2 col0 FROM tab2 cor0
----
-1508
-608
-810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3541
SELECT DISTINCT - col1 + + col2 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3541
SELECT DISTINCT - col1 + + col2 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + + ( + col0 ) AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL + ( + col1 ) + ( 87 ) AS col1 FROM tab0 AS cor0
----
173
178
184

query I rowsort
SELECT DISTINCT + 22 * col0 FROM tab2 AS cor0
----
154
1716
1738

query I rowsort
SELECT ALL + cor0.col2 + cor0.col1 + + col0 * - 70 FROM tab2 AS cor0
----
-432
-5375
-5475

query I rowsort
SELECT DISTINCT + col2 * - col0 - + cor0.col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT DISTINCT - - col0 * col2 + 79 * - 97 * - col1 FROM tab2 cor0
----
133273
237742
454145

query I rowsort
SELECT + 29 + cor0.col2 FROM tab0 AS cor0
----
111
30
62

query I rowsort
SELECT DISTINCT + col2 + - col1 * + col2 + + 25 FROM tab0 AS cor0
----
-2780
-71
-7355

query I rowsort
SELECT ALL + col0 * col0 + col0 AS col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT ALL 71 + 85 AS col0 FROM tab1
----
156
156
156

query I rowsort
SELECT + - col2 * - col1 + ( - 29 ) AS col1 FROM tab2 AS cor0
----
1505
617
808

query I rowsort
SELECT ALL col0 * col1 * 92 + + col1 AS col0 FROM tab0 AS cor0
----
189974
312437
745199

query I rowsort
SELECT DISTINCT + 25 - col2 FROM tab0 AS cor0
----
-57
-8
24

query I rowsort
SELECT ALL - 29 + + col0 AS col0 FROM tab2 AS cor0
----
-22
49
50

query I rowsort
SELECT - cor0.col1 + - cor0.col0 * 33 * col0 AS col0 FROM tab2 AS cor0
----
-1648
-200831
-205970

query I rowsort
SELECT + col0 + - col1 * ( 7 ) + col2 AS col0 FROM tab2 AS cor0
----
-183
-2
-309

query I rowsort
SELECT ALL + 90 + + col2 AS col0 FROM tab2 AS cor0
----
116
117
128

query I rowsort
SELECT 41 * + col1 * - col2 FROM tab1 AS cor0
----
-23370
-51168
-57564

query I rowsort
SELECT DISTINCT - 93 * col1 FROM tab0 AS cor0
----
-7998
-8463
-9021

query I rowsort
SELECT + col1 * tab0.col2 * + ( + col1 ) FROM tab0
----
244068
679042
9409

query I rowsort
SELECT - - 13 + col0 * col1 AS col1 FROM tab1 cor0
----
1053
653
91

query I rowsort
SELECT col1 + - col0 * 77 FROM tab1 AS cor0
----
-205
-4918
-6147

query I rowsort
SELECT DISTINCT 11 AS col1 FROM tab0
----
11

query I rowsort
SELECT 75 + - col0 * 10 AS col0 FROM tab1
----
-565
-725
45

query I rowsort
SELECT DISTINCT - 84 * - col1 FROM tab2
----
1428
2604
4956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 * + col0 col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - + cor0.col2 AS col2 FROM tab1 cor0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3569
SELECT - 54 DIV col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3569
SELECT - 54 / col2 FROM tab1 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + 44 col1 FROM tab1 AS cor0
----
-20
-36
41

query I rowsort
SELECT ALL - + col1 * - 89 FROM tab1 AS cor0
----
1157
2314
890

query I rowsort
SELECT + - col2 - - col0 AS col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT - - col2 + 52 AS col1 FROM tab1 AS cor0
----
106
109
148

query I rowsort
SELECT - ( + col1 ) + col1 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 88 * - 52 FROM tab0 AS cor0
----
-4576
-4576
-4576

query I rowsort
SELECT DISTINCT + + 78 * col2 AS col0 FROM tab1 cor0
----
4212
4446
7488

query I rowsort
SELECT DISTINCT + + col1 * + col1 AS col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT cor0.col2 + col2 AS col0 FROM tab2 AS cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - + 13 col0 FROM tab0 AS cor0
----
11
22
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( 41 ) col0 FROM tab2, tab1 AS cor0
----
41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3581
SELECT ALL col1 + - ( 5 ) * tab1.col0 * CAST( col1 AS SIGNED ) - - col2 * col0 AS col1 FROM tab1
----
-202
2493
458

skipif mysql # not compatible
query I rowsort label-3581
SELECT ALL col1 + - ( 5 ) * tab1.col0 * CAST ( col1 AS INTEGER ) - - col2 * col0 AS col1 FROM tab1
----
-202
2493
458

query I rowsort
SELECT - tab2.col1 * + 72 AS col2 FROM tab2
----
-1224
-2232
-4248

query I rowsort
SELECT col0 - - 99 * - col0 FROM tab1
----
-294
-6272
-7840

query I rowsort
SELECT - tab1.col0 + tab1.col1 + ( col1 ) FROM tab1
----
-44
-54
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-3585
SELECT DISTINCT - 30 + - col1 DIV col0 FROM tab0
----
-31
-32
-33

skipif mysql # not compatible
query I rowsort label-3585
SELECT DISTINCT - 30 + - col1 / col0 FROM tab0
----
-31
-32
-33

query I rowsort
SELECT 45 FROM tab0, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

query I rowsort
SELECT DISTINCT col2 + - tab0.col1 + + col0 * col2 AS col1 FROM tab0
----
-61
7289
739

query I rowsort
SELECT col1 * + col2 + - col1 + - 27 * ( tab2.col1 ) AS col2 FROM tab2
----
-118
-31
170

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 44 * col2 col2 FROM tab1 AS cor0
----
-2376
-2508
-4224

query I rowsort
SELECT DISTINCT + col1 * col1 AS col1 FROM tab2 cor0
----
289
3481
961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3591
SELECT - - CAST( NULL AS DECIMAL ) * 26 * - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3591
SELECT - - CAST ( NULL AS REAL ) * 26 * - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * + 25 FROM tab2
----
175
1950
1975

query I rowsort
SELECT col1 * ( + ( - col1 ) ) FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT - col1 + col0 * + ( col0 ) AS col1 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT DISTINCT + col0 * col1 + + col1 AS col1 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3596
SELECT ( cor0.col2 ) * + cor0.col2 + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3596
SELECT ( cor0.col2 ) * + cor0.col2 + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 + - 30 FROM tab0 cor0
----
-29
3
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( 18 ) col1 FROM tab1 AS cor0
----
18
18
18

query I rowsort
SELECT - cor0.col0 + + 6 FROM tab2 AS cor0
----
-1
-72
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-3600
SELECT - col1 * col0 DIV + ( - col2 ) - + col1 AS col2 FROM tab0 AS cor0
----
-24
3298
7

skipif mysql # not compatible
query I rowsort label-3600
SELECT - col1 * col0 / + ( - col2 ) - + col1 AS col2 FROM tab0 AS cor0
----
-24
3298
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3601
SELECT ALL cor0.col1 * col2 + - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3601
SELECT ALL cor0.col1 * col2 + - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 - + col2 AS col2 FROM tab2 AS cor0
----
-104
-117
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 72 col2 FROM tab0 AS cor0
----
-72
-72
-72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3604
SELECT + col0 * + col1 - CAST( NULL AS DECIMAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3604
SELECT + col0 * + col1 - CAST ( NULL AS REAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 99 FROM tab2
----
99
99
99

query I rowsort
SELECT - 75 + col1 FROM tab2 AS cor0
----
-16
-44
-58

query I rowsort
SELECT + - 13 * - col1 FROM tab0 cor0
----
1118
1183
1261

query I rowsort
SELECT - 10 + col2 + cor0.col0 AS col1 FROM tab0 AS cor0
----
161
26
47

query I rowsort
SELECT + 76 * col1 - 85 * col0 AS col1 FROM tab2 AS cor0
----
-2146
-5423
1761

query I rowsort
SELECT + 3 + - col1 * - 17 AS col2 FROM tab1 AS cor0
----
173
224
445

query I rowsort
SELECT col1 * - col2 - col2 * + col1 FROM tab2 AS cor0
----
-1292
-1674
-3068

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + ( col1 + - col1 ) col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - col0 + + col1 * ( 52 + - tab0.col1 ) * + 32 AS col2 FROM tab0
----
-113657
-139715
-93592

query I rowsort
SELECT + tab1.col2 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3615
SELECT col0 + - CAST( - col0 AS SIGNED ) - + col2 FROM tab2 AS cor0
----
-13
120
130

skipif mysql # not compatible
query I rowsort label-3615
SELECT col0 + - CAST ( - col0 AS INTEGER ) - + col2 FROM tab2 AS cor0
----
-13
120
130

query I rowsort
SELECT ALL col1 + - ( + cor0.col0 ) AS col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + + col0 * + col1 + - 38 * col0 AS col2 FROM tab1 AS cor0
----
-1792
-2000
-36

query I rowsort
SELECT + col2 + - ( + cor0.col0 ) FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - cor0.col1 + - col1 AS col0 FROM tab1 cor0
----
-20
-26
-52

query I rowsort
SELECT DISTINCT + + col1 * col1 * + col0 AS col2 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT - col1 + + col0 * + col2 AS col0 FROM tab0 cor0
----
-62
706
7207

query I rowsort
SELECT DISTINCT - col1 * 69 - - 85 FROM tab1 AS cor0
----
-1709
-605
-812

query I rowsort
SELECT DISTINCT - + col0 * + col1 * + ( col0 ) FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT - col0 * + col0 + - col2 - - col2 * + col0 * col1 FROM tab2 AS cor0
----
113542
44755
5783

query I rowsort
SELECT ALL + col1 * col0 AS col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT - col1 + - 46 - 96 FROM tab1 AS cor0
----
-152
-155
-168

query I rowsort
SELECT + col0 + - cor0.col2 + + 60 * + col1 * - col1 AS col0 FROM tab2 AS cor0
----
-17299
-208808
-57680

query I rowsort
SELECT - col2 * col0 + - col2 + + col2 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - ( col0 ) col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL cor0.col1 * cor0.col1 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 9708a433b981d9b5fd095bfe2ea45aea

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3631
SELECT DISTINCT CAST( NULL AS DECIMAL ) + 93 * + col1 * - CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3631
SELECT DISTINCT CAST ( NULL AS REAL ) + 93 * + col1 * - CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL

query I rowsort
SELECT DISTINCT - col2 - col2 AS col0 FROM tab1 AS cor0
----
-108
-114
-192

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3633
SELECT ALL + + CAST( NULL AS SIGNED ) - cor0.col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3633
SELECT ALL + + CAST ( NULL AS INTEGER ) - cor0.col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - 48 FROM tab0 AS cor0
----
-48

query I rowsort
SELECT - + col0 * - col2 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - 73 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
1898
1971
2774

query I rowsort
SELECT DISTINCT ( + col1 ) * - col1 FROM tab0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-3638
SELECT + col1 * col1 + ( col2 ) * + tab1.col0 DIV tab1.col0 FROM tab1
----
157
265
730

skipif mysql # not compatible
query I rowsort label-3638
SELECT + col1 * col1 + ( col2 ) * + tab1.col0 / tab1.col0 FROM tab1
----
157
265
730

query I rowsort
SELECT DISTINCT 43 * + col1 * col2 FROM tab0
----
122034
320866
4171

query I rowsort
SELECT DISTINCT + ( 22 ) FROM tab0 AS cor0
----
22

query I rowsort
SELECT + col1 + ( - col0 ) + col2 FROM tab1 AS cor0
----
29
3
77

query I rowsort
SELECT DISTINCT + cor0.col2 + 23 AS col0 FROM tab0 AS cor0
----
105
24
56

query I rowsort
SELECT DISTINCT - + cor0.col2 * 84 * col0 AS col1 FROM tab2 AS cor0
----
-15876
-170352
-252168

query I rowsort
SELECT - + col2 + 39 * col2 AS col2 FROM tab1 AS cor0
----
2052
2166
3648

onlyif mysql # use DIV operator for integer division
query I rowsort label-3645
SELECT + + ( col1 ) DIV - col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3645
SELECT + + ( col1 ) / - col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col1 + + ( + col1 ) FROM tab2
----
118
34
62

query I rowsort
SELECT DISTINCT - ( - col2 ) AS col0 FROM tab1
----
54
57
96

query I rowsort
SELECT + 38 FROM tab0
----
38
38
38

query I rowsort
SELECT cor0.col2 * - 88 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 18d5e44248faf39019b0f7d86024557d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 22 * - tab2.col0 col1 FROM tab2
----
-123
-1657
-1721

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 9 col2 FROM tab2
----
9

query I rowsort
SELECT DISTINCT - 90 AS col0 FROM tab2, tab0 AS cor0
----
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 19 col1 FROM tab1
----
19

query I rowsort
SELECT ALL 61 * - tab2.col0 AS col0 FROM tab2
----
-427
-4758
-4819

query I rowsort
SELECT DISTINCT col0 + ( cor0.col0 ) AS col2 FROM tab0 cor0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-3656
SELECT ALL - col1 * 18 DIV - col0 + - cor0.col2 FROM tab1 cor0
----
-55
-94
102

skipif mysql # not compatible
query I rowsort label-3656
SELECT ALL - col1 * 18 / - col0 + - cor0.col2 FROM tab1 cor0
----
-55
-94
102

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + col2 AS REAL ) AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL + col0 * - col1 AS col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT 91 AS col0 FROM tab2, tab1, tab1 AS cor0
----
91

query I rowsort
SELECT DISTINCT - ( 75 ) FROM tab2
----
-75

query I rowsort
SELECT DISTINCT ( col0 + col0 * 79 ) FROM tab0
----
1920
2800
7120

onlyif mysql # use DIV operator for integer division
query I rowsort label-3662
SELECT ( col2 ) DIV - col0 AS col2 FROM tab2
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-3662
SELECT ( col2 ) / - col0 AS col2 FROM tab2
----
-3
0
0

query I rowsort
SELECT 37 + + col0 - - tab0.col0 FROM tab0
----
107
215
85

query I rowsort
SELECT col0 * col2 * col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT DISTINCT 42 - + tab1.col1 AS col2 FROM tab1
----
16
29
32

query I rowsort
SELECT + tab0.col2 * tab0.col2 + col0 AS col2 FROM tab0
----
1113
36
6813

skipif mysql # not compatible
query I rowsort
SELECT + col2 * - col0 * CAST ( + col2 AS REAL ) - col2 FROM tab2
----
-114114
-5130
-52754

query I rowsort
SELECT - col1 + 48 FROM tab1 AS cor0
----
22
35
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3669
SELECT + - cor0.col2 + - col1 DIV + ( col1 ) FROM tab0 AS cor0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-3669
SELECT + - cor0.col2 + - col1 / + ( col1 ) FROM tab0 AS cor0
----
-2
-34
-83

query I rowsort
SELECT + cor0.col0 + col2 * - col1 * col1 FROM tab1 AS cor0
----
-16144
-36501
-5636

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3671
SELECT + col0 * CAST( cor0.col2 AS SIGNED ) + - col2 AS col1 FROM tab2 AS cor0
----
162
2002
2964

skipif mysql # not compatible
query I rowsort label-3671
SELECT + col0 * CAST ( cor0.col2 AS INTEGER ) + - col2 AS col1 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT DISTINCT - cor0.col1 * - col1 + col2 AS col2 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT + col0 + + cor0.col1 + col0 AS col1 FROM tab0 AS cor0
----
134
167
269

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3674
SELECT DISTINCT col1 * + CAST( col2 AS SIGNED ) col0 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3674
SELECT DISTINCT col1 * + CAST ( col2 AS INTEGER ) col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - col0 * col2 * - col0 FROM tab2 cor0
----
1323
158184
237158

query I rowsort
SELECT col2 * cor0.col1 + + col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL col0 * 50 - col0 FROM tab2 cor0
----
343
3822
3871

query I rowsort
SELECT DISTINCT - col0 + - 95 AS col0 FROM tab2 AS cor0
----
-102
-173
-174

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3679
SELECT DISTINCT col0 + + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3679
SELECT DISTINCT col0 + + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3680
SELECT col0 + CAST( - 40 + col1 AS SIGNED ) * 29 FROM tab1 AS cor0
----
-403
-703
-806

skipif mysql # not compatible
query I rowsort label-3680
SELECT col0 + CAST ( - 40 + col1 AS INTEGER ) * 29 FROM tab1 AS cor0
----
-403
-703
-806

query I rowsort
SELECT ALL + col1 + 6 * + col1 - + col1 FROM tab2 AS cor0
----
102
186
354

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 33 col2 FROM tab2
----
1254
858
891

query I rowsort
SELECT + 61 FROM tab1, tab0 AS cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

query I rowsort
SELECT DISTINCT col1 * col0 * tab0.col2 + col0 AS col2 FROM tab0
----
3430
664207
68136

query I rowsort
SELECT - - col0 * - 62 + - col2 FROM tab0 AS cor0
----
-1521
-2171
-5600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3686
SELECT ALL + col1 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3686
SELECT ALL + col1 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 + col1 * col1 FROM tab2 cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT + + col0 * col2 + + col2 AS col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL + - cor0.col0 * - 99 AS col0 FROM tab1 AS cor0
----
297
6336
7920

query I rowsort
SELECT DISTINCT tab2.col1 * - 71 * 12 FROM tab2
----
-14484
-26412
-50268

query I rowsort
SELECT - 83 FROM tab0, tab2 cor0, tab0 AS cor1
----
27 values hashing to 77a48ad722db122f51d5ef36604ad843

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3692
SELECT DISTINCT - col2 * + CAST( + col1 AS SIGNED ) FROM tab1 AS cor0
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-3692
SELECT DISTINCT - col2 * + CAST ( + col1 AS INTEGER ) FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + - col2 * + col0 + col0 * col1 AS col0 FROM tab2 AS cor0
----
-1659
2574
28

query I rowsort
SELECT + cor0.col0 + ( + col2 ) * ( + col2 ) FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT ALL + + col0 + 1 FROM tab2 cor0
----
79
8
80

query I rowsort
SELECT DISTINCT + 30 + ( col2 ) FROM tab2 AS cor0
----
56
57
68

query I rowsort
SELECT ALL + - 44 * cor0.col2 + col1 AS col2 FROM tab2 cor0
----
-1085
-1157
-1655

query I rowsort
SELECT ALL + 3 AS col0 FROM tab0 AS cor0
----
3
3
3

query I rowsort
SELECT DISTINCT + - col1 * - cor0.col0 + col2 * col1 FROM tab1 AS cor0
----
1210
1482
2288

query I rowsort
SELECT + + 7 FROM tab0 AS cor0
----
7
7
7

query I rowsort
SELECT ALL + - col0 + + 1 AS col2 FROM tab2 cor0
----
-6
-77
-78

query I rowsort
SELECT + + col0 * col1 + - col1 AS col2 FROM tab0 cor0
----
1978
3298
8008

query I rowsort
SELECT ALL + 44 * + ( + col1 ) + + cor0.col2 AS col1 FROM tab0 AS cor0
----
3817
4086
4269

query I rowsort
SELECT ALL col1 + + 31 AS col1 FROM tab2
----
48
62
90

query I rowsort
SELECT + 60 + cor0.col2 AS col0 FROM tab1 AS cor0
----
114
117
156

query I rowsort
SELECT cor0.col1 * col1 + col1 AS col2 FROM tab2 AS cor0
----
306
3540
992

onlyif mysql # use DIV operator for integer division
query I rowsort label-3707
SELECT ALL + col1 * + col1 DIV + col1 AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3707
SELECT ALL + col1 * + col1 / + col1 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - + 71 * col0 AS col1 FROM tab2 AS cor0
----
-497
-5538
-5609

query I rowsort
SELECT ALL - 47 AS col1 FROM tab0 AS cor0
----
-47
-47
-47

query I rowsort
SELECT + + col2 * - cor0.col2 + + col0 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT ALL - 93 * + col2 FROM tab1 AS cor0
----
-5022
-5301
-8928

query I rowsort
SELECT ALL - 92 * col1 AS col1 FROM tab1 AS cor0
----
-1196
-2392
-920

query I rowsort
SELECT + 77 + col1 * - cor0.col0 * + 71 FROM tab1 AS cor0
----
-45363
-5461
-73763

query I rowsort
SELECT ALL - + 10 AS col0 FROM tab1 AS cor0
----
-10
-10
-10

query I rowsort
SELECT ALL - 72 AS col2 FROM tab0 cor0
----
-72
-72
-72

query I rowsort
SELECT ALL + cor0.col0 * + col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - 2 + - col2 FROM tab1 AS cor0
----
-56
-59
-98

query I rowsort
SELECT + col0 + + col1 * + col1 AS col1 FROM tab1
----
164
249
679

onlyif mysql # use DIV operator for integer division
query I rowsort label-3719
SELECT + 36 + col1 DIV col2 AS col0 FROM tab0
----
133
37
38

skipif mysql # not compatible
query I rowsort label-3719
SELECT + 36 + col1 / col2 AS col0 FROM tab0
----
133
37
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3720
SELECT DISTINCT ( cor0.col2 ) * + CAST( col1 AS SIGNED ) + col2 FROM tab2 AS cor0
----
1560
684
864

skipif mysql # not compatible
query I rowsort label-3720
SELECT DISTINCT ( cor0.col2 ) * + CAST ( col1 AS INTEGER ) + col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL 21 * - col2 FROM tab2 AS cor0
----
-546
-567
-798

query I rowsort
SELECT DISTINCT + - 32 FROM tab1 cor0
----
-32

onlyif mysql # use DIV operator for integer division
query I rowsort label-3723
SELECT ALL + col0 + + col2 * col1 DIV + 51 AS col0 FROM tab1 AS cor0
----
104
30
75

skipif mysql # not compatible
query I rowsort label-3723
SELECT ALL + col0 + + col2 * col1 / + 51 AS col0 FROM tab1 AS cor0
----
104
30
75

query I rowsort
SELECT DISTINCT - ( + col0 ) * col2 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-3725
SELECT - - ( col0 ) DIV - cor0.col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3725
SELECT - - ( col0 ) / - cor0.col2 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT 97 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

query I rowsort
SELECT - col1 + 37 AS col0 FROM tab0 cor0
----
-49
-54
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-3728
SELECT ALL - col2 DIV - tab2.col1 - - col2 * - tab2.col1 FROM tab2
----
-1534
-644
-837

skipif mysql # not compatible
query I rowsort label-3728
SELECT ALL - col2 / - tab2.col1 - - col2 * - tab2.col1 FROM tab2
----
-1534
-644
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

onlyif mysql # use DIV operator for integer division
query I rowsort label-3730
SELECT DISTINCT - tab0.col0 DIV col1 AS col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-3730
SELECT DISTINCT - tab0.col0 / col1 AS col1 FROM tab0
----
0

query I rowsort
SELECT ALL + cor0.col1 + + 67 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 5e164dbaaf2ae1211d6899dcefebc58b

query I rowsort
SELECT + ( + col0 ) * + col1 + - col2 * col1 * ( - col0 ) FROM tab1 cor0
----
100880
37120
4290

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col0 ) * + ( 97 ) col0 FROM tab1 AS cor0
----
291
6208
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 - - col2 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 22 + - cor0.col1 * 35 FROM tab1 AS cor0
----
-372
-477
-932

query I rowsort
SELECT ( col0 * + col2 + col1 * col2 ) AS col2 FROM tab0
----
132
14760
3630

query I rowsort
SELECT ALL + 14 + col2 FROM tab0
----
15
47
96

query I rowsort
SELECT - col2 + cor0.col0 + col0 AS col0 FROM tab0 AS cor0
----
15
69
96

query I rowsort
SELECT + 41 * + col2 FROM tab0 AS cor0
----
1353
3362
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + col1 col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT DISTINCT 45 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 - col2 * - col1 col0 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3743
SELECT + - cor0.col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3743
SELECT + - cor0.col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 * + ( + cor0.col0 ) + - cor0.col2 AS col1 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT + col0 + ( col1 ) * cor0.col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT DISTINCT + col0 * + 79 FROM tab1
----
237
5056
6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3747
SELECT DISTINCT + col0 * - CAST( NULL AS SIGNED ) AS col1 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3747
SELECT DISTINCT + col0 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 cor0
----
NULL

query I rowsort
SELECT + col1 + col0 * - col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT - ( 68 ) * + col2 FROM tab1
----
-3672
-3876
-6528

query I rowsort
SELECT DISTINCT 73 * tab2.col1 AS col0 FROM tab2, tab1 AS cor0
----
1241
2263
4307

query I rowsort
SELECT DISTINCT - - 35 * - col0 * - col1 AS col1 FROM tab2 AS cor0
----
161070
47005
7595

query I rowsort
SELECT DISTINCT + 87 AS col2 FROM tab0, tab2 AS cor0
----
87

query I rowsort
SELECT ALL 59 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT + col1 + - ( col1 ) * + cor0.col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL + - col0 * col0 + col1 - col2 FROM tab0 AS cor0
----
-1129
-523
-7912

query I rowsort
SELECT col0 + 2 * col0 FROM tab2 AS cor0
----
21
234
237

onlyif mysql # use DIV operator for integer division
query I rowsort label-3757
SELECT DISTINCT + + col2 + - col2 DIV col2 AS col0 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-3757
SELECT DISTINCT + + col2 + - col2 / col2 AS col0 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT DISTINCT - + ( - col2 ) * col1 + col2 AS col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + - 25 * col1 AS col2 FROM tab0 AS cor0
----
-2150
-2275
-2425

onlyif mysql # use DIV operator for integer division
query I rowsort label-3760
SELECT + 82 * col2 DIV col0 FROM tab2 AS cor0
----
27
316
39

skipif mysql # not compatible
query I rowsort label-3760
SELECT + 82 * col2 / col0 FROM tab2 AS cor0
----
27
316
39

query I rowsort
SELECT ALL - ( - col2 ) * - col0 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 col2 FROM tab0, tab2 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to a5b6acb471910ea4ad7f31cae3b818f7

query I rowsort
SELECT DISTINCT - 21 + col1 * col0 FROM tab2 cor0
----
1322
196
4581

query I rowsort
SELECT - + 71 * + col0 AS col2 FROM tab1 cor0
----
-213
-4544
-5680

query I rowsort
SELECT col0 * col1 + col2 AS col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT - ( col0 ) + + col2 AS col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT 57 AS col2 FROM tab0, tab2 cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT - col1 + + ( col1 * col0 ) + - col1 * - 13 FROM tab1 AS cor0
----
1196
390
760

query I rowsort
SELECT col1 + col1 + cor0.col1 FROM tab1 AS cor0
----
30
39
78

query I rowsort
SELECT - col0 + cor0.col2 + cor0.col2 * col0 FROM tab2 AS cor0
----
1976
209
2961

query I rowsort
SELECT ALL + col0 + + 28 + - col0 * col2 FROM tab2 AS cor0
----
-154
-1922
-2895

query I rowsort
SELECT DISTINCT + - cor0.col0 AS col2 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL - - 1 FROM tab1, tab0, tab1 AS cor0, tab2
----
81 values hashing to 2a004dce2d308bae163576f54ee1a3fc

onlyif mysql # use DIV operator for integer division
query I rowsort label-3774
SELECT ALL - col2 DIV cor0.col1 - - col2 FROM tab2 AS cor0
----
26
27
36

skipif mysql # not compatible
query I rowsort label-3774
SELECT ALL - col2 / cor0.col1 - - col2 FROM tab2 AS cor0
----
26
27
36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3775
SELECT DISTINCT + - CAST( col1 AS SIGNED ) * col0 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-3775
SELECT DISTINCT + - CAST ( col1 AS INTEGER ) * col0 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL 46 AS col1 FROM tab1 AS cor0
----
46
46
46

query I rowsort
SELECT ( cor0.col2 ) * col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - col2 * col2 * 49 AS col1 FROM tab0
----
-329476
-49
-53361

query I rowsort
SELECT ALL + tab0.col1 * col0 + col2 FROM tab0
----
2097
3396
8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-3780
SELECT ALL col1 * + tab1.col1 DIV col1 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3780
SELECT ALL col1 * + tab1.col1 / col1 FROM tab1
----
10
13
26

query I rowsort
SELECT - 29 AS col1 FROM tab0, tab2 cor0
----
9 values hashing to 0cc9ddad93fc783055518ae4b6be054b

query I rowsort
SELECT DISTINCT cor0.col0 * tab2.col1 FROM tab2, tab2 AS cor0, tab2 cor1
----
9 values hashing to 7e3c34e781801a3db37bc76b9d86ef8c

query I rowsort
SELECT ALL col0 * + col0 + col2 * col2 AS col2 FROM tab1 AS cor0
----
15616
2925
7345

query I rowsort
SELECT ALL + - col1 + col1 * col2 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-3785
SELECT ALL 73 * col2 + - cor0.col1 DIV col0 AS col1 FROM tab1 AS cor0
----
3934
4161
7008

skipif mysql # not compatible
query I rowsort label-3785
SELECT ALL 73 * col2 + - cor0.col1 / col0 AS col1 FROM tab1 AS cor0
----
3934
4161
7008

query I rowsort
SELECT - 19 * col1 FROM tab0 cor0
----
-1634
-1729
-1843

query I rowsort
SELECT DISTINCT - col2 + + col2 * + col2 * col0 AS col2 FROM tab2
----
114038
5076
52702

query I rowsort
SELECT - ( + col2 ) + col1 AS col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL + 97 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
38
66
80

query I rowsort
SELECT 47 * + col0 + + col1 AS col0 FROM tab1 AS cor0
----
167
3018
3773

query I rowsort
SELECT ALL - 35 AS col0 FROM tab2 AS cor0
----
-35
-35
-35

query I rowsort
SELECT + + cor0.col2 * col0 - - col0 AS col2 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT + col0 * col1 - + col0 AS col2 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT ALL + + 94 AS col2 FROM tab1 cor0
----
94
94
94

query I rowsort
SELECT ALL + + 34 AS col1 FROM tab0 AS cor0
----
34
34
34

query I rowsort
SELECT ALL + - 66 * col2 AS col1 FROM tab2 AS cor0
----
-1716
-1782
-2508

query I rowsort
SELECT DISTINCT + + 10 * col0 FROM tab0 AS cor0
----
240
350
890

onlyif mysql # use DIV operator for integer division
query I rowsort label-3798
SELECT col1 + col1 DIV col2 AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3798
SELECT col1 + col1 / col2 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL col2 + + cor0.col0 FROM tab0 AS cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col1 + col1 col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT + 66 + col1 FROM tab1
----
76
79
92

query I rowsort
SELECT DISTINCT + - 30 AS col0 FROM tab1 AS cor0
----
-30

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( col1 AS REAL ) col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - 33 FROM tab1 cor0
----
-33

query I rowsort
SELECT - tab0.col2 * + tab0.col0 * + col2 + col0 AS col0 FROM tab0
----
-26112
-598347
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3806
SELECT - col1 DIV - 9 FROM tab1 AS cor0
----
1
1
2

skipif mysql # not compatible
query I rowsort label-3806
SELECT - col1 / - 9 FROM tab1 AS cor0
----
1
1
2

query I rowsort
SELECT + 48 + 25 FROM tab1
----
73
73
73

query I rowsort
SELECT ALL - col1 - + col2 AS col0 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT tab2.col0 + + tab2.col1 + + col0 FROM tab2
----
175
215
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-3810
SELECT DISTINCT - + cor0.col0 DIV col1 + col1 AS col0 FROM tab1 AS cor0
----
26
4
7

skipif mysql # not compatible
query I rowsort label-3810
SELECT DISTINCT - + cor0.col0 / col1 + col1 AS col0 FROM tab1 AS cor0
----
26
4
7

query I rowsort
SELECT + ( + tab2.col1 ) * - col0 - col1 FROM tab2
----
-1360
-248
-4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-3812
SELECT DISTINCT + col2 * 24 DIV tab0.col0 - + col2 * - col0 FROM tab0
----
35
7320
825

skipif mysql # not compatible
query I rowsort label-3812
SELECT DISTINCT + col2 * 24 / tab0.col0 - + col2 * - col0 FROM tab0
----
35
7320
825

query I rowsort
SELECT 46 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT DISTINCT - col2 - - tab1.col2 FROM tab1
----
0

query I rowsort
SELECT DISTINCT col1 * col1 * - col1 - col2 * - col0 AS col1 FROM tab0
----
-635264
-746273
-912638

query I rowsort
SELECT col0 * 35 FROM tab2
----
245
2730
2765

query I rowsort
SELECT - 12 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to e698dd57d3aac30af14ce35da434bb45

query I rowsort
SELECT ALL + - col2 + + 72 * col0 AS col1 FROM tab0 AS cor0
----
1695
2519
6326

onlyif mysql # use DIV operator for integer division
query I rowsort label-3819
SELECT - col0 DIV + col1 AS col0 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-3819
SELECT - col0 / + col1 AS col0 FROM tab2
----
-1
-4
0

query I rowsort
SELECT + col0 + 30 - - col2 FROM tab0
----
201
66
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col0 ) + tab2.col1 col0 FROM tab2
----
137
38
96

query I rowsort
SELECT ( 61 ) + + tab0.col0 * - col0 + col0 FROM tab0
----
-1129
-491
-7771

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3823
SELECT ALL CAST( NULL AS SIGNED ) + + tab2.col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3823
SELECT ALL CAST ( NULL AS INTEGER ) + + tab2.col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * cor0.col0 col0 FROM tab2 cor0
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-3825
SELECT ALL - tab1.col0 * col1 DIV - col1 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3825
SELECT ALL - tab1.col0 * col1 / - col1 FROM tab1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col2 col2 FROM tab0
----
171
36
57

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL = - col2 * col0 * col0 + + col1 * + col0
----

query I rowsort
SELECT DISTINCT - col2 AS col1 FROM tab1 WHERE NOT NULL IN ( col0 + col2 )
----

query I rowsort
SELECT DISTINCT + col1 + + col0 AS col2 FROM tab1 WHERE NULL IN ( + col1 / col1 + tab1.col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col0 col1 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT - col2 * - tab0.col0 * col1 FROM tab0 WHERE NOT ( col0 ) NOT IN ( tab0.col0 )
----
3395
664118
68112

query I rowsort
SELECT DISTINCT - col1 * + tab0.col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL col2 * col2 * + tab1.col1 AS col2 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT col1 * col0 + col2 * col1 AS col1 FROM tab0
----
15561
3492
4902

query I rowsort
SELECT + col1 + col2 * col2 FROM tab2 AS cor0
----
1461
735
760

onlyif mysql # use DIV operator for integer division
query I rowsort label-3836
SELECT + col2 DIV tab1.col2 - - col0 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-3836
SELECT + col2 / tab1.col2 - - col0 FROM tab1
----
4
65
81

query I rowsort
SELECT - cor0.col2 FROM tab0 cor0 WHERE col2 NOT IN ( + col0 + col0 * col0 * + col1 )
----
-1
-33
-82

query I rowsort
SELECT col0 + + col2 * tab2.col1 FROM tab2
----
1612
725
844

query I rowsort
SELECT + col0 * col2 + tab2.col1 * col1 FROM tab2
----
1150
3291
5509

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col0 col1 FROM tab0
----
110
132
180

query I rowsort
SELECT + - col2 + col1 * - cor0.col1 AS col2 FROM tab0 AS cor0
----
-7429
-8363
-9410

query I rowsort
SELECT ALL + col2 * - cor0.col1 - + col2 AS col2 FROM tab0 AS cor0
----
-2871
-7544
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3843
SELECT DISTINCT + - col2 DIV - col2 + - col1 AS col1 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-3843
SELECT DISTINCT + - col2 / - col2 + - col1 AS col1 FROM tab0 AS cor0
----
-85
-90
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3844
SELECT DISTINCT - + col2 * col1 + col0 * col1 DIV - col0 AS col0 FROM tab1 AS cor0
----
-1261
-1430
-580

skipif mysql # not compatible
query I rowsort label-3844
SELECT DISTINCT - + col2 * col1 + col0 * col1 / - col0 AS col0 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT col2 + cor0.col2 * col1 AS col0 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT + col2 * - col2 + - cor0.col0 * - col0 AS col0 FROM tab1 AS cor0
----
-2816
-2907
847

query I rowsort
SELECT ALL col1 + - col1 * - col2 AS col2 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT + cor0.col0 * + col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL - col2 * - cor0.col2 + - col0 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT DISTINCT - - col1 * cor0.col2 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - - col2 + col2 + col2 * - col0 FROM tab1 AS cor0
----
-3534
-54
-7488

query I rowsort
SELECT DISTINCT tab2.col1 * col2 * col0 AS col0 FROM tab2
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-3853
SELECT DISTINCT + col0 * col2 DIV - col1 AS col0 FROM tab0 AS cor0
----
-80
-9
0

skipif mysql # not compatible
query I rowsort label-3853
SELECT DISTINCT + col0 * col2 / - col1 AS col0 FROM tab0 AS cor0
----
-80
-9
0

query I rowsort
SELECT ALL col1 * + col2 * + col1 AS col2 FROM tab2 AS cor0
----
10982
25947
90506

onlyif mysql # use DIV operator for integer division
query I rowsort label-3855
SELECT ALL - col2 + + col1 DIV + cor0.col0 AS col2 FROM tab0 AS cor0
----
-30
-81
1

skipif mysql # not compatible
query I rowsort label-3855
SELECT ALL - col2 + + col1 / + cor0.col0 AS col2 FROM tab0 AS cor0
----
-30
-81
1

query I rowsort
SELECT col1 * + col2 + col0 FROM tab0 cor0
----
132
2862
7551

query I rowsort
SELECT cor0.col2 * + col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT col2 - - tab2.col0 * 60 FROM tab2
----
447
4706
4778

onlyif mysql # use DIV operator for integer division
query I rowsort label-3859
SELECT + col1 * 57 - - col1 * col0 DIV - 46 AS col1 FROM tab2
----
1763
3263
940

skipif mysql # not compatible
query I rowsort label-3859
SELECT + col1 * 57 - - col1 * col0 / - 46 AS col1 FROM tab2
----
1763
3263
940

onlyif mysql # use DIV operator for integer division
query I rowsort label-3860
SELECT + - col1 + ( col0 ) DIV cor0.col0 AS col0 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-3860
SELECT + - col1 + ( col0 ) / cor0.col0 AS col0 FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT + cor0.col1 + + ( 1 ) * col2 AS col2 FROM tab2 cor0
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3862
SELECT DISTINCT - + cor0.col2 * col1 - col0 / CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3862
SELECT DISTINCT - + cor0.col2 * col1 - col0 / CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - - ( col0 ) + col2 * - col2 AS col2 FROM tab0 cor0
----
-1065
-6635
34

query I rowsort
SELECT + 17 * - cor0.col1 + col2 FROM tab0 AS cor0
----
-1429
-1465
-1648

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3865
SELECT ALL CAST( 85 AS SIGNED ) + col0 AS col2 FROM tab0 AS cor0
----
109
120
174

skipif mysql # not compatible
query I rowsort label-3865
SELECT ALL CAST ( 85 AS INTEGER ) + col0 AS col2 FROM tab0 AS cor0
----
109
120
174

query I rowsort
SELECT + 50 * + col0 + - ( + col2 * col0 ) + - ( + 40 ) FROM tab1 AS cor0
----
-3720
-488
-52

query I rowsort
SELECT + - col1 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + col0 + + col2 * + 69 FROM tab2 AS cor0
----
1870
1872
2701

query I rowsort
SELECT col0 + col0 + - 89 AS col2 FROM tab1 AS cor0
----
-83
39
71

query I rowsort
SELECT - col2 * + 16 FROM tab2
----
-416
-432
-608

query I rowsort
SELECT col0 + - 45 AS col1 FROM tab0
----
-10
-21
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-3872
SELECT DISTINCT col0 DIV 21 AS col1 FROM tab0
----
1
4

skipif mysql # not compatible
query I rowsort label-3872
SELECT DISTINCT col0 / 21 AS col1 FROM tab0
----
1
4

query I rowsort
SELECT DISTINCT + 40 * col2 FROM tab2
----
1040
1080
1520

onlyif mysql # use DIV operator for integer division
query I rowsort label-3874
SELECT - col0 + + col0 DIV ( col0 * + col1 ) FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-3874
SELECT - col0 + + col0 / ( col0 * + col1 ) FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3875
SELECT + - col1 + cor0.col1 + + col0 DIV + col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3875
SELECT + - col1 + cor0.col1 + + col0 / + col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT - cor0.col0 * col0 + ( - col2 ) FROM tab2 AS cor0
----
-6110
-6279
-76

query I rowsort
SELECT ALL - col2 * col0 * col1 AS col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT + col2 * - 2 * + col0 AS col0 FROM tab0 AS cor0
----
-14596
-1584
-70

query I rowsort
SELECT DISTINCT col2 * + ( + col0 ) FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-3880
SELECT + - cor0.col0 + + col0 DIV col2 AS col1 FROM tab1 AS cor0
----
-3
-63
-80

skipif mysql # not compatible
query I rowsort label-3880
SELECT + - cor0.col0 + + col0 / col2 AS col1 FROM tab1 AS cor0
----
-3
-63
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 26 col2 FROM tab1
----
26
26
26

query I rowsort
SELECT ALL + 3 + tab0.col0 AS col2 FROM tab0
----
27
38
92

query I rowsort
SELECT ALL - col1 + - col2 AS col0 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT DISTINCT - col2 * col1 + + ( ( - col2 ) ) FROM tab2
----
-1560
-684
-864

onlyif mysql # use DIV operator for integer division
query I rowsort label-3885
SELECT ALL + col1 + + col2 * col2 DIV col2 FROM tab1
----
109
67
80

skipif mysql # not compatible
query I rowsort label-3885
SELECT ALL + col1 + + col2 * col2 / col2 FROM tab1
----
109
67
80

query I rowsort
SELECT ALL + col0 + - col2 AS col2 FROM tab1
----
-16
-51
7

query I rowsort
SELECT DISTINCT + col0 * + ( col1 ) + + col0 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT - col1 * 29 AS col1 FROM tab2 AS cor0
----
-1711
-493
-899

query I rowsort
SELECT ALL - + cor0.col1 + + 30 * col2 FROM tab1 AS cor0
----
1594
1700
2867

query I rowsort
SELECT DISTINCT col1 * ( + col2 ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + col0 * 67 + ( + cor0.col1 ) AS col1 FROM tab1 AS cor0
----
227
4298
5373

query I rowsort
SELECT col1 + 52 AS col0 FROM tab1 cor0
----
62
65
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3893
SELECT ( 8 ) * col0 + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3893
SELECT ( 8 ) * col0 + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( - 60 ) + + cor0.col0 AS col2 FROM tab0 AS cor0
----
149
84
95

query I rowsort
SELECT - 60 AS col0 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to 1a0b29f8e6f82c54623a665ba4af8fd1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 59 + - col1 col0 FROM tab0 AS cor0
----
-27
-32
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3897
SELECT DISTINCT col1 * col2 + ( col2 ) DIV - col2 + - col2 * cor0.col0 * - col1 FROM tab0 AS cor0
----
3491
671579
70949

skipif mysql # not compatible
query I rowsort label-3897
SELECT DISTINCT col1 * col2 + ( col2 ) / - col2 + - col2 * cor0.col0 * - col1 FROM tab0 AS cor0
----
3491
671579
70949

query I rowsort
SELECT - + 20 AS col2 FROM tab0 AS cor0
----
-20
-20
-20

query I rowsort
SELECT + col1 * + col1 + col1 AS col0 FROM tab2 cor0
----
306
3540
992

query I rowsort
SELECT DISTINCT 93 AS col1 FROM tab1, tab0 AS cor0
----
93

query I rowsort
SELECT - col1 * + col2 * + col1 FROM tab2
----
-10982
-25947
-90506

onlyif mysql # use DIV operator for integer division
query I rowsort label-3902
SELECT DISTINCT col2 DIV - col1 + - col1 * col2 FROM tab1 cor0
----
-1255
-1406
-575

skipif mysql # not compatible
query I rowsort label-3902
SELECT DISTINCT col2 / - col1 + - col1 * col2 FROM tab1 cor0
----
-1255
-1406
-575

query I rowsort
SELECT + - 68 * - col2 + + ( + col1 ) * + col1 * + col2 AS col0 FROM tab0 AS cor0
----
246312
684618
9477

query I rowsort
SELECT ALL - + col2 * - col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + - cor0.col1 * ( - 45 ) FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 256997fa690cf0b54b6070927cea829d

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0, tab2, tab2 cor1
----
972 values hashing to 163d7732097d78f1cda7f65c2cea5a08

query I rowsort
SELECT DISTINCT + tab0.col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col1 + - cor0.col1 * + cor0.col2 col0 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT DISTINCT col2 * cor0.col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - + cor0.col2 * cor0.col0 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - + col0 + ( - col1 ) AS col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL - ( - col1 ) + - col0 * + 87 * - col1 FROM tab0 AS cor0
----
179654
295462
704704

query I rowsort
SELECT DISTINCT - ( + col0 ) + col0 * - 97 AS col1 FROM tab1 AS cor0
----
-294
-6272
-7840

query I rowsort
SELECT + + 51 AS col1 FROM tab2 AS cor0
----
51
51
51

query I rowsort
SELECT ALL + col0 - - col2 * col2 * ( col2 ) AS col2 FROM tab0 AS cor0
----
35961
36
551457

onlyif mysql # use DIV operator for integer division
query I rowsort label-3916
SELECT DISTINCT + - col1 * col1 DIV - cor0.col2 FROM tab0 AS cor0
----
100
224
9409

skipif mysql # not compatible
query I rowsort label-3916
SELECT DISTINCT + - col1 * col1 / - cor0.col2 FROM tab0 AS cor0
----
100
224
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 * col2 + + col2 col2 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT ALL - cor0.col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT DISTINCT - - col0 + cor0.col2 * cor0.col0 * 78 + + col2 * - ( cor0.col0 * + col1 + - ( cor0.col0 ) ) FROM tab1 AS cor0
----
251776
506960
8589

query I rowsort
SELECT + ( col0 ) * col0 + col1 * - col0 * 22 FROM tab0 AS cor0
----
-170257
-44832
-73465

query I rowsort
SELECT ALL + - col2 * cor0.col0 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + + col1 * - col1 AS col2 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT + cor0.col1 + - cor0.col1 * 69 AS col2 FROM tab2 AS cor0
----
-1156
-2108
-4012

onlyif mysql # use DIV operator for integer division
query I rowsort label-3924
SELECT ALL + - col0 DIV + col0 + 92 DIV - ( - col2 ) FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3924
SELECT ALL + - col0 / + col0 + 92 / - ( - col2 ) FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT - cor0.col0 * + col1 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
-2150
-3492
-8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col0 * + 78 * col0 + col0 col2 FROM tab0 AS cor0
----
45038
618018
95682

query I rowsort
SELECT + - col2 * 96 AS col0 FROM tab1 AS cor0
----
-5184
-5472
-9216

query I rowsort
SELECT + + col2 * 81 FROM tab2 AS cor0
----
2106
2187
3078

query I rowsort
SELECT - col1 * col1 + - 38 FROM tab2 AS cor0
----
-327
-3519
-999

query I rowsort
SELECT ALL col0 * - 68 + - col2 - + cor0.col0 FROM tab2 AS cor0
----
-510
-5408
-5489

onlyif mysql # use DIV operator for integer division
query I rowsort label-3931
SELECT ALL + col2 * col0 DIV col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3931
SELECT ALL + col2 * col0 / col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - - col1 * 72 AS col1 FROM tab0 cor0
----
6192
6552
6984

query I rowsort
SELECT - col2 + 90 FROM tab2 AS cor0
----
52
63
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-3934
SELECT ALL + ( + col0 ) + + col1 DIV ( + col1 + col1 ) AS col2 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-3934
SELECT ALL + ( + col0 ) + + col1 / ( + col1 + col1 ) AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + col2 * - col0 - - col1 AS col0 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT DISTINCT - + col2 + + col0 * cor0.col1 FROM tab2 cor0
----
1305
190
4576

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3937
SELECT CAST( col2 AS SIGNED ) + - col2 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3937
SELECT CAST ( col2 AS INTEGER ) + - col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL + 80 + + cor0.col0 * cor0.col2 AS col1 FROM tab2 AS cor0
----
2108
269
3082

onlyif mysql # use DIV operator for integer division
query I rowsort label-3939
SELECT ALL + CAST( col2 AS SIGNED ) DIV + cor0.col2 + - col1 * - col2 FROM tab0 AS cor0
----
2839
7463
98

skipif mysql # not compatible
query I rowsort label-3939
SELECT ALL + CAST ( col2 AS INTEGER ) / + cor0.col2 + - col1 * - col2 FROM tab0 AS cor0
----
2839
7463
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3940
SELECT DISTINCT + col1 DIV - col1 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-3940
SELECT DISTINCT + col1 / - col1 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT DISTINCT + + col1 * + col0 - col0 AS col0 FROM tab1 cor0
----
576
75
960

query I rowsort
SELECT tab0.col0 + - ( col2 ) FROM tab0
----
-9
34
7

query I rowsort
SELECT + 5 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

query I rowsort
SELECT - col1 * ( col2 ) + - col2 * - col2 AS col0 FROM tab1
----
1512
2679
7968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3945
SELECT DISTINCT + CAST( + tab2.col1 AS SIGNED ) FROM tab2, tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-3945
SELECT DISTINCT + CAST ( + tab2.col1 AS INTEGER ) FROM tab2, tab2 AS cor0
----
17
31
59

query I rowsort
SELECT col1 * 80 + col1 * col2 AS col2 FROM tab1
----
1370
2288
3484

query I rowsort
SELECT ALL - + ( + col1 ) * - col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + col1 * 19 FROM tab1 cor0
----
190
247
494

query I rowsort
SELECT 8 * col1 FROM tab2 cor0
----
136
248
472

query I rowsort
SELECT ALL + ( 18 ) * cor0.col1 * 46 FROM tab1 AS cor0
----
10764
21528
8280

query I rowsort
SELECT DISTINCT - 36 + 98 * - col0 AS col2 FROM tab0 cor0
----
-2388
-3466
-8758

query I rowsort
SELECT - - cor0.col2 * + col2 * + col1 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT DISTINCT - + 70 AS col2 FROM tab1 AS cor0
----
-70

query I rowsort
SELECT ALL + cor0.col2 * - 15 FROM tab1, tab2 AS cor0
----
9 values hashing to 7a84a10c22c3ce827b7343a92d1e9372

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 62 col2 FROM tab1
----
72
75
88

query I rowsort
SELECT ALL - 48 - + 80 AS col1 FROM tab2 AS cor0
----
-128
-128
-128

query I rowsort
SELECT DISTINCT 90 * col2 AS col0 FROM tab1
----
4860
5130
8640

onlyif mysql # use DIV operator for integer division
query I rowsort label-3958
SELECT ALL - col1 DIV - col0 + + ( ( + tab1.col1 ) ) DIV + 21 col2 FROM tab1
----
0
0
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3958
SELECT ALL - col1 / - col0 + + ( ( + tab1.col1 ) ) / + 21 col2 FROM tab1
----
0
0
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col0 + + col0 col1 FROM tab0
----
178
48
70

query I rowsort
SELECT + cor0.col2 + + 36 * 4 AS col1 FROM tab2 AS cor0
----
170
171
182

query I rowsort
SELECT + + col2 * col1 + + ( + col2 * col1 ) + - 97 FROM tab2 AS cor0
----
1195
1577
2971

onlyif mysql # use DIV operator for integer division
query I rowsort label-3962
SELECT 58 DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3962
SELECT 58 / col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - tab1.col2 * col2 + - col0 AS col2 FROM tab1
----
-2919
-3313
-9296

query I rowsort
SELECT ALL 74 + - col1 AS col1 FROM tab1
----
48
61
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-3965
SELECT DISTINCT col0 * + col2 * - col1 + + 30 DIV col0 FROM tab2
----
-119652
-51034
-5855

skipif mysql # not compatible
query I rowsort label-3965
SELECT DISTINCT col0 * + col2 * - col1 + + 30 / col0 FROM tab2
----
-119652
-51034
-5855

query I rowsort
SELECT 11 AS col1 FROM tab0, tab2 AS cor0, tab2 cor1
----
27 values hashing to 69116737f3f57e2e3273f6dbb04d036c

query I rowsort
SELECT ALL col2 * + ( - tab0.col2 ) FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT 27 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

query I rowsort
SELECT DISTINCT col1 * - ( - col2 ) FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL col0 * - col1 + col0 AS col2 FROM tab1 AS cor0
----
-576
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + - col0 * col2 + - col0 col1 FROM tab1 AS cor0
----
-168
-3776
-7840

query I rowsort
SELECT DISTINCT + col1 + 82 AS col0 FROM tab1 cor0
----
108
92
95

query I rowsort
SELECT ALL + - col0 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL + col1 + col2 * + 75 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
207
2585
6330

query I rowsort
SELECT DISTINCT - + col0 + - 29 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
-354
-457
-757

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 + ( ( cor0.col1 ) * - col1 ) col0 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT ALL 49 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 57 * col2 * 80 col1 FROM tab2 cor0
----
-118560
-123120
-173280

query I rowsort
SELECT + col0 * - col0 + col2 AS col2 FROM tab1 cor0
----
-4039
-6304
45

query I rowsort
SELECT 49 * - cor0.col2 + col2 AS col2 FROM tab0 cor0
----
-1584
-3936
-48

query I rowsort
SELECT - - 35 + - col2 * + cor0.col2 FROM tab2 cor0
----
-1409
-641
-694

query I rowsort
SELECT + ( cor0.col1 ) FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT + col1 * + 9 FROM tab0 cor0
----
774
819
873

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 71 col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

query I rowsort
SELECT ALL col2 + - 2 * 3 AS col2 FROM tab1 AS cor0
----
48
51
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3986
SELECT DISTINCT col1 - 48 DIV + col0 col1 FROM tab2 AS cor0
----
17
25
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3986
SELECT DISTINCT col1 - 48 / + col0 col1 FROM tab2 AS cor0
----
17
25
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * ( 10 ) col2 FROM tab2 AS cor0
----
260
270
380

query I rowsort
SELECT ALL col2 + + ( col2 ) * cor0.col0 AS col2 FROM tab0 AS cor0
----
36
7380
825

skipif mysql # not compatible
query I rowsort
SELECT - - col1 + CAST ( col1 AS INTEGER ) * + col0 * + CAST ( - col1 AS REAL ) AS col0 FROM tab1 AS cor0
----
-13507
-2002
-6390

onlyif mysql # use DIV operator for integer division
query I rowsort label-3990
SELECT ALL - col2 + - col2 DIV col2 FROM tab0 AS cor0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-3990
SELECT ALL - col2 + - col2 / col2 FROM tab0 AS cor0
----
-2
-34
-83

query I rowsort
SELECT ALL col0 * - tab0.col1 AS col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT + col1 + col1 + col0 FROM tab0
----
196
229
271

query I rowsort
SELECT tab1.col0 + + col0 + col1 FROM tab1
----
138
173
32

query I rowsort
SELECT DISTINCT tab2.col0 * col1 AS col1 FROM tab2
----
1343
217
4602

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE col1 + col2 * + col1 + + col1 >= + col2
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT DISTINCT + col2 * + col0 AS col2 FROM tab1
----
162
3648
7680

query III rowsort
SELECT ALL * FROM tab0 WHERE ( - col2 ) >= NULL
----

query I rowsort
SELECT - col2 AS col0 FROM tab0 WHERE NOT ( NULL ) NOT IN ( + col0 + - tab0.col1 )
----

query I rowsort
SELECT tab1.col2 + col2 FROM tab1 WHERE NOT NULL IN ( - col0 + col2 )
----

query I rowsort
SELECT DISTINCT - col1 * col1 * - tab0.col0 + - col0 AS col1 FROM tab0
----
177480
329280
736920

query I rowsort
SELECT ALL + col1 + col0 * + col1 AS col0 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT + tab0.col1 * tab0.col2 + - col2 AS col2 FROM tab0
----
2805
7380
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col0 col1 FROM tab1
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4004
SELECT + col2 * col2 DIV + col1 FROM tab0
----
0
12
73

skipif mysql # not compatible
query I rowsort label-4004
SELECT + col2 * col2 / + col1 FROM tab0
----
0
12
73

query I rowsort
SELECT ALL col1 * - col2 AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT ALL - col1 * col0 * - col0 AS col1 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT + col0 AS col2 FROM tab0 WHERE NOT + col2 * col0 >= col1 - + col0
----
35

query I rowsort
SELECT + col0 + - col0 * col0 AS col1 FROM tab1
----
-4032
-6
-6320

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT - col2 IN ( col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT DISTINCT col1 - + tab1.col0 AS col2 FROM tab1
----
-54
-67
23

query I rowsort
SELECT - 7 + - col0 FROM tab2 AS cor0
----
-14
-85
-86

query I rowsort
SELECT + col1 * col2 - + col0 * - tab0.col0 FROM tab0
----
1322
15383
3414

query I rowsort
SELECT col1 + - col0 * + col0 * col2 FROM tab0
----
-1128
-18922
-649431

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL BETWEEN + col1 AND NULL
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4015
SELECT ( - cor0.col1 ) + + CAST( 14 AS SIGNED ) + col0 * col1 FROM tab0 AS cor0
----
1992
3312
8022

skipif mysql # not compatible
query I rowsort label-4015
SELECT ( - cor0.col1 ) + + CAST ( 14 AS INTEGER ) + col0 * col1 FROM tab0 AS cor0
----
1992
3312
8022

query I rowsort
SELECT DISTINCT + ( + col2 ) * - 56 FROM tab1 AS cor0
----
-3024
-3192
-5376

query I rowsort
SELECT - cor0.col0 + - col0 * 56 FROM tab1 AS cor0
----
-171
-3648
-4560

query I rowsort
SELECT + col2 + + col0 + 1 AS col0 FROM tab1 AS cor0
----
122
177
58

query I rowsort
SELECT ALL 73 AS col2 FROM tab1 cor0
----
73
73
73

query I rowsort
SELECT ALL - col2 * col1 + + cor0.col1 * col1 FROM tab0 AS cor0
----
4558
819
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-4021
SELECT DISTINCT + cor0.col0 * col1 DIV - col0 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-4021
SELECT DISTINCT + cor0.col0 * col1 / - col0 AS col2 FROM tab1 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 42 * + col2 col1 FROM tab1 AS cor0
----
-2268
-2394
-4032

query I rowsort
SELECT - col2 * + col2 + cor0.col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT + - cor0.col2 + col2 * - 70 AS col2 FROM tab1 AS cor0
----
-3834
-4047
-6816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4025
SELECT + CAST( NULL AS SIGNED ) * 59 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4025
SELECT + CAST ( NULL AS INTEGER ) * 59 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 8 AS col1 FROM tab1 AS cor0
----
8
8
8

query I rowsort
SELECT col1 * + ( col0 ) AS col0 FROM tab2
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4028
SELECT + CAST( 61 AS SIGNED ) AS col0 FROM tab1
----
61
61
61

skipif mysql # not compatible
query I rowsort label-4028
SELECT + CAST ( 61 AS INTEGER ) AS col0 FROM tab1
----
61
61
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4029
SELECT DISTINCT - col2 + col1 * - CAST( NULL AS DECIMAL ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-4029
SELECT DISTINCT - col2 + col1 * - CAST ( NULL AS REAL ) FROM tab1
----
NULL

query I rowsort
SELECT col0 * col0 * + col0 + 52 * cor0.col1 FROM tab1 AS cor0
----
1379
262664
512676

query I rowsort
SELECT - + 86 + + col1 AS col1 FROM tab2 AS cor0
----
-27
-55
-69

query I rowsort
SELECT col2 + - col0 * + col0 FROM tab2
----
-22
-6058
-6203

query I rowsort
SELECT ALL + 6 * - 64 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d00de1889aeec64df46a912ac59cca67

query I rowsort
SELECT + col1 * - ( - col1 ) AS col0 FROM tab1
----
100
169
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4035
SELECT col1 / + CAST( NULL AS DECIMAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4035
SELECT col1 / + CAST ( NULL AS REAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 93 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

query I rowsort
SELECT + - col1 * - 74 + - col2 + col0 AS col1 FROM tab1 AS cor0
----
1873
747
946

query I rowsort
SELECT 93 + + col0 AS col1 FROM tab0 AS cor0
----
117
128
182

query I rowsort
SELECT DISTINCT + 45 - + col0 AS col1 FROM tab2
----
-33
-34
38

query I rowsort
SELECT ALL + col0 * col0 - tab0.col0 * 83 AS col0 FROM tab0
----
-1416
-1680
534

onlyif mysql # use DIV operator for integer division
query I rowsort label-4041
SELECT + 25 DIV 16 AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4041
SELECT + 25 / 16 AS col2 FROM tab1
----
1
1
1

query I rowsort
SELECT ALL + 69 * + 80 - col0 FROM tab1
----
5440
5456
5517

onlyif mysql # use DIV operator for integer division
query I rowsort label-4043
SELECT ALL - - col1 + - col0 DIV - col0 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-4043
SELECT ALL - - col1 + - col0 / - col0 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT DISTINCT - - col0 * - col2 * col0 AS col1 FROM tab1 cor0
----
-233472
-486
-614400

query I rowsort
SELECT ALL - ( 66 ) FROM tab1 AS cor0
----
-66
-66
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-4046
SELECT 81 DIV + col2 FROM tab0 AS cor0
----
0
2
81

skipif mysql # not compatible
query I rowsort label-4046
SELECT 81 / + col2 FROM tab0 AS cor0
----
0
2
81

query I rowsort
SELECT col2 * - ( - col0 ) FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT col2 * - cor0.col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL - col2 + col0 * - ( col2 + - cor0.col1 ) FROM tab2 AS cor0
----
-1697
1
2548

query I rowsort
SELECT DISTINCT - col0 * - 29 AS col1 FROM tab2 AS cor0
----
203
2262
2291

query I rowsort
SELECT DISTINCT - col0 * - col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT + col0 + - col0 * - ( 19 ) FROM tab0
----
1780
480
700

query I rowsort
SELECT - tab2.col2 * 94 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to fac3ae1610e9f3cd3dfc30552461cbb4

query I rowsort
SELECT DISTINCT - 65 AS col2 FROM tab0
----
-65

query I rowsort
SELECT - 82 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to f800b0aad28b82b2deb67f7045c9a45c

query I rowsort
SELECT ALL 47 AS col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

query I rowsort
SELECT ALL - tab2.col1 * 80 FROM tab2
----
-1360
-2480
-4720

query I rowsort
SELECT + 82 * 56 FROM tab2, tab1 AS cor0
----
9 values hashing to 8d8029db59dbc63d4a0c6a30111b7553

query I rowsort
SELECT ALL col2 + + 78 FROM tab0 cor0
----
111
160
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4060
SELECT + col1 * col0 DIV + cor0.col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-4060
SELECT + col1 * col0 / + cor0.col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL col1 + ( col0 ) AS col0 FROM tab2 cor0
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4062
SELECT DISTINCT + col0 * + CAST( 78 AS SIGNED ) FROM tab0 AS cor0
----
1872
2730
6942

skipif mysql # not compatible
query I rowsort label-4062
SELECT DISTINCT + col0 * + CAST ( 78 AS INTEGER ) FROM tab0 AS cor0
----
1872
2730
6942

query I rowsort
SELECT - - col1 * 48 FROM tab2 AS cor0
----
1488
2832
816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4064
SELECT DISTINCT + col0 * - CAST( - ( col0 ) AS SIGNED ) + cor0.col0 AS col0 FROM tab0 AS cor0
----
1260
600
8010

skipif mysql # not compatible
query I rowsort label-4064
SELECT DISTINCT + col0 * - CAST ( - ( col0 ) AS INTEGER ) + cor0.col0 AS col0 FROM tab0 AS cor0
----
1260
600
8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4065
SELECT DISTINCT - CAST( NULL AS SIGNED ) + 74 * + col2 AS col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-4065
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + 74 * + col2 AS col1 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT + 36 + 84 * col0 * + col2 FROM tab0
----
2976
613068
66564

query I rowsort
SELECT - col2 * - ( col2 ) - + 45 FROM tab1
----
2871
3204
9171

query I rowsort
SELECT DISTINCT + 15 + col2 AS col2 FROM tab1 AS cor0
----
111
69
72

query I rowsort
SELECT DISTINCT ( - ( - cor0.col2 ) ) - - 28 FROM tab2 cor0
----
54
55
66

query I rowsort
SELECT DISTINCT - col2 + + col1 - - col1 AS col0 FROM tab1 AS cor0
----
-2
-37
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-4071
SELECT col1 * col1 - col1 DIV 86 AS col1 FROM tab1 cor0
----
100
169
676

skipif mysql # not compatible
query I rowsort label-4071
SELECT col1 * col1 - col1 / 86 AS col1 FROM tab1 cor0
----
100
169
676

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
243 values hashing to 3e8bd9634a3f5947d8becd5f5799bb7f

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0 CROSS JOIN tab0, tab1 cor1, tab2 AS cor2, tab0 AS cor3
----
13122 values hashing to 01f7a0553637ef49dd1cb634feec6dbf

query I rowsort
SELECT ALL - - cor0.col2 + + col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT - col2 * - col0 + - cor0.col2 FROM tab2 cor0
----
162
2002
2964

query I rowsort
SELECT DISTINCT - col2 * col1 * - 99 FROM tab1 AS cor0
----
123552
138996
56430

onlyif mysql # use DIV operator for integer division
query I rowsort label-4077
SELECT ( - col2 ) * + col0 DIV col0 + cor0.col0 + - 98 AS col1 FROM tab1 AS cor0
----
-114
-149
-91

skipif mysql # not compatible
query I rowsort label-4077
SELECT ( - col2 ) * + col0 / col0 + cor0.col0 + - 98 AS col1 FROM tab1 AS cor0
----
-114
-149
-91

query I rowsort
SELECT ALL - 28 * + col1 FROM tab1
----
-280
-364
-728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 * - col2 + + col2 col0 FROM tab2 AS cor0
----
1560
684
864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 49 col2 FROM tab2 AS cor0
----
49
49
49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4081
SELECT ALL col1 + col0 + - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4081
SELECT ALL col1 + col0 + - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( cor0.col0 ) FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT + col0 * col0 + + col0 FROM tab1 AS cor0
----
12
4160
6480

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 ALL - col1 + cor0.col0 * col1 + + col2 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-651
3009
680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col2 col0 FROM tab0, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT - + col0 * - col0 + + col0 AS col2 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT - - 55 * col0 FROM tab0 AS cor0
----
1320
1925
4895

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4089
SELECT DISTINCT - cor0.col1 * col0 / + CAST( NULL AS SIGNED ) - + col2 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4089
SELECT DISTINCT - cor0.col1 * col0 / + CAST ( NULL AS INTEGER ) - + col2 FROM tab0 cor0
----
NULL

query I rowsort
SELECT col0 * - col1 + - 16 FROM tab1 cor0
----
-1056
-656
-94

query I rowsort
SELECT 43 + col0 AS col0 FROM tab0 AS cor0
----
132
67
78

query I rowsort
SELECT ALL - cor0.col1 + col2 * - 40 AS col1 FROM tab1 AS cor0
----
-2186
-2290
-3853

query I rowsort
SELECT DISTINCT 97 + - col0 * ( + 80 ) AS col2 FROM tab2 cor0
----
-463
-6143
-6223

query I rowsort
SELECT col1 * 48 * - 29 + + col1 * - col2 FROM tab1 AS cor0
----
-14490
-19344
-37596

query I rowsort
SELECT DISTINCT ( col1 ) * col2 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - col2 * col1 + col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL - cor0.col0 * + cor1.col0 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to fa8f09039d622159cb79f83c1d68bd00

query I rowsort
SELECT 4 FROM tab2, tab2 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT - 6 * col0 + - col1 FROM tab1 AS cor0
----
-394
-44
-493

query I rowsort
SELECT DISTINCT 32 + + col0 * - col2 FROM tab0 AS cor0
----
-3
-7266
-760

query I rowsort
SELECT DISTINCT 82 * col0 FROM tab1 AS cor0
----
246
5248
6560

query I rowsort
SELECT ALL + cor0.col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + 25 * 3 + col0 - 96 * col1 FROM tab2 AS cor0
----
-1478
-2894
-5511

query I rowsort
SELECT ALL - tab1.col1 + + col1 * col1 AS col0 FROM tab1
----
156
650
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4105
SELECT ALL col2 + tab2.col1 DIV + col1 AS col1 FROM tab2
----
27
28
39

skipif mysql # not compatible
query I rowsort label-4105
SELECT ALL col2 + tab2.col1 / + col1 AS col1 FROM tab2
----
27
28
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 43 col2 FROM tab2, tab0, tab0 AS cor0
----
43

query I rowsort
SELECT col1 * tab2.col1 AS col0 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL ( 25 ) + + col0 AS col2 FROM tab2
----
103
104
32

query I rowsort
SELECT ALL - 40 FROM tab0, tab0 AS cor0
----
9 values hashing to f02f17e9bc17e514af018c6f245ed7a9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - col2 col1 FROM tab1 cor0
----
-121
-176
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4111
SELECT DISTINCT - CAST( col0 AS SIGNED ) * - col0 + - CAST( NULL AS SIGNED ) + - 67 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4111
SELECT DISTINCT - CAST ( col0 AS INTEGER ) * - col0 + - CAST ( NULL AS INTEGER ) + - 67 FROM tab2 cor0
----
NULL

query I rowsort
SELECT - - ( + col2 ) + - col1 + - col1 AS col2 FROM tab0 AS cor0
----
-100
-139
-193

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 68 col2 FROM tab0
----
68
68
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-4114
SELECT DISTINCT col1 DIV - ( col2 ) + 68 col0 FROM tab1
----
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4114
SELECT DISTINCT col1 / - ( col2 ) + 68 col0 FROM tab1
----
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4115
SELECT ALL CAST( 10 AS SIGNED ) + + col0 AS col0 FROM tab0
----
34
45
99

skipif mysql # not compatible
query I rowsort label-4115
SELECT ALL CAST ( 10 AS INTEGER ) + + col0 AS col0 FROM tab0
----
34
45
99

query I rowsort
SELECT DISTINCT 48 * col1 + + tab0.col1 + col2 FROM tab0
----
4247
4541
4754

query I rowsort
SELECT ALL col1 + 48 * col2 FROM tab0
----
145
1670
4027

onlyif mysql # use DIV operator for integer division
query I rowsort label-4118
SELECT + - col2 DIV + col1 + col0 + col2 FROM tab1 cor0
----
116
169
55

skipif mysql # not compatible
query I rowsort label-4118
SELECT + - col2 / + col1 + col0 + col2 FROM tab1 cor0
----
116
169
55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4119
SELECT - CAST( NULL AS SIGNED ) * - col2 + col1 * cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4119
SELECT - CAST ( NULL AS INTEGER ) * - col2 + col1 * cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4120
SELECT + - CAST( - 50 AS SIGNED ) * col0 FROM tab2 AS cor0
----
350
3900
3950

skipif mysql # not compatible
query I rowsort label-4120
SELECT + - CAST ( - 50 AS INTEGER ) * col0 FROM tab2 AS cor0
----
350
3900
3950

query I rowsort
SELECT DISTINCT - 44 * col2 * - tab2.col1 AS col2 FROM tab2
----
28424
36828
67496

onlyif mysql # use DIV operator for integer division
query I rowsort label-4122
SELECT + col0 DIV col1 AS col0 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-4122
SELECT + col0 / col1 AS col0 FROM tab2
----
0
1
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-4123
SELECT + ( + col0 + 99 ) DIV - ( col1 ) AS col0 FROM tab1
----
-13
-16
-3

skipif mysql # not compatible
query I rowsort label-4123
SELECT + ( + col0 + 99 ) / - ( col1 ) AS col0 FROM tab1
----
-13
-16
-3

query I rowsort
SELECT - 75 AS col2 FROM tab1 cor0
----
-75
-75
-75

query I rowsort
SELECT col2 + + 92 + col0 FROM tab2 AS cor0
----
126
196
209

query I rowsort
SELECT - cor0.col2 * - 5 - + col1 FROM tab2 cor0
----
104
173
71

query I rowsort
SELECT - + col2 - cor0.col2 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT - + col0 + col2 * + col1 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT ALL + tab2.col1 + + col1 AS col0 FROM tab2
----
118
34
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + ( + cor0.col1 ) col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL col2 + - 20 FROM tab2 AS cor0
----
18
6
7

query I rowsort
SELECT ALL - col1 * col2 * - col2 + + col0 AS col2 FROM tab0
----
132
611973
93678

query I rowsort
SELECT ALL + col0 * - col1 + - col2 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT - col2 - - ( + col2 ) * col2 FROM tab2 cor0
----
1406
650
702

query I rowsort
SELECT + 85 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

query I rowsort
SELECT - - cor0.col2 * 22 * + col1 FROM tab1 AS cor0
----
12540
27456
30888

query I rowsort
SELECT - cor0.col1 * - col0 * col0 + col2 * - col1 AS col0 FROM tab1 AS cor0
----
-1170
40390
81952

query I rowsort
SELECT ALL - + col0 * - col1 + col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL + 78 * col2 * col2 AS col2 FROM tab1 cor0
----
227448
253422
718848

query I rowsort
SELECT + 69 * - ( - col0 ) + 84 * col1 * col0 FROM tab1 AS cor0
----
58176
6759
92880

query I rowsort
SELECT ALL + 84 + col0 FROM tab2 AS cor0
----
162
163
91

query I rowsort
SELECT + + 90 * - col2 + col1 AS col2 FROM tab0 AS cor0
----
-2884
-7289
7

query I rowsort
SELECT DISTINCT - + ( col1 ) + - col2 AS col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT - 96 * + col0 + col2 FROM tab1 AS cor0
----
-234
-6087
-7584

query I rowsort
SELECT ( - cor0.col2 ) + + col1 AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL col1 * - 92 + cor0.col2 FROM tab1 AS cor0
----
-1100
-2338
-863

query I rowsort
SELECT - cor0.col2 + + ( col0 ) AS col0 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4148
SELECT DISTINCT CAST( + col2 AS SIGNED ) + col1 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-4148
SELECT DISTINCT CAST ( + col2 AS INTEGER ) + col1 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4149
SELECT DISTINCT - CAST( col1 AS SIGNED ) + - col1 FROM tab0 AS cor0
----
-172
-182
-194

skipif mysql # not compatible
query I rowsort label-4149
SELECT DISTINCT - CAST ( col1 AS INTEGER ) + - col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT DISTINCT - cor0.col1 + col0 * col2 * col1 AS col0 FROM tab0 AS cor0
----
3298
664027
68026

query I rowsort
SELECT + col2 + col0 + + col1 FROM tab2
----
134
163
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-4152
SELECT DISTINCT - col1 DIV + col1 - col1 FROM tab2
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-4152
SELECT DISTINCT - col1 / + col1 - col1 FROM tab2
----
-18
-32
-60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4153
SELECT ALL + + CAST( NULL AS SIGNED ) * + col1 * - col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4153
SELECT ALL + + CAST ( NULL AS INTEGER ) * + col1 * - col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( - 93 ) FROM tab2, tab2 AS cor0
----
93

query I rowsort
SELECT col1 * 27 + + col0 FROM tab0
----
2346
2546
2654

query I rowsort
SELECT DISTINCT - + col0 * cor0.col1 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4157
SELECT ALL col1 + col1 DIV - 11 AS col2 FROM tab2 AS cor0
----
16
29
54

skipif mysql # not compatible
query I rowsort label-4157
SELECT ALL col1 + col1 / - 11 AS col2 FROM tab2 AS cor0
----
16
29
54

query I rowsort
SELECT 44 FROM tab2 cor0
----
44
44
44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4159
SELECT ALL + CAST( NULL AS SIGNED ) * + ( + col2 ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4159
SELECT ALL + CAST ( NULL AS INTEGER ) * + ( + col2 ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * - col0 * tab1.col2 AS col1 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT ALL 73 * col1 FROM tab2 AS cor0
----
1241
2263
4307

query I rowsort
SELECT - 58 * - col1 AS col0 FROM tab1 AS cor0
----
1508
580
754

query I rowsort
SELECT + 55 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col2 col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - col1 * - cor0.col0 + - ( col1 ) AS col2 FROM tab0 AS cor0
----
1978
3298
8008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col2 + - col0 * 59 * col1 col1 FROM tab0 AS cor0
----
-124614
-200402
-485303

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 62 col0 FROM tab0 cor0
----
-62

query I rowsort
SELECT + cor0.col0 + col2 * + col2 AS col0 FROM tab0 cor0
----
1113
36
6813

query I rowsort
SELECT ALL + 79 + - col1 + col2 FROM tab2 AS cor0
----
100
46
75

query I rowsort
SELECT DISTINCT + - 43 - + col2 AS col0 FROM tab2 cor0
----
-69
-70
-81

query I rowsort
SELECT ALL + 1 * + col1 + - col2 AS col1 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4172
SELECT DISTINCT + 25 * col1 - col2 DIV ( 68 ) FROM tab0 AS cor0
----
2150
2274
2425

skipif mysql # not compatible
query I rowsort label-4172
SELECT DISTINCT + 25 * col1 - col2 / ( 68 ) FROM tab0 AS cor0
----
2150
2274
2425

query I rowsort
SELECT ALL - + 53 + + col0 * col2 AS col2 FROM tab2 AS cor0
----
136
1975
2949

query I rowsort
SELECT DISTINCT + - 14 - - col2 AS col1 FROM tab2 AS cor0
----
12
13
24

query I rowsort
SELECT ALL - + ( - 15 ) * - col2 FROM tab1 AS cor0
----
-1440
-810
-855

query I rowsort
SELECT col1 + 75 * + col1 AS col0 FROM tab2 cor0
----
1292
2356
4484

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col0 ) col0 FROM tab0
----
24
35
89

query I rowsort
SELECT - ( - col2 ) * col1 + col2 * col0 + + col0 AS col1 FROM tab0 AS cor0
----
14849
167
3654

query I rowsort
SELECT DISTINCT 0 * col1 FROM tab1 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4180
SELECT + col0 - + ( + col1 ) DIV + col1 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-4180
SELECT + col0 - + ( + col1 ) / + col1 FROM tab2 AS cor0
----
6
77
78

query I rowsort
SELECT - 96 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to a7b3e5dd01c8929180b7ffda67f79798

query I rowsort
SELECT ALL tab2.col1 + col0 * + 67 * + col0 FROM tab2
----
3314
407687
418164

query I rowsort
SELECT ALL + col2 + - col2 + col2 AS col2 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT + col0 * - ( col0 ) + col0 * col1 AS col1 FROM tab2 cor0
----
-1482
-4898
168

query I rowsort
SELECT + col2 + + cor0.col1 * col2 AS col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT + + col2 * col0 * col1 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL col0 * - 21 FROM tab0 AS cor0
----
-1869
-504
-735

query I rowsort
SELECT ALL + col0 * 63 AS col2 FROM tab2 AS cor0
----
441
4914
4977

query I rowsort
SELECT ALL - col0 + + 27 FROM tab0
----
-62
-8
3

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab1 AS cor2, tab1 cor3
----
3645 values hashing to 028fd38910121a0fa7c5b9a24c207cf0

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0, tab0, tab0 cor1
----
972 values hashing to 3406497351e4789c89a295ee9b64b201

query I rowsort
SELECT DISTINCT + col2 + 21 FROM tab0
----
103
22
54

query IIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab1, tab1 cor1, tab1 AS cor2
----
972 values hashing to a8481bfbfcb330825976c5896e54bc19

query I rowsort
SELECT col2 + + col2 + 5 * col1 AS col1 FROM tab1
----
164
238
257

query I rowsort
SELECT - col1 + - ( + col0 ) AS col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL cor0.col0 * + cor0.col2 + col2 AS col1 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT - - col2 + col0 AS col2 FROM tab1 AS cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * + col2 col2 FROM tab1 cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-4199
SELECT DISTINCT + - col0 DIV 11 AS col2 FROM tab1 AS cor0
----
-5
-7
0

skipif mysql # not compatible
query I rowsort label-4199
SELECT DISTINCT + - col0 / 11 AS col2 FROM tab1 AS cor0
----
-5
-7
0

query I rowsort
SELECT DISTINCT + - 81 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
-81

query I rowsort
SELECT DISTINCT + 23 * + 40 AS col0 FROM tab0 AS cor0
----
920

onlyif mysql # use DIV operator for integer division
query I rowsort label-4202
SELECT - + col1 * + col2 + cor0.col1 DIV - 66 + col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif mysql # not compatible
query I rowsort label-4202
SELECT - + col1 * + col2 + cor0.col1 / - 66 + col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col2 + - col0 col0 FROM tab2 cor0
----
-24
51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4204
SELECT DISTINCT + col1 DIV 44 AS col1 FROM tab1 cor0
----
0

skipif mysql # not compatible
query I rowsort label-4204
SELECT DISTINCT + col1 / 44 AS col1 FROM tab1 cor0
----
0

query I rowsort
SELECT DISTINCT col1 * + 72 AS col0 FROM tab2
----
1224
2232
4248

query I rowsort
SELECT - tab0.col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

onlyif mysql # use DIV operator for integer division
query I rowsort label-4207
SELECT + - cor0.col2 + + ( col2 ) DIV + 98 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-4207
SELECT + - cor0.col2 + + ( col2 ) / + 98 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT 95 * ( cor0.col1 ) + col0 FROM tab0 AS cor0
----
8194
8734
9250

query I rowsort
SELECT + + 73 + 66 * + col0 FROM tab1 AS cor0
----
271
4297
5353

query I rowsort
SELECT ALL 53 AS col1 FROM tab0
----
53
53
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-4211
SELECT DISTINCT - - 63 * - col0 DIV + col0 + cor0.col0 FROM tab0 AS cor0
----
-28
-39
26

skipif mysql # not compatible
query I rowsort label-4211
SELECT DISTINCT - - 63 * - col0 / + col0 + cor0.col0 FROM tab0 AS cor0
----
-28
-39
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col0 col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT tab2.col2 * tab1.col1 FROM tab1, tab0, tab0 AS cor0, tab2
----
81 values hashing to cd5ecc76d0948b50f1d826b9984604f3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 34 col1 FROM tab1
----
-34
-34
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 45 col0 FROM tab2 AS cor0
----
45
45
45

query I rowsort
SELECT - col2 * col0 * 57 AS col1 FROM tab0 AS cor0
----
-1995
-415986
-45144

query I rowsort
SELECT ALL + col1 - cor0.col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL - 61 * + col1 - + 5 AS col1 FROM tab2 AS cor0
----
-1042
-1896
-3604

onlyif mysql # use DIV operator for integer division
query I rowsort label-4219
SELECT DISTINCT cor0.col0 DIV + cor0.col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-4219
SELECT DISTINCT cor0.col0 / + cor0.col2 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT - col1 - 96 AS col1 FROM tab1 AS cor0
----
-106
-109
-122

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4221
SELECT + col0 * CAST( NULL AS SIGNED ) - - col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4221
SELECT + col0 * CAST ( NULL AS INTEGER ) - - col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col2 * - col2 + col2 AS col1 FROM tab2 cor0
----
-1406
-650
-702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4223
SELECT cor0.col1 + - CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort label-4223
SELECT cor0.col1 + - CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL - col1 * - col0 + + col2 * cor0.col0 FROM tab1 cor0
----
240
4288
8720

query I rowsort
SELECT 26 + - col1 FROM tab1
----
0
13
16

query I rowsort
SELECT - ( - col1 ) AS col1 FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-4227
SELECT - col1 * + col0 + + col0 DIV col2 AS col1 FROM tab1
----
-1040
-639
-78

skipif mysql # not compatible
query I rowsort label-4227
SELECT - col1 * + col0 + + col0 / col2 AS col1 FROM tab1
----
-1040
-639
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4228
SELECT + col2 DIV + col1 + 15 FROM tab1
----
17
20
22

skipif mysql # not compatible
query I rowsort label-4228
SELECT + col2 / + col1 + 15 FROM tab1
----
17
20
22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col1 col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 * col2 AS col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT - cor0.col1 + - cor0.col2 * + ( col1 ) AS col2 FROM tab2 AS cor0
----
-1593
-663
-868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * + col2 + 93 col0 FROM tab0 AS cor0
----
128
7391
885

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0, tab1 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to ca4c79a162f92454e0544707b897521a

onlyif mysql # use DIV operator for integer division
query I rowsort label-4234
SELECT DISTINCT col2 DIV - 47 FROM tab0
----
-1
0

skipif mysql # not compatible
query I rowsort label-4234
SELECT DISTINCT col2 / - 47 FROM tab0
----
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4235
SELECT + ( - tab1.col2 + col1 ) DIV col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4235
SELECT + ( - tab1.col2 + col1 ) / col2 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4236
SELECT - col1 * col2 DIV tab0.col1 AS col1 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-4236
SELECT - col1 * col2 / tab0.col1 AS col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT + tab1.col0 - 26 AS col2 FROM tab0, tab2, tab0 AS cor0, tab1
----
81 values hashing to 1b2977f16beccfcc527e74c0f3803cdb

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4238
SELECT col1 + - tab1.col1 - CAST( NULL AS DECIMAL ) * tab1.col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4238
SELECT col1 + - tab1.col1 - CAST ( NULL AS REAL ) * tab1.col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 - - col1 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL + 58 FROM tab1, tab1 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT - ( col0 ) + - col2 * col2 FROM tab2 cor0
----
-1523
-736
-754

skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( col0 AS REAL ) + - col1 * + 18 * - 59 FROM tab1 AS cor0
----
10684
13886
27615

query I rowsort
SELECT DISTINCT - tab2.col1 * col1 AS col2 FROM tab2
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-4244
SELECT DISTINCT tab0.col0 DIV col0 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-4244
SELECT DISTINCT tab0.col0 / col0 FROM tab0
----
1

query I rowsort
SELECT + + 39 + + col0 * col0 * col0 FROM tab2 AS cor0
----
382
474591
493078

onlyif mysql # use DIV operator for integer division
query I rowsort label-4246
SELECT - col2 DIV + 86 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4246
SELECT - col2 / + 86 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) + - tab0.col1 col0 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT + 73 * + 62 FROM tab0 AS cor0
----
4526
4526
4526

query I rowsort
SELECT ALL - - col2 * 43 - col1 AS col0 FROM tab0 cor0
----
-54
1333
3435

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col1 * col1 + - col1 * - col0 col2 FROM tab1 AS cor0
----
-1157
-17498
-360

query I rowsort
SELECT + col2 - col0 * - 50 * col1 FROM tab1 AS cor0
----
32057
3954
52096

query I rowsort
SELECT DISTINCT - 7 + + col0 * - col2 AS col0 FROM tab2 AS cor0
----
-196
-2035
-3009

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4253
SELECT ALL + col1 * - col2 + - CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4253
SELECT ALL + col1 * - col2 + - CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 11 * col1 col0 FROM tab1 AS cor0
----
-110
-143
-286

query I rowsort
SELECT DISTINCT + - col2 + - cor0.col0 * + 57 AS col1 FROM tab2 AS cor0
----
-426
-4472
-4541

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * col1 - col2 * - cor0.col1 col1 FROM tab1 AS cor0
----
1079
470
728

query I rowsort
SELECT cor0.col0 + + col1 AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + + 73 AS col2 FROM tab1 cor0
----
73
73
73

query I rowsort
SELECT ALL - col2 + - col1 * col2 FROM tab1 cor0
----
-1344
-1458
-627

query I rowsort
SELECT ALL - + col2 * cor0.col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT + + col0 * cor0.col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4262
SELECT DISTINCT - ( - col2 ) DIV 68 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-4262
SELECT DISTINCT - ( - col2 ) / 68 FROM tab0 AS cor0
----
0
1

query I rowsort
SELECT DISTINCT + col0 * col1 + - col0 AS col1 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT ALL - col2 * col2 + - col2 FROM tab1 cor0
----
-2970
-3306
-9312

query I rowsort
SELECT col0 + - 83 FROM tab0 AS cor0
----
-48
-59
6

query I rowsort
SELECT + col1 + 40 FROM tab2 cor0
----
57
71
99

query I rowsort
SELECT - col1 + - 3 FROM tab0 AS cor0
----
-100
-89
-94

onlyif mysql # use DIV operator for integer division
query I rowsort label-4268
SELECT DISTINCT col1 * col1 DIV tab0.col0 + + col1 FROM tab0
----
184
365
394

skipif mysql # not compatible
query I rowsort label-4268
SELECT DISTINCT col1 * col1 / tab0.col0 + + col1 FROM tab0
----
184
365
394

query I rowsort
SELECT col0 * + col2 + + col1 AS col2 FROM tab0 cor0
----
132
7389
878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 * col0 col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4271
SELECT ALL - col1 * col2 DIV col1 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-4271
SELECT ALL - col1 * col2 / col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + cor0.col0 * col2 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col2 * col1 + - col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT cor0.col1 + 78 FROM tab0 cor0
----
164
169
175

query I rowsort
SELECT - col1 + 13 AS col1 FROM tab1 AS cor0
----
-13
0
3

query I rowsort
SELECT - col0 * + 66 + - col0 FROM tab2 cor0
----
-469
-5226
-5293

query I rowsort
SELECT ALL - ( col0 ) - + col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT - + 34 + + 85 FROM tab2 AS cor0
----
51
51
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-4279
SELECT DISTINCT - 83 + col2 DIV col1 FROM tab0 cor0
----
-83

skipif mysql # not compatible
query I rowsort label-4279
SELECT DISTINCT - 83 + col2 / col1 FROM tab0 cor0
----
-83

query I rowsort
SELECT DISTINCT - 24 FROM tab2, tab1 AS cor0
----
-24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col1 ) + + col1 col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT - col2 * ( - 8 ) + + col0 AS col0 FROM tab1
----
435
520
848

query I rowsort
SELECT - 29 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 0cc9ddad93fc783055518ae4b6be054b

onlyif mysql # use DIV operator for integer division
query I rowsort label-4284
SELECT DISTINCT col0 DIV - col1 AS col0 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-4284
SELECT DISTINCT col0 / - col1 AS col0 FROM tab0
----
0

query I rowsort
SELECT ALL - col0 * + 99 + + col0 AS col0 FROM tab0
----
-2352
-3430
-8722

query I rowsort
SELECT tab2.col0 * + tab2.col2 FROM tab2
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4287
SELECT ALL - col2 * tab2.col1 + + 65 * - col2 + CAST( + col2 + col0 AS SIGNED ) FROM tab2
----
-2558
-2999
-3120

skipif mysql # not compatible
query I rowsort label-4287
SELECT ALL - col2 * tab2.col1 + + 65 * - col2 + CAST ( + col2 + col0 AS INTEGER ) FROM tab2
----
-2558
-2999
-3120

query I rowsort
SELECT DISTINCT cor0.col1 + + col0 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + cor0.col2 + col2 AS col2 FROM tab0 AS cor0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + - col2 col2 FROM tab2 AS cor0
----
-21
33
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 + + 81 + ( + col2 ) * 48 * 91 col2 FROM tab2 AS cor0
----
113708
118048
166082

query I rowsort
SELECT ALL - cor0.col1 * + cor0.col0 * + col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL - + col1 * col0 + - col0 FROM tab1 AS cor0
----
-1120
-704
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-4294
SELECT tab2.col2 DIV + ( + col1 ) FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-4294
SELECT tab2.col2 / + ( + col1 ) FROM tab2
----
0
0
2

query I rowsort
SELECT DISTINCT - col2 * ( col1 ) FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 col1 FROM tab1, tab2 cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT col0 + col0 * - col1 + col0 FROM tab2 AS cor0
----
-1185
-203
-4446

query I rowsort
SELECT - ( - 29 ) AS col1 FROM tab2 cor0
----
29
29
29

query I rowsort
SELECT ( + col2 ) + - col1 + col0 * - col0 AS col1 FROM tab2 AS cor0
----
-53
-6117
-6220

query I rowsort
SELECT + 43 * 85 + col2 * col2 + cor0.col1 AS col1 FROM tab2 AS cor0
----
4390
4415
5116

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( + 73 ) * + col1 + + 13 + + col2 col0 FROM tab1 AS cor0
----
-1831
-660
-840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4302
SELECT DISTINCT - 23 DIV + col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4302
SELECT DISTINCT - 23 / + col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + cor0.col2 + + 89 AS col0 FROM tab0 AS cor0
----
122
171
90

query I rowsort
SELECT DISTINCT + 27 + - 13 AS col1 FROM tab2 AS cor0
----
14

query I rowsort
SELECT ALL + - 65 * - ( - cor0.col1 ) FROM tab2 AS cor0
----
-1105
-2015
-3835

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( - col0 AS REAL ) * col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT - col1 + - 14 AS col1 FROM tab2
----
-31
-45
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-4308
SELECT DISTINCT col1 DIV - tab2.col1 + + 18 FROM tab2
----
17

skipif mysql # not compatible
query I rowsort label-4308
SELECT DISTINCT col1 / - tab2.col1 + + 18 FROM tab2
----
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4309
SELECT ALL col0 + CAST( - 75 + - col0 AS SIGNED ) AS col1 FROM tab1
----
-75
-75
-75

skipif mysql # not compatible
query I rowsort label-4309
SELECT ALL col0 + CAST ( - 75 + - col0 AS INTEGER ) AS col1 FROM tab1
----
-75
-75
-75

query I rowsort
SELECT ALL + col0 + 41 AS col1 FROM tab1
----
105
121
44

query I rowsort
SELECT ALL tab2.col1 * - 77 + + tab2.col2 FROM tab2
----
-1271
-2360
-4517

query I rowsort
SELECT - ( - col0 ) * + cor0.col1 * 34 AS col1 FROM tab1 AS cor0
----
21760
2652
35360

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 65 * + ( - col2 ) + - col2 * + 4 * col2 col0 FROM tab2 AS cor0
----
-4394
-4671
-8246

query I rowsort
SELECT ALL - + col1 + + col2 * 90 * - 14 AS col2 FROM tab0 cor0
----
-103411
-1357
-41666

query I rowsort
SELECT DISTINCT - col1 - col0 AS col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT - + 60 + col1 FROM tab2 AS cor0
----
-1
-29
-43

query I rowsort
SELECT ALL - col1 * col0 * - col1 AS col0 FROM tab2 cor0
----
22831
271518
6727

query I rowsort
SELECT DISTINCT - - cor0.col2 + + col0 + + col1 AS col0 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT ALL - col2 * - col0 * - col1 AS col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT col0 * col0 + - ( cor0.col0 ) FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT - col2 + - cor0.col2 * ( - col1 ) FROM tab0 cor0
----
2805
7380
96

query I rowsort
SELECT DISTINCT col1 + col1 * col2 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL + 49 - col0 FROM tab1 AS cor0
----
-15
-31
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-4324
SELECT ALL 5 DIV col0 AS col0 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4324
SELECT ALL 5 / col0 AS col0 FROM tab1 AS cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4325
SELECT ALL - 52 - + col1 DIV + col0 FROM tab2 cor0
----
-52
-52
-56

skipif mysql # not compatible
query I rowsort label-4325
SELECT ALL - 52 - + col1 / + col0 FROM tab2 cor0
----
-52
-52
-56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 2 * - col2 col1 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT ALL + - col1 - + col0 AS col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT - + cor0.col1 * col1 + col2 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT + - col1 - 34 AS col2 FROM tab1 cor0
----
-44
-47
-60

query I rowsort
SELECT ALL - col0 + 93 * col0 FROM tab2 AS cor0
----
644
7176
7268

query I rowsort
SELECT + 51 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT ( col1 ) * 41 + 77 + + col2 AS col1 FROM tab1
----
1197
544
706

query I rowsort
SELECT ALL - cor1.col1 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4334
SELECT - col2 + - col2 DIV col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-4334
SELECT - col2 + - col2 / col1 FROM tab0 AS cor0
----
-1
-33
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4335
SELECT + CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4335
SELECT + CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT 75 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 76 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

query I rowsort
SELECT - cor0.col1 + ( + col2 ) * - col0 - 63 AS col2 FROM tab1 AS cor0
----
-251
-3721
-7756

query I rowsort
SELECT ALL - ( ( + cor0.col1 ) ) FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + col2 * + col1 * col2 + col1 + - col2 FROM tab2
----
22603
24527
39917

query I rowsort
SELECT DISTINCT col1 * + 43 + - tab0.col1 AS col1 FROM tab0
----
3612
3822
4074

query I rowsort
SELECT DISTINCT + col0 + + 92 AS col2 FROM tab1 AS cor0
----
156
172
95

query I rowsort
SELECT col0 * 18 FROM tab1 AS cor0
----
1152
1440
54

query I rowsort
SELECT + 33 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT ( col0 ) * - ( + col1 ) FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4346
SELECT ( col2 ) * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4346
SELECT ( col2 ) * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col1 col2 FROM tab2, tab0 cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 60 * col1 col2 FROM tab1
----
-1560
-600
-780

query I rowsort
SELECT ALL ( col2 ) * + col1 AS col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT + col2 * col1 * - ( + ( + col1 ) * + col0 ) AS col1 FROM tab0 AS cor0
----
-329315
-5857632
-60434738

query I rowsort
SELECT DISTINCT + col0 * cor0.col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-4352
SELECT ALL + 80 DIV col1 FROM tab2
----
1
2
4

skipif mysql # not compatible
query I rowsort label-4352
SELECT ALL + 80 / col1 FROM tab2
----
1
2
4

query I rowsort
SELECT + + cor0.col0 * + col2 AS col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - 57 AS col0 FROM tab0 AS cor0
----
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 + - col2 * + ( 96 * col1 ) col2 FROM tab0 cor0
----
-272481
-716434
-9313

query I rowsort
SELECT - 87 + col2 AS col2 FROM tab1 AS cor0
----
-30
-33
9

query I rowsort
SELECT DISTINCT tab1.col2 * + tab1.col1 / - tab1.col0 AS col1 FROM tab1 WHERE + col1 >= ( col1 * + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4358
SELECT tab0.col1 + + col1 + col1 DIV - col0 FROM tab0
----
169
181
192

skipif mysql # not compatible
query I rowsort label-4358
SELECT tab0.col1 + + col1 + col1 / - col0 FROM tab0
----
169
181
192

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL IN ( col0 )
----

query I rowsort
SELECT + col1 - - col0 * col2 * + col2 AS col1 FROM tab1
----
207946
737293
8774

query I rowsort
SELECT col0 + - tab1.col1 * col1 + col2 FROM tab1
----
-619
21
7

query I rowsort
SELECT + col2 + col1 * + tab2.col2 FROM tab2
----
1560
684
864

query I rowsort
SELECT + col1 + col1 * + col1 AS col2 FROM tab0
----
7482
8372
9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col1 col1 FROM tab0 WHERE + col0 NOT BETWEEN col2 AND ( NULL )
----
2064

query I rowsort
SELECT - tab1.col1 + col1 * - tab1.col2 AS col1 FROM tab1
----
-1261
-1430
-580

query I rowsort
SELECT - tab0.col0 + + col0 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col0 * + ( - col2 * + col0 ) - + ( - cor0.col0 * + col1 ) col1 FROM tab1 AS cor0
----
-1380
-14941568
-49150960

query I rowsort
SELECT - 43 + col2 AS col0 FROM tab2 AS cor0
----
-16
-17
-5

query I rowsort
SELECT DISTINCT 28 + + cor0.col0 FROM tab2 AS cor0
----
106
107
35

query I rowsort
SELECT + ( - col2 ) * col0 AS col1 FROM tab0 cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 66 * col2 col1 FROM tab2 AS cor0
----
-1716
-1782
-2508

query I rowsort
SELECT - - col0 + - col0 * - 93 FROM tab2 AS cor0
----
658
7332
7426

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col0 - + col0 col0 FROM tab2
----
42
6006
6162

query I rowsort
SELECT DISTINCT + col2 * + tab0.col1 - + col1 AS col2 FROM tab0
----
0
2752
7371

query I rowsort
SELECT ALL - 32 * + col0 + + 61 AS col1 FROM tab1 AS cor0
----
-1987
-2499
-35

query I rowsort
SELECT col0 + col0 AS col1 FROM tab1 WHERE NOT ( - col0 ) < NULL
----

query I rowsort
SELECT col1 * + col0 * col1 AS col1 FROM tab0 AS cor0
----
177504
329315
737009

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT NULL IN ( + cor0.col1 - - cor0.col1 )
----

query I rowsort
SELECT + col0 + - col1 * + col0 AS col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT cor0.col0 FROM tab2 AS cor0 WHERE + col2 IN ( - col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col1 + col2 col0 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT - col2 FROM tab0 WHERE NOT NULL >= + col1 * col0
----

query I rowsort
SELECT ALL + col1 * col0 + col1 AS col1 FROM tab1
----
104
1053
650

query I rowsort
SELECT col2 + col0 + - col2 AS col1 FROM tab0 WHERE + col0 <> col0 - col0
----
24
35
89

query I rowsort
SELECT + col1 + - col0 + col1 * col2 * tab0.col0 AS col2 FROM tab0
----
3457
664120
68174

query I rowsort
SELECT col1 + col0 * - col2 AS col0 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT ALL - col0 + col2 AS col2 FROM tab1 WHERE NOT NULL IN ( + tab1.col2 )
----

query I rowsort
SELECT + col0 + tab2.col1 FROM tab2
----
137
38
96

query I rowsort
SELECT ALL + col0 * col1 + + col1 AS col1 FROM tab0 WHERE col2 * - col0 + col1 <> ( NULL )
----

query I rowsort
SELECT DISTINCT + col0 * col1 - col0 AS col2 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT + - cor0.col2 + + col0 AS col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT + cor2.col0 * 48 + - cor1.col2 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0, tab2 AS cor2
----
9 values hashing to 424c32cf1f4f6d3e36bbd52cc5ec1481

query I rowsort
SELECT + + 77 * col1 + col1 AS col0 FROM tab1 AS cor0
----
1014
2028
780

query I rowsort
SELECT DISTINCT + cor0.col2 * + 96 * + col2 FROM tab0 cor0
----
104544
645504
96

query I rowsort
SELECT 3 + col0 + col0 AS col2 FROM tab0 AS cor0
----
181
51
73

query I rowsort
SELECT ALL - 55 + + 80 AS col1 FROM tab0 AS cor0
----
25
25
25

query I rowsort
SELECT DISTINCT + ( + 67 ) AS col1 FROM tab0 cor0
----
67

query I rowsort
SELECT + cor1.col1 AS col2 FROM tab1, tab1 AS cor0, tab2, tab0 cor1
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT + 82 + tab2.col1 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 5991c127b9971bf727bb5e6df54863e2

query I rowsort
SELECT col0 * - tab0.col2 + col1 AS col2 FROM tab0
----
-706
-7207
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + 93 col1 FROM tab2
----
14
15
86

query I rowsort
SELECT ALL - col0 * + col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

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 + ( col0 ) * + col1 * + col2 col2 FROM tab0 AS cor0
----
3395
664118
68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4405
SELECT DISTINCT CAST( NULL AS SIGNED ) * + 30 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4405
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + 30 AS col2 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4406
SELECT + 50 DIV + col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4406
SELECT + 50 / + col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - ( + cor0.col1 ) * - col1 * col2 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT col0 + col1 - ( 56 * + col2 ) FROM tab0
----
-1738
-4412
76

query I rowsort
SELECT - col0 * col0 + - col2 - col1 * col0 * ( + tab0.col1 ) FROM tab0
----
-178113
-330541
-745012

query I rowsort
SELECT DISTINCT col2 * col0 - tab1.col2 FROM tab1
----
108
3591
7584

query I rowsort
SELECT + tab1.col2 * col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT - tab2.col1 * col2 + col0 - 99 AS col2 FROM tab2
----
-1555
-666
-929

query I rowsort
SELECT DISTINCT 60 - col1 FROM tab0
----
-26
-31
-37

query I rowsort
SELECT - - col0 * - ( + col0 ) + + col0 * + col2 FROM tab2 AS cor0
----
-3239
-4056
140

query I rowsort
SELECT DISTINCT col2 * + 22 AS col1 FROM tab0 AS cor0
----
1804
22
726

query I rowsort
SELECT + 83 AS col1 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT 73 AS col0 FROM tab1
----
73
73
73

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0, tab1 cor0, tab2 AS cor1
----
972 values hashing to f0b9665afa0b835e4e5097af17c51766

onlyif mysql # use DIV operator for integer division
query I rowsort label-4419
SELECT + tab1.col2 DIV col1 - - tab1.col1 * - col1 FROM tab1
----
-162
-674
-95

skipif mysql # not compatible
query I rowsort label-4419
SELECT + tab1.col2 / col1 - - tab1.col1 * - col1 FROM tab1
----
-162
-674
-95

query I rowsort
SELECT + tab2.col2 + col0 * - col1 + col2 * - col0 FROM tab2
----
-379
-4307
-6604

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 68 * + col1 + col0 col1 FROM tab2
----
1235
2115
4090

query I rowsort
SELECT - + col2 + + ( col1 ) + - col1 * col2 FROM tab1 cor0
----
-1331
-1432
-617

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col0 * 68 + ( + col0 ) + - 3 * + 11 col0 FROM tab0 AS cor0
----
-1641
-2378
-5996

query I rowsort
SELECT + col0 + ( + col1 * col1 ) + col2 AS col0 FROM tab1 AS cor0
----
221
345
733

onlyif mysql # use DIV operator for integer division
query I rowsort label-4425
SELECT col0 * ( + tab1.col1 ) + - col2 DIV + ( - col2 * - col2 ) FROM tab1
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-4425
SELECT col0 * ( + tab1.col1 ) + - col2 / + ( - col2 * - col2 ) FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL - - col2 + col1 * - col2 AS col1 FROM tab2 AS cor0
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col2 * col0 col2 FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT - col2 - col0 AS col1 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4429
SELECT DISTINCT + col2 + col1 DIV 28 FROM tab0 AS cor0
----
36
4
85

skipif mysql # not compatible
query I rowsort label-4429
SELECT DISTINCT + col2 + col1 / 28 FROM tab0 AS cor0
----
36
4
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4430
SELECT DISTINCT - col2 + CAST( - 55 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-137
-56
-88

skipif mysql # not compatible
query I rowsort label-4430
SELECT DISTINCT - col2 + CAST ( - 55 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-137
-56
-88

query I rowsort
SELECT DISTINCT - + cor0.col1 + - ( + 61 ) * col2 FROM tab2 cor0
----
-1645
-1678
-2335

query I rowsort
SELECT col1 * cor0.col2 AS col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT ALL - cor0.col0 * col2 + cor0.col1 AS col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT - col2 * 70 AS col1 FROM tab2 AS cor0
----
-1820
-1890
-2660

onlyif mysql # use DIV operator for integer division
query I rowsort label-4435
SELECT ALL col2 DIV ( col1 ) FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-4435
SELECT ALL col2 / ( col1 ) FROM tab2 AS cor0
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - ( - col0 ) col1 FROM tab1
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 78 col2 FROM tab0
----
78
78
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4438
SELECT DISTINCT CAST( NULL AS SIGNED ) * tab0.col1 + - col1 - - ( + col0 ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-4438
SELECT DISTINCT CAST ( NULL AS INTEGER ) * tab0.col1 + - col1 - - ( + col0 ) FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4439
SELECT ALL 38 DIV col1 FROM tab2
----
0
1
2

skipif mysql # not compatible
query I rowsort label-4439
SELECT ALL 38 / col1 FROM tab2
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 50 col2 FROM tab2
----
50

query I rowsort
SELECT - ( - col1 ) AS col2 FROM tab0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4442
SELECT col0 * + ( col1 ) + CAST( + col2 AS SIGNED ) FROM tab2
----
1381
244
4628

skipif mysql # not compatible
query I rowsort label-4442
SELECT col0 * + ( col1 ) + CAST ( + col2 AS INTEGER ) FROM tab2
----
1381
244
4628

query I rowsort
SELECT ALL + 13 * + col2 FROM tab0 AS cor0
----
1066
13
429

query I rowsort
SELECT - 11 * col0 + col0 AS col0 FROM tab2 cor0
----
-70
-780
-790

query I rowsort
SELECT ALL cor0.col1 * - col2 + ( col0 ) * col0 FROM tab2 AS cor0
----
-788
4550
5595

query I rowsort
SELECT 61 + - col2 AS col2 FROM tab1 AS cor0
----
-35
4
7

query I rowsort
SELECT - col1 - + col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT - - ( + cor0.col0 ) + + col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + 28 * cor0.col2 * - col1 + - col0 FROM tab1 AS cor0
----
-16024
-35024
-39315

query I rowsort
SELECT - 82 * + col0 + + col0 * 55 FROM tab2 cor0
----
-189
-2106
-2133

query I rowsort
SELECT DISTINCT + col1 * - cor0.col1 * - col0 AS col0 FROM tab0 AS cor0
----
177504
329315
737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-4452
SELECT - - cor0.col2 DIV cor0.col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4452
SELECT - - cor0.col2 / cor0.col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT - - col1 - cor0.col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col0 + col1 * col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + cor0.col0 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
3
64
80

query I rowsort
SELECT DISTINCT - cor0.col0 + col2 AS col1 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT - + col2 - - ( col0 ) AS col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL + col1 + ( col2 ) * + col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT ALL + cor0.col1 * col2 - - col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT col1 * 0 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - cor0.col2 AS col2 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + col2 * - cor0.col1 * 70 + - col2 + - col0 FROM tab0 AS cor0
----
-198717
-522511
-6826

query I rowsort
SELECT ALL + cor0.col2 - - col1 AS col2 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4464
SELECT ALL + col1 * + col2 * - col1 + cor0.col2 * - CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4464
SELECT ALL + col1 * + col2 * - col1 + cor0.col2 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + 51 * + 59 FROM tab0 AS cor0
----
3010
3042
3091

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4466
SELECT ALL + col0 + - CAST( col0 AS SIGNED ) * - cor0.col2 + col2 FROM tab1 AS cor0
----
219
3769
7856

skipif mysql # not compatible
query I rowsort label-4466
SELECT ALL + col0 + - CAST ( col0 AS INTEGER ) * - cor0.col2 + col2 FROM tab1 AS cor0
----
219
3769
7856

query I rowsort
SELECT col0 + + ( 43 ) FROM tab1 cor0
----
107
123
46

query I rowsort
SELECT ALL col0 * ( - col1 + + col0 ) AS col1 FROM tab0 AS cor0
----
-1488
-178
-2170

query I rowsort
SELECT DISTINCT + cor0.col2 * - col0 + - col1 + - col0 FROM tab0 AS cor0
----
-167
-7478
-902

query I rowsort
SELECT + col1 + 79 * + col1 AS col1 FROM tab1 cor0
----
1040
2080
800

query I rowsort
SELECT DISTINCT - 88 * col1 AS col1 FROM tab1 AS cor0
----
-1144
-2288
-880

query I rowsort
SELECT ALL + col2 * 30 AS col1 FROM tab1 AS cor0
----
1620
1710
2880

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4473
SELECT + CAST( NULL AS SIGNED ) / - 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-4473
SELECT + CAST ( NULL AS INTEGER ) / - col0 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col1 * - col1 + cor0.col2 + + 80 FROM tab2 AS cor0
----
1068
3587
407

query I rowsort
SELECT DISTINCT - cor0.col1 * + cor0.col1 FROM tab1, tab1 AS cor0
----
-100
-169
-676

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0, tab1 AS cor1, tab2 cor2
----
972 values hashing to 0fcd8d0934383dd58863be894b07a6ed

query I rowsort
SELECT + + 20 AS col1 FROM tab1 cor0
----
20
20
20

query I rowsort
SELECT ALL + cor0.col2 * - col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 64 + col0 col2 FROM tab0 AS cor0
----
153
88
99

query I rowsort
SELECT - 49 * cor0.col1 FROM tab2 AS cor0
----
-1519
-2891
-833

query I rowsort
SELECT - 59 * 16 AS col1 FROM tab1 cor0
----
-944
-944
-944

query I rowsort
SELECT DISTINCT - 9 + + col1 - col0 FROM tab1 AS cor0
----
-63
-76
14

query I rowsort
SELECT - 78 * 23 FROM tab0 AS cor0
----
-1794
-1794
-1794

query I rowsort
SELECT DISTINCT + ( col2 ) + col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + col0 * col0 + - col0 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT - col0 + + col1 * - col0 AS col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-4487
SELECT + + col1 + col1 DIV - cor0.col0 col2 FROM tab0 AS cor0
----
83
90
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4487
SELECT + + col1 + col1 / - cor0.col0 col2 FROM tab0 AS cor0
----
83
90
95

query I rowsort
SELECT + - col0 * + col2 + cor0.col1 AS col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT 83 + + col0 FROM tab1
----
147
163
86

query I rowsort
SELECT 94 FROM tab0, tab1 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0, tab0 cor1, tab1, tab1 AS cor2
----
3645 values hashing to bce5cbf48f4a41569415c085ae91ae7c

query I rowsort
SELECT col0 + col0 + ( cor0.col2 ) AS col0 FROM tab1 AS cor0
----
185
256
60

query I rowsort
SELECT ALL + cor0.col1 * 97 AS col2 FROM tab1 AS cor0
----
1261
2522
970

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4494
SELECT DISTINCT - col2 / - CAST( NULL AS SIGNED ) col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4494
SELECT DISTINCT - col2 / - CAST ( NULL AS INTEGER ) col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + + 77 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT - cor0.col0 * 27 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to bc4ba142e01cf8908b59b57f0026ae45

query I rowsort
SELECT + ( col1 ) - + col1 * - 97 FROM tab2
----
1666
3038
5782

query I rowsort
SELECT ALL + 26 + 47 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4499
SELECT - col1 * - CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4499
SELECT - col1 * - 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 - + col0 * col0 col2 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT + col1 * ( + col2 * - col1 + ( col0 ) ) AS col1 FROM tab2 cor0
----
-25730
-85904
-9639

query I rowsort
SELECT DISTINCT cor0.col0 * - ( 5 ) FROM tab1, tab1 AS cor0
----
-15
-320
-400

query I rowsort
SELECT DISTINCT + col2 * + cor0.col1 + + ( col1 ) FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL + - col0 * col0 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT - col1 * 54 - col0 * - ( + col1 ) FROM tab2
----
-1457
1416
425

query I rowsort
SELECT ALL - col1 * col0 + col0 AS col1 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT ( - 35 ) * - tab2.col0 * 50 FROM tab2
----
12250
136500
138250

query I rowsort
SELECT - - col0 * col1 + + col1 AS col0 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT - col0 * col1 + ( col2 ) AS col1 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT ALL + col2 * - col1 + + ( col2 ) * - col2 FROM tab0 AS cor0
----
-14186
-3927
-98

query I rowsort
SELECT + 89 AS col1 FROM tab0 AS cor0
----
89
89
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 + col2 col2 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4513
SELECT ALL 17 + - col2 DIV col2 FROM tab0 AS cor0
----
16
16
16

skipif mysql # not compatible
query I rowsort label-4513
SELECT ALL 17 + - col2 / col2 FROM tab0 AS cor0
----
16
16
16

query I rowsort
SELECT 2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

onlyif mysql # use DIV operator for integer division
query I rowsort label-4515
SELECT - 34 DIV tab1.col2 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4515
SELECT - 34 / tab1.col2 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + cor0.col1 + cor0.col1 AS col2 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT DISTINCT 44 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
44

query I rowsort
SELECT ALL + - col1 - col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT - - col0 * + col1 + 81 * col0 * col1 AS col2 FROM tab2 cor0
----
110126
17794
377364

query I rowsort
SELECT DISTINCT - 39 * col0 + + 50 AS col0 FROM tab1 AS cor0
----
-2446
-3070
-67

query I rowsort
SELECT 91 + col0 FROM tab1 AS cor0
----
155
171
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-4522
SELECT ALL ( - col2 ) * col2 DIV - col0 FROM tab1
----
115
50
972

skipif mysql # not compatible
query I rowsort label-4522
SELECT ALL ( - col2 ) * col2 / - col0 FROM tab1
----
115
50
972

query I rowsort
SELECT DISTINCT - - 32 + col1 * col1 * col1 FROM tab1 AS cor0
----
1032
17608
2229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col1 col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT col0 + col1 * cor0.col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL + + 54 AS col1 FROM tab0 AS cor0
----
54
54
54

query I rowsort
SELECT - + 4 + col2 * + col0 FROM tab0 AS cor0
----
31
7294
788

query I rowsort
SELECT + col1 * col0 * - ( col2 ) AS col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT - + col1 + - cor0.col2 * + col1 AS col2 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT tab0.col0 * tab0.col2 + - col1 FROM tab0
----
-62
706
7207

query I rowsort
SELECT - col0 + col1 * 13 * col2 FROM tab1 AS cor0
----
16144
18249
7346

query I rowsort
SELECT ALL - col1 + ( + 8 ) * - cor0.col0 AS col1 FROM tab2 AS cor0
----
-649
-683
-87

query I rowsort
SELECT col2 * - col1 + col0 * cor0.col0 FROM tab1 AS cor0
----
-1395
3526
5152

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col2 + ( col0 ) col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + col0 * col0 * + ( col2 * col0 ) + - cor0.col2 FROM tab1 AS cor0
----
1404
14942151
49151904

query I rowsort
SELECT DISTINCT col1 * col0 + - col0 AS col0 FROM tab1
----
576
75
960

query I rowsort
SELECT - - 71 FROM tab0 AS cor0
----
71
71
71

query I rowsort
SELECT ALL - 75 AS col1 FROM tab0 AS cor0
----
-75
-75
-75

query I rowsort
SELECT ALL + 51 * + 68 FROM tab2 cor0
----
3468
3468
3468

query I rowsort
SELECT ( - col2 ) * col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL - col2 + - 92 * + col2 * + col1 + - col0 * col2 FROM tab2 AS cor0
----
-143182
-62472
-77220

query I rowsort
SELECT DISTINCT col2 + - col1 * cor0.col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4543
SELECT - - col2 * col2 + - col1 * + CAST( col1 AS SIGNED ) AS col1 FROM tab2 cor0
----
-232
-2805
1155

skipif mysql # not compatible
query I rowsort label-4543
SELECT - - col2 * col2 + - col1 * + CAST ( col1 AS INTEGER ) AS col1 FROM tab2 cor0
----
-232
-2805
1155

query I rowsort
SELECT DISTINCT - col1 * - ( col1 ) * + col2 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT DISTINCT col0 * col1 * - tab0.col1 AS col0 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL - col0 - tab1.col1 AS col2 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT ( + 72 ) FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4548
SELECT - + CAST( - col0 AS SIGNED ) + + col2 col0 FROM tab2 AS cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4548
SELECT - + CAST ( - col0 AS INTEGER ) + + col2 col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL - ( 56 ) + - col0 AS col0 FROM tab2 AS cor0
----
-134
-135
-63

query I rowsort
SELECT + + col1 * col0 + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + ( ( col1 ) ) + - col2 AS col1 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT ALL - 37 + col1 * cor0.col0 AS col1 FROM tab0 AS cor0
----
2027
3358
8062

query I rowsort
SELECT ALL col1 * + 22 FROM tab0 AS cor0
----
1892
2002
2134

query I rowsort
SELECT DISTINCT - + 64 AS col2 FROM tab1 AS cor0
----
-64

onlyif mysql # use DIV operator for integer division
query I rowsort label-4555
SELECT col2 + - col0 DIV col1 FROM tab2 AS cor0
----
25
27
34

skipif mysql # not compatible
query I rowsort label-4555
SELECT col2 + - col0 / col1 FROM tab2 AS cor0
----
25
27
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4556
SELECT col1 DIV - col2 - + col2 FROM tab0 AS cor0
----
-35
-83
-98

skipif mysql # not compatible
query I rowsort label-4556
SELECT col1 / - col2 - + col2 FROM tab0 AS cor0
----
-35
-83
-98

query I rowsort
SELECT + + ( - col1 ) * + col1 + - 52 * col1 - + col0 FROM tab1 AS cor0
----
-2031
-684
-925

query I rowsort
SELECT DISTINCT + 24 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
24

query I rowsort
SELECT - col0 + - cor0.col1 * col2 AS col0 FROM tab2 cor0
----
-1612
-725
-844

onlyif mysql # use DIV operator for integer division
query I rowsort label-4560
SELECT ALL cor0.col1 DIV col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4560
SELECT ALL cor0.col1 / col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT + col0 + 2 * + ( + cor0.col0 ) FROM tab2 AS cor0
----
21
234
237

query I rowsort
SELECT col2 + - col0 * + col0 * - col2 FROM tab2
----
1350
158210
237196

query I rowsort
SELECT cor0.col0 * 30 AS col0 FROM tab1 AS cor0
----
1920
2400
90

query I rowsort
SELECT - + cor0.col1 + + cor0.col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - - cor0.col0 * ( col2 + col1 ) FROM tab1 AS cor0
----
240
4288
8720

onlyif mysql # use DIV operator for integer division
query I rowsort label-4566
SELECT - col0 DIV + col2 + + col1 FROM tab1
----
13
26
9

skipif mysql # not compatible
query I rowsort label-4566
SELECT - col0 / + col2 + + col1 FROM tab1
----
13
26
9

query I rowsort
SELECT + - ( - col1 ) FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT + ( 77 ) FROM tab1 AS cor0
----
77
77
77

query I rowsort
SELECT 82 FROM tab0, tab0 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

query I rowsort
SELECT + cor0.col2 AS col0 FROM tab2, tab1, tab0 AS cor0 WHERE NULL = NULL
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4571
SELECT - CAST( NULL AS SIGNED ) - - 53 * + col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4571
SELECT - CAST ( NULL AS INTEGER ) - - 53 * + col1 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( tab2.col0 ) + - col0 * tab2.col0 + + 4 * + col0 col1 FROM tab2
----
-14
-5694
-5846

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 col0 FROM tab2 cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-4574
SELECT + cor0.col0 + + cor0.col2 DIV - cor0.col2 + + ( + col0 ) AS col1 FROM tab0 AS cor0
----
177
47
69

skipif mysql # not compatible
query I rowsort label-4574
SELECT + cor0.col0 + + cor0.col2 / - cor0.col2 + + ( + col0 ) AS col1 FROM tab0 AS cor0
----
177
47
69

query I rowsort
SELECT + + cor0.col1 * - col0 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4576
SELECT - col0 + - col2 * CAST( NULL AS SIGNED ) * 82 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4576
SELECT - col0 + - col2 * CAST ( NULL AS INTEGER ) * 82 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - 48 col0 FROM tab1
----
-112
-128
-51

query I rowsort
SELECT - ( col1 ) + - col1 + + ( col0 ) AS col0 FROM tab0
----
-148
-159
-93

query I rowsort
SELECT - col0 * - 38 + col2 FROM tab1
----
168
2489
3136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 col1 FROM tab1, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT ALL + + col1 + - col0 AS col0 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT col2 + col2 + - col1 FROM tab1 AS cor0
----
104
179
82

query I rowsort
SELECT ALL - 86 AS col1 FROM tab0 AS cor0
----
-86
-86
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-4584
SELECT col1 * cor0.col1 * col2 + cor0.col0 DIV cor0.col0 + ( col2 ) AS col0 FROM tab0 AS cor0
----
244102
679125
9411

skipif mysql # not compatible
query I rowsort label-4584
SELECT col1 * cor0.col1 * col2 + cor0.col0 / cor0.col0 + ( col2 ) AS col0 FROM tab0 AS cor0
----
244102
679125
9411

query I rowsort
SELECT ALL - - ( + col0 ) AS col2 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + 24 * col2 AS col2 FROM tab1 AS cor0
----
1296
1368
2304

query I rowsort
SELECT - ( + col2 ) * col0 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - + cor0.col2 * + col0 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + col2 * + col0 col0 FROM tab1 cor0
----
-36480
-4212
-99840

query I rowsort
SELECT + 29 * - col0 * col0 AS col2 FROM tab0
----
-16704
-229709
-35525

query I rowsort
SELECT + 10 * - col0 AS col2 FROM tab1
----
-30
-640
-800

onlyif mysql # use DIV operator for integer division
query I rowsort label-4592
SELECT DISTINCT + 17 DIV + col0 AS col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-4592
SELECT DISTINCT + 17 / + col0 AS col1 FROM tab0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT DISTINCT - 97 AS col2 FROM tab2, tab0, tab1 AS cor0
----
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4595
SELECT ALL + ( - col2 ) / CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4595
SELECT ALL + ( - col2 ) / CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - + col1 + 91 FROM tab2 AS cor0
----
32
60
74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * col0 col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT col1 + ( 38 ) AS col0 FROM tab2 AS cor0
----
55
69
97

query I rowsort
SELECT DISTINCT col2 * + 99 AS col2 FROM tab2
----
2574
2673
3762

query I rowsort
SELECT col0 - 85 FROM tab1
----
-21
-5
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4601
SELECT + cor0.col2 * CAST( col1 AS SIGNED ) + col2 DIV + ( col0 ) + + col2 AS col1 FROM tab0 cor0
----
2872
7544
98

skipif mysql # not compatible
query I rowsort label-4601
SELECT + cor0.col2 * CAST ( col1 AS INTEGER ) + col2 / + ( col0 ) + + col2 AS col1 FROM tab0 cor0
----
2872
7544
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col1 * col2 col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL - - 58 * col2 AS col0 FROM tab2 AS cor0
----
1508
1566
2204

query I rowsort
SELECT col2 - + col1 FROM tab0 cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4605
SELECT DISTINCT + - ( 40 ) DIV col0 AS col2 FROM tab2 AS cor0
----
-5
0

skipif mysql # not compatible
query I rowsort label-4605
SELECT DISTINCT + - ( 40 ) / col0 AS col2 FROM tab2 AS cor0
----
-5
0

query I rowsort
SELECT DISTINCT 28 * - col2 * + col1 + col1 AS col2 FROM tab2 cor0
----
-18071
-23405
-42893

query I rowsort
SELECT col2 * col2 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT ALL 7 + - col1 AS col2 FROM tab0 AS cor0
----
-79
-84
-90

query I rowsort
SELECT ( col0 ) + - col2 FROM tab2 AS cor0
----
-20
41
52

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 cor0 CROSS JOIN tab0, tab1 AS cor1
----
972 values hashing to 0210050fb1701e2797a9b17e1ebac91e

query I rowsort
SELECT - cor0.col1 * col0 - - col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT - 44 + 42 FROM tab1 AS cor0
----
-2
-2
-2

query I rowsort
SELECT + + ( cor0.col2 ) AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - col0 + - col0 + col1 AS col1 FROM tab2 AS cor0
----
-141
-97
17

query I rowsort
SELECT + col1 * + col1 - cor0.col0 * col2 AS col0 FROM tab2 AS cor0
----
-2713
1453
772

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4616
SELECT - col0 + col0 + - CAST( 7 AS SIGNED ) * col2 AS col0 FROM tab0 AS cor0
----
-231
-574
-7

skipif mysql # not compatible
query I rowsort label-4616
SELECT - col0 + col0 + - CAST ( 7 AS INTEGER ) * col2 AS col0 FROM tab0 AS cor0
----
-231
-574
-7

query I rowsort
SELECT col1 + col1 AS col2 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT DISTINCT + 92 AS col1 FROM tab0, tab1 AS cor0 CROSS JOIN tab1
----
92

query I rowsort
SELECT - cor1.col0 AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT + 33 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT ALL + col1 * 66 * - col1 FROM tab2 AS cor0
----
-19074
-229746
-63426

query I rowsort
SELECT ALL - - col1 - 83 FROM tab0 AS cor0
----
14
3
8

query I rowsort
SELECT DISTINCT - ( col0 ) + col2 AS col1 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT + - col1 + - col1 * - cor0.col1 AS col2 FROM tab2 cor0
----
272
3422
930

query I rowsort
SELECT ALL - + cor0.col0 - + col0 AS col1 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT ALL + - col0 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - col0 + cor0.col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + ( col2 ) * - col2 AS col1 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT - col0 + col0 * col2 AS col2 FROM tab1 AS cor0
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-4630
SELECT ALL col2 DIV 48 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4630
SELECT ALL col2 / 48 FROM tab0 AS cor0
----
0
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4631
SELECT + CAST( col1 AS SIGNED ) * col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-4631
SELECT + CAST ( col1 AS INTEGER ) * col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - col2 + - cor0.col1 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4633
SELECT DISTINCT - CAST( NULL AS SIGNED ) * 87 AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4633
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * 87 AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT col1 + col1 - col2 * col2 FROM tab0
----
-6542
-917
193

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - ( 72 * - col1 ) col1 FROM tab1
----
1032
1926
777

query I rowsort
SELECT col2 * - 63 AS col2 FROM tab2
----
-1638
-1701
-2394

query I rowsort
SELECT - 58 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to a38440572743ed8a3d8af7b49a5388c9

query I rowsort
SELECT DISTINCT col1 + ( - col1 ) - col2 AS col0 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT + 61 AS col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab0 cor1
----
972 values hashing to 09b120a8ff13ebafea7af10c2152241b

onlyif mysql # use DIV operator for integer division
query I rowsort label-4641
SELECT - col0 DIV + col1 AS col2 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-4641
SELECT - col0 / + col1 AS col2 FROM tab2
----
-1
-4
0

query I rowsort
SELECT ALL col0 * - 48 * + cor0.col0 + - col0 * - col1 AS col0 FROM tab1 AS cor0
----
-195968
-306160
-354

query I rowsort
SELECT col1 + - col0 * col0 AS col2 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT + + cor0.col1 + + col1 * cor0.col0 AS col0 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4645
SELECT ALL + col1 + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4645
SELECT ALL + col1 + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 + - ( 97 ) * - col0 FROM tab1 cor0
----
317
6218
7773

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * - cor0.col2 + + col1 col2 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT - + 29 FROM tab1, tab1 AS cor0
----
9 values hashing to 0cc9ddad93fc783055518ae4b6be054b

query I rowsort
SELECT ALL col1 * tab1.col2 + 19 + col1 AS col1 FROM tab1
----
1280
1449
599

query I rowsort
SELECT 14 AS col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 409c1790b702540dd9dc067c1965b7c0

query I rowsort
SELECT ALL 12 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

onlyif mysql # use DIV operator for integer division
query I rowsort label-4652
SELECT DISTINCT + + col2 DIV - ( ( - col1 ) ) + + col0 FROM tab2 cor0
----
7
78
81

skipif mysql # not compatible
query I rowsort label-4652
SELECT DISTINCT + + col2 / - ( ( - col1 ) ) + + col0 FROM tab2 cor0
----
7
78
81

query I rowsort
SELECT ALL + + col1 + col1 * - col2 * - col1 FROM tab2 AS cor0
----
10999
25978
90565

onlyif mysql # use DIV operator for integer division
query I rowsort label-4654
SELECT DISTINCT - col1 * - col0 + cor0.col2 DIV col0 FROM tab0 AS cor0
----
2065
3395
8099

skipif mysql # not compatible
query I rowsort label-4654
SELECT DISTINCT - col1 * - col0 + cor0.col2 / col0 FROM tab0 AS cor0
----
2065
3395
8099

query I rowsort
SELECT DISTINCT - cor0.col1 + col1 AS col1 FROM tab2 cor0
----
0

query I rowsort
SELECT ALL - col0 + 71 FROM tab2 AS cor0
----
-7
-8
64

query I rowsort
SELECT ALL - col2 * 58 FROM tab1 AS cor0
----
-3132
-3306
-5568

query I rowsort
SELECT DISTINCT col1 * - 57 + 30 FROM tab2 AS cor0
----
-1737
-3333
-939

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4659
SELECT ALL col2 + + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4659
SELECT ALL col2 + + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4660
SELECT + col1 * 89 DIV col2 + + col1 * - ( cor0.col2 ) + col2 col2 FROM tab0 AS cor0
----
-2574
-7282
8537

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4660
SELECT + col1 * 89 / col2 + + col1 * - ( cor0.col2 ) + col2 col2 FROM tab0 AS cor0
----
-2574
-7282
8537

query I rowsort
SELECT + col2 * - 55 * + col2 + 87 + col2 AS col0 FROM tab2 AS cor0
----
-37067
-39981
-79295

onlyif mysql # use DIV operator for integer division
query I rowsort label-4662
SELECT DISTINCT + 76 DIV + cor0.col0 FROM tab0 AS cor0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-4662
SELECT DISTINCT + 76 / + cor0.col0 FROM tab0 AS cor0
----
0
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-4663
SELECT + ( 11 ) DIV col2 + + col2 AS col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-4663
SELECT + ( 11 ) / col2 + + col2 AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - - col2 * col2 + col2 AS col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT ALL - ( + col1 ) + col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + - cor0.col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

onlyif mysql # use DIV operator for integer division
query I rowsort label-4667
SELECT + + 98 DIV - col2 + - col1 * + col1 AS col2 FROM tab0 AS cor0
----
-7398
-8282
-9507

skipif mysql # not compatible
query I rowsort label-4667
SELECT + + 98 / - col2 + - col1 * + col1 AS col2 FROM tab0 AS cor0
----
-7398
-8282
-9507

onlyif mysql # use DIV operator for integer division
query I rowsort label-4668
SELECT ALL + cor0.col1 + - ( col1 ) DIV col0 col2 FROM tab1 cor0
----
10
13
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4668
SELECT ALL + cor0.col1 + - ( col1 ) / col0 col2 FROM tab1 cor0
----
10
13
18

query I rowsort
SELECT + - 76 * - col0 - col2 FROM tab1 AS cor0
----
174
4807
5984

query I rowsort
SELECT ALL + 33 + + col0 AS col0 FROM tab2 cor0
----
111
112
40

query I rowsort
SELECT ALL - 20 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to eb3a66728062963cccbd15bd2f5c9eee

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - cor0.col1 col2 FROM tab1 AS cor0
----
-109
-67
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col0 col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4674
SELECT ALL + - ( - col0 ) * - CAST( NULL AS SIGNED ) * col0 + - col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4674
SELECT ALL + - ( - col0 ) * - CAST ( NULL AS INTEGER ) * col0 + - col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col2 - + col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT col2 * + 76 FROM tab2 AS cor0
----
1976
2052
2888

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col1 col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL + - col1 + ( col1 ) AS col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4679
SELECT ALL + + col0 DIV + 36 + col1 AS col0 FROM tab0 cor0
----
86
93
97

skipif mysql # not compatible
query I rowsort label-4679
SELECT ALL + + col0 / + 36 + col1 AS col0 FROM tab0 cor0
----
86
93
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4680
SELECT ALL + col2 * ( - 88 ) + col1 - - CAST( - col2 * + col2 AS SIGNED ) FROM tab2 AS cor0
----
-2905
-3074
-4771

skipif mysql # not compatible
query I rowsort label-4680
SELECT ALL + col2 * ( - 88 ) + col1 - - CAST ( - col2 * + col2 AS INTEGER ) FROM tab2 AS cor0
----
-2905
-3074
-4771

onlyif mysql # use DIV operator for integer division
query I rowsort label-4681
SELECT DISTINCT + cor0.col0 DIV + col2 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-4681
SELECT DISTINCT + cor0.col0 / + col2 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT DISTINCT - col1 * 53 * + 44 + + cor0.col2 FROM tab2 AS cor0
----
-137562
-39606
-72265

query I rowsort
SELECT + + col1 * col2 + - 77 FROM tab2 cor0
----
1457
569
760

onlyif mysql # use DIV operator for integer division
query I rowsort label-4684
SELECT - col0 DIV - col2 + - col2 AS col0 FROM tab0
----
-33
-81
34

skipif mysql # not compatible
query I rowsort label-4684
SELECT - col0 / - col2 + - col2 AS col0 FROM tab0
----
-33
-81
34

query I rowsort
SELECT 90 FROM tab1, tab0 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT ALL 4 * col2 + col1 AS col1 FROM tab1 AS cor0
----
238
242
397

query I rowsort
SELECT - col1 * ( + col2 ) + - cor0.col2 AS col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT 48 AS col0 FROM tab2
----
48
48
48

query I rowsort
SELECT ALL - 14 * col2 + col0 AS col2 FROM tab1 AS cor0
----
-1264
-734
-753

query I rowsort
SELECT ALL - + 54 * - col1 + - col1 FROM tab2 cor0
----
1643
3127
901

query I rowsort
SELECT col2 * col0 + + col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT + + ( cor0.col0 ) + col1 AS col1 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4693
SELECT + col1 + - col1 DIV + col2 AS col2 FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4693
SELECT + col1 + - col1 / + col2 AS col2 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT - 28 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to c3e7fa3d059fc708f03c60e9cef0c115

query I rowsort
SELECT 63 * 18 * + col2 + col0 FROM tab2
----
29562
30625
43171

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 92 col2 FROM tab2
----
92
92
92

query I rowsort
SELECT DISTINCT - 73 * col0 FROM tab0
----
-1752
-2555
-6497

onlyif mysql # use DIV operator for integer division
query I rowsort label-4698
SELECT + ( + tab1.col2 ) + col1 DIV col0 col0 FROM tab1
----
57
62
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4698
SELECT + ( + tab1.col2 ) + col1 / col0 col0 FROM tab1
----
57
62
96

query I rowsort
SELECT ALL + 2 FROM tab0
----
2
2
2

query I rowsort
SELECT DISTINCT + + cor0.col0 * 89 + + 60 - - col1 AS col0 FROM tab0 AS cor0
----
2282
3272
8072

query I rowsort
SELECT DISTINCT col1 + 35 FROM tab0 AS cor0
----
121
126
132

query I rowsort
SELECT cor0.col1 * ( - 60 ) AS col0 FROM tab1 AS cor0
----
-1560
-600
-780

query I rowsort
SELECT DISTINCT - + col0 * 49 FROM tab0 AS cor0
----
-1176
-1715
-4361

query I rowsort
SELECT ALL - col1 + - 34 FROM tab0 AS cor0
----
-120
-125
-131

query I rowsort
SELECT DISTINCT + + col2 + + 14 FROM tab1 AS cor0
----
110
68
71

query I rowsort
SELECT DISTINCT - 58 + col1 - col1 FROM tab0
----
-58

query I rowsort
SELECT DISTINCT + 28 - - col2 * col2 * 83 AS col2 FROM tab0
----
111
558120
90415

query I rowsort
SELECT col1 + col2 * - tab1.col2 * col1 AS col2 FROM tab1
----
-119795
-32480
-75790

query I rowsort
SELECT + ( col2 ) + 4 FROM tab0
----
37
5
86

query I rowsort
SELECT 93 * - col1 FROM tab1
----
-1209
-2418
-930

query I rowsort
SELECT col2 * + col0 + + col0 + - tab1.col2 FROM tab1
----
111
3655
7664

onlyif mysql # use DIV operator for integer division
query I rowsort label-4712
SELECT + col2 * + tab1.col2 - 74 DIV - ( col1 ) FROM tab1
----
2918
3256
9221

skipif mysql # not compatible
query I rowsort label-4712
SELECT + col2 * + tab1.col2 - 74 / - ( col1 ) FROM tab1
----
2918
3256
9221

query I rowsort
SELECT - col0 * col0 + col0 * col1 AS col0 FROM tab1
----
-3456
-5360
69

query I rowsort
SELECT DISTINCT col1 + col2 + - ( col2 ) AS col1 FROM tab2
----
17
31
59

query I rowsort
SELECT DISTINCT + col0 * - col1 * 70 + tab1.col1 * + col0 FROM tab1
----
-44160
-5382
-71760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4716
SELECT - CAST( NULL AS SIGNED ) / 12 AS col2 FROM tab0, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4716
SELECT - CAST ( NULL AS INTEGER ) / 12 AS col2 FROM tab0, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL - - col0 * col1 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - + col0 * + 2 * + col0 FROM tab0 AS cor0
----
-1152
-15842
-2450

query I rowsort
SELECT DISTINCT col2 + + ( + 73 ) AS col1 FROM tab0
----
106
155
74

query I rowsort
SELECT col0 * ( 77 * col0 ) + - col0 * col0 AS col0 FROM tab2
----
3724
462384
474316

query I rowsort
SELECT - - col2 * cor0.col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL col0 + col2 * col1 FROM tab1
----
1328
1407
634

query I rowsort
SELECT ALL col1 * col0 * col1 + - col1 + + col2 * - col1 FROM tab2
----
22168
269925
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + cor0.col2 * - col1 col1 FROM tab1 AS cor0
----
-1152
-1350
-513

onlyif mysql # use DIV operator for integer division
query I rowsort label-4725
SELECT - cor0.col2 DIV col0 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4725
SELECT - cor0.col2 / col0 FROM tab0 cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4726
SELECT DISTINCT + tab1.col0 * col2 DIV tab1.col0 col2 FROM tab1
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4726
SELECT DISTINCT + tab1.col0 * col2 / tab1.col0 col2 FROM tab1
----
54
57
96

query I rowsort
SELECT - tab2.col1 * - col1 AS col2 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL + col1 * col0 AS col1 FROM tab2
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 + col1 col2 FROM tab0 cor0
----
2150
3492
8190

query I rowsort
SELECT ALL - col0 * col0 + - col0 AS col2 FROM tab1
----
-12
-4160
-6480

onlyif mysql # use DIV operator for integer division
query I rowsort label-4731
SELECT col2 DIV cor0.col1 + + col1 AS col1 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-4731
SELECT col2 / cor0.col1 + + col1 AS col1 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT - + col0 + col0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + 5 + + col2 FROM tab1 AS cor0
----
101
59
62

query I rowsort
SELECT DISTINCT - + col2 * col0 + col0 * col1 + - cor0.col0 FROM tab2 AS cor0
----
-1738
21
2496

query I rowsort
SELECT ALL ( + col2 ) * cor0.col1 + - col2 FROM tab2 cor0
----
1508
608
810

query I rowsort
SELECT - 51 AS col0 FROM tab0
----
-51
-51
-51

onlyif mysql # use DIV operator for integer division
query I rowsort label-4737
SELECT DISTINCT + col0 * + col2 + + col1 DIV col0 FROM tab2 AS cor0
----
193
2028
3002

skipif mysql # not compatible
query I rowsort label-4737
SELECT DISTINCT + col0 * + col2 + + col1 / col0 FROM tab2 AS cor0
----
193
2028
3002

query I rowsort
SELECT tab0.col2 FROM tab0, tab0 AS cor0 WHERE NULL = ( + cor0.col1 )
----

query I rowsort
SELECT ALL + col2 * + cor0.col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + + col1 + col1 * - col2 FROM tab0 AS cor0
----
-2752
-7371
0

query IIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0 WHERE NOT NULL = NULL
----

query I rowsort
SELECT ALL + 29 AS col2 FROM tab2
----
29
29
29

onlyif mysql # use DIV operator for integer division
query I rowsort label-4743
SELECT 82 DIV + col1 - col0 DIV 60 col2 FROM tab1 AS cor0
----
3
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4743
SELECT 82 / + col1 - col0 / 60 col2 FROM tab1 AS cor0
----
3
5
7

query I rowsort
SELECT DISTINCT - cor0.col2 + cor0.col0 + + 80 AS col0 FROM tab1 AS cor0
----
29
64
87

query I rowsort
SELECT DISTINCT - 36 * col2 AS col0 FROM tab1 AS cor0
----
-1944
-2052
-3456

query I rowsort
SELECT + 51 * col2 + + cor0.col2 FROM tab2 AS cor0
----
1352
1404
1976

query I rowsort
SELECT + col1 - - col2 AS col1 FROM tab1 AS cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 15 * + col1 + + cor0.col2 col2 FROM tab1 cor0
----
207
291
444

query I rowsort
SELECT DISTINCT - + 23 * cor0.col2 FROM tab1 AS cor0
----
-1242
-1311
-2208

query I rowsort
SELECT - cor0.col2 + + col2 * - 98 AS col2 FROM tab2 AS cor0
----
-2574
-2673
-3762

query I rowsort
SELECT ALL 63 FROM tab1 cor0
----
63
63
63

query I rowsort
SELECT 30 + - cor0.col0 * - cor0.col1 FROM tab2 AS cor0
----
1373
247
4632

query I rowsort
SELECT DISTINCT 15 - col2 AS col1 FROM tab2 AS cor0
----
-11
-12
-23

query I rowsort
SELECT - cor0.col2 + + col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * - col2 + col2 col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT col2 + col0 * - col0 + col1 AS col2 FROM tab2 cor0
----
-5999
-6186
9

query I rowsort
SELECT - 51 + + col0 AS col1 FROM tab1 AS cor0
----
-48
13
29

query I rowsort
SELECT DISTINCT + col2 + + ( - col2 ) + - col0 FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4759
SELECT col0 DIV 84 + + 7 * col2 FROM tab2 AS cor0
----
182
189
266

skipif mysql # not compatible
query I rowsort label-4759
SELECT col0 / 84 + + 7 * col2 FROM tab2 AS cor0
----
182
189
266

query I rowsort
SELECT - + col2 + - col1 AS col0 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT 87 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

onlyif mysql # use DIV operator for integer division
query I rowsort label-4762
SELECT DISTINCT - + cor0.col1 * - col2 + + 14 DIV col0 - CAST( 9 AS SIGNED ) * - col2 FROM tab2 AS cor0
----
1082
1768
988

skipif mysql # not compatible
query I rowsort label-4762
SELECT DISTINCT - + cor0.col1 * - col2 + + 14 / col0 - CAST ( 9 AS INTEGER ) * - col2 FROM tab2 AS cor0
----
1082
1768
988

query I rowsort
SELECT DISTINCT + ( col2 ) * + col0 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-4764
SELECT ALL + 5 DIV 85 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4764
SELECT ALL + 5 / 85 FROM tab1 AS cor0
----
0
0
0

query IIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 AS cor2
----
972 values hashing to 5621675b1bd32b061d284d0444c76601

query I rowsort
SELECT DISTINCT 0 AS col1 FROM tab0, tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT col2 * tab2.col1 FROM tab2
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4768
SELECT CAST( - col2 AS SIGNED ) AS col2 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-4768
SELECT CAST ( - col2 AS INTEGER ) AS col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT 6 * col2 * col0 + - 84 AS col0 FROM tab1
----
21804
45996
888

query I rowsort
SELECT DISTINCT 54 * + tab1.col2 AS col1 FROM tab1, tab2 AS cor0
----
2916
3078
5184

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4771
SELECT + col1 + - col0 * - col2 * CAST( col1 + col2 AS SIGNED ) FROM tab0 AS cor0
----
1262645
3527
94334

skipif mysql # not compatible
query I rowsort label-4771
SELECT + col1 + - col0 * - col2 * CAST ( col1 + col2 AS INTEGER ) FROM tab0 AS cor0
----
1262645
3527
94334

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( cor0.col1 ) + - 42 col0 FROM tab0, tab1 AS cor0
----
-16
-29
-32

query I rowsort
SELECT - 45 AS col0 FROM tab1 AS cor0
----
-45
-45
-45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4774
SELECT + - CAST( 8 AS SIGNED ) * col2 * - 34 AS col0 FROM tab1 AS cor0
----
14688
15504
26112

skipif mysql # not compatible
query I rowsort label-4774
SELECT + - CAST ( 8 AS INTEGER ) * col2 * - 34 AS col0 FROM tab1 AS cor0
----
14688
15504
26112

query I rowsort
SELECT + cor1.col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4776
SELECT - CAST( 68 AS SIGNED ) + + col2 AS col1 FROM tab1
----
-11
-14
28

skipif mysql # not compatible
query I rowsort label-4776
SELECT - CAST ( 68 AS INTEGER ) + + col2 AS col1 FROM tab1
----
-11
-14
28

query I rowsort
SELECT 50 AS col2 FROM tab1
----
50
50
50

query I rowsort
SELECT DISTINCT + 56 * col0 * col0 FROM tab2
----
2744
340704
349496

query I rowsort
SELECT - - col2 + + col1 * + col2 AS col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT - col2 + 0 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT + cor0.col1 * + cor0.col2 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4782
SELECT ALL 1 + col1 DIV 41 AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4782
SELECT ALL 1 + col1 / 41 AS col2 FROM tab1
----
1
1
1

query I rowsort
SELECT - 33 + cor0.col0 * + 95 FROM tab0 AS cor0
----
2247
3292
8422

query I rowsort
SELECT DISTINCT + 23 * - col0 AS col2 FROM tab2 AS cor0
----
-161
-1794
-1817

query I rowsort
SELECT - 86 * col1 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
-1500
-2693
-5100

query I rowsort
SELECT ALL - 96 AS col2 FROM tab2 AS cor0
----
-96
-96
-96

query I rowsort
SELECT ALL cor0.col0 + ( 41 ) FROM tab2 AS cor0
----
119
120
48

query I rowsort
SELECT ALL col0 + col1 - + col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + - col0 - + col2 AS col1 FROM tab2 cor0
----
-104
-117
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + 10 + + 12 col2 FROM tab1 AS cor0
----
-118
-248
-88

query I rowsort
SELECT DISTINCT + + col1 * col2 + 84 * + cor0.col2 FROM tab1 AS cor0
----
5358
5940
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-4792
SELECT + col0 DIV ( col0 + cor0.col0 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4792
SELECT + col0 / ( col0 + cor0.col0 ) FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4793
SELECT ALL + CAST( - col0 AS SIGNED ) * + col1 * - ( 66 ) AS col2 FROM tab2 AS cor0
----
14322
303732
88638

skipif mysql # not compatible
query I rowsort label-4793
SELECT ALL + CAST ( - col0 AS INTEGER ) * + col1 * - ( 66 ) AS col2 FROM tab2 AS cor0
----
14322
303732
88638

query I rowsort
SELECT - 22 + - ( col0 ) * - col2 FROM tab0 cor0
----
13
7276
770

query I rowsort
SELECT ALL + col1 * 44 AS col0 FROM tab0 AS cor0
----
3784
4004
4268

query I rowsort
SELECT DISTINCT 79 * + col2 AS col0 FROM tab0 AS cor0
----
2607
6478
79

query I rowsort
SELECT DISTINCT + col1 + 41 * col2 FROM tab1 cor0
----
2240
2347
3949

query I rowsort
SELECT ALL - 31 AS col1 FROM tab2 AS cor0
----
-31
-31
-31

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + cor0.col0 AS REAL ) FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4800
SELECT DISTINCT - cor0.col2 DIV + 46 + - col1 AS col2 FROM tab0 AS cor0
----
-86
-92
-97

skipif mysql # not compatible
query I rowsort label-4800
SELECT DISTINCT - cor0.col2 / + 46 + - col1 AS col2 FROM tab0 AS cor0
----
-86
-92
-97

query I rowsort
SELECT ALL 29 FROM tab0 cor0
----
29
29
29

query I rowsort
SELECT ALL col0 + + 1 FROM tab2
----
79
8
80

query I rowsort
SELECT - - 28 * col2 + + col2 * - col0 AS col2 FROM tab0 cor0
----
-5002
-7
132

query I rowsort
SELECT ALL + - 28 * col2 FROM tab0 AS cor0
----
-2296
-28
-924

query I rowsort
SELECT - ( + 77 ) AS col0 FROM tab0 cor0
----
-77
-77
-77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4806
SELECT ALL - CAST( - col2 AS SIGNED ) * col2 FROM tab2 AS cor0
----
1444
676
729

skipif mysql # not compatible
query I rowsort label-4806
SELECT ALL - CAST ( - col2 AS INTEGER ) * col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT cor0.col0 + + cor0.col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + tab0.col0 + 38 AS col2 FROM tab0, tab0 AS cor0
----
127
62
73

query I rowsort
SELECT col2 * + 34 AS col2 FROM tab1
----
1836
1938
3264

query I rowsort
SELECT - col0 * 31 - - col1 * - col1 FROM tab1 AS cor0
----
-2084
-2649
-769

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4811
SELECT ALL col2 * + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4811
SELECT ALL col2 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 + 2 AS col1 FROM tab1 AS cor0
----
12
15
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 1 col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

query I rowsort
SELECT DISTINCT - col0 + - col0 * cor0.col2 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT col1 * col1 * col2 + col1 FROM tab1 AS cor0
----
16237
36530
5710

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT + 99 * col0 + col0 AS col2 FROM tab2 cor0
----
700
7800
7900

query I rowsort
SELECT - col1 + col1 + + col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT - + ( - col2 ) * - col0 + col2 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT + - 49 FROM tab1 AS cor0
----
-49

query I rowsort
SELECT ALL + col2 + + col2 * col2 FROM tab1 AS cor0
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-4822
SELECT DISTINCT + - 77 DIV col0 FROM tab0 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-4822
SELECT DISTINCT + - 77 / col0 FROM tab0 AS cor0
----
-2
-3
0

query I rowsort
SELECT ALL - + cor0.col0 + + ( col2 ) FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4824
SELECT DISTINCT + - col2 DIV - ( - col0 ) AS col0 FROM tab0 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-4824
SELECT DISTINCT + - col2 / - ( - col0 ) AS col0 FROM tab0 cor0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col2 + + col1 col1 FROM tab1
----
109
67
80

query I rowsort
SELECT col0 + + tab0.col1 FROM tab0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-4827
SELECT col2 * col2 DIV 36 AS col2 FROM tab2 AS cor0
----
18
20
40

skipif mysql # not compatible
query I rowsort label-4827
SELECT col2 * col2 / 36 AS col2 FROM tab2 AS cor0
----
18
20
40

query I rowsort
SELECT - cor0.col1 + col0 * - col1 * col2 FROM tab2 AS cor0
----
-119711
-51051
-5890

query I rowsort
SELECT col1 * tab1.col0 + + col0 * col0 AS col2 FROM tab1
----
4736
7440
87

query I rowsort
SELECT DISTINCT cor1.col1 FROM tab1, tab1 cor0, tab0 AS cor1
----
86
91
97

query I rowsort
SELECT - ( 27 ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 90b76caf54a4e48ee4a9784f52997a6a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - ( + col2 + col2 ) * - cor0.col1 col1 FROM tab0 AS cor0
----
-1223768
-187308
-194

query I rowsort
SELECT ALL - col0 + ( col2 ) AS col2 FROM tab2 AS cor0
----
-41
-52
20

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0, tab1 cor1, tab1, tab0 AS cor2
----
3645 values hashing to 3b4587ab6c08d2179c6df094d2f76ad7

query I rowsort
SELECT DISTINCT + ( - col0 ) AS col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT 50 * 70 + + col2 FROM tab1 AS cor0
----
3554
3557
3596

onlyif mysql # use DIV operator for integer division
query I rowsort label-4837
SELECT ALL + + cor0.col0 DIV col2 - cor0.col2 AS col1 FROM tab1 AS cor0
----
-54
-56
-96

skipif mysql # not compatible
query I rowsort label-4837
SELECT ALL + + cor0.col0 / col2 - cor0.col2 AS col1 FROM tab1 AS cor0
----
-54
-56
-96

query I rowsort
SELECT - col2 * col1 + - col0 AS col1 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT ALL - + 46 * ( + col1 ) FROM tab1 cor0
----
-1196
-460
-598

query I rowsort
SELECT 22 * col0 + + col2 * + col1 FROM tab1 cor0
----
1470
1978
3008

query I rowsort
SELECT - + col2 * 70 - col1 FROM tab2 AS cor0
----
-1879
-1921
-2677

query I rowsort
SELECT 97 + - col0 FROM tab0 AS cor0
----
62
73
8

query I rowsort
SELECT DISTINCT ( + col1 ) + col0 * 86 FROM tab2 AS cor0
----
633
6767
6811

onlyif mysql # use DIV operator for integer division
query I rowsort label-4844
SELECT DISTINCT + ( cor0.col2 ) * col2 + cor0.col1 DIV + cor0.col0 AS col1 FROM tab1 AS cor0
----
2924
3249
9216

skipif mysql # not compatible
query I rowsort label-4844
SELECT DISTINCT + ( cor0.col2 ) * col2 + cor0.col1 / + cor0.col0 AS col1 FROM tab1 AS cor0
----
2924
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4845
SELECT ALL + - CAST( NULL AS SIGNED ) + + cor0.col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4845
SELECT ALL + - CAST ( NULL AS INTEGER ) + + cor0.col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 28 * + 88 + - col0 FROM tab1 cor0
----
2384
2400
2461

query I rowsort
SELECT ALL ( - 7 ) AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to ba940cd66e21e94e95aada5f28e1faf5

query I rowsort
SELECT col1 + cor0.col1 * col2 * cor0.col1 FROM tab0 AS cor0
----
244154
679133
9506

query I rowsort
SELECT - + col1 + - col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT + 29 * col0 * - col2 FROM tab2 cor0
----
-5481
-58812
-87058

query I rowsort
SELECT ALL - col1 * - 57 FROM tab1
----
1482
570
741

query I rowsort
SELECT 36 AS col2 FROM tab2
----
36
36
36

query I rowsort
SELECT - col1 * col0 * - col1 AS col1 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT + col2 + tab2.col1 * tab2.col2 FROM tab2
----
1560
684
864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + col1 ) * ( + col1 ) col0 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT + col1 * - col0 * - col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT ( tab2.col1 ) AS col2 FROM tab2
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4858
SELECT + CAST( NULL AS SIGNED ) * - 70 + + tab1.col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4858
SELECT + CAST ( NULL AS INTEGER ) * - 70 + + tab1.col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT 50 * - tab1.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 6db5ca93d5facf44cc4fe562a982ec50

query I rowsort
SELECT 58 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT DISTINCT 99 AS col0 FROM tab1
----
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-4862
SELECT + 66 DIV 47 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4862
SELECT + 66 / 47 AS col0 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4863
SELECT + cor0.col2 + + 66 DIV + col2 FROM tab0 AS cor0
----
35
67
82

skipif mysql # not compatible
query I rowsort label-4863
SELECT + cor0.col2 + + 66 / + col2 FROM tab0 AS cor0
----
35
67
82

query I rowsort
SELECT - - ( + cor0.col1 ) FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - ( - cor0.col1 ) + - col2 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT 97 + + tab0.col2 * - col1 AS col1 FROM tab0
----
-2741
-7365
0

query I rowsort
SELECT 77 FROM tab0, tab1 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

onlyif mysql # use DIV operator for integer division
query I rowsort label-4868
SELECT col1 * col1 DIV CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
1
1
12

skipif mysql # not compatible
query I rowsort label-4868
SELECT col1 * col1 / CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
1
1
12

query I rowsort
SELECT + + col2 - col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT - cor0.col0 + + col2 - ( + col2 + - col0 ) * col0 * col2 FROM tab2 AS cor0
----
-3760
105404
123041

query I rowsort
SELECT DISTINCT + - col2 * - col2 + 58 AS col2 FROM tab2 AS cor0
----
1502
734
787

query I rowsort
SELECT + 78 * col1 FROM tab0 AS cor0
----
6708
7098
7566

query I rowsort
SELECT 41 * - col0 AS col0 FROM tab1 AS cor0
----
-123
-2624
-3280

query I rowsort
SELECT DISTINCT + + col0 * col2 * col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT tab1.col2 + + cor0.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 35de0b553e14f89ea44b7652e1ff642c

query I rowsort
SELECT - - col1 * + col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 10 col0 FROM tab0 AS cor0
----
10
10
10

query I rowsort
SELECT col0 * col2 + - col2 - 74 FROM tab1 AS cor0
----
34
3517
7510

query I rowsort
SELECT 24 + col2 AS col1 FROM tab1 AS cor0
----
120
78
81

query I rowsort
SELECT - 27 AS col1 FROM tab2 cor0
----
-27
-27
-27

query I rowsort
SELECT DISTINCT + + 37 * cor0.col0 * + 72 FROM tab1 AS cor0
----
170496
213120
7992

query I rowsort
SELECT ALL - 28 FROM tab1 cor0
----
-28
-28
-28

query I rowsort
SELECT + + 26 * col1 AS col2 FROM tab1 AS cor0
----
260
338
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-4884
SELECT + - col1 + ( col2 ) DIV + col0 col2 FROM tab1 cor0
----
-10
-12
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4884
SELECT + - col1 + ( col2 ) / + col0 col2 FROM tab1 cor0
----
-10
-12
-8

query I rowsort
SELECT col2 + - col0 * cor0.col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT + col1 * col0 * col0 + col0 * + col1 FROM tab2
----
107440
1736
363558

query I rowsort
SELECT ALL - cor0.col1 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT + tab1.col0 - - col0 * - col2 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT + col1 * 40 + - cor0.col0 FROM tab2 AS cor0
----
1233
2282
601

query I rowsort
SELECT ALL - - col0 + - ( - col2 ) * + col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT - col2 + + 62 AS col1 FROM tab0 AS cor0
----
-20
29
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-4892
SELECT DISTINCT col2 DIV ( col1 + col1 ) AS col1 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-4892
SELECT DISTINCT col2 / ( col1 + col1 ) AS col1 FROM tab0 cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4893
SELECT - cor0.col2 + CAST( ( - col2 ) AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-164
-2
-66

skipif mysql # not compatible
query I rowsort label-4893
SELECT - cor0.col2 + CAST ( ( - col2 ) AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-164
-2
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-4894
SELECT DISTINCT col0 + - ( + 83 ) DIV col2 AS col2 FROM tab1 AS cor0
----
2
63
80

skipif mysql # not compatible
query I rowsort label-4894
SELECT DISTINCT col0 + - ( + 83 ) / col2 AS col2 FROM tab1 AS cor0
----
2
63
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * 42 + cor0.col1 col0 FROM tab0 AS cor0
----
1094
1567
3829

query I rowsort
SELECT DISTINCT - 42 * col1 * col1 FROM tab2 AS cor0
----
-12138
-146202
-40362

query I rowsort
SELECT DISTINCT + 44 + + 84 FROM tab1, tab1 AS cor0
----
128

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 61 * + col0 col2 FROM tab0 AS cor0
----
-1464
-2135
-5429

query I rowsort
SELECT + cor0.col2 * - 57 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 7ab6a49f65b0dc01c7c572ba5c21131f

query I rowsort
SELECT DISTINCT col1 * - ( - col2 ) AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + 11 AS col1 FROM tab2 AS cor0
----
11

query I rowsort
SELECT ALL 0 * + 77 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT + cor0.col1 + - 55 FROM tab1 AS cor0 CROSS JOIN tab0, tab2 cor1
----
-29
-42
-45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4904
SELECT DISTINCT - - CAST( + col2 AS SIGNED ) AS col0 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4904
SELECT DISTINCT - - CAST ( + col2 AS INTEGER ) AS col0 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT + col1 + + 59 * - col2 FROM tab2 AS cor0
----
-1475
-1562
-2225

query I rowsort
SELECT ALL + col0 * col2 + - col0 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT ALL col1 + - ( + col0 + col0 * - cor0.col2 ) FROM tab2 AS cor0
----
2009
213
2940

query I rowsort
SELECT DISTINCT - col2 + + ( col2 ) FROM tab2 cor0
----
0

query I rowsort
SELECT DISTINCT - ( - ( + col2 ) ) * + 14 FROM tab2 AS cor0
----
364
378
532

query I rowsort
SELECT - col1 * col2 + col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT 90 AS col2 FROM tab2 cor0
----
90
90
90

query I rowsort
SELECT DISTINCT + 37 + cor0.col1 * col0 + - 2 * - cor0.col1 * - col2 FROM tab0 cor0
----
-3575
-6788
3238

onlyif mysql # use DIV operator for integer division
query I rowsort label-4913
SELECT ALL ( col0 ) + col0 * cor0.col1 - + cor0.col2 DIV + col1 FROM tab0 cor0
----
2088
3430
8188

skipif mysql # not compatible
query I rowsort label-4913
SELECT ALL ( col0 ) + col0 * cor0.col1 - + cor0.col2 / + col1 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT ALL - col0 + + tab1.col0 * col2 FROM tab1
----
159
3584
7600

query I rowsort
SELECT DISTINCT col1 + col0 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT - col0 + + col2 * col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT ALL + col0 + + col2 * - col2 + - col2 FROM tab0 AS cor0
----
-1098
-6717
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-4918
SELECT + - ( col0 ) DIV - col0 + col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-4918
SELECT + - ( col0 ) / - col0 + col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( + 28 AS REAL ) * + col1 + + ( col2 ) AS col2 FROM tab2 cor0
----
1678
514
895

query I rowsort
SELECT + + col2 + - ( - 11 ) * + col2 - - 19 FROM tab1 cor0
----
1171
667
703

query I rowsort
SELECT - col2 * cor0.col1 + + col0 * col0 AS col1 FROM tab2 AS cor0
----
-788
4550
5595

query I rowsort
SELECT + col1 * col1 + tab2.col0 FROM tab2
----
3559
368
968

query I rowsort
SELECT ALL + - 2 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

query I rowsort
SELECT DISTINCT - 59 FROM tab2, tab0 AS cor0
----
-59

query I rowsort
SELECT ALL + col2 * - 36 + - 68 * - col0 + 62 AS col0 FROM tab1
----
-1678
2046
2362

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4926
SELECT ALL + col2 + + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4926
SELECT ALL + col2 + + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - cor0.col2 * + col0 * col0 FROM tab1 cor0
----
-233472
-486
-614400

query I rowsort
SELECT - + col0 + col1 * + col2 AS col0 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT col0 * tab1.col1 + + 40 FROM tab1
----
1080
118
680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4930
SELECT ALL + col0 * col1 + col1 DIV col1 FROM tab2 AS cor0
----
1344
218
4603

skipif mysql # not compatible
query I rowsort label-4930
SELECT ALL + col0 * col1 + col1 / col1 FROM tab2 AS cor0
----
1344
218
4603

query I rowsort
SELECT ALL - col2 + + 60 * 45 AS col0 FROM tab1 cor0
----
2604
2643
2646

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + cor0.col0 * col0 + - 13 * col0 col2 FROM tab0 AS cor0
----
297
6846
771

query I rowsort
SELECT - 40 + 49 AS col0 FROM tab1
----
9
9
9

query I rowsort
SELECT ALL - col0 * + col1 AS col2 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT ALL 15 + + tab1.col2 FROM tab1
----
111
69
72

query I rowsort
SELECT - col1 * col0 + 86 * 3 AS col2 FROM tab1 AS cor0
----
-382
-782
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-4937
SELECT col2 + col2 DIV col0 AS col0 FROM tab2 AS cor0
----
26
30
38

skipif mysql # not compatible
query I rowsort label-4937
SELECT col2 + col2 / col0 AS col0 FROM tab2 AS cor0
----
26
30
38

query I rowsort
SELECT - cor0.col2 * col0 AS col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - - col1 + col1 * + col0 FROM tab1 cor0
----
104
1053
650

query I rowsort
SELECT ALL col0 + col2 AS col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT ALL + cor0.col0 + - ( + col0 ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col1 + + 77 FROM tab0 AS cor0
----
-14
-20
-9

query I rowsort
SELECT ALL - 48 + 7 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 4ba0c102091f9cbc9fe9439b04584e70

onlyif mysql # use DIV operator for integer division
query I rowsort label-4944
SELECT - col0 * - col1 + 64 DIV - col2 AS col0 FROM tab0
----
2063
3331
8099

skipif mysql # not compatible
query I rowsort label-4944
SELECT - col0 * - col1 + 64 / - col2 AS col0 FROM tab0
----
2063
3331
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-4945
SELECT DISTINCT - col2 DIV - ( col0 * col1 ) FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-4945
SELECT DISTINCT - col2 / - ( col0 * col1 ) FROM tab2
----
0

query I rowsort
SELECT - 30 AS col0 FROM tab2, tab1, tab2 AS cor0, tab1 AS cor1
----
81 values hashing to 6993f5c634597e63319c949df6b4733d

query I rowsort
SELECT DISTINCT - + col2 + col2 AS col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL + + ( 4 ) * - cor0.col2 FROM tab1 AS cor0
----
-216
-228
-384

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 46 col0 FROM tab2 AS cor0
----
46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 44 col1 FROM tab1 cor0
----
-44
-44
-44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4951
SELECT ALL - CAST( 84 AS SIGNED ) * col2 + + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4951
SELECT ALL - CAST ( 84 AS INTEGER ) * col2 + + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 31 * - col2 FROM tab0 AS cor0
----
-1023
-2542
-31

query I rowsort
SELECT ALL + ( 75 ) FROM tab1 cor0
----
75
75
75

query I rowsort
SELECT DISTINCT - - 61 AS col2 FROM tab1 AS cor0
----
61

query I rowsort
SELECT ALL col2 + + col1 * - col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT col2 * col0 + col0 AS col1 FROM tab1 cor0
----
165
3712
7760

query I rowsort
SELECT + + col0 * ( + col1 ) AS col0 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4958
SELECT + + CAST( NULL AS SIGNED ) / - col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4958
SELECT + + CAST ( NULL AS INTEGER ) / - col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 7 * cor0.col0 FROM tab1 AS cor0
----
21
448
560

query I rowsort
SELECT - ( - ( + cor0.col1 ) ) AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL - col1 * 53 FROM tab0
----
-4558
-4823
-5141

query I rowsort
SELECT - 45 * 71 FROM tab0 AS cor0
----
-3195
-3195
-3195

query I rowsort
SELECT - 84 + 22 FROM tab0 AS cor0
----
-62
-62
-62

query I rowsort
SELECT + 23 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

query I rowsort
SELECT DISTINCT 59 FROM tab2, tab0, tab0 AS cor0
----
59

query I rowsort
SELECT DISTINCT + + 22 + col2 FROM tab0 AS cor0
----
104
23
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-4967
SELECT - + col1 * cor0.col1 DIV - col1 AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4967
SELECT - + col1 * cor0.col1 / - col1 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT - 72 + + col2 * + col0 AS col0 FROM tab2 AS cor0
----
117
1956
2930

query I rowsort
SELECT 92 + + col0 AS col2 FROM tab1
----
156
172
95

query I rowsort
SELECT ALL - col1 + + 94 AS col0 FROM tab2 AS cor0
----
35
63
77

query I rowsort
SELECT ALL + col2 - 71 FROM tab2 AS cor0
----
-33
-44
-45

query I rowsort
SELECT col1 * - col1 + 42 FROM tab2 AS cor0
----
-247
-3439
-919

query I rowsort
SELECT + col0 * - col1 + + 70 FROM tab0 AS cor0
----
-1994
-3325
-8029

query I rowsort
SELECT + - col2 + - col2 FROM tab2 cor0
----
-52
-54
-76

query I rowsort
SELECT 38 * + col1 AS col1 FROM tab2
----
1178
2242
646

query I rowsort
SELECT ALL col2 + - col2 * - col2 * tab1.col1 FROM tab1
----
119904
32547
75870

query I rowsort
SELECT tab0.col1 * tab0.col0 + ( + ( col0 ) ) FROM tab0
----
2088
3430
8188

query I rowsort
SELECT cor0.col1 * - col2 - - col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT - col2 + 35 AS col2 FROM tab2 AS cor0
----
-3
8
9

query I rowsort
SELECT - col2 + + ( 37 ) FROM tab1 AS cor0
----
-17
-20
-59

query I rowsort
SELECT + col0 * + 21 FROM tab0 AS cor0
----
1869
504
735

query I rowsort
SELECT DISTINCT - cor0.col0 FROM tab1, tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT ALL col2 * col2 * col2 FROM tab0
----
1
35937
551368

query I rowsort
SELECT ALL - col0 + col2 * 63 AS col1 FROM tab0
----
2055
28
5077

query I rowsort
SELECT ALL col0 * - tab0.col2 + + col2 * col2 FROM tab0
----
-34
-574
297

query I rowsort
SELECT 5 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 * col1 * col1 col1 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-4988
SELECT ALL col2 DIV - CAST( + col1 AS SIGNED ) AS col2 FROM tab1 cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-4988
SELECT ALL col2 / - CAST ( + col1 AS INTEGER ) AS col2 FROM tab1 cor0
----
-2
-5
-7

query I rowsort
SELECT col1 * ( - cor0.col0 ) AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + - cor0.col2 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col2 + ( cor0.col2 ) * - col2 AS col1 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT ALL - col0 + 65 AS col1 FROM tab0 AS cor0
----
-24
30
41

query I rowsort
SELECT - col0 + cor0.col2 * col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT + col0 * - 79 FROM tab1 AS cor0
----
-237
-5056
-6320

query I rowsort
SELECT DISTINCT - - col2 * - 25 AS col0 FROM tab1 AS cor0
----
-1350
-1425
-2400

query I rowsort
SELECT DISTINCT tab1.col0 + col2 + - col0 * + col2 * col2 FROM tab1
----
-207815
-737104
-8691

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4997
SELECT - col2 + + tab1.col2 * - CAST( NULL AS DECIMAL ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4997
SELECT - col2 + + tab1.col2 * - CAST ( NULL AS REAL ) FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4998
SELECT ALL - col0 + col0 DIV - col0 AS col0 FROM tab2
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-4998
SELECT ALL - col0 + col0 / - col0 AS col0 FROM tab2
----
-79
-8
-80

query I rowsort
SELECT ALL col2 + - col0 + col2 * - col0 AS col1 FROM tab1
----
-111
-3655
-7664

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab2, tab2 AS cor0, tab0 cor1
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-5001
SELECT DISTINCT - col2 + - col1 DIV - col1 FROM tab0 AS cor0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-5001
SELECT DISTINCT - col2 + - col1 / - col1 FROM tab0 AS cor0
----
-32
-81
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5002
SELECT col1 * CAST( col0 * + col2 AS SIGNED ) FROM tab1 AS cor0
----
36480
4212
99840

skipif mysql # not compatible
query I rowsort label-5002
SELECT col1 * CAST ( col0 * + col2 AS INTEGER ) FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL col2 * + 51 * - 61 AS col2 FROM tab2 AS cor0
----
-118218
-80886
-83997

query I rowsort
SELECT + - col1 * col2 + col2 AS col0 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT + + col0 * col1 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT col1 * 11 FROM tab1 AS cor0
----
110
143
286

query I rowsort
SELECT DISTINCT + + col2 * + 62 FROM tab2 AS cor0
----
1612
1674
2356

query I rowsort
SELECT + col2 * ( + cor0.col1 ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + - col0 * - 14 * ( col1 ) FROM tab1 AS cor0
----
1092
14560
8960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5010
SELECT - col0 * col0 * col0 - CAST( + col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-13857
-42876
-705051

skipif mysql # not compatible
query I rowsort label-5010
SELECT - col0 * col0 * col0 - CAST ( + col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-13857
-42876
-705051

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5011
SELECT - + CAST( NULL AS SIGNED ) * + col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5011
SELECT - + CAST ( NULL AS INTEGER ) * + col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * - 7 + col1 + col1 AS col2 FROM tab1 AS cor0
----
-326
-379
-646

query I rowsort
SELECT DISTINCT + - 0 * col2 FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5014
SELECT DISTINCT 83 * col0 DIV col0 FROM tab1 cor0
----
83

skipif mysql # not compatible
query I rowsort label-5014
SELECT DISTINCT 83 * col0 / col0 FROM tab1 cor0
----
83

query I rowsort
SELECT - cor0.col2 + + col0 + 97 AS col1 FROM tab0 cor0
----
104
131
88

query I rowsort
SELECT + col2 * + col1 + col1 + + col2 AS col1 FROM tab1 AS cor0
----
1357
1484
637

query I rowsort
SELECT + + 26 AS col0 FROM tab2 cor0
----
26
26
26

query I rowsort
SELECT ALL - + 86 + - col0 AS col0 FROM tab1 AS cor0
----
-150
-166
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5019
SELECT ALL - + 20 DIV col1 AS col2 FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5019
SELECT ALL - + 20 / col1 AS col2 FROM tab2 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT - cor0.col1 + col0 AS col1 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT + 48 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT + col2 + + col0 - + ( col2 ) * - col2 AS col1 FROM tab0 cor0
----
1146
37
6895

query I rowsort
SELECT ALL - - cor0.col1 + + col2 * + 1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT - - 87 + - cor0.col1 FROM tab1 AS cor0
----
61
74
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-5025
SELECT DISTINCT + cor0.col1 + col1 DIV 71 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-5025
SELECT DISTINCT + cor0.col1 + col1 / 71 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - 38 + - col0 AS col1 FROM tab0 AS cor0
----
-127
-62
-73

query I rowsort
SELECT DISTINCT + 14 * col1 - + col2 FROM tab2 AS cor0
----
200
407
800

query I rowsort
SELECT ALL + - col1 * + col1 + + cor0.col2 + - col2 * col1 FROM tab0 AS cor0
----
-10201
-15661
-9505

query I rowsort
SELECT ALL - 40 + + col2 FROM tab1 AS cor0
----
14
17
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-5030
SELECT - 52 + col2 DIV + cor0.col1 FROM tab0 AS cor0
----
-52
-52
-52

skipif mysql # not compatible
query I rowsort label-5030
SELECT - 52 + col2 / + cor0.col1 FROM tab0 AS cor0
----
-52
-52
-52

query I rowsort
SELECT ALL - col2 + + col2 + 7 FROM tab1 AS cor0
----
7
7
7

query I rowsort
SELECT ALL + - col0 + col1 + col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT 48 * col1 AS col0 FROM tab2 cor0
----
1488
2832
816

query I rowsort
SELECT + col1 + col1 + + col1 FROM tab0 cor0
----
258
273
291

onlyif mysql # use DIV operator for integer division
query I rowsort label-5035
SELECT cor0.col0 * 54 + col0 + col2 * col1 DIV - col2 FROM tab1 AS cor0
----
139
3510
4387

skipif mysql # not compatible
query I rowsort label-5035
SELECT cor0.col0 * 54 + col0 + col2 * col1 / - col2 FROM tab1 AS cor0
----
139
3510
4387

query I rowsort
SELECT DISTINCT col2 + ( + cor0.col1 ) FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT - - col0 + - cor0.col1 * col2 * cor0.col1 AS col0 FROM tab0 AS cor0
----
-244044
-678953
-9374

query I rowsort
SELECT col1 * - col1 + col0 AS col2 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT DISTINCT + col1 + col0 * - col0 AS col0 FROM tab1
----
-4086
-6387
17

query I rowsort
SELECT + col0 * 15 * cor0.col0 AS col2 FROM tab2 cor0
----
735
91260
93615

query I rowsort
SELECT ALL cor0.col2 * - 63 + col2 * col2 FROM tab0 AS cor0
----
-62
-990
1558

query I rowsort
SELECT ALL cor1.col0 FROM tab1, tab2 cor0, tab2 cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL + col2 + cor0.col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - - col1 * - cor0.col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT col0 - ( 40 ) AS col0 FROM tab0
----
-16
-5
49

query I rowsort
SELECT DISTINCT - col1 * + cor0.col2 + col0 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + - 63 * col2 FROM tab2 AS cor0
----
-1638
-1701
-2394

query I rowsort
SELECT DISTINCT - col2 * col2 + col1 AS col1 FROM tab2 AS cor0
----
-1427
-617
-698

query I rowsort
SELECT - ( - col0 ) * - col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT + - 27 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 90b76caf54a4e48ee4a9784f52997a6a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col1 ) - - col2 col0 FROM tab1
----
28
47
83

query I rowsort
SELECT - 77 + col1 + col0 AS col2 FROM tab0
----
103
33
55

query I rowsort
SELECT + + 9 + - col0 * - col0 AS col2 FROM tab0 AS cor0
----
1234
585
7930

onlyif mysql # use DIV operator for integer division
query I rowsort label-5054
SELECT 38 DIV col0 - col2 * col1 FROM tab0
----
-2837
-7462
-96

skipif mysql # not compatible
query I rowsort label-5054
SELECT 38 / col0 - col2 * col1 FROM tab0
----
-2837
-7462
-96

query I rowsort
SELECT ( tab2.col0 * - col0 ) - 79 FROM tab2
----
-128
-6163
-6320

query I rowsort
SELECT ( - 66 * - col2 ) AS col1 FROM tab2
----
1716
1782
2508

query I rowsort
SELECT ALL + col0 * ( + col2 ) + + col2 AS col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT ALL 79 * cor0.col2 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to c2aacfdf4f2480a874e8b88315fbf830

onlyif mysql # use DIV operator for integer division
query I rowsort label-5059
SELECT ALL - col1 + + col0 DIV col1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-5059
SELECT ALL - col1 + + col0 / col1 FROM tab0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5060
SELECT DISTINCT + CAST( NULL AS SIGNED ) + col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5060
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + col1 FROM tab0
----
NULL

query I rowsort
SELECT ( col0 ) * + col2 + 76 FROM tab0
----
111
7374
868

query I rowsort
SELECT - col1 + - ( + col1 ) * + col0 AS col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + 9 + - cor0.col0 * - col2 col0 FROM tab0 AS cor0
----
-838
18
6479

query I rowsort
SELECT ALL + + col2 + cor0.col1 + - col1 AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT + col0 * + 89 AS col2 FROM tab1 AS cor0
----
267
5696
7120

query I rowsort
SELECT + cor1.col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT 17 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
17

query I rowsort
SELECT ALL col1 * - 65 AS col0 FROM tab1
----
-1690
-650
-845

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 30 * 54 col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 39e201e127f3a8b0f2aca124dc0c11e1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5070
SELECT - col0 DIV col1 + + 27 AS col1 FROM tab0 AS cor0
----
27
27
27

skipif mysql # not compatible
query I rowsort label-5070
SELECT - col0 / col1 + + 27 AS col1 FROM tab0 AS cor0
----
27
27
27

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5071
SELECT DISTINCT + CAST( - col2 AS SIGNED ) FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-5071
SELECT DISTINCT + CAST ( - col2 AS INTEGER ) FROM tab1
----
-54
-57
-96

query I rowsort
SELECT 42 AS col0 FROM tab1
----
42
42
42

query I rowsort
SELECT ALL + ( col0 * + col1 ) AS col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT col0 - - cor0.col1 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT 90 + + col2 * - 48 FROM tab1 AS cor0
----
-2502
-2646
-4518

query I rowsort
SELECT DISTINCT - cor0.col1 + + col0 + col0 FROM tab0 AS cor0
----
-27
-38
87

query I rowsort
SELECT col1 + col2 * col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL + col1 * col0 - col1 AS col2 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT ( - col0 + col0 * col0 ) FROM tab2
----
42
6006
6162

query I rowsort
SELECT DISTINCT col0 * + col0 + + col1 * - tab0.col0 FROM tab0
----
-1488
-178
-2170

query I rowsort
SELECT col0 * - col1 * + col1 AS col0 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT ALL - 5 FROM tab0
----
-5
-5
-5

query I rowsort
SELECT + col0 * tab2.col0 - + col1 FROM tab2
----
18
6025
6224

query I rowsort
SELECT ALL - col2 + tab0.col1 FROM tab0
----
53
9
96

query I rowsort
SELECT + col2 * + col1 + cor0.col0 * col0 * cor0.col0 FROM tab1 AS cor0
----
1431
262714
513248

onlyif mysql # use DIV operator for integer division
query I rowsort label-5086
SELECT + - col0 DIV cor0.col1 + - col1 * + cor0.col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-5086
SELECT + - col0 / cor0.col1 + - col1 * + cor0.col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-5087
SELECT col2 DIV + 5 AS col0 FROM tab1
----
10
11
19

skipif mysql # not compatible
query I rowsort label-5087
SELECT col2 / + 5 AS col0 FROM tab1
----
10
11
19

onlyif mysql # use DIV operator for integer division
query I rowsort label-5088
SELECT - ( - 74 ) DIV + tab1.col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-5088
SELECT - ( - 74 ) / + tab1.col1 FROM tab1
----
2
5
7

query I rowsort
SELECT ALL + cor0.col1 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT 4 + 8 - - col2 * - col1 FROM tab1 cor0
----
-1236
-1392
-558

query I rowsort
SELECT - - 9 * + col1 AS col1 FROM tab1 cor0
----
117
234
90

query I rowsort
SELECT DISTINCT col2 * + col1 * - col2 + - tab0.col0 - tab0.col2 AS col0 FROM tab0
----
-133
-612055
-93711

query I rowsort
SELECT ALL - col2 * - tab2.col2 AS col0 FROM tab2
----
1444
676
729

query I rowsort
SELECT DISTINCT - col0 - + 79 FROM tab1
----
-143
-159
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5095
SELECT + + col0 * col0 DIV + col1 FROM tab2 AS cor0
----
1
103
367

skipif mysql # not compatible
query I rowsort label-5095
SELECT + + col0 * col0 / + col1 FROM tab2 AS cor0
----
1
103
367

query I rowsort
SELECT - + col1 - col1 AS col0 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT - col1 + col2 * cor0.col0 FROM tab1 AS cor0
----
136
3638
7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-5098
SELECT col1 * + col2 + col0 + + col2 DIV col0 AS col1 FROM tab0 AS cor0
----
132
2863
7551

skipif mysql # not compatible
query I rowsort label-5098
SELECT col1 * + col2 + col0 + + col2 / col0 AS col1 FROM tab0 AS cor0
----
132
2863
7551

query I rowsort
SELECT + - ( + col0 ) * col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - 50 * col0 FROM tab2
----
-350
-3900
-3950

query I rowsort
SELECT ALL + 98 * col1 FROM tab1
----
1274
2548
980

query I rowsort
SELECT 28 * - col0 AS col0 FROM tab2 cor0
----
-196
-2184
-2212

query I rowsort
SELECT - 28 * col0 FROM tab1 AS cor0
----
-1792
-2240
-84

query I rowsort
SELECT - cor0.col0 * - col1 * + col0 + col2 AS col0 FROM tab2 AS cor0
----
106135
1546
358982

query I rowsort
SELECT DISTINCT - col2 + + 58 FROM tab1 AS cor0
----
-38
1
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-5106
SELECT DISTINCT + cor0.col1 * 70 - + col2 DIV 16 AS col2 FROM tab1 AS cor0
----
1817
697
904

skipif mysql # not compatible
query I rowsort label-5106
SELECT DISTINCT + cor0.col1 * 70 - + col2 / 16 AS col2 FROM tab1 AS cor0
----
1817
697
904

query I rowsort
SELECT - col1 + - col0 * col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT - col2 * - col1 + - col1 * ( + cor0.col0 + + col0 ) FROM tab1 AS cor0
----
-710
-832
1248

query I rowsort
SELECT DISTINCT - - col1 + - col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT - + ( col0 ) * - col0 * + ( - cor0.col2 ) + col1 AS col0 FROM tab1 AS cor0
----
-233462
-460
-614387

query I rowsort
SELECT DISTINCT 67 AS col2 FROM tab2, tab1 cor0
----
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5112
SELECT + + CAST( col2 AS SIGNED ) * col0 + - 5 * 3 AS col0 FROM tab0 AS cor0
----
20
7283
777

skipif mysql # not compatible
query I rowsort label-5112
SELECT + + CAST ( col2 AS INTEGER ) * col0 + - 5 * 3 AS col0 FROM tab0 AS cor0
----
20
7283
777

query I rowsort
SELECT ALL - 92 AS col1 FROM tab1 AS cor0
----
-92
-92
-92

query I rowsort
SELECT ( - ( col1 ) ) * cor0.col0 + + 32 AS col0 FROM tab1 AS cor0
----
-1008
-46
-608

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col1 + col2 col0 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - + 55 - - cor0.col0 AS col1 FROM tab0 AS cor0
----
-20
-31
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5117
SELECT ALL + ( cor0.col0 ) + + col0 DIV col0 AS col0 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-5117
SELECT ALL + ( cor0.col0 ) + + col0 / col0 AS col0 FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT ALL col0 - + ( - col0 ) FROM tab0
----
178
48
70

query I rowsort
SELECT DISTINCT - + col0 * col2 + + col1 + + cor0.col1 * cor0.col1 AS col1 FROM tab0 cor0
----
1074
6690
9471

query I rowsort
SELECT col0 * + ( col2 ) + + 33 AS col2 FROM tab0 AS cor0
----
68
7331
825

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 DISTINCT + col0 + col1 AS col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ( + col1 ) + cor0.col1 FROM tab1 cor0
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-5124
SELECT - col0 + col2 DIV col1 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-5124
SELECT - col0 + col2 / col1 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT ( col2 ) * col1 + + 54 FROM tab2
----
1588
700
891

query I rowsort
SELECT ALL - ( col2 ) + + col2 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col1 + col0 * col0 * + col1 FROM tab1 AS cor0
----
260
40970
83213

query I rowsort
SELECT + 47 + col1 AS col1 FROM tab1 AS cor0
----
57
60
73

query I rowsort
SELECT ALL - 51 + cor0.col2 FROM tab2 AS cor0
----
-13
-24
-25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5130
SELECT ALL + col2 * col1 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5130
SELECT ALL + col2 * col1 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 75 * col0 + - col2 FROM tab1 AS cor0
----
-279
-4857
-6096

query I rowsort
SELECT ALL 37 + - tab2.col0 FROM tab2
----
-41
-42
30

query I rowsort
SELECT DISTINCT - col2 * + 61 + col1 FROM tab2
----
-1527
-1616
-2301

query I rowsort
SELECT col2 + + col2 * + col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT cor0.col2 - - 34 AS col0 FROM tab0 AS cor0
----
116
35
67

query I rowsort
SELECT DISTINCT + col0 * - ( - col2 + col1 ) AS col1 FROM tab0 AS cor0
----
-1272
-3360
-801

query I rowsort
SELECT DISTINCT col1 * - ( - 84 ) FROM tab0 AS cor0
----
7224
7644
8148

query I rowsort
SELECT - col2 + 91 AS col2 FROM tab2 cor0
----
53
64
65

query I rowsort
SELECT col1 + + col1 - - 0 FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT ALL col1 + + col1 * col1 FROM tab2 AS cor0
----
306
3540
992

onlyif mysql # use DIV operator for integer division
query I rowsort label-5141
SELECT DISTINCT - - col0 DIV - ( ( col2 ) ) AS col2 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-5141
SELECT DISTINCT - - col0 / - ( ( col2 ) ) AS col2 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT tab1.col0 * cor0.col1 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to e6d1e51162f22414194f33e791083a39

query I rowsort
SELECT DISTINCT + col2 + 46 FROM tab1
----
100
103
142

query I rowsort
SELECT + col2 * col1 * cor0.col0 + + col0 AS col2 FROM tab1 AS cor0
----
36544
4215
99920

query I rowsort
SELECT ALL - col1 * 5 AS col1 FROM tab1 AS cor0
----
-130
-50
-65

query I rowsort
SELECT ALL - col0 + col0 - 89 AS col2 FROM tab2 AS cor0
----
-89
-89
-89

query I rowsort
SELECT ALL - col0 * + cor0.col1 + cor0.col2 * col0 + 84 AS col0 FROM tab0 AS cor0
----
-1188
-3276
-717

query I rowsort
SELECT ALL col0 - - 70 FROM tab0 cor0
----
105
159
94

query I rowsort
SELECT DISTINCT - col2 + 53 AS col1 FROM tab1
----
-1
-4
-43

query I rowsort
SELECT + - col1 + 32 * - col1 AS col0 FROM tab2 cor0
----
-1023
-1947
-561

query I rowsort
SELECT DISTINCT - col1 + - col2 + + col1 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT - tab1.col2 + + ( + col0 ) AS col0 FROM tab1
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-5153
SELECT - 41 DIV 55 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5153
SELECT - 41 / 55 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - cor0.col0 AS col2 FROM tab2, tab0, tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT 88 FROM tab2, tab2 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5156
SELECT DISTINCT col0 * CAST( NULL AS DECIMAL ) * col1 AS col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-5156
SELECT DISTINCT col0 * CAST ( NULL AS REAL ) * col1 AS col2 FROM tab1
----
NULL

query I rowsort
SELECT 14 + + 50 FROM tab0, tab1 AS cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5158
SELECT ALL - col1 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5158
SELECT ALL - col1 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 17 * + 53 AS col2 FROM tab1 AS cor0
----
-901

query I rowsort
SELECT 69 + col2 - col1 FROM tab0 cor0
----
-27
16
60

query I rowsort
SELECT DISTINCT 59 * col0 FROM tab1 AS cor0
----
177
3776
4720

query I rowsort
SELECT col0 * col2 + col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT - col0 + - ( col2 ) FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT ( col2 * col1 ) AS col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL 52 FROM tab1, tab1 cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT - col1 + - col1 * col0 AS col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT + ( + 43 ) + cor0.col0 FROM tab1 AS cor0
----
107
123
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-5168
SELECT DISTINCT + cor0.col1 DIV - col1 FROM tab2 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5168
SELECT DISTINCT + cor0.col1 / - col1 FROM tab2 AS cor0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5169
SELECT ALL ( ( - col1 ) ) DIV + 76 + col2 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-5169
SELECT ALL ( ( - col1 ) ) / + 76 + col2 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT 49 * col0 FROM tab2 AS cor0
----
343
3822
3871

query I rowsort
SELECT DISTINCT + + col2 * ( + col0 ) - + col1 FROM tab0 cor0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-5172
SELECT + + 80 DIV 6 - - col0 * cor0.col0 AS col2 FROM tab0 AS cor0
----
1238
589
7934

skipif mysql # not compatible
query I rowsort label-5172
SELECT + + 80 / 6 - - col0 * cor0.col0 AS col2 FROM tab0 AS cor0
----
1238
589
7934

query I rowsort
SELECT ALL 6 * cor0.col1 + col1 * col0 FROM tab2 AS cor0
----
1445
403
4956

query I rowsort
SELECT ALL + 55 AS col2 FROM tab2 AS cor0
----
55
55
55

query I rowsort
SELECT - cor0.col1 * col2 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT + col0 * - col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-5177
SELECT + - col0 + - col0 DIV + col1 FROM tab2 AS cor0
----
-7
-79
-83

skipif mysql # not compatible
query I rowsort label-5177
SELECT + - col0 + - col0 / + col1 FROM tab2 AS cor0
----
-7
-79
-83

query I rowsort
SELECT ALL - + col1 * - col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5179
SELECT ALL + col0 * col0 + - 29 DIV - col0 FROM tab2 cor0
----
53
6084
6241

skipif mysql # not compatible
query I rowsort label-5179
SELECT ALL + col0 * col0 + - 29 / - col0 FROM tab2 cor0
----
53
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5180
SELECT ALL + - 25 * + col1 + + CAST( NULL AS SIGNED ) col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5180
SELECT ALL + - 25 * + col1 + + CAST ( NULL AS INTEGER ) col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5181
SELECT ALL - - col1 DIV col2 AS col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-5181
SELECT ALL - - col1 / col2 AS col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT DISTINCT + col0 * + col0 + + col2 AS col1 FROM tab1 cor0
----
4153
63
6496

query I rowsort
SELECT DISTINCT - 16 AS col2 FROM tab2 AS cor0
----
-16

query I rowsort
SELECT - col2 * ( cor0.col2 ) FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT - cor0.col0 + ( + 82 ) FROM tab2 cor0
----
3
4
75

query I rowsort
SELECT + 8 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 33069adc3c1142d31511ec88fcfa40af

query I rowsort
SELECT DISTINCT - col0 * col2 + + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT ALL - col1 * - 12 FROM tab0 AS cor0
----
1032
1092
1164

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 89 col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT ALL 97 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

query I rowsort
SELECT ALL + col2 + - col2 * col1 + col1 * + cor0.col2 * + col1 AS col0 FROM tab1 AS cor0
----
15072
35154
5187

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 4 + col1 * + col2 col0 FROM tab0 AS cor0
----
101
2842
7466

query I rowsort
SELECT DISTINCT - - col2 * col1 AS col0 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5194
SELECT ALL + 46 DIV - col2 AS col1 FROM tab0 AS cor0
----
-1
-46
0

skipif mysql # not compatible
query I rowsort label-5194
SELECT ALL + 46 / - col2 AS col1 FROM tab0 AS cor0
----
-1
-46
0

query I rowsort
SELECT + col2 * ( cor0.col1 + + col1 ) FROM tab1 AS cor0
----
1140
2496
2808

query I rowsort
SELECT col1 * - 59 AS col2 FROM tab1 AS cor0
----
-1534
-590
-767

query I rowsort
SELECT + col1 * col1 * + 91 AS col1 FROM tab0 AS cor0
----
673036
753571
856219

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5198
SELECT + col2 * + CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5198
SELECT + col2 * + CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 25 * tab0.col0 col0 FROM tab0
----
-2225
-600
-875

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col2 ) col1 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ( col1 + col2 ) AS col1 FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT + + col1 + + cor0.col1 * col2 + - cor0.col2 * + 52 AS col2 FROM tab0 AS cor0
----
1208
142
3289

query I rowsort
SELECT 29 AS col2 FROM tab2, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 40739d223aa019bd2dfe2db99d596302

query I rowsort
SELECT ALL 4 FROM tab2, tab1 cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT col0 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-5206
SELECT + + col2 * + col1 + - col2 DIV - 94 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-5206
SELECT + + col2 * + col1 + - col2 / - 94 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5207
SELECT ALL tab2.col0 DIV + ( col0 ) - - col1 DIV col1 FROM tab2
----
2
2
2

skipif mysql # not compatible
query I rowsort label-5207
SELECT ALL tab2.col0 / + ( col0 ) - - col1 / col1 FROM tab2
----
2
2
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5208
SELECT + CAST( col1 AS SIGNED ) * col1 + ( 77 ) AS col0 FROM tab2 AS cor0
----
1038
3558
366

skipif mysql # not compatible
query I rowsort label-5208
SELECT + CAST ( col1 AS INTEGER ) * col1 + ( 77 ) AS col0 FROM tab2 AS cor0
----
1038
3558
366

query I rowsort
SELECT - ( + 74 ) * col1 + cor0.col0 AS col0 FROM tab0 AS cor0
----
-6340
-6645
-7143

query I rowsort
SELECT - 23 + 40 AS col0 FROM tab2 cor0
----
17
17
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-5211
SELECT + col2 DIV col2 + ( + col1 ) FROM tab1 cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-5211
SELECT + col2 / col2 + ( + col1 ) FROM tab1 cor0
----
11
14
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-5212
SELECT ALL + col0 + - col1 + col2 DIV - 4 AS col1 FROM tab1
----
-36
40
43

skipif mysql # not compatible
query I rowsort label-5212
SELECT ALL + col0 + - col1 + col2 / - 4 AS col1 FROM tab1
----
-36
40
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col1 ) * - col0 col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT - + col1 + + col0 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT - col0 * + col2 + col2 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-34
-574
297

query I rowsort
SELECT ALL + 12 AS col1 FROM tab1
----
12
12
12

query I rowsort
SELECT - - cor0.col2 * + col2 + col0 AS col0 FROM tab2 AS cor0
----
1523
736
754

onlyif mysql # use DIV operator for integer division
query I rowsort label-5218
SELECT cor0.col2 + col2 DIV col0 - col1 AS col1 FROM tab1 AS cor0
----
46
47
84

skipif mysql # not compatible
query I rowsort label-5218
SELECT cor0.col2 + col2 / col0 - col1 AS col1 FROM tab1 AS cor0
----
46
47
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5219
SELECT DISTINCT + col2 * col2 * + CAST( col2 AS SIGNED ) + cor0.col1 FROM tab1 AS cor0
----
157490
185203
884749

skipif mysql # not compatible
query I rowsort label-5219
SELECT DISTINCT + col2 * col2 * + CAST ( col2 AS INTEGER ) + cor0.col1 FROM tab1 AS cor0
----
157490
185203
884749

query I rowsort
SELECT DISTINCT 46 * col0 + + col0 AS col2 FROM tab1 AS cor0
----
141
3008
3760

onlyif mysql # use DIV operator for integer division
query I rowsort label-5221
SELECT - - col2 - col1 DIV col2 FROM tab0 AS cor0
----
-96
31
81

skipif mysql # not compatible
query I rowsort label-5221
SELECT - - col2 - col1 / col2 FROM tab0 AS cor0
----
-96
31
81

query I rowsort
SELECT DISTINCT + 64 FROM tab2
----
64

query I rowsort
SELECT DISTINCT col1 + 63 * col0 AS col0 FROM tab2 AS cor0
----
472
4973
4994

query I rowsort
SELECT ALL - + col0 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT + col0 * - ( cor0.col0 ) + col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT cor0.col0 * + 50 - col0 FROM tab2 AS cor0
----
343
3822
3871

query I rowsort
SELECT - col0 * col1 * ( + tab2.col1 * - col0 ) FROM tab2
----
1803649
21178404
47089

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - - col0 col2 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 * col2 * col0 FROM tab0
----
-1225
-19008
-649522

query I rowsort
SELECT DISTINCT - 66 FROM tab2, tab2 cor0
----
-66

query I rowsort
SELECT - cor0.col1 + - 90 FROM tab1, tab2 AS cor0
----
9 values hashing to 8460464eaf730a0c496582c508a09693

query I rowsort
SELECT ALL 0 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL + 99 - col2 AS col1 FROM tab2
----
61
72
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-5234
SELECT - col0 DIV - 17 FROM tab0
----
1
2
5

skipif mysql # not compatible
query I rowsort label-5234
SELECT - col0 / - 17 FROM tab0
----
1
2
5

query I rowsort
SELECT DISTINCT 67 AS col2 FROM tab2
----
67

query I rowsort
SELECT + - col0 * + ( col0 ) FROM tab2 cor0
----
-49
-6084
-6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5237
SELECT - + CAST( NULL AS SIGNED ) + - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5237
SELECT - + CAST ( NULL AS INTEGER ) + - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 36 + col2 AS col1 FROM tab1 AS cor0
----
132
90
93

query I rowsort
SELECT col1 * - ( cor0.col0 + 97 * + col2 ) AS col2 FROM tab2 cor0
----
-153400
-64005
-81406

query I rowsort
SELECT - ( 39 ) * col1 FROM tab0 AS cor0
----
-3354
-3549
-3783

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col2 col0 FROM tab0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 + + col1 col2 FROM tab0
----
1322
662
8012

query I rowsort
SELECT DISTINCT + col0 + col2 * - col0 + col2 FROM tab2
----
-155
-1924
-2885

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col2 * col0 * col0 + - col0 col1 FROM tab0 AS cor0
----
1093
18898
649342

query I rowsort
SELECT - col2 / cor0.col2 AS col1 FROM tab2 cor0 WHERE NOT ( NULL ) NOT IN ( col2 * col2 )
----

query I rowsort
SELECT + col1 * col1 + col2 / - tab2.col0 FROM tab2 WHERE NOT - col2 * - col2 + + col0 < ( NULL )
----

query I rowsort
SELECT col1 * tab2.col1 + - col2 * col2 * + col2 AS col0 FROM tab2
----
-14095
-18722
-54583

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 col1 FROM tab1 WHERE NOT NULL IN ( - tab1.col2 )
----

query I rowsort
SELECT DISTINCT col0 + col0 + tab1.col1 * - col0 * col1 AS col0 FROM tab1
----
-13360
-2022
-6272

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NULL NOT IN ( + col1 )
----

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query IIIIII rowsort
SELECT ALL * FROM tab1, tab1 cor0 WHERE ( NULL ) NOT BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5253
SELECT DISTINCT col2 DIV - col0 FROM tab1 cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-5253
SELECT DISTINCT col2 / - col0 FROM tab1 cor0
----
-1
-18
0

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE NOT ( NULL ) = ( NULL )
----

query I rowsort
SELECT DISTINCT + col1 * tab2.col1 FROM tab2 WHERE NOT NULL >= NULL
----

query I rowsort
SELECT - col1 - tab0.col1 * col2 FROM tab0
----
-194
-2924
-7553

query I rowsort
SELECT DISTINCT col1 AS col2 FROM tab2 WHERE col2 >= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col2 - col2 col1 FROM tab0
----
0
1056
6642

query I rowsort
SELECT DISTINCT - col0 / col2 FROM tab0 WHERE NOT NULL <> NULL
----

query I rowsort
SELECT ALL col1 + col1 + + col2 * col0 AS col2 FROM tab2
----
2146
251
3036

onlyif mysql # use DIV operator for integer division
query I rowsort label-5261
SELECT DISTINCT - col0 DIV col1 AS col0 FROM tab1
----
-6
0

skipif mysql # not compatible
query I rowsort label-5261
SELECT DISTINCT - col0 / col1 AS col0 FROM tab1
----
-6
0

query I rowsort
SELECT - col0 + + col1 * + col1 + - tab2.col2 * + col2 FROM tab2
----
-1234
225
2727

query I rowsort
SELECT ALL + col1 + col0 AS col1 FROM tab2
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col1 + - col0 * col1 col1 FROM tab1
----
-70
1326
208

onlyif mysql # use DIV operator for integer division
query I rowsort label-5265
SELECT ALL - tab0.col0 DIV + col2 FROM tab0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-5265
SELECT ALL - tab0.col0 / + col2 FROM tab0
----
-1
-35
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5266
SELECT DISTINCT + col1 DIV - col1 AS col0 FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-5266
SELECT DISTINCT + col1 / - col1 AS col0 FROM tab1
----
-1

query III rowsort
SELECT * FROM tab0 WHERE NOT + col1 - + col2 = col2 * col2 - - col2
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT cor0.col2 + - col2 * col0 FROM tab2 cor0
----
-162
-2002
-2964

query I rowsort
SELECT + + col2 + - col1 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-7363
-8199
-9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-5270
SELECT DISTINCT + col1 DIV - col2 AS col1 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-5270
SELECT DISTINCT + col1 / - col2 AS col1 FROM tab0 AS cor0
----
-1
-2
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * - cor0.col2 * - col0 col0 FROM tab2 AS cor0
----
-114076
-5103
-52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-5272
SELECT ALL - - col2 DIV - cor0.col0 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5272
SELECT ALL - - col2 / - cor0.col0 FROM tab0 cor0
----
-1
0
0

query I rowsort
SELECT - + col0 * + col1 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - cor0.col1 * col1 + + col1 AS col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT ALL + - col2 + cor0.col0 * col1 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT + col2 + - cor0.col1 * + col2 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT - + col2 - - col0 * - col0 FROM tab0 cor0
----
-1226
-609
-8003

query I rowsort
SELECT - col1 / tab1.col1 + + tab1.col2 + + col0 FROM tab1 WHERE NOT ( + col2 ) NOT IN ( - tab1.col1 / col2 )
----

query I rowsort
SELECT col0 * + col2 * + col2 - col2 FROM tab0
----
26103
34
598354

query I rowsort
SELECT DISTINCT - col1 * - cor0.col0 + cor0.col1 AS col0 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL + col1 + - cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 + + col0 * - col1 AS col1 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT - cor0.col1 * 41 AS col2 FROM tab0 AS cor0
----
-3526
-3731
-3977

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + + ( - col0 ) col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL + - cor0.col0 * 4 FROM tab1 AS cor0
----
-12
-256
-320

query I rowsort
SELECT DISTINCT - tab1.col2 * - tab1.col2 * ( col0 ) AS col1 FROM tab1
----
207936
737280
8748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col1 col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT + 11 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 69116737f3f57e2e3273f6dbb04d036c

query I rowsort
SELECT 73 + + col2 * ( tab2.col1 ) FROM tab2
----
1607
719
910

query I rowsort
SELECT col1 + - col2 * 5 * + 74 AS col1 FROM tab2
----
-14043
-9561
-9959

query I rowsort
SELECT + 52 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT ALL col0 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + col2 + - ( - 0 ) FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT ALL + - col2 - col2 * + 91 FROM tab0 AS cor0
----
-3036
-7544
-92

onlyif mysql # use DIV operator for integer division
query I rowsort label-5295
SELECT ALL - col0 DIV + ( 33 ) + + col2 AS col1 FROM tab1 AS cor0
----
54
56
94

skipif mysql # not compatible
query I rowsort label-5295
SELECT ALL - col0 / + ( 33 ) + + col2 AS col1 FROM tab1 AS cor0
----
54
56
94

query I rowsort
SELECT DISTINCT - - col0 * + ( col0 ) FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT 28 - cor1.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
15
18
2

query I rowsort
SELECT ALL - - col2 - cor0.col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + + col2 * - 14 FROM tab0 cor0
----
-1148
-14
-462

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + col0 + 37 col1 FROM tab1 AS cor0
----
199
3685
7717

query I rowsort
SELECT DISTINCT col2 - col1 * + col2 * tab1.col1 FROM tab1
----
-16128
-36450
-5643

query III rowsort
SELECT ALL * FROM tab0 WHERE ( NULL ) NOT IN ( + col2 )
----

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) < ( col2 )
----

query I rowsort
SELECT col1 + col0 * - col2 FROM tab1
----
-136
-3638
-7667

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL >= ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col1 col0 FROM tab0
----
-7396
-8281
-9409

query III rowsort
SELECT * FROM tab1 WHERE + col2 + col0 + + col0 IN ( col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5308
SELECT - col0 DIV - tab0.col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5308
SELECT - col0 / - tab0.col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + tab0.col1 col0 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-5310
SELECT + tab1.col2 DIV + col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-5310
SELECT + tab1.col2 / + col1 FROM tab1
----
2
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + tab0.col1 col2 FROM tab0
----
172
182
194

query I rowsort
SELECT DISTINCT tab1.col1 * + tab1.col0 * + col2 FROM tab1 WHERE NOT NULL > NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * + col2 col2 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5314
SELECT - + col1 DIV - col0 + - col2 FROM tab2 AS cor0
----
-23
-26
-38

skipif mysql # not compatible
query I rowsort label-5314
SELECT - + col1 / - col0 + - col2 FROM tab2 AS cor0
----
-23
-26
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5315
SELECT DISTINCT ( + col1 ) - - CAST( - col0 AS SIGNED ) FROM tab0 AS cor0
----
2
62

skipif mysql # not compatible
query I rowsort label-5315
SELECT DISTINCT ( + col1 ) - - CAST ( - col0 AS INTEGER ) FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT ALL 86 + cor0.col1 - ( col1 ) FROM tab2 AS cor0
----
86
86
86

query I rowsort
SELECT 46 AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 2f97924b57b73102233df7c9ce8ad602

query I rowsort
SELECT DISTINCT + tab1.col1 * + col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT - col1 + col1 + + 3 * col0 FROM tab2 AS cor0
----
21
234
237

query I rowsort
SELECT DISTINCT ( - col0 ) * col1 * col2 AS col0 FROM tab0 cor0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-5321
SELECT - cor0.col1 DIV cor0.col1 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

skipif mysql # not compatible
query I rowsort label-5321
SELECT - cor0.col1 / cor0.col1 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

query I rowsort
SELECT + - col1 + - cor0.col0 + col0 * - col0 FROM tab2 AS cor0
----
-6221
-6337
-87

query I rowsort
SELECT 34 * col2 FROM tab0 AS cor0
----
1122
2788
34

query I rowsort
SELECT DISTINCT - - col1 * - cor0.col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5325
SELECT ALL col1 DIV col1 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5325
SELECT ALL col1 / col1 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT + col1 * + 31 FROM tab1 AS cor0
----
310
403
806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 27 * - col2 col2 FROM tab0 AS cor0
----
-2214
-27
-891

query I rowsort
SELECT + 82 * 5 * col1 AS col2 FROM tab1 AS cor0
----
10660
4100
5330

query I rowsort
SELECT col1 - ( col2 ) * 62 FROM tab0 AS cor0
----
-1960
-4993
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-5330
SELECT 61 DIV 75 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-5330
SELECT 61 / 75 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

onlyif mysql # use DIV operator for integer division
query I rowsort label-5331
SELECT - col0 DIV - col1 AS col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-5331
SELECT - col0 / - col1 AS col1 FROM tab2
----
0
1
4

query I rowsort
SELECT ALL 84 AS col0 FROM tab1
----
84
84
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5333
SELECT ALL + cor1.col1 + - CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5333
SELECT ALL + cor1.col1 + - CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - col2 * - col2 + col0 AS col2 FROM tab2 AS cor0
----
1523
736
754

onlyif mysql # use DIV operator for integer division
query I rowsort label-5335
SELECT + + col0 DIV col2 + col0 AS col2 FROM tab0 AS cor0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-5335
SELECT + + col0 / col2 + col0 AS col2 FROM tab0 AS cor0
----
24
70
90

query I rowsort
SELECT col1 * 53 AS col0 FROM tab1 AS cor0
----
1378
530
689

query I rowsort
SELECT - col1 + - cor0.col2 * col2 AS col1 FROM tab0 AS cor0
----
-1175
-6815
-98

query I rowsort
SELECT + 2 + col2 AS col1 FROM tab2 AS cor0
----
28
29
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 12 + - col2 * 59 * + col2 col0 FROM tab2 AS cor0
----
-39872
-42999
-85184

query I rowsort
SELECT + 69 * col2 AS col2 FROM tab2 AS cor0
----
1794
1863
2622

query I rowsort
SELECT + col2 * - col1 AS col2 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT + - 55 * + cor0.col2 * + col1 AS col1 FROM tab2 cor0
----
-35530
-46035
-84370

onlyif mysql # use DIV operator for integer division
query I rowsort label-5343
SELECT - col1 DIV 17 FROM tab0
----
-5
-5
-5

skipif mysql # not compatible
query I rowsort label-5343
SELECT - col1 / 17 FROM tab0
----
-5
-5
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-5344
SELECT DISTINCT col0 DIV - 79 AS col0 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-5344
SELECT DISTINCT col0 / - 79 AS col0 FROM tab2 AS cor0
----
-1
0

query I rowsort
SELECT + col1 * + 43 FROM tab0 AS cor0
----
3698
3913
4171

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * col0 col1 FROM tab2 cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + col2 col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT col0 + + col2 * - 51 AS col0 FROM tab2 AS cor0
----
-1248
-1370
-1859

query I rowsort
SELECT - col2 * - col2 + col2 AS col1 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT - col1 * ( - 6 + col1 ) * - ( cor0.col1 + - cor0.col0 ) AS col2 FROM tab2 AS cor0
----
-11594
-59413
18600

query I rowsort
SELECT DISTINCT + col2 + col2 * - col1 FROM tab2 AS cor0
----
-1508
-608
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-5352
SELECT DISTINCT col2 + 87 DIV 79 + + cor0.col1 FROM tab2 cor0
----
56
59
86

skipif mysql # not compatible
query I rowsort label-5352
SELECT DISTINCT col2 + 87 / 79 + + cor0.col1 FROM tab2 cor0
----
56
59
86

query I rowsort
SELECT ALL + - cor0.col0 * + col1 + + col0 * col2 AS col2 FROM tab1 AS cor0
----
3008
6640
84

query I rowsort
SELECT ALL col1 + + 59 * + col0 AS col1 FROM tab1 AS cor0
----
203
3786
4733

query I rowsort
SELECT DISTINCT + col0 * - cor0.col1 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5356
SELECT col2 DIV - ( - col2 ) FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5356
SELECT col2 / - ( - col2 ) FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT - col2 * - ( + col0 ) * col0 - - cor0.col0 FROM tab2 AS cor0
----
1330
158262
237237

onlyif mysql # use DIV operator for integer division
query I rowsort label-5358
SELECT - - 14 DIV col0 FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-5358
SELECT - - 14 / col0 FROM tab2 AS cor0
----
0
0
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-5359
SELECT 4 DIV - cor0.col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5359
SELECT 4 / - cor0.col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL cor0.col0 + - 59 AS col0 FROM tab1 AS cor0
----
-56
21
5

query I rowsort
SELECT DISTINCT - + 91 + - ( col1 ) * - 10 * col0 FROM tab0 AS cor0
----
20549
33859
80899

onlyif mysql # use DIV operator for integer division
query I rowsort label-5362
SELECT - col0 DIV - col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5362
SELECT - col0 / - col0 FROM tab1
----
1
1
1

query I rowsort
SELECT + col1 + col2 AS col0 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT - + col2 * + col2 + + ( col1 ) * col1 * + ( - col0 + + col0 * + col1 ) AS col1 FROM tab0 cor0
----
15086751
31614239
66324086

query I rowsort
SELECT - 80 * col0 + - col1 AS col0 FROM tab1 AS cor0
----
-266
-5130
-6413

query I rowsort
SELECT + 43 * + cor1.col1 AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 2f7ebab4cffbbd6a65cee7cc4ff288a5

onlyif mysql # use DIV operator for integer division
query I rowsort label-5367
SELECT ALL + cor0.col0 DIV col0 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5367
SELECT ALL + cor0.col0 / col0 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - ( - col0 ) * ( - 66 ) + - cor0.col2 AS col2 FROM tab0 cor0
----
-1617
-2311
-5956

query I rowsort
SELECT DISTINCT + cor0.col0 + + cor0.col2 * col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL 39 AS col1 FROM tab2
----
39
39
39

query I rowsort
SELECT ALL - + col0 * col0 * + col2 + + cor0.col1 FROM tab2 AS cor0
----
-1292
-158125
-237141

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + 22 col2 FROM tab1 AS cor0
----
1408
1760
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + 74 col1 FROM tab1 AS cor0
----
3996
4218
7104

query I rowsort
SELECT col1 * - ( 91 ) + + col2 FROM tab2 AS cor0
----
-1509
-2794
-5343

query I rowsort
SELECT ALL + col2 + + col2 + col2 FROM tab1 AS cor0
----
162
171
288

query I rowsort
SELECT DISTINCT - col0 + + col2 AS col2 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT ALL 32 AS col1 FROM tab2
----
32
32
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-5378
SELECT DISTINCT 23 DIV + col1 AS col0 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-5378
SELECT DISTINCT 23 / + col1 AS col0 FROM tab0
----
0

query I rowsort
SELECT ALL - ( col0 ) * tab1.col0 AS col0 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT 8 * + tab0.col1 AS col2 FROM tab0
----
688
728
776

onlyif mysql # use DIV operator for integer division
query I rowsort label-5381
SELECT + cor0.col0 DIV 61 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 43a387ef4ba85927dc3d9d573afc12c9

skipif mysql # not compatible
query I rowsort label-5381
SELECT + cor0.col0 / 61 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 43a387ef4ba85927dc3d9d573afc12c9

query I rowsort
SELECT ALL - 9 * + col2 FROM tab2 AS cor0
----
-234
-243
-342

query I rowsort
SELECT + 67 * col2 FROM tab2
----
1742
1809
2546

query I rowsort
SELECT ALL - col2 * - col1 * ( - col0 ) + - tab0.col0 FROM tab0
----
-3430
-664207
-68136

query I rowsort
SELECT ALL + + col0 * + col2 + - col1 + - col2 AS col2 FROM tab1 AS cor0
----
3581
7571
82

query I rowsort
SELECT DISTINCT - 13 * cor0.col1 AS col1 FROM tab1 AS cor0
----
-130
-169
-338

query I rowsort
SELECT DISTINCT 50 * col2 AS col1 FROM tab1 AS cor0
----
2700
2850
4800

query I rowsort
SELECT DISTINCT + 10 * + col0 + + col0 * + cor0.col1 FROM tab1 AS cor0
----
108
1280
1840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col1 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5390
SELECT + CAST( NULL AS SIGNED ) + - 79 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5390
SELECT + CAST ( NULL AS INTEGER ) + - 79 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT tab0.col2 * - col0 * + ( col1 ) FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL col0 + - tab2.col1 + + tab2.col2 FROM tab2
----
100
3
45

query I rowsort
SELECT DISTINCT 54 FROM tab1, tab0 AS cor0, tab2 cor1
----
54

query I rowsort
SELECT ALL - col2 * + ( + cor0.col1 ) FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT cor1.col2 FROM tab0, tab2 AS cor0, tab2 cor1, tab0 AS cor2
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5396
SELECT + - cor0.col1 + col1 DIV col0 + - col0 * col0 AS col2 FROM tab2 AS cor0
----
-6143
-6258
-76

skipif mysql # not compatible
query I rowsort label-5396
SELECT + - cor0.col1 + col1 / col0 + - col0 * col0 AS col2 FROM tab2 AS cor0
----
-6143
-6258
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-5397
SELECT - + col2 DIV 60 + - col2 FROM tab0 AS cor0
----
-1
-33
-83

skipif mysql # not compatible
query I rowsort label-5397
SELECT - + col2 / 60 + - col2 FROM tab0 AS cor0
----
-1
-33
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5398
SELECT - + CAST( - col2 AS SIGNED ) AS col2 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-5398
SELECT - + CAST ( - col2 AS INTEGER ) AS col2 FROM tab0 cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 17 col0 FROM tab1 cor0
----
-17

query I rowsort
SELECT ALL + 77 * 86 + col1 + - col0 FROM tab2 AS cor0
----
6560
6603
6646

onlyif mysql # use DIV operator for integer division
query I rowsort label-5401
SELECT - - col0 + ( col0 ) DIV + cor0.col1 AS col1 FROM tab0 cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-5401
SELECT - - col0 + ( col0 ) / + cor0.col1 AS col1 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT - col0 * - 25 * col2 AS col0 FROM tab1 AS cor0
----
192000
4050
91200

query I rowsort
SELECT + - col0 * cor0.col0 + col1 FROM tab0 cor0
----
-1128
-490
-7830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 35 + cor0.col2 * - col0 col2 FROM tab2 AS cor0
----
-154
-1993
-2967

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5405
SELECT ALL - + CAST( NULL AS SIGNED ) * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5405
SELECT ALL - + CAST ( NULL AS INTEGER ) * + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 + col1 * col2 FROM tab2
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-5407
SELECT + + 35 DIV - col1 AS col1 FROM tab2 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-5407
SELECT + + 35 / - col1 AS col1 FROM tab2 AS cor0
----
-1
-2
0

query I rowsort
SELECT ALL - ( col1 ) + + col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - 38 * + col2 FROM tab0 AS cor0
----
-1254
-3116
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5410
SELECT ALL + 38 DIV 32 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5410
SELECT ALL + 38 / 32 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - 9 * + col1 + - col1 AS col0 FROM tab1 AS cor0
----
-100
-130
-260

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col2 col0 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5413
SELECT ALL CAST( NULL AS SIGNED ) * col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5413
SELECT ALL CAST ( NULL AS INTEGER ) * col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( + col2 ) * - col1 + ( col0 + col1 ) FROM tab0 AS cor0
----
-2728
-7282
35

query I rowsort
SELECT DISTINCT + + 63 + col2 * - col2 FROM tab2 AS cor0
----
-1381
-613
-666

query I rowsort
SELECT + 39 + 88 AS col0 FROM tab1 AS cor0
----
127
127
127

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 53 + - 81 col1 FROM tab1 AS cor0
----
-134
-134
-134

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 80 col1 FROM tab1
----
80

query I rowsort
SELECT - 41 * + col0 AS col2 FROM tab2
----
-287
-3198
-3239

query I rowsort
SELECT - cor0.col1 * + 10 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 5e22af8b7528912f3b8522f470befb82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 + - col2 col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL ( - cor0.col2 ) * col1 + - col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT - col0 + 18 * + col1 AS col1 FROM tab1 AS cor0
----
116
154
465

query I rowsort
SELECT + - 75 FROM tab0 AS cor0
----
-75
-75
-75

query I rowsort
SELECT - - ( + cor0.col0 ) AS col0 FROM tab1 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - col1 * ( col2 ) col1 FROM tab0 cor0
----
-2814
-62
-7373

query I rowsort
SELECT - 0 + tab1.col2 * + tab1.col2 AS col1 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT ALL tab2.col2 * + 71 * col1 AS col2 FROM tab2
----
108914
45866
59427

query I rowsort
SELECT ALL - col0 * col1 - col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT - col0 + - 16 * col2 * cor0.col1 FROM tab0 AS cor0
----
-119481
-1587
-45432

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + 79 + ( + col0 ) col0 FROM tab0 AS cor0
----
-6770
-7100
-7628

query I rowsort
SELECT - - col0 * + 93 + ( - col0 ) * col2 AS col0 FROM tab1 AS cor0
----
-240
117
2304

query I rowsort
SELECT DISTINCT + col1 - + col1 AS col1 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 + + col2 col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT + col1 * - 74 + - col2 + + col1 AS col0 FROM tab0 AS cor0
----
-6311
-6725
-7082

query I rowsort
SELECT - + col1 * 67 - 58 * col2 AS col2 FROM tab0 AS cor0
----
-10853
-6557
-7676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5437
SELECT ALL - col1 * CAST( + ( - col0 ) AS SIGNED ) FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-5437
SELECT ALL - col1 * CAST ( + ( - col0 ) AS INTEGER ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - 2 + + col2 * + col1 AS col2 FROM tab0
----
2836
7460
95

query I rowsort
SELECT col0 * col1 * + 3 FROM tab0
----
10185
24297
6192

query I rowsort
SELECT + 16 + + col2 AS col0 FROM tab1
----
112
70
73

query I rowsort
SELECT - - cor0.col0 * - cor0.col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT col0 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-5443
SELECT - tab0.col2 + col1 DIV col2 AS col0 FROM tab0
----
-31
-81
96

skipif mysql # not compatible
query I rowsort label-5443
SELECT - tab0.col2 + col1 / col2 AS col0 FROM tab0
----
-31
-81
96

query I rowsort
SELECT + col2 * - col1 + col0 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT ALL + col0 + - tab0.col0 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT - cor0.col1 + + 16 FROM tab0 AS cor0
----
-70
-75
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-5447
SELECT ALL col0 DIV - cor0.col1 + 77 + cor0.col1 FROM tab1 AS cor0
----
103
81
84

skipif mysql # not compatible
query I rowsort label-5447
SELECT ALL col0 / - cor0.col1 + 77 + cor0.col1 FROM tab1 AS cor0
----
103
81
84

query I rowsort
SELECT DISTINCT + - col0 * - ( col2 ) FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL + col1 + 1 AS col2 FROM tab0 cor0
----
87
92
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5450
SELECT + col2 + CAST( + 9 AS SIGNED ) * col2 FROM tab2
----
260
270
380

skipif mysql # not compatible
query I rowsort label-5450
SELECT + col2 + CAST ( + 9 AS INTEGER ) * col2 FROM tab2
----
260
270
380

query I rowsort
SELECT + 6 * + col0 AS col1 FROM tab1 AS cor0
----
18
384
480

query I rowsort
SELECT - - cor0.col0 * col0 AS col0 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT 82 - - col0 FROM tab0 AS cor0
----
106
117
171

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 * 84 - + cor0.col1 col2 FROM tab0 AS cor0
----
7138
7553
8051

query I rowsort
SELECT ALL + col2 + col1 * col0 * col0 FROM tab2
----
106135
1546
358982

onlyif mysql # use DIV operator for integer division
query I rowsort label-5456
SELECT cor1.col1 DIV 73 FROM tab0 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-5456
SELECT cor1.col1 / 73 FROM tab0 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT tab1.col2 * 54 * tab1.col0 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to 80dd958bc9b651af4cf9217e0a3fdc2f

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0, tab1 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to 32e6d0f63bf719b0a999c75379e75eca

query I rowsort
SELECT ALL ( tab2.col1 ) * col0 AS col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL col0 * + tab0.col0 AS col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT - - col2 * + ( + col1 ) * col0 FROM tab1 AS cor0
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col2 + col0 ) col0 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT - 18 * + col0 * col2 FROM tab0 AS cor0
----
-131364
-14256
-630

query I rowsort
SELECT - ( + ( col2 ) ) * - col2 AS col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT col1 + - 76 * + col2 AS col1 FROM tab2 AS cor0
----
-1917
-2021
-2871

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5466
SELECT DISTINCT col0 + col2 * col0 * - CAST( col0 + - col1 AS SIGNED ) col1 FROM tab0
----
14685
2205
49128

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5466
SELECT DISTINCT col0 + col2 * col0 * - CAST ( col0 + - col1 AS INTEGER ) col1 FROM tab0
----
14685
2205
49128

query I rowsort
SELECT + col0 + + col1 * + col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT - col2 + - 10 + col1 FROM tab0 AS cor0
----
-1
43
86

query I rowsort
SELECT - ( + ( - col1 ) ) FROM tab2
----
17
31
59

query I rowsort
SELECT col1 + col2 * + col0 * + ( - 0 * + col1 ) AS col0 FROM tab2
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5471
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + 97 AS col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5471
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + 97 AS col2 FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5472
SELECT DISTINCT ( - col1 ) DIV tab0.col1 AS col0 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-5472
SELECT DISTINCT ( - col1 ) / tab0.col1 AS col0 FROM tab0
----
-1

query I rowsort
SELECT 69 + tab2.col2 FROM tab2
----
107
95
96

query I rowsort
SELECT - col2 + + col0 * col2 FROM tab0
----
34
7216
759

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - col1 col0 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT + - col2 - + col1 AS col0 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT ALL 53 * + col1 AS col2 FROM tab0 cor0
----
4558
4823
5141

query I rowsort
SELECT DISTINCT - col2 * - col2 * cor0.col0 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT col0 + - 10 FROM tab0 AS cor0
----
14
25
79

query I rowsort
SELECT DISTINCT + 70 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
70

query I rowsort
SELECT col2 * - ( + col0 ) AS col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - col0 + 87 * - col0 FROM tab0
----
-2112
-3080
-7832

query I rowsort
SELECT + col2 * 84 - col1 AS col1 FROM tab0 AS cor0
----
-13
2686
6797

query I rowsort
SELECT - col1 + - col0 + col1 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT - + col1 + + col2 * col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT DISTINCT - 40 FROM tab1, tab0 cor0
----
-40

query I rowsort
SELECT ALL 69 + col2 + - cor0.col1 FROM tab0 AS cor0
----
-27
16
60

query I rowsort
SELECT DISTINCT col0 * - 31 FROM tab2 AS cor0
----
-217
-2418
-2449

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5489
SELECT + CAST( NULL AS SIGNED ) AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5489
SELECT + CAST ( NULL AS INTEGER ) AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5490
SELECT DISTINCT col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5490
SELECT DISTINCT col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL

query I rowsort
SELECT - col0 * + ( 56 ) * col1 AS col0 FROM tab1
----
-35840
-4368
-58240

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5492
SELECT DISTINCT - col1 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5492
SELECT DISTINCT - col1 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT tab0.col2 * tab0.col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT + - col1 + - 25 FROM tab1 AS cor0
----
-35
-38
-51

query I rowsort
SELECT DISTINCT - - col0 * ( 22 ) + + col2 FROM tab0 AS cor0
----
2040
561
771

query I rowsort
SELECT ALL - - col1 - - ( + col0 ) * + col1 AS col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL + 33 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 76da8bc7cae18ecf856438f872430c80

query I rowsort
SELECT - 75 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 258bc565c64924d905a55eaaa6e57547

query I rowsort
SELECT DISTINCT + + 14 * - 98 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
-1372

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 96 col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to a7b3e5dd01c8929180b7ffda67f79798

query I rowsort
SELECT DISTINCT col1 - col0 FROM tab0 cor0
----
2
62

query I rowsort
SELECT ALL + col2 * col1 + col0 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5503
SELECT DISTINCT col1 * + CAST( + col1 AS SIGNED ) + + col2 * 48 + col1 AS col1 FROM tab1 AS cor0
----
2846
3294
4790

skipif mysql # not compatible
query I rowsort label-5503
SELECT DISTINCT col1 * + CAST ( + col1 AS INTEGER ) + + col2 * 48 + col1 AS col1 FROM tab1 AS cor0
----
2846
3294
4790

query I rowsort
SELECT DISTINCT col1 - ( col1 * + col2 ) FROM tab0 cor0
----
-2752
-7371
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + col2 + + tab0.col1 * + ( - col1 ) col0 FROM tab0
----
-7339
-8110
-9373

query I rowsort
SELECT - - 31 + + col2 * 46 * + cor0.col1 AS col2 FROM tab2 AS cor0
----
29747
38533
70595

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5507
SELECT CAST( NULL AS SIGNED ) * col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5507
SELECT CAST ( NULL AS INTEGER ) * col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + ( + col2 ) * col0 AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT - 63 AS col2 FROM tab1, tab0, tab1 cor0
----
-63

query I rowsort
SELECT DISTINCT + col0 * - 36 AS col1 FROM tab1
----
-108
-2304
-2880

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5511
SELECT DISTINCT CAST( 99 AS SIGNED ) + + col0 FROM tab2
----
106
177
178

skipif mysql # not compatible
query I rowsort label-5511
SELECT DISTINCT CAST ( 99 AS INTEGER ) + + col0 FROM tab2
----
106
177
178

query I rowsort
SELECT DISTINCT ( col2 ) + - col2 FROM tab2
----
0

query I rowsort
SELECT ALL - + ( - tab1.col0 ) FROM tab2, tab0, tab2 cor0, tab1
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5514
SELECT - col0 * - col2 + col2 DIV ( - tab0.col0 ) FROM tab0
----
35
7298
791

skipif mysql # not compatible
query I rowsort label-5514
SELECT - col0 * - col2 + col2 / ( - tab0.col0 ) FROM tab0
----
35
7298
791

query I rowsort
SELECT + col1 * - col0 + + col0 AS col1 FROM tab1 AS cor0
----
-576
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col2 + col1 col1 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT DISTINCT - 9 + - col1 FROM tab0 AS cor0
----
-100
-106
-95

query I rowsort
SELECT DISTINCT + 75 AS col0 FROM tab2
----
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-5519
SELECT ALL - col1 DIV - cor0.col0 AS col1 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-5519
SELECT ALL - col1 / - cor0.col0 AS col1 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT + + col0 * col1 + + 6 FROM tab0 AS cor0
----
2070
3401
8105

query I rowsort
SELECT DISTINCT - + col0 + + col2 * - col2 AS col0 FROM tab2 cor0
----
-1523
-736
-754

query I rowsort
SELECT - + 51 AS col2 FROM tab2 AS cor0
----
-51
-51
-51

query I rowsort
SELECT ALL - 62 + + col0 AS col1 FROM tab0 cor0
----
-27
-38
27

query I rowsort
SELECT ALL 34 * col0 - ( + cor0.col1 ) * col1 FROM tab0 cor0
----
-5255
-6580
-8219

query I rowsort
SELECT DISTINCT + - 65 AS col2 FROM tab1 AS cor0
----
-65

query I rowsort
SELECT - 31 * col2 * col2 AS col1 FROM tab2
----
-20956
-22599
-44764

onlyif mysql # use DIV operator for integer division
query I rowsort label-5527
SELECT ALL 29 DIV + tab2.col0 AS col2 FROM tab2
----
0
0
4

skipif mysql # not compatible
query I rowsort label-5527
SELECT ALL 29 / + tab2.col0 AS col2 FROM tab2
----
0
0
4

query I rowsort
SELECT - 70 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to c2a2994a4e94583683ccda2cc098c58f

onlyif mysql # use DIV operator for integer division
query I rowsort label-5529
SELECT ALL - - 35 + - col0 DIV - col1 AS col0 FROM tab1 AS cor0
----
35
41
41

skipif mysql # not compatible
query I rowsort label-5529
SELECT ALL - - 35 + - col0 / - col1 AS col0 FROM tab1 AS cor0
----
35
41
41

query I rowsort
SELECT - 20 * - cor0.col2 + + col2 FROM tab0 AS cor0
----
1722
21
693

query I rowsort
SELECT + + col0 * col2 * col2 + + col2 AS col2 FROM tab2 AS cor0
----
114114
5130
52754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + - cor0.col2 * col0 col2 FROM tab2 AS cor0
----
-158
-1969
-2985

skipif mysql # not compatible
query I rowsort
SELECT + col2 * CAST ( - col1 AS REAL ) * + col2 AS col1 FROM tab0 cor0
----
-611884
-93654
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5534
SELECT DISTINCT - col0 * CAST( col0 AS SIGNED ) AS col1 FROM tab2 cor0
----
-49
-6084
-6241

skipif mysql # not compatible
query I rowsort label-5534
SELECT DISTINCT - col0 * CAST ( col0 AS INTEGER ) AS col1 FROM tab2 cor0
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-5535
SELECT ALL col2 + + 20 DIV cor0.col2 FROM tab0 AS cor0
----
21
33
82

skipif mysql # not compatible
query I rowsort label-5535
SELECT ALL col2 + + 20 / cor0.col2 FROM tab0 AS cor0
----
21
33
82

query I rowsort
SELECT - col1 * + 34 FROM tab2 AS cor0
----
-1054
-2006
-578

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 77 * col0 + - col0 + + 41 col0 FROM tab0
----
1865
2701
6805

query I rowsort
SELECT col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5539
SELECT - col0 * CAST( NULL AS SIGNED ) + 54 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5539
SELECT - col0 * CAST ( NULL AS INTEGER ) + 54 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5540
SELECT DISTINCT + col0 + col0 DIV col1 FROM tab1 AS cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-5540
SELECT DISTINCT + col0 + col0 / col1 FROM tab1 AS cor0
----
3
70
86

query I rowsort
SELECT DISTINCT col0 + + 68 AS col2 FROM tab2 AS cor0
----
146
147
75

query I rowsort
SELECT DISTINCT col0 * 25 + - col2 * cor0.col0 - - cor0.col2 * col1 FROM tab1 cor0
----
-1478
-4432
1317

query I rowsort
SELECT ALL + 49 + - 75 * col0 AS col1 FROM tab2 AS cor0
----
-476
-5801
-5876

query I rowsort
SELECT ALL - + col2 + col1 * col1 FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT col0 + 8 * + col1 AS col1 FROM tab0 AS cor0
----
712
811
817

query I rowsort
SELECT DISTINCT + 53 - 42 FROM tab1 cor0
----
11

query I rowsort
SELECT DISTINCT + - ( col0 ) * col1 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL + col1 + - tab1.col1 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - col1 + ( col0 * + col2 ) AS col2 FROM tab0 cor0
----
-62
706
7207

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5550
SELECT CAST( NULL AS SIGNED ) * - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5550
SELECT CAST ( NULL AS INTEGER ) * - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 + - col1 * - col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT + col1 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 88 * 66 + + col0 FROM tab2 AS cor0
----
-5729
-5730
-5801

query I rowsort
SELECT DISTINCT + - ( 15 ) AS col2 FROM tab1 AS cor0
----
-15

onlyif mysql # use DIV operator for integer division
query I rowsort label-5555
SELECT + 77 + + col1 * col2 DIV col0 FROM tab2 AS cor0
----
196
85
96

skipif mysql # not compatible
query I rowsort label-5555
SELECT + 77 + + col1 * col2 / col0 FROM tab2 AS cor0
----
196
85
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5556
SELECT ALL - col2 * col2 + col1 DIV - cor0.col0 FROM tab1 AS cor0
----
-2924
-3249
-9216

skipif mysql # not compatible
query I rowsort label-5556
SELECT ALL - col2 * col2 + col1 / - cor0.col0 FROM tab1 AS cor0
----
-2924
-3249
-9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * - 19 col0 FROM tab0 AS cor0
----
-1558
-19
-627

query I rowsort
SELECT DISTINCT + + 49 FROM tab0 cor0
----
49

query I rowsort
SELECT + 24 + + col0 AS col0 FROM tab1 AS cor0
----
104
27
88

query I rowsort
SELECT DISTINCT cor0.col2 * col1 + 39 AS col1 FROM tab1 AS cor0
----
1287
1443
609

query I rowsort
SELECT - col1 + cor0.col2 + + col0 FROM tab0 AS cor0
----
-29
-61
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5562
SELECT - + col0 * cor0.col2 + + col2 DIV + col0 FROM tab2 AS cor0
----
-186
-2028
-3002

skipif mysql # not compatible
query I rowsort label-5562
SELECT - + col0 * cor0.col2 + + col2 / + col0 FROM tab2 AS cor0
----
-186
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

onlyif mysql # use DIV operator for integer division
query I rowsort label-5564
SELECT + 9 DIV - col0 AS col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5564
SELECT + 9 / - col0 AS col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - - 9 * col0 FROM tab1 AS cor0
----
27
576
720

query I rowsort
SELECT ALL + - 15 + - cor0.col1 * + col0 AS col2 FROM tab0 AS cor0
----
-2079
-3410
-8114

query I rowsort
SELECT DISTINCT + cor0.col2 * - cor0.col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + 89 * + col2 FROM tab0 AS cor0
----
2937
7298
89

query I rowsort
SELECT DISTINCT - 78 AS col1 FROM tab2 AS cor0
----
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * - col1 col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col1 * + cor0.col0 col0 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT col0 * ( col1 ) + - col2 * col2 * 85 AS col1 FROM tab0 AS cor0
----
-563441
-90501
3310

query I rowsort
SELECT - col1 * - 22 FROM tab1
----
220
286
572

query I rowsort
SELECT + - col0 * col0 + col0 AS col2 FROM tab0 cor0
----
-1190
-552
-7832

query I rowsort
SELECT - col0 * - cor0.col0 + col2 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT - + col1 + + col2 * col2 AS col1 FROM tab2 AS cor0
----
1427
617
698

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5577
SELECT ALL + col2 * tab2.col0 + + CAST( - col1 AS SIGNED ) AS col1 FROM tab2
----
158
1969
2985

skipif mysql # not compatible
query I rowsort label-5577
SELECT ALL + col2 * tab2.col0 + + CAST ( - col1 AS INTEGER ) AS col1 FROM tab2
----
158
1969
2985

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5578
SELECT col2 + + CAST( - col2 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5578
SELECT col2 + + CAST ( - col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + - col2 * + 54 AS col1 FROM tab2 AS cor0
----
-1404
-1458
-2052

query I rowsort
SELECT - col2 * col2 + - col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT ( - col0 ) + col1 * col1 + - 31 FROM tab2 AS cor0
----
179
3372
923

onlyif mysql # use DIV operator for integer division
query I rowsort label-5582
SELECT + - ( - col0 ) + + col1 DIV - col0 AS col0 FROM tab0 cor0
----
21
33
88

skipif mysql # not compatible
query I rowsort label-5582
SELECT + - ( - col0 ) + + col1 / - col0 AS col0 FROM tab0 cor0
----
21
33
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-5583
SELECT DISTINCT + cor1.col0 DIV 79 AS col1 FROM tab1, tab1 cor0, tab1 AS cor1
----
0
1

skipif mysql # not compatible
query I rowsort label-5583
SELECT DISTINCT + cor1.col0 / 79 AS col1 FROM tab1, tab1 cor0, tab1 AS cor1
----
0
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5584
SELECT ALL CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5584
SELECT ALL CAST ( NULL AS INTEGER ) * col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5585
SELECT CAST( cor0.col0 AS SIGNED ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

skipif mysql # not compatible
query I rowsort label-5585
SELECT CAST ( cor0.col0 AS INTEGER ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT DISTINCT - + col2 - + 42 FROM tab2 AS cor0
----
-68
-69
-80

query I rowsort
SELECT - + cor0.col1 + cor0.col1 * + cor0.col1 * + col0 FROM tab2 AS cor0
----
22814
271459
6696

query I rowsort
SELECT DISTINCT 32 + + cor0.col0 AS col1 FROM tab2 AS cor0
----
110
111
39

query I rowsort
SELECT ALL - 99 + + 95 AS col2 FROM tab2 AS cor0
----
-4
-4
-4

query I rowsort
SELECT ALL 21 + col1 FROM tab1 AS cor0
----
31
34
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-5591
SELECT ALL - - 47 * 36 DIV col1 AS col1 FROM tab0 AS cor0
----
17
18
19

skipif mysql # not compatible
query I rowsort label-5591
SELECT ALL - - 47 * 36 / col1 AS col1 FROM tab0 AS cor0
----
17
18
19

onlyif mysql # use DIV operator for integer division
query I rowsort label-5592
SELECT + - col0 DIV cor0.col2 + + col0 FROM tab0 AS cor0
----
0
24
88

skipif mysql # not compatible
query I rowsort label-5592
SELECT + - col0 / cor0.col2 + + col0 FROM tab0 AS cor0
----
0
24
88

query I rowsort
SELECT ALL col1 * + ( col0 ) + - col1 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT - 24 + + tab2.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to aa71a05ca1e669f5a5eec28723618397

onlyif mysql # use DIV operator for integer division
query I rowsort label-5595
SELECT DISTINCT col0 DIV 28 + 91 FROM tab1
----
91
93

skipif mysql # not compatible
query I rowsort label-5595
SELECT DISTINCT col0 / 28 + 91 FROM tab1
----
91
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5596
SELECT DISTINCT + CAST( NULL AS SIGNED ) col0 FROM tab2, tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5596
SELECT DISTINCT + CAST ( NULL AS INTEGER ) col0 FROM tab2, tab0 AS cor0
----
NULL

query I rowsort
SELECT + col2 * col0 * + col1 AS col2 FROM tab1
----
36480
4212
99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5598
SELECT - col1 - - CAST( - 81 AS SIGNED ) * tab0.col2 FROM tab0
----
-178
-2759
-6733

skipif mysql # not compatible
query I rowsort label-5598
SELECT - col1 - - CAST ( - 81 AS INTEGER ) * tab0.col2 FROM tab0
----
-178
-2759
-6733

query I rowsort
SELECT - col1 * ( - col0 ) + 47 * 80 FROM tab2 cor0
----
3977
5103
8362

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5600
SELECT col0 * CAST( col2 AS SIGNED ) col1 FROM tab1
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5600
SELECT col0 * CAST ( col2 AS INTEGER ) col1 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT ( col0 ) * + col0 * 0 + col2 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL - + col1 * col2 * + cor0.col1 + - 3 AS col1 FROM tab1 AS cor0
----
-16227
-36507
-5703

query I rowsort
SELECT - 77 * col2 AS col0 FROM tab2
----
-2002
-2079
-2926

query I rowsort
SELECT - cor0.col2 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT ALL col1 * + 52 + - col1 FROM tab0 AS cor0
----
4386
4641
4947

query I rowsort
SELECT col0 - ( col0 ) AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 70 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
70

query I rowsort
SELECT - col2 - ( - tab1.col2 + col1 ) AS col1 FROM tab1
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5609
SELECT - col2 * CAST( NULL AS SIGNED ) * col1 + - col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5609
SELECT - col2 * CAST ( NULL AS INTEGER ) * col1 + - col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5610
SELECT col0 DIV col0 + cor0.col1 FROM tab0 cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-5610
SELECT col0 / col0 + cor0.col1 FROM tab0 cor0
----
87
92
98

query I rowsort
SELECT ALL - col0 * + col0 + - col1 * col0 FROM tab1
----
-4736
-7440
-87

query I rowsort
SELECT - col1 - col2 AS col0 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT - cor0.col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT DISTINCT col1 + - 59 * - 9 AS col0 FROM tab0 AS cor0
----
617
622
628

query I rowsort
SELECT ALL - col0 + ( - col0 ) - + col2 * + col1 FROM tab2 AS cor0
----
-1690
-804
-851

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 DISTINCT + col0 * col2 col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL - col0 * + col2 + col1 + - col0 FROM tab0 AS cor0
----
-7296
-730
27

query I rowsort
SELECT ALL col1 * - col1 + + cor0.col1 + cor0.col2 * col2 FROM tab2 AS cor0
----
-201
-2746
1172

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + tab1.col0 * - col2 col0 FROM tab1
----
-216
-3705
-7776

query I rowsort
SELECT ALL - col0 FROM tab0 WHERE NOT NULL > NULL
----

query I rowsort
SELECT - col2 * - col0 * - col1 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT + col0 * - col1 * - col1 AS col1 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT DISTINCT + + col0 + + col1 * col0 AS col0 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT col0 + - col2 * + col2 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT DISTINCT + col0 * col0 * + col2 FROM tab1 AS cor0
----
233472
486
614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-5627
SELECT - col0 + col1 DIV cor0.col0 + - col1 FROM tab2 AS cor0
----
-137
-34
-96

skipif mysql # not compatible
query I rowsort label-5627
SELECT - col0 + col1 / cor0.col0 + - col1 FROM tab2 AS cor0
----
-137
-34
-96

query I rowsort
SELECT cor0.col2 * cor0.col2 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 50c4b0a13fc95d13442dcf4b04857ce8

query I rowsort
SELECT ALL - tab0.col1 + col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT tab2.col1 + + col0 FROM tab2
----
137
38
96

query I rowsort
SELECT + col1 * + col0 + col2 AS col1 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT ALL - + col2 + - col1 * col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT + - cor0.col1 * + cor0.col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL - + col2 * - col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + + col1 * col1 + col2 AS col2 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT ALL cor0.col2 * + col2 * + col0 + + cor0.col1 FROM tab1 cor0
----
207946
737293
8774

query I rowsort
SELECT DISTINCT col1 * + col2 * col0 + col1 FROM tab0 cor0
----
3492
664209
68198

query I rowsort
SELECT DISTINCT + + cor0.col0 * col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT + col2 * + col2 + - col2 * + col0 - + col2 * col1 FROM tab0
----
-131
-2541
-8036

onlyif mysql # use DIV operator for integer division
query I rowsort label-5640
SELECT ALL col0 * col2 * - col0 - + col0 DIV col2 AS col0 FROM tab0
----
-1260
-19008
-649523

skipif mysql # not compatible
query I rowsort label-5640
SELECT ALL col0 * col2 * - col0 - + col0 / col2 AS col0 FROM tab0
----
-1260
-19008
-649523

query I rowsort
SELECT DISTINCT - col0 * col2 + col1 AS col0 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT - col1 * col2 + - col0 * col0 FROM tab2
----
-6887
-7618
-886

query I rowsort
SELECT col2 + + col0 * col1 + - col0 AS col1 FROM tab0
----
2073
3361
8092

query I rowsort
SELECT - col1 * col1 + - col0 * - col1 AS col2 FROM tab2 AS cor0
----
-744
1054
1121

query I rowsort
SELECT + col2 + - col2 + col2 * col1 * - col0 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT col0 + + col2 * tab2.col0 + - tab2.col2 * col0 AS col1 FROM tab2
----
7
78
79

query I rowsort
SELECT col1 + + col2 + + col2 * col1 FROM tab2
----
1619
701
895

query I rowsort
SELECT tab0.col1 * - col1 AS col0 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT + col0 + tab2.col1 AS col2 FROM tab2
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5650
SELECT ALL col2 + - tab1.col1 DIV col0 FROM tab1
----
46
57
96

skipif mysql # not compatible
query I rowsort label-5650
SELECT ALL col2 + - tab1.col1 / col0 FROM tab1
----
46
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 col0 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-5652
SELECT 43 DIV col1 + col2 AS col0 FROM tab2 AS cor0
----
26
28
40

skipif mysql # not compatible
query I rowsort label-5652
SELECT 43 / col1 + col2 AS col0 FROM tab2 AS cor0
----
26
28
40

query III rowsort
SELECT * FROM tab2 WHERE NULL < ( col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5654
SELECT - col0 DIV - tab0.col2 + col2 AS col2 FROM tab0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-5654
SELECT - col0 / - tab0.col2 + col2 AS col2 FROM tab0
----
33
36
83

query I rowsort
SELECT DISTINCT + col0 + - col2 - col0 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT ALL + tab1.col2 + - col1 - - col2 AS col0 FROM tab1
----
104
179
82

query I rowsort
SELECT ALL col1 * + col1 * + col2 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT - tab1.col2 * + col1 AS col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT col0 * + col2 + cor0.col1 AS col2 FROM tab1 AS cor0
----
188
3658
7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-5660
SELECT 20 * - col0 DIV col0 AS col0 FROM tab1
----
-20
-20
-20

skipif mysql # not compatible
query I rowsort label-5660
SELECT 20 * - col0 / col0 AS col0 FROM tab1
----
-20
-20
-20

onlyif mysql # use DIV operator for integer division
query I rowsort label-5661
SELECT col0 * + tab1.col2 DIV col2 col0 FROM tab1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5661
SELECT col0 * + tab1.col2 / col2 col0 FROM tab1
----
3
64
80

query I rowsort
SELECT 40 * + col1 AS col1 FROM tab2
----
1240
2360
680

query I rowsort
SELECT + 43 + + col0 AS col2 FROM tab1 AS cor0
----
107
123
46

query I rowsort
SELECT - col2 AS col2 FROM tab0 WHERE NOT ( - col0 ) <> ( NULL )
----

query I rowsort
SELECT ALL + col2 AS col2 FROM tab2 WHERE ( NULL ) NOT BETWEEN - col2 * col1 / col1 AND NULL
----

query I rowsort
SELECT DISTINCT tab0.col0 + + col0 * - col2 AS col2 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT ALL + col2 + col2 * col0 FROM tab0
----
36
7380
825

query I rowsort
SELECT DISTINCT cor0.col0 * + col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT col1 - col0 * + tab2.col1 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT ALL - col2 - col0 * - col2 FROM tab1
----
108
3591
7584

query III rowsort
SELECT * FROM tab1 WHERE NOT + col1 * + col2 > ( col2 )
----

query I rowsort
SELECT ALL + col1 + col2 FROM tab2 WHERE ( + col2 ) < NULL
----

query I rowsort
SELECT col0 * col0 + + col0 + + col1 * tab0.col1 FROM tab0
----
10669
16291
7996

query I rowsort
SELECT - col1 AS col2 FROM tab0 WHERE col2 <= - col2
----

query I rowsort
SELECT col2 FROM tab1 WHERE NOT col1 * col0 = col0 * col2
----
54
57
96

query I rowsort
SELECT ALL col2 + + col0 AS col0 FROM tab0 WHERE NOT NULL = col0 * col2
----

query I rowsort
SELECT + col1 + + col2 * col0 FROM tab2
----
2087
220
3019

query I rowsort
SELECT ALL - + 95 AS col1 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to cf302b83f15b730fe35c19bdd9363c13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 18 col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 2dbe09d9295cfd52d854fefabf2cec4e

query I rowsort
SELECT ALL tab0.col1 - + tab0.col1 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT 34 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
34

query I rowsort
SELECT DISTINCT - col2 + - tab1.col1 * ( - col2 ) FROM tab1
----
1152
1350
513

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5683
SELECT ( - col1 ) + - cor0.col1 * + col2 * col2 + - CAST( NULL AS DECIMAL ) * col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5683
SELECT ( - col1 ) + - cor0.col1 * + col2 * col2 + - CAST ( NULL AS REAL ) * col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 74 AS col1 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 5a477330c946251f814fbbfd08e77c28

query I rowsort
SELECT ALL - 48 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 2558735eaa258a08592aef9d33020c18

query I rowsort
SELECT + col2 * col1 * ( 78 ) AS col1 FROM tab0
----
221364
582036
7566

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + tab2.col1 col0 FROM tab2
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-5688
SELECT col0 + - col1 DIV 27 AS col2 FROM tab2 AS cor0
----
6
76
79

skipif mysql # not compatible
query I rowsort label-5688
SELECT col0 + - col1 / 27 AS col2 FROM tab2 AS cor0
----
6
76
79

query I rowsort
SELECT + col0 + ( - 1 ) * + cor0.col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - 93 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

query I rowsort
SELECT col1 * tab0.col0 - + col0 AS col0 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT col1 * col0 + col0 + + cor0.col2 * cor0.col0 AS col2 FROM tab0 AS cor0
----
15486
2880
3465

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * cor0.col2 col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + + col2 + - 83 AS col2 FROM tab2 AS cor0
----
-45
-56
-57

query I rowsort
SELECT ALL col2 + col1 * - col0 AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT - col1 * + 34 FROM tab0 AS cor0
----
-2924
-3094
-3298

onlyif mysql # use DIV operator for integer division
query I rowsort label-5697
SELECT ALL + + 78 + col2 DIV + col1 AS col0 FROM tab0 AS cor0
----
78
78
78

skipif mysql # not compatible
query I rowsort label-5697
SELECT ALL + + 78 + col2 / + col1 AS col0 FROM tab0 AS cor0
----
78
78
78

query I rowsort
SELECT ( cor0.col2 ) - - cor0.col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT - - col0 * cor0.col0 + - col0 FROM tab0 AS cor0
----
1190
552
7832

query I rowsort
SELECT - + 7 * 31 FROM tab0 AS cor0
----
-217
-217
-217

query I rowsort
SELECT + + 60 * - col0 AS col2 FROM tab0 AS cor0
----
-1440
-2100
-5340

onlyif mysql # use DIV operator for integer division
query I rowsort label-5702
SELECT - + col1 * + 0 * col0 - - 67 DIV col1 FROM tab2 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-5702
SELECT - + col1 * + 0 * col0 - - 67 / col1 FROM tab2 AS cor0
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5703
SELECT col0 + col0 DIV + col2 + - col0 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5703
SELECT col0 + col0 / + col2 + - col0 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT + + ( + col1 ) + - 7 * + col0 FROM tab2 AS cor0
----
-18
-487
-536

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 - 97 col1 FROM tab2, tab2 cor0
----
9 values hashing to 7befb1edf2a81995e5e6744f110ab39f

query I rowsort
SELECT + col1 + - col2 + cor0.col1 AS col1 FROM tab1 AS cor0
----
-2
-37
-70

query I rowsort
SELECT - 33 * col0 + + ( 4 + cor0.col2 ) FROM tab2 AS cor0
----
-200
-2544
-2565

query I rowsort
SELECT 50 + + cor0.col2 FROM tab1 AS cor0
----
104
107
146

query I rowsort
SELECT ALL - + col0 + + col2 * 24 * cor0.col1 FROM tab1 AS cor0
----
13616
29872
33693

query I rowsort
SELECT - - ( + col2 ) * - col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT + - col0 - col0 AS col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT DISTINCT + + cor0.col1 + - col0 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-5713
SELECT ALL - col1 + - col1 DIV 91 col0 FROM tab2
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5713
SELECT ALL - col1 + - col1 / 91 col0 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT + col0 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col1 * - 41 col0 FROM tab0 AS cor0
----
-3493
-3649
-3976

query I rowsort
SELECT + - 39 AS col2 FROM tab0 cor0
----
-39
-39
-39

query I rowsort
SELECT + cor0.col1 - col2 AS col0 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL + - col1 * col0 * + 21 FROM tab1 AS cor0
----
-13440
-1638
-21840

query I rowsort
SELECT DISTINCT - 95 * col1 FROM tab2 cor0
----
-1615
-2945
-5605

query I rowsort
SELECT - col1 + col1 * ( - col1 * + col2 ) FROM tab1 AS cor0
----
-16237
-36530
-5710

query I rowsort
SELECT - col2 * col2 + - col1 + 71 AS col0 FROM tab0 cor0
----
-1104
-27
-6744

onlyif mysql # use DIV operator for integer division
query I rowsort label-5722
SELECT ALL + 97 + + col1 DIV col0 FROM tab0 AS cor0
----
100
98
99

skipif mysql # not compatible
query I rowsort label-5722
SELECT ALL + 97 + + col1 / col0 FROM tab0 AS cor0
----
100
98
99

query I rowsort
SELECT - 33 * + col0 + 89 AS col2 FROM tab0 AS cor0
----
-1066
-2848
-703

query I rowsort
SELECT + - col2 * ( cor0.col1 ) + cor0.col2 + cor0.col2 AS col2 FROM tab1 AS cor0
----
-1056
-1296
-456

query I rowsort
SELECT DISTINCT + col2 * - cor0.col2 AS col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT col2 + - col0 + col2 * + col2 AS col1 FROM tab0 AS cor0
----
-33
1098
6717

query I rowsort
SELECT ALL + - col2 + + col0 * col2 AS col0 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT ALL - col2 + tab0.col2 * + ( - 53 ) * col1 FROM tab0
----
-150447
-395568
-5142

query I rowsort
SELECT - 3 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5730
SELECT 0 / + cor0.col1 + CAST( NULL AS DECIMAL ) AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5730
SELECT 0 / + cor0.col1 + CAST ( NULL AS REAL ) AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + col1 + col2 * col2 AS col2 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT 41 FROM tab2 cor0
----
41
41
41

query I rowsort
SELECT DISTINCT - ( col1 ) + + cor0.col1 * 56 * col0 AS col1 FROM tab1 cor0
----
35830
4342
58227

query I rowsort
SELECT - 11 + + 24 * - col0 FROM tab1 AS cor0
----
-1547
-1931
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col1 col2 FROM tab1
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5736
SELECT CAST( NULL AS SIGNED ) / col2 - tab0.col0 * + ( col0 ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5736
SELECT CAST ( NULL AS INTEGER ) / col2 - tab0.col0 * + ( col0 ) AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( - 75 * col0 ) FROM tab0
----
-1800
-2625
-6675

query I rowsort
SELECT + tab1.col2 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT + ( - 87 ) + col2 FROM tab0
----
-5
-54
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-5740
SELECT ALL - col2 DIV 57 + col0 + + col1 FROM tab0
----
110
132
179

skipif mysql # not compatible
query I rowsort label-5740
SELECT ALL - col2 / 57 + col0 + + col1 FROM tab0
----
110
132
179

query I rowsort
SELECT - cor0.col1 + cor0.col1 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT DISTINCT - - cor0.col2 * + cor0.col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT + cor0.col0 * col0 + ( col0 ) AS col1 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT - + col2 * - 0 + - 94 - + col1 * col2 AS col1 FROM tab0 AS cor0
----
-191
-2932
-7556

query I rowsort
SELECT cor0.col1 * ( col1 ) + + col2 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT ALL col0 * - 55 FROM tab1 AS cor0
----
-165
-3520
-4400

query I rowsort
SELECT + + col1 * col1 * - 28 FROM tab0 AS cor0
----
-207088
-231868
-263452

query I rowsort
SELECT + col2 - 67 * - col0 AS col1 FROM tab1 AS cor0
----
255
4345
5456

query I rowsort
SELECT DISTINCT + cor0.col1 + col1 * col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT col1 + 6 AS col0 FROM tab0 AS cor0
----
103
92
97

query I rowsort
SELECT DISTINCT + col2 * 74 FROM tab1 AS cor0
----
3996
4218
7104

query I rowsort
SELECT - + col1 * 10 AS col2 FROM tab0 AS cor0
----
-860
-910
-970

query I rowsort
SELECT + + 20 + cor0.col1 FROM tab0 cor0
----
106
111
117

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5754
SELECT DISTINCT - + CAST( NULL AS SIGNED ) / cor0.col1 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5754
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) / cor0.col1 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + 40 + cor0.col0 * col1 FROM tab1 AS cor0
----
1080
118
680

query I rowsort
SELECT - col0 + 12 FROM tab1 AS cor0
----
-52
-68
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col0 + col0 * cor0.col2 * - 32 col2 FROM tab1 cor0
----
-116800
-245840
-5187

query I rowsort
SELECT ALL + 39 + col2 AS col1 FROM tab0 AS cor0
----
121
40
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-5759
SELECT DISTINCT - 65 DIV - col2 - - col2 AS col0 FROM tab0 AS cor0
----
34
66
82

skipif mysql # not compatible
query I rowsort label-5759
SELECT DISTINCT - 65 / - col2 - - col2 AS col0 FROM tab0 AS cor0
----
34
66
82

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 cor0, tab2 cor1, tab2, tab0 AS cor2
----
3645 values hashing to 52c9380a39df7a744b9f2f2c5bf55dd5

onlyif mysql # use DIV operator for integer division
query I rowsort label-5761
SELECT DISTINCT - - col2 DIV - col1 + + 24 * - col0 * col2 AS col0 FROM tab1 cor0
----
-184327
-3890
-87557

skipif mysql # not compatible
query I rowsort label-5761
SELECT DISTINCT - - col2 / - col1 + + 24 * - col0 * col2 AS col0 FROM tab1 cor0
----
-184327
-3890
-87557

query I rowsort
SELECT DISTINCT + col2 * - col0 + 29 AS col0 FROM tab2 AS cor0
----
-160
-1999
-2973

query I rowsort
SELECT - + cor0.col0 * + col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 72 col2 FROM tab2 cor0
----
72
72
72

query I rowsort
SELECT ALL - 74 AS col2 FROM tab0 cor0
----
-74
-74
-74

query I rowsort
SELECT DISTINCT - col2 * col1 * - cor0.col2 + - col1 * col2 + - col0 FROM tab0 AS cor0
----
-35
604333
90792

query I rowsort
SELECT + col1 * - col2 + col2 AS col1 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT ALL + col2 + 98 * - 72 FROM tab2 AS cor0
----
-7018
-7029
-7030

onlyif mysql # use DIV operator for integer division
query I rowsort label-5769
SELECT ALL + - col1 + + 12 DIV + cor0.col2 AS col1 FROM tab1 cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-5769
SELECT ALL + - col1 + + 12 / + cor0.col2 AS col1 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - col2 * + 80 FROM tab0 AS cor0
----
-2640
-6560
-80

query I rowsort
SELECT - + col1 * - col1 AS col1 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-5772
SELECT - + col2 + 1 * 23 DIV cor0.col2 FROM tab0 cor0
----
-33
-82
22

skipif mysql # not compatible
query I rowsort label-5772
SELECT - + col2 + 1 * 23 / cor0.col2 FROM tab0 cor0
----
-33
-82
22

query I rowsort
SELECT ALL + col2 + col0 * - 75 FROM tab2 AS cor0
----
-498
-5824
-5887

query I rowsort
SELECT ALL 23 + - 37 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to c2bf0e2420d22cd58d7ee3b30827afcc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 49 col0 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

query I rowsort
SELECT ALL + col1 * - col1 AS col2 FROM tab2
----
-289
-3481
-961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + cor0.col1 col0 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5778
SELECT ALL col1 DIV 44 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5778
SELECT ALL col1 / 44 AS col2 FROM tab1 AS cor0
----
0
0
0

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-5780
SELECT DISTINCT - 3 DIV + tab0.col1 AS col1 FROM tab0, tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5780
SELECT DISTINCT - 3 / + tab0.col1 AS col1 FROM tab0, tab0 AS cor0
----
0

query I rowsort
SELECT col1 + col0 - - cor0.col0 * + ( 67 * col0 ) FROM tab1 AS cor0
----
274506
428893
632

query I rowsort
SELECT - ( + col0 ) + + col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT + tab1.col1 * ( + col1 * col0 + col1 ) FROM tab1
----
13689
2704
6500

onlyif mysql # use DIV operator for integer division
query I rowsort label-5784
SELECT ALL + col2 * ( 20 ) DIV col0 FROM tab2
----
6
77
9

skipif mysql # not compatible
query I rowsort label-5784
SELECT ALL + col2 * ( 20 ) / col0 FROM tab2
----
6
77
9

query I rowsort
SELECT col0 + - ( - col1 ) + - 18 FROM tab1
----
11
56
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5786
SELECT ALL + 26 + + tab2.col0 * - CAST( NULL AS SIGNED ) FROM tab2, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5786
SELECT ALL + 26 + + tab2.col0 * - CAST ( NULL AS INTEGER ) FROM tab2, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + col1 col2 FROM tab2
----
137
38
96

query I rowsort
SELECT col1 * - cor0.col1 + 15 FROM tab1 cor0
----
-154
-661
-85

query I rowsort
SELECT ALL + 50 AS col2 FROM tab0
----
50
50
50

query I rowsort
SELECT 4 + col1 * + tab2.col0 AS col1 FROM tab2
----
1347
221
4606

query I rowsort
SELECT DISTINCT + 81 + - col2 * col1 AS col1 FROM tab0
----
-16
-2757
-7381

query I rowsort
SELECT ALL + 88 * + 42 * + col0 + 83 FROM tab1
----
11171
236627
295763

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * col2 + 97 * + 36 col2 FROM tab1 AS cor0
----
2088
2244
2922

query I rowsort
SELECT DISTINCT - ( + col2 ) AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT cor0.col2 + col0 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT 24 + col0 AS col0 FROM tab1 AS cor0
----
104
27
88

query I rowsort
SELECT DISTINCT - col2 * - cor0.col0 + ( + col2 ) * - col2 AS col0 FROM tab0 AS cor0
----
-297
34
574

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + cor0.col2 * col2 col1 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT + 93 + col2 * cor0.col1 FROM tab0 AS cor0
----
190
2931
7555

onlyif mysql # use DIV operator for integer division
query I rowsort label-5800
SELECT DISTINCT - 14 DIV col0 AS col0 FROM tab1 AS cor0
----
-4
0

skipif mysql # not compatible
query I rowsort label-5800
SELECT DISTINCT - 14 / col0 AS col0 FROM tab1 AS cor0
----
-4
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col2 ) * + col2 + cor0.col2 col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT + - cor0.col2 * col2 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
-2942
-3259
-9229

query I rowsort
SELECT ALL - 61 + col1 + cor0.col2 FROM tab0 AS cor0
----
112
37
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-5804
SELECT + ( + col1 ) + col2 DIV col1 AS col1 FROM tab2 AS cor0
----
19
31
59

skipif mysql # not compatible
query I rowsort label-5804
SELECT + ( + col1 ) + col2 / col1 AS col1 FROM tab2 AS cor0
----
19
31
59

query I rowsort
SELECT 44 + - col2 FROM tab1 AS cor0
----
-10
-13
-52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5806
SELECT DISTINCT + CAST( NULL AS SIGNED ) + + col0 + + col1 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5806
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + + col0 + + col1 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL cor1.col0 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5808
SELECT + CAST( + col1 AS SIGNED ) + - col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5808
SELECT + CAST ( + col1 AS INTEGER ) + - col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col0 * col2 + col2 AS col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL - col2 + + col1 + - col2 AS col2 FROM tab2 AS cor0
----
-23
-59
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - - 94 * + col0 col2 FROM tab2 AS cor0
----
689
7391
7443

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 49 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 01b1fa22fee872a7ba64f90d6046ffae

query I rowsort
SELECT ALL + - col2 * - col2 + 67 AS col2 FROM tab1 cor0
----
2983
3316
9283

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5814
SELECT - CAST( NULL AS DECIMAL ) * - 91 col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5814
SELECT - CAST ( NULL AS REAL ) * - 91 col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 + - ( tab0.col1 ) * - ( col1 ) + - tab0.col0 FROM tab0
----
7348
8103
9339

query I rowsort
SELECT ALL ( + cor0.col1 ) FROM tab0, tab0 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5817
SELECT DISTINCT CAST( - 85 * + tab1.col1 AS SIGNED ) + 86 AS col2 FROM tab1
----
-1019
-2124
-764

skipif mysql # not compatible
query I rowsort label-5817
SELECT DISTINCT CAST ( - 85 * + tab1.col1 AS INTEGER ) + 86 AS col2 FROM tab1
----
-1019
-2124
-764

query I rowsort
SELECT ALL - col2 + + 79 FROM tab2
----
41
52
53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5819
SELECT DISTINCT CAST( - col1 AS SIGNED ) * - col0 + 17 FROM tab2
----
1360
234
4619

skipif mysql # not compatible
query I rowsort label-5819
SELECT DISTINCT CAST ( - col1 AS INTEGER ) * - col0 + 17 FROM tab2
----
1360
234
4619

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5820
SELECT DISTINCT - col1 - CAST( - col1 AS SIGNED ) * - col2 FROM tab2 AS cor0
----
-1593
-663
-868

skipif mysql # not compatible
query I rowsort label-5820
SELECT DISTINCT - col1 - CAST ( - col1 AS INTEGER ) * - col2 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT cor0.col1 * ( col0 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL + col2 * - ( - col2 ) FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL - col2 * - col1 - + 42 FROM tab0
----
2796
55
7420

query I rowsort
SELECT - col1 * + col0 + + col2 AS col0 FROM tab0
----
-2031
-3394
-8017

skipif mysql # not compatible
query I rowsort
SELECT - col1 * CAST ( col0 AS REAL ) FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT + + col1 * - 29 FROM tab2 AS cor0
----
-1711
-493
-899

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col1 - - col1 col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT col2 + 59 * - col1 AS col0 FROM tab1
----
-1480
-533
-671

query I rowsort
SELECT ALL - col1 * col2 * 64 FROM tab1
----
-36480
-79872
-89856

query I rowsort
SELECT - col2 + - ( col2 ) * + col0 FROM tab1
----
-216
-3705
-7776

query I rowsort
SELECT col0 - + 49 AS col0 FROM tab1
----
-46
15
31

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5832
SELECT ALL + CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5832
SELECT ALL + CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + 70 FROM tab0, tab1 AS cor0
----
70

query I rowsort
SELECT + col0 + + 98 * col2 FROM tab0 AS cor0
----
133
3258
8125

onlyif mysql # use DIV operator for integer division
query I rowsort label-5835
SELECT DISTINCT col1 DIV col0 AS col1 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-5835
SELECT DISTINCT col1 / col0 AS col1 FROM tab0
----
1
2
3

query I rowsort
SELECT - col0 * col1 * 93 FROM tab0 AS cor0
----
-191952
-315735
-753207

query I rowsort
SELECT tab1.col1 + 91 * - 50 AS col1 FROM tab1
----
-4524
-4537
-4540

query I rowsort
SELECT DISTINCT + col0 * 33 AS col1 FROM tab2 AS cor0
----
231
2574
2607

query I rowsort
SELECT ALL + ( + col1 ) * col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT 14 - col2 FROM tab1 AS cor0
----
-40
-43
-82

query I rowsort
SELECT ALL + + 78 * col0 + col1 AS col2 FROM tab0 AS cor0
----
1958
2827
7033

query I rowsort
SELECT DISTINCT - + cor0.col2 + col1 * + col1 AS col1 FROM tab1 AS cor0
----
43
622
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-5843
SELECT DISTINCT col2 DIV + col2 AS col0 FROM tab1 cor0
----
1

skipif mysql # not compatible
query I rowsort label-5843
SELECT DISTINCT col2 / + col2 AS col0 FROM tab1 cor0
----
1

query I rowsort
SELECT 20 * col1 + col1 * cor0.col1 * - 31 AS col0 FROM tab2 AS cor0
----
-106731
-29171
-8619

query I rowsort
SELECT + + cor0.col1 * - cor0.col2 + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * - col1 + col2 col0 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT + + cor0.col2 * + col0 - col0 * col2 * + col0 AS col2 FROM tab0 cor0
----
-1190
-18216
-642224

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5848
SELECT DISTINCT + CAST( col2 AS SIGNED ) - + col0 FROM tab1 AS cor0
----
-7
16
51

skipif mysql # not compatible
query I rowsort label-5848
SELECT DISTINCT + CAST ( col2 AS INTEGER ) - + col0 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-5849
SELECT col2 DIV + col1 + + col2 * + cor0.col1 FROM tab2 AS cor0
----
1534
648
837

skipif mysql # not compatible
query I rowsort label-5849
SELECT col2 / + col1 + + col2 * + cor0.col1 FROM tab2 AS cor0
----
1534
648
837

query I rowsort
SELECT 7 + + cor0.col1 FROM tab2 cor0
----
24
38
66

query I rowsort
SELECT DISTINCT 97 + - col0 * - col0 * ( - col0 ) FROM tab2 AS cor0
----
-246
-474455
-492942

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5852
SELECT - CAST( + ( - col2 ) AS SIGNED ) * - 14 AS col2 FROM tab1 AS cor0
----
-1344
-756
-798

skipif mysql # not compatible
query I rowsort label-5852
SELECT - CAST ( + ( - col2 ) AS INTEGER ) * - 14 AS col2 FROM tab1 AS cor0
----
-1344
-756
-798

query I rowsort
SELECT ALL - + 57 * col2 AS col2 FROM tab1 cor0
----
-3078
-3249
-5472

query I rowsort
SELECT ALL + col2 + col2 * + col0 AS col1 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT - 66 * cor0.col2 AS col2 FROM tab0 AS cor0
----
-2178
-5412
-66

query I rowsort
SELECT DISTINCT + - ( col2 ) * cor0.col1 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5857
SELECT ALL CAST( NULL AS SIGNED ) + + col2 * col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5857
SELECT ALL CAST ( NULL AS INTEGER ) + + col2 * col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col1 + 60 FROM tab2 AS cor0
----
1
29
43

query I rowsort
SELECT DISTINCT + - cor0.col1 + col2 * col1 + col1 * + 26 FROM tab2 AS cor0
----
1071
1612
3009

query I rowsort
SELECT - 11 FROM tab1 AS cor0
----
-11
-11
-11

query I rowsort
SELECT DISTINCT ( + col0 ) * col1 AS col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL + + ( - col2 ) + col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5863
SELECT - - 10 + - cor0.col2 DIV - col0 FROM tab0 AS cor0
----
10
10
11

skipif mysql # not compatible
query I rowsort label-5863
SELECT - - 10 + - cor0.col2 / - col0 FROM tab0 AS cor0
----
10
10
11

query I rowsort
SELECT DISTINCT 52 + cor0.col1 * + ( col0 ) * - col0 FROM tab1 AS cor0
----
-182
-40908
-83148

onlyif mysql # use DIV operator for integer division
query I rowsort label-5865
SELECT 86 * + col0 + + 9 DIV col2 col2 FROM tab0 AS cor0
----
2064
3019
7654

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5865
SELECT 86 * + col0 + + 9 / col2 col2 FROM tab0 AS cor0
----
2064
3019
7654

query I rowsort
SELECT + 38 * cor0.col1 + - 7 AS col0 FROM tab2 AS cor0
----
1171
2235
639

query I rowsort
SELECT ALL ( col2 ) + cor0.col1 * + col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT + col1 + col0 - + 90 FROM tab0 cor0
----
20
42
90

query I rowsort
SELECT DISTINCT - col0 * + col0 * + cor0.col0 FROM tab0 cor0
----
-13824
-42875
-704969

onlyif mysql # use DIV operator for integer division
query I rowsort label-5870
SELECT + col0 DIV - col0 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5870
SELECT + col0 / - col0 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col0 * - 67 FROM tab1 AS cor0
----
-201
-4288
-5360

query I rowsort
SELECT ALL 42 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5873
SELECT ALL + + col0 * - CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5873
SELECT ALL + + col0 * - CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + cor0.col1 + 4 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e91eb2fc5d50bb7c86f996f34cd0bf28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * cor0.col0 col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - 74 * - col0 FROM tab0 cor0
----
1776
2590
6586

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 81 + - col2 col2 FROM tab0 AS cor0
----
-1
48
80

query I rowsort
SELECT 25 * - col2 + col0 * col1 AS col1 FROM tab2 cor0
----
-458
393
3952

query I rowsort
SELECT ALL 74 FROM tab1, tab1 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

query I rowsort
SELECT ALL col1 * 15 AS col2 FROM tab0
----
1290
1365
1455

query I rowsort
SELECT ALL + tab1.col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL + - 40 AS col0 FROM tab1 AS cor0
----
-40
-40
-40

onlyif mysql # use DIV operator for integer division
query I rowsort label-5883
SELECT col0 DIV + col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5883
SELECT col0 / + col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 0 * + col0 AS col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT - col1 + + cor0.col2 * 85 AS col2 FROM tab1 AS cor0
----
4564
4835
8147

query I rowsort
SELECT ALL + ( col1 ) * 79 FROM tab1 AS cor0
----
1027
2054
790

query I rowsort
SELECT + 80 FROM tab1 AS cor0
----
80
80
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + col2 col0 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT + cor0.col0 + - col2 * - col0 * col1 AS col1 FROM tab2 AS cor0
----
119730
51113
5866

query I rowsort
SELECT DISTINCT - col1 * - col1 * - ( - col0 * cor0.col2 ) + col0 FROM tab2 AS cor0
----
181636
7059546
867657

query I rowsort
SELECT ALL - + 15 * - col1 AS col0 FROM tab1 AS cor0
----
150
195
390

onlyif mysql # use DIV operator for integer division
query I rowsort label-5892
SELECT ALL + - col0 DIV cor0.col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5892
SELECT ALL + - col0 / cor0.col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5893
SELECT ALL col0 + col1 DIV col1 AS col0 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-5893
SELECT ALL col0 + col1 / col1 AS col0 FROM tab1
----
4
65
81

query I rowsort
SELECT DISTINCT - col2 - - 12 AS col0 FROM tab2 AS cor0
----
-14
-15
-26

query I rowsort
SELECT ALL col0 * col2 * - col1 + + col1 + col1 FROM tab1 AS cor0
----
-36460
-4160
-99814

query I rowsort
SELECT DISTINCT col2 * col0 + - 22 + - col2 AS col2 FROM tab1 cor0
----
3569
7562
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5897
SELECT ALL col2 + + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5897
SELECT ALL col2 + + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * - ( col2 ) AS col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + cor1.col0 AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT DISTINCT - ( + col1 ) - + cor0.col0 * + col2 AS col2 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT DISTINCT + 75 * - col0 AS col0 FROM tab2 AS cor0
----
-525
-5850
-5925

query I rowsort
SELECT + + col0 + + col0 * col0 * 3 + + 20 * col0 AS col2 FROM tab0 AS cor0
----
2232
25632
4410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( 10 ) col0 FROM tab0
----
10
10
10

onlyif mysql # use DIV operator for integer division
query I rowsort label-5904
SELECT CAST( col1 AS SIGNED ) + col0 DIV + 9 FROM tab2
----
25
31
67

skipif mysql # not compatible
query I rowsort label-5904
SELECT CAST ( col1 AS INTEGER ) + col0 / + 9 FROM tab2
----
25
31
67

query I rowsort
SELECT DISTINCT col2 * ( col1 ) FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT + col2 * + 74 FROM tab2 AS cor0
----
1924
1998
2812

query I rowsort
SELECT DISTINCT - cor0.col2 * - col1 AS col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - ( + cor0.col2 ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + + cor0.col1 + 95 FROM tab0 AS cor0
----
181
186
192

query I rowsort
SELECT DISTINCT 62 FROM tab0, tab2 AS cor0, tab2, tab2 AS cor1
----
62

query I rowsort
SELECT DISTINCT 83 AS col0 FROM tab2
----
83

query I rowsort
SELECT - 99 AS col0 FROM tab0 AS cor0
----
-99
-99
-99

query I rowsort
SELECT 87 + 24 * col2 AS col0 FROM tab1 AS cor0
----
1383
1455
2391

query I rowsort
SELECT col2 * col0 + col2 + 49 FROM tab0 AS cor0
----
7429
85
874

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * cor0.col1 col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT ( - 53 ) + col2 * - col2 AS col2 FROM tab1 AS cor0
----
-2969
-3302
-9269

onlyif mysql # use DIV operator for integer division
query I rowsort label-5917
SELECT + col2 * + col0 + col2 + col1 DIV col1 FROM tab0 AS cor0
----
37
7381
826

skipif mysql # not compatible
query I rowsort label-5917
SELECT + col2 * + col0 + col2 + col1 / col1 FROM tab0 AS cor0
----
37
7381
826

query I rowsort
SELECT DISTINCT + cor0.col0 * - 24 + + col2 + 82 FROM tab1 AS cor0
----
-1397
-1742
64

query I rowsort
SELECT DISTINCT 53 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
53

query I rowsort
SELECT - 68 FROM tab1, tab0 AS cor0
----
9 values hashing to 5febf382d36d6e0191889c41b928786f

onlyif mysql # use DIV operator for integer division
query I rowsort label-5921
SELECT + 35 DIV cor0.col0 FROM tab2 AS cor0
----
0
0
5

skipif mysql # not compatible
query I rowsort label-5921
SELECT + 35 / cor0.col0 FROM tab2 AS cor0
----
0
0
5

query I rowsort
SELECT DISTINCT - - cor0.col0 * 15 * - col0 FROM tab0 AS cor0
----
-118815
-18375
-8640

onlyif mysql # use DIV operator for integer division
query I rowsort label-5923
SELECT col0 * ( - col2 ) DIV col0 + - col2 + col0 * - cor0.col2 col0 FROM tab0 AS cor0
----
-37
-7462
-858

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5923
SELECT col0 * ( - col2 ) / col0 + - col2 + col0 * - cor0.col2 col0 FROM tab0 AS cor0
----
-37
-7462
-858

query I rowsort
SELECT DISTINCT + + col2 * ( - cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5925
SELECT DISTINCT col0 DIV ( col0 ) FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-5925
SELECT DISTINCT col0 / ( col0 ) FROM tab2 AS cor0
----
1

query I rowsort
SELECT + cor0.col1 + + col1 * - col2 AS col2 FROM tab0 AS cor0
----
-2752
-7371
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * cor0.col0 + - col0 col1 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT - col2 * ( + col1 ) - col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT ALL - tab1.col1 * - ( + tab1.col0 ) * col1 + 47 * col1 + col1 FROM tab1
----
14144
3276
6880

query I rowsort
SELECT DISTINCT + tab2.col1 + ( col1 + col0 * + 7 ) AS col2 FROM tab2
----
111
587
664

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5931
SELECT col0 + CAST( + 58 AS SIGNED ) FROM tab1
----
122
138
61

skipif mysql # not compatible
query I rowsort label-5931
SELECT col0 + CAST ( + 58 AS INTEGER ) FROM tab1
----
122
138
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5932
SELECT + ( - col2 ) + col0 + + CAST( NULL AS SIGNED ) * - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5932
SELECT + ( - col2 ) + col0 + + CAST ( NULL AS INTEGER ) * - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5933
SELECT - - CAST( NULL AS SIGNED ) + - col2 + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5933
SELECT - - CAST ( NULL AS INTEGER ) + - col2 + col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( 38 ) * col2 + ( + 21 ) + col2 AS col1 FROM tab1 AS cor0
----
2127
2244
3765

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 59 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT ALL col1 * + tab1.col0 - 49 FROM tab1
----
29
591
991

query I rowsort
SELECT - 27 * col1 FROM tab0
----
-2322
-2457
-2619

query I rowsort
SELECT ALL 7 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

query I rowsort
SELECT + 84 * col1 + + col0 FROM tab0 AS cor0
----
7248
7733
8183

query I rowsort
SELECT - - cor0.col0 - col2 AS col1 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-5941
SELECT - col0 + - col0 DIV cor0.col2 AS col1 FROM tab0 AS cor0
----
-24
-70
-90

skipif mysql # not compatible
query I rowsort label-5941
SELECT - col0 + - col0 / cor0.col2 AS col1 FROM tab0 AS cor0
----
-24
-70
-90

query I rowsort
SELECT 65 * tab0.col1 AS col1 FROM tab0
----
5590
5915
6305

query I rowsort
SELECT - + cor0.col0 * ( - col0 ) AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT - + col1 * ( col0 ) + col2 AS col2 FROM tab2 AS cor0
----
-1305
-190
-4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * cor0.col1 col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT col2 * - 60 + 53 + col1 FROM tab0 AS cor0
----
-1841
-4776
90

query I rowsort
SELECT - cor0.col1 * 25 AS col0 FROM tab1 AS cor0
----
-250
-325
-650

query I rowsort
SELECT ALL + 49 AS col2 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

query I rowsort
SELECT DISTINCT col1 * col1 * col1 + - tab1.col2 - col2 * + col0 AS col0 FROM tab1
----
-2705
-5579
17360

query I rowsort
SELECT ALL ( + col1 + - col2 ) FROM tab0
----
53
9
96

query I rowsort
SELECT + cor0.col0 * col0 + + col0 * col1 FROM tab2 AS cor0
----
10686
266
7584

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5952
SELECT + + CAST( + 9 AS SIGNED ) FROM tab0 cor0
----
9
9
9

skipif mysql # not compatible
query I rowsort label-5952
SELECT + + CAST ( + 9 AS INTEGER ) FROM tab0 cor0
----
9
9
9

query I rowsort
SELECT - col1 + + col2 AS col1 FROM tab2 cor0
----
-33
-4
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5954
SELECT CAST( NULL AS SIGNED ) / cor0.col0 + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5954
SELECT CAST ( NULL AS INTEGER ) / cor0.col0 + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT tab1.col1 * + col2 AS col0 FROM tab1
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * 48 col2 FROM tab2
----
1488
2832
816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 70 * col2 col1 FROM tab1
----
3780
3990
6720

query I rowsort
SELECT - + col0 * col1 + col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT ALL + col1 - - col1 AS col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT 49 + col0 AS col0 FROM tab1 cor0
----
113
129
52

query I rowsort
SELECT DISTINCT ( + col2 ) * - col2 + col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT DISTINCT - 23 + 86 FROM tab1
----
63

query I rowsort
SELECT 57 * 76 * col1 + col0 AS col0 FROM tab2
----
134299
255666
73723

query I rowsort
SELECT ALL + col1 + col1 + col0 AS col0 FROM tab2
----
113
196
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 43 col2 FROM tab2
----
-43
-43
-43

query I rowsort
SELECT ALL - 16 * col0 + + col0 FROM tab2 AS cor0
----
-105
-1170
-1185

query I rowsort
SELECT DISTINCT - 63 - cor0.col0 AS col1 FROM tab0 AS cor0
----
-152
-87
-98

query I rowsort
SELECT DISTINCT + cor0.col0 * + col2 * cor0.col1 + col2 FROM tab1 AS cor0
----
36537
4266
99936

onlyif mysql # use DIV operator for integer division
query I rowsort label-5969
SELECT ALL - + cor0.col0 DIV - cor0.col1 FROM tab1 cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-5969
SELECT ALL - + cor0.col0 / - cor0.col1 FROM tab1 cor0
----
0
6
6

query I rowsort
SELECT ALL + - 88 AS col0 FROM tab1 AS cor0
----
-88
-88
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 69 + - col1 * - col1 col0 FROM tab2 AS cor0
----
220
3412
892

query I rowsort
SELECT - col2 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT 22 * col1 AS col2 FROM tab0 AS cor0
----
1892
2002
2134

query I rowsort
SELECT DISTINCT + + 26 * - col2 + - col0 AS col0 FROM tab1 AS cor0
----
-1407
-1546
-2576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + + 84 col0 FROM tab0 AS cor0
----
2
51
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-5976
SELECT col0 DIV - col0 + + tab0.col2 AS col1 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-5976
SELECT col0 / - col0 + + tab0.col2 AS col1 FROM tab0
----
0
32
81

query I rowsort
SELECT - + col0 * 71 + col1 FROM tab1 AS cor0
----
-187
-4534
-5667

query I rowsort
SELECT + - cor0.col2 * col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - - 16 + + col2 FROM tab1 AS cor0
----
112
70
73

query I rowsort
SELECT ALL - + 93 * + col1 AS col1 FROM tab0 AS cor0
----
-7998
-8463
-9021

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 67 + + col2 col2 FROM tab0 AS cor0
----
-34
-66
15

onlyif mysql # use DIV operator for integer division
query I rowsort label-5982
SELECT ALL + 69 DIV - ( + cor0.col0 * + col2 ) AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5982
SELECT ALL + 69 / - ( + cor0.col0 * + col2 ) AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - 38 FROM tab2, tab1 AS cor0
----
9 values hashing to e571541ae40cb0ddaca16e11f4359507

query I rowsort
SELECT ( + col0 ) + col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT + col1 * + 47 AS col0 FROM tab1 AS cor0
----
1222
470
611

query I rowsort
SELECT DISTINCT + - 19 AS col2 FROM tab0 AS cor0
----
-19

query I rowsort
SELECT + - 52 * + ( col2 ) + col0 * col1 FROM tab0 AS cor0
----
3343
348
3835

onlyif mysql # use DIV operator for integer division
query I rowsort label-5988
SELECT DISTINCT - cor0.col2 DIV - col0 AS col0 FROM tab0 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-5988
SELECT DISTINCT - cor0.col2 / - col0 AS col0 FROM tab0 cor0
----
0
1

query I rowsort
SELECT - col1 + - 81 + - col2 FROM tab1 AS cor0
----
-148
-161
-190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 54 col2 FROM tab1 AS cor0
----
54
54
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-5991
SELECT DISTINCT + 20 * + col0 - + cor0.col0 DIV col0 AS col0 FROM tab0 AS cor0
----
1779
479
699

skipif mysql # not compatible
query I rowsort label-5991
SELECT DISTINCT + 20 * + col0 - + cor0.col0 / col0 AS col0 FROM tab0 AS cor0
----
1779
479
699

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + 16 col0 FROM tab2 AS cor0
----
272
496
944

query I rowsort
SELECT DISTINCT + - col2 + - col1 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT + cor0.col1 * 37 - col0 * + col2 FROM tab0 AS cor0
----
-3931
2390
3554

query I rowsort
SELECT DISTINCT col2 * + 99 + + 72 FROM tab2 AS cor0
----
2646
2745
3834

query I rowsort
SELECT DISTINCT col0 * 63 + + 90 + - col1 AS col1 FROM tab0 cor0
----
1516
2198
5606

query I rowsort
SELECT + col2 * + ( col0 ) FROM tab0 cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5998
SELECT col1 DIV - ( col1 + - col0 ) AS col0 FROM tab0 AS cor0
----
-1
-1
-45

skipif mysql # not compatible
query I rowsort label-5998
SELECT col1 / - ( col1 + - col0 ) AS col0 FROM tab0 AS cor0
----
-1
-1
-45

query I rowsort
SELECT DISTINCT + col1 * col2 + + col0 AS col2 FROM tab2 AS cor0
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 * + col0 col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - col0 * - 0 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 38 + - col0 col0 FROM tab2 AS cor0
----
1171
2164
567

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col1 ) col2 FROM tab0
----
86
91
97

query I rowsort
SELECT col2 * tab2.col1 - col2 AS col0 FROM tab2
----
1508
608
810

query I rowsort
SELECT ALL 6 + col0 AS col0 FROM tab1
----
70
86
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col2 ) + tab0.col0 * + 83 col1 FROM tab0
----
2025
2906
7469

query I rowsort
SELECT ALL - col1 - 16 * - 86 AS col0 FROM tab0 AS cor0
----
1279
1285
1290

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6008
SELECT ALL - col2 * CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6008
SELECT ALL - col2 * CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col1 * + ( col2 + + cor0.col1 ) * col0 AS col0 FROM tab2 AS cor0
----
12586
391170
73865

query I rowsort
SELECT ALL - ( + tab0.col2 ) FROM tab0, tab1 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT + - col1 + 1 * cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col2 + 31 AS col1 FROM tab0
----
113
32
64

query I rowsort
SELECT + col0 + + col2 * col2 FROM tab1
----
2919
3313
9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-6014
SELECT + col1 DIV + col0 + - col0 FROM tab2 AS cor0
----
-3
-78
-79

skipif mysql # not compatible
query I rowsort label-6014
SELECT + col1 / + col0 + - col0 FROM tab2 AS cor0
----
-3
-78
-79

query I rowsort
SELECT ALL - col2 - col2 * + col1 AS col2 FROM tab1
----
-1344
-1458
-627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col1 ) * ( col1 ) - col1 col1 FROM tab0 AS cor0
----
-7482
-8372
-9506

query I rowsort
SELECT + cor0.col2 * + col0 + - 84 FROM tab1 AS cor0
----
3564
7596
78

query I rowsort
SELECT ALL + - col0 + - cor0.col0 FROM tab2 AS cor0
----
-14
-156
-158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col1 ) col2 FROM tab0
----
86
91
97

query I rowsort
SELECT ALL - 67 AS col0 FROM tab2
----
-67
-67
-67

query I rowsort
SELECT DISTINCT - 42 * - col0 + + 15 FROM tab1
----
141
2703
3375

query I rowsort
SELECT - 4 + cor0.col2 FROM tab0 AS cor0
----
-3
29
78

query I rowsort
SELECT DISTINCT + + col0 * col0 + + 73 FROM tab2 AS cor0
----
122
6157
6314

onlyif mysql # use DIV operator for integer division
query I rowsort label-6024
SELECT ALL + col2 * - col2 + + col2 * - col1 DIV col1 AS col2 FROM tab2 AS cor0
----
-1482
-702
-756

skipif mysql # not compatible
query I rowsort label-6024
SELECT ALL + col2 * - col2 + + col2 * - col1 / col1 AS col2 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT col2 * col0 + + 25 * col0 FROM tab2 AS cor0
----
364
3978
4977

query I rowsort
SELECT + 98 AS col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c758e8afbdfa6aae279045b0e9cbacc2

query I rowsort
SELECT DISTINCT col2 * col2 + - 31 FROM tab0
----
-30
1058
6693

query I rowsort
SELECT DISTINCT tab2.col0 * + tab2.col2 FROM tab2, tab0 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + - col0 * - col0 + col0 AS col1 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT + cor0.col0 FROM tab2, tab2 AS cor0, tab1, tab0 AS cor1
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

onlyif mysql # use DIV operator for integer division
query I rowsort label-6031
SELECT + col1 * 78 + - col2 * col2 DIV CAST( + 38 AS SIGNED ) AS col0 FROM tab2 cor0
----
1288
2399
4585

skipif mysql # not compatible
query I rowsort label-6031
SELECT + col1 * 78 + - col2 * col2 / CAST ( + 38 AS INTEGER ) AS col0 FROM tab2 cor0
----
1288
2399
4585

query I rowsort
SELECT + + cor0.col0 + col2 AS col1 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6033
SELECT - + col2 DIV 55 + col1 AS col2 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-6033
SELECT - + col2 / 55 + col1 AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT col1 * - 91 FROM tab1 AS cor0
----
-1183
-2366
-910

query I rowsort
SELECT + col1 + cor0.col2 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL ( + 44 + - col1 ) * - ( tab2.col0 ) FROM tab2
----
-2133
-91
1170

query I rowsort
SELECT ALL col2 * - cor0.col2 FROM tab2 AS cor0
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 58 col0 FROM tab2, tab2 AS cor0
----
58

query I rowsort
SELECT 46 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( + col1 ) col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + col2 * col1 - - ( col1 * col2 ) AS col2 FROM tab1 AS cor0
----
1140
2496
2808

query I rowsort
SELECT + + col2 + + col2 - ( cor0.col2 ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT 12 AS col0 FROM tab1 AS cor0
----
12

query I rowsort
SELECT 12 * cor0.col1 FROM tab0 AS cor0
----
1032
1092
1164

query I rowsort
SELECT - - ( col0 ) * - col0 + 25 AS col1 FROM tab0 AS cor0
----
-1200
-551
-7896

query I rowsort
SELECT DISTINCT - - 6 * col2 FROM tab2 AS cor0
----
156
162
228

onlyif mysql # use DIV operator for integer division
query I rowsort label-6047
SELECT tab1.col0 DIV col2 AS col2 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6047
SELECT tab1.col0 / col2 AS col2 FROM tab1
----
0
0
1

query I rowsort
SELECT DISTINCT + col2 + - col2 * col2 AS col2 FROM tab2
----
-1406
-650
-702

query I rowsort
SELECT ALL - col0 * col0 + col1 FROM tab0
----
-1128
-490
-7830

query I rowsort
SELECT + 92 * cor0.col2 + 56 - - cor0.col1 * col1 * col2 FROM tab0 AS cor0
----
247160
686642
9557

query I rowsort
SELECT - + col1 * + col1 + col2 * col1 FROM tab1 AS cor0
----
1079
470
728

onlyif mysql # use DIV operator for integer division
query I rowsort label-6052
SELECT DISTINCT - ( 24 ) * col1 + col2 DIV - col1 + col2 AS col0 FROM tab2
----
-1390
-372
-717

skipif mysql # not compatible
query I rowsort label-6052
SELECT DISTINCT - ( 24 ) * col1 + col2 / - col1 + col2 AS col0 FROM tab2
----
-1390
-372
-717

query I rowsort
SELECT + 74 * 31 FROM tab1
----
2294
2294
2294

query I rowsort
SELECT col0 * - 15 FROM tab2 AS cor0
----
-105
-1170
-1185

query I rowsort
SELECT - col1 * col2 + - col0 * + col0 FROM tab1 AS cor0
----
-1413
-4666
-7648

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6056
SELECT DISTINCT CAST( NULL AS SIGNED ) * col0 / col1 AS col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-6056
SELECT DISTINCT CAST ( NULL AS INTEGER ) * col0 / col1 AS col1 FROM tab0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6057
SELECT cor0.col1 + + col0 * - CAST( NULL AS SIGNED ) * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6057
SELECT cor0.col1 + + col0 * - CAST ( NULL AS INTEGER ) * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor0.col0 - cor0.col0 FROM tab1, tab2, tab2 AS cor0
----
0

query I rowsort
SELECT - col0 - col2 * + col0 FROM tab1
----
-165
-3712
-7760

query I rowsort
SELECT ALL - 74 * + col1 FROM tab2 cor0
----
-1258
-2294
-4366

query I rowsort
SELECT DISTINCT - - 83 AS col2 FROM tab2 cor0
----
83

query I rowsort
SELECT DISTINCT + 67 * + col1 FROM tab2 AS cor0
----
1139
2077
3953

onlyif mysql # use DIV operator for integer division
query I rowsort label-6063
SELECT ALL col0 DIV col1 FROM tab2 cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-6063
SELECT ALL col0 / col1 FROM tab2 cor0
----
0
1
4

query I rowsort
SELECT + 67 * col2 AS col0 FROM tab2 AS cor0
----
1742
1809
2546

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6065
SELECT DISTINCT col1 + CAST( col0 AS SIGNED ) * + tab0.col0 col1 FROM tab0
----
1322
662
8012

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6065
SELECT DISTINCT col1 + CAST ( col0 AS INTEGER ) * + tab0.col0 col1 FROM tab0
----
1322
662
8012

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6066
SELECT col0 + - CAST( col2 + + col2 AS SIGNED ) AS col1 FROM tab1
----
-105
-112
-50

skipif mysql # not compatible
query I rowsort label-6066
SELECT col0 + - CAST ( col2 + + col2 AS INTEGER ) AS col1 FROM tab1
----
-105
-112
-50

query I rowsort
SELECT - cor0.col2 AS col1 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT + + col2 * col0 + col0 AS col1 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT - col2 + + 56 AS col1 FROM tab1 AS cor0
----
-1
-40
2

query I rowsort
SELECT col2 * + 37 + + col2 AS col0 FROM tab1 AS cor0
----
2052
2166
3648

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6072
SELECT - col2 * + CAST( col1 AS SIGNED ) * - col0 - + 73 AS col1 FROM tab2 AS cor0
----
119579
50961
5786

skipif mysql # not compatible
query I rowsort label-6072
SELECT - col2 * + CAST ( col1 AS INTEGER ) * - col0 - + 73 AS col1 FROM tab2 AS cor0
----
119579
50961
5786

query I rowsort
SELECT - col0 * - ( - col0 ) * - col2 + - col0 + col2 AS col0 FROM tab2 AS cor0
----
1343
158132
237117

query I rowsort
SELECT - - col2 + - col0 * - 20 FROM tab1 AS cor0
----
114
1337
1696

query I rowsort
SELECT ALL + - 24 * + col2 AS col2 FROM tab1 AS cor0
----
-1296
-1368
-2304

onlyif mysql # use DIV operator for integer division
query I rowsort label-6076
SELECT + 53 + col0 DIV + col1 AS col1 FROM tab1 AS cor0
----
53
59
59

skipif mysql # not compatible
query I rowsort label-6076
SELECT + 53 + col0 / + col1 AS col1 FROM tab1 AS cor0
----
53
59
59

query I rowsort
SELECT + 47 AS col1 FROM tab0 AS cor0
----
47
47
47

query I rowsort
SELECT col1 * - 95 * 97 FROM tab2
----
-156655
-285665
-543685

query I rowsort
SELECT ALL - tab2.col2 * 48 FROM tab2
----
-1248
-1296
-1824

query I rowsort
SELECT DISTINCT 38 FROM tab1, tab1 cor0, tab2 AS cor1
----
38

query I rowsort
SELECT ALL - col0 * + 92 FROM tab1
----
-276
-5888
-7360

onlyif mysql # use DIV operator for integer division
query I rowsort label-6082
SELECT DISTINCT col2 DIV + 65 AS col0 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-6082
SELECT DISTINCT col2 / + 65 AS col0 FROM tab2
----
0

query I rowsort
SELECT ALL + 35 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * col2 col2 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL - col2 * - 24 + col1 + 69 * - col1 * cor0.col1 FROM tab0 AS cor0
----
-509446
-569330
-649100

query I rowsort
SELECT DISTINCT + + col0 * 95 FROM tab1 AS cor0
----
285
6080
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 25 + - col2 col1 FROM tab1 AS cor0
----
-29
-32
-71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6088
SELECT - - CAST( 78 AS SIGNED ) + - col1 * - ( 68 ) col2 FROM tab0 AS cor0
----
5926
6266
6674

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6088
SELECT - - CAST ( 78 AS INTEGER ) + - col1 * - ( 68 ) col2 FROM tab0 AS cor0
----
5926
6266
6674

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * - col0 + - col2 col2 FROM tab0 AS cor0
----
-36
-7380
-825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col1 ) col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - 34 * - 84 + + col2 + col2 FROM tab0 AS cor0
----
2858
2922
3020

query I rowsort
SELECT - ( + col0 ) * col1 + - col1 FROM tab1 cor0
----
-104
-1053
-650

query I rowsort
SELECT DISTINCT cor0.col1 + cor0.col2 + col2 AS col2 FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT ALL tab2.col0 + col0 - - col0 * - col1 AS col2 FROM tab2
----
-1185
-203
-4446

query I rowsort
SELECT ALL + col1 + ( col0 ) * col0 + - col0 * col1 AS col1 FROM tab1 AS cor0
----
-43
3466
5373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col0 col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - - col0 * + 66 + col1 FROM tab1 AS cor0
----
224
4234
5293

query I rowsort
SELECT ALL col1 + - cor0.col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 11 + col1 col2 FROM tab0 cor0
----
102
108
97

query I rowsort
SELECT DISTINCT 17 + - ( col1 ) FROM tab2 cor0
----
-14
-42
0

query I rowsort
SELECT DISTINCT + - col0 * + col2 + col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL col0 + + col1 + - col1 AS col1 FROM tab0
----
24
35
89

query I rowsort
SELECT ALL - tab1.col1 + - col1 * + col2 FROM tab1
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT + cor0.col1 + - col0 * ( col0 ) AS col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT col1 + col2 * + ( 96 ) AS col2 FROM tab1 AS cor0
----
5210
5482
9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-6106
SELECT DISTINCT - col0 DIV + cor0.col2 AS col0 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-6106
SELECT DISTINCT - col0 / + cor0.col2 AS col0 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT DISTINCT + - col2 * col2 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL col0 * - 26 + col0 AS col2 FROM tab1
----
-1600
-2000
-75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6109
SELECT CAST( NULL AS DECIMAL ) AS col1 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6109
SELECT CAST ( NULL AS REAL ) AS col1 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6110
SELECT - CAST( NULL AS SIGNED ) + + 76 / col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6110
SELECT - CAST ( NULL AS INTEGER ) + + 76 / col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6111
SELECT + col1 * + col0 DIV col0 + col0 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-6111
SELECT + col1 * + col0 / col0 + col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL - col2 + col2 * col2 FROM tab1 AS cor0
----
2862
3192
9120

query I rowsort
SELECT DISTINCT - col2 * ( 90 ) + + cor0.col2 + col1 * - ( + cor0.col0 * + ( 28 ) ) AS col2 FROM tab0 AS cor0
----
-234070
-60729
-95149

onlyif mysql # use DIV operator for integer division
query I rowsort label-6114
SELECT ALL + + col0 DIV 78 - ( col0 ) col0 FROM tab0 cor0
----
-24
-35
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6114
SELECT ALL + + col0 / 78 - ( col0 ) col0 FROM tab0 cor0
----
-24
-35
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 - col0 * col2 col1 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT DISTINCT + - col1 + cor0.col1 * col1 FROM tab1 AS cor0
----
156
650
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6117
SELECT - col2 + CAST( ( col1 ) AS SIGNED ) * 40 AS col2 FROM tab0 AS cor0
----
3407
3558
3879

skipif mysql # not compatible
query I rowsort label-6117
SELECT - col2 + CAST ( ( col1 ) AS INTEGER ) * 40 AS col2 FROM tab0 AS cor0
----
3407
3558
3879

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6118
SELECT ALL + + cor0.col0 * CAST( NULL AS SIGNED ) * - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6118
SELECT ALL + + cor0.col0 * CAST ( NULL AS INTEGER ) * - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 + + col1 * - col1 AS col2 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT - cor0.col1 * col2 + 10 * col2 AS col2 FROM tab1 AS cor0
----
-288
-864
0

query I rowsort
SELECT - - col2 * col2 - col0 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT ALL + ( col2 + col1 * col0 ) AS col1 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT 96 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to f1d978c2d5bfc6f26e0907ac777be83e

query I rowsort
SELECT ALL tab0.col1 + + 49 FROM tab0
----
135
140
146

query I rowsort
SELECT - 91 AS col2 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 745d1c3a09d935465cad552325c5c945

onlyif mysql # use DIV operator for integer division
query I rowsort label-6126
SELECT ALL col2 + - col0 DIV + 49 FROM tab1
----
54
56
95

skipif mysql # not compatible
query I rowsort label-6126
SELECT ALL col2 + - col0 / + 49 FROM tab1
----
54
56
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-6127
SELECT DISTINCT - - cor0.col2 * + 93 - col1 DIV col2 col0 FROM tab0 AS cor0
----
-4
3067
7625

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6127
SELECT DISTINCT - - cor0.col2 * + 93 - col1 / col2 col0 FROM tab0 AS cor0
----
-4
3067
7625

query I rowsort
SELECT - cor0.col1 * + 1 + 10 AS col1 FROM tab2 AS cor0
----
-21
-49
-7

query I rowsort
SELECT DISTINCT + - col2 + - ( col0 ) * col2 * + col2 FROM tab0 AS cor0
----
-26169
-36
-598518

query I rowsort
SELECT DISTINCT - + col1 + + 6 FROM tab0 AS cor0
----
-80
-85
-91

query I rowsort
SELECT + col2 * + col1 - col1 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-6132
SELECT ALL - cor0.col1 DIV cor0.col1 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

skipif mysql # not compatible
query I rowsort label-6132
SELECT ALL - cor0.col1 / cor0.col1 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * tab2.col1 col2 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT - 56 + col2 AS col2 FROM tab2 AS cor0
----
-18
-29
-30

query I rowsort
SELECT col1 + cor0.col1 * - ( + cor0.col2 ) * - col2 FROM tab1 AS cor0
----
119821
32500
75842

onlyif mysql # use DIV operator for integer division
query I rowsort label-6136
SELECT DISTINCT + - col0 + col0 * - ( + col1 ) * col0 + + col0 DIV cor0.col0 col0 FROM tab2 AS cor0
----
-106175
-1525
-359033

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6136
SELECT DISTINCT + - col0 + col0 * - ( + col1 ) * col0 + + col0 / cor0.col0 col0 FROM tab2 AS cor0
----
-106175
-1525
-359033

query I rowsort
SELECT cor0.col2 * cor0.col2 + - cor0.col0 FROM tab2 AS cor0
----
1365
598
722

onlyif mysql # use DIV operator for integer division
query I rowsort label-6138
SELECT ALL + - 87 + col0 DIV + 77 FROM tab1 AS cor0
----
-86
-87
-87

skipif mysql # not compatible
query I rowsort label-6138
SELECT ALL + - 87 + col0 / + 77 FROM tab1 AS cor0
----
-86
-87
-87

query I rowsort
SELECT + - col0 * + col0 + + col1 * - col0 FROM tab1 cor0
----
-4736
-7440
-87

query I rowsort
SELECT - - cor0.col1 * + col1 + - col0 + col0 * + ( col1 ) * col1 FROM tab2 AS cor0
----
23041
274921
7681

onlyif mysql # use DIV operator for integer division
query I rowsort label-6141
SELECT DISTINCT + col0 * - ( col2 ) + - cor0.col2 DIV - col1 FROM tab2 AS cor0
----
-189
-2028
-3000

skipif mysql # not compatible
query I rowsort label-6141
SELECT DISTINCT + col0 * - ( col2 ) + - cor0.col2 / - col1 FROM tab2 AS cor0
----
-189
-2028
-3000

query I rowsort
SELECT col2 + + 91 * col0 FROM tab2 cor0
----
664
7124
7227

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - - col1 + + CAST ( + col2 AS REAL ) AS col1 FROM tab2 AS cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + ( col2 * col0 ) col0 FROM tab2 AS cor0
----
1323
158184
237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-6145
SELECT DISTINCT col1 DIV - col2 + - tab0.col2 AS col1 FROM tab0
----
-35
-83
-98

skipif mysql # not compatible
query I rowsort label-6145
SELECT DISTINCT col1 / - col2 + - tab0.col2 AS col1 FROM tab0
----
-35
-83
-98

query I rowsort
SELECT + - col2 + col1 * + 17 AS col1 FROM tab2 AS cor0
----
251
500
977

query I rowsort
SELECT + + col1 * col0 AS col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT + col1 * col1 + col0 * + col0 + 68 FROM tab1 AS cor0
----
4264
6637
753

query I rowsort
SELECT + 43 FROM tab1 cor0
----
43
43
43

query I rowsort
SELECT + col0 + col1 * - cor0.col2 - + 1 AS col0 FROM tab1 AS cor0
----
-1169
-1402
-507

onlyif mysql # use DIV operator for integer division
query I rowsort label-6151
SELECT CAST( + col1 AS SIGNED ) DIV col0 AS col1 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-6151
SELECT CAST ( + col1 AS INTEGER ) / col0 AS col1 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT DISTINCT ( + 72 ) + - col0 AS col1 FROM tab1 AS cor0
----
-8
69
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-6153
SELECT ALL + + col0 DIV col1 FROM tab2 cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-6153
SELECT ALL + + col0 / col1 FROM tab2 cor0
----
0
1
4

query I rowsort
SELECT + - cor0.col0 * col2 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT col1 + ( cor0.col1 ) * - col2 + + ( col0 ) AS col2 FROM tab0 AS cor0
----
-2728
-7282
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - cor0.col1 ) col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL 26 * - col1 AS col1 FROM tab1 AS cor0
----
-260
-338
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-6158
SELECT - col0 + col0 DIV col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-6158
SELECT - col0 + col0 / col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT cor0.col2 * + col2 + - col1 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT ALL 7 + col2 FROM tab2 cor0
----
33
34
45

query I rowsort
SELECT DISTINCT - ( ( - col2 ) ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + - ( col0 ) * col2 + + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT 70 AS col1 FROM tab2 AS cor0
----
70
70
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-6164
SELECT ALL + 14 DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6164
SELECT ALL + 14 / col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 6 FROM tab2, tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
-6

query I rowsort
SELECT + col2 + + col2 * 52 FROM tab2 AS cor0
----
1378
1431
2014

query I rowsort
SELECT - - col0 + col2 AS col2 FROM tab1 AS cor0
----
121
176
57

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0, tab0, tab2 AS cor1
----
972 values hashing to d41be7437523f0dba2158c7f0439f329

query I rowsort
SELECT DISTINCT col1 + + tab0.col0 * - col2 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT ALL tab2.col2 AS col1 FROM tab0, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT - col1 + col0 * col2 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT + col1 - - cor0.col0 AS col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + - 30 + - col0 AS col0 FROM tab0 AS cor0
----
-119
-54
-65

query I rowsort
SELECT 88 AS col1 FROM tab1 AS cor0
----
88
88
88

query I rowsort
SELECT DISTINCT + 91 * tab2.col0 FROM tab2, tab1, tab2 AS cor0
----
637
7098
7189

onlyif mysql # use DIV operator for integer division
query I rowsort label-6176
SELECT - - col2 + col0 + + ( + col0 ) * - col0 DIV col0 col0 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6176
SELECT - - col2 + col0 + + ( + col0 ) * - col0 / col0 col0 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6177
SELECT ALL + cor0.col0 * - CAST( NULL AS DECIMAL ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6177
SELECT ALL + cor0.col0 * - CAST ( NULL AS REAL ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col2 col0 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL - 25 AS col2 FROM tab1
----
-25
-25
-25

query I rowsort
SELECT col2 * col0 * col0 FROM tab1
----
233472
486
614400

query I rowsort
SELECT - + col2 + + 34 * col1 FROM tab0 AS cor0
----
2891
3012
3297

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 5 * + col1 col1 FROM tab0 AS cor0
----
-430
-455
-485

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6183
SELECT - ( ( - col0 ) + CAST( col1 AS SIGNED ) ) FROM tab1
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-6183
SELECT - ( ( - col0 ) + CAST ( col1 AS INTEGER ) ) FROM tab1
----
-23
54
67

query I rowsort
SELECT DISTINCT + ( tab0.col0 * col0 ) AS col1 FROM tab0
----
1225
576
7921

query I rowsort
SELECT ALL cor1.col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT ALL - col1 * + cor0.col2 + + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL - + col2 - 47 AS col0 FROM tab2 AS cor0
----
-73
-74
-85

query I rowsort
SELECT ALL cor1.col1 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT - cor0.col1 * cor0.col1 + - col0 AS col2 FROM tab2 AS cor0
----
-3559
-368
-968

query I rowsort
SELECT ALL - tab2.col2 * 90 FROM tab2
----
-2340
-2430
-3420

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col2 ) * tab0.col2 col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - 78 FROM tab2, tab1, tab2 AS cor0
----
-78

query I rowsort
SELECT ALL - col2 * tab1.col0 * col1 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT + 14 AS col0 FROM tab1 cor0
----
14
14
14

query I rowsort
SELECT - - ( - col0 ) + col0 AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6196
SELECT ALL CAST( 15 AS SIGNED ) + col2 * col0 * + 90 - + col0 AS col1 FROM tab1
----
14592
328271
691135

skipif mysql # not compatible
query I rowsort label-6196
SELECT ALL CAST ( 15 AS INTEGER ) + col2 * col0 * + 90 - + col0 AS col1 FROM tab1
----
14592
328271
691135

query I rowsort
SELECT + + cor0.col0 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT col0 * col1 * + col1 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT col1 * + col0 - - ( - col0 ) FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT - cor0.col2 * col1 * - 48 + col2 AS col1 FROM tab0 AS cor0
----
136257
358258
4657

onlyif mysql # use DIV operator for integer division
query I rowsort label-6201
SELECT + - col2 DIV + col2 + - 14 FROM tab0 AS cor0
----
-15
-15
-15

skipif mysql # not compatible
query I rowsort label-6201
SELECT + - col2 / + col2 + - 14 FROM tab0 AS cor0
----
-15
-15
-15

onlyif mysql # use DIV operator for integer division
query I rowsort label-6202
SELECT + col2 DIV - col2 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6202
SELECT + col2 / - col2 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6203
SELECT - col2 DIV col1 + + ( + col0 ) FROM tab0 cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6203
SELECT - col2 / col1 + + ( + col0 ) FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + - 88 * + col2 AS col2 FROM tab2 AS cor0
----
-2288
-2376
-3344

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6205
SELECT DISTINCT col0 * col0 + CAST( 58 AS SIGNED ) * col2 FROM tab2 AS cor0
----
1615
7592
8445

skipif mysql # not compatible
query I rowsort label-6205
SELECT DISTINCT col0 * col0 + CAST ( 58 AS INTEGER ) * col2 FROM tab2 AS cor0
----
1615
7592
8445

query I rowsort
SELECT ALL - col1 * col1 - cor0.col0 AS col1 FROM tab2 AS cor0
----
-3559
-368
-968

query I rowsort
SELECT ALL ( + 42 ) AS col0 FROM tab2
----
42
42
42

query I rowsort
SELECT col0 * + col1 + + 18 FROM tab2 AS cor0
----
1361
235
4620

onlyif mysql # use DIV operator for integer division
query I rowsort label-6209
SELECT ALL - - col2 DIV col2 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6209
SELECT ALL - - col2 / col2 AS col0 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6210
SELECT DISTINCT col2 DIV col0 + + ( + 12 ) * + col2 * + col1 AS col0 FROM tab0
----
1164
34057
89544

skipif mysql # not compatible
query I rowsort label-6210
SELECT DISTINCT col2 / col0 + + ( + 12 ) * + col2 * + col1 AS col0 FROM tab0
----
1164
34057
89544

query I rowsort
SELECT ALL + 60 * + col1 + col0 + 80 FROM tab1
----
1643
744
940

query I rowsort
SELECT DISTINCT cor0.col2 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
54
57
96

query I rowsort
SELECT ALL cor0.col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT - col0 * tab1.col1 + - 2 - col1 AS col2 FROM tab1
----
-1055
-106
-652

onlyif mysql # use DIV operator for integer division
query I rowsort label-6215
SELECT + col0 DIV - col0 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6215
SELECT + col0 / - col0 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + col1 + - col2 * + col2 AS col0 FROM tab2
----
-1427
-617
-698

query I rowsort
SELECT 81 + + col1 FROM tab0 cor0
----
167
172
178

query I rowsort
SELECT ALL + 34 * + col2 AS col2 FROM tab0 AS cor0
----
1122
2788
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6219
SELECT + + col1 + col1 * CAST( NULL AS SIGNED ) * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6219
SELECT + + col1 + col1 * CAST ( NULL AS INTEGER ) * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + + col1 AS col0 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT - + cor0.col1 + + 81 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1040
2080
800

query I rowsort
SELECT ALL + col2 * 19 FROM tab2 AS cor0
----
494
513
722

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6223
SELECT + + cor0.col0 * - CAST( col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-6223
SELECT + + cor0.col0 * - CAST ( col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT + cor0.col0 + 29 FROM tab0 AS cor0
----
118
53
64

query I rowsort
SELECT - col2 + 14 FROM tab2 AS cor0
----
-12
-13
-24

query I rowsort
SELECT - + col1 + + 97 * + col2 FROM tab1 AS cor0
----
5212
5519
9299

query I rowsort
SELECT - + col1 + 89 * col0 + - col1 AS col0 FROM tab2 cor0
----
561
6824
6997

onlyif mysql # use DIV operator for integer division
query I rowsort label-6228
SELECT ALL - + col0 DIV 28 AS col2 FROM tab2 AS cor0
----
-2
-2
0

skipif mysql # not compatible
query I rowsort label-6228
SELECT ALL - + col0 / 28 AS col2 FROM tab2 AS cor0
----
-2
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * cor0.col2 col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT 60 * col0 + col2 FROM tab2
----
447
4706
4778

query I rowsort
SELECT DISTINCT col1 + + col0 AS col2 FROM tab2
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6232
SELECT ALL - + col1 / + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6232
SELECT ALL - + col1 / + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + 80 * + ( - col1 + + 42 * col2 ) AS col0 FROM tab1 AS cor0
----
179363
190784
321600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 6 + col0 - - col2 * 98 col1 FROM tab2
----
2620
2647
3797

query I rowsort
SELECT ALL ( tab2.col0 ) * col1 * + col0 - col0 AS col0 FROM tab2
----
106018
1512
358878

query I rowsort
SELECT ALL + - ( - 20 ) * col2 FROM tab0 AS cor0
----
1640
20
660

onlyif mysql # use DIV operator for integer division
query I rowsort label-6237
SELECT ALL + 37 * + ( col2 ) + col0 DIV 16 + col2 DIV 5 AS col0 FROM tab0 cor0
----
1228
3055
39

skipif mysql # not compatible
query I rowsort label-6237
SELECT ALL + 37 * + ( col2 ) + col0 / 16 + col2 / 5 AS col0 FROM tab0 cor0
----
1228
3055
39

query I rowsort
SELECT + + ( cor0.col1 ) AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - + col0 + 90 * + col0 FROM tab0 AS cor0
----
2136
3115
7921

query I rowsort
SELECT ALL - - 75 FROM tab0 cor0
----
75
75
75

query I rowsort
SELECT + - 37 * + cor0.col0 FROM tab0 AS cor0
----
-1295
-3293
-888

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6242
SELECT ALL + CAST( NULL AS DECIMAL ) AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6242
SELECT ALL + CAST ( NULL AS REAL ) AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL + ( 26 ) FROM tab2, tab1 AS cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT DISTINCT ( + 62 + - tab0.col1 ) FROM tab0, tab1 AS cor0
----
-24
-29
-35

query I rowsort
SELECT DISTINCT col2 * - 40 * + col0 + + col1 FROM tab2 AS cor0
----
-120063
-7529
-81061

onlyif mysql # use DIV operator for integer division
query I rowsort label-6246
SELECT ALL col0 * + cor0.col2 * col0 - - col0 DIV col0 FROM tab0 AS cor0
----
1226
19009
649523

skipif mysql # not compatible
query I rowsort label-6246
SELECT ALL col0 * + cor0.col2 * col0 - - col0 / col0 FROM tab0 AS cor0
----
1226
19009
649523

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6247
SELECT + + CAST( + col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-6247
SELECT + + CAST ( + col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL - 8 FROM tab0 cor0
----
-8
-8
-8

query I rowsort
SELECT DISTINCT col0 + + cor0.col1 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT + 13 AS col2 FROM tab2 AS cor0
----
13

query I rowsort
SELECT DISTINCT + + col0 + - ( - col0 ) AS col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT + - 12 AS col2 FROM tab0 AS cor0
----
-12
-12
-12

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0 CROSS JOIN tab1, tab0, tab0 AS cor1
----
3645 values hashing to 78077727601c056ad0d4f4c11c8daffb

query I rowsort
SELECT DISTINCT 25 * - col2 AS col1 FROM tab1
----
-1350
-1425
-2400

query I rowsort
SELECT - col0 - col1 AS col2 FROM tab1
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6256
SELECT ALL CAST( 2 AS SIGNED ) * col0 DIV col2 FROM tab0
----
1
2
70

skipif mysql # not compatible
query I rowsort label-6256
SELECT ALL CAST ( 2 AS INTEGER ) * col0 / col2 FROM tab0
----
1
2
70

query I rowsort
SELECT cor0.col1 * 78 FROM tab2, tab1 AS cor0, tab2 cor1
----
27 values hashing to 03fa4ecfc5dd69ed0190c273be4f94e8

onlyif mysql # use DIV operator for integer division
query I rowsort label-6258
SELECT + col2 + - col0 DIV col1 AS col1 FROM tab1
----
51
54
90

skipif mysql # not compatible
query I rowsort label-6258
SELECT + col2 + - col0 / col1 AS col1 FROM tab1
----
51
54
90

query I rowsort
SELECT DISTINCT + col2 + - tab2.col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT + + ( + 65 ) * col0 AS col1 FROM tab2 AS cor0
----
455
5070
5135

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col1 + + col1 col1 FROM tab0
----
172
182
194

query I rowsort
SELECT + - col2 * col2 + + col0 * col2 FROM tab2 AS cor0
----
-540
1352
1558

query I rowsort
SELECT ALL + col1 + + col1 AS col2 FROM tab2
----
118
34
62

query I rowsort
SELECT col0 + col0 * 41 + tab0.col2 * - col2 FROM tab0
----
-2986
-81
1469

onlyif mysql # use DIV operator for integer division
query I rowsort label-6265
SELECT col2 * 97 DIV col0 AS col0 FROM tab2
----
32
374
46

skipif mysql # not compatible
query I rowsort label-6265
SELECT col2 * 97 / col0 AS col0 FROM tab2
----
32
374
46

query I rowsort
SELECT + col1 * cor0.col1 + + col0 FROM tab2 cor0
----
3559
368
968

query I rowsort
SELECT ALL + ( - 28 ) AS col1 FROM tab0 AS cor0
----
-28
-28
-28

query I rowsort
SELECT DISTINCT + 63 * - col2 + col1 * + col0 FROM tab1 AS cor0
----
-2951
-3324
-5008

query I rowsort
SELECT + ( + 84 ) FROM tab0 AS cor0
----
84
84
84

query I rowsort
SELECT ALL - cor0.col1 * + 41 FROM tab2 AS cor0
----
-1271
-2419
-697

query I rowsort
SELECT - + 26 + - col0 FROM tab0 AS cor0
----
-115
-50
-61

query I rowsort
SELECT ALL + + col0 * col0 + cor0.col1 * + ( - col0 ) - col1 * col1 AS col0 FROM tab0 AS cor0
----
-11579
-8459
-8884

query I rowsort
SELECT + 38 + 66 FROM tab2 AS cor0
----
104
104
104

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col1 col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col1 * + col2 + + col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT - col1 * - col2 AS col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT + - col0 + - col1 * + col1 FROM tab2 AS cor0
----
-3559
-368
-968

query I rowsort
SELECT DISTINCT - col0 * col0 + col2 * col2 FROM tab1 AS cor0
----
-847
2816
2907

query I rowsort
SELECT - 90 * - col1 AS col1 FROM tab1 AS cor0
----
1170
2340
900

query I rowsort
SELECT ALL 56 AS col2 FROM tab2 cor0
----
56
56
56

query I rowsort
SELECT ALL 91 AS col1 FROM tab1 AS cor0
----
91
91
91

query I rowsort
SELECT + 74 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
3996
4218
7104

onlyif mysql # use DIV operator for integer division
query I rowsort label-6283
SELECT DISTINCT + col1 DIV col0 + - col1 FROM tab0 AS cor0
----
-83
-90
-95

skipif mysql # not compatible
query I rowsort label-6283
SELECT DISTINCT + col1 / col0 + - col1 FROM tab0 AS cor0
----
-83
-90
-95

query I rowsort
SELECT 94 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query I rowsort
SELECT + + cor0.col1 * + col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL cor0.col0 * + 69 * - cor0.col1 FROM tab2 AS cor0
----
-14973
-317538
-92667

query I rowsort
SELECT + cor0.col2 * + ( col1 + col1 ) AS col1 FROM tab2 AS cor0
----
1292
1674
3068

query I rowsort
SELECT 58 * - tab2.col0 - 67 AS col0 FROM tab2
----
-4591
-4649
-473

query I rowsort
SELECT + col0 * - ( 56 ) AS col0 FROM tab0 AS cor0
----
-1344
-1960
-4984

query I rowsort
SELECT 25 FROM tab0, tab1 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6291
SELECT - 14 DIV + col1 + col1 FROM tab1
----
12
26
9

skipif mysql # not compatible
query I rowsort label-6291
SELECT - 14 / + col1 + col1 FROM tab1
----
12
26
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6292
SELECT + col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6292
SELECT + col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6293
SELECT - col2 DIV + col0 AS col2 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6293
SELECT - col2 / + col0 AS col2 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT 35 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT + - cor0.col0 * col0 * - 59 AS col0 FROM tab2 AS cor0
----
2891
358956
368219

query I rowsort
SELECT col2 * 68 * col2 FROM tab2 AS cor0
----
45968
49572
98192

query I rowsort
SELECT ALL - - 0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT cor0.col0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT + cor0.col0 * + col1 + col1 FROM tab2 cor0
----
1360
248
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col1 * + ( + col0 ) + + col2 col1 FROM tab0 AS cor0
----
177537
329316
737091

query I rowsort
SELECT DISTINCT 66 AS col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
66

query I rowsort
SELECT + 62 AS col2 FROM tab2, tab1, tab1 cor0
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

query I rowsort
SELECT ALL 36 + - col2 AS col2 FROM tab0 AS cor0
----
-46
3
35

query I rowsort
SELECT ALL + + col0 + + col2 * col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL + col1 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - 87 + - col1 AS col2 FROM tab1 AS cor0
----
-100
-113
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 23 + + col2 * + col1 col0 FROM tab2 AS cor0
----
1511
623
814

query I rowsort
SELECT + + 41 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-41
40
8

query I rowsort
SELECT + + 43 + - 99 * - col1 FROM tab1 AS cor0
----
1033
1330
2617

query I rowsort
SELECT DISTINCT - col0 * col0 + + col2 AS col1 FROM tab2 AS cor0
----
-22
-6058
-6203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col0 col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + cor0.col2 * - 10 AS col1 FROM tab1 AS cor0
----
-540
-570
-960

query I rowsort
SELECT ALL 57 * + col1 AS col1 FROM tab0 AS cor0
----
4902
5187
5529

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6314
SELECT - - CAST( NULL AS SIGNED ) + + 79 * col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6314
SELECT - - CAST ( NULL AS INTEGER ) + + 79 * col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col0 * - col2 col2 FROM tab1 cor0
----
-188
-3658
-7693

query I rowsort
SELECT ALL - - col2 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - 33 + - col2 col2 FROM tab0 cor0
----
-2871
-3085
-3202

query I rowsort
SELECT ALL - - 77 * col1 + - col1 AS col0 FROM tab1 cor0
----
1976
760
988

onlyif mysql # use DIV operator for integer division
query I rowsort label-6319
SELECT - + 47 + col0 DIV col0 AS col2 FROM tab0 cor0
----
-46
-46
-46

skipif mysql # not compatible
query I rowsort label-6319
SELECT - + 47 + col0 / col0 AS col2 FROM tab0 cor0
----
-46
-46
-46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6320
SELECT DISTINCT - + CAST( col0 AS SIGNED ) * + col1 + - 72 AS col0 FROM tab2 cor0
----
-1415
-289
-4674

skipif mysql # not compatible
query I rowsort label-6320
SELECT DISTINCT - + CAST ( col0 AS INTEGER ) * + col1 + - 72 AS col0 FROM tab2 cor0
----
-1415
-289
-4674

skipif mysql # not compatible
query I rowsort
SELECT ALL + + CAST ( col0 AS REAL ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + col0 + + col0 AS col1 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT + ( - col2 ) + + col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col1 * - 75 AS col2 FROM tab0 AS cor0
----
-6450
-6825
-7275

query I rowsort
SELECT + 53 - col0 FROM tab2 AS cor0
----
-25
-26
46

query I rowsort
SELECT - 3 + + cor0.col0 * col1 AS col0 FROM tab0 cor0
----
2061
3392
8096

query I rowsort
SELECT DISTINCT ( + cor0.col1 ) + + col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL - col2 + - cor0.col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT + 93 * + col1 AS col1 FROM tab2 AS cor0
----
1581
2883
5487

query I rowsort
SELECT DISTINCT ( col0 + - tab0.col0 ) AS col1 FROM tab0
----
0

query I rowsort
SELECT ALL cor0.col2 + cor0.col1 AS col1 FROM tab1 AS cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 80 + - col0 col1 FROM tab2 AS cor0
----
1
2
73

query I rowsort
SELECT ALL - 51 AS col0 FROM tab2 AS cor0
----
-51
-51
-51

query I rowsort
SELECT DISTINCT - + 65 + col1 AS col2 FROM tab2 cor0
----
-34
-48
-6

onlyif mysql # use DIV operator for integer division
query I rowsort label-6335
SELECT DISTINCT + + col0 DIV + col2 AS col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-6335
SELECT DISTINCT + + col0 / + col2 AS col2 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT ALL - col0 + ( col0 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 43 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

skipif mysql # not compatible
query I rowsort
SELECT + col1 + CAST ( col0 AS REAL ) FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + ( col0 ) * col0 FROM tab2
----
49
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6340
SELECT ALL col1 + CAST( NULL AS SIGNED ) * col2 - + col1 * - ( - 5 ) * col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6340
SELECT ALL col1 + CAST ( NULL AS INTEGER ) * col2 - + col1 * - ( - 5 ) * col1 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - col0 + + tab1.col0 * tab1.col0 col2 FROM tab1
----
4089
60
6416

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6342
SELECT DISTINCT col0 - CAST( NULL AS DECIMAL ) AS col0 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-6342
SELECT DISTINCT col0 - CAST ( NULL AS REAL ) AS col0 FROM tab2
----
NULL

query I rowsort
SELECT col2 + + ( - col2 * tab2.col0 ) AS col0 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT + tab1.col0 * - col1 + + tab1.col2 * col2 FROM tab1
----
2609
2838
8176

query I rowsort
SELECT tab1.col0 + ( col0 ) AS col2 FROM tab1
----
128
160
6

query I rowsort
SELECT DISTINCT - + col1 + - col2 AS col0 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT - cor0.col0 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6348
SELECT col2 DIV 5 FROM tab2
----
5
5
7

skipif mysql # not compatible
query I rowsort label-6348
SELECT col2 / 5 FROM tab2
----
5
5
7

query I rowsort
SELECT DISTINCT + 75 * 51 - + col2 FROM tab0 AS cor0
----
3743
3792
3824

query I rowsort
SELECT DISTINCT col1 + - col1 AS col1 FROM tab0
----
0

query I rowsort
SELECT 21 + + col0 + tab1.col1 FROM tab1
----
114
50
95

query I rowsort
SELECT ALL + + col0 * + 57 * + col0 AS col0 FROM tab1 AS cor0
----
233472
364800
513

query I rowsort
SELECT DISTINCT - ( col1 ) + col2 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT - cor0.col0 FROM tab1, tab1 cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT - col2 + col1 * col1 * + col2 AS col0 FROM tab1 AS cor0
----
16128
36450
5643

query I rowsort
SELECT - - 21 * col2 * col0 FROM tab0 cor0
----
153258
16632
735

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6357
SELECT ALL - CAST( col2 AS SIGNED ) * col2 col1 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6357
SELECT ALL - CAST ( col2 AS INTEGER ) * col2 col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL col1 + - col0 + col0 AS col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - 42 * tab1.col1 + col2 * tab1.col1 FROM tab1
----
150
312
702

query I rowsort
SELECT + 75 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT DISTINCT col2 * - col2 AS col1 FROM tab2
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-6362
SELECT ALL + - col0 DIV col1 AS col2 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-6362
SELECT ALL + - col0 / col1 AS col2 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT ALL - col0 + - col0 * ( - col2 ) + - col2 AS col0 FROM tab0 AS cor0
----
-1
7127
735

onlyif mysql # use DIV operator for integer division
query I rowsort label-6364
SELECT DISTINCT + ( + col0 ) + ( col2 ) + - cor0.col2 DIV col0 FROM tab0 AS cor0
----
171
36
56

skipif mysql # not compatible
query I rowsort label-6364
SELECT DISTINCT + ( + col0 ) + ( col2 ) + - cor0.col2 / col0 FROM tab0 AS cor0
----
171
36
56

query I rowsort
SELECT ALL - tab2.col2 * tab2.col2 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT - cor0.col2 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6367
SELECT DISTINCT col0 + CAST( NULL AS DECIMAL ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6367
SELECT DISTINCT col0 + CAST ( NULL AS REAL ) AS col2 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6368
SELECT ALL - cor0.col2 * 53 - - col2 DIV - col0 FROM tab2 cor0
----
-1378
-1434
-2014

skipif mysql # not compatible
query I rowsort label-6368
SELECT ALL - cor0.col2 * 53 - - col2 / - col0 FROM tab2 cor0
----
-1378
-1434
-2014

query I rowsort
SELECT DISTINCT col1 + + col2 * + col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - - col1 + 49 * - col1 FROM tab0 cor0
----
-4128
-4368
-4656

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col0 * col2 col0 FROM tab0 AS cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-6372
SELECT DISTINCT - col0 - 92 DIV col0 FROM tab0 AS cor0
----
-27
-37
-90

skipif mysql # not compatible
query I rowsort label-6372
SELECT DISTINCT - col0 - 92 / col0 FROM tab0 AS cor0
----
-27
-37
-90

query I rowsort
SELECT ALL - - col1 * + col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL col2 + + col2 AS col0 FROM tab0 AS cor0
----
164
2
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-6375
SELECT ALL col2 + col0 * 23 DIV col1 AS col2 FROM tab1 AS cor0
----
204
237
56

skipif mysql # not compatible
query I rowsort label-6375
SELECT ALL col2 + col0 * 23 / col1 AS col2 FROM tab1 AS cor0
----
204
237
56

query I rowsort
SELECT col2 * - tab2.col2 * - 16 AS col1 FROM tab2
----
10816
11664
23104

onlyif mysql # use DIV operator for integer division
query I rowsort label-6377
SELECT DISTINCT 95 * tab0.col1 DIV tab0.col1 + col2 FROM tab0
----
128
177
96

skipif mysql # not compatible
query I rowsort label-6377
SELECT DISTINCT 95 * tab0.col1 / tab0.col1 + col2 FROM tab0
----
128
177
96

query I rowsort
SELECT + cor0.col1 * - 78 FROM tab2 AS cor0
----
-1326
-2418
-4602

query I rowsort
SELECT DISTINCT col0 * + 0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - col1 * - ( + col2 ) AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + col2 * - 65 AS col1 FROM tab2 AS cor0
----
-1690
-1755
-2470

query I rowsort
SELECT DISTINCT - col0 * - ( - col0 ) AS col1 FROM tab2 cor0
----
-49
-6084
-6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6383
SELECT CAST( NULL AS DECIMAL ) AS col1 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6383
SELECT CAST ( NULL AS REAL ) AS col1 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col2 ) col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT col0 + + 49 FROM tab1 AS cor0
----
113
129
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-6386
SELECT col0 * - ( + col2 ) + - col0 DIV ( + col1 ) FROM tab2 AS cor0
----
-189
-2029
-3006

skipif mysql # not compatible
query I rowsort label-6386
SELECT col0 * - ( + col2 ) + - col0 / ( + col1 ) FROM tab2 AS cor0
----
-189
-2029
-3006

query I rowsort
SELECT DISTINCT + tab2.col1 AS col1 FROM tab2, tab0, tab0 AS cor0
----
17
31
59

query I rowsort
SELECT + col1 + + ( col1 ) FROM tab1
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-6389
SELECT col0 * tab2.col1 DIV col0 - + col1 DIV 49 FROM tab2
----
17
31
58

skipif mysql # not compatible
query I rowsort label-6389
SELECT col0 * tab2.col1 / col0 - + col1 / 49 FROM tab2
----
17
31
58

query I rowsort
SELECT ALL - col1 + + tab2.col0 AS col2 FROM tab2
----
-24
19
62

query I rowsort
SELECT - col0 + + 46 * - col1 AS col0 FROM tab1 AS cor0
----
-1199
-524
-678

query I rowsort
SELECT - ( 79 ) * col0 + col2 * + cor0.col1 * col2 FROM tab0 AS cor0
----
-2668
604853
91758

query I rowsort
SELECT DISTINCT - 75 AS col2 FROM tab1, tab2 AS cor0, tab0 cor1
----
-75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6394
SELECT ALL + tab1.col2 * CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6394
SELECT ALL + tab1.col2 * CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 * + 12 AS col1 FROM tab0
----
-1068
-288
-420

query I rowsort
SELECT ( 85 ) AS col2 FROM tab2
----
85
85
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6397
SELECT ALL tab0.col1 DIV + 8 FROM tab0
----
10
11
12

skipif mysql # not compatible
query I rowsort label-6397
SELECT ALL tab0.col1 / + 8 FROM tab0
----
10
11
12

query I rowsort
SELECT ALL + + ( - cor0.col1 ) + - col0 AS col0 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT ALL - + ( 90 ) - col0 FROM tab0 AS cor0
----
-114
-125
-179

query I rowsort
SELECT - - cor0.col0 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ALL + col1 * col2 * - cor0.col1 + - cor0.col2 * - cor0.col1 FROM tab1 cor0
----
-14976
-35100
-5130

query I rowsort
SELECT ALL - col1 - + 52 AS col1 FROM tab0 AS cor0
----
-138
-143
-149

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 12 col0 FROM tab2 AS cor0
----
12

query I rowsort
SELECT - 32 AS col1 FROM tab0
----
-32
-32
-32

query I rowsort
SELECT ALL - 18 AS col1 FROM tab0
----
-18
-18
-18

query I rowsort
SELECT + 33 AS col1 FROM tab2
----
33
33
33

query I rowsort
SELECT DISTINCT + 45 + - ( col0 ) * ( - tab2.col1 ) AS col0 FROM tab2
----
1388
262
4647

query I rowsort
SELECT + col2 + - 72 * + col0 FROM tab0 AS cor0
----
-1695
-2519
-6326

query I rowsort
SELECT DISTINCT + 18 AS col2 FROM tab2
----
18

query I rowsort
SELECT + col1 + - ( col1 ) * 78 FROM tab0
----
-6622
-7007
-7469

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 ) * - col1 col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - 97 AS col1 FROM tab1 AS cor0
----
-97
-97
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 30 col2 FROM tab0 AS cor0
----
30
30
30

query I rowsort
SELECT - cor0.col0 * + cor0.col0 + ( + col2 ) AS col2 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT DISTINCT - ( - col1 ) AS col2 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT - cor0.col2 * - col0 * 0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT cor0.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT + col0 * + 42 - col2 FROM tab0 cor0
----
1469
3656
975

query I rowsort
SELECT ALL tab0.col2 AS col0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

onlyif mysql # use DIV operator for integer division
query I rowsort label-6420
SELECT - col0 DIV + ( 23 ) col2 FROM tab2 cor0
----
-3
-3
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6420
SELECT - col0 / + ( 23 ) col2 FROM tab2 cor0
----
-3
-3
0

query I rowsort
SELECT col2 - 72 FROM tab1 AS cor0
----
-15
-18
24

query I rowsort
SELECT col1 + 62 AS col0 FROM tab0 AS cor0
----
148
153
159

query I rowsort
SELECT + col0 + 97 FROM tab2 AS cor0
----
104
175
176

onlyif mysql # use DIV operator for integer division
query I rowsort label-6424
SELECT - col0 DIV ( col0 * + col0 ) AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6424
SELECT - col0 / ( col0 * + col0 ) AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 + - col1 * - col2 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-6426
SELECT - + ( cor0.col0 ) * + cor0.col0 + + 23 * col2 DIV + col2 FROM tab0 cor0
----
-1202
-553
-7898

skipif mysql # not compatible
query I rowsort label-6426
SELECT - + ( cor0.col0 ) * + cor0.col0 + + 23 * col2 / + col2 FROM tab0 cor0
----
-1202
-553
-7898

query I rowsort
SELECT + - col2 * - 7 + col1 * col2 * cor0.col1 AS col1 FROM tab1 AS cor0
----
16896
36882
6099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - + ( tab0.col0 ) col0 FROM tab0
----
2
62
62

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to 677ef6b86493a7e48d2f6a3cfd7eea4c

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 AS cor2, tab2 cor3
----
3645 values hashing to bd2b318ad064d89aa12ab468220362b6

query I rowsort
SELECT + cor0.col0 * col2 * + col1 FROM tab1 cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-6432
SELECT DISTINCT - col1 DIV 8 - 76 FROM tab1
----
-77
-79

skipif mysql # not compatible
query I rowsort label-6432
SELECT DISTINCT - col1 / 8 - 76 FROM tab1
----
-77
-79

query I rowsort
SELECT col1 + + col2 * 33 FROM tab1
----
1808
1891
3181

onlyif mysql # use DIV operator for integer division
query I rowsort label-6434
SELECT + + col2 + col1 DIV col2 AS col0 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6434
SELECT + + col2 + col1 / col2 AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL col1 + + col1 * - 40 FROM tab0 cor0
----
-3354
-3549
-3783

query I rowsort
SELECT - + col1 + + col1 * + 68 FROM tab2 AS cor0
----
1139
2077
3953

query I rowsort
SELECT + cor0.col2 * + 27 * col2 FROM tab2 AS cor0
----
18252
19683
38988

query I rowsort
SELECT 48 + + cor0.col0 * col0 FROM tab1 AS cor0
----
4144
57
6448

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * - 41 col1 FROM tab0 AS cor0
----
3526
3731
3977

query I rowsort
SELECT + cor0.col2 + - col2 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col0 * + col2 - col0 AS col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT ALL 99 + 46 AS col0 FROM tab1 AS cor0
----
145
145
145

query I rowsort
SELECT ALL 72 FROM tab2, tab0 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT - col1 * - col0 + + col1 FROM tab2 cor0
----
1360
248
4661

query I rowsort
SELECT ALL - - 53 + col1 AS col1 FROM tab2 AS cor0
----
112
70
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-6446
SELECT ALL + - col0 DIV + col2 + + col0 FROM tab0 AS cor0
----
0
24
88

skipif mysql # not compatible
query I rowsort label-6446
SELECT ALL + - col0 / + col2 + + col0 FROM tab0 AS cor0
----
0
24
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6447
SELECT DISTINCT - CAST( NULL AS SIGNED ) * - col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6447
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * - col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - ( + 88 ) + - col2 FROM tab1 AS cor0
----
-142
-145
-184

query I rowsort
SELECT - + 38 AS col1 FROM tab0 AS cor0
----
-38
-38
-38

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0, tab1 cor1, tab0 cor2
----
972 values hashing to 9b91cf9fcc064ee1c13074a678b72ac7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6451
SELECT cor0.col1 DIV + 30 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to fe1df43d82827beaec70549919af445c

skipif mysql # not compatible
query I rowsort label-6451
SELECT cor0.col1 / + 30 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to fe1df43d82827beaec70549919af445c

query I rowsort
SELECT cor0.col0 + - col1 * - col2 AS col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT + col0 - col0 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT 17 + col0 AS col2 FROM tab1 AS cor0
----
20
81
97

query I rowsort
SELECT DISTINCT + col2 * col1 - + cor0.col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT DISTINCT + tab0.col0 * - col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - + col0 * - col0 AS col1 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6458
SELECT + col2 * CAST( NULL AS SIGNED ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6458
SELECT + col2 * CAST ( NULL AS INTEGER ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6459
SELECT + + col0 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6459
SELECT + + col0 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 80 AS col1 FROM tab2, tab0, tab0 AS cor0
----
80

query I rowsort
SELECT ALL + 18 * col2 FROM tab2
----
468
486
684

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col1 FROM tab2, tab1, tab1 AS cor0, tab0 AS cor1
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

query I rowsort
SELECT DISTINCT - 11 * col0 AS col2 FROM tab0
----
-264
-385
-979

query I rowsort
SELECT DISTINCT - col0 + ( + 47 ) FROM tab1 AS cor0
----
-17
-33
44

query I rowsort
SELECT + 67 AS col1 FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6466
SELECT - col2 * + CAST( NULL AS SIGNED ) + + ( cor0.col0 ) * + ( - ( + cor0.col1 ) * col1 ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6466
SELECT - col2 * + CAST ( NULL AS INTEGER ) + + ( cor0.col0 ) * + ( - ( + cor0.col1 ) * col1 ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * + 95 FROM tab1 cor0
----
285
6080
7600

query I rowsort
SELECT ALL + col2 * col0 + - cor0.col0 * col0 AS col0 FROM tab0 AS cor0
----
-1190
-623
216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + cor0.col1 * + col1 col2 FROM tab2 AS cor0
----
210
3403
954

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6470
SELECT 60 / + col2 + - CAST( NULL AS DECIMAL ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6470
SELECT 60 / + col2 + - CAST ( NULL AS REAL ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 26 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 76 * + col2 + + 55 col0 FROM tab1
----
4159
4387
7351

query I rowsort
SELECT + col2 * 34 - - 25 FROM tab1
----
1861
1963
3289

query I rowsort
SELECT ALL - col1 + + col0 * col2 AS col2 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT ALL - col0 * - 86 FROM tab1 AS cor0
----
258
5504
6880

query I rowsort
SELECT col0 * + col2 + col1 * col2 * - col1 AS col0 FROM tab1
----
-2052
-36342
-8544

query I rowsort
SELECT ALL - 21 FROM tab2, tab2 AS cor0
----
9 values hashing to 631fbd1fd929405aba54a22c2a06c757

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6478
SELECT - CAST( NULL AS SIGNED ) AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6478
SELECT - CAST ( NULL AS INTEGER ) AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - col1 + + ( col1 + col1 ) FROM tab1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 col2 FROM tab2, tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ( + col1 ) * col1 * col1 + - 63 * col2 FROM tab0
----
633977
748405
912610

query I rowsort
SELECT + cor1.col1 FROM tab2, tab1 cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT + 78 FROM tab2 AS cor0
----
78

query I rowsort
SELECT ( tab0.col0 ) - tab0.col1 * col1 AS col2 FROM tab0
----
-7372
-8192
-9374

query I rowsort
SELECT + 47 AS col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

onlyif mysql # use DIV operator for integer division
query I rowsort label-6486
SELECT DISTINCT - col0 DIV tab2.col1 + col2 + - ( - col2 ) * - col0 FROM tab2
----
-162
-2003
-2968

skipif mysql # not compatible
query I rowsort label-6486
SELECT DISTINCT - col0 / tab2.col1 + col2 + - ( - col2 ) * - col0 FROM tab2
----
-162
-2003
-2968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6487
SELECT + CAST( - col1 AS SIGNED ) + col0 AS col1 FROM tab2 cor0
----
-24
19
62

skipif mysql # not compatible
query I rowsort label-6487
SELECT + CAST ( - col1 AS INTEGER ) + col0 AS col1 FROM tab2 cor0
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + tab2.col0 ) + col1 col1 FROM tab2
----
-19
-62
24

query I rowsort
SELECT DISTINCT - col2 + col0 * + col1 AS col1 FROM tab0
----
2031
3394
8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-6490
SELECT DISTINCT col2 * col0 DIV col1 + col2 FROM tab1
----
421
60
686

skipif mysql # not compatible
query I rowsort label-6490
SELECT DISTINCT col2 * col0 / col1 + col2 FROM tab1
----
421
60
686

query I rowsort
SELECT DISTINCT + col1 * col2 + + col0 * + 85 FROM tab1
----
1659
6010
8048

query I rowsort
SELECT ALL col1 * col0 + + tab2.col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT ( + col1 ) + col2 AS col2 FROM tab0
----
119
173
98

query I rowsort
SELECT DISTINCT 44 * - col2 - + col0 AS col2 FROM tab2 AS cor0
----
-1195
-1222
-1751

query I rowsort
SELECT col0 * + cor0.col2 + col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL + 94 * + col0 * cor0.col1 AS col1 FROM tab0 cor0
----
194016
319130
761306

query I rowsort
SELECT DISTINCT + 75 * col2 FROM tab2 cor0
----
1950
2025
2850

query I rowsort
SELECT DISTINCT + col0 * cor0.col0 AS col0 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT col0 * cor0.col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - - col0 + - col2 AS col0 FROM tab0 cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6501
SELECT DISTINCT + col1 DIV + col0 - ( - 83 ) col1 FROM tab2 AS cor0
----
83
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6501
SELECT DISTINCT + col1 / + col0 - ( - 83 ) col1 FROM tab2 AS cor0
----
83
87

query I rowsort
SELECT + col0 + + col0 * + col2 AS col2 FROM tab0 cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-6503
SELECT + col0 + - cor0.col2 DIV - col1 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6503
SELECT + col0 + - cor0.col2 / - col1 AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + 40 + - col2 + ( col0 ) AS col1 FROM tab1 AS cor0
----
-11
24
47

query I rowsort
SELECT DISTINCT ( col2 ) + - col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT col1 * col1 * + col2 AS col1 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT ALL - + col2 * col2 - 71 FROM tab0 AS cor0
----
-1160
-6795
-72

query I rowsort
SELECT ALL - col0 + + col1 * + col2 AS col1 FROM tab2 cor0
----
1456
567
830

query I rowsort
SELECT ALL + col0 * - col1 + - col1 FROM tab1 AS cor0
----
-104
-1053
-650

onlyif mysql # use DIV operator for integer division
query I rowsort label-6510
SELECT col0 + + col1 DIV col1 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-6510
SELECT col0 + + col1 / col1 FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT + - col0 * - col2 + + col1 FROM tab2 AS cor0
----
2087
220
3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col2 col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + col1 * - col2 AS col0 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT ALL 24 + col2 * + col1 FROM tab1 AS cor0
----
1272
1428
594

query I rowsort
SELECT + + cor0.col1 + cor0.col0 + + col0 AS col1 FROM tab2 AS cor0
----
175
215
45

query I rowsort
SELECT + col2 * col0 + col2 * col1 * col0 AS col0 FROM tab2 AS cor0
----
121680
54036
6048

query I rowsort
SELECT - + col2 - + col0 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT ALL + - 78 * col0 FROM tab1 AS cor0
----
-234
-4992
-6240

query I rowsort
SELECT DISTINCT - cor0.col1 * + cor0.col2 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT col0 * col1 + - cor0.col2 + - col1 AS col0 FROM tab1 AS cor0
----
-2
573
931

query I rowsort
SELECT - - col1 + col0 + cor0.col2 FROM tab1 cor0
----
131
189
83

query I rowsort
SELECT ALL col0 + - 92 AS col1 FROM tab2
----
-13
-14
-85

query I rowsort
SELECT DISTINCT + ( + col0 ) + col1 AS col0 FROM tab2
----
137
38
96

query I rowsort
SELECT DISTINCT ( col1 ) * - col0 + col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT + ( + 19 ) * col0 FROM tab1
----
1216
1520
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col1 col0 FROM tab2
----
0
0
0

query I rowsort
SELECT 31 * + col0 + - col0 FROM tab1 cor0
----
1920
2400
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col2 + col0 col2 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL + 82 + - col2 FROM tab1
----
-14
25
28

query I rowsort
SELECT DISTINCT col2 * + col0 + - col2 + cor0.col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - col1 + cor0.col2 * col0 + col0 FROM tab0 AS cor0
----
-27
7296
730

query I rowsort
SELECT DISTINCT ( + tab0.col1 * col2 ) FROM tab0
----
2838
7462
97

query I rowsort
SELECT 30 * - col0 AS col1 FROM tab2
----
-210
-2340
-2370

query I rowsort
SELECT DISTINCT + 14 AS col1 FROM tab0
----
14

query I rowsort
SELECT ALL col1 * + col2 * col1 + tab1.col2 FROM tab1
----
16320
36558
5757

query I rowsort
SELECT ALL tab1.col2 * tab1.col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT - col0 + col0 FROM tab1 WHERE ( + col0 + col1 ) > NULL
----

query I rowsort
SELECT - tab2.col1 * col2 + col1 AS col1 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT + col2 AS col2 FROM tab2 WHERE NOT NULL NOT IN ( - tab2.col0 + - col2 )
----

query I rowsort
SELECT DISTINCT - col0 - + col0 * col1 FROM tab0
----
-2088
-3430
-8188

query I rowsort
SELECT tab2.col2 * - col2 + col1 * col2 FROM tab2
----
-798
108
858

query I rowsort
SELECT col1 * - col0 + + tab1.col1 AS col2 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT + col1 + - col2 + col1 / col1 FROM tab0 WHERE NULL <= + col2 * col0
----

query I rowsort
SELECT - col0 - tab1.col2 FROM tab1
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6545
SELECT col1 * col1 + col0 DIV + col1 AS col0 FROM tab2
----
293
3482
961

skipif mysql # not compatible
query I rowsort label-6545
SELECT col1 * col1 + col0 / + col1 AS col0 FROM tab2
----
293
3482
961

query I rowsort
SELECT col1 * + col0 FROM tab1 WHERE NOT NULL NOT BETWEEN - col0 AND NULL
----

query I rowsort
SELECT + col2 * col2 + col0 AS col0 FROM tab2
----
1523
736
754

onlyif mysql # use DIV operator for integer division
query I rowsort label-6548
SELECT DISTINCT col1 DIV - col1 - tab2.col1 AS col1 FROM tab2
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-6548
SELECT DISTINCT col1 / - col1 - tab2.col1 AS col1 FROM tab2
----
-18
-32
-60

query I rowsort
SELECT ALL tab2.col1 + - col1 * + tab2.col2 FROM tab2
----
-1475
-629
-806

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT col0 + - col1 * + col0 < - col2
----

query I rowsort
SELECT col1 * col1 + col1 AS col1 FROM tab1
----
110
182
702

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL BETWEEN ( col2 ) AND col2 * col1
----

query I rowsort
SELECT DISTINCT tab0.col0 * + col2 * col2 AS col1 FROM tab0
----
26136
35
598436

onlyif mysql # use DIV operator for integer division
query I rowsort label-6554
SELECT ALL - col0 * col0 + col1 - - col0 DIV - col1 FROM tab2
----
-18
-6026
-6228

skipif mysql # not compatible
query I rowsort label-6554
SELECT ALL - col0 * col0 + col1 - - col0 / - col1 FROM tab2
----
-18
-6026
-6228

query I rowsort
SELECT col2 + col1 * - col1 AS col1 FROM tab0
----
-7363
-8199
-9408

query I rowsort
SELECT ALL col2 AS col1 FROM tab2 WHERE NOT NULL BETWEEN ( col1 ) AND NULL
----

query I rowsort
SELECT ALL col2 * col2 * + tab0.col0 FROM tab0
----
26136
35
598436

query I rowsort
SELECT col2 + - col0 + col2 FROM tab2
----
-26
-3
47

query I rowsort
SELECT ALL cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query III rowsort
SELECT ALL * FROM tab2 WHERE NULL IN ( col0 )
----

query I rowsort
SELECT + cor0.col0 + col1 * + cor0.col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT DISTINCT + + cor0.col2 * + col1 AS col1 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT cor0.col0 FROM tab2, tab2 cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6564
SELECT - col0 DIV col1 + col1 DIV cor0.col0 col0 FROM tab2 AS cor0
----
-1
-4
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6564
SELECT - col0 / col1 + col1 / cor0.col0 col0 FROM tab2 AS cor0
----
-1
-4
4

query III rowsort
SELECT ALL * FROM tab1 WHERE col0 NOT BETWEEN col0 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6566
SELECT DISTINCT + tab0.col2 + col1 DIV + col0 + - tab0.col0 FROM tab0
----
-32
-6
12

skipif mysql # not compatible
query I rowsort label-6566
SELECT DISTINCT + tab0.col2 + col1 / + col0 + - tab0.col0 FROM tab0
----
-32
-6
12

query I rowsort
SELECT - col0 * + cor0.col2 + col2 + col0 * col0 FROM tab0 AS cor0
----
-183
1191
705

query I rowsort
SELECT + col1 AS col2 FROM tab1 AS cor0 WHERE ( col2 ) IN ( + col2 / col1 )
----

query I rowsort
SELECT ALL - cor0.col1 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT - 88 + - col0 FROM tab2
----
-166
-167
-95

query I rowsort
SELECT + 78 * + col2 AS col1 FROM tab0 cor0
----
2574
6396
78

query I rowsort
SELECT ALL col2 + col2 * + col1 + + 79 * col1 AS col0 FROM tab1 AS cor0
----
1417
2371
3512

query I rowsort
SELECT DISTINCT 63 AS col1 FROM tab2 AS cor0
----
63

query I rowsort
SELECT + - cor0.col2 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL + - col2 + cor0.col0 AS col0 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6576
SELECT tab2.col1 DIV col0 + col2 AS col0 FROM tab2
----
26
31
38

skipif mysql # not compatible
query I rowsort label-6576
SELECT tab2.col1 / col0 + col2 AS col0 FROM tab2
----
26
31
38

query I rowsort
SELECT DISTINCT 92 AS col0 FROM tab1, tab0, tab1 AS cor0
----
92

query I rowsort
SELECT - - 99 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

onlyif mysql # use DIV operator for integer division
query I rowsort label-6579
SELECT DISTINCT + cor0.col2 DIV 70 AS col0 FROM tab0, tab1 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-6579
SELECT DISTINCT + cor0.col2 / 70 AS col0 FROM tab0, tab1 cor0
----
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6580
SELECT DISTINCT - 82 DIV col1 AS col2 FROM tab1
----
-3
-6
-8

skipif mysql # not compatible
query I rowsort label-6580
SELECT DISTINCT - 82 / col1 AS col2 FROM tab1
----
-3
-6
-8

query I rowsort
SELECT DISTINCT - 79 + col1 + col2 AS col0 FROM tab2 AS cor0
----
-21
-24
6

query I rowsort
SELECT ALL - col2 * cor0.col0 + + col1 * cor0.col2 FROM tab1 AS cor0
----
-3078
-6432
1242

query I rowsort
SELECT DISTINCT 37 * + col1 FROM tab1 AS cor0
----
370
481
962

onlyif mysql # use DIV operator for integer division
query I rowsort label-6584
SELECT DISTINCT - + 81 DIV col2 + + ( - col0 ) FROM tab1 cor0
----
-4
-65
-80

skipif mysql # not compatible
query I rowsort label-6584
SELECT DISTINCT - + 81 / col2 + + ( - col0 ) FROM tab1 cor0
----
-4
-65
-80

query I rowsort
SELECT DISTINCT 90 * col0 + col0 AS col2 FROM tab2 AS cor0
----
637
7098
7189

query I rowsort
SELECT DISTINCT + 6 * - col1 + ( + col2 ) * + col0 FROM tab1 cor0
----
3588
6
7602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6587
SELECT ALL + cor0.col1 * - col1 + CAST( + col1 AS SIGNED ) + - cor0.col1 AS col1 FROM tab1 cor0
----
-100
-169
-676

skipif mysql # not compatible
query I rowsort label-6587
SELECT ALL + cor0.col1 * - col1 + CAST ( + col1 AS INTEGER ) + - cor0.col1 AS col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT ALL - col2 + ( - 27 ) AS col0 FROM tab2
----
-53
-54
-65

onlyif mysql # use DIV operator for integer division
query I rowsort label-6589
SELECT ALL col2 DIV + 30 + tab0.col1 AS col0 FROM tab0
----
87
93
97

skipif mysql # not compatible
query I rowsort label-6589
SELECT ALL col2 / + 30 + tab0.col1 AS col0 FROM tab0
----
87
93
97

query I rowsort
SELECT + cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT + col1 * - col2 * - col2 AS col1 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT - + col0 * + ( col0 ) * col0 AS col0 FROM tab0 AS cor0
----
-13824
-42875
-704969

query I rowsort
SELECT + col1 * - col0 * + col2 + - col1 FROM tab1 AS cor0
----
-36490
-4238
-99853

query I rowsort
SELECT col1 * - col1 * + col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-6595
SELECT ALL - col0 + col2 * + col2 + - col0 DIV cor0.col1 FROM tab1 cor0
----
2913
3179
9130

skipif mysql # not compatible
query I rowsort label-6595
SELECT ALL - col0 + col2 * + col2 + - col0 / cor0.col1 FROM tab1 cor0
----
2913
3179
9130

query I rowsort
SELECT + 27 + 76 * col2 FROM tab1 AS cor0
----
4131
4359
7323

query I rowsort
SELECT DISTINCT + col2 * - 87 + + col2 FROM tab0 AS cor0
----
-2838
-7052
-86

query I rowsort
SELECT DISTINCT - col1 - + 62 AS col1 FROM tab1 AS cor0
----
-72
-75
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 27 + col2 col1 FROM tab0 AS cor0
----
2355
2539
2620

query I rowsort
SELECT ALL 4 + 78 FROM tab1 AS cor0
----
82
82
82

query I rowsort
SELECT DISTINCT - 38 * + col1 AS col2 FROM tab1 AS cor0
----
-380
-494
-988

query I rowsort
SELECT DISTINCT - 33 FROM tab0, tab1 AS cor0
----
-33

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0, tab1 AS cor1, tab2 cor2
----
972 values hashing to e610acd60f342127e6cdba18673d9f0e

query I rowsort
SELECT + col1 * - 31 FROM tab0 AS cor0
----
-2666
-2821
-3007

onlyif mysql # use DIV operator for integer division
query I rowsort label-6605
SELECT ALL - cor0.col1 DIV - cor0.col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6605
SELECT ALL - cor0.col1 / - cor0.col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT - 4 * col1 AS col2 FROM tab0 AS cor0
----
-344
-364
-388

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6607
SELECT DISTINCT + CAST( - col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-6607
SELECT DISTINCT + CAST ( - col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + col1 + + col1 * + col0 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT - - col1 * col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT + col1 * - 17 * col0 FROM tab0 AS cor0
----
-137683
-35088
-57715

query I rowsort
SELECT ALL 11 + ( col0 + + 16 ) AS col2 FROM tab0 AS cor0
----
116
51
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( - cor0.col0 ) * col2 col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT - col1 * col2 + - col0 * ( + col0 ) FROM tab0 AS cor0
----
-1322
-15383
-3414

query I rowsort
SELECT ALL + col2 * - col2 * col1 AS col2 FROM tab1 cor0
----
-119808
-32490
-75816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * ( - col0 ) col2 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT + 23 + col2 + - col0 FROM tab2 cor0
----
-18
-29
43

query I rowsort
SELECT + col0 + - 65 * col1 AS col1 FROM tab1 AS cor0
----
-1687
-586
-765

onlyif mysql # use DIV operator for integer division
query I rowsort label-6618
SELECT DISTINCT + + col1 DIV 95 AS col1 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-6618
SELECT DISTINCT + + col1 / 95 AS col1 FROM tab0 AS cor0
----
0
1

query I rowsort
SELECT + ( - ( - col0 ) ) * ( - col2 + - col2 * 63 ) FROM tab0 AS cor0
----
-2240
-467072
-50688

query I rowsort
SELECT ALL - 28 AS col0 FROM tab2 AS cor0
----
-28
-28
-28

query I rowsort
SELECT DISTINCT - col1 * + 36 FROM tab1 AS cor0
----
-360
-468
-936

query I rowsort
SELECT - col0 + - cor0.col1 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT + 97 - col1 FROM tab1 AS cor0
----
71
84
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-6624
SELECT ALL + - 31 + col0 - ( - col0 ) DIV + col2 FROM tab0 AS cor0
----
-7
39
59

skipif mysql # not compatible
query I rowsort label-6624
SELECT ALL + - 31 + col0 - ( - col0 ) / + col2 FROM tab0 AS cor0
----
-7
39
59

query I rowsort
SELECT - ( - ( col0 ) + + col0 ) FROM tab0
----
0
0
0

query I rowsort
SELECT ALL cor0.col2 + 78 FROM tab2 AS cor0
----
104
105
116

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 + + cor0.col0 * 33 * cor0.col2 col0 FROM tab2 AS cor0
----
6264
66950
99104

query I rowsort
SELECT - col2 * cor0.col2 + cor0.col2 + col1 AS col2 FROM tab0 AS cor0
----
-6551
-970
97

query I rowsort
SELECT + cor0.col2 * + 28 + + col2 AS col0 FROM tab2 AS cor0
----
1102
754
783

query I rowsort
SELECT DISTINCT cor0.col1 + 16 AS col0 FROM tab2 AS cor0
----
33
47
75

query I rowsort
SELECT col1 + + col0 + - 18 * + col1 AS col0 FROM tab2
----
-210
-520
-925

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6632
SELECT DISTINCT col1 * col1 + + ( col0 ) + CAST( NULL AS SIGNED ) AS col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6632
SELECT DISTINCT col1 * col1 + + ( col0 ) + CAST ( NULL AS INTEGER ) AS col2 FROM tab1
----
NULL

query I rowsort
SELECT tab1.col2 + - 73 FROM tab1
----
-16
-19
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-6634
SELECT DISTINCT + col2 DIV col0 + col1 * col1 FROM tab2
----
289
3481
964

skipif mysql # not compatible
query I rowsort label-6634
SELECT DISTINCT + col2 / col0 + col1 * col1 FROM tab2
----
289
3481
964

query I rowsort
SELECT - 92 + 42 AS col0 FROM tab2 AS cor0
----
-50
-50
-50

onlyif mysql # use DIV operator for integer division
query I rowsort label-6636
SELECT col0 * ( - col1 ) DIV - col1 + - col1 + col0 * + col2 FROM tab1
----
139
3702
7747

skipif mysql # not compatible
query I rowsort label-6636
SELECT col0 * ( - col1 ) / - col1 + - col1 + col0 * + col2 FROM tab1
----
139
3702
7747

query I rowsort
SELECT DISTINCT col2 + col2 + + 37 FROM tab0
----
103
201
39

query I rowsort
SELECT ALL - col2 * col1 + - col2 + + tab2.col1 AS col1 FROM tab2
----
-1501
-667
-833

query I rowsort
SELECT - col0 * + 59 AS col2 FROM tab2
----
-413
-4602
-4661

query I rowsort
SELECT DISTINCT + - col0 * - ( + col0 ) AS col0 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6641
SELECT col0 DIV col1 + - 98 AS col1 FROM tab0
----
-98
-98
-98

skipif mysql # not compatible
query I rowsort label-6641
SELECT col0 / col1 + - 98 AS col1 FROM tab0
----
-98
-98
-98

query I rowsort
SELECT - tab2.col1 + + 47 * ( + col2 ) * - col0 AS col0 FROM tab2
----
-141111
-8914
-95375

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6643
SELECT + col1 + CAST( + col2 AS SIGNED ) + + tab0.col1 FROM tab0
----
195
205
264

skipif mysql # not compatible
query I rowsort label-6643
SELECT + col1 + CAST ( + col2 AS INTEGER ) + + tab0.col1 FROM tab0
----
195
205
264

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6644
SELECT tab2.col1 * CAST( NULL AS SIGNED ) + 58 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6644
SELECT tab2.col1 * CAST ( NULL AS INTEGER ) + 58 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6645
SELECT DISTINCT - col0 DIV + col2 + + col2 AS col2 FROM tab1
----
54
56
96

skipif mysql # not compatible
query I rowsort label-6645
SELECT DISTINCT - col0 / + col2 + + col2 AS col2 FROM tab1
----
54
56
96

query I rowsort
SELECT DISTINCT + col0 + col0 + - 75 AS col0 FROM tab1
----
-69
53
85

query I rowsort
SELECT DISTINCT - ( col2 * + col2 ) AS col1 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT 87 * cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
1131
2262
870

query I rowsort
SELECT + cor0.col1 + - col2 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL + - 95 FROM tab1 cor0
----
-95
-95
-95

query I rowsort
SELECT col2 + + col1 * col1 AS col2 FROM tab0 AS cor0
----
7429
8363
9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col2 col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + col2 * col0 + col0 * + col2 FROM tab1 AS cor0
----
15360
324
7296

query I rowsort
SELECT + col0 + ( - 80 ) AS col0 FROM tab2 AS cor0
----
-1
-2
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-6655
SELECT DISTINCT + tab0.col0 DIV col0 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-6655
SELECT DISTINCT + tab0.col0 / col0 FROM tab0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 19 col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
19

onlyif mysql # use DIV operator for integer division
query I rowsort label-6657
SELECT col1 DIV + 18 + ( col0 ) FROM tab1 AS cor0
----
4
64
80

skipif mysql # not compatible
query I rowsort label-6657
SELECT col1 / + 18 + ( col0 ) FROM tab1 AS cor0
----
4
64
80

query I rowsort
SELECT ALL + ( + 95 ) + - col2 FROM tab0 AS cor0
----
13
62
94

query I rowsort
SELECT 69 * col2 FROM tab0
----
2277
5658
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-6660
SELECT 13 DIV + col0 AS col0 FROM tab1
----
0
0
4

skipif mysql # not compatible
query I rowsort label-6660
SELECT 13 / + col0 AS col0 FROM tab1
----
0
0
4

query I rowsort
SELECT DISTINCT - tab1.col2 * - col0 FROM tab1
----
162
3648
7680

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0, tab0 AS cor1, tab1 AS cor2
----
972 values hashing to 5621675b1bd32b061d284d0444c76601

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6663
SELECT ALL - + CAST( - 33 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
33
33
33

skipif mysql # not compatible
query I rowsort label-6663
SELECT ALL - + CAST ( - 33 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
33
33
33

query I rowsort
SELECT - 86 * + col2 AS col0 FROM tab1 AS cor0
----
-4644
-4902
-8256

query I rowsort
SELECT DISTINCT + 4 + - 48 FROM tab0 AS cor0
----
-44

query I rowsort
SELECT ( 54 ) AS col1 FROM tab0 AS cor0
----
54
54
54

query I rowsort
SELECT DISTINCT ( 71 ) FROM tab1 AS cor0
----
71

query I rowsort
SELECT col1 + cor0.col0 * - 92 FROM tab1 AS cor0
----
-250
-5878
-7347

query I rowsort
SELECT + - 57 - cor0.col1 * cor0.col2 FROM tab1 AS cor0
----
-1305
-1461
-627

query I rowsort
SELECT - col0 * - col1 + + col0 AS col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT - 20 AS col2 FROM tab0
----
-20
-20
-20

query I rowsort
SELECT + tab1.col1 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT DISTINCT + col1 + + 87 * + col2 AS col1 FROM tab0
----
184
2957
7225

query I rowsort
SELECT - + col1 + + col2 AS col2 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT + ( + col2 ) * + col1 * - 30 + col1 * + col2 * ( tab2.col2 * - col2 ) AS col0 FROM tab2
----
-1083004
-635283
-952204

query I rowsort
SELECT DISTINCT - 60 - tab0.col0 FROM tab0
----
-149
-84
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 60 col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 1d2ab302ae60f95b15e68cf89083b162

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6678
SELECT - 35 + tab2.col0 * - CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6678
SELECT - 35 + tab2.col0 * - CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col0 + 7 FROM tab1, tab0 AS cor0
----
9 values hashing to 846f3d0e9cb5a61a1928b56585f3dcf0

query I rowsort
SELECT ALL 40 * col2 AS col1 FROM tab0 AS cor0
----
1320
3280
40

query I rowsort
SELECT ALL cor0.col2 + 11 FROM tab0 AS cor0
----
12
44
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6682
SELECT col1 - CAST( + 68 AS SIGNED ) col1 FROM tab1 AS cor0
----
-42
-55
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6682
SELECT col1 - CAST ( + 68 AS INTEGER ) col1 FROM tab1 AS cor0
----
-42
-55
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col2 + - 48 col1 FROM tab0 AS cor0
----
2790
49
7414

query I rowsort
SELECT ALL - cor0.col1 + + ( - ( col0 ) ) * 90 AS col0 FROM tab1 cor0
----
-296
-5770
-7213

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col2 col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + col0 * - cor0.col1 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6687
SELECT DISTINCT + col1 * CAST( col0 AS SIGNED ) * + col0 FROM tab2 cor0
----
106097
1519
358956

skipif mysql # not compatible
query I rowsort label-6687
SELECT DISTINCT + col1 * CAST ( col0 AS INTEGER ) * + col0 FROM tab2 cor0
----
106097
1519
358956

query I rowsort
SELECT + - cor0.col2 + col1 * + 84 FROM tab2 AS cor0
----
1390
2577
4930

query I rowsort
SELECT DISTINCT - col2 * ( - 66 * col2 ) AS col0 FROM tab0 AS cor0
----
443784
66
71874

query I rowsort
SELECT ALL - col0 * - 55 FROM tab0 AS cor0
----
1320
1925
4895

query I rowsort
SELECT DISTINCT - col2 * 8 + + col2 AS col0 FROM tab0 AS cor0
----
-231
-574
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col2 + col0 col1 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-6693
SELECT - - col2 DIV cor0.col1 + col0 FROM tab2 AS cor0
----
7
78
81

skipif mysql # not compatible
query I rowsort label-6693
SELECT - - col2 / cor0.col1 + col0 FROM tab2 AS cor0
----
7
78
81

query I rowsort
SELECT DISTINCT + + col2 * ( + col0 ) * - col0 AS col0 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT ALL - + col1 + ( + col2 * col0 ) AS col1 FROM tab1 cor0
----
136
3638
7667

query I rowsort
SELECT + col1 + 48 * + col2 FROM tab0 AS cor0
----
145
1670
4027

query I rowsort
SELECT ALL + cor0.col1 - + 20 AS col2 FROM tab2 AS cor0
----
-3
11
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-6698
SELECT ALL - col2 DIV + col1 + + ( tab1.col1 * + col0 ) - + 15 AS col2 FROM tab1
----
1018
61
620

skipif mysql # not compatible
query I rowsort label-6698
SELECT ALL - col2 / + col1 + + ( tab1.col1 * + col0 ) - + 15 AS col2 FROM tab1
----
1018
61
620

query I rowsort
SELECT DISTINCT 35 * + col2 AS col2 FROM tab0
----
1155
2870
35

query I rowsort
SELECT ALL - ( - col0 ) AS col1 FROM tab0
----
24
35
89

query I rowsort
SELECT 98 * cor0.col0 + + col0 FROM tab1 AS cor0
----
297
6336
7920

onlyif mysql # use DIV operator for integer division
query I rowsort label-6702
SELECT + col1 * - col0 DIV - cor0.col0 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-6702
SELECT + col1 * - col0 / - cor0.col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT tab2.col2 * - ( col0 * + tab2.col0 ) AS col1 FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT col1 * + col0 + - col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT DISTINCT + col2 + + 8 AS col0 FROM tab0 AS cor0
----
41
9
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6706
SELECT ALL - - CAST( - col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-6706
SELECT ALL - - CAST ( - col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 86 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 9ac806793c03d3a6b5e3a3029d20e4da

query I rowsort
SELECT - + ( - col2 ) * + col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT 33 FROM tab0, tab1 cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT DISTINCT 56 AS col0 FROM tab1
----
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-6711
SELECT ALL + col0 + 39 DIV - cor0.col1 AS col1 FROM tab2 AS cor0
----
6
77
78

skipif mysql # not compatible
query I rowsort label-6711
SELECT ALL + col0 + 39 / - cor0.col1 AS col1 FROM tab2 AS cor0
----
6
77
78

query I rowsort
SELECT - col0 * cor0.col2 + - col0 + col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT col0 * - ( - col2 ) FROM tab2 cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + col0 col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT col0 * - cor0.col2 + + ( col2 ) FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT ALL + + col2 * col0 + + ( col0 ) * ( + 49 ) AS col0 FROM tab0 AS cor0
----
11659
1750
1968

query I rowsort
SELECT DISTINCT - col2 * col1 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6718
SELECT col1 + - 70 DIV + col1 + col1 FROM tab1 AS cor0
----
13
21
50

skipif mysql # not compatible
query I rowsort label-6718
SELECT col1 + - 70 / + col1 + col1 FROM tab1 AS cor0
----
13
21
50

query I rowsort
SELECT - col0 * cor0.col1 * col2 + + col1 * 97 FROM tab2 AS cor0
----
-113929
-2852
-49385

query I rowsort
SELECT DISTINCT - 21 AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
-21

query I rowsort
SELECT DISTINCT - col2 * + col1 + col2 * - ( col2 ) FROM tab2
----
-1566
-2090
-2210

onlyif mysql # use DIV operator for integer division
query I rowsort label-6722
SELECT DISTINCT + col0 + col2 DIV 56 FROM tab1 AS cor0
----
3
65
81

skipif mysql # not compatible
query I rowsort label-6722
SELECT DISTINCT + col0 + col2 / 56 FROM tab1 AS cor0
----
3
65
81

query I rowsort
SELECT - cor1.col2 AS col1 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT ALL + 65 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 cor1, tab0 AS cor2
----
81 values hashing to 1654646feeae82f39d2f564fe4ea26c2

query I rowsort
SELECT DISTINCT col2 + - ( 7 ) FROM tab1 AS cor0
----
47
50
89

query I rowsort
SELECT ALL - col1 * + ( - 31 ) FROM tab1 cor0
----
310
403
806

query I rowsort
SELECT + + 87 AS col2 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT - col2 + + 30 FROM tab1
----
-24
-27
-66

query I rowsort
SELECT 77 * cor0.col0 - col2 * col0 AS col0 FROM tab2 AS cor0
----
3081
350
3978

query I rowsort
SELECT DISTINCT - - cor0.col1 * + col0 + ( - 52 ) AS col0 FROM tab1 AS cor0
----
26
588
988

query I rowsort
SELECT DISTINCT col2 - - 66 FROM tab2
----
104
92
93

query I rowsort
SELECT - 59 + + col0 FROM tab1 AS cor0
----
-56
21
5

query I rowsort
SELECT DISTINCT + 43 + + tab1.col1 * 45 + - col1 * - col2 * + 26 FROM tab1
----
15313
33076
37717

query I rowsort
SELECT DISTINCT + col1 + - col2 AS col0 FROM tab2
----
-21
33
4

query I rowsort
SELECT ALL 60 - cor0.col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 0191b046395faff4543d5cccd81247ed

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6736
SELECT ALL 34 + + col2 + CAST( - cor0.col1 AS SIGNED ) * - col0 FROM tab0 AS cor0
----
2131
3430
8215

skipif mysql # not compatible
query I rowsort label-6736
SELECT ALL 34 + + col2 + CAST ( - cor0.col1 AS INTEGER ) * - col0 FROM tab0 AS cor0
----
2131
3430
8215

query I rowsort
SELECT col1 * - col2 * col2 + - col1 FROM tab2 cor0
----
-22630
-24565
-39943

query I rowsort
SELECT col0 + - cor0.col0 AS col1 FROM tab0 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6739
SELECT DISTINCT - col0 DIV col2 + col1 - - 93 FROM tab1 cor0
----
102
106
119

skipif mysql # not compatible
query I rowsort label-6739
SELECT DISTINCT - col0 / col2 + col1 - - 93 FROM tab1 cor0
----
102
106
119

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6740
SELECT ALL - + col2 * + cor0.col1 + CAST( col0 AS SIGNED ) * + col0 col2 FROM tab1 AS cor0
----
-1395
3526
5152

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6740
SELECT ALL - + col2 * + cor0.col1 + CAST ( col0 AS INTEGER ) * + col0 col2 FROM tab1 AS cor0
----
-1395
3526
5152

query I rowsort
SELECT DISTINCT cor0.col0 AS col2 FROM tab2, tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL col2 + col2 * 55 * + col0 AS col1 FROM tab0
----
1926
401472
43593

onlyif mysql # use DIV operator for integer division
query I rowsort label-6743
SELECT ALL + tab0.col1 DIV col1 + + col2 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-6743
SELECT ALL + tab0.col1 / col1 + + col2 FROM tab0
----
2
34
83

query I rowsort
SELECT DISTINCT - 48 FROM tab2 AS cor0
----
-48

onlyif mysql # use DIV operator for integer division
query I rowsort label-6745
SELECT + col1 DIV - col1 + col1 * col1 - col1 * - 44 FROM tab0 AS cor0
----
11179
12284
13676

skipif mysql # not compatible
query I rowsort label-6745
SELECT + col1 / - col1 + col1 * col1 - col1 * - 44 FROM tab0 AS cor0
----
11179
12284
13676

query I rowsort
SELECT - - 43 * + col2 FROM tab2 AS cor0
----
1118
1161
1634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col2 * - 67 col0 FROM tab0
----
-2244
-5576
-68

query I rowsort
SELECT + - 11 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 05cc989122d7724c7abefaba9625ef3d

query I rowsort
SELECT ALL - 52 + + col1 AS col1 FROM tab0
----
34
39
45

query I rowsort
SELECT - ( + col1 ) * + col2 + + 47 AS col1 FROM tab2 AS cor0
----
-1487
-599
-790

query I rowsort
SELECT + + col2 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT col1 * col2 + - 68 FROM tab1 AS cor0
----
1180
1336
502

query I rowsort
SELECT + - col2 * + 51 + + 63 * + col0 * + col2 FROM tab1 AS cor0
----
226917
478944
7452

query I rowsort
SELECT DISTINCT - col1 + + 2 * - 48 FROM tab0 cor0
----
-182
-187
-193

query I rowsort
SELECT DISTINCT col2 + - col0 * - col1 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT DISTINCT + + col2 + + ( - 88 ) FROM tab1 AS cor0
----
-31
-34
8

query I rowsort
SELECT ALL col1 + + 60 AS col2 FROM tab0 cor0
----
146
151
157

query I rowsort
SELECT + + col1 + - col1 * col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT + - col0 + 25 FROM tab0 AS cor0
----
-10
-64
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6760
SELECT + cor0.col1 DIV - col0 + + col0 * col1 * + ( - col1 ) AS col2 FROM tab0 AS cor0
----
-177507
-329317
-737010

skipif mysql # not compatible
query I rowsort label-6760
SELECT + cor0.col1 / - col0 + + col0 * col1 * + ( - col1 ) AS col2 FROM tab0 AS cor0
----
-177507
-329317
-737010

query I rowsort
SELECT ALL + - col1 * ( 98 ) - - cor0.col0 FROM tab0 AS cor0
----
-8404
-8829
-9471

query I rowsort
SELECT - cor0.col1 - col0 * - 6 FROM tab1 AS cor0
----
-8
374
467

query I rowsort
SELECT ALL 58 * - col2 AS col1 FROM tab0 AS cor0
----
-1914
-4756
-58

query I rowsort
SELECT ALL 8 + col2 FROM tab2 cor0
----
34
35
46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - col2 ) col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT col0 + - col2 * tab2.col2 AS col2 FROM tab2
----
-1365
-598
-722

query I rowsort
SELECT DISTINCT - cor0.col0 + tab0.col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 61ad3e51e9dd48475950e1fb3eb814f6

query I rowsort
SELECT DISTINCT + 32 * - col0 FROM tab1
----
-2048
-2560
-96

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + CAST ( - cor0.col2 AS REAL ) FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( 48 ) * + cor0.col2 col2 FROM tab2 AS cor0
----
-1248
-1296
-1824

query I rowsort
SELECT DISTINCT 63 FROM tab0, tab1 AS cor0
----
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 40 col0 FROM tab2 AS cor0
----
-40

query I rowsort
SELECT cor1.col2 AS col0 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT - 64 * + col2 AS col2 FROM tab1 AS cor0
----
-3456
-3648
-6144

query I rowsort
SELECT 44 * + 41 AS col2 FROM tab2 AS cor0
----
1804
1804
1804

query I rowsort
SELECT DISTINCT - cor0.col1 * - 71 * col2 AS col2 FROM tab1 AS cor0
----
40470
88608
99684

query I rowsort
SELECT DISTINCT 99 * 60 FROM tab2 AS cor0
----
5940

query I rowsort
SELECT ALL - cor0.col1 AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT ( 25 ) + - col2 FROM tab1
----
-29
-32
-71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6780
SELECT ALL col1 * + col1 + + CAST( col2 + - col0 AS SIGNED ) * 98 AS col2 FROM tab0 AS cor0
----
6077
7595
8278

skipif mysql # not compatible
query I rowsort label-6780
SELECT ALL col1 * + col1 + + CAST ( col2 + - col0 AS INTEGER ) * 98 AS col2 FROM tab0 AS cor0
----
6077
7595
8278

query I rowsort
SELECT DISTINCT + + 48 AS col0 FROM tab2 AS cor0
----
48

query I rowsort
SELECT ALL - 96 + col2 AS col0 FROM tab2 cor0
----
-58
-69
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 99 + col1 col1 FROM tab0 AS cor0
----
185
190
196

query I rowsort
SELECT DISTINCT - + 1 + col0 - + col2 FROM tab0 AS cor0
----
-10
33
6

query I rowsort
SELECT ALL 16 * 79 AS col2 FROM tab0
----
1264
1264
1264

query I rowsort
SELECT ALL col1 * col1 * tab0.col0 AS col2 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT ALL col2 * + 85 AS col1 FROM tab2
----
2210
2295
3230

query I rowsort
SELECT + col0 * cor0.col0 * cor0.col2 + ( col0 + + col0 ) FROM tab1 AS cor0
----
233600
492
614560

query I rowsort
SELECT + + col1 * + col2 + - col0 + cor0.col1 * cor0.col2 FROM tab1 AS cor0
----
1076
2416
2805

query I rowsort
SELECT - 11 + + cor0.col1 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to fdf9d557934fdc8592893293eff5103b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6791
SELECT - CAST( NULL AS SIGNED ) - col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6791
SELECT - CAST ( NULL AS INTEGER ) - col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + 84 + + col0 col0 FROM tab2 AS cor0
----
240
242
98

query I rowsort
SELECT + + col0 * - col1 + col2 AS col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT - - ( + cor0.col1 ) + col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + col0 * 81 FROM tab2 AS cor0
----
567
6318
6399

onlyif mysql # use DIV operator for integer division
query I rowsort label-6796
SELECT col2 DIV - col0 + col2 FROM tab0
----
1
32
82

skipif mysql # not compatible
query I rowsort label-6796
SELECT col2 / - col0 + col2 FROM tab0
----
1
32
82

query I rowsort
SELECT ALL + 63 FROM tab0 cor0
----
63
63
63

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 cor0, tab1 AS cor1, tab1, tab2 AS cor2
----
3645 values hashing to b6efe6f7ec1a3daa3cc6ea9dd7d13455

query I rowsort
SELECT DISTINCT - col2 * col1 * col2 FROM tab0
----
-611884
-93654
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6800
SELECT DISTINCT - col2 DIV - cor0.col2 AS col2 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-6800
SELECT DISTINCT - col2 / - cor0.col2 AS col2 FROM tab1 AS cor0
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6801
SELECT DISTINCT cor0.col0 * - CAST( NULL AS SIGNED ) + col1 * col2 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6801
SELECT DISTINCT cor0.col0 * - CAST ( NULL AS INTEGER ) + col1 * col2 FROM tab1 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + col2 * col2 * + cor0.col1 col1 FROM tab1 AS cor0
----
119728
32426
75813

query I rowsort
SELECT ALL - - col0 * - col2 + - 90 * cor0.col2 AS col2 FROM tab0 AS cor0
----
-125
-14678
-3762

query I rowsort
SELECT - cor0.col0 + col0 * - col0 AS col0 FROM tab1 AS cor0
----
-12
-4160
-6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 - - col2 col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT col2 * ( - cor0.col2 ) FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT - col1 * - 81 AS col2 FROM tab1 AS cor0
----
1053
2106
810

query I rowsort
SELECT ALL + - cor0.col1 * - 64 + - col1 FROM tab0 AS cor0
----
5418
5733
6111

query I rowsort
SELECT ALL - 43 AS col1 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to ab0c314d2b589ccedb9a875beeb1f86a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6810
SELECT col0 + CAST( NULL AS SIGNED ) * ( cor0.col0 * col0 ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6810
SELECT col0 + CAST ( NULL AS INTEGER ) * ( cor0.col0 * col0 ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - tab1.col0 * ( + 41 ) + col0 AS col0 FROM tab1
----
-120
-2560
-3200

query I rowsort
SELECT + col1 * - 17 * col0 + + tab0.col0 * ( + col1 ) FROM tab0
----
-129584
-33024
-54320

query I rowsort
SELECT 96 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT DISTINCT 82 FROM tab0, tab0 cor0
----
82

query I rowsort
SELECT - - cor0.col0 * col0 AS col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - cor0.col1 * cor0.col2 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * + col0 col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT col2 * col2 * col2 FROM tab0 AS cor0
----
1
35937
551368

query I rowsort
SELECT 8 + - col1 * col1 FROM tab0 AS cor0
----
-7388
-8273
-9401

query I rowsort
SELECT DISTINCT col0 * - ( + col1 ) AS col1 FROM tab1
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 27 + + col2 col2 FROM tab0 AS cor0
----
-26
55
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6822
SELECT - CAST( - col2 AS SIGNED ) + + col0 FROM tab1 AS cor0
----
121
176
57

skipif mysql # not compatible
query I rowsort label-6822
SELECT - CAST ( - col2 AS INTEGER ) + + col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL - col2 + 52 AS col1 FROM tab0 AS cor0
----
-30
19
51

query I rowsort
SELECT DISTINCT - cor0.col1 + col1 * + cor0.col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT DISTINCT - 28 * col1 AS col0 FROM tab0 AS cor0
----
-2408
-2548
-2716

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col0 col1 FROM tab0 cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * cor0.col1 + col1 col2 FROM tab2 cor0
----
1360
248
4661

query I rowsort
SELECT - 45 AS col1 FROM tab2
----
-45
-45
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-6829
SELECT + col2 DIV + col1 + 31 DIV col0 + col0 * col0 FROM tab2 AS cor0
----
53
6084
6243

skipif mysql # not compatible
query I rowsort label-6829
SELECT + col2 / + col1 + 31 / col0 + col0 * col0 FROM tab2 AS cor0
----
53
6084
6243

query I rowsort
SELECT - - 2 FROM tab2 cor0
----
2
2
2

query I rowsort
SELECT - - 41 + col0 FROM tab1 AS cor0
----
105
121
44

query I rowsort
SELECT - col1 + tab0.col1 AS col2 FROM tab0
----
0
0
0

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 cor0, tab0 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to 181d902c42955a43a374f13a73d8b0a1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6834
SELECT + col2 + - CAST( NULL AS DECIMAL ) * - col2 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6834
SELECT + col2 + - CAST ( NULL AS REAL ) * - col2 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 10 * - col1 FROM tab0
----
-860
-910
-970

query I rowsort
SELECT + tab2.col2 + - col2 + - col0 AS col0 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT DISTINCT col1 + - col1 * col2 FROM tab1 cor0
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-6838
SELECT DISTINCT + col1 + col2 DIV + col0 + - col1 * col0 FROM tab2
----
-1326
-183
-4543

skipif mysql # not compatible
query I rowsort label-6838
SELECT DISTINCT + col1 + col2 / + col0 + - col1 * col0 FROM tab2
----
-1326
-183
-4543

query I rowsort
SELECT col0 + col2 * + col1 FROM tab1
----
1328
1407
634

onlyif mysql # use DIV operator for integer division
query I rowsort label-6840
SELECT - col0 DIV col0 + col2 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-6840
SELECT - col0 / col0 + col2 FROM tab0
----
0
32
81

query I rowsort
SELECT ALL 11 AS col0 FROM tab0 AS cor0
----
11
11
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 27 + cor0.col1 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 448aa4b975eb2a1a6146022537ad7dbd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + + cor0.col2 col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + ( col1 ) + - cor0.col2 AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL - cor0.col1 * - 42 AS col1 FROM tab2 AS cor0
----
1302
2478
714

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * cor0.col1 + col0 col0 FROM tab1 cor0
----
-36
-673
-89

query I rowsort
SELECT col2 * col2 + 75 FROM tab2 cor0
----
1519
751
804

query I rowsort
SELECT - col0 * + cor0.col1 * + 80 + + col0 AS col0 FROM tab1 AS cor0
----
-51136
-6237
-83120

query I rowsort
SELECT DISTINCT cor0.col0 * - 28 + col1 FROM tab2 AS cor0
----
-165
-2125
-2195

query I rowsort
SELECT col2 * - cor0.col1 * + col0 + col0 * cor0.col2 FROM tab1 AS cor0
----
-32832
-4050
-92160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6851
SELECT DISTINCT cor0.col2 * CAST( 91 AS SIGNED ) + + col1 AS col1 FROM tab0 AS cor0
----
188
3089
7553

skipif mysql # not compatible
query I rowsort label-6851
SELECT DISTINCT cor0.col2 * CAST ( 91 AS INTEGER ) + + col1 AS col1 FROM tab0 AS cor0
----
188
3089
7553

query I rowsort
SELECT - col1 * + ( - col1 * cor0.col2 ) + ( cor0.col2 ) * + col2 AS col1 FROM tab2 AS cor0
----
12426
26676
91182

query I rowsort
SELECT + - col0 + + ( col0 ) AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col2 + col1 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT DISTINCT + cor0.col2 * - tab2.col0 FROM tab2, tab0, tab1 AS cor0
----
9 values hashing to 99e52647357b835698a6730896ff820d

query I rowsort
SELECT ALL - 51 + - col1 * col0 AS col2 FROM tab2
----
-1394
-268
-4653

query I rowsort
SELECT - col0 * - col1 AS col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT + ( tab2.col1 ) FROM tab2, tab2 AS cor0, tab2 cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT col2 * + ( + col0 ) + + col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT + 93 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 85ef191bf1b307f300b3fd49992fcae7

query I rowsort
SELECT + ( 87 ) AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

query I rowsort
SELECT ALL - 84 + + tab2.col1 FROM tab2
----
-25
-53
-67

query I rowsort
SELECT DISTINCT col1 AS col0 FROM tab2 WHERE col1 NOT IN ( tab2.col1 + col0 )
----
17
31
59

query I rowsort
SELECT DISTINCT col2 * tab0.col2 AS col1 FROM tab0 WHERE NOT ( NULL ) >= NULL
----

query I rowsort
SELECT DISTINCT col1 - col1 * + tab1.col1 FROM tab1 WHERE ( col0 ) BETWEEN NULL AND ( col1 + + col2 * col0 )
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL IN ( col0 + col2 )
----

query I rowsort
SELECT DISTINCT + col1 * col2 * - col2 - - col2 FROM tab1
----
-119712
-32433
-75762

query I rowsort
SELECT DISTINCT + col0 AS col1 FROM tab1 WHERE NULL < NULL
----

query I rowsort
SELECT DISTINCT - col2 + - tab2.col0 * col2 FROM tab2
----
-2054
-216
-3040

query I rowsort
SELECT DISTINCT col1 * - tab2.col2 / col1 FROM tab2 WHERE NULL <= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6871
SELECT - col2 + + tab2.col1 DIV col0 AS col1 FROM tab2
----
-23
-26
-38

skipif mysql # not compatible
query I rowsort label-6871
SELECT - col2 + + tab2.col1 / col0 AS col1 FROM tab2
----
-23
-26
-38

query I rowsort
SELECT ALL - tab0.col1 + - col0 * col1 FROM tab0
----
-2150
-3492
-8190

query I rowsort
SELECT col2 * col2 AS col2 FROM tab1 WHERE NOT ( col0 ) IN ( + col2 * - col0 )
----
2916
3249
9216

query III rowsort
SELECT ALL * FROM tab1 WHERE - col1 - col0 < col0
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT tab0.col0 * - col2 AS col0 FROM tab0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col1 + col0 + col2 col2 FROM tab1
----
131
189
83

query I rowsort
SELECT + col1 * cor0.col0 * ( col0 ) + + col1 * col2 AS col1 FROM tab2 AS cor0
----
106743
2356
360490

query I rowsort
SELECT DISTINCT 91 AS col2 FROM tab0 cor0
----
91

query I rowsort
SELECT DISTINCT + col0 * + col0 + - 82 + + col0 * col2 FROM tab0 AS cor0
----
1178
1286
15137

onlyif mysql # use DIV operator for integer division
query I rowsort label-6880
SELECT ALL + 90 * - col0 + 6 DIV col0 FROM tab2 AS cor0
----
-630
-7020
-7110

skipif mysql # not compatible
query I rowsort label-6880
SELECT ALL + 90 * - col0 + 6 / col0 FROM tab2 AS cor0
----
-630
-7020
-7110

query I rowsort
SELECT + cor0.col0 + cor0.col0 AS col0 FROM tab2 cor0
----
14
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-6882
SELECT + col0 * col2 DIV - col2 + col2 AS col1 FROM tab0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-6882
SELECT + col0 * col2 / - col2 + col2 AS col1 FROM tab0
----
-34
-7
9

query I rowsort
SELECT DISTINCT - col1 * - col0 - col1 * - col2 FROM tab0 AS cor0
----
15561
3492
4902

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL NOT IN ( - col0 )
----

query I rowsort
SELECT DISTINCT - tab1.col0 - + col1 * + col0 FROM tab1
----
-1120
-704
-81

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( col0 ) BETWEEN NULL AND + col0
----

query I rowsort
SELECT tab0.col2 + + tab0.col0 AS col1 FROM tab0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6888
SELECT + col0 DIV + cor0.col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6888
SELECT + col0 / + cor0.col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT + + 93 * - col2 * col1 FROM tab0 AS cor0
----
-263934
-693966
-9021

query I rowsort
SELECT ALL cor0.col0 + col0 AS col0 FROM tab0 AS cor0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col2 ) * col2 col0 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT - 60 AS col0 FROM tab0 cor0
----
-60
-60
-60

query I rowsort
SELECT ALL ( - tab0.col2 * tab0.col1 ) FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - 21 AS col1 FROM tab0
----
-21
-21
-21

query I rowsort
SELECT ALL + ( tab0.col2 * col2 + + col2 ) FROM tab0
----
1122
2
6806

onlyif mysql # use DIV operator for integer division
query I rowsort label-6896
SELECT ALL - col2 DIV col1 + - 37 DIV col2 + col1 AS col0 FROM tab0
----
60
85
91

skipif mysql # not compatible
query I rowsort label-6896
SELECT ALL - col2 / col1 + - 37 / col2 + col1 AS col0 FROM tab0
----
60
85
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 32 col0 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ef8f93119983b962f4c81381ebf4b1e6

query I rowsort
SELECT ALL ( col1 ) + col2 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - + col2 * + cor0.col0 * - col1 FROM tab0 cor0
----
3395
664118
68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 * tab1.col1 col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + - cor0.col1 * 33 AS col1 FROM tab1 AS cor0
----
-330
-429
-858

onlyif mysql # use DIV operator for integer division
query I rowsort label-6902
SELECT ALL - - cor0.col1 * - ( - 91 ) - col2 DIV 24 FROM tab0 AS cor0
----
7825
8278
8827

skipif mysql # not compatible
query I rowsort label-6902
SELECT ALL - - cor0.col1 * - ( - 91 ) - col2 / 24 FROM tab0 AS cor0
----
7825
8278
8827

query I rowsort
SELECT DISTINCT col1 * - col0 * + col2 AS col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT + col2 + + col2 * col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT - + col1 * 61 AS col0 FROM tab2 AS cor0
----
-1037
-1891
-3599

onlyif mysql # use DIV operator for integer division
query I rowsort label-6906
SELECT col1 DIV 34 + - col2 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-6906
SELECT col1 / 34 + - col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ALL + 70 * cor0.col1 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to be00591f9886d7eb84584586c1406373

query I rowsort
SELECT DISTINCT + col0 * - col1 + col1 AS col2 FROM tab1 cor0
----
-1027
-52
-630

query I rowsort
SELECT ALL + 27 * col2 AS col2 FROM tab0
----
2214
27
891

query I rowsort
SELECT DISTINCT + + 27 * - col0 AS col1 FROM tab1 AS cor0
----
-1728
-2160
-81

query I rowsort
SELECT ALL + + col0 - cor0.col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 93 AS col0 FROM tab0, tab2 cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 88 col2 FROM tab2 AS cor0
----
88
88
88

query I rowsort
SELECT 92 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to cfcf012ce1a8dd60a7428b4ef6b95843

query I rowsort
SELECT ALL + 41 FROM tab0 cor0
----
41
41
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-6916
SELECT ALL - - col2 DIV ( + col0 ) + - ( - col1 ) * - col1 * 84 FROM tab1 cor0
----
-14195
-56766
-8400

skipif mysql # not compatible
query I rowsort label-6916
SELECT ALL - - col2 / ( + col0 ) + - ( - col1 ) * - col1 * 84 FROM tab1 cor0
----
-14195
-56766
-8400

query I rowsort
SELECT - 6 * col2 AS col2 FROM tab1 cor0
----
-324
-342
-576

query I rowsort
SELECT DISTINCT + + col0 + col1 + col2 AS col1 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT DISTINCT + col1 + col1 * + col1 * - col0 FROM tab2 AS cor0
----
-22814
-271459
-6696

query I rowsort
SELECT cor0.col2 + - col1 + - col0 * + cor0.col2 FROM tab2 AS cor0
----
-193
-2061
-2981

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + col2 * + col0 * col0 col1 FROM tab1 cor0
----
233529
540
614496

query I rowsort
SELECT 53 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT + 35 AS col2 FROM tab1 cor0
----
35
35
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 87 col1 FROM tab2
----
-87
-87
-87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 70 + - tab2.col2 col1 FROM tab2, tab1 AS cor0
----
32
43
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-6926
SELECT DISTINCT 40 DIV + col0 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-6926
SELECT DISTINCT 40 / + col0 FROM tab0
----
0
1

query I rowsort
SELECT ALL - - 70 AS col1 FROM tab0 AS cor0
----
70
70
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 + - cor0.col2 * - col0 + - col2 * col0 col0 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT - cor0.col1 + + 96 + + col0 * + col2 AS col2 FROM tab1 cor0
----
232
3734
7763

query I rowsort
SELECT DISTINCT 47 * - col1 FROM tab1
----
-1222
-470
-611

query I rowsort
SELECT DISTINCT col1 * col2 * - cor0.col1 - col1 * col1 * col0 FROM tab2 AS cor0
----
-32674
-33813
-362024

query I rowsort
SELECT col2 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT tab2.col1 FROM tab2 WHERE NULL < col1
----

query I rowsort
SELECT tab1.col0 + tab1.col1 AS col0 FROM tab1
----
29
74
93

query III rowsort
SELECT * FROM tab1 WHERE NOT - col0 <> NULL
----

query I rowsort
SELECT DISTINCT col1 * + col2 FROM tab0 WHERE NULL < NULL
----

query I rowsort
SELECT tab1.col1 + col2 * col0 FROM tab1
----
188
3658
7693

query I rowsort
SELECT - col1 * - col0 + col1 - + col2 * + tab2.col1 * + col2 FROM tab2
----
-22351
-23188
-35223

query I rowsort
SELECT DISTINCT cor0.col1 + + col2 * - col2 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT + col2 AS col2 FROM tab0 WHERE NOT + col0 NOT IN ( + col0 / col1 )
----

query I rowsort
SELECT ALL + col2 * - col0 FROM tab2 AS cor0 WHERE col2 = NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6942
SELECT - col1 DIV + col0 AS col2 FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-6942
SELECT - col1 / + col0 AS col2 FROM tab0
----
-1
-2
-3

query I rowsort
SELECT col2 + + cor0.col2 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT ALL - tab2.col0 - + tab2.col0 AS col0 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT + col1 + - col0 + - col0 AS col2 FROM tab1
----
-118
-147
20

query I rowsort
SELECT ALL tab2.col1 - col2 * - col1 * col1 AS col1 FROM tab2
----
10999
25978
90565

query I rowsort
SELECT ALL + col0 * col1 - col2 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT DISTINCT - tab0.col1 - + col0 AS col1 FROM tab0
----
-110
-132
-180

query I rowsort
SELECT + + cor0.col1 + + col0 * col2 * col0 AS col2 FROM tab1 AS cor0
----
233482
512
614413

query I rowsort
SELECT + col0 + + col1 * + col1 + + col2 * - col1 AS col1 FROM tab2 cor0
----
-278
131
2025

query I rowsort
SELECT ALL - col1 + cor0.col2 AS col0 FROM tab1 AS cor0
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * cor0.col0 * col2 + col2 col0 FROM tab2 AS cor0
----
-1296
-158158
-237120

query I rowsort
SELECT DISTINCT col1 * + col2 + + col0 - col1 * col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + col2 - col1 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT + cor0.col0 * - col1 + col0 * + cor0.col2 FROM tab2 AS cor0
----
-2574
-28
1659

query I rowsort
SELECT - col2 + - col2 AS col0 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT ALL col2 * + col0 + col1 * - col2 FROM tab2 AS cor0
----
-648
2356
494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * col0 col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT + 41 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT DISTINCT 23 FROM tab0, tab0 cor0
----
23

query I rowsort
SELECT DISTINCT - col2 * + ( - col1 ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - ( + 91 ) AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 745d1c3a09d935465cad552325c5c945

query I rowsort
SELECT DISTINCT - 38 AS col0 FROM tab2, tab2 AS cor0
----
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6964
SELECT + CAST( + 83 AS SIGNED ) * cor0.col1 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 21ef298eb031fd9f51dd01b458df836a

skipif mysql # not compatible
query I rowsort label-6964
SELECT + CAST ( + 83 AS INTEGER ) * cor0.col1 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 21ef298eb031fd9f51dd01b458df836a

query I rowsort
SELECT DISTINCT + cor0.col2 + col2 + col0 * col1 * + 33 AS col0 FROM tab1 AS cor0
----
21234
2682
34512

query I rowsort
SELECT ALL + + 43 FROM tab1 AS cor0
----
43
43
43

query I rowsort
SELECT col2 + 7 * col0 AS col1 FROM tab2 cor0
----
572
591
76

query I rowsort
SELECT ALL - + 70 + 83 AS col0 FROM tab2 AS cor0
----
13
13
13

query I rowsort
SELECT + col0 * col0 * + col2 + col2 FROM tab1 AS cor0
----
233529
540
614496

query I rowsort
SELECT + - 55 FROM tab2 cor0
----
-55
-55
-55

query I rowsort
SELECT ALL - - 5 * col2 + - col0 FROM tab1 AS cor0
----
221
267
400

query I rowsort
SELECT - 67 * col2 + col0 FROM tab2 AS cor0
----
-1664
-1802
-2467

query I rowsort
SELECT DISTINCT ( + tab0.col0 ) + col1 AS col2 FROM tab0
----
110
132
180

query I rowsort
SELECT DISTINCT cor0.col0 * col2 + col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT + col0 * + col0 + col1 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT + 58 - 55 * col0 FROM tab1 AS cor0
----
-107
-3462
-4342

query I rowsort
SELECT DISTINCT + - 39 - - col0 FROM tab1 AS cor0
----
-36
25
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-6978
SELECT col2 + + col1 DIV - cor0.col0 FROM tab0 AS cor0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-6978
SELECT col2 + + col1 / - cor0.col0 FROM tab0 AS cor0
----
-1
30
81

query I rowsort
SELECT 88 * 78 - - cor0.col1 FROM tab2 cor0
----
6881
6895
6923

query I rowsort
SELECT DISTINCT 15 - - cor0.col0 FROM tab2 AS cor0
----
22
93
94

query I rowsort
SELECT + col1 * col1 - col1 AS col1 FROM tab1 cor0
----
156
650
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6982
SELECT ALL col0 DIV col1 - col2 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-6982
SELECT ALL col0 / col1 - col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT + col0 + + 73 * + col1 FROM tab0 AS cor0
----
6302
6732
7116

query I rowsort
SELECT ALL col2 + + 20 + col1 AS col2 FROM tab2 AS cor0
----
105
75
78

query I rowsort
SELECT ALL - ( col1 ) * - cor0.col1 AS col1 FROM tab0 cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + col0 col1 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-6987
SELECT ALL + cor0.col1 DIV 80 + - col2 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-6987
SELECT ALL + cor0.col1 / 80 + - col2 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6988
SELECT DISTINCT - - CAST( NULL AS SIGNED ) * + ( col1 ) - col0 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6988
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) * + ( col1 ) - col0 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + - col1 * + col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6990
SELECT DISTINCT tab2.col1 DIV + tab2.col1 AS col1 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-6990
SELECT DISTINCT tab2.col1 / + tab2.col1 AS col1 FROM tab2
----
1

query I rowsort
SELECT + tab2.col0 FROM tab2, tab1 cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ALL 60 AS col1 FROM tab0 cor0
----
60
60
60

query I rowsort
SELECT + col0 + - cor0.col0 + 23 FROM tab0 AS cor0
----
23
23
23

query I rowsort
SELECT DISTINCT - 98 * cor0.col2 AS col1 FROM tab1 AS cor0
----
-5292
-5586
-9408

query I rowsort
SELECT ALL - cor0.col2 + col2 + + col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT ( col0 ) * + 32 AS col0 FROM tab0 AS cor0
----
1120
2848
768

query I rowsort
SELECT ALL 10 + col0 * col0 AS col0 FROM tab0 cor0
----
1235
586
7931

query I rowsort
SELECT DISTINCT + cor0.col2 * - col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6999
SELECT DISTINCT + + ( col2 ) + + CAST( col2 AS SIGNED ) FROM tab0 AS cor0
----
164
2
66

skipif mysql # not compatible
query I rowsort label-6999
SELECT DISTINCT + + ( col2 ) + + CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL cor0.col2 * + col0 AS col0 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT + col1 + 79 * - col2 FROM tab1 AS cor0
----
-4240
-4493
-7571

query I rowsort
SELECT ALL + cor0.col2 + - col1 * + col0 AS col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 + + col1 * cor0.col0 col0 FROM tab1 cor0
----
104
1053
650

query I rowsort
SELECT ALL + - col1 * - col2 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7005
SELECT ALL - col1 * ( + col0 ) DIV - col2 FROM tab1 cor0
----
1
10
11

skipif mysql # not compatible
query I rowsort label-7005
SELECT ALL - col1 * ( + col0 ) / - col2 FROM tab1 cor0
----
1
10
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 52 * col2 col1 FROM tab2
----
1352
1404
1976

query I rowsort
SELECT + 78 * + col0 - + col1 FROM tab2
----
515
6025
6145

query I rowsort
SELECT DISTINCT + col1 * + col2 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
-611884
-93654
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7009
SELECT + col1 DIV col0 AS col0 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-7009
SELECT + col1 / col0 AS col0 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT ALL - col1 + cor0.col2 * col0 AS col1 FROM tab2 cor0
----
158
1969
2985

query I rowsort
SELECT DISTINCT - - col1 * 56 + col0 FROM tab2 AS cor0
----
1031
1743
3382

query I rowsort
SELECT col2 * 64 * - col0 FROM tab0 AS cor0
----
-2240
-467072
-50688

query I rowsort
SELECT DISTINCT - 22 + col0 FROM tab1
----
-19
42
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-7014
SELECT + - col2 DIV 16 FROM tab2 AS cor0
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-7014
SELECT + - col2 / 16 FROM tab2 AS cor0
----
-1
-1
-2

query I rowsort
SELECT - col0 * col1 * + col0 AS col1 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT col0 * ( col2 ) + - col1 AS col2 FROM tab2 cor0
----
158
1969
2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-7017
SELECT col0 DIV - 82 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7017
SELECT col0 / - 82 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 70 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7019
SELECT - + ( 22 ) + col1 / CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7019
SELECT - + ( 22 ) + col1 / CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7020
SELECT ALL + col1 / CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7020
SELECT ALL + col1 / CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-54
-57
-96

query I rowsort
SELECT - 4 FROM tab1, tab2 cor0
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

onlyif mysql # use DIV operator for integer division
query I rowsort label-7023
SELECT DISTINCT - + col0 DIV col2 + 16 * + col2 FROM tab1 AS cor0
----
1536
864
911

skipif mysql # not compatible
query I rowsort label-7023
SELECT DISTINCT - + col0 / col2 + 16 * + col2 FROM tab1 AS cor0
----
1536
864
911

query I rowsort
SELECT + col1 * col1 + + ( - ( cor0.col2 ) ) FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT ALL - 24 * + col2 - col1 AS col0 FROM tab1 AS cor0
----
-1322
-1378
-2317

query I rowsort
SELECT DISTINCT + ( - cor0.col0 ) FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-7027
SELECT - + 46 + + col1 DIV col0 + cor0.col2 AS col1 FROM tab2 AS cor0
----
-15
-20
-8

skipif mysql # not compatible
query I rowsort label-7027
SELECT - + 46 + + col1 / col0 + cor0.col2 AS col1 FROM tab2 AS cor0
----
-15
-20
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-7028
SELECT + 40 + col0 DIV col0 + + 45 FROM tab1 AS cor0
----
86
86
86

skipif mysql # not compatible
query I rowsort label-7028
SELECT + 40 + col0 / col0 + + 45 FROM tab1 AS cor0
----
86
86
86

query I rowsort
SELECT DISTINCT - - cor0.col2 * col1 + col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL + 88 + 82 FROM tab1
----
170
170
170

onlyif mysql # use DIV operator for integer division
query I rowsort label-7031
SELECT DISTINCT + 56 DIV col1 FROM tab2
----
0
1
3

skipif mysql # not compatible
query I rowsort label-7031
SELECT DISTINCT + 56 / col1 FROM tab2
----
0
1
3

query I rowsort
SELECT DISTINCT + - 71 + + col1 * + ( + cor0.col2 ) AS col2 FROM tab2 AS cor0
----
1463
575
766

query I rowsort
SELECT DISTINCT 37 * col0 + + 82 FROM tab1 AS cor0
----
193
2450
3042

onlyif mysql # use DIV operator for integer division
query I rowsort label-7034
SELECT ALL - 78 DIV col1 + col2 - - col2 FROM tab2 AS cor0
----
51
52
72

skipif mysql # not compatible
query I rowsort label-7034
SELECT ALL - 78 / col1 + col2 - - col2 FROM tab2 AS cor0
----
51
52
72

query I rowsort
SELECT DISTINCT - col1 * cor0.col0 + + 63 FROM tab2 AS cor0
----
-1280
-154
-4539

query I rowsort
SELECT ALL - col1 * + col2 AS col2 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT - 36 * 34 * - col0 AS col2 FROM tab0 AS cor0
----
108936
29376
42840

query I rowsort
SELECT - + col2 * - 44 AS col0 FROM tab1 AS cor0
----
2376
2508
4224

query I rowsort
SELECT ALL + ( + col2 ) + - col2 * col0 FROM tab2 AS cor0
----
-162
-2002
-2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + 86 ) * col1 + 17 col1 FROM tab1 AS cor0
----
-1101
-2219
-843

query I rowsort
SELECT + - 79 * - 13 * col0 FROM tab0 AS cor0
----
24648
35945
91403

query I rowsort
SELECT DISTINCT - cor0.col0 + cor0.col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + - cor0.col0 * - col1 * col2 AS col1 FROM tab0 AS cor0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-7044
SELECT DISTINCT col0 DIV 88 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-7044
SELECT DISTINCT col0 / 88 FROM tab1
----
0

query I rowsort
SELECT - cor0.col1 * - ( cor0.col0 ) + col2 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7046
SELECT + col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7046
SELECT + col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 + 23 FROM tab0 AS cor0
----
-10
-59
22

query I rowsort
SELECT - + col0 + - ( - col1 + col1 ) AS col1 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT - 75 * - col0 + + col0 AS col1 FROM tab0 AS cor0
----
1824
2660
6764

query I rowsort
SELECT - tab0.col1 * - ( + col1 ) + - tab0.col1 * col2 + - 88 AS col1 FROM tab0
----
4470
731
9224

query I rowsort
SELECT - 89 * - cor0.col2 FROM tab0 AS cor0
----
2937
7298
89

query I rowsort
SELECT cor0.col2 * + col0 AS col2 FROM tab2 cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 col1 FROM tab1, tab0, tab2 cor0
----
17
31
59

query I rowsort
SELECT ALL col2 * 80 FROM tab2
----
2080
2160
3040

query I rowsort
SELECT DISTINCT + col1 + col1 * col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT 87 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab1 AS cor2
----
87

query I rowsort
SELECT ALL 46 FROM tab2, tab0 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

onlyif mysql # use DIV operator for integer division
query I rowsort label-7058
SELECT + + 10 * + col1 + col1 DIV + col1 + + 84 * col0 AS col0 FROM tab0 AS cor0
----
2877
3911
8387

skipif mysql # not compatible
query I rowsort label-7058
SELECT + + 10 * + col1 + col1 / + col1 + + 84 * col0 AS col0 FROM tab0 AS cor0
----
2877
3911
8387

query I rowsort
SELECT 68 FROM tab0 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 7ff6433dda3248dce73040b2c590f3da

query I rowsort
SELECT ALL - cor0.col2 + + 16 * + col0 AS col2 FROM tab1 AS cor0
----
-6
1184
967

query I rowsort
SELECT + + col2 * - col0 + - col1 * + col2 FROM tab0 AS cor0
----
-132
-14760
-3630

query I rowsort
SELECT DISTINCT + 94 AS col2 FROM tab2, tab2 AS cor0
----
94

query I rowsort
SELECT DISTINCT ( + col2 ) + + col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT - col0 * + col1 * col1 AS col0 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT ( col1 ) + + col0 * col0 - - col2 FROM tab0
----
1323
695
8094

query I rowsort
SELECT + - col1 * - col1 + cor0.col0 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT DISTINCT + col0 + 78 + tab1.col1 AS col1 FROM tab1
----
107
152
171

onlyif mysql # use DIV operator for integer division
query I rowsort label-7068
SELECT - 99 DIV - col0 + col1 FROM tab0
----
90
92
99

skipif mysql # not compatible
query I rowsort label-7068
SELECT - 99 / - col0 + col1 FROM tab0
----
90
92
99

query I rowsort
SELECT col2 * 8 + - col1 AS col0 FROM tab2 AS cor0
----
149
185
287

onlyif mysql # use DIV operator for integer division
query I rowsort label-7070
SELECT ALL - col2 * cor0.col2 DIV 59 + col0 AS col2 FROM tab2 AS cor0
----
-5
55
67

skipif mysql # not compatible
query I rowsort label-7070
SELECT ALL - col2 * cor0.col2 / 59 + col0 AS col2 FROM tab2 AS cor0
----
-5
55
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7071
SELECT DISTINCT - col1 * - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7071
SELECT DISTINCT - col1 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7072
SELECT + col0 DIV - col1 AS col0 FROM tab1 AS cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-7072
SELECT + col0 / - col1 AS col0 FROM tab1 AS cor0
----
-6
-6
0

query I rowsort
SELECT ALL - - col0 + 37 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
-252
-2808
-2844

query I rowsort
SELECT DISTINCT 55 FROM tab1
----
55

query I rowsort
SELECT + + cor0.col1 * - 31 + - col2 AS col1 FROM tab2 cor0
----
-1855
-565
-988

query I rowsort
SELECT - + col0 * + cor0.col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - - col1 * col0 * ( col0 * ( col2 ) ) + - cor0.col0 AS col1 FROM tab2 cor0
----
4031607
41006
9332778

onlyif mysql # use DIV operator for integer division
query I rowsort label-7078
SELECT - - ( col0 ) + + col0 DIV + 76 FROM tab0 AS cor0
----
24
35
90

skipif mysql # not compatible
query I rowsort label-7078
SELECT - - ( col0 ) + + col0 / + 76 FROM tab0 AS cor0
----
24
35
90

query I rowsort
SELECT ALL col0 * - col1 + - 94 FROM tab1 AS cor0
----
-1134
-172
-734

query I rowsort
SELECT ALL col0 + - col2 * - col2 AS col0 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT ALL + 71 * col1 FROM tab0 AS cor0
----
6106
6461
6887

query I rowsort
SELECT ALL + 32 AS col1 FROM tab0
----
32
32
32

query I rowsort
SELECT ALL - col2 * + col2 * col2 FROM tab1
----
-157464
-185193
-884736

query I rowsort
SELECT DISTINCT - 93 FROM tab0 cor0
----
-93

query I rowsort
SELECT DISTINCT - + col2 * col0 + - col1 AS col0 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT DISTINCT - ( + col1 ) * cor0.col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - 23 * - col1 + ( + cor0.col2 ) * + col0 FROM tab0 AS cor0
----
2266
2770
9391

query I rowsort
SELECT DISTINCT col0 + tab1.col1 AS col2 FROM tab1
----
29
74
93

query I rowsort
SELECT ALL + 96 * + col0 - - col0 FROM tab0 AS cor0
----
2328
3395
8633

onlyif mysql # use DIV operator for integer division
query I rowsort label-7090
SELECT col1 + - 60 * 71 DIV col1 FROM tab0
----
37
45
54

skipif mysql # not compatible
query I rowsort label-7090
SELECT col1 + - 60 * 71 / col1 FROM tab0
----
37
45
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-7091
SELECT - tab1.col2 DIV - col1 + + 3 * - col2 AS col1 FROM tab1
----
-160
-166
-281

skipif mysql # not compatible
query I rowsort label-7091
SELECT - tab1.col2 / - col1 + + 3 * - col2 AS col1 FROM tab1
----
-160
-166
-281

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7092
SELECT + col0 * CAST( + col0 AS SIGNED ) + col0 + 84 FROM tab0
----
1344
684
8094

skipif mysql # not compatible
query I rowsort label-7092
SELECT + col0 * CAST ( + col0 AS INTEGER ) + col0 + 84 FROM tab0
----
1344
684
8094

query I rowsort
SELECT DISTINCT + col2 * tab1.col2 + col1 AS col2 FROM tab1
----
2942
3259
9229

query I rowsort
SELECT DISTINCT - col2 * + 53 + col1 AS col2 FROM tab2
----
-1319
-1400
-1997

query I rowsort
SELECT col1 * + ( ( col1 ) ) * + col0 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT DISTINCT - col0 + 47 AS col1 FROM tab1
----
-17
-33
44

query I rowsort
SELECT ALL ( + 95 ) * + col1 FROM tab0 cor0
----
8170
8645
9215

query I rowsort
SELECT 76 + col2 * - col1 AS col1 FROM tab1 AS cor0
----
-1172
-1328
-494

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - - CAST ( 79 AS REAL ) FROM tab0 cor0
----
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-7100
SELECT + 81 DIV + cor0.col2 FROM tab0 AS cor0
----
0
2
81

skipif mysql # not compatible
query I rowsort label-7100
SELECT + 81 / + cor0.col2 FROM tab0 AS cor0
----
0
2
81

query I rowsort
SELECT ALL + cor0.col1 + + col1 * - col2 + - 0 FROM tab2 AS cor0
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-7102
SELECT ALL - ( + col1 ) DIV cor0.col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7102
SELECT ALL - ( + col1 ) / cor0.col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 48 + - 36 FROM tab1 AS cor0
----
12

query I rowsort
SELECT ALL - + col2 + - col2 FROM tab2 cor0
----
-52
-54
-76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7105
SELECT DISTINCT - CAST( NULL AS SIGNED ) + ( cor0.col0 * - cor0.col1 ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7105
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + ( cor0.col0 * - cor0.col1 ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col0 * 78 AS col1 FROM tab0 AS cor0
----
-1872
-2730
-6942

onlyif mysql # use DIV operator for integer division
query I rowsort label-7107
SELECT - + cor0.col2 DIV - col0 + - col2 * col2 DIV 43 AS col1 FROM tab2 AS cor0
----
-13
-15
-33

skipif mysql # not compatible
query I rowsort label-7107
SELECT - + cor0.col2 / - col0 + - col2 * col2 / 43 AS col1 FROM tab2 AS cor0
----
-13
-15
-33

query I rowsort
SELECT DISTINCT - + 85 + 2 AS col1 FROM tab1 AS cor0
----
-83

query I rowsort
SELECT + cor0.col1 + 68 AS col1 FROM tab0 AS cor0
----
154
159
165

query I rowsort
SELECT DISTINCT - + 67 FROM tab0 AS cor0
----
-67

query I rowsort
SELECT - + 56 AS col1 FROM tab0 AS cor0
----
-56
-56
-56

query I rowsort
SELECT DISTINCT - col2 + 16 * col0 AS col1 FROM tab1 AS cor0
----
-6
1184
967

query I rowsort
SELECT ( - col1 ) + col1 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + ( - 33 ) FROM tab2
----
-33
-33
-33

query I rowsort
SELECT ALL + 65 AS col2 FROM tab2
----
65
65
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 0 + - ( - col2 ) col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT ( + col1 ) AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + + col1 + cor0.col0 * + col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT + col1 * col0 + col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT - col2 + col1 * + 94 FROM tab2 AS cor0
----
1560
2887
5520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 50 col2 FROM tab1
----
50

query I rowsort
SELECT DISTINCT - + col1 + - col0 - col2 * + col0 AS col2 FROM tab2 AS cor0
----
-2165
-227
-3098

query I rowsort
SELECT + - col1 + - ( + col0 ) AS col2 FROM tab1 AS cor0
----
-29
-74
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + 97 * - cor0.col0 col2 FROM tab1 cor0
----
-237
-6151
-7664

query I rowsort
SELECT DISTINCT + + col2 + - 39 AS col0 FROM tab0 cor0
----
-38
-6
43

query I rowsort
SELECT - - cor0.col2 * - 14 - 75 FROM tab2 AS cor0
----
-439
-453
-607

onlyif mysql # use DIV operator for integer division
query I rowsort label-7127
SELECT ALL - + cor0.col1 DIV - col0 + 65 AS col2 FROM tab1 AS cor0
----
65
65
73

skipif mysql # not compatible
query I rowsort label-7127
SELECT ALL - + cor0.col1 / - col0 + 65 AS col2 FROM tab1 AS cor0
----
65
65
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7128
SELECT DISTINCT - col0 + - CAST( NULL AS SIGNED ) - - col2 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7128
SELECT DISTINCT - col0 + - CAST ( NULL AS INTEGER ) - - col2 AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + col0 * - col1 + + 9 AS col0 FROM tab2 AS cor0
----
-1334
-208
-4593

onlyif mysql # use DIV operator for integer division
query I rowsort label-7130
SELECT ALL col1 + - col2 DIV col1 AS col1 FROM tab1
----
24
5
6

skipif mysql # not compatible
query I rowsort label-7130
SELECT ALL col1 + - col2 / col1 AS col1 FROM tab1
----
24
5
6

query I rowsort
SELECT DISTINCT + + 7 FROM tab2, tab1 AS cor0, tab0, tab2 AS cor1
----
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-7132
SELECT ALL + col0 DIV + 39 FROM tab0 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-7132
SELECT ALL + col0 / + 39 FROM tab0 AS cor0
----
0
0
2

query I rowsort
SELECT - + cor0.col2 * col2 + + ( - col0 ) AS col2 FROM tab1 AS cor0
----
-2919
-3313
-9296

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + cor0.col2 col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - - col2 + col2 * col1 AS col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT + col2 * - 33 AS col2 FROM tab0 cor0
----
-1089
-2706
-33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + col0 col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - col1 + - col0 * - cor0.col2 FROM tab2 AS cor0
----
158
1969
2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + col0 col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - col1 + ( - 71 ) FROM tab2 AS cor0
----
-102
-130
-88

query I rowsort
SELECT + 76 - col1 AS col0 FROM tab1 AS cor0
----
50
63
66

query I rowsort
SELECT + ( - cor0.col2 ) + col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 * col0 * col0 - col0 AS col2 FROM tab0 AS cor0
----
118790
49512
720722

onlyif mysql # use DIV operator for integer division
query I rowsort label-7144
SELECT ALL col0 + 89 DIV tab1.col1 FROM tab1
----
6
72
86

skipif mysql # not compatible
query I rowsort label-7144
SELECT ALL col0 + 89 / tab1.col1 FROM tab1
----
6
72
86

query I rowsort
SELECT - col1 + - col0 + ( cor0.col0 + - col1 ) AS col2 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT ALL + + col1 * col0 + - col1 AS col1 FROM tab0 cor0
----
1978
3298
8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-7147
SELECT - + col2 * + ( + col0 * + col2 ) + 85 DIV - col0 FROM tab1 cor0
----
-207937
-737281
-8776

skipif mysql # not compatible
query I rowsort label-7147
SELECT - + col2 * + ( + col0 * + col2 ) + 85 / - col0 FROM tab1 cor0
----
-207937
-737281
-8776

query I rowsort
SELECT - col0 * + col1 + 64 * col0 FROM tab0 AS cor0
----
-1155
-2403
-528

query I rowsort
SELECT DISTINCT 52 * col2 FROM tab1
----
2808
2964
4992

query I rowsort
SELECT - tab0.col1 * col1 * + col0 AS col2 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL 63 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 65 col1 FROM tab2, tab2 cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 + 33 * - cor0.col1 + col2 * ( + 72 ) * + col2 col0 FROM tab1 AS cor0
----
209068
233588
663110

query I rowsort
SELECT - - col2 + + col0 * - col1 + + cor0.col0 FROM tab0 AS cor0
----
-2007
-3359
-7928

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * cor0.col0 + ( col1 ) col1 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT - 11 * + cor0.col0 * col2 AS col1 FROM tab0 cor0
----
-385
-80278
-8712

query I rowsort
SELECT ( + 99 ) FROM tab0
----
99
99
99

query I rowsort
SELECT - 30 * - col1 FROM tab2 AS cor0
----
1770
510
930

query I rowsort
SELECT DISTINCT 90 AS col1 FROM tab1, tab1 AS cor0
----
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-7160
SELECT + ( - col2 ) DIV - col0 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7160
SELECT + ( - col2 ) / - col0 FROM tab0
----
0
0
1

query I rowsort
SELECT ALL + 32 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to cf4f01ac97eb83445b1721f3ae28961a

query I rowsort
SELECT + 3 AS col1 FROM tab0
----
3
3
3

query I rowsort
SELECT + + 66 - - col0 * - 53 * + col2 FROM tab0 cor0
----
-1789
-386728
-41910

query I rowsort
SELECT + 55 * col2 + + col0 AS col1 FROM tab2 AS cor0
----
1492
1508
2169

onlyif mysql # use DIV operator for integer division
query I rowsort label-7165
SELECT + cor0.col0 * col2 DIV - 43 + ( + col2 ) * - ( + col0 + col2 ) FROM tab0 cor0
----
-14191
-1899
-36

skipif mysql # not compatible
query I rowsort label-7165
SELECT + cor0.col0 * col2 / - 43 + ( + col2 ) * - ( + col0 + col2 ) FROM tab0 cor0
----
-14191
-1899
-36

query I rowsort
SELECT ALL 3 * 82 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to e19130993a2e5c1f8a42a950ddaf8619

query I rowsort
SELECT ( + col1 ) + col2 FROM tab2
----
55
58
85

query I rowsort
SELECT DISTINCT + col2 * - col0 + ( col2 ) * - col2 - - tab1.col1 AS col1 FROM tab1
----
-16883
-3052
-6887

query I rowsort
SELECT DISTINCT + + 94 * col1 FROM tab1 AS cor0
----
1222
2444
940

query I rowsort
SELECT ALL - col2 * col1 * + ( + col0 ) FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ( - col2 ) + - col2 * - col1 AS col1 FROM tab1 cor0
----
1152
1350
513

query I rowsort
SELECT DISTINCT cor0.col2 * col0 AS col0 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * 42 col2 FROM tab2 AS cor0
----
1092
1134
1596

query I rowsort
SELECT DISTINCT - - col0 + 99 AS col2 FROM tab2 AS cor0
----
106
177
178

onlyif mysql # use DIV operator for integer division
query I rowsort label-7175
SELECT - col1 * col0 * col1 + + cor0.col2 DIV ( col1 ) AS col2 FROM tab1 AS cor0
----
-13513
-2026
-6395

skipif mysql # not compatible
query I rowsort label-7175
SELECT - col1 * col0 * col1 + + cor0.col2 / ( col1 ) AS col2 FROM tab1 AS cor0
----
-13513
-2026
-6395

query I rowsort
SELECT DISTINCT cor0.col2 + 4 AS col1 FROM tab0 AS cor0
----
37
5
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-7177
SELECT ALL + + col0 DIV + CAST( + 44 AS SIGNED ) + col0 FROM tab1 AS cor0
----
3
65
81

skipif mysql # not compatible
query I rowsort label-7177
SELECT ALL + + col0 / + CAST ( + 44 AS INTEGER ) + col0 FROM tab1 AS cor0
----
3
65
81

query I rowsort
SELECT - col0 + + 31 FROM tab2 AS cor0
----
-47
-48
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-7179
SELECT DISTINCT col1 + col0 * col1 DIV col2 col2 FROM tab0 AS cor0
----
148
189
3492

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7179
SELECT DISTINCT col1 + col0 * col1 / col2 col2 FROM tab0 AS cor0
----
148
189
3492

query I rowsort
SELECT + col2 * col0 * + 42 + col2 FROM tab0 AS cor0
----
1471
306598
33297

query I rowsort
SELECT DISTINCT - col0 + 78 AS col2 FROM tab2 AS cor0
----
-1
0
71

query I rowsort
SELECT + col2 * ( cor0.col0 ) + + col0 AS col1 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ( col2 ) - + col1 FROM tab1
----
28
47
83

query I rowsort
SELECT + - 4 AS col2 FROM tab1 AS cor0
----
-4
-4
-4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7185
SELECT ALL + CAST( col2 AS SIGNED ) * + col1 AS col2 FROM tab1
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-7185
SELECT ALL + CAST ( col2 AS INTEGER ) * + col1 AS col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + col2 * + 12 FROM tab1 AS cor0
----
1152
648
684

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col0 + + 23 * col1 col1 FROM tab1 AS cor0
----
166
219
595

query I rowsort
SELECT ( - 6 + + col1 ) AS col2 FROM tab1
----
20
4
7

query I rowsort
SELECT DISTINCT + tab0.col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 70 * - col2 * 91 col0 FROM tab2 cor0
----
-165620
-171990
-242060

query I rowsort
SELECT DISTINCT + col0 + + col1 * - cor0.col0 AS col0 FROM tab2 AS cor0
----
-1264
-210
-4524

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 * col1 col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT col2 + col2 * + col0 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT ALL - + ( col0 ) * 36 AS col2 FROM tab0 AS cor0
----
-1260
-3204
-864

query I rowsort
SELECT - 80 * + col0 AS col0 FROM tab2 AS cor0
----
-560
-6240
-6320

query I rowsort
SELECT ALL col0 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - - 53 * col2 FROM tab1 AS cor0
----
2862
3021
5088

query I rowsort
SELECT ALL + 16 FROM tab0 AS cor0
----
16
16
16

query I rowsort
SELECT ALL + col0 * 36 FROM tab1
----
108
2304
2880

query I rowsort
SELECT + 0 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL + - col2 * col2 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL col1 * + 0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 * col0 * ( cor0.col1 ) + 50 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
2934
43810
88000

query I rowsort
SELECT ALL - + cor0.col1 - col1 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT + col1 + - 48 * cor0.col0 + col0 * col2 FROM tab0 AS cor0
----
-1548
-274
3117

query I rowsort
SELECT DISTINCT - - col2 + col0 AS col1 FROM tab0 cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 * ( 51 ) col1 FROM tab2 AS cor0
----
1326
1377
1938

query I rowsort
SELECT + col0 + ( col0 ) * + col1 AS col1 FROM tab0 AS cor0
----
2088
3430
8188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7209
SELECT DISTINCT col2 * + CAST( 46 AS SIGNED ) FROM tab0 cor0
----
1518
3772
46

skipif mysql # not compatible
query I rowsort label-7209
SELECT DISTINCT col2 * + CAST ( 46 AS INTEGER ) FROM tab0 cor0
----
1518
3772
46

query I rowsort
SELECT 76 AS col1 FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

query I rowsort
SELECT - 21 AS col2 FROM tab0 AS cor0
----
-21
-21
-21

query I rowsort
SELECT DISTINCT - col1 * + col1 + + col2 FROM tab1
----
-43
-622
-73

query I rowsort
SELECT DISTINCT - col1 * 5 FROM tab2
----
-155
-295
-85

query I rowsort
SELECT - 49 * + col0 FROM tab0 AS cor0
----
-1176
-1715
-4361

query I rowsort
SELECT ALL + col2 + + col0 * col1 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL - 11 * - cor0.col1 FROM tab0 AS cor0
----
1001
1067
946

onlyif mysql # use DIV operator for integer division
query I rowsort label-7217
SELECT - col1 DIV 75 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7217
SELECT - col1 / 75 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - 4 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 39ed23475412c3cbba02ecdd2d7018e6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7219
SELECT DISTINCT - CAST( 84 AS SIGNED ) AS col2 FROM tab1, tab2 AS cor0
----
-84

skipif mysql # not compatible
query I rowsort label-7219
SELECT DISTINCT - CAST ( 84 AS INTEGER ) AS col2 FROM tab1, tab2 AS cor0
----
-84

query I rowsort
SELECT - col0 + ( + col1 ) AS col1 FROM tab2
----
-19
-62
24

query I rowsort
SELECT col1 + - 71 * col0 FROM tab1
----
-187
-4534
-5667

query I rowsort
SELECT - - col1 + col1 + col0 * ( - col2 ) AS col2 FROM tab2 cor0
----
-127
-1910
-2968

query I rowsort
SELECT col0 * - col1 - - col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT ALL + + 21 * + col0 + ( + col2 ) * - cor0.col2 FROM tab0 AS cor0
----
-4855
-585
734

query I rowsort
SELECT DISTINCT + 66 + col1 * col1 FROM tab1 AS cor0
----
166
235
742

query I rowsort
SELECT + col0 * + col2 - 97 AS col0 FROM tab0 AS cor0
----
-62
695
7201

query I rowsort
SELECT ALL - + 61 * col2 AS col2 FROM tab0 AS cor0
----
-2013
-5002
-61

query I rowsort
SELECT ALL + - 22 + - col0 FROM tab0 AS cor0
----
-111
-46
-57

query I rowsort
SELECT DISTINCT + - col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL tab2.col2 - - col2 * tab2.col2 AS col0 FROM tab2
----
1482
702
756

query I rowsort
SELECT ALL + 22 - col0 * - col0 AS col2 FROM tab2
----
6106
6263
71

query I rowsort
SELECT ALL - 71 - + col0 FROM tab0
----
-106
-160
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-7233
SELECT DISTINCT + 77 DIV col2 AS col1 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-7233
SELECT DISTINCT + 77 / col2 AS col1 FROM tab1
----
0
1

query I rowsort
SELECT ALL - 44 - + tab0.col1 AS col2 FROM tab0
----
-130
-135
-141

query I rowsort
SELECT ALL 68 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 88 + col2 col0 FROM tab1
----
142
145
184

query I rowsort
SELECT + col0 * cor0.col0 + - col1 + col2 AS col1 FROM tab1 AS cor0
----
37
4143
6483

onlyif mysql # use DIV operator for integer division
query I rowsort label-7238
SELECT - + col1 DIV col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7238
SELECT - + col1 / col1 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL + + 11 * + cor0.col0 + 89 AS col2 FROM tab2 AS cor0
----
166
947
958

query I rowsort
SELECT DISTINCT + - col0 + + col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT + col2 * col1 + cor0.col0 + - col1 FROM tab0 AS cor0
----
2776
35
7460

query I rowsort
SELECT DISTINCT - col2 * col2 * col2 + + 78 + + col1 FROM tab0
----
-35773
-551199
174

query I rowsort
SELECT + tab2.col2 + + tab2.col2 * - 58 + - 69 FROM tab2
----
-1551
-1608
-2235

query I rowsort
SELECT col1 * col2 + - tab1.col1 * + col1 AS col0 FROM tab1
----
1079
470
728

query I rowsort
SELECT - col1 * ( - col2 ) + col1 * col0 FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT ALL tab2.col0 + - col2 + - col0 AS col0 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT DISTINCT 54 * tab0.col0 * + col0 + 49 * + col1 FROM tab0
----
35318
432193
70903

query I rowsort
SELECT DISTINCT - 75 AS col1 FROM tab1
----
-75

query I rowsort
SELECT DISTINCT 39 + col2 FROM tab1
----
135
93
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7250
SELECT cor0.col1 DIV + ( 74 ) AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-7250
SELECT cor0.col1 / + ( 74 ) AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT 19 + col1 AS col1 FROM tab0
----
105
110
116

query I rowsort
SELECT + 5 * col1 FROM tab2
----
155
295
85

query I rowsort
SELECT ALL col2 + + 45 AS col1 FROM tab0 cor0
----
127
46
78

query I rowsort
SELECT cor0.col1 * + 52 FROM tab0 AS cor0
----
4472
4732
5044

query I rowsort
SELECT DISTINCT - - col0 + 61 * col2 FROM tab0 AS cor0
----
2037
5091
96

query I rowsort
SELECT - - col1 * + col1 - - col2 FR