sqllogictest

Artifact [86751a6d0b]
Login

Artifact 86751a6d0b26a69e46cdebba563398f42f300389:


hash-threshold 8

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

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

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + col0 * + col2 * - 64 AS col0 FROM tab0 AS cor0
----
-2240
-467072
-50688

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

query I rowsort
SELECT ALL cor0.col0 * 94 AS col2 FROM tab1 AS cor0
----
282
6016
7520

query I rowsort
SELECT ALL + - cor0.col2 * + col2 + - col1 FROM tab1 cor0
----
-2942
-3259
-9229

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

query I rowsort
SELECT DISTINCT + + cor0.col0 * 24 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
1898
1934
195

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

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

query I rowsort
SELECT DISTINCT col0 * 30 * col1 AS col0 FROM tab0 AS cor0
----
101850
242970
61920

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

query I rowsort
SELECT + - 81 * col2 * - cor0.col2 - + col1 FROM tab0 cor0
----
-16
544553
88123

query I rowsort
SELECT - 47 - 17 AS col0 FROM tab1 AS cor0
----
-64
-64
-64

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-11
SELECT + CAST ( NULL AS REAL ) + col1 + - col0 * - ( + col2 ) / col0 col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 - - 75 AS col0 FROM tab1
----
139
155
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-13
SELECT col1 * + 23 + + col2 + ( - col1 + tab1.col0 ) DIV ( - 35 ) FROM tab1
----
286
394
652

skipif mysql # not compatible
query I rowsort label-13
SELECT col1 * + 23 + + col2 + ( - col1 + tab1.col0 ) / ( - 35 ) FROM tab1
----
286
394
652

query I rowsort
SELECT - col0 * + col2 + + col1 * col1 AS col1 FROM tab2 cor0
----
-2713
1453
772

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

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

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

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

query I rowsort
SELECT ALL + col0 + col2 * col0 * + col1 FROM tab2 AS cor0
----
119730
51113
5866

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

skipif mysql # not compatible
query I rowsort label-18
SELECT col0 / - cor0.col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - 77 + - cor0.col2 * + 75 AS col2 FROM tab2 AS cor0
----
-2027
-2102
-2927

query I rowsort
SELECT - col1 * - col0 * - 24 FROM tab1 cor0
----
-15360
-1872
-24960

query I rowsort
SELECT DISTINCT + + 16 + + col2 * col2 FROM tab1 AS cor0
----
2932
3265
9232

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

query I rowsort
SELECT - 73 * 84 FROM tab0
----
-6132
-6132
-6132

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

skipif mysql # not compatible
query I rowsort label-24
SELECT ALL - 99 / tab1.col2 AS col2 FROM tab1
----
-1
-1
-1

query I rowsort
SELECT ( 67 ) FROM tab0
----
67
67
67

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

query I rowsort
SELECT cor0.col0 + 67 AS col0 FROM tab0 AS cor0
----
102
156
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-28
SELECT ALL + - col0 + - 23 - + cor0.col0 DIV col0 AS col0 FROM tab2 AS cor0
----
-102
-103
-31

skipif mysql # not compatible
query I rowsort label-28
SELECT ALL + - col0 + - 23 - + cor0.col0 / col0 AS col0 FROM tab2 AS cor0
----
-102
-103
-31

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - 52 ) + - cor0.col0 col0 FROM tab2 AS cor0
----
-130
-131
-59

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

query I rowsort
SELECT DISTINCT col2 * cor0.col0 * + cor0.col0 + + ( col1 ) * + col1 + + col0 * 43 * - cor0.col0 FROM tab0 AS cor0
----
-42041
1636
317200

query I rowsort
SELECT DISTINCT - - col1 - - 71 AS col1 FROM tab2 AS cor0
----
102
130
88

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

query I rowsort
SELECT ALL + col0 + - col2 + col2 AS col1 FROM tab2
----
7
78
79

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

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

skipif mysql # not compatible
query I rowsort label-37
SELECT DISTINCT - CAST ( 72 AS INTEGER ) AS col1 FROM tab2
----
-72

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

query I rowsort
SELECT ALL - col1 + 10 AS col0 FROM tab0 AS cor0
----
-76
-81
-87

query I rowsort
SELECT 60 * 76 AS col2 FROM tab0
----
4560
4560
4560

onlyif mysql # use DIV operator for integer division
query I rowsort label-41
SELECT DISTINCT tab0.col1 + + tab0.col1 DIV col2 - col1 * - col0 FROM tab0
----
2152
3589
8191

skipif mysql # not compatible
query I rowsort label-41
SELECT DISTINCT tab0.col1 + + tab0.col1 / col2 - col1 * - col0 FROM tab0
----
2152
3589
8191

onlyif mysql # use DIV operator for integer division
query I rowsort label-42
SELECT 22 DIV tab1.col2 col0 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-42
SELECT 22 / tab1.col2 col0 FROM tab1
----
0
0
0

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

query I rowsort
SELECT - 78 + col2 + + 31 AS col1 FROM tab0
----
-14
-46
35

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

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

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

query I rowsort
SELECT DISTINCT + 2 - - col0 * col1 AS col0 FROM tab2
----
1345
219
4604

onlyif mysql # use DIV operator for integer division
query I rowsort label-48
SELECT + col0 * col2 DIV - CAST( col2 AS SIGNED ) + col2 FROM tab1
----
-7
16
51

skipif mysql # not compatible
query I rowsort label-48
SELECT + col0 * col2 / - CAST ( col2 AS INTEGER ) + col2 FROM tab1
----
-7
16
51

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

query I rowsort
SELECT DISTINCT + tab0.col0 + 82 AS col1 FROM tab0, tab2, tab2 AS cor0, tab1
----
106
117
171

query I rowsort
SELECT DISTINCT + col2 * - ( + 17 * col0 + + col1 ) AS col2 FROM tab2 AS cor0
----
-36010
-4050
-51680

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

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

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

query I rowsort
SELECT - col0 + - ( + 78 ) * col0 AS col1 FROM tab0
----
-1896
-2765
-7031

query I rowsort
SELECT + + col0 - + 42 FROM tab2 AS cor0
----
-35
36
37

query I rowsort
SELECT col1 * col1 + 98 + col2 FROM tab0 AS cor0
----
7527
8461
9508

query I rowsort
SELECT DISTINCT - - col0 * - 47 + col2 AS col0 FROM tab1 AS cor0
----
-2951
-3664
-87

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

query I rowsort
SELECT ALL - + col2 + - col0 + 90 AS col0 FROM tab2 AS cor0
----
-14
-27
56

query I rowsort
SELECT DISTINCT + col0 - ( - 99 ) FROM tab2 AS cor0
----
106
177
178

query I rowsort
SELECT ALL - + col2 * + ( 65 ) FROM tab2 AS cor0
----
-1690
-1755
-2470

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

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

query I rowsort
SELECT + col2 * 21 - ( + cor0.col2 ) AS col0 FROM tab0 AS cor0
----
1640
20
660

query I rowsort
SELECT ALL - col0 * - ( - 45 ) FROM tab0 AS cor0
----
-1080
-1575
-4005

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

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

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

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

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

query I rowsort
SELECT ALL col2 + 33 * col2 + col2 AS col1 FROM tab1
----
1890
1995
3360

query I rowsort
SELECT ALL col1 * + 69 FROM tab2
----
1173
2139
4071

query I rowsort
SELECT tab0.col2 * - 44 AS col1 FROM tab0
----
-1452
-3608
-44

query I rowsort
SELECT DISTINCT - col2 + ( - col0 ) * col2 AS col0 FROM tab1
----
-216
-3705
-7776

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

query I rowsort
SELECT - col0 * + 3 + - col0 FROM tab1 AS cor0
----
-12
-256
-320

query I rowsort
SELECT + col0 + 60 - - col1 AS col0 FROM tab1 AS cor0
----
134
153
89

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

query I rowsort
SELECT - col2 + + 19 + col0 AS col2 FROM tab2
----
-1
60
71

query I rowsort
SELECT DISTINCT tab1.col1 * col1 + + 16 FROM tab1
----
116
185
692

query I rowsort
SELECT + - col2 * 65 + - cor0.col1 * col0 FROM tab2 AS cor0
----
-1972
-3813
-6292

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

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

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

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

query I rowsort
SELECT ALL + col2 * cor0.col1 + + ( + ( - col2 ) + - col1 * col2 ) FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-83
SELECT - cor0.col2 + + cor0.col0 * CAST( 51 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
1191
1784
4457

skipif mysql # not compatible
query I rowsort label-83
SELECT - cor0.col2 + + cor0.col0 * CAST ( 51 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
1191
1784
4457

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

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

query I rowsort
SELECT ALL - 42 + col0 AS col2 FROM tab0 AS cor0
----
-18
-7
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 6 * - col0 + col0 col2 FROM tab2 AS cor0
----
-35
-390
-395

query I rowsort
SELECT - + 95 * col2 AS col2 FROM tab0 AS cor0
----
-3135
-7790
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-88
SELECT DISTINCT - - col2 * - col2 - col2 DIV - col0 FROM tab1 AS cor0
----
-2898
-3249
-9215

skipif mysql # not compatible
query I rowsort label-88
SELECT DISTINCT - - col2 * - col2 - col2 / - col0 FROM tab1 AS cor0
----
-2898
-3249
-9215

query I rowsort
SELECT col2 * + ( 73 * - col1 ) FROM tab1 AS cor0
----
-102492
-41610
-91104

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

query I rowsort
SELECT ALL + 39 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to ed2ebd9def3e2c38aa46cb3af60fe229

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-92
SELECT CAST( ( - col1 ) AS SIGNED ) + - cor0.col0 AS col1 FROM tab1 AS cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort label-92
SELECT CAST ( ( - col1 ) AS INTEGER ) + - cor0.col0 AS col1 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-93
SELECT DISTINCT CAST( 60 * - col1 AS SIGNED ) AS col0 FROM tab2
----
-1020
-1860
-3540

skipif mysql # not compatible
query I rowsort label-93
SELECT DISTINCT CAST ( 60 * - col1 AS INTEGER ) AS col0 FROM tab2
----
-1020
-1860
-3540

query I rowsort
SELECT col0 + + 69 AS col1 FROM tab2 cor0
----
147
148
76

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 40 + - cor0.col2 * + col0 * col0 col2 FROM tab1 AS cor0
----
-233512
-526
-614440

query I rowsort
SELECT + - 41 AS col0 FROM tab0 AS cor0
----
-41
-41
-41

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

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

query I rowsort
SELECT col2 + 20 AS col0 FROM tab2 AS cor0
----
46
47
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-103
SELECT + cor0.col2 + + CAST( + col1 * + col1 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
327
3507
988

skipif mysql # not compatible
query I rowsort label-103
SELECT + cor0.col2 + + CAST ( + col1 * + col1 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT - - cor0.col0 * - 97 AS col1 FROM tab2 AS cor0
----
-679
-7566
-7663

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

query I rowsort
SELECT tab2.col0 * + 34 * - col2 FROM tab2
----
-102068
-6426
-68952

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

query I rowsort
SELECT DISTINCT - col1 * + 92 FROM tab0
----
-7912
-8372
-8924

query I rowsort
SELECT DISTINCT - - ( + 15 ) * col0 FROM tab1 AS cor0
----
1200
45
960

query I rowsort
SELECT + col0 + + cor0.col1 * col2 * + col2 + col2 FROM tab0 AS cor0
----
133
612055
93711

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-112
SELECT ALL col0 DIV + tab1.col2 + 2 * col1 - col1 FROM tab1
----
11
13
26

skipif mysql # not compatible
query I rowsort label-112
SELECT ALL col0 / + tab1.col2 + 2 * col1 - col1 FROM tab1
----
11
13
26

query I rowsort
SELECT ALL 25 * - col2 + tab2.col1 FROM tab2
----
-591
-644
-933

query I rowsort
SELECT ALL - 69 + tab2.col0 FROM tab2
----
-62
10
9

query I rowsort
SELECT ALL ( - col0 ) * + col2 + - col2 + + col0 FROM tab1
----
-213
-3641
-7696

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

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

query I rowsort
SELECT ALL + + 1 + - col2 AS col1 FROM tab2 cor0
----
-25
-26
-37

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

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

skipif mysql # not compatible
query I rowsort label-119
SELECT ALL CAST ( NULL AS INTEGER ) * 76 + col2 / 20 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 24 * + tab0.col0 AS col2 FROM tab0
----
2136
576
840

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col1 col2 FROM tab1, tab0 AS cor0
----
-10
-13
-26

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

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( 0 AS REAL ) / + cor0.col0 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 - - col0 col0 FROM tab0
----
1260
600
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-126
SELECT + - col2 + col2 DIV - col0 + - col1 AS col2 FROM tab1 AS cor0
----
-110
-67
-98

skipif mysql # not compatible
query I rowsort label-126
SELECT + - col2 + col2 / - col0 + - col1 AS col2 FROM tab1 AS cor0
----
-110
-67
-98

query I rowsort
SELECT ALL - col2 + - ( - col2 ) * - col0 - + ( - 66 ) FROM tab1
----
-150
-3639
-7710

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

skipif mysql # not compatible
query I rowsort label-128
SELECT col0 - CAST ( 93 AS INTEGER ) * + col2 AS col2 FROM tab0 AS cor0
----
-3045
-58
-7537

query I rowsort
SELECT - col1 * - 93 + col1 + col1 * ( ( col2 ) ) AS col1 FROM tab1 AS cor0
----
1510
2470
3848

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

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

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

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

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

query I rowsort
SELECT ALL + col2 * col0 * - 65 AS col0 FROM tab1 cor0
----
-10530
-237120
-499200

query I rowsort
SELECT ALL + cor0.col2 * - col2 + 56 * col1 * - ( col1 ) FROM tab1 AS cor0
----
-18680
-40772
-8849

onlyif mysql # use DIV operator for integer division
query I rowsort label-135
SELECT ALL col2 DIV 22 AS col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-135
SELECT ALL col2 / 22 AS col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + + col1 * 43 AS col0 FROM tab2 AS cor0
----
1333
2537
731

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

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

query I rowsort
SELECT + - 65 AS col0 FROM tab0 AS cor0
----
-65
-65
-65

query I rowsort
SELECT DISTINCT - 38 * col2 AS col2 FROM tab2 AS cor0
----
-1026
-1444
-988

query I rowsort
SELECT ALL 4 + - col0 FROM tab1
----
-60
-76
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-141
SELECT ALL - 22 DIV cor0.col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-141
SELECT ALL - 22 / cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 31 FROM tab0, tab2 AS cor0, tab0 cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

query I rowsort
SELECT + 36 + - col2 AS col1 FROM tab2 AS cor0
----
-2
10
9

query I rowsort
SELECT tab0.col2 AS col1 FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 7786718bd8042022537378d40ec87475

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

query I rowsort
SELECT + 6 + col0 * 22 FROM tab2 AS cor0
----
160
1722
1744

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-148
SELECT ALL + tab1.col1 DIV 79 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-148
SELECT ALL + tab1.col1 / 79 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL - - col1 * - 77 AS col2 FROM tab1 cor0
----
-1001
-2002
-770

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

skipif mysql # not compatible
query I rowsort label-150
SELECT - - cor0.col2 / + ( col0 ) + + col0 AS col1 FROM tab0 cor0
----
25
35
89

query I rowsort
SELECT ALL col2 + 29 * col0 FROM tab0 AS cor0
----
1016
2663
729

query I rowsort
SELECT DISTINCT - - col2 * 4 * 13 FROM tab0 AS cor0
----
1716
4264
52

query I rowsort
SELECT ALL - col0 * + 17 + col0 AS col0 FROM tab0 AS cor0
----
-1424
-384
-560

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

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

query I rowsort
SELECT ALL - tab1.col1 * tab1.col1 + col0 * - tab1.col1 * col0 AS col2 FROM tab1
----
-41060
-83369
-910

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

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

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

query I rowsort
SELECT + 88 * 40 * col0 FROM tab2 AS cor0
----
24640
274560
278080

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

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

query I rowsort
SELECT DISTINCT - 94 + 88 * col0 FROM tab2 AS cor0
----
522
6770
6858

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - - 66 col0 FROM tab2
----
144
145
73

query I rowsort
SELECT DISTINCT col0 + 87 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
-2184
-2342
-3227

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT - col0 * col2 * + col1 + col1 AS col0 FROM tab1 AS cor0
----
-36470
-4186
-99827

query I rowsort
SELECT col2 + 34 FROM tab2 cor0
----
60
61
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 11 + - col2 * + col0 col1 FROM tab1
----
-151
-3637
-7669

query I rowsort
SELECT 61 * - col0 AS col1 FROM tab0 cor0
----
-1464
-2135
-5429

query I rowsort
SELECT DISTINCT 13 * 97 FROM tab1
----
1261

query I rowsort
SELECT ALL 63 * col1 * col1 AS col2 FROM tab1
----
10647
42588
6300

query I rowsort
SELECT - 54 + + col1 AS col1 FROM tab2
----
-23
-37
5

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-186
SELECT DISTINCT 54 DIV col0 AS col0 FROM tab0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-186
SELECT DISTINCT 54 / col0 AS col0 FROM tab0
----
0
1
2

query I rowsort
SELECT cor0.col1 + + col0 * + 30 AS col0 FROM tab1 AS cor0
----
116
1930
2413

query I rowsort
SELECT ALL + 6 + - col2 AS col2 FROM tab2 AS cor0
----
-20
-21
-32

onlyif mysql # use DIV operator for integer division
query I rowsort label-189
SELECT + col1 * + col0 DIV - CAST( - col0 AS SIGNED ) FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-189
SELECT + col1 * + col0 / - CAST ( - col0 AS INTEGER ) FROM tab0
----
86
91
97

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

query I rowsort
SELECT col0 + - 31 * 99 AS col0 FROM tab2
----
-2990
-2991
-3062

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

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

query I rowsort
SELECT ALL col0 * 93 AS col0 FROM tab1 AS cor0
----
279
5952
7440

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

query I rowsort
SELECT DISTINCT + - col1 + + 7 AS col2 FROM tab0 AS cor0
----
-79
-84
-90

query I rowsort
SELECT - col1 + ( ( col1 ) ) * + col1 + col2 AS col0 FROM tab1 AS cor0
----
147
252
704

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-201
SELECT col0 + 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-202
SELECT DISTINCT - col2 DIV + 20 + + col0 + - col0 FROM tab0 AS cor0
----
-1
-4
0

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-204
SELECT DISTINCT cor0.col1 DIV col0 + col1 * + col1 AS col2 FROM tab1 AS cor0
----
100
169
684

skipif mysql # not compatible
query I rowsort label-204
SELECT DISTINCT cor0.col1 / col0 + col1 * + col1 AS col2 FROM tab1 AS cor0
----
100
169
684

query I rowsort
SELECT ALL - ( 33 ) + - col1 AS col2 FROM tab0 AS cor0
----
-119
-124
-130

query I rowsort
SELECT - + col2 + - col2 * + cor0.col1 + ( col0 ) * col2 AS col0 FROM tab2 cor0
----
-675
2318
468

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 38 * col0 col0 FROM tab0 AS cor0
----
1330
3382
912

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

query I rowsort
SELECT ALL + cor0.col0 * - cor0.col0 FROM tab1, tab1 cor0
----
9 values hashing to b1a10d0ce1bd78a97a3f25900325a81f

query I rowsort
SELECT - col0 + 96 * col1 FROM tab1
----
1168
2493
896

query I rowsort
SELECT - 43 * col2 + col0 * - col2 AS col1 FROM tab1 AS cor0
----
-11808
-2484
-6099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col1 * col0 col0 FROM tab0
----
-177504
-329315
-737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-213
SELECT 19 * col0 DIV col0 AS col1 FROM tab0
----
19
19
19

skipif mysql # not compatible
query I rowsort label-213
SELECT 19 * col0 / col0 AS col1 FROM tab0
----
19
19
19

onlyif mysql # use DIV operator for integer division
query I rowsort label-214
SELECT ALL - col1 DIV + 84 + 88 * col2 AS col0 FROM tab0 AS cor0
----
2903
7215
87

skipif mysql # not compatible
query I rowsort label-214
SELECT ALL - col1 / + 84 + 88 * col2 AS col0 FROM tab0 AS cor0
----
2903
7215
87

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

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

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

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

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

query I rowsort
SELECT - 32 * + col2 - ( - col2 * - tab0.col0 ) AS col2 FROM tab0
----
-1848
-67
-9922

query I rowsort
SELECT col1 * col1 + 12 - col2 * col1 FROM tab2
----
-345
136
1959

query I rowsort
SELECT col0 + 21 AS col0 FROM tab0 AS cor0
----
110
45
56

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

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

query I rowsort
SELECT + col2 + ( col2 + cor0.col2 ) FROM tab2 AS cor0
----
114
78
81

query I rowsort
SELECT DISTINCT - col1 + col0 * - ( + col2 ) FROM tab1
----
-188
-3658
-7693

query I rowsort
SELECT col2 * col0 + - ( + cor0.col0 * - col2 ) + - col0 AS col0 FROM tab1 AS cor0
----
15280
321
7232

query I rowsort
SELECT DISTINCT - - col0 + col2 + + col0 * col2 FROM tab0 AS cor0
----
71
7469
849

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-226
SELECT DISTINCT - col1 / col2 col0 FROM tab0 AS cor0
----
-1
-2
-97

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-228
SELECT + + col1 + - 96 DIV - col2 AS col1 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-228
SELECT + + col1 + - 96 / - col2 AS col1 FROM tab1 AS cor0
----
11
14
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-229
SELECT - - ( - col1 ) + + col1 DIV + 89 FROM tab2 cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-229
SELECT - - ( - col1 ) + + col1 / + 89 FROM tab2 cor0
----
-17
-31
-59

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-231
SELECT DISTINCT ( + 96 ) DIV col0 col0 FROM tab0
----
1
2
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-231
SELECT DISTINCT ( + 96 ) / col0 col0 FROM tab0
----
1
2
4

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

query I rowsort
SELECT + col2 * col0 + - col1 * + col2 + col1 AS col1 FROM tab2 cor0
----
-617
2373
553

query I rowsort
SELECT - - 95 * - col0 - - 30 * + col1 FROM tab0 AS cor0
----
-415
-5725
300

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

query I rowsort
SELECT 10 * - cor0.col1 * + ( col0 ) AS col0 FROM tab1 AS cor0
----
-10400
-6400
-780

query I rowsort
SELECT DISTINCT 75 + + col1 FROM tab2 AS cor0
----
106
134
92

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

query I rowsort
SELECT ALL + - 71 FROM tab0 AS cor0
----
-71
-71
-71

query I rowsort
SELECT DISTINCT - - col0 * + col0 + cor0.col0 FROM tab1 cor0
----
12
4160
6480

query I rowsort
SELECT DISTINCT + col0 * + col0 * + col0 AS col0 FROM tab2 AS cor0
----
343
474552
493039

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-244
SELECT ALL + col1 + + col1 DIV col0 + + col1 FROM tab1 AS cor0
----
20
26
60

skipif mysql # not compatible
query I rowsort label-244
SELECT ALL + col1 + + col1 / col0 + + col1 FROM tab1 AS cor0
----
20
26
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + + col2 * + col0 col1 FROM tab0 cor0
----
0
7209
768

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

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

query I rowsort
SELECT DISTINCT col1 * col1 + - col1 + - col0 * col2 * col2 FROM tab0 AS cor0
----
-18826
-590246
9277

query I rowsort
SELECT ALL 52 - col1 FROM tab1 AS cor0
----
26
39
42

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

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

query I rowsort
SELECT + col0 + col2 + + col1 * - col2 AS col0 FROM tab0 AS cor0
----
-2781
-61
-7291

query I rowsort
SELECT 44 * col0 + + col2 FROM tab0 AS cor0
----
1089
1541
3998

query I rowsort
SELECT DISTINCT - 55 * + col0 * + col1 - col2 AS col0 FROM tab1 AS cor0
----
-35257
-4344
-57296

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 99 * 69 + cor0.col1 * - col2 col2 FROM tab2 AS cor0
----
5297
5994
6185

onlyif mysql # use DIV operator for integer division
query I rowsort label-256
SELECT ALL col0 + col2 DIV + col2 AS col0 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-256
SELECT ALL col0 + col2 / + col2 AS col0 FROM tab0 AS cor0
----
25
36
90

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-258
SELECT DISTINCT + CAST( + col1 AS SIGNED ) DIV - col0 + col2 * + col0 AS col2 FROM tab0 AS cor0
----
33
7297
789

skipif mysql # not compatible
query I rowsort label-258
SELECT DISTINCT + CAST ( + col1 AS INTEGER ) / - col0 + col2 * + col0 AS col2 FROM tab0 AS cor0
----
33
7297
789

query I rowsort
SELECT DISTINCT + 20 FROM tab1, tab1 cor0
----
20

query I rowsort
SELECT ALL ( - col2 * - col2 ) FROM tab0
----
1
1089
6724

query I rowsort
SELECT + 6 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

query I rowsort
SELECT 90 * 10 AS col0 FROM tab0 AS cor0
----
900
900
900

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-264
SELECT + 35 * ( - col2 ) - - tab0.col1 DIV - col1 AS col1 FROM tab0
----
-1156
-2871
-36

skipif mysql # not compatible
query I rowsort label-264
SELECT + 35 * ( - col2 ) - - tab0.col1 / - col1 AS col1 FROM tab0
----
-1156
-2871
-36

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-267
SELECT DISTINCT col2 / + col1 + - col2 FROM tab2 AS cor0
----
-26
-27
-36

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 + 66 * - col1 col0 FROM tab2 AS cor0
----
-1160
-2073
-3920

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

query I rowsort
SELECT DISTINCT - 66 * + col1 AS col1 FROM tab0 cor0
----
-5676
-6006
-6402

query I rowsort
SELECT ALL - ( cor0.col1 ) + + col0 * + 91 AS col2 FROM tab2 AS cor0
----
606
7039
7172

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

query I rowsort
SELECT ( - col2 * + col1 + 30 ) FROM tab2
----
-1504
-616
-807

query I rowsort
SELECT - + col1 - + ( col1 + + col2 ) AS col2 FROM tab0 AS cor0
----
-195
-205
-264

query I rowsort
SELECT - 37 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to a283a98d14c34636d74b0e0b57633585

query I rowsort
SELECT ALL + - 36 - 60 AS col0 FROM tab0 AS cor0
----
-96
-96
-96

query I rowsort
SELECT ALL cor0.col0 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab1, tab0 cor2
----
243 values hashing to 63f734facb33901524f6f2c799118db4

query I rowsort
SELECT ALL - 73 * 5 FROM tab1 AS cor0
----
-365
-365
-365

query I rowsort
SELECT - col2 * + col2 + + col1 + - col2 * cor0.col1 FROM tab2 AS cor0
----
-1535
-2073
-2151

query I rowsort
SELECT - + 72 * - col0 FROM tab1 AS cor0
----
216
4608
5760

query I rowsort
SELECT ALL + 26 + - col1 AS col2 FROM tab1 AS cor0
----
0
13
16

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

query I rowsort
SELECT DISTINCT - col0 + col0 * - 92 * 3 FROM tab1 AS cor0
----
-17728
-22160
-831

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

query I rowsort
SELECT ALL col1 - - col0 AS col1 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-288
SELECT ALL - col1 * col0 - CAST( col1 AS SIGNED ) FROM tab1 AS cor0
----
-104
-1053
-650

skipif mysql # not compatible
query I rowsort label-288
SELECT ALL - col1 * col0 - CAST ( col1 AS INTEGER ) FROM tab1 AS cor0
----
-104
-1053
-650

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

query I rowsort
SELECT + + 94 + col0 AS col0 FROM tab2 AS cor0
----
101
172
173

query I rowsort
SELECT ALL + 94 * - cor0.col2 + col1 + col0 FROM tab1 AS cor0
----
-5047
-5284
-8931

query I rowsort
SELECT ALL + col1 * col2 * + ( + col0 + - col2 ) FROM tab2 AS cor0
----
-16740
26486
79768

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

skipif mysql # not compatible
query I rowsort label-293
SELECT DISTINCT cor0.col0 / - col1 + + col0 + col0 AS col1 FROM tab0 AS cor0
----
178
48
70

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

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

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

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

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

query I rowsort
SELECT - - 82 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

query I rowsort
SELECT - col1 * + tab2.col2 * ( + ( col1 ) * col1 ) - 93 FROM tab2
----
-186787
-5339947
-804450

query I rowsort
SELECT DISTINCT col0 + 30 * - col0 FROM tab2 AS cor0
----
-203
-2262
-2291

query I rowsort
SELECT - col0 * ( + col0 ) FROM tab0 AS cor0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * - 25 col1 FROM tab2 AS cor0
----
-650
-675
-950

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

query I rowsort
SELECT 69 - - col2 FROM tab0
----
102
151
70

query I rowsort
SELECT ALL 20 AS col1 FROM tab0
----
20
20
20

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

query I rowsort
SELECT ALL col1 * col0 + 34 AS col2 FROM tab1 AS cor0
----
1074
112
674

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

query I rowsort
SELECT - col2 * + col1 + - col0 * + col0 FROM tab1 AS cor0
----
-1413
-4666
-7648

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-310
SELECT + col1 * - CAST( - 48 AS SIGNED ) + col0 col2 FROM tab2 AS cor0
----
1495
2910
895

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-310
SELECT + col1 * - CAST ( - 48 AS INTEGER ) + col0 col2 FROM tab2 AS cor0
----
1495
2910
895

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col0 * - ( col2 * col0 ) col1 FROM tab2 AS cor0
----
-1354
-158243
-237175

query I rowsort
SELECT col0 + + col0 * 48 FROM tab1
----
147
3136
3920

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

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

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

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

query I rowsort
SELECT DISTINCT ( - col2 ) + col1 * col2 * 9 FROM tab2
----
13780
5776
7506

query I rowsort
SELECT + col1 * + col2 * + col2 + - col0 AS col1 FROM tab2 AS cor0
----
22592
24469
39806

query I rowsort
SELECT 60 + cor0.col0 AS col2 FROM tab0 AS cor0
----
149
84
95

query I rowsort
SELECT DISTINCT + col1 + 55 + - col1 * - col0 AS col0 FROM tab2
----
1415
303
4716

onlyif mysql # use DIV operator for integer division
query I rowsort label-322
SELECT ALL 70 * col2 DIV tab0.col2 + - 84 FROM tab0
----
-14
-14
-14

skipif mysql # not compatible
query I rowsort label-322
SELECT ALL 70 * col2 / tab0.col2 + - 84 FROM tab0
----
-14
-14
-14

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-323
SELECT ALL + CAST( + col0 AS SIGNED ) + - tab1.col2 + col1 * - col0 FROM tab1
----
-1056
-129
-633

skipif mysql # not compatible
query I rowsort label-323
SELECT ALL + CAST ( + col0 AS INTEGER ) + - tab1.col2 + col1 * - col0 FROM tab1
----
-1056
-129
-633

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

query I rowsort
SELECT ALL col1 + 41 FROM tab0
----
127
132
138

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

query I rowsort
SELECT DISTINCT - - col0 + - col0 * - 88 AS col2 FROM tab0 AS cor0
----
2136
3115
7921

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * col2 + col0 + + col2 col0 FROM tab0 AS cor0
----
1146
37
6895

query I rowsort
SELECT DISTINCT col2 * col1 + 1 AS col1 FROM tab0 AS cor0
----
2839
7463
98

query I rowsort
SELECT ALL 37 - col1 * - col2 * + ( cor0.col2 ) FROM tab0 cor0
----
134
611921
93691

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

query I rowsort
SELECT DISTINCT 68 * ( col2 ) FROM tab2
----
1768
1836
2584

query I rowsort
SELECT + - 33 + + col0 AS col2 FROM tab2 AS cor0
----
-26
45
46

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

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

query I rowsort
SELECT ALL + col2 * + 61 FROM tab0
----
2013
5002
61

query I rowsort
SELECT ALL + 69 * col1 AS col2 FROM tab2
----
1173
2139
4071

query I rowsort
SELECT + 83 * + col1 + + 30 * col2 AS col0 FROM tab1 AS cor0
----
2540
3778
3959

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-342
SELECT DISTINCT + CAST ( NULL AS REAL ) col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
NULL

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

query I rowsort
SELECT ALL + 15 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

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

query I rowsort
SELECT DISTINCT - col1 * cor0.col2 + 99 FROM tab2 AS cor0
----
-1435
-547
-738

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

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

skipif mysql # not compatible
query I rowsort label-348
SELECT + cor0.col0 + 5 / 45 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + 36 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

query I rowsort
SELECT ALL - col0 + 32 FROM tab1 AS cor0
----
-32
-48
29

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

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

query I rowsort
SELECT ALL - 27 AS col2 FROM tab0
----
-27
-27
-27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 8 * col0 col0 FROM tab2
----
56
624
632

query I rowsort
SELECT ALL - + 96 * cor0.col2 + + col2 * + col0 FROM tab1 AS cor0
----
-1536
-1824
-5022

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

query I rowsort
SELECT - 60 + - col1 * col2 + 16 * col0 AS col0 FROM tab0 cor0
----
-2514
-6098
403

query I rowsort
SELECT DISTINCT - cor0.col1 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-358
SELECT col0 / cor0.col0 col0 FROM tab1 AS cor0
----
1
1
1

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

query I rowsort
SELECT DISTINCT 25 * + col2 FROM tab1 cor0
----
1350
1425
2400

query I rowsort
SELECT + col0 * - col1 + 52 AS col0 FROM tab1 AS cor0
----
-26
-588
-988

query I rowsort
SELECT - - col0 + 1 + cor0.col2 FROM tab0 AS cor0
----
172
37
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + ( cor0.col2 ) + - cor0.col0 col1 FROM tab0 cor0
----
63
84
95

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-365
SELECT ALL + - col1 + ( + col0 ) DIV col1 + + col2 AS col0 FROM tab2 AS cor0
----
-32
-4
25

skipif mysql # not compatible
query I rowsort label-365
SELECT ALL + - col1 + ( + col0 ) / col1 + + col2 AS col0 FROM tab2 AS cor0
----
-32
-4
25

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

query I rowsort
SELECT 79 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col0 ) * - col0 col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT + cor0.col2 * - 61 AS col1 FROM tab1 AS cor0
----
-3294
-3477
-5856

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

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( cor0.col1 AS REAL ) + - col0 * 86 * col2 FROM tab1 cor0
----
-13906
-313718
-660467

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col1 * - col1 + col2 + CAST ( col1 AS REAL ) AS col0 FROM tab2 AS cor0
----
1019
344
3566

query I rowsort
SELECT ALL tab0.col1 * 72 + 84 FROM tab0
----
6276
6636
7068

query I rowsort
SELECT DISTINCT + col1 + - 13 FROM tab0
----
73
78
84

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-378
SELECT ALL col2 + - col2 DIV tab0.col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-378
SELECT ALL col2 + - col2 / tab0.col1 FROM tab0
----
1
33
82

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

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

query III rowsort
SELECT DISTINCT * FROM tab2 AS cor0 WHERE NOT NULL NOT IN ( col0 * col2 * col0 )
----

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

query I rowsort
SELECT - col0 * col1 + - col1 AS col1 FROM tab1 WHERE col0 < + col2
----
-104
-1053

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-385
SELECT DISTINCT cor0.col0 / col2 col2 FROM tab0 cor0
----
0
1
35

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

query I rowsort
SELECT ALL - col0 + tab2.col0 * tab2.col2 + col2 * tab2.col2 FROM tab2
----
2626
4367
911

query I rowsort
SELECT - col0 + + col1 + col1 * - col1 FROM tab0
----
-7334
-8279
-9347

query I rowsort
SELECT DISTINCT tab0.col0 * col0 + col2 AS col0 FROM tab0
----
1226
609
8003

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

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

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

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

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

query IIIIII rowsort
SELECT ALL * FROM tab0, tab1 AS cor0 WHERE NULL > ( NULL )
----

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-395
SELECT + col0 * col1 + col1 DIV + col0 FROM tab2 cor0
----
1343
221
4602

skipif mysql # not compatible
query I rowsort label-395
SELECT + col0 * col1 + col1 / + col0 FROM tab2 cor0
----
1343
221
4602

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

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

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 - col0 * - col2 * + col1 AS col1 FROM tab0 AS cor0
----
3395
664118
68112

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - - col1 col0 FROM tab2
----
137
38
96

query I rowsort
SELECT DISTINCT col0 + - col0 * - tab0.col0 FROM tab0
----
1260
600
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-403
SELECT DISTINCT col2 + col2 DIV col2 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-403
SELECT DISTINCT col2 + col2 / col2 FROM tab0
----
2
34
83

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

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

query I rowsort
SELECT + 38 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

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

skipif mysql # not compatible
query I rowsort label-407
SELECT ALL - - col2 / + col2 FROM tab1 cor0
----
1
1
1

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-410
SELECT - - col1 DIV - col1 + col1 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-410
SELECT - - col1 / - col1 + col1 FROM tab1 AS cor0
----
12
25
9

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

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

query I rowsort
SELECT + col1 * ( 84 ) AS col0 FROM tab1 AS cor0
----
1092
2184
840

query I rowsort
SELECT + 57 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-415
SELECT + col1 DIV + tab0.col0 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-415
SELECT + col1 / + tab0.col0 FROM tab0
----
1
2
3

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-417
SELECT - col1 DIV col1 + - col2 + col1 * col1 col1 FROM tab1
----
42
621
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-417
SELECT - col1 / col1 + - col2 + col1 * col1 col1 FROM tab1
----
42
621
72

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

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

query I rowsort
SELECT ALL col2 * + col2 * col1 + col2 * + col1 AS col0 FROM tab0
----
194
619346
96492

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 col2 FROM tab0 WHERE NOT NULL > col1
----

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

query III rowsort
SELECT * FROM tab1 WHERE ( col0 * - col2 + + col1 * col2 ) BETWEEN - col1 * + col2 * + col2 AND col1 - col2
----
64
10
57
80
13
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-425
SELECT + col1 DIV - col1 + - col2 * - col0 FROM tab0
----
34
7297
791

skipif mysql # not compatible
query I rowsort label-425
SELECT + col1 / - col1 + - col2 * - col0 FROM tab0
----
34
7297
791

query I rowsort
SELECT DISTINCT col2 FROM tab0 WHERE NOT col2 + + col0 / + col0 NOT IN ( - col1 + col2 * - col1 )
----

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

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

query I rowsort
SELECT + col1 * - col0 + col2 * - col2 FROM tab1
----
-10256
-2994
-3889

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

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

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

query III rowsort
SELECT * FROM tab2 WHERE NOT ( col1 * + col2 + - col2 / col1 ) NOT IN ( col1 * - tab2.col1 )
----

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

query I rowsort
SELECT + + cor0.col1 * 75 AS col2 FROM tab2 AS cor0
----
1275
2325
4425

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

query I rowsort
SELECT DISTINCT cor0.col0 * ( 28 ) + cor0.col0 FROM tab1 AS cor0
----
1856
2320
87

query I rowsort
SELECT ALL + col2 * - 10 * + cor0.col0 AS col1 FROM tab2 AS cor0
----
-1890
-20280
-30020

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

query I rowsort
SELECT - + 15 + col0 FROM tab0 AS cor0
----
20
74
9

query I rowsort
SELECT col1 + - tab2.col0 * - 85 AS col0 FROM tab2
----
626
6689
6732

query I rowsort
SELECT + col2 + - ( col0 + col2 ) AS col0 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT ALL + col1 * tab2.col1 AS col2 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL - - 98 + + col0 AS col0 FROM tab1 AS cor0
----
101
162
178

query I rowsort
SELECT - 89 * col1 * + col1 AS col1 FROM tab1
----
-15041
-60164
-8900

query I rowsort
SELECT ALL tab0.col1 * 51 * - 0 AS col2 FROM tab0, tab1 cor0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-446
SELECT CAST( + col1 AS SIGNED ) * - col1 FROM tab1
----
-100
-169
-676

skipif mysql # not compatible
query I rowsort label-446
SELECT CAST ( + col1 AS INTEGER ) * - col1 FROM tab1
----
-100
-169
-676

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 19 * col0 + cor0.col0 col1 FROM tab2 AS cor0
----
-126
-1404
-1422

query I rowsort
SELECT - col0 * - col1 - ( 29 ) AS col1 FROM tab0
----
2035
3366
8070

query I rowsort
SELECT ( - col2 ) * + ( 89 ) * + tab1.col2 AS col1 FROM tab1
----
-259524
-289161
-820224

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-453
SELECT DISTINCT col2 DIV col1 - col2 FROM tab2 AS cor0
----
-26
-27
-36

skipif mysql # not compatible
query I rowsort label-453
SELECT DISTINCT col2 / col1 - col2 FROM tab2 AS cor0
----
-26
-27
-36

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

query I rowsort
SELECT ALL + col1 + col1 * + col0 * + col0 FROM tab1 AS cor0
----
260
40970
83213

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

query I rowsort
SELECT ALL 88 + + col2 FROM tab1
----
142
145
184

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

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

query I rowsort
SELECT - col2 + col1 * ( - col2 ) AS col0 FROM tab2
----
-1560
-684
-864

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 * col2 - cor0.col0 col2 FROM tab1 AS cor0
----
2913
3185
9136

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-466
SELECT DISTINCT CAST( - col2 AS SIGNED ) * + col2 + + 65 - 62 AS col1 FROM tab2
----
-1441
-673
-726

skipif mysql # not compatible
query I rowsort label-466
SELECT DISTINCT CAST ( - col2 AS INTEGER ) * + col2 + + 65 - 62 AS col1 FROM tab2
----
-1441
-673
-726

query I rowsort
SELECT - col1 * + 23 * col2 - + col1 AS col0 FROM tab2 AS cor0
----
-14875
-19282
-35341

query I rowsort
SELECT DISTINCT + 62 + col2 * + col1 AS col1 FROM tab0 AS cor0
----
159
2900
7524

query I rowsort
SELECT ALL + 61 + col1 FROM tab0 AS cor0
----
147
152
158

query I rowsort
SELECT + cor0.col1 * 81 AS col2 FROM tab2 AS cor0
----
1377
2511
4779

query I rowsort
SELECT + col0 * - col0 + - 32 * - ( + col2 ) FROM tab0 AS cor0
----
-1193
-5297
480

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 18 + + 60 col0 FROM tab1, tab1 cor0, tab1 AS cor1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

onlyif mysql # use DIV operator for integer division
query I rowsort label-475
SELECT col0 DIV 3 AS col2 FROM tab0
----
11
29
8

skipif mysql # not compatible
query I rowsort label-475
SELECT col0 / 3 AS col2 FROM tab0
----
11
29
8

query I rowsort
SELECT DISTINCT - - 8 AS col2 FROM tab1 AS cor0
----
8

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

query I rowsort
SELECT ALL 3 * col2 * col1 FROM tab0 AS cor0
----
22386
291
8514

query I rowsort
SELECT DISTINCT + - 70 * 73 FROM tab0 AS cor0
----
-5110

query I rowsort
SELECT + 56 + 53 + col0 FROM tab1 AS cor0
----
112
173
189

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-484
SELECT ( + col2 ) + + col2 DIV ( + col0 + col2 ) AS col1 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-484
SELECT ( + col2 ) + + col2 / ( + col0 + col2 ) AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + 37 - - col0 * + col1 AS col0 FROM tab0 AS cor0
----
2101
3432
8136

query I rowsort
SELECT ALL - 35 + 31 + + cor0.col1 FROM tab1 AS cor0
----
22
6
9

query I rowsort
SELECT + 90 * + col2 * col2 AS col1 FROM tab2 AS cor0
----
129960
60840
65610

query I rowsort
SELECT ALL - - ( 31 ) + - cor0.col1 AS col1 FROM tab1 AS cor0
----
18
21
5

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

query I rowsort
SELECT + 36 * ( col2 + - col0 ) FROM tab1 AS cor0
----
-252
1836
576

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

skipif mysql # not compatible
query I rowsort label-491
SELECT + col0 + col2 / col2 AS col2 FROM tab0 AS cor0
----
25
36
90

query I rowsort
SELECT + col2 - - ( - col1 + - col1 ) FROM tab0
----
-100
-139
-193

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 57 * + col1 + col1 * col1 col0 FROM tab1 AS cor0
----
2158
670
910

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

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

query I rowsort
SELECT - col2 + 31 * ( col2 ) AS col2 FROM tab1 AS cor0
----
1620
1710
2880

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

skipif mysql # not compatible
query I rowsort label-498
SELECT ALL + col1 / - col1 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

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

query I rowsort
SELECT col1 + 45 + col0 FROM tab2
----
141
182
83

query I rowsort
SELECT DISTINCT + col0 + 28 AS col2 FROM tab0
----
117
52
63

query I rowsort
SELECT DISTINCT + - cor0.col0 * 53 AS col1 FROM tab1 AS cor0
----
-159
-3392
-4240

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + 74 - col1 * col2 col2 FROM tab0 cor0
----
-728
3526
7081

query I rowsort
SELECT ALL + col2 + + col1 * - 31 * - col1 AS col1 FROM tab2 cor0
----
107937
29818
8997

query I rowsort
SELECT - col2 + + col0 + col2 * + cor0.col2 FROM tab1 AS cor0
----
2865
3256
9200

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

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

query I rowsort
SELECT ALL + col1 + ( + 33 ) FROM tab0 AS cor0
----
119
124
130

query I rowsort
SELECT tab0.col0 * - 13 FROM tab0
----
-1157
-312
-455

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

query I rowsort
SELECT - + 52 AS col1 FROM tab0 AS cor0
----
-52
-52
-52

query I rowsort
SELECT ALL 90 * tab1.col2 AS col0 FROM tab1
----
4860
5130
8640

query I rowsort
SELECT - col0 * col1 + col0 + col1 * col1 AS col2 FROM tab1 AS cor0
----
-476
-791
601

query I rowsort
SELECT + col1 * 50 FROM tab0 AS cor0
----
4300
4550
4850

onlyif mysql # use DIV operator for integer division
query I rowsort label-514
SELECT DISTINCT col2 * col0 DIV - 10 AS col0 FROM tab2
----
-18
-202
-300

skipif mysql # not compatible
query I rowsort label-514
SELECT DISTINCT col2 * col0 / - 10 AS col0 FROM tab2
----
-18
-202
-300

query I rowsort
SELECT + 69 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 2810c3097fe4771e273cfff903357b40

query I rowsort
SELECT - col0 * - col1 * + 12 FROM tab2 AS cor0
----
16116
2604
55224

query I rowsort
SELECT ALL tab2.col1 + col1 * tab2.col2 * - tab2.col2 + col2 * - col2 AS col1 FROM tab2
----
-23297
-25975
-40501

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 97 * 33 col1 FROM tab1, tab0, tab2 cor0
----
27 values hashing to 3548b808162626c2150bcba5290823c3

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 92 * cor0.col1 col0 FROM tab0 AS cor0
----
7912
8372
8924

query I rowsort
SELECT ALL 6 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

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

query I rowsort
SELECT ALL + + ( + col1 ) FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - 60 * - col2 FROM tab2 AS cor0
----
1560
1620
2280

query I rowsort
SELECT - cor0.col2 + - col1 * + col1 * col0 FROM tab0 AS cor0
----
-177537
-329316
-737091

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 54 * + col1 col1 FROM tab0 AS cor0
----
4644
4914
5238

query I rowsort
SELECT ALL - - 15 * + col1 AS col0 FROM tab0 cor0
----
1290
1365
1455

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-530
SELECT + col1 * 34 DIV col0 - + col2 * 86 FROM tab2 AS cor0
----
-2172
-2211
-3261

skipif mysql # not compatible
query I rowsort label-530
SELECT + col1 * 34 / col0 - + col2 * 86 FROM tab2 AS cor0
----
-2172
-2211
-3261

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-532
SELECT - col2 * col0 DIV - 68 FROM tab1 AS cor0
----
112
2
53

skipif mysql # not compatible
query I rowsort label-532
SELECT - col2 * col0 / - 68 FROM tab1 AS cor0
----
112
2
53

query I rowsort
SELECT ALL - col0 * col2 + 60 AS col0 FROM tab0
----
-7238
-732
25

query I rowsort
SELECT - 15 * col0 + col1 * col2 + col0 * + ( tab2.col2 * - col2 ) AS col0 FROM tab2
----
-114615
-4371
-52364

query I rowsort
SELECT + col1 * 41 + col1 * + col0 FROM tab2 AS cor0
----
1488
2040
7021

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

query I rowsort
SELECT - + col0 * + 47 - - col2 FROM tab1 AS cor0
----
-2951
-3664
-87

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-540
SELECT ALL CAST( 24 AS SIGNED ) + + col2 AS col0 FROM tab0 AS cor0
----
106
25
57

skipif mysql # not compatible
query I rowsort label-540
SELECT ALL CAST ( 24 AS INTEGER ) + + col2 AS col0 FROM tab0 AS cor0
----
106
25
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-541
SELECT col2 DIV 33 + cor0.col0 FROM tab1 cor0
----
4
65
82

skipif mysql # not compatible
query I rowsort label-541
SELECT col2 / 33 + cor0.col0 FROM tab1 cor0
----
4
65
82

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 + + col2 * + cor0.col0 col2 FROM tab1 AS cor0
----
108
3591
7584

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

query I rowsort
SELECT DISTINCT - + 21 * - 38 AS col0 FROM tab0 cor0
----
798

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

query I rowsort
SELECT DISTINCT - ( - col1 ) + + cor0.col2 + + ( 45 ) * + col2 FROM tab0 AS cor0
----
143
1604
3863

onlyif mysql # use DIV operator for integer division
query I rowsort label-548
SELECT ALL 18 * ( col2 ) + + cor0.col2 DIV + col1 AS col2 FROM tab0 AS cor0
----
1476
18
594

skipif mysql # not compatible
query I rowsort label-548
SELECT ALL 18 * ( col2 ) + + cor0.col2 / + col1 AS col2 FROM tab0 AS cor0
----
1476
18
594

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

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

query I rowsort
SELECT DISTINCT 28 + + ( + col2 ) * ( col2 ) AS col2 FROM tab2 AS cor0
----
1472
704
757

query I rowsort
SELECT col2 * col0 * col1 - col0 FROM tab1
----
36416
4209
99760

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-554
SELECT DISTINCT + tab1.col2 + + ( + 60 ) * col0 - CAST( col2 AS SIGNED ) AS col1 FROM tab1
----
180
3840
4800

skipif mysql # not compatible
query I rowsort label-554
SELECT DISTINCT + tab1.col2 + + ( + 60 ) * col0 - CAST ( col2 AS INTEGER ) AS col1 FROM tab1
----
180
3840
4800

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

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

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

query I rowsort
SELECT ALL - 1 + col1 * - col2 * + col2 AS col0 FROM tab1 AS cor0
----
-119809
-32491
-75817

onlyif mysql # use DIV operator for integer division
query I rowsort label-558
SELECT DISTINCT col0 DIV + col1 - - col0 AS col2 FROM tab1 AS cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-558
SELECT DISTINCT col0 / + col1 - - col0 AS col2 FROM tab1 AS cor0
----
3
70
86

query I rowsort
SELECT + col0 + - cor0.col2 * 69 + + col1 AS col0 FROM tab2 cor0
----
-1657
-1825
-2526

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

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

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

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

query I rowsort
SELECT DISTINCT - + col2 + col2 * col2 AS col1 FROM tab1 AS cor0
----
2862
3192
9120

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 31 * - col2 col2 FROM tab2 cor0
----
-1178
-806
-837

query I rowsort
SELECT 71 + + 17 FROM tab1 AS cor0
----
88
88
88

query I rowsort
SELECT DISTINCT + 82 + 61 * col0 AS col0 FROM tab1 AS cor0
----
265
3986
4962

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-567
SELECT DISTINCT + CAST( col2 AS SIGNED ) * col0 + - ( - 20 ) AS col0 FROM tab2
----
2048
209
3022

skipif mysql # not compatible
query I rowsort label-567
SELECT DISTINCT + CAST ( col2 AS INTEGER ) * col0 + - ( - 20 ) AS col0 FROM tab2
----
2048
209
3022

query I rowsort
SELECT 89 + col2 AS col2 FROM tab1
----
143
146
185

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + - col0 * 42 col1 FROM tab1 cor0
----
-180
-2745
-3456

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-574
SELECT DISTINCT + tab0.col0 DIV col2 - tab0.col0 * col2 FROM tab0
----
-7297
-792
0

skipif mysql # not compatible
query I rowsort label-574
SELECT DISTINCT + tab0.col0 / col2 - tab0.col0 * col2 FROM tab0
----
-7297
-792
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-575
SELECT + col1 DIV 37 AS col1 FROM tab0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-575
SELECT + col1 / 37 AS col1 FROM tab0
----
2
2
2

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

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

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

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

query I rowsort
SELECT ALL - 45 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 71160abf09589695379a70558726f0ba

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-580
SELECT DISTINCT + 71 * 83 + + cor1.col1 + + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-580
SELECT DISTINCT + 71 * 83 + + cor1.col1 + + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
NULL

query I rowsort
SELECT ALL + col0 * - col2 + 75 FROM tab1 AS cor0
----
-3573
-7605
-87

query I rowsort
SELECT DISTINCT col1 + col0 * + 42 * 47 AS col2 FROM tab2 cor0
----
13849
154031
155963

onlyif mysql # use DIV operator for integer division
query I rowsort label-583
SELECT + col0 DIV + col0 - 88 DIV + 95 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-583
SELECT + col0 / + col0 - 88 / + 95 FROM tab0 cor0
----
1
1
1

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

skipif mysql # not compatible
query I rowsort label-584
SELECT ALL cor0.col1 / - col0 + - 39 AS col0 FROM tab2 AS cor0
----
-39
-39
-43

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

query I rowsort
SELECT col2 - col2 * 32 AS col0 FROM tab2 AS cor0
----
-1178
-806
-837

query I rowsort
SELECT + + 79 * - col0 * col2 + - 32 FROM tab1 AS cor0
----
-12830
-288224
-606752

query I rowsort
SELECT + - 34 * + col0 + + col2 * + 32 * - col0 FROM tab2 AS cor0
----
-6286
-67548
-98750

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + col0 + col2 col1 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT - - col0 * col0 + + col1 * - col1 FROM tab2 AS cor0
----
-912
2603
5952

query I rowsort
SELECT DISTINCT - col2 * 90 AS col0 FROM tab2 AS cor0
----
-2340
-2430
-3420

query I rowsort
SELECT + + col0 * - 78 FROM tab2 cor0
----
-546
-6084
-6162

query I rowsort
SELECT DISTINCT + cor0.col2 + 14 AS col0 FROM tab1 cor0
----
110
68
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-595
SELECT ALL CAST( + col0 AS SIGNED ) * col1 DIV ( 50 + - col2 ) col2 FROM tab0 AS cor0
----
-253
121
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-595
SELECT ALL CAST ( + col0 AS INTEGER ) * col1 / ( 50 + - col2 ) col2 FROM tab0 AS cor0
----
-253
121
69

query I rowsort
SELECT DISTINCT - 5 * - col0 FROM tab0 AS cor0
----
120
175
445

query I rowsort
SELECT ALL + 5 - - col0 FROM tab2 cor0
----
12
83
84

query I rowsort
SELECT DISTINCT + 37 * - 37 FROM tab0, tab1 AS cor0
----
-1369

query I rowsort
SELECT ( col1 * tab2.col0 ) + - 28 AS col1 FROM tab2
----
1315
189
4574

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

query I rowsort
SELECT ALL - 61 - + cor0.col1 * + 36 FROM tab2, tab0 AS cor0
----
9 values hashing to 1207d1eb4633fba917730f45d0bee86c

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

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

query I rowsort
SELECT + col2 + + 88 AS col2 FROM tab1
----
142
145
184

onlyif mysql # use DIV operator for integer division
query I rowsort label-605
SELECT DISTINCT 31 DIV 69 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-605
SELECT DISTINCT 31 / 69 FROM tab2
----
0

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

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

query I rowsort
SELECT - 72 AS col2 FROM tab2
----
-72
-72
-72

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

query I rowsort
SELECT - ( col0 ) * + col0 AS col0 FROM tab1 AS cor0
----
-4096
-6400
-9

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

query I rowsort
SELECT - 95 AS col0 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to cf302b83f15b730fe35c19bdd9363c13

query I rowsort
SELECT DISTINCT 18 * cor0.col1 * - 59 AS col2 FROM tab1, tab2 AS cor0
----
-18054
-32922
-62658

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

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

query I rowsort
SELECT DISTINCT col0 * - col1 * col0 + tab0.col1 FROM tab0
----
-118728
-49450
-720720

query I rowsort
SELECT ALL col2 + col2 - ( - 45 ) AS col2 FROM tab1 AS cor0
----
153
159
237

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

query I rowsort
SELECT - tab2.col0 - tab2.col1 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to 679222606429bc7195f6dbd388ba1980

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

query I rowsort
SELECT - col0 * + 68 AS col0 FROM tab2
----
-476
-5304
-5372

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

query I rowsort
SELECT ALL + - col1 + + 38 * - cor0.col2 * + col1 AS col0 FROM tab1 AS cor0
----
-21670
-47437
-53378

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

skipif mysql # not compatible
query I rowsort label-624
SELECT DISTINCT - 33 / + 71 - col2 * col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

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

query I rowsort
SELECT DISTINCT col1 * ( - col2 * + col0 ) - + 79 * col2 FROM tab0 AS cor0
----
-3474
-670596
-70719

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

query I rowsort
SELECT + 45 * col2 * col0 + ( - ( + cor0.col0 ) ) AS col0 FROM tab0 AS cor0
----
1540
328321
35616

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

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

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

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

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

query I rowsort
SELECT DISTINCT + + 93 * ( + col2 ) AS col2 FROM tab2 cor0
----
2418
2511
3534

query I rowsort
SELECT ALL cor0.col1 + - 16 AS col0 FROM tab0 AS cor0
----
70
75
81

query I rowsort
SELECT - 56 * col0 + cor0.col1 * col1 FROM tab1 AS cor0
----
-3484
-4311
508

query I rowsort
SELECT DISTINCT 79 + + col1 FROM tab1 AS cor0
----
105
89
92

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

query I rowsort
SELECT DISTINCT - col1 * col2 + + col0 * - col0 AS col2 FROM tab1
----
-1413
-4666
-7648

query I rowsort
SELECT DISTINCT 4 + tab0.col0 * col2 AS col0 FROM tab0
----
39
7302
796

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

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

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

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

query I rowsort
SELECT ALL - col0 * col1 + tab2.col2 * + 23 * 1 AS col0 FROM tab2
----
-4004
-469
404

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

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT 96 + + col1 * - CAST ( col0 AS REAL ) * - col2 FROM tab1 AS cor0
----
36576
4308
99936

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

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

query I rowsort
SELECT - col2 + 88 * col1 FROM tab1 AS cor0
----
1048
2234
823

skipif mysql # not compatible
query I rowsort
SELECT ALL + col1 + CAST ( col1 AS REAL ) * - col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT - col0 * - 75 - - col1 FROM tab2 AS cor0
----
556
5909
5942

query I rowsort
SELECT ALL + col2 + - 11 * col2 AS col0 FROM tab2 AS cor0
----
-260
-270
-380

query I rowsort
SELECT + + col2 - 26 AS col2 FROM tab1 AS cor0
----
28
31
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-655
SELECT DISTINCT + col2 DIV + 65 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-655
SELECT DISTINCT + col2 / + 65 FROM tab2
----
0

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col1 * 40 col2 FROM tab0
----
3526
3731
3977

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

query I rowsort
SELECT ALL 10 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

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

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

query I rowsort
SELECT - col1 * + 78 FROM tab1 AS cor0
----
-1014
-2028
-780

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

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

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

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

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

query I rowsort
SELECT + col2 * col1 * - col2 + col2 FROM tab0 AS cor0
----
-611802
-93621
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col1 - - 21 * col2 col1 FROM tab0 AS cor0
----
-76
1631
607

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-668
SELECT ALL + - col1 DIV 59 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-668
SELECT ALL + - col1 / 59 AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-669
SELECT ALL + 68 DIV - 7 FROM tab1 cor0
----
-9
-9
-9

skipif mysql # not compatible
query I rowsort label-669
SELECT ALL + 68 / - 7 FROM tab1 cor0
----
-9
-9
-9

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

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

query I rowsort
SELECT DISTINCT - + 65 * - col2 AS col1 FROM tab0 AS cor0
----
2145
5330
65

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

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

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

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

query I rowsort
SELECT DISTINCT col1 * col2 - 34 AS col2 FROM tab2
----
1500
612
803

query I rowsort
SELECT col2 + - 2 - tab1.col2 * col1 AS col2 FROM tab1
----
-1154
-1352
-515

query I rowsort
SELECT col1 * + col0 - 73 AS col2 FROM tab0
----
1991
3322
8026

onlyif mysql # use DIV operator for integer division
query I rowsort label-680
SELECT ALL + col0 DIV 13 AS col1 FROM tab1
----
0
4
6

skipif mysql # not compatible
query I rowsort label-680
SELECT ALL + col0 / 13 AS col1 FROM tab1
----
0
4
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 55 * col0 * - col1 + col0 col0 FROM tab1 AS cor0
----
-35136
-4287
-57120

onlyif mysql # use DIV operator for integer division
query I rowsort label-682
SELECT ALL - tab1.col1 + + 40 * col2 DIV col0 - col1 FROM tab1
----
15
22
668

skipif mysql # not compatible
query I rowsort label-682
SELECT ALL - tab1.col1 + + 40 * col2 / col0 - col1 FROM tab1
----
15
22
668

onlyif mysql # use DIV operator for integer division
query I rowsort label-683
SELECT DISTINCT + col2 DIV + col2 + col2 * + cor0.col2 + - col1 FROM tab0 cor0
----
-95
1004
6634

skipif mysql # not compatible
query I rowsort label-683
SELECT DISTINCT + col2 / + col2 + col2 * + cor0.col2 + - col1 FROM tab0 cor0
----
-95
1004
6634

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-684
SELECT ALL - - ( col2 ) * CAST( 64 AS SIGNED ) col2 FROM tab0 AS cor0
----
2112
5248
64

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-684
SELECT ALL - - ( col2 ) * CAST ( 64 AS INTEGER ) col2 FROM tab0 AS cor0
----
2112
5248
64

query I rowsort
SELECT ALL - ( + col0 ) * cor0.col1 * + 56 FROM tab0 AS cor0
----
-115584
-190120
-453544

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

query I rowsort
SELECT ALL - - col1 + col1 * col1 * col1 FROM tab2 AS cor0
----
205438
29822
4930

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

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

query I rowsort
SELECT ALL + 46 * - cor0.col2 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 42d0451242676f1cf578fa24fe0c8dc5

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

skipif mysql # not compatible
query I rowsort label-690
SELECT ALL cor1.col2 * - CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-692
SELECT DISTINCT + + 36 * + col1 + - CAST( col0 AS SIGNED ) FROM tab2 AS cor0
----
1109
2046
533

skipif mysql # not compatible
query I rowsort label-692
SELECT DISTINCT + + 36 * + col1 + - CAST ( col0 AS INTEGER ) FROM tab2 AS cor0
----
1109
2046
533

query I rowsort
SELECT ALL 1 + col2 + 70 FROM tab2 cor0
----
109
97
98

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-696
SELECT ALL - + col0 DIV - col0 + - 17 FROM tab2 AS cor0
----
-16
-16
-16

skipif mysql # not compatible
query I rowsort label-696
SELECT ALL - + col0 / - col0 + - 17 FROM tab2 AS cor0
----
-16
-16
-16

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

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

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

query I rowsort
SELECT + col2 - col1 * tab0.col2 * col1 FROM tab0
----
-244035
-678960
-9408

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-701
SELECT + tab1.col2 DIV - col0 + + col2 AS col1 FROM tab1
----
36
57
95

skipif mysql # not compatible
query I rowsort label-701
SELECT + tab1.col2 / - col0 + + col2 AS col1 FROM tab1
----
36
57
95

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-703
SELECT - - col2 DIV + col1 - cor0.col1 AS col0 FROM tab2 AS cor0
----
-15
-31
-59

skipif mysql # not compatible
query I rowsort label-703
SELECT - - col2 / + col1 - cor0.col1 AS col0 FROM tab2 AS cor0
----
-15
-31
-59

query I rowsort
SELECT ALL col0 * col0 + - col2 * cor0.col2 AS col1 FROM tab1 AS cor0
----
-2816
-2907
847

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

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

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

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

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

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

query I rowsort
SELECT ALL - 33 + - col2 FROM tab2 AS cor0
----
-59
-60
-71

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

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

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

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

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

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( NULL ) IN ( - tab2.col1 )
----

query I rowsort
SELECT - col1 + tab1.col2 * + tab1.col0 + col1 * - tab1.col0 FROM tab1
----
2998
58
6627

query III rowsort
SELECT * FROM tab2 WHERE NOT col1 + + col2 + col0 IN ( - col0 * - col2 - col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT - col2 * col2 - - col2 AS col1 FROM tab2 WHERE NOT NULL BETWEEN col2 AND - col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col0 - col1 col2 FROM tab2
----
-1360
-248
-4661

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-721
SELECT - col2 - - col1 DIV col0 col2 FROM tab2
----
-23
-26
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-721
SELECT - col2 - - col1 / col0 col2 FROM tab2
----
-23
-26
-38

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

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

skipif mysql # not compatible
query I rowsort label-723
SELECT ALL - col0 + col2 / - tab1.col2 AS col2 FROM tab1
----
-4
-65
-81

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

query I rowsort
SELECT - col0 FROM tab0 WHERE - col0 + + col0 * col0 < ( NULL )
----

query I rowsort
SELECT + col1 * col0 + - col2 * - tab1.col1 + col0 FROM tab1
----
1274
1485
2368

query I rowsort
SELECT + - 82 AS col0 FROM tab1 AS cor0
----
-82
-82
-82

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-730
SELECT 68 DIV col1 AS col1 FROM tab1 AS cor0
----
2
5
6

skipif mysql # not compatible
query I rowsort label-730
SELECT 68 / col1 AS col1 FROM tab1 AS cor0
----
2
5
6

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

query I rowsort
SELECT ALL + col2 / + col0 AS col1 FROM tab2 AS cor0 WHERE NOT ( col2 * col1 ) BETWEEN col2 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-733
SELECT col2 + col1 * - col0 + col2 DIV + col2 AS col0 FROM tab1
----
-23
-582
-943

skipif mysql # not compatible
query I rowsort label-733
SELECT col2 + col1 * - col0 + col2 / + col2 AS col0 FROM tab1
----
-23
-582
-943

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

query III rowsort
SELECT ALL * FROM tab0 WHERE - col1 >= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-736
SELECT col1 * - col2 + col1 * col2 DIV + col0 FROM tab1
----
-1233
-562
-936

skipif mysql # not compatible
query I rowsort label-736
SELECT col1 * - col2 + col1 * col2 / + col0 FROM tab1
----
-1233
-562
-936

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

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

query I rowsort
SELECT col0 FROM tab0 WHERE ( col2 ) = ( NULL )
----

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

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

query I rowsort
SELECT ALL - 81 + col0 * col0 AS col2 FROM tab0 AS cor0
----
1144
495
7840

query I rowsort
SELECT DISTINCT - ( col1 ) * + 20 + - col1 AS col0 FROM tab1 AS cor0
----
-210
-273
-546

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-746
SELECT ALL + - col0 DIV + col0 + col1 AS col1 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-746
SELECT ALL + - col0 / + col0 + col1 AS col1 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT - - col1 + col2 * 30 AS col1 FROM tab2 AS cor0
----
1157
839
841

query I rowsort
SELECT - 42 + col0 AS col0 FROM tab1
----
-39
22
38

query I rowsort
SELECT ALL - 48 + - col0 * - col0 * col2 AS col2 FROM tab2 cor0
----
1275
158136
237110

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

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

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

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

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

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

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

query I rowsort
SELECT ALL - tab2.col0 FROM tab2, tab2 cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT - 87 * cor0.col1 AS col1 FROM tab1 AS cor0
----
-1131
-2262
-870

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

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

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

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

query I rowsort
SELECT DISTINCT + tab1.col1 * - ( col0 + + ( - col1 ) ) FROM tab1
----
-540
-871
598

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

query I rowsort
SELECT - 23 * col2 FROM tab2 cor0
----
-598
-621
-874

query I rowsort
SELECT ALL + - col0 + col2 * - 54 FROM tab2 AS cor0
----
-1465
-1482
-2131

query I rowsort
SELECT DISTINCT + + cor0.col0 * cor0.col2 + col0 - - 42 FROM tab1 AS cor0
----
207
3754
7802

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-765
SELECT ALL + - col0 * cor0.col1 DIV + col2 - - col2 FROM tab1 AS cor0
----
46
53
86

skipif mysql # not compatible
query I rowsort label-765
SELECT ALL + - col0 * cor0.col1 / + col2 - - col2 FROM tab1 AS cor0
----
46
53
86

query I rowsort
SELECT ALL + 71 * - col1 * + 74 FROM tab0 AS cor0
----
-451844
-478114
-509638

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

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

query I rowsort
SELECT - 35 + + col1 FROM tab0 AS cor0
----
51
56
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 33 * tab0.col0 col1 FROM tab0
----
1252
3028
878

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

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

skipif mysql # not compatible
query I rowsort label-771
SELECT DISTINCT - 66 / - col1 AS col1 FROM tab0 cor0
----
0

query I rowsort
SELECT - 54 + + col2 FROM tab1 AS cor0
----
0
3
42

query I rowsort
SELECT + cor0.col2 * - 15 FROM tab0 AS cor0
----
-1230
-15
-495

query I rowsort
SELECT ALL col2 * - col1 + col0 AS col1 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT ALL - + cor0.col0 * col2 * col0 + col1 * + col1 AS col1 FROM tab0 AS cor0
----
-11612
-641241
8184

query I rowsort
SELECT ALL cor0.col2 * - 14 + - col1 FROM tab2 AS cor0
----
-409
-423
-549

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

query I rowsort
SELECT DISTINCT - col1 - - 89 AS col1 FROM tab2 AS cor0
----
30
58
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-779
SELECT + col2 * + ( + col0 ) + - col0 DIV + 10 AS col2 FROM tab2 AS cor0
----
189
2021
2995

skipif mysql # not compatible
query I rowsort label-779
SELECT + col2 * + ( + col0 ) + - col0 / + 10 AS col2 FROM tab2 AS cor0
----
189
2021
2995

onlyif mysql # use DIV operator for integer division
query I rowsort label-780
SELECT DISTINCT + col0 + ( col2 ) DIV + col0 AS col0 FROM tab1 AS cor0
----
21
64
81

skipif mysql # not compatible
query I rowsort label-780
SELECT DISTINCT + col0 + ( col2 ) / + col0 AS col0 FROM tab1 AS cor0
----
21
64
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - 56 + 22 col2 FROM tab1 AS cor0
----
-1434
-538
-706

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

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

query I rowsort
SELECT ALL + - col2 * - 48 FROM tab2 cor0
----
1248
1296
1824

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

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

query I rowsort
SELECT col2 + 12 * - ( col2 ) AS col2 FROM tab1 AS cor0
----
-1056
-594
-627

onlyif mysql # use DIV operator for integer division
query I rowsort label-786
SELECT - col1 DIV col1 + - col1 * CAST( - 7 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
118
216
412

skipif mysql # not compatible
query I rowsort label-786
SELECT - col1 / col1 + - col1 * CAST ( - 7 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
118
216
412

onlyif mysql # use DIV operator for integer division
query I rowsort label-787
SELECT ALL - - col0 * - col2 + col0 DIV - 46 + - 21 AS col1 FROM tab1 AS cor0
----
-183
-3670
-7702

skipif mysql # not compatible
query I rowsort label-787
SELECT ALL - - col0 * - col2 + col0 / - 46 + - 21 AS col1 FROM tab1 AS cor0
----
-183
-3670
-7702

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

query I rowsort
SELECT + - 16 + 28 AS col1 FROM tab0 AS cor0
----
12
12
12

query I rowsort
SELECT DISTINCT 74 * col2 FROM tab2 AS cor0
----
1924
1998
2812

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-792
SELECT ALL + 23 DIV 74 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-792
SELECT ALL + 23 / 74 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 * 94 + col1 AS col0 FROM tab0
----
191
3188
7799

query I rowsort
SELECT col0 * - 89 + + col1 FROM tab0
----
-2050
-3018
-7830

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

skipif mysql # not compatible
query I rowsort label-795
SELECT - - col0 + CAST ( + col1 AS INTEGER ) * - col0 FROM tab0 cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT col2 * + col2 + 85 AS col1 FROM tab1 cor0
----
3001
3334
9301

query I rowsort
SELECT + col1 + - 39 * col2 * col0 FROM tab2 AS cor0
----
-117061
-7340
-79033

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

query I rowsort
SELECT + - 16 + - cor0.col0 AS col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 924e1641bd78deab362b5bdd9e181555

query I rowsort
SELECT ALL + ( col1 * - 35 ) FROM tab1
----
-350
-455
-910

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

query I rowsort
SELECT DISTINCT - 18 + - cor0.col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
-35
-49
-77

query I rowsort
SELECT ALL 37 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

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

query I rowsort
SELECT ALL - col0 * - 97 + + cor0.col1 AS col1 FROM tab1 AS cor0
----
317
6218
7773

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-807
SELECT ALL cor0.col2 * + 72 + + col0 DIV - col0 AS col1 FROM tab2 cor0
----
1871
1943
2735

skipif mysql # not compatible
query I rowsort label-807
SELECT ALL cor0.col2 * + 72 + + col0 / - col0 AS col1 FROM tab2 cor0
----
1871
1943
2735

query I rowsort
SELECT DISTINCT + col0 * 59 - 59 FROM tab2 cor0
----
354
4543
4602

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

query I rowsort
SELECT col1 + - 31 FROM tab1 AS cor0
----
-18
-21
-5

onlyif mysql # use DIV operator for integer division
query I rowsort label-811
SELECT DISTINCT - col2 DIV 86 AS col2 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-811
SELECT DISTINCT - col2 / 86 AS col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL + 93 * col0 + col0 * ( - 76 ) AS col0 FROM tab2
----
119
1326
1343

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

query I rowsort
SELECT DISTINCT + - cor0.col1 + 70 AS col0 FROM tab0, tab1 AS cor0
----
44
57
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-815
SELECT + - CAST( NULL AS DECIMAL ) - col2 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-815
SELECT + - CAST ( NULL AS REAL ) - col2 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

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

query I rowsort
SELECT - col0 + 6 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
6
6
6

query I rowsort
SELECT DISTINCT + cor0.col1 * 42 AS col1 FROM tab0 AS cor0
----
3612
3822
4074

onlyif mysql # use DIV operator for integer division
query I rowsort label-819
SELECT - 27 DIV - 99 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-819
SELECT - 27 / - 99 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL + - 43 + + col1 AS col2 FROM tab1 AS cor0
----
-17
-30
-33

query I rowsort
SELECT DISTINCT - cor0.col2 * col0 + + 80 * col2 FROM tab1 AS cor0
----
0
4158
912

query I rowsort
SELECT DISTINCT + + 70 + + col1 AS col0 FROM tab2 cor0
----
101
129
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-823
SELECT + + col2 DIV col0 + col1 FROM tab1 cor0
----
10
14
44

skipif mysql # not compatible
query I rowsort label-823
SELECT + + col2 / col0 + col1 FROM tab1 cor0
----
10
14
44

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

query I rowsort
SELECT + 86 + + col1 AS col2 FROM tab1 AS cor0
----
112
96
99

query I rowsort
SELECT - 58 * 57 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to e0dd320c964dcb6fe4c9489922c054ef

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

query I rowsort
SELECT - - cor0.col1 * - cor0.col2 + cor0.col0 * - 25 AS col0 FROM tab1 AS cor0
----
-1479
-2170
-3248

query I rowsort
SELECT 28 + - col0 AS col1 FROM tab0 AS cor0
----
-61
-7
4

query I rowsort
SELECT ALL + ( + col1 ) * - col0 * - cor0.col1 + col2 AS col2 FROM tab2 cor0
----
22869
271544
6754

query I rowsort
SELECT DISTINCT + 86 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
86

query I rowsort
SELECT 5 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 6035628694bdea36f584f3649088551d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-833
SELECT cor0.col1 + + col2 - CAST( + col1 + col2 * 48 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-1551
-3854
-47

skipif mysql # not compatible
query I rowsort label-833
SELECT cor0.col1 + + col2 - CAST ( + col1 + col2 * 48 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-1551
-3854
-47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col2 - col0 * + 26 col1 FROM tab0 AS cor0
----
-813
2214
5148

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

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

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

query I rowsort
SELECT - cor0.col0 + - ( 33 ) FROM tab0 AS cor0
----
-122
-57
-68

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

query I rowsort
SELECT + - 68 + 85 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT 19 + + col2 + ( col2 ) FROM tab1
----
127
133
211

query I rowsort
SELECT col0 + 80 AS col2 FROM tab1 AS cor0
----
144
160
83

query I rowsort
SELECT 10 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query I rowsort
SELECT - + col0 * - cor0.col1 + + 17 - - col1 FROM tab0 AS cor0
----
2167
3509
8207

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

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

skipif mysql # not compatible
query I rowsort label-845
SELECT - - col0 / col1 + - ( + col0 ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - - col2 * + col2 + + 12 FROM tab2 AS cor0
----
1456
688
741

query I rowsort
SELECT col2 * - 46 AS col2 FROM tab2
----
-1196
-1242
-1748

query I rowsort
SELECT ALL 38 + + ( col2 ) * col1 + - col0 FROM tab0
----
100
2852
7411

query I rowsort
SELECT col0 + + ( + col1 + col0 ) AS col2 FROM tab2
----
175
215
45

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + + CAST ( - 32 AS REAL ) * tab0.col2 AS col2 FROM tab0, tab1 AS cor0, tab1, tab0 AS cor1
----
-1056
-2624
-32

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

query I rowsort
SELECT + cor0.col2 * 34 AS col2 FROM tab0 AS cor0
----
1122
2788
34

query I rowsort
SELECT + - col0 * + 96 AS col0 FROM tab1 AS cor0
----
-288
-6144
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-854
SELECT DISTINCT col0 + 17 DIV + col0 col1 FROM tab1 cor0
----
64
8
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-854
SELECT DISTINCT col0 + 17 / + col0 col1 FROM tab1 cor0
----
64
8
80

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

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

skipif mysql # not compatible
query I rowsort label-856
SELECT + 17 / cor0.col1 FROM tab2 AS cor0
----
0
0
1

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

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

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

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

query I rowsort
SELECT + - 30 + - col1 FROM tab0 AS cor0
----
-116
-121
-127

query I rowsort
SELECT ALL + - 5 * + col0 AS col1 FROM tab2 cor0
----
-35
-390
-395

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

query I rowsort
SELECT DISTINCT - 82 + - col2 * - ( col1 + col2 ) AS col2 FROM tab0 AS cor0
----
14104
16
3845

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

query I rowsort
SELECT col1 + col1 * 29 FROM tab0 AS cor0
----
2580
2730
2910

query I rowsort
SELECT DISTINCT 55 + cor0.col0 AS col2 FROM tab1 AS cor0
----
119
135
58

query I rowsort
SELECT DISTINCT ( col2 + - 11 * tab2.col2 ) FROM tab2
----
-260
-270
-380

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

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

query I rowsort
SELECT DISTINCT col0 + ( col2 + col1 ) FROM tab0 AS cor0
----
133
143
262

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

query I rowsort
SELECT DISTINCT col1 + - col1 * col1 + col2 FROM tab0 AS cor0
----
-7277
-8108
-9311

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

query I rowsort
SELECT 88 * - tab1.col2 + - ( + 48 ) AS col2 FROM tab1
----
-4800
-5064
-8496

query I rowsort
SELECT - col1 * col0 + - 10 + - 98 * col2 FROM tab2
----
-2873
-5077
-7160

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

query I rowsort
SELECT DISTINCT - col1 * + 58 FROM tab2 AS cor0
----
-1798
-3422
-986

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

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

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

query I rowsort
SELECT + col2 * ( 44 ) AS col0 FROM tab0 AS cor0
----
1452
3608
44

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

query I rowsort
SELECT ALL + col0 * + col2 + - 14 - col1 * col1 AS col1 FROM tab1 AS cor0
----
-528
3534
7497

query I rowsort
SELECT ALL + col0 + - ( 85 * cor0.col2 ) FROM tab2 AS cor0
----
-2132
-2288
-3151

query I rowsort
SELECT ALL + + 39 + 48 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT ALL col0 * - 78 FROM tab1
----
-234
-4992
-6240

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

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

query I rowsort
SELECT 83 + + 46 FROM tab1, tab0 AS cor0
----
9 values hashing to 418f1c817ef9b3406f572acab9f54796

query I rowsort
SELECT col1 + - 28 AS col1 FROM tab0 AS cor0
----
58
63
69

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-890
SELECT DISTINCT cor0.col2 + col1 DIV + col2 AS col0 FROM tab0 cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-890
SELECT DISTINCT cor0.col2 + col1 / + col2 AS col0 FROM tab0 cor0
----
35
83
98

query I rowsort
SELECT ALL col1 - - 6 FROM tab2
----
23
37
65

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 * col2 ) + - ( - col2 ) - col1 * + 78 col2 FROM tab1
----
-1812
2925
6762

query I rowsort
SELECT - ( + 65 ) * - col2 - - col0 * col2 FROM tab2
----
1944
3718
5472

query I rowsort
SELECT ALL + 69 + col1 AS col0 FROM tab0 cor0
----
155
160
166

query I rowsort
SELECT DISTINCT - + 30 * col0 FROM tab0 AS cor0
----
-1050
-2670
-720

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

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

query I rowsort
SELECT DISTINCT + 24 * + ( + col0 + tab0.col2 ) FROM tab0
----
1368
4104
864

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

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

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

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

query I rowsort
SELECT DISTINCT - 51 * - cor0.col0 FROM tab0 AS cor0
----
1224
1785
4539

query I rowsort
SELECT - cor0.col0 * cor0.col0 - + 80 AS col0 FROM tab2 AS cor0
----
-129
-6164
-6321

onlyif mysql # use DIV operator for integer division
query I rowsort label-905
SELECT + col0 * col2 - CAST( - 80 AS SIGNED ) DIV col0 AS col2 FROM tab0 AS cor0
----
37
7298
795

skipif mysql # not compatible
query I rowsort label-905
SELECT + col0 * col2 - CAST ( - 80 AS INTEGER ) / col0 AS col2 FROM tab0 AS cor0
----
37
7298
795

onlyif mysql # use DIV operator for integer division
query I rowsort label-906
SELECT DISTINCT - 48 * col0 * - col1 - 8 * col2 DIV - 23 AS col0 FROM tab1 AS cor0
----
30739
3762
49953

skipif mysql # not compatible
query I rowsort label-906
SELECT DISTINCT - 48 * col0 * - col1 - 8 * col2 / - 23 AS col0 FROM tab1 AS cor0
----
30739
3762
49953

query I rowsort
SELECT col1 + - col2 * 23 AS col2 FROM tab2 AS cor0
----
-539
-590
-857

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

query I rowsort
SELECT ALL col0 + + col0 * - 69 + - col2 * - col2 AS col2 FROM tab0 AS cor0
----
-2379
-543
672

query I rowsort
SELECT ALL - 97 * col0 + cor0.col1 AS col2 FROM tab0 AS cor0
----
-2242
-3298
-8542

query I rowsort
SELECT ( col2 ) + + 71 AS col1 FROM tab0 AS cor0
----
104
153
72

query I rowsort
SELECT DISTINCT - - 50 - cor0.col0 AS col1 FROM tab1 AS cor0
----
-14
-30
47

query I rowsort
SELECT DISTINCT 77 * 4 * - col0 FROM tab1 cor0
----
-19712
-24640
-924

query I rowsort
SELECT DISTINCT + ( - 50 * + col0 ) FROM tab2
----
-350
-3900
-3950

query I rowsort
SELECT DISTINCT + ( - col2 ) * - col1 * tab2.col2 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT 98 * 16 FROM tab1
----
1568
1568
1568

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

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

query I rowsort
SELECT - 87 * - col1 AS col0 FROM tab1
----
1131
2262
870

query I rowsort
SELECT - ( + 30 ) FROM tab0
----
-30
-30
-30

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

query I rowsort
SELECT - - 70 * + ( col2 ) + 62 FROM tab0 AS cor0
----
132
2372
5802

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

query I rowsort
SELECT col1 * + col1 + col2 * + 94 FROM tab0 AS cor0
----
10498
15989
9503

onlyif mysql # use DIV operator for integer division
query I rowsort label-924
SELECT - - col0 + col0 * col2 DIV 59 FROM tab0 AS cor0
----
212
35
37

skipif mysql # not compatible
query I rowsort label-924
SELECT - - col0 + col0 * col2 / 59 FROM tab0 AS cor0
----
212
35
37

query I rowsort
SELECT - 23 * col1 + ( + col1 ) FROM tab1 AS cor0
----
-220
-286
-572

query I rowsort
SELECT - + ( + col0 ) * 17 + col0 * cor0.col1 FROM tab1 AS cor0
----
-320
-448
27

query I rowsort
SELECT DISTINCT - 48 FROM tab2, tab0 cor0
----
-48

onlyif mysql # use DIV operator for integer division
query I rowsort label-928
SELECT ALL cor0.col1 DIV + 12 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to bbb27326c926bed56f07f4b0660b3cff

skipif mysql # not compatible
query I rowsort label-928
SELECT ALL cor0.col1 / + 12 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to bbb27326c926bed56f07f4b0660b3cff

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

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col2 + + CAST ( col2 AS REAL ) FROM tab0 AS cor0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 - ( - col0 ) * col1 col0 FROM tab1 AS cor0
----
1120
704
81

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

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

query I rowsort
SELECT DISTINCT + col0 * col0 + - col2 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT DISTINCT + col1 * - col0 + col1 * col1 FROM tab2 AS cor0
----
-1054
-1121
744

query I rowsort
SELECT - + col0 * col1 + 38 FROM tab0 AS cor0
----
-2026
-3357
-8061

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

query I rowsort
SELECT - - 89 * col0 * - col2 + - 69 FROM tab2 AS cor0
----
-16890
-180561
-267247

query I rowsort
SELECT - 69 + - 82 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to f40aa0b5c301d6179d07413f4c2d6796

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + 6 + + tab1.col2 col0 FROM tab1
----
34
53
89

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-941
SELECT ALL + - col2 * CAST ( col2 AS INTEGER ) col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT + col1 + + 45 * col0 AS col0 FROM tab0 AS cor0
----
1166
1672
4096

query I rowsort
SELECT - col2 * col2 - - col2 * - cor0.col1 FROM tab0 AS cor0
----
-14186
-3927
-98

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

skipif mysql # not compatible
query I rowsort label-944
SELECT DISTINCT tab2.col1 / tab2.col0 FROM tab2, tab2 AS cor0
----
0
4

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

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

query I rowsort
SELECT DISTINCT + col2 * + tab1.col2 + - 63 FROM tab1
----
2853
3186
9153

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

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

query I rowsort
SELECT ALL - col1 * ( + col2 * 87 ) AS col2 FROM tab0 AS cor0
----
-246906
-649194
-8439

query I rowsort
SELECT + col0 * 48 + col1 AS col2 FROM tab2 AS cor0
----
367
3803
3809

query I rowsort
SELECT - 61 - + 78 FROM tab1 AS cor0
----
-139
-139
-139

onlyif mysql # use DIV operator for integer division
query I rowsort label-953
SELECT ALL - 77 DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-953
SELECT ALL - 77 / col1 FROM tab0
----
0
0
0

query I rowsort
SELECT + cor1.col2 AS col2 FROM tab1, tab0 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * col0 + cor0.col0 col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT + + col1 + + 36 FROM tab1 AS cor0
----
46
49
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-957
SELECT - + cor0.col2 + col1 * CAST( - col2 AS SIGNED ) FROM tab2 AS cor0
----
-1560
-684
-864

skipif mysql # not compatible
query I rowsort label-957
SELECT - + cor0.col2 + col1 * CAST ( - col2 AS INTEGER ) FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT - 35 * - cor0.col2 FROM tab1 AS cor0
----
1890
1995
3360

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

query I rowsort
SELECT - 52 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 9500afe5646d620d5e8943351a29d082

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

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

query I rowsort
SELECT ALL - + 24 AS col0 FROM tab2, tab1 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to ad9e2feda1bc3d52e1a836279e031a8b

query I rowsort
SELECT - + col2 + 1 AS col2 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT DISTINCT - 46 + col2 FROM tab2 cor0
----
-19
-20
-8

query I rowsort
SELECT + + 97 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
5238
5529
9312

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col2 * col1 + - CAST ( + col2 AS REAL ) * - col0 FROM tab0 AS cor0
----
132
14760
3630

query I rowsort
SELECT - col2 * col2 + + 80 FROM tab2
----
-1364
-596
-649

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 12 + - cor0.col1 col1 FROM tab2 AS cor0
----
-19
-47
-5

query I rowsort
SELECT ALL + 50 - - col2 * + col2 FROM tab1 AS cor0
----
2966
3299
9266

query I rowsort
SELECT DISTINCT - 70 * col2 + 40 FROM tab2 AS cor0
----
-1780
-1850
-2620

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + tab1.col0 * 52 col2 FROM tab1
----
210
3385
4256

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

query I rowsort
SELECT DISTINCT col0 + - ( + col1 ) * + col0 - col2 FROM tab1
----
-1056
-129
-633

query I rowsort
SELECT 1 * + tab2.col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT - + col0 * + ( + col0 ) * - col0 + col2 FROM tab2 AS cor0
----
370
474578
493077

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

query I rowsort
SELECT + - col0 * 27 + col2 AS col2 FROM tab0 AS cor0
----
-2321
-615
-944

query I rowsort
SELECT DISTINCT + + ( - 90 ) AS col0 FROM tab2 AS cor0
----
-90

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

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

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

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

query I rowsort
SELECT DISTINCT - 19 + + col2 FROM tab1 cor0
----
35
38
77

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 21 + col1 * col2 * col0 col2 FROM tab1 AS cor0
----
36501
4233
99861

query I rowsort
SELECT DISTINCT + + ( - 97 ) + - col1 AS col2 FROM tab1 AS cor0
----
-107
-110
-123

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

query I rowsort
SELECT DISTINCT - 94 * cor0.col2 + tab1.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 3a350f605a239776e9e21280c8650698

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

query I rowsort
SELECT + ( + col1 ) * col0 + col2 * + col2 AS col2 FROM tab1 AS cor0
----
10256
2994
3889

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

skipif mysql # not compatible
query I rowsort label-990
SELECT ALL tab0.col0 * CAST ( NULL AS INTEGER ) / + 41 FROM tab0
----
NULL
NULL
NULL

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

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

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

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

query I rowsort
SELECT DISTINCT 25 + + 22 AS col2 FROM tab0
----
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-995
SELECT DISTINCT col1 * col1 + + col0 - col0 DIV col2 AS col1 FROM tab1 AS cor0
----
163
249
679

skipif mysql # not compatible
query I rowsort label-995
SELECT DISTINCT col1 * col1 + + col0 - col0 / col2 AS col1 FROM tab1 AS cor0
----
163
249
679

query I rowsort
SELECT DISTINCT - col1 * + 94 - col0 * col0 AS col2 FROM tab1
----
-2453
-5036
-7622

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

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

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

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

query I rowsort
SELECT DISTINCT ( - 36 ) + + col0 AS col2 FROM tab2
----
-29
42
43

query I rowsort
SELECT DISTINCT 49 + ( col1 ) + col0 AS col1 FROM tab1
----
123
142
78

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

skipif mysql # not compatible
query I rowsort label-1002
SELECT - col2 / - col0 + col2 * col1 AS col0 FROM tab2
----
1534
646
840

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

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

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

query I rowsort
SELECT 62 + + col0 * col0 AS col1 FROM tab0 AS cor0
----
1287
638
7983

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1007
SELECT + 50 * col2 * - col1 + col1 * col2 DIV - col0 FROM tab0
----
-142018
-373183
-4852

skipif mysql # not compatible
query I rowsort label-1007
SELECT + 50 * col2 * - col1 + col1 * col2 / - col0 FROM tab0
----
-142018
-373183
-4852

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

skipif mysql # not compatible
query I rowsort label-1008
SELECT ALL - CAST ( NULL AS REAL ) * 32 + tab0.col0 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT 89 * - col0 FROM tab0
----
-2136
-3115
-7921

query I rowsort
SELECT ALL col0 * + col0 + col2 * + tab0.col1 + col2 AS col1 FROM tab0
----
1323
15465
3447

query I rowsort
SELECT DISTINCT + 55 + col1 + tab2.col1 * tab2.col2 FROM tab2
----
1648
718
923

query I rowsort
SELECT DISTINCT + col2 + 53 * - col1 * - cor0.col2 FROM tab2 AS cor0
----
34276
44388
81328

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

skipif mysql # not compatible
query I rowsort label-1013
SELECT ALL + col2 / 50 + - col1 + col1 AS col2 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT - col1 * col1 + - 51 * + col1 FROM tab0 AS cor0
----
-11782
-12922
-14356

query I rowsort
SELECT DISTINCT - - col2 - - 99 * - col2 AS col2 FROM tab2 AS cor0
----
-2548
-2646
-3724

query I rowsort
SELECT ALL + col1 * + col0 + col0 * + col0 FROM tab2 AS cor0
----
10686
266
7584

query I rowsort
SELECT + col0 * 57 AS col2 FROM tab2 AS cor0
----
399
4446
4503

query I rowsort
SELECT DISTINCT col1 + 2 * + 25 FROM tab1 cor0
----
60
63
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1019
SELECT - + col2 * - CAST( col2 * cor0.col1 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
22599
24548
39884

skipif mysql # not compatible
query I rowsort label-1019
SELECT - + col2 * - CAST ( col2 * cor0.col1 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT col1 * 88 AS col0 FROM tab0 AS cor0
----
7568
8008
8536

query I rowsort
SELECT ALL - col2 - + 14 FROM tab1 AS cor0
----
-110
-68
-71

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

query I rowsort
SELECT ALL col1 * - 54 AS col2 FROM tab1 AS cor0
----
-1404
-540
-702

query I rowsort
SELECT col0 * col2 * 77 + - 84 AS col2 FROM tab2
----
14469
156072
231070

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

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

skipif mysql # not compatible
query I rowsort label-1026
SELECT tab0.col0 / - 51 AS col1 FROM tab0
----
-1
0
0

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

skipif mysql # not compatible
query I rowsort label-1027
SELECT DISTINCT col2 * - CAST ( - col1 AS INTEGER ) - + col0 FROM tab2
----
1456
567
830

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1030
SELECT ALL - cor0.col2 DIV + 53 + col0 FROM tab0 AS cor0
----
24
35
88

skipif mysql # not compatible
query I rowsort label-1030
SELECT ALL - cor0.col2 / + 53 + col0 FROM tab0 AS cor0
----
24
35
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-1031
SELECT DISTINCT + cor0.col2 DIV 90 + - col0 - col2 FROM tab1 cor0
----
-121
-175
-57

skipif mysql # not compatible
query I rowsort label-1031
SELECT DISTINCT + cor0.col2 / 90 + - col0 - col2 FROM tab1 cor0
----
-121
-175
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-1032
SELECT ALL - col2 DIV tab0.col1 + + col0 * 84 AS col0 FROM tab0
----
2016
2940
7476

skipif mysql # not compatible
query I rowsort label-1032
SELECT ALL - col2 / tab0.col1 + + col0 * 84 AS col0 FROM tab0
----
2016
2940
7476

query I rowsort
SELECT ALL - + 73 AS col2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 2931474b870c05694e446771031a6949

query I rowsort
SELECT DISTINCT 46 + col2 * + col1 + col2 AS col0 FROM tab0
----
144
2917
7590

query I rowsort
SELECT ALL - ( col0 ) * 64 AS col0 FROM tab1 cor0
----
-192
-4096
-5120

query I rowsort
SELECT ALL - ( - tab2.col2 ) AS col2 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT + col1 + + col0 * 9 FROM tab2 AS cor0
----
728
761
94

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

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

query I rowsort
SELECT - - col0 + + cor0.col1 * + 68 AS col1 FROM tab1 AS cor0
----
1771
744
964

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

query I rowsort
SELECT DISTINCT col1 + col2 + - ( + 26 ) * + col1 * ( col1 * - tab1.col2 ) FROM tab1
----
148267
421933
949184

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

query I rowsort
SELECT col2 - ( cor0.col1 + col1 ) FROM tab1 AS cor0
----
2
37
70

query I rowsort
SELECT DISTINCT + 88 * col0 FROM tab1 cor0
----
264
5632
7040

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

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

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

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

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

query I rowsort
SELECT ALL - + col0 * ( - col1 ) + 43 AS col0 FROM tab2 AS cor0
----
1386
260
4645

query I rowsort
SELECT - 49 + col0 * - col2 * - col2 FROM tab0 AS cor0
----
-14
26087
598387

query I rowsort
SELECT ALL cor0.col0 * 95 FROM tab1 AS cor0
----
285
6080
7600

query I rowsort
SELECT DISTINCT - 95 + col1 AS col1 FROM tab1 cor0
----
-69
-82
-85

query I rowsort
SELECT DISTINCT + + col2 * ( + col2 ) + + col2 AS col1 FROM tab0 AS cor0
----
1122
2
6806

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

query I rowsort
SELECT - - col2 + - col2 * col2 FROM tab0 AS cor0
----
-1056
-6642
0

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1056
SELECT DISTINCT CAST ( NULL AS REAL ) col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
NULL

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1060
SELECT - ( col0 ) + + 38 DIV + col2 FROM tab0 AS cor0
----
-23
-89
3

skipif mysql # not compatible
query I rowsort label-1060
SELECT - ( col0 ) + + 38 / + col2 FROM tab0 AS cor0
----
-23
-89
3

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

query I rowsort
SELECT DISTINCT - ( 32 ) AS col1 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
-32

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

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

query I rowsort
SELECT + - 62 + - col0 * - col2 FROM tab0 AS cor0
----
-27
7236
730

query I rowsort
SELECT DISTINCT - ( 6 + + tab0.col2 ) FROM tab0
----
-39
-7
-88

query I rowsort
SELECT + 88 * cor0.col1 FROM tab0 AS cor0
----
7568
8008
8536

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

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

query I rowsort
SELECT DISTINCT + col2 * col0 + - ( - col2 + + col2 * col0 ) FROM tab0 AS cor0
----
1
33
82

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

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

query I rowsort
SELECT cor0.col0 * cor0.col0 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 458b4c13e6825f9686b15a38663930f4

query I rowsort
SELECT - - col0 * 45 + col0 AS col0 FROM tab2 cor0
----
322
3588
3634

query I rowsort
SELECT DISTINCT 62 + col0 AS col1 FROM tab1
----
126
142
65

query I rowsort
SELECT col0 * - 0 * - col2 FROM tab0
----
0
0
0

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

skipif mysql # not compatible
query I rowsort label-1076
SELECT - col2 * ( + col2 ) + CAST ( + col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT DISTINCT - 97 - col2 FROM tab1 AS cor0
----
-151
-154
-193

onlyif mysql # use DIV operator for integer division
query I rowsort label-1078
SELECT + cor0.col1 DIV - col2 + col1 * ( - 82 + col0 ) FROM tab0 AS cor0
----
-4656
-4990
636

skipif mysql # not compatible
query I rowsort label-1078
SELECT + cor0.col1 / - col2 + col1 * ( - 82 + col0 ) FROM tab0 AS cor0
----
-4656
-4990
636

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

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

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

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

query I rowsort
SELECT DISTINCT 4 * + col2 AS col1 FROM tab2 AS cor0
----
104
108
152

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col0 ) * + cor0.col0 col1 FROM tab0 cor0
----
-1225
-576
-7921

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

query I rowsort
SELECT ALL - + col2 * + 66 + col0 AS col0 FROM tab1 AS cor0
----
-3561
-3698
-6256

query I rowsort
SELECT ALL 87 + col0 FROM tab0 AS cor0
----
111
122
176

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 72 + col0 col2 FROM tab0 AS cor0
----
107
161
96

query I rowsort
SELECT 45 * + col1 + - col1 FROM tab1 cor0
----
1144
440
572

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1090
SELECT DISTINCT 58 + col0 DIV + cor0.col1 FROM tab2 cor0
----
58
59
62

skipif mysql # not compatible
query I rowsort label-1090
SELECT DISTINCT 58 + col0 / + cor0.col1 FROM tab2 cor0
----
58
59
62

query I rowsort
SELECT - col0 + + 60 + - 32 AS col0 FROM tab2
----
-50
-51
21

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

skipif mysql # not compatible
query I rowsort label-1092
SELECT CAST ( NULL AS INTEGER ) * 61 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

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

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

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

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

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

query I rowsort
SELECT DISTINCT + ( - cor0.col2 ) + - col0 + 52 * - 12 * - col2 FROM tab2 AS cor0
----
16120
16814
23595

query I rowsort
SELECT ALL 92 * - 75 + col1 * col0 * + 24 FROM tab2
----
-1692
103548
25332

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

query I rowsort
SELECT ( 4 ) * - col2 AS col1 FROM tab0
----
-132
-328
-4

query I rowsort
SELECT - 31 * col2 AS col1 FROM tab1 AS cor0
----
-1674
-1767
-2976

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - ( 15 ) + - col2 col2 FROM tab1 AS cor0
----
-39
-42
-81

query I rowsort
SELECT col0 * + col0 - col0 * + ( col2 ) * 56 AS col0 FROM tab0
----
-400767
-43776
-735

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

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

query I rowsort
SELECT col1 + col2 - + tab0.col2 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT - + col1 + - 1 FROM tab0 AS cor0
----
-87
-92
-98

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * col0 + - col2 col2 FROM tab0 AS cor0
----
2031
3394
8017

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

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

query I rowsort
SELECT ALL + col2 * 86 AS col0 FROM tab2 AS cor0
----
2236
2322
3268

query I rowsort
SELECT DISTINCT + col2 * 1 * - 59 FROM tab2 AS cor0
----
-1534
-1593
-2242

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

query I rowsort
SELECT DISTINCT 89 + cor0.col2 * col2 FROM tab0 AS cor0
----
1178
6813
90

query I rowsort
SELECT 81 - 10 AS col1 FROM tab2 cor0
----
71
71
71

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

query I rowsort
SELECT + 53 + cor0.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 2cd14832f76a56e635b1e88e89f255c7

query I rowsort
SELECT - col0 + + 80 AS col1 FROM tab0 AS cor0
----
-9
45
56

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

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

query I rowsort
SELECT ALL ( + cor0.col1 ) * - 91 FROM tab2 AS cor0
----
-1547
-2821
-5369

onlyif mysql # use DIV operator for integer division
query I rowsort label-1123
SELECT DISTINCT 48 DIV - 93 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
0

skipif mysql # not compatible
query I rowsort label-1123
SELECT DISTINCT 48 / - 93 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
0

query I rowsort
SELECT DISTINCT col0 * - col0 * 37 FROM tab0
----
-21312
-293077
-45325

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + + 8 * + cor0.col0 FROM tab0 AS cor0
----
192
280
712

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1132
SELECT + + cor0.col0 / ( cor0.col2 ) col1 FROM tab0 AS cor0
----
0
1
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-1133
SELECT ALL - col0 DIV 28 FROM tab1 AS cor0
----
-2
-2
0

skipif mysql # not compatible
query I rowsort label-1133
SELECT ALL - col0 / 28 FROM tab1 AS cor0
----
-2
-2
0

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

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

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

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

query I rowsort
SELECT DISTINCT - col1 + + 3 * + col0 AS col1 FROM tab1 AS cor0
----
-17
182
227

query I rowsort
SELECT ALL - 21 * col1 * + col1 AS col2 FROM tab2
----
-20181
-6069
-73101

onlyif mysql # use DIV operator for integer division
query I rowsort label-1138
SELECT - col1 + + col2 DIV 58 FROM tab1
----
-10
-12
-26

skipif mysql # not compatible
query I rowsort label-1138
SELECT - col1 + + col2 / 58 FROM tab1
----
-10
-12
-26

query I rowsort
SELECT - + 35 + col0 AS col2 FROM tab1 AS cor0
----
-32
29
45

query I rowsort
SELECT + cor0.col0 AS col0 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

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

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

query I rowsort
SELECT 28 + col0 FROM tab0 AS cor0
----
117
52
63

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

skipif mysql # not compatible
query I rowsort label-1143
SELECT ALL + CAST ( NULL AS INTEGER ) * 5 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + - 70 * + col0 AS col1 FROM tab0 AS cor0
----
-1680
-2450
-6230

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

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

query I rowsort
SELECT ALL + col1 * 14 + col2 * + col0 FROM tab1
----
3788
526
7862

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 61 * col2 col2 FROM tab0
----
2013
5002
61

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

query I rowsort
SELECT ALL + cor2.col0 - 22 AS col1 FROM tab1, tab1 cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 3685607c8c7cd8c427ac079e0d553ced

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

query I rowsort
SELECT ALL - - col0 * - col0 + - col2 * col2 AS col1 FROM tab2 AS cor0
----
-6760
-7685
-778

query I rowsort
SELECT ALL - ( + col2 ) - - ( - 54 ) FROM tab0 cor0
----
-136
-55
-87

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

query I rowsort
SELECT ALL col0 * col2 * col0 - col0 AS col2 FROM tab0 AS cor0
----
1190
18984
649433

query I rowsort
SELECT + 86 * - col0 FROM tab2 cor0
----
-602
-6708
-6794

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

skipif mysql # not compatible
query I rowsort
SELECT cor0.col0 * + CAST ( col0 AS REAL ) + + col0 * + 59 AS col2 FROM tab0 AS cor0
----
13172
1992
3290

onlyif mysql # use DIV operator for integer division
query I rowsort label-1160
SELECT - col2 * 50 * + 53 + col1 - col2 DIV col2 FROM tab0 AS cor0
----
-217210
-2554
-87365

skipif mysql # not compatible
query I rowsort label-1160
SELECT - col2 * 50 * + 53 + col1 - col2 / col2 FROM tab0 AS cor0
----
-217210
-2554
-87365

query I rowsort
SELECT + col0 * - ( col1 * col1 ) + + cor0.col0 * 63 FROM tab0 AS cor0
----
-175992
-327110
-731402

onlyif mysql # use DIV operator for integer division
query I rowsort label-1162
SELECT - col2 * col1 DIV + col0 FROM tab1 AS cor0
----
-15
-468
-8

skipif mysql # not compatible
query I rowsort label-1162
SELECT - col2 * col1 / + col0 FROM tab1 AS cor0
----
-15
-468
-8

query I rowsort
SELECT - col1 * col2 * + col1 + cor0.col0 FROM tab1 AS cor0
----
-16144
-36501
-5636

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * ( - cor0.col0 ) + cor0.col0 col2 FROM tab1 AS cor0
----
-4032
-6
-6320

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

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

query I rowsort
SELECT DISTINCT - col1 * - 50 + + col2 FROM tab1 AS cor0
----
1354
557
746

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

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

skipif mysql # not compatible
query I rowsort label-1170
SELECT - col2 * col2 * CAST ( - col0 AS INTEGER ) FROM tab0 cor0
----
26136
35
598436

query I rowsort
SELECT ALL + - 93 + - col0 AS col1 FROM tab1 AS cor0
----
-157
-173
-96

query I rowsort
SELECT DISTINCT - col0 + + col0 * col2 AS col1 FROM tab1 cor0
----
159
3584
7600

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 65 * col0 * + col1 col1 FROM tab0 AS cor0
----
-134160
-220675
-526435

onlyif mysql # use DIV operator for integer division
query I rowsort label-1175
SELECT DISTINCT + ( + col2 ) * 25 + + col2 DIV + col2 FROM tab1 AS cor0
----
1351
1426
2401

skipif mysql # not compatible
query I rowsort label-1175
SELECT DISTINCT + ( + col2 ) * 25 + + col2 / + col2 FROM tab1 AS cor0
----
1351
1426
2401

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

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

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

query I rowsort
SELECT - ( col1 ) * + ( + 31 ) FROM tab0 AS cor0
----
-2666
-2821
-3007

query I rowsort
SELECT ALL - 87 * - col2 AS col2 FROM tab1 AS cor0
----
4698
4959
8352

query I rowsort
SELECT ALL + 28 + - col0 * 59 AS col2 FROM tab2 AS cor0
----
-385
-4574
-4633

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

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

query I rowsort
SELECT - col0 * 73 + + 56 * - cor0.col1 FROM tab2 AS cor0
----
-2247
-6719
-8998

onlyif mysql # use DIV operator for integer division
query I rowsort label-1183
SELECT col1 * col1 DIV - 30 FROM tab1
----
-22
-3
-5

skipif mysql # not compatible
query I rowsort label-1183
SELECT col1 * col1 / - 30 FROM tab1
----
-22
-3
-5

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

query I rowsort
SELECT - - col1 * 65 + col0 + col2 * ( col2 ) AS col0 FROM tab1 AS cor0
----
10141
3963
4609

query I rowsort
SELECT ALL 74 - + col1 * tab0.col1 AS col0 FROM tab0
----
-7322
-8207
-9335

query I rowsort
SELECT DISTINCT 12 * - col1 - + 11 * + col2 AS col1 FROM tab0
----
-1175
-1395
-1994

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 47 col0 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

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

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

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

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

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

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

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

query I rowsort
SELECT - 97 * col1 + - col2 AS col0 FROM tab0
----
-8375
-8909
-9410

query I rowsort
SELECT ALL 83 * + col2 FROM tab2
----
2158
2241
3154

query I rowsort
SELECT DISTINCT - col2 * + col1 + col2 + - ( - col1 ) FROM tab0 AS cor0
----
-2719
-7289
1

query I rowsort
SELECT + 89 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 860d55eb6785972467218a9c3badb5ad

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

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

query I rowsort
SELECT ALL - 55 + col0 AS col0 FROM tab1 AS cor0
----
-52
25
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-1203
SELECT ALL - 54 DIV cor0.col0 + + col2 AS col2 FROM tab0 AS cor0
----
0
31
82

skipif mysql # not compatible
query I rowsort label-1203
SELECT ALL - 54 / cor0.col0 + + col2 AS col2 FROM tab0 AS cor0
----
0
31
82

query I rowsort
SELECT ALL col1 + + col2 * + col1 AS col2 FROM tab1
----
1261
1430
580

query I rowsort
SELECT ALL + col1 + col1 * - col0 * tab1.col0 + col2 AS col2 FROM tab1
----
-154
-40893
-83091

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

query I rowsort
SELECT col0 * 4 FROM tab2
----
28
312
316

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

query I rowsort
SELECT ALL - 6 FROM tab0, tab2 cor0
----
9 values hashing to e92b2679faac7be63701967e3f0c0934

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

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

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

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

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

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

query I rowsort
SELECT - + ( col0 ) * col1 + - col0 * col0 AS col2 FROM tab0 AS cor0
----
-16020
-2640
-4620

query I rowsort
SELECT ALL - col2 + + col1 * - col0 * col0 FROM tab2 AS cor0
----
-106135
-1546
-358982

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1218
SELECT - col2 * col2 + - cor0.col2 * CAST ( col1 * col1 AS INTEGER ) FROM tab1 AS cor0
----
-25440
-39420
-8949

query I rowsort
SELECT 84 * col1 + cor0.col2 * 7 AS col2 FROM tab2 AS cor0
----
1694
2793
5138

query I rowsort
SELECT - col1 + tab2.col2 * - col2 AS col2 FROM tab2
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT - col1 * 90 + 33 FROM tab2
----
-1497
-2757
-5277

query I rowsort
SELECT DISTINCT - tab1.col1 + + col0 * 49 * - col2 FROM tab1
----
-178762
-376333
-7964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col0 + 80 col0 FROM tab2
----
129
6164
6321

onlyif mysql # use DIV operator for integer division
query I rowsort label-1224
SELECT DISTINCT col1 + col0 DIV - col1 AS col2 FROM tab1 AS cor0
----
26
4
7

skipif mysql # not compatible
query I rowsort label-1224
SELECT DISTINCT col1 + col0 / - col1 AS col2 FROM tab1 AS cor0
----
26
4
7

query I rowsort
SELECT ALL - 28 - col1 AS col1 FROM tab1 cor0
----
-38
-41
-54

query I rowsort
SELECT ALL - 27 * + col0 AS col2 FROM tab0 AS cor0
----
-2403
-648
-945

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1227
SELECT ALL CAST( col2 AS SIGNED ) * cor0.col1 + - col1 * + col1 - cor0.col2 FROM tab2 AS cor0
----
-151
-1973
319

skipif mysql # not compatible
query I rowsort label-1227
SELECT ALL CAST ( col2 AS INTEGER ) * cor0.col1 + - col1 * + col1 - cor0.col2 FROM tab2 AS cor0
----
-151
-1973
319

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 94 col2 FROM tab0, tab2 AS cor0
----
9 values hashing to a95bfa539191d3f72f6548147d7efb9e

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

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

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

query I rowsort
SELECT 32 * + col2 AS col2 FROM tab0
----
1056
2624
32

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

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

query I rowsort
SELECT - 18 * + tab1.col1 FROM tab1
----
-180
-234
-468

query I rowsort
SELECT + 62 + - col2 * col1 AS col0 FROM tab2
----
-1472
-584
-775

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1240
SELECT - col0 / col2 + + ( - col1 ) FROM tab0 AS cor0
----
-132
-86
-92

query I rowsort
SELECT ALL + + col2 + col1 + col0 * col1 AS col2 FROM tab0 AS cor0
----
2183
3493
8272

query I rowsort
SELECT + - col1 * - col0 + 69 AS col1 FROM tab0 cor0
----
2133
3464
8168

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

query I rowsort
SELECT ALL 30 AS col2 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

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

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

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

query I rowsort
SELECT DISTINCT - col2 * col1 - - 93 FROM tab0
----
-2745
-4
-7369

query I rowsort
SELECT - 56 AS col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to a228dfb9ede9780b082a5a3dfb2fca80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 33 col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 76da8bc7cae18ecf856438f872430c80

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

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

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

query I rowsort
SELECT - col1 * 1 + - 60 AS col1 FROM tab0 AS cor0
----
-146
-151
-157

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

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

query I rowsort
SELECT DISTINCT - + cor0.col1 * + col2 + + 60 - - col1 FROM tab0 AS cor0
----
-2692
-7311
60

query I rowsort
SELECT - + col1 * + col1 + + col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1258
SELECT DISTINCT + col2 * CAST( 86 AS SIGNED ) - - col2 * 84 AS col1 FROM tab0 cor0
----
13940
170
5610

skipif mysql # not compatible
query I rowsort label-1258
SELECT DISTINCT + col2 * CAST ( 86 AS INTEGER ) - - col2 * 84 AS col1 FROM tab0 cor0
----
13940
170
5610

query I rowsort
SELECT DISTINCT - - col1 + ( 71 ) FROM tab0 AS cor0
----
157
162
168

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

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

query I rowsort
SELECT + ( + 92 ) * + cor0.col1 AS col0 FROM tab1 AS cor0
----
1196
2392
920

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1263
SELECT DISTINCT 51 / + col1 col0 FROM tab0
----
0

query I rowsort
SELECT + 3 * - col2 FROM tab1 AS cor0
----
-162
-171
-288

query I rowsort
SELECT - - col0 * - 6 AS col2 FROM tab2 AS cor0
----
-42
-468
-474

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 3 * col2 col2 FROM tab2 cor0
----
-114
-78
-81

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

query I rowsort
SELECT ALL + col2 + + 43 FROM tab2
----
69
70
81

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

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

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

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

query I rowsort
SELECT DISTINCT + col0 * + 66 + col1 AS col1 FROM tab0 AS cor0
----
1670
2407
5965

query I rowsort
SELECT DISTINCT - ( + 79 ) - + col2 FROM tab0 AS cor0
----
-112
-161
-80

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

query I rowsort
SELECT DISTINCT - + ( cor0.col1 ) AS col0 FROM tab0 AS cor0
----
-86
-91
-97

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

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

skipif mysql # not compatible
query I rowsort label-1279
SELECT CAST ( - ( + col1 ) AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-86
-91
-97

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

query I rowsort
SELECT - + cor0.col0 + 56 AS col1 FROM tab1 cor0
----
-24
-8
53

query I rowsort
SELECT ALL - - col1 * + 29 + col1 * 65 FROM tab0 AS cor0
----
8084
8554
9118

query I rowsort
SELECT DISTINCT col0 + cor0.col2 * col0 * col1 + - col1 FROM tab0 cor0
----
3333
664116
68050

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1287
SELECT ( cor0.col0 ) DIV - col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1287
SELECT ( cor0.col0 ) / - col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + 19 * - col2 + + col2 AS col2 FROM tab2 AS cor0
----
-468
-486
-684

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

query I rowsort
SELECT DISTINCT + 57 * cor0.col0 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
399
4446
4503

query I rowsort
SELECT DISTINCT col1 + - col0 * - col2 * - col1 FROM tab0
----
-3298
-664027
-68026

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

skipif mysql # not compatible
query I rowsort label-1292
SELECT - col2 + + col2 * + CAST ( + col1 + col1 AS INTEGER ) * CAST ( col1 + col2 * - col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-264519
-3856658
-6040918

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

query I rowsort
SELECT DISTINCT 32 + + col1 * + 54 FROM tab2 AS cor0
----
1706
3218
950

query I rowsort
SELECT - - col1 * + col2 + + 99 FROM tab1 AS cor0
----
1347
1503
669

query I rowsort
SELECT - col2 + - col0 * 90 FROM tab0 AS cor0
----
-2193
-3151
-8092

query I rowsort
SELECT ALL + + ( col2 ) * 29 FROM tab0 AS cor0
----
2378
29
957

query I rowsort
SELECT DISTINCT - - ( cor0.col2 ) + 85 FROM tab2 AS cor0
----
111
112
123

query I rowsort
SELECT DISTINCT - - 56 * - col1 AS col0 FROM tab1 cor0
----
-1456
-560
-728

query I rowsort
SELECT - + 25 + + col2 * 22 AS col0 FROM tab2 cor0
----
547
569
811

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + col2 col0 FROM tab2 AS cor0
----
-189
-2028
-3002

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

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

query I rowsort
SELECT ALL - + cor0.col0 * ( 51 ) FROM tab0 AS cor0
----
-1224
-1785
-4539

onlyif mysql # use DIV operator for integer division
query I rowsort label-1306
SELECT ALL + col1 + + tab0.col1 DIV ( + col2 ) AS col2 FROM tab0
----
194
88
92

skipif mysql # not compatible
query I rowsort label-1306
SELECT ALL + col1 + + tab0.col1 / ( + col2 ) AS col2 FROM tab0
----
194
88
92

query I rowsort
SELECT - ( + col0 ) + + 2 FROM tab0
----
-22
-33
-87

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col2 + 41 col2 FROM tab2 AS cor0
----
14
15
3

query I rowsort
SELECT ALL cor0.col0 * 20 AS col2 FROM tab1 AS cor0
----
1280
1600
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-1311
SELECT DISTINCT - + col2 DIV col1 + - col0 * + col0 * col0 FROM tab2 AS cor0
----
-343
-474552
-493041

skipif mysql # not compatible
query I rowsort label-1311
SELECT DISTINCT - + col2 / col1 + - col0 * + col0 * col0 FROM tab2 AS cor0
----
-343
-474552
-493041

query I rowsort
SELECT ALL + - col0 + - col1 * 93 FROM tab2 AS cor0
----
-1660
-2890
-5565

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

skipif mysql # not compatible
query I rowsort label-1313
SELECT + col1 * - CAST ( col0 AS INTEGER ) + col1 * - col2 AS col2 FROM tab1 AS cor0
----
-1210
-1482
-2288

query I rowsort
SELECT - col0 * - ( col0 ) * - col1 + col1 * + col2 AS col1 FROM tab0 AS cor0
----
-118728
-46698
-713349

query I rowsort
SELECT ALL + ( col2 * col2 ) + 45 FROM tab0
----
1134
46
6769

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

query I rowsort
SELECT col0 + - col1 + 81 AS col0 FROM tab1
----
135
148
58

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1319
SELECT + + col1 DIV - 61 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1319
SELECT + + col1 / - 61 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + 56 + col0 * + col0 AS col0 FROM tab1 cor0
----
4152
6456
65

query I rowsort
SELECT ALL cor0.col0 * cor0.col0 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 4829ede06f586935ff95a5b0dfdb9199

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

query I rowsort
SELECT ALL - ( - ( tab0.col0 ) ) - 93 * col2 AS col0 FROM tab0
----
-3045
-58
-7537

query I rowsort
SELECT col0 * + col0 + tab2.col2 + ( - tab2.col0 ) FROM tab2
----
6032
6200
69

query I rowsort
SELECT DISTINCT ( cor0.col2 + + 40 ) FROM tab0, tab2 AS cor0
----
66
67
78

query I rowsort
SELECT ALL 93 + col1 * + col2 AS col1 FROM tab1
----
1341
1497
663

query I rowsort
SELECT DISTINCT col1 * + tab0.col0 + - 49 * - col0 FROM tab0
----
12460
3240
5110

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

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

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

query I rowsort
SELECT ALL + 84 FROM tab2, tab2 cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

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

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0 CROSS JOIN tab1 WHERE NOT NULL < ( NULL )
----

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

skipif mysql # not compatible
query I rowsort label-1334
SELECT - CAST ( - col2 AS INTEGER ) * col0 FROM tab1 cor0
----
162
3648
7680

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

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

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

query I rowsort
SELECT 87 + col0 AS col2 FROM tab0 AS cor0
----
111
122
176

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - ( + col1 + col1 ) * + col0 col2 FROM tab2
----
-102068
-11718
-239304

query I rowsort
SELECT - - col1 * ( - 27 ) - col0 AS col2 FROM tab2 AS cor0
----
-1671
-538
-844

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

query I rowsort
SELECT ALL - 91 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 745d1c3a09d935465cad552325c5c945

query I rowsort
SELECT + col0 * 42 AS col0 FROM tab2 AS cor0
----
294
3276
3318

query I rowsort
SELECT col0 + 38 AS col2 FROM tab0 AS cor0
----
127
62
73

query I rowsort
SELECT - 52 * col0 - - cor0.col1 AS col1 FROM tab1 AS cor0
----
-130
-3318
-4147

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

query I rowsort
SELECT + cor0.col1 + 93 AS col1 FROM tab0 cor0
----
179
184
190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 60 + + col2 + col0 * col1 col2 FROM tab1 AS cor0
----
1196
192
757

query I rowsort
SELECT + 88 + - ( + col2 ) AS col0 FROM tab0 AS cor0
----
55
6
87

query I rowsort
SELECT col2 * 12 AS col1 FROM tab1
----
1152
648
684

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

query I rowsort
SELECT ALL + tab0.col2 * - col2 + - tab0.col1 * col0 * 53 AS col0 FROM tab0
----
-110481
-179936
-435971

query I rowsort
SELECT DISTINCT + col0 * + col1 + + 2 * - tab2.col0 AS col2 FROM tab2
----
1185
203
4446

query I rowsort
SELECT DISTINCT 80 + 3 * col0 FROM tab2 AS cor0
----
101
314
317

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

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

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

query IIIIII rowsort
SELECT ALL * FROM tab0, tab1 AS cor0 WHERE NULL IN ( cor0.col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - cor0.col1 + - col2 * + 85 col2 FROM tab2 AS cor0
----
-3256
-3519
-5691

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

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

query I rowsort
SELECT ALL col0 * + col1 * 76 AS col0 FROM tab2
----
102068
16492
349752

query I rowsort
SELECT ALL + 15 FROM tab0, tab2, tab2 cor0, tab1
----
81 values hashing to 97c4e033347d2076218e240ed49af0a7

query I rowsort
SELECT DISTINCT 70 - + col0 * col0 AS col0 FROM tab2
----
-6014
-6171
21

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

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + 74 * col0 + col2 * CAST ( 8 AS REAL ) + + col0 FROM tab0
----
2064
2633
7331

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

query I rowsort
SELECT DISTINCT col1 + 20 AS col0 FROM tab1
----
30
33
46

query I rowsort
SELECT col1 + - col2 - col2 * col0 FROM tab2
----
-185
-1995
-3023

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

query I rowsort
SELECT col2 * + col1 + - col1 + - col2 FROM tab1
----
1139
1324
503

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col1 * col2 col1 FROM tab2
----
1612
725
844

query I rowsort
SELECT DISTINCT 93 AS col2 FROM tab2
----
93

query I rowsort
SELECT DISTINCT + + cor0.col0 + 66 * + 52 * col0 AS col2 FROM tab1 AS cor0
----
10299
219712
274640

query I rowsort
SELECT DISTINCT cor0.col1 * + col2 + + 85 FROM tab0 AS cor0
----
182
2923
7547

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

query I rowsort
SELECT DISTINCT + + col0 + - col2 * - 31 FROM tab1 AS cor0
----
1677
1831
3056

query I rowsort
SELECT ALL - col0 * col1 + col1 * col0 * col1 AS col0 FROM tab0
----
175440
325920
728910

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

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

query I rowsort
SELECT DISTINCT - 71 AS col0 FROM tab2
----
-71

query I rowsort
SELECT - col1 + + 43 AS col2 FROM tab2
----
-16
12
26

query I rowsort
SELECT + + col2 + 68 FROM tab1 AS cor0
----
122
125
164

onlyif mysql # use DIV operator for integer division
query I rowsort label-1384
SELECT col1 + + 36 * col1 DIV + col1 AS col2 FROM tab1
----
46
49
62

skipif mysql # not compatible
query I rowsort label-1384
SELECT col1 + + 36 * col1 / + col1 AS col2 FROM tab1
----
46
49
62

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1386
SELECT - col2 + + cor0.col0 DIV col0 AS col2 FROM tab1 AS cor0
----
-53
-56
-95

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

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

query I rowsort
SELECT 66 * + col2 AS col0 FROM tab1
----
3564
3762
6336

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col1 + + 56 col2 FROM tab1 AS cor0
----
-1192
-1348
-514

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

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

query I rowsort
SELECT ALL + + col0 * + 88 + - col2 - col2 FROM tab1 AS cor0
----
156
5518
6848

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

query I rowsort
SELECT - col0 * col1 + + ( col2 ) FROM tab1
----
-24
-583
-944

query I rowsort
SELECT ALL + col1 + + col2 * 31 FROM tab0 AS cor0
----
1109
128
2633

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

query I rowsort
SELECT + col2 + - 28 FROM tab0 AS cor0
----
-27
5
54

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

query I rowsort
SELECT DISTINCT + cor0.col0 + + 52 + - 5 FROM tab0 AS cor0
----
136
71
82

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1400
SELECT + col2 * ( + ( - col2 ) ) / - col0 col2 FROM tab0 AS cor0
----
0
45
75

query I rowsort
SELECT ALL - col2 + 18 FROM tab1 cor0
----
-36
-39
-78

query I rowsort
SELECT DISTINCT + - col2 * 1 AS col1 FROM tab0 cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-1403
SELECT col1 * col2 DIV + col0 FROM tab1 AS cor0
----
15
468
8

skipif mysql # not compatible
query I rowsort label-1403
SELECT col1 * col2 / + col0 FROM tab1 AS cor0
----
15
468
8

query I rowsort
SELECT DISTINCT col0 + - col0 * 27 FROM tab1 AS cor0
----
-1664
-2080
-78

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

query I rowsort
SELECT ALL + col2 + - col2 * - col0 FROM tab1 WHERE NULL NOT IN ( col2 + col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1407
SELECT DISTINCT tab0.col0 DIV tab0.col2 + - col0 - - col2 FROM tab0
----
-6
1
9

skipif mysql # not compatible
query I rowsort label-1407
SELECT DISTINCT tab0.col0 / tab0.col2 + - col0 - - col2 FROM tab0
----
-6
1
9

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

query I rowsort
SELECT DISTINCT - col0 * + col0 + + col2 * col2 + + col1 FROM tab2
----
-4780
-5349
711

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1411
SELECT col2 * col1 DIV - col0 AS col0 FROM tab2
----
-119
-19
-8

skipif mysql # not compatible
query I rowsort label-1411
SELECT col2 * col1 / - col0 AS col0 FROM tab2
----
-119
-19
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-1412
SELECT DISTINCT + col2 * + col0 DIV tab0.col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1412
SELECT DISTINCT + col2 * + col0 / tab0.col0 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT col2 + col2 - - col1 AS col0 FROM tab0
----
152
255
99

query I rowsort
SELECT DISTINCT col1 + - tab2.col2 - + col2 * - tab2.col0 AS col2 FROM tab2
----
193
2061
2981

onlyif mysql # use DIV operator for integer division
query I rowsort label-1415
SELECT + col2 * col0 + col2 DIV - col2 FROM tab0
----
34
7297
791

skipif mysql # not compatible
query I rowsort label-1415
SELECT + col2 * col0 + col2 / - col2 FROM tab0
----
34
7297
791

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT col2 + col0 > NULL
----

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

query I rowsort
SELECT ALL col1 + col1 * ( - 61 ) AS col1 FROM tab1 AS cor0
----
-1560
-600
-780

onlyif mysql # use DIV operator for integer division
query I rowsort label-1419
SELECT + - col1 DIV col0 + col2 AS col0 FROM tab0 AS cor0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-1419
SELECT + - col1 / col0 + col2 AS col0 FROM tab0 AS cor0
----
-1
30
81

query I rowsort
SELECT 65 AS col2 FROM tab0, tab2 cor0, tab2 AS cor1, tab2 cor2
----
81 values hashing to 1654646feeae82f39d2f564fe4ea26c2

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 53 + col1 col0 FROM tab2 AS cor0
----
-22
-36
6

query I rowsort
SELECT DISTINCT col1 + cor0.col0 + ( col0 * + col0 ) FROM tab2 AS cor0
----
6221
6337
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-1424
SELECT ALL - col1 * + col1 * - col1 - col2 DIV - col0 FROM tab0
----
636057
753571
912673

skipif mysql # not compatible
query I rowsort label-1424
SELECT ALL - col1 * + col1 * - col1 - col2 / - col0 FROM tab0
----
636057
753571
912673

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

query I rowsort
SELECT DISTINCT - col0 + col2 * col2 * + col0 AS col0 FROM tab2 AS cor0
----
113997
5096
52650

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

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

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

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

query I rowsort
SELECT - col1 - col0 * 48 AS col2 FROM tab2 AS cor0
----
-367
-3803
-3809

query I rowsort
SELECT ALL + ( - col1 ) + col0 * 71 AS col2 FROM tab0 AS cor0
----
1618
2388
6228

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

query I rowsort
SELECT - - 48 - + cor0.col2 AS col2 FROM tab0 AS cor0
----
-34
15
47

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

skipif mysql # not compatible
query I rowsort label-1435
SELECT - - col1 * col0 + 80 / col0 - col1 * 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 - cor0.col0 + - col1 * col0 col1 FROM tab2 AS cor0
----
-1422
-224
-4680

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

query I rowsort
SELECT DISTINCT 88 * - col0 AS col0 FROM tab0 AS cor0
----
-2112
-3080
-7832

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

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

skipif mysql # not compatible
query I rowsort label-1440
SELECT ALL + col1 / - col0 AS col2 FROM tab1 cor0
----
-8
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1441
SELECT 34 DIV 92 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-1441
SELECT 34 / 92 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + - 99 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 64d06513850a26495bc6c2fddeb254b7

query I rowsort
SELECT DISTINCT + 98 * col1 FROM tab1 AS cor0
----
1274
2548
980

query I rowsort
SELECT + col0 * - 59 FROM tab1 AS cor0
----
-177
-3776
-4720

query I rowsort
SELECT ALL 88 + col2 AS col1 FROM tab0 cor0
----
121
170
89

query I rowsort
SELECT ALL + 26 * 69 + col1 AS col1 FROM tab1 AS cor0
----
1804
1807
1820

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1447
SELECT + + CAST( - cor0.col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-1447
SELECT + + CAST ( - cor0.col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

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

query I rowsort
SELECT 79 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

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

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

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

query I rowsort
SELECT ( + ( - col1 ) + + 66 * col1 ) FROM tab1
----
1690
650
845

query I rowsort
SELECT + - col2 * cor0.col2 + - cor0.col0 + ( col2 ) AS col2 FROM tab2 AS cor0
----
-1485
-709
-728

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

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

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

query I rowsort
SELECT DISTINCT + ( cor0.col0 ) + 91 AS col0 FROM tab2, tab0 AS cor0
----
115
126
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-1457
SELECT DISTINCT - ( col2 ) * - col0 + 59 * col0 DIV col1 FROM tab1 AS cor0
----
168
4025
8043

skipif mysql # not compatible
query I rowsort label-1457
SELECT DISTINCT - ( col2 ) * - col0 + 59 * col0 / col1 FROM tab1 AS cor0
----
168
4025
8043

onlyif mysql # use DIV operator for integer division
query I rowsort label-1458
SELECT 65 + 31 DIV col2 FROM tab1
----
65
65
65

skipif mysql # not compatible
query I rowsort label-1458
SELECT 65 + 31 / col2 FROM tab1
----
65
65
65

query I rowsort
SELECT ALL - col0 * col2 - - col0 AS col1 FROM tab1 AS cor0
----
-159
-3584
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-1460
SELECT + 93 DIV col0 AS col0 FROM tab2
----
1
1
13

skipif mysql # not compatible
query I rowsort label-1460
SELECT + 93 / col0 AS col0 FROM tab2
----
1
1
13

onlyif mysql # use DIV operator for integer division
query I rowsort label-1461
SELECT tab0.col0 DIV col0 - + col1 * + col0 FROM tab0
----
-2063
-3394
-8098

skipif mysql # not compatible
query I rowsort label-1461
SELECT tab0.col0 / col0 - + col1 * + col0 FROM tab0
----
-2063
-3394
-8098

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

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

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

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

query I rowsort
SELECT + 59 FROM tab1, tab2 cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

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

query I rowsort
SELECT ALL - 97 FROM tab2, tab0 cor0
----
9 values hashing to e4a6bd848a69226cbb7ad3d154be321b

query I rowsort
SELECT DISTINCT - col1 * col1 + cor0.col2 * col0 + cor0.col1 AS col1 FROM tab2 AS cor0
----
-1394
-741
2730

query I rowsort
SELECT DISTINCT - 23 * col0 + + col0 - + col2 AS col1 FROM tab1 AS cor0
----
-120
-1465
-1856

query I rowsort
SELECT - 73 + - cor0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 1525dd7e30930d73f1ded25dfe0a9e61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1472
SELECT - CAST( + 46 AS SIGNED ) * + col0 FROM tab2 AS cor0
----
-322
-3588
-3634

skipif mysql # not compatible
query I rowsort label-1472
SELECT - CAST ( + 46 AS INTEGER ) * + col0 FROM tab2 AS cor0
----
-322
-3588
-3634

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

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

query I rowsort
SELECT + - 96 * cor0.col2 * cor0.col1 FROM tab1 cor0
----
-119808
-134784
-54720

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

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

query I rowsort
SELECT DISTINCT ( + 88 ) * - col0 FROM tab1
----
-264
-5632
-7040

query I rowsort
SELECT ALL col1 * col1 + - col1 FROM tab1 AS cor0 WHERE NULL BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1479
SELECT DISTINCT col2 + - col1 DIV col1 FROM tab1
----
53
56
95

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

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

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

skipif mysql # not compatible
query I rowsort label-1481
SELECT tab2.col2 / col1 AS col0 FROM tab2
----
0
0
2

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

query I rowsort
SELECT ALL + col0 * - col0 + col2 + col2 FROM tab1 AS cor0
----
-3982
-6208
99

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

query III rowsort
SELECT ALL * FROM tab2 WHERE - col1 BETWEEN ( - tab2.col1 ) AND NULL
----

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

query I rowsort
SELECT + col2 FROM tab2 WHERE col1 + - col1 IN ( tab2.col0 )
----

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

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

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

query I rowsort
SELECT col0 + tab0.col2 * col0 FROM tab0
----
70
7387
816

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

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

query I rowsort
SELECT - col1 * cor0.col0 + - col2 * + col0 AS col1 FROM tab1 cor0
----
-240
-4288
-8720

query IIIIIIIII rowsort
SELECT * FROM tab2, tab0, tab0 AS cor0 WHERE NULL <> NULL
----

query III rowsort
SELECT * FROM tab2 WHERE col1 BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT DISTINCT + col0 * col0 + - col0 + - col0 FROM tab0
----
1155
528
7743

query I rowsort
SELECT col1 * - col1 * col2 + tab0.col0 AS col0 FROM tab0
----
-244044
-678953
-9374

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

query I rowsort
SELECT - 31 * cor0.col1 + col2 FROM tab0 cor0
----
-2633
-2739
-3006

query I rowsort
SELECT ALL - + ( - 64 ) * + col2 FROM tab1 AS cor0
----
3456
3648
6144

query I rowsort
SELECT DISTINCT - tab1.col0 + + col1 - - 43 FROM tab1
----
-11
-24
66

query I rowsort
SELECT ALL 73 * - col0 FROM tab2 AS cor0
----
-511
-5694
-5767

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

query I rowsort
SELECT ALL - 88 + + 5 * col2 FROM tab0 AS cor0
----
-83
322
77

query I rowsort
SELECT DISTINCT + col1 + tab2.col0 * col1 * col2 + + col2 * - col1 FROM tab2
----
118177
50405
5053

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

query I rowsort
SELECT ALL - col2 + - cor0.col0 * - ( 74 ) * col0 FROM tab1 AS cor0
----
303047
473504
612

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1510
SELECT 47 * col2 + col2 DIV col1 AS col2 FROM tab2 AS cor0
----
1222
1269
1788

skipif mysql # not compatible
query I rowsort label-1510
SELECT 47 * col2 + col2 / col1 AS col2 FROM tab2 AS cor0
----
1222
1269
1788

query I rowsort
SELECT - - col2 * col0 * ( 39 ) + - col0 FROM tab0 cor0
----
1330
284533
30864

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

query I rowsort
SELECT ALL col1 + - col1 + tab0.col2 FROM tab0
----
1
33
82

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

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

query I rowsort
SELECT ALL + col0 + - col2 + cor0.col1 AS col0 FROM tab1 cor0
----
-25
-3
17

query I rowsort
SELECT + col2 + + 18 FROM tab2 AS cor0
----
44
45
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + 16 + 80 * - cor0.col0 col0 FROM tab0 AS cor0
----
-1248
-544
-5664

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

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

query I rowsort
SELECT + col2 + - 94 AS col0 FROM tab0 AS cor0
----
-12
-61
-93

query I rowsort
SELECT DISTINCT - + col1 + col0 * + 42 AS col0 FROM tab1 AS cor0
----
100
2678
3347

onlyif mysql # use DIV operator for integer division
query I rowsort label-1523
SELECT ALL + cor0.col1 + 48 * ( + col2 + 15 ) DIV col2 FROM tab1 AS cor0
----
68
70
87

skipif mysql # not compatible
query I rowsort label-1523
SELECT ALL + cor0.col1 + 48 * ( + col2 + 15 ) / col2 FROM tab1 AS cor0
----
68
70
87

query I rowsort
SELECT col0 + - cor0.col1 * - 72 FROM tab2 AS cor0
----
1303
2239
4326

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

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

query I rowsort
SELECT - - 24 FROM tab0, tab2, tab0 cor0
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

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

query I rowsort
SELECT + cor1.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT 94 * cor0.col0 AS col1 FROM tab2 cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 37799307c40b8bf4649b145620e74df5

onlyif mysql # use DIV operator for integer division
query I rowsort label-1531
SELECT col2 + + col1 DIV + col2 + col0 AS col1 FROM tab1
----
121
176
57

skipif mysql # not compatible
query I rowsort label-1531
SELECT col2 + + col1 / + col2 + col0 AS col1 FROM tab1
----
121
176
57

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1532
SELECT - - cor0.col0 / - ( col0 + - col1 * col1 ) col2 FROM tab0 AS cor0
----
0
0
0

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

query I rowsort
SELECT - col2 + + 51 FROM tab2 AS cor0
----
13
24
25

query I rowsort
SELECT DISTINCT 64 + 2 AS col0 FROM tab0, tab2 AS cor0
----
66

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

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

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

query I rowsort
SELECT + ( - col1 ) * + col1 + cor0.col1 FROM tab1 AS cor0
----
-156
-650
-90

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1541
SELECT - ( + col1 ) DIV - col1 + cor0.col0 AS col2 FROM tab2 AS cor0
----
79
8
80

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

query I rowsort
SELECT ( col1 ) * col2 * - 25 + - 18 + - col1 * col2 AS col2 FROM tab1 cor0
----
-14838
-32466
-36522

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

query I rowsort
SELECT col0 * col1 + 4 * + 91 * col0 AS col0 FROM tab0
----
10800
16135
40495

query I rowsort
SELECT ALL - 85 * col2 + col2 * 34 * col1 AS col1 FROM tab0 AS cor0
----
246738
3213
93687

query I rowsort
SELECT ALL - col0 + - col0 * 4 FROM tab2 AS cor0
----
-35
-390
-395

query I rowsort
SELECT DISTINCT 8 * - cor0.col0 - col2 FROM tab1 AS cor0
----
-569
-736
-78

query I rowsort
SELECT ALL - 83 - col2 FROM tab2 AS cor0
----
-109
-110
-121

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

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

query I rowsort
SELECT DISTINCT - + col1 + 6 AS col0 FROM tab1 AS cor0
----
-20
-4
-7

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

query I rowsort
SELECT DISTINCT + cor0.col1 + ( col1 ) + col2 AS col2 FROM tab2 AS cor0
----
144
72
89

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

query I rowsort
SELECT - 62 + 18 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 07457d9e571e036a9a3a0f5a5a2e1ef2

onlyif mysql # use DIV operator for integer division
query I rowsort label-1556
SELECT - 66 DIV cor0.col0 AS col0 FROM tab1 AS cor0
----
-1
-22
0

skipif mysql # not compatible
query I rowsort label-1556
SELECT - 66 / cor0.col0 AS col0 FROM tab1 AS cor0
----
-1
-22
0

query I rowsort
SELECT + col0 * col1 * + 45 AS col0 FROM tab2 AS cor0
----
207090
60435
9765

query I rowsort
SELECT DISTINCT + tab2.col1 * 96 FROM tab2
----
1632
2976
5664

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - 53 * - col2 AS REAL ) AS col0 FROM tab0
----
1749
4346
53

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1561
SELECT DISTINCT + 15 DIV col2 AS col2 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-1561
SELECT DISTINCT + 15 / col2 AS col2 FROM tab1
----
0

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

query I rowsort
SELECT DISTINCT + 18 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
18

query I rowsort
SELECT cor0.col1 * 39 FROM tab1, tab1 cor0
----
9 values hashing to bb790270e532ac3c3e5adf5b4097c5c6

query I rowsort
SELECT DISTINCT - + col2 * + col2 * + 73 FROM tab0 AS cor0
----
-490852
-73
-79497

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

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

query I rowsort
SELECT DISTINCT - 35 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
-35

query I rowsort
SELECT 60 + - col0 * + ( - tab0.col1 ) AS col2 FROM tab0
----
2124
3455
8159

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

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

query I rowsort
SELECT + cor0.col2 + + 75 * - col2 AS col0 FROM tab1 AS cor0
----
-3996
-4218
-7104

query I rowsort
SELECT - - 24 + 38 AS col0 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

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

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

query I rowsort
SELECT col0 + ( + col2 ) * ( + 65 ) * col2 FROM tab2 AS cor0
----
44018
47392
93939

onlyif mysql # use DIV operator for integer division
query I rowsort label-1576
SELECT + CAST( - 33 AS SIGNED ) + col1 DIV 64 + + col1 AS col2 FROM tab0 AS cor0
----
54
59
65

skipif mysql # not compatible
query I rowsort label-1576
SELECT + CAST ( - 33 AS INTEGER ) + col1 / 64 + + col1 AS col2 FROM tab0 AS cor0
----
54
59
65

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

query I rowsort
SELECT col0 + 55 FROM tab2
----
133
134
62

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

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

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

query I rowsort
SELECT - col0 + - 64 FROM tab1 AS cor0
----
-128
-144
-67

query I rowsort
SELECT + 79 + 24 * - col0 * 90 FROM tab1 AS cor0
----
-138161
-172721
-6401

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

query I rowsort
SELECT DISTINCT - 73 + + ( col2 + - col2 ) FROM tab0
----
-73

query I rowsort
SELECT ALL + col2 * + cor0.col0 * - 76 - + col0 AS col2 FROM tab2 AS cor0
----
-14371
-154206
-228231

query I rowsort
SELECT ALL - 60 * + col1 + col1 AS col1 FROM tab1 AS cor0
----
-1534
-590
-767

query I rowsort
SELECT 78 + + col2 AS col0 FROM tab1 cor0
----
132
135
174

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

query I rowsort
SELECT DISTINCT - col1 * col2 + - 68 * 78 FROM tab2 AS cor0
----
-5950
-6141
-6838

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

query I rowsort
SELECT - cor0.col1 + + col1 * 29 AS col2 FROM tab0 AS cor0
----
2408
2548
2716

query I rowsort
SELECT - - col1 + col1 * + 81 FROM tab1 AS cor0
----
1066
2132
820

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 57 + - cor0.col2 col1 FROM tab2 AS cor0
----
19
30
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-1595
SELECT + - cor0.col1 DIV col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1595
SELECT + - cor0.col1 / col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT ( + col2 ) + + 61 * - col1 AS col1 FROM tab1 AS cor0
----
-1532
-553
-697

query I rowsort
SELECT col1 - 35 AS col2 FROM tab1 AS cor0
----
-22
-25
-9

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - 79 - - 5 col2 FROM tab1
----
-232
-5051
-6315

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

query I rowsort
SELECT DISTINCT col2 * col2 + - col2 AS col0 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT - cor0.col1 * col1 + - col1 + + cor0.col0 FROM tab0 AS cor0
----
-7458
-8283
-9471

query I rowsort
SELECT - col0 * 62 FROM tab1 cor0
----
-186
-3968
-4960

onlyif mysql # use DIV operator for integer division
query I rowsort label-1605
SELECT cor0.col0 + - col2 DIV + col1 + col1 * - col0 AS col2 FROM tab1 AS cor0
----
-581
-77
-967

skipif mysql # not compatible
query I rowsort label-1605
SELECT cor0.col0 + - col2 / + col1 + col1 * - col0 AS col2 FROM tab1 AS cor0
----
-581
-77
-967

query I rowsort
SELECT DISTINCT ( 34 ) * col0 FROM tab1 cor0
----
102
2176
2720

onlyif mysql # use DIV operator for integer division
query I rowsort label-1607
SELECT ( col1 ) DIV - col1 + col0 + 55 DIV - col1 FROM tab1 AS cor0
----
0
58
75

skipif mysql # not compatible
query I rowsort label-1607
SELECT ( col1 ) / - col1 + col0 + 55 / - col1 FROM tab1 AS cor0
----
0
58
75

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

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

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

query I rowsort
SELECT DISTINCT - - 94 * cor0.col1 + + col1 FROM tab2 AS cor0
----
1615
2945
5605

onlyif mysql # use DIV operator for integer division
query I rowsort label-1611
SELECT + + 49 * col2 * - col0 + col0 DIV - col0 FROM tab0 AS cor0
----
-1716
-357603
-38809

skipif mysql # not compatible
query I rowsort label-1611
SELECT + + 49 * col2 * - col0 + col0 / - col0 FROM tab0 AS cor0
----
-1716
-357603
-38809

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 63 * - col1 col0 FROM tab1 AS cor0
----
-1638
-630
-819

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

query I rowsort
SELECT DISTINCT - 15 + - col0 AS col2 FROM tab1 cor0
----
-18
-79
-95

query I rowsort
SELECT ALL - - 4 * - col1 + - col1 AS col1 FROM tab1 AS cor0
----
-130
-50
-65

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

query I rowsort
SELECT + + 70 + col1 + + col2 * col1 FROM tab0 AS cor0
----
264
2994
7623

query I rowsort
SELECT - 76 - - 58 FROM tab1 AS cor0
----
-18
-18
-18

query I rowsort
SELECT ALL 50 AS col1 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 314aace40e704c20a6be06204a329f80

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

query I rowsort
SELECT 74 * + col1 * - 91 AS col0 FROM tab2 AS cor0
----
-114478
-208754
-397306

query I rowsort
SELECT DISTINCT ( tab0.col1 ) + + 58 * 51 FROM tab0
----
3044
3049
3055

query I rowsort
SELECT ALL ( col2 ) * + 32 AS col2 FROM tab1 AS cor0
----
1728
1824
3072

query I rowsort
SELECT - + 29 + cor0.col1 FROM tab0 AS cor0
----
57
62
68

query I rowsort
SELECT DISTINCT + - col2 * 92 AS col1 FROM tab1 cor0
----
-4968
-5244
-8832

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

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

query I rowsort
SELECT ALL col2 * 58 FROM tab0 AS cor0
----
1914
4756
58

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

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

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

query I rowsort
SELECT + col0 - col2 AS col0 FROM tab0 cor0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1631
SELECT ALL + - col2 + - CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1631
SELECT ALL + - col2 + - CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col2 + + ( col1 ) * + col0 AS col0 FROM tab0 cor0
----
2031
3394
8017

query I rowsort
SELECT ALL + col2 - + 29 * - col1 FROM tab1 AS cor0
----
347
473
808

query I rowsort
SELECT - col1 * 48 + col2 * col1 FROM tab2 AS cor0
----
-1298
-170
-651

query I rowsort
SELECT DISTINCT + - col1 * ( col0 ) AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT col1 * ( col2 ) FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1637
SELECT - col2 - col1 DIV + cor0.col1 col0 FROM tab1 AS cor0
----
-55
-58
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1637
SELECT - col2 - col1 / + cor0.col1 col0 FROM tab1 AS cor0
----
-55
-58
-97

query I rowsort
SELECT DISTINCT col0 * col1 - + 16 FROM tab1
----
1024
62
624

query I rowsort
SELECT 48 * + col2 AS col1 FROM tab0
----
1584
3936
48

query I rowsort
SELECT ALL ( + col2 ) - 79 AS col1 FROM tab1
----
-22
-25
17

query I rowsort
SELECT DISTINCT 30 + - col2 * col2 * - col0 AS col1 FROM tab1 AS cor0
----
207966
737310
8778

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col0 ) + col0 * - cor0.col2 col2 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT ALL + - ( col2 ) * col1 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - 83 + - cor0.col0 FROM tab2 AS cor0
----
-161
-162
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + col0 * - col0 col2 FROM tab2 AS cor0
----
-6143
-6258
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1646
SELECT DISTINCT + - 22 DIV col0 AS col0 FROM tab2 cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-1646
SELECT DISTINCT + - 22 / col0 AS col0 FROM tab2 cor0
----
-3
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1647
SELECT + CAST( NULL AS SIGNED ) * + 80 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1647
SELECT + CAST ( NULL AS INTEGER ) * + 80 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1648
SELECT tab1.col1 DIV + tab1.col0 - + col0 * tab1.col1 * ( + col0 ) AS col2 FROM tab1
----
-226
-40960
-83200

skipif mysql # not compatible
query I rowsort label-1648
SELECT tab1.col1 / + tab1.col0 - + col0 * tab1.col1 * ( + col0 ) AS col2 FROM tab1
----
-226
-40960
-83200

query I rowsort
SELECT DISTINCT 11 * - 87 FROM tab2 AS cor0
----
-957

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1650
SELECT ALL - CAST( NULL AS SIGNED ) / + col2 + col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1650
SELECT ALL - CAST ( NULL AS INTEGER ) / + col2 + col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( col1 ) * + col1 + ( - col0 ) + - col1 FROM tab1 cor0
----
26
647
76

query I rowsort
SELECT ALL + - ( col2 ) * col0 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - + col1 * - col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ( + col0 ) - + col0 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 91 col0 FROM tab1 AS cor0
----
91

query I rowsort
SELECT col1 * cor0.col0 * col0 AS col1 FROM tab0 cor0
----
118825
49536
720811

onlyif mysql # use DIV operator for integer division
query I rowsort label-1657
SELECT DISTINCT + ( + col2 ) + 20 DIV col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1657
SELECT DISTINCT + ( + col2 ) + 20 / col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT - 19 AS col1 FROM tab2, tab1 AS cor0
----
-19

query I rowsort
SELECT 31 * - cor0.col0 FROM tab1 cor0
----
-1984
-2480
-93

query I rowsort
SELECT + col0 - 67 FROM tab0
----
-32
-43
22

query I rowsort
SELECT ( 77 ) * + col2 + ( col1 ) FROM tab1
----
4184
4399
7405

query I rowsort
SELECT ALL + ( col2 * 35 ) AS col2 FROM tab2
----
1330
910
945

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 52 * col2 col0 FROM tab1 AS cor0
----
-2808
-2964
-4992

query I rowsort
SELECT ALL + - cor0.col1 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT 55 * col1 + - col2 FROM tab1 AS cor0
----
1376
493
619

query I rowsort
SELECT ALL 87 + col1 * - col2 AS col0 FROM tab2 AS cor0
----
-1447
-559
-750

onlyif mysql # use DIV operator for integer division
query I rowsort label-1667
SELECT col0 DIV - 69 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1667
SELECT col0 / - 69 FROM tab0
----
-1
0
0

query I rowsort
SELECT 87 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT ALL 11 AS col2 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

query I rowsort
SELECT col2 + col1 * ( col0 ) AS col0 FROM tab0 AS cor0
----
2097
3396
8181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1671
SELECT DISTINCT - col0 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1671
SELECT DISTINCT - col0 * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1672
SELECT DISTINCT - - col0 * + CAST( col0 AS SIGNED ) + col1 + - ( + 62 + col2 ) AS col2 FROM tab1 AS cor0
----
-81
3987
6255

skipif mysql # not compatible
query I rowsort label-1672
SELECT DISTINCT - - col0 * + CAST ( col0 AS INTEGER ) + col1 + - ( + 62 + col2 ) AS col2 FROM tab1 AS cor0
----
-81
3987
6255

query I rowsort
SELECT ALL - col1 * col0 - - col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT col2 * + 75 AS col2 FROM tab1 cor0
----
4050
4275
7200

query I rowsort
SELECT DISTINCT - + ( - 37 ) * - col0 + ( + cor0.col2 ) FROM tab2 AS cor0
----
-232
-2860
-2885

query I rowsort
SELECT + + col2 * + col0 + + col2 AS col1 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT - ( 99 ) AS col1 FROM tab1
----
-99
-99
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-1678
SELECT - 31 DIV - 67 + - col2 AS col1 FROM tab1 cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-1678
SELECT - 31 / - 67 + - col2 AS col1 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT ALL - 17 + 92 FROM tab0 AS cor0
----
75
75
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-1680
SELECT + 38 + 21 DIV + col1 AS col2 FROM tab2 AS cor0
----
38
38
39

skipif mysql # not compatible
query I rowsort label-1680
SELECT + 38 + 21 / + col1 AS col2 FROM tab2 AS cor0
----
38
38
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - 3 + - cor0.col1 col2 FROM tab1 AS cor0
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1682
SELECT ALL - - CAST( NULL AS SIGNED ) * col2 + + cor0.col0 * - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1682
SELECT ALL - - CAST ( NULL AS INTEGER ) * col2 + + cor0.col0 * - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1683
SELECT + cor0.col0 DIV ( - 1 ) AS col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-1683
SELECT + cor0.col0 / ( - 1 ) AS col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL tab0.col1 + 14 * + 19 * col0 AS col0 FROM tab0
----
23765
6470
9407

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - ( - ( col0 ) ) col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + cor0.col2 * ( col0 ) + - col2 * col2 AS col1 FROM tab0 AS cor0
----
-297
34
574

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 39 col1 FROM tab2 AS cor0
----
39
39
39

query I rowsort
SELECT + cor0.col2 + col1 * + col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT ALL + 92 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT - ( + tab2.col2 ) FROM tab2, tab0 AS cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT col2 * + cor0.col0 + col1 * col0 FROM tab0 AS cor0
----
15397
2856
3430

query I rowsort
SELECT - col1 + - col1 * + col0 AS col1 FROM tab2 AS cor0
----
-1360
-248
-4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-1693
SELECT + col2 * - col0 + col2 DIV cor0.col1 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-1693
SELECT + col2 * - col0 + col2 / cor0.col1 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - + 51 * - 13 - + cor0.col1 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 06bba2923e4112f35888991d0407b573

query I rowsort
SELECT - col2 * + col0 + col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT - + col0 * - col0 * + 94 + + col1 FROM tab1 AS cor0
----
385034
601613
872

onlyif mysql # use DIV operator for integer division
query I rowsort label-1697
SELECT 59 DIV - col0 + + col1 + + col2 FROM tab2
----
50
55
85

skipif mysql # not compatible
query I rowsort label-1697
SELECT 59 / - col0 + + col1 + + col2 FROM tab2
----
50
55
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-1698
SELECT 68 DIV - 51 AS col1 FROM tab0, tab2 cor0 CROSS JOIN tab2
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

skipif mysql # not compatible
query I rowsort label-1698
SELECT 68 / - 51 AS col1 FROM tab0, tab2 cor0 CROSS JOIN tab2
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

query I rowsort
SELECT ALL 24 AS col0 FROM tab2, tab0, tab1 cor0
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT ALL - - 38 AS col2 FROM tab0 AS cor0
----
38
38
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-1701
SELECT - 84 DIV cor0.col0 FROM tab0 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-1701
SELECT - 84 / cor0.col0 FROM tab0 AS cor0
----
-2
-3
0

query I rowsort
SELECT DISTINCT - + col0 * + col1 + 50 FROM tab2 cor0
----
-1293
-167
-4552

query I rowsort
SELECT ALL + ( cor0.col1 ) FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT ALL - col2 * col0 + + col1 * - col1 AS col1 FROM tab2 AS cor0
----
-1150
-3291
-5509

onlyif mysql # use DIV operator for integer division
query I rowsort label-1705
SELECT ALL + col1 DIV col0 + + col1 AS col2 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-1705
SELECT ALL + col1 / col0 + + col1 AS col2 FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT + 95 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

query I rowsort
SELECT col1 * - 0 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 + 28 AS col2 FROM tab0
----
117
52
63

query I rowsort
SELECT DISTINCT + col2 * + col1 * col1 + - tab2.col0 + ( col0 ) FROM tab2
----
10982
25947
90506

query I rowsort
SELECT - tab0.col2 * + ( + 39 ) AS col1 FROM tab0
----
-1287
-3198
-39

query I rowsort
SELECT DISTINCT col0 * - tab0.col1 + - 98 FROM tab0
----
-2162
-3493
-8197

query I rowsort
SELECT DISTINCT col0 + col2 * - ( + col1 ) FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT col1 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - - col2 * col0 + + col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT col1 * + 80 AS col2 FROM tab2
----
1360
2480
4720

query I rowsort
SELECT col0 * - tab0.col2 + + col0 * - col0 FROM tab0
----
-1260
-1368
-15219

query I rowsort
SELECT + ( - cor0.col1 ) FROM tab2, tab1 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

onlyif mysql # use DIV operator for integer division
query I rowsort label-1718
SELECT col2 + col2 DIV + col2 FROM tab0 cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-1718
SELECT col2 + col2 / + col2 FROM tab0 cor0
----
2
34
83

query I rowsort
SELECT + + col0 - - col2 * - col1 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT col1 * - col0 + + cor0.col1 FROM tab0 cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - ( + col0 ) * col0 - cor0.col0 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT DISTINCT + - col2 * + col0 + col0 AS col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL col0 * + cor0.col1 + + col2 + col1 * col1 * 80 AS col2 FROM tab2 cor0
----
24501
283108
77124

onlyif mysql # use DIV operator for integer division
query I rowsort label-1724
SELECT DISTINCT + - col2 DIV - cor0.col0 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-1724
SELECT DISTINCT + - col2 / - cor0.col0 FROM tab0 AS cor0
----
0
1

query I rowsort
SELECT ALL - col2 * + col0 + - 47 FROM tab1 AS cor0
----
-209
-3695
-7727

onlyif mysql # use DIV operator for integer division
query I rowsort label-1726
SELECT DISTINCT + col0 DIV col0 + 70 * col2 + col2 * col1 AS col2 FROM tab1 AS cor0
----
4561
5185
7969

skipif mysql # not compatible
query I rowsort label-1726
SELECT DISTINCT + col0 / col0 + 70 * col2 + col2 * col1 AS col2 FROM tab1 AS cor0
----
4561
5185
7969

onlyif mysql # use DIV operator for integer division
query I rowsort label-1727
SELECT ALL - col1 DIV + col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1727
SELECT ALL - col1 / + col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + + col1 * col2 - col1 * 50 AS col2 FROM tab0 AS cor0
----
-1462
-4753
2912

query I rowsort
SELECT - + 61 + - col0 FROM tab2 AS cor0
----
-139
-140
-68

query I rowsort
SELECT - col0 * col0 + + col0 - col1 * - col1 FROM tab1
----
-3932
-6151
670

query I rowsort
SELECT - - cor0.col2 + col2 AS col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT col0 + - col2 * col2 AS col2 FROM tab2
----
-1365
-598
-722

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL > col0 + col2
----

query III rowsort
SELECT * FROM tab2 WHERE - col0 NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT col1 * col1 FROM tab0 WHERE + col1 NOT IN ( + col2 + + col1 * col1 * col0 )
----
7396
8281
9409

query I rowsort
SELECT ALL - col2 * col1 - - col0 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT - col2 FROM tab2 WHERE NULL NOT IN ( col2 * col0 / + col0 )
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1738
SELECT - 37 * col2 + - ( 80 + col2 ) * + CAST( 31 + col1 AS SIGNED ) FROM tab0
----
-10405
-14442
-22798

skipif mysql # not compatible
query I rowsort label-1738
SELECT - 37 * col2 + - ( 80 + col2 ) * + CAST ( 31 + col1 AS INTEGER ) FROM tab0
----
-10405
-14442
-22798

query I rowsort
SELECT - col1 * + col1 + 34 FROM tab0
----
-7362
-8247
-9375

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col2 * + col2 * + col1 col0 FROM tab1
----
-119808
-32490
-75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-1741
SELECT DISTINCT + col1 DIV tab2.col1 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-1741
SELECT DISTINCT + col1 / tab2.col1 FROM tab2
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1742
SELECT DISTINCT - col0 DIV + tab1.col2 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-1742
SELECT DISTINCT - col0 / + tab1.col2 FROM tab1
----
-1
0

query I rowsort
SELECT - + col0 * - col2 * + ( col1 * col2 + col2 * + col1 ) AS col0 FROM tab0 AS cor0
----
108915352
4495392
6790

query I rowsort
SELECT DISTINCT + 67 AS col2 FROM tab2 AS cor0
----
67

query I rowsort
SELECT DISTINCT + col0 + col0 * ( 56 ) FROM tab0 AS cor0
----
1368
1995
5073

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col0 * - 33 col0 FROM tab0 AS cor0
----
1190
3026
816

query I rowsort
SELECT DISTINCT - 43 * + col2 + col1 FROM tab2 AS cor0
----
-1059
-1130
-1617

onlyif mysql # use DIV operator for integer division
query I rowsort label-1748
SELECT + col2 DIV col2 + col0 + col2 FROM tab0
----
172
37
58

skipif mysql # not compatible
query I rowsort label-1748
SELECT + col2 / col2 + col0 + col2 FROM tab0
----
172
37
58

query I rowsort
SELECT DISTINCT - col1 * - col0 * col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT col1 * col2 - col2 FROM tab0
----
2805
7380
96

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL IN ( + col2 + col1 * tab2.col0 + col1 * - col2 )
----

query I rowsort
SELECT DISTINCT + col2 * col2 + - col1 FROM tab2
----
1427
617
698

query III rowsort
SELECT * FROM tab2 WHERE col2 + - col1 IN ( col1 + col1 + - col1 )
----

query I rowsort
SELECT DISTINCT - col2 * col1 + col1 AS col1 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT col0 * col0 * tab1.col1 + + col0 AS col2 FROM tab1
----
237
41024
83280

query I rowsort
SELECT ALL + col1 + + col1 + col2 FROM tab1 AS cor0
----
106
122
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-1757
SELECT DISTINCT cor0.col1 DIV + cor0.col1 + + col1 * col2 FROM tab0 AS cor0
----
2839
7463
98

skipif mysql # not compatible
query I rowsort label-1757
SELECT DISTINCT cor0.col1 / + cor0.col1 + + col1 * col2 FROM tab0 AS cor0
----
2839
7463
98

query I rowsort
SELECT DISTINCT col2 * col0 + + col0 AS col1 FROM tab2
----
196
2106
3081

query III rowsort
SELECT * FROM tab0 WHERE NULL >= + col2 * + col0
----

query I rowsort
SELECT - col2 + col2 * col1 * tab1.col2 FROM tab1
----
119712
32433
75762

query I rowsort
SELECT DISTINCT col2 * + col0 + col2 AS col1 FROM tab0
----
36
7380
825

query I rowsort
SELECT DISTINCT col1 * col0 + - col2 AS col0 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT ALL col0 AS col1 FROM tab1 WHERE NOT ( - col2 + col2 ) IN ( col1 + col1 )
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 col1 FROM tab1 WHERE NULL > ( col2 + col1 - - col1 )
----

query I rowsort
SELECT + col1 * - col2 + col1 FROM tab1
----
-1235
-1378
-560

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) > ( + col2 * - tab1.col0 )
----

query I rowsort
SELECT ALL + 59 * + col1 FROM tab1
----
1534
590
767

query I rowsort
SELECT ALL + - cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT + col2 * 45 + col1 * col0 FROM tab2 AS cor0
----
1432
3053
5772

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1770
SELECT + - CAST( NULL AS SIGNED ) * col0 * - col2 + 49 / col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1770
SELECT + - CAST ( NULL AS INTEGER ) * col0 * - col2 + 49 / col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor1.col2 AS col0 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL + ( 7 ) FROM tab1
----
7
7
7

query I rowsort
SELECT - cor0.col2 + + 41 + cor0.col1 AS col0 FROM tab0 cor0
----
137
50
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-1774
SELECT DISTINCT + - col1 DIV + 82 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-1774
SELECT DISTINCT + - col1 / + 82 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1775
SELECT + col2 * + col0 + col1 * col2 + + CAST( col1 AS SIGNED ) col2 FROM tab0 AS cor0
----
14851
229
3716

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1775
SELECT + col2 * + col0 + col1 * col2 + + CAST ( col1 AS INTEGER ) col2 FROM tab0 AS cor0
----
14851
229
3716

query I rowsort
SELECT - + col0 + ( + 70 * - col2 ) AS col1 FROM tab0 AS cor0
----
-105
-2334
-5829

query I rowsort
SELECT ALL + col0 + col1 * + tab0.col2 + + col1 FROM tab0
----
229
2948
7642

query I rowsort
SELECT col0 * + ( + col1 * + 4 ) + col0 FROM tab1 AS cor0
----
2624
315
4240

query I rowsort
SELECT ( - col0 ) + col0 FROM tab2 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 2 col1 FROM tab2, tab1 AS cor0
----
2

query I rowsort
SELECT ALL - 54 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 AS cor2
----
81 values hashing to 440ee4bea4c39df49899f4a4d88059fe

query I rowsort
SELECT 27 AS col0 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

query I rowsort
SELECT col0 * + 41 + 50 FROM tab1 AS cor0
----
173
2674
3330

query I rowsort
SELECT ALL - 13 + col0 FROM tab0 AS cor0
----
11
22
76

query I rowsort
SELECT DISTINCT + - col0 + cor0.col0 * col1 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT ALL - ( + 69 ) AS col1 FROM tab2
----
-69
-69
-69

query I rowsort
SELECT DISTINCT - col1 + col0 * tab0.col1 FROM tab0
----
1978
3298
8008

query I rowsort
SELECT + 79 + - 24 * - col0 FROM tab2
----
1951
1975
247

query I rowsort
SELECT 37 * col0 AS col0 FROM tab2
----
259
2886
2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-1790
SELECT DISTINCT col2 - + col1 DIV col2 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-1790
SELECT DISTINCT col2 - + col1 / col2 FROM tab1
----
54
57
96

query I rowsort
SELECT + - col1 + cor0.col0 * + col1 AS col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT + + cor0.col0 * col2 + + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT ALL - - col0 + col1 * - col2 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT 65 + col1 AS col0 FROM tab0 AS cor0
----
151
156
162

query I rowsort
SELECT DISTINCT + ( col1 ) * cor0.col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + col2 + col0 + col2 AS col0 FROM tab2 AS cor0
----
130
155
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-1797
SELECT - cor0.col0 + col1 DIV - col2 AS col1 FROM tab0 AS cor0
----
-132
-26
-90

skipif mysql # not compatible
query I rowsort label-1797
SELECT - cor0.col0 + col1 / - col2 AS col1 FROM tab0 AS cor0
----
-132
-26
-90

query I rowsort
SELECT + + 99 * cor0.col2 FROM tab0 AS cor0
----
3267
8118
99

query I rowsort
SELECT + cor0.col0 * + col2 + - col2 + col0 AS col1 FROM tab0 AS cor0
----
69
7305
783

query I rowsort
SELECT col0 * ( - col2 + - col0 * col2 ) FROM tab1 AS cor0
----
-237120
-622080
-648

query I rowsort
SELECT + + ( - col0 ) + cor0.col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT - col0 * 7 FROM tab2
----
-49
-546
-553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + ( - col0 ) ) + col2 * col0 col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT + - 77 FROM tab1 cor0
----
-77

query I rowsort
SELECT + 63 + - col0 FROM tab0 AS cor0
----
-26
28
39

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 - - col1 FROM tab1 cor0
----
0
0
0

query III rowsort
SELECT * FROM tab1 WHERE NULL >= ( + col2 + - col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1809
SELECT ALL + col0 + - col1 DIV - col1 + - tab0.col1 AS col1 FROM tab0
----
-1
-61
-61

skipif mysql # not compatible
query I rowsort label-1809
SELECT ALL + col0 + - col1 / - col1 + - tab0.col1 AS col1 FROM tab0
----
-1
-61
-61

query I rowsort
SELECT cor0.col2 + - cor0.col1 * cor0.col1 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT + cor0.col2 + + col0 * - cor0.col1 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT ALL - - col2 * col1 * - col0 AS col1 FROM tab1 cor0
----
-36480
-4212
-99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 + col0 * + cor0.col2 col2 FROM tab0 AS cor0
----
34
7216
759

onlyif mysql # use DIV operator for integer division
query I rowsort label-1814
SELECT tab2.col1 DIV tab2.col0 FROM tab2
----
0
0
4

skipif mysql # not compatible
query I rowsort label-1814
SELECT tab2.col1 / tab2.col0 FROM tab2
----
0
0
4

query I rowsort
SELECT DISTINCT + col1 + - col1 * cor0.col2 + + col2 FROM tab0 AS cor0
----
-2719
-7289
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 + col0 * col0 col0 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT ALL + tab1.col0 - - col2 AS col1 FROM tab1
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 - - col0 * tab0.col1 col0 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT ALL col1 * col0 + col1 * col0 - - col0 * col1 FROM tab1
----
1920
234
3120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + tab1.col2 * col2 + tab1.col1 col1 FROM tab1
----
2996
3316
9325

onlyif mysql # use DIV operator for integer division
query I rowsort label-1821
SELECT - col1 * + col1 + - col2 + - col0 DIV - tab1.col0 AS col2 FROM tab1
----
-156
-264
-729

skipif mysql # not compatible
query I rowsort label-1821
SELECT - col1 * + col1 + - col2 + - col0 / - tab1.col0 AS col2 FROM tab1
----
-156
-264
-729

query I rowsort
SELECT cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab2
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT DISTINCT cor0.col2 + - col1 * col2 FROM tab0 AS cor0
----
-2805
-7380
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col2 * + cor0.col2 col1 FROM tab1 AS cor0
----
119808
32490
75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-1825
SELECT DISTINCT + - col0 DIV + col1 + - col0 * col0 + col0 AS col1 FROM tab1 AS cor0
----
-4038
-6
-6326

skipif mysql # not compatible
query I rowsort label-1825
SELECT DISTINCT + - col0 / + col1 + - col0 * col0 + col0 AS col1 FROM tab1 AS cor0
----
-4038
-6
-6326

query I rowsort
SELECT col0 + + col1 * - cor0.col2 FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-1827
SELECT - col2 * cor0.col1 DIV cor0.col0 col0 FROM tab0 AS cor0
----
-118
-2
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1827
SELECT - col2 * cor0.col1 / cor0.col0 col0 FROM tab0 AS cor0
----
-118
-2
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-1828
SELECT + col1 * col2 DIV col1 - - col2 FROM tab1
----
108
114
192

skipif mysql # not compatible
query I rowsort label-1828
SELECT + col1 * col2 / col1 - - col2 FROM tab1
----
108
114
192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 - col2 * + col2 col0 FROM tab1
----
-2913
-3185
-9136

query I rowsort
SELECT + tab0.col2 + col1 AS col0 FROM tab0
----
119
173
98

skipif mysql # not compatible
query I rowsort
SELECT - + col0 + - CAST ( + 38 + - col1 AS REAL ) FROM tab1 AS cor0
----
-105
-15
-92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col2 col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT - col2 + 87 AS col1 FROM tab0 AS cor0
----
5
54
86

query I rowsort
SELECT ALL - col1 * ( cor0.col2 ) AS col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT - - col0 + + 24 + - col2 FROM tab2 AS cor0
----
4
65
76

query I rowsort
SELECT ALL - 80 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 26dbcc98d4b4e864ffa31be685a5dfbd

query I rowsort
SELECT DISTINCT - + col0 + 96 AS col2 FROM tab2 AS cor0
----
17
18
89

query I rowsort
SELECT DISTINCT - 10 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
-10

query I rowsort
SELECT ALL - ( col1 ) + - tab0.col1 FROM tab0
----
-172
-182
-194

onlyif mysql # use DIV operator for integer division
query I rowsort label-1840
SELECT DISTINCT col0 * col2 DIV col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1840
SELECT DISTINCT col0 * col2 / col0 FROM tab0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 89 col1 FROM tab2, tab0 cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT ALL col1 * - ( - col2 ) FROM tab2
----
1534
646
837

query I rowsort
SELECT col2 * - ( col2 ) * col2 FROM tab1
----
-157464
-185193
-884736

query I rowsort
SELECT DISTINCT - col1 * 42 FROM tab2 AS cor0
----
-1302
-2478
-714

query I rowsort
SELECT DISTINCT + + col2 * + cor0.col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT 3 FROM tab1, tab1 AS cor0, tab2 cor1
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT col2 * ( 15 ) * tab2.col1 AS col1 FROM tab2
----
12555
23010
9690

query I rowsort
SELECT ALL col2 - + 98 * - col2 AS col2 FROM tab2
----
2574
2673
3762

query I rowsort
SELECT + 89 * col2 + col1 * 71 AS col1 FROM tab2 AS cor0
----
4589
4604
6503

query I rowsort
SELECT DISTINCT - col0 + col1 * col1 AS col1 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT ALL + 71 + col2 * - col0 FROM tab0
----
-721
-7227
36

query I rowsort
SELECT 38 * col2 FROM tab2
----
1026
1444
988

query I rowsort
SELECT cor0.col0 * col2 - cor0.col0 AS col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT tab2.col0 + + tab2.col2 * + col2 + + col1 AS col1 FROM tab2
----
1540
767
813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1855
SELECT DISTINCT - + col1 + - col0 * + CAST( + col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-1360
-248
-4661

skipif mysql # not compatible
query I rowsort label-1855
SELECT DISTINCT - + col1 + - col0 * + CAST ( + col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT col0 * col2 * - col1 + ( col0 ) FROM tab0 AS cor0
----
-3360
-664029
-68088

query I rowsort
SELECT ALL - col2 + col2 * col2 AS col1 FROM tab2 AS cor0
----
1406
650
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-1858
SELECT + col2 * - cor0.col1 + - 46 DIV cor0.col0 AS col1 FROM tab2 AS cor0
----
-1534
-646
-843

skipif mysql # not compatible
query I rowsort label-1858
SELECT + col2 * - cor0.col1 + - 46 / cor0.col0 AS col1 FROM tab2 AS cor0
----
-1534
-646
-843

query I rowsort
SELECT DISTINCT - col1 + + col2 * col2 AS col0 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT DISTINCT col0 + col0 * - col2 AS col0 FROM tab0 AS cor0
----
-7209
-768
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1861
SELECT + + 66 DIV - col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1861
SELECT + + 66 / - col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + cor0.col0 * col1 + + 4 AS col0 FROM tab2 AS cor0
----
1347
221
4606

query I rowsort
SELECT + col1 * col1 * + col1 + col0 * col2 FROM tab0 cor0
----
636848
760869
912708

query I rowsort
SELECT DISTINCT col2 * - col0 * 70 FROM tab0 AS cor0
----
-2450
-510860
-55440

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + col1 + - 35 col0 FROM tab2 AS cor0
----
-1378
-252
-4637

query I rowsort
SELECT ALL - + col0 * col2 + col1 FROM tab2 AS cor0
----
-158
-1969
-2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col1 + ( + col0 ) * + col2 + + col1 col0 FROM tab0 AS cor0
----
-1186
-3263
-710

query I rowsort
SELECT ALL + - col2 * col1 * col2 AS col0 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT col1 + col1 * + 99 AS col1 FROM tab0 cor0
----
8600
9100
9700

query I rowsort
SELECT DISTINCT col2 * col0 * + 16 FROM tab2 AS cor0
----
3024
32448
48032

onlyif mysql # use DIV operator for integer division
query I rowsort label-1871
SELECT ALL + 14 DIV + col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1871
SELECT ALL + 14 / + col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 * + col2 + - ( + col1 + col0 ) AS col1 FROM tab2
----
-1540
-767
-813

query I rowsort
SELECT ALL + + 13 * + col1 FROM tab0 AS cor0
----
1118
1183
1261

query I rowsort
SELECT ALL - col2 - cor0.col2 FROM tab1 cor0
----
-108
-114
-192

query I rowsort
SELECT ALL - - cor0.col0 + + 60 + 92 * col1 FROM tab1 AS cor0
----
1044
1336
2455

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col0 * - col2 col2 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-1877
SELECT - - cor0.col1 DIV col0 + col1 AS col2 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-1877
SELECT - - cor0.col1 / col0 + col1 AS col2 FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT + - cor0.col2 + ( + 14 + col0 ) * col1 FROM tab2 AS cor0
----
1543
5402
624

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + 9 col1 FROM tab2 AS cor0
----
153
279
531

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( 22 AS REAL ) FROM tab0 AS cor0
----
22
22
22

query I rowsort
SELECT DISTINCT + col1 + + 40 * + col0 * col0 FROM tab0 AS cor0
----
23126
316931
49097

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0 CROSS JOIN tab1, tab0 AS cor1, tab0 AS cor2
----
3645 values hashing to 862fba9ac85fdf2cec88a0bec0808b7e

query I rowsort
SELECT + col2 * 4 FROM tab1 AS cor0
----
216
228
384

query I rowsort
SELECT ALL + col2 + - col1 + cor0.col1 AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL - ( + col0 ) + - col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT DISTINCT 94 * cor0.col1 FROM tab0 AS cor0
----
8084
8554
9118

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1887
SELECT + + CAST( - 89 AS SIGNED ) FROM tab2 AS cor0
----
-89
-89
-89

skipif mysql # not compatible
query I rowsort label-1887
SELECT + + CAST ( - 89 AS INTEGER ) FROM tab2 AS cor0
----
-89
-89
-89

query I rowsort
SELECT + col2 * ( cor0.col1 ) AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT 48 * + col1 FROM tab1 AS cor0
----
1248
480
624

query I rowsort
SELECT - 19 + + col1 * + col1 AS col2 FROM tab2
----
270
3462
942

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 89 + col1 * - col2 col2 FROM tab0 cor0
----
-2749
-7373
-8

query I rowsort
SELECT + 54 + + 60 AS col0 FROM tab2 AS cor0
----
114
114
114

query I rowsort
SELECT DISTINCT - 51 * - 29 AS col0 FROM tab2 AS cor0
----
1479

query I rowsort
SELECT ALL + + ( col1 ) + + cor0.col2 * + col0 + - col1 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + ( + col1 ) * - cor0.col1 + 67 - col1 AS col2 FROM tab0 cor0
----
-7415
-8305
-9439

query I rowsort
SELECT DISTINCT 49 * + col2 + col0 * - ( 39 ) + - col0 FROM tab2 cor0
----
-1298
-1846
1043

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 46 + + ( col0 ) col0 FROM tab2 AS cor0
----
124
125
53

query I rowsort
SELECT - - ( col2 ) * - col2 * - 45 + + col2 AS col2 FROM tab0 AS cor0
----
302662
46
49038

query I rowsort
SELECT ALL col2 * - ( col0 + + tab2.col2 ) FROM tab2
----
-2704
-4446
-918

onlyif mysql # use DIV operator for integer division
query I rowsort label-1900
SELECT col1 DIV ( col0 + + col2 ) AS col1 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1900
SELECT col1 / ( col0 + + col2 ) AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL + col2 - - col0 FROM tab0
----
171
36
57

query I rowsort
SELECT + 61 + - 63 - + col2 AS col2 FROM tab1 AS cor0
----
-56
-59
-98

query I rowsort
SELECT + + 76 * - col1 AS col1 FROM tab0 cor0
----
-6536
-6916
-7372

query I rowsort
SELECT + + 39 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT ALL + - ( - 98 ) AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

onlyif mysql # use DIV operator for integer division
query I rowsort label-1906
SELECT + 36 DIV col1 + + ( + col0 ) FROM tab2 AS cor0
----
78
8
81

skipif mysql # not compatible
query I rowsort label-1906
SELECT + 36 / col1 + + ( + col0 ) FROM tab2 AS cor0
----
78
8
81

query I rowsort
SELECT 41 + col0 FROM tab1 AS cor0
----
105
121
44

query I rowsort
SELECT + 72 AS col1 FROM tab0, tab2 AS cor0, tab1 cor1
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT + - col2 * col2 + - col2 FROM tab0 AS cor0
----
-1122
-2
-6806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - 29 col2 FROM tab2 AS cor0
----
-1711
-493
-899

query I rowsort
SELECT DISTINCT col0 * + col2 * col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT col1 + 39 FROM tab1
----
49
52
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-1913
SELECT col0 DIV 14 + col1 col0 FROM tab1
----
14
18
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1913
SELECT col0 / 14 + col1 col0 FROM tab1
----
14
18
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-1914
SELECT ALL + col2 + ( cor0.col1 ) + col1 DIV col2 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-1914
SELECT ALL + col2 + ( cor0.col1 ) + col1 / col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL + + col0 * + col1 + - 85 * - col2 AS col1 FROM tab2 AS cor0
----
2512
4573
6812

query I rowsort
SELECT DISTINCT - cor0.col2 - - col1 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL cor0.col1 * 47 + - col2 * + col1 AS col1 FROM tab2 AS cor0
----
1239
153
620

query I rowsort
SELECT ALL 16 * col1 AS col0 FROM tab1 AS cor0
----
160
208
416

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) + + col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT 34 * + cor0.col0 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 5b56eae1c3cd0c95f5cc27d11a48f9b8

query I rowsort
SELECT DISTINCT + 37 * ( col0 ) + 27 * + col1 - col2 AS col0 FROM tab0 cor0
----
3177
3913
5668

skipif mysql # not compatible
query I rowsort
SELECT - - CAST ( col1 AS REAL ) FROM tab2 cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 37 * cor0.col1 col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 879f2c333e9aeb37c869b03b0e2622fd

query I rowsort
SELECT - - col1 + - 18 AS col2 FROM tab0 AS cor0
----
68
73
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1925
SELECT ALL col1 * col1 + CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1925
SELECT ALL col1 * col1 + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 23 * col0 + - 86 * - col0 FROM tab1 AS cor0
----
327
6976
8720

onlyif mysql # use DIV operator for integer division
query I rowsort label-1927
SELECT DISTINCT - 90 * col2 DIV - col0 AS col2 FROM tab0 AS cor0
----
123
2
82

skipif mysql # not compatible
query I rowsort label-1927
SELECT DISTINCT - 90 * col2 / - col0 AS col2 FROM tab0 AS cor0
----
123
2
82

query I rowsort
SELECT - cor0.col2 * col2 + col0 AS col0 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT DISTINCT - ( - col0 ) + - col2 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT ALL - col1 * - cor0.col1 * + 35 FROM tab1 AS cor0
----
23660
3500
5915

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1931
SELECT DISTINCT col2 / CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1931
SELECT DISTINCT col2 / CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + + col2 + 6 FROM tab2 AS cor0
----
32
33
44

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + cor0.col2 * CAST ( - col2 AS REAL ) FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT - 54 + - col2 FROM tab1
----
-108
-111
-150

query I rowsort
SELECT 28 + + col1 FROM tab1
----
38
41
54

query I rowsort
SELECT DISTINCT cor1.col2 FROM tab2, tab2 cor0, tab2 AS cor1
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1937
SELECT - ( col1 ) + CAST( col1 AS SIGNED ) * - col0 FROM tab0
----
-2150
-3492
-8190

skipif mysql # not compatible
query I rowsort label-1937
SELECT - ( col1 ) + CAST ( col1 AS INTEGER ) * - col0 FROM tab0
----
-2150
-3492
-8190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1938
SELECT col2 + + col0 * - CAST( - ( col2 ) AS SIGNED ) FROM tab1
----
216
3705
7776

skipif mysql # not compatible
query I rowsort label-1938
SELECT col2 + + col0 * - CAST ( - ( col2 ) AS INTEGER ) FROM tab1
----
216
3705
7776

query I rowsort
SELECT DISTINCT + + ( 11 ) FROM tab0 AS cor0
----
11

query I rowsort
SELECT ALL 6 * + col1 FROM tab0 AS cor0
----
516
546
582

query I rowsort
SELECT - - ( - col1 ) + col1 * - col2 * + col2 AS col2 FROM tab2 AS cor0
----
-22630
-24565
-39943

query I rowsort
SELECT 10 - - cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to d2d8976966203a1b5d75df233eeec40f

query I rowsort
SELECT DISTINCT - - 17 - cor0.col0 * + cor0.col0 AS col1 FROM tab2 AS cor0
----
-32
-6067
-6224

onlyif mysql # use DIV operator for integer division
query I rowsort label-1944
SELECT + 26 * + 24 + + col2 * + 80 * col2 + col1 DIV - 62 FROM tab2 AS cor0
----
116144
54704
58944

skipif mysql # not compatible
query I rowsort label-1944
SELECT + 26 * + 24 + + col2 * + 80 * col2 + col1 / - 62 FROM tab2 AS cor0
----
116144
54704
58944

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1945
SELECT CAST( 41 AS SIGNED ) + col2 * 46 FROM tab2 AS cor0
----
1237
1283
1789

skipif mysql # not compatible
query I rowsort label-1945
SELECT CAST ( 41 AS INTEGER ) + col2 * 46 FROM tab2 AS cor0
----
1237
1283
1789

query I rowsort
SELECT DISTINCT cor0.col2 + - 54 FROM tab2 AS cor0
----
-16
-27
-28

query I rowsort
SELECT ALL - 90 + cor0.col2 AS col1 FROM tab2 cor0
----
-52
-63
-64

onlyif mysql # use DIV operator for integer division
query I rowsort label-1948
SELECT + + 71 DIV ( col1 ) - col0 AS col0 FROM tab1 AS cor0
----
-1
-57
-75

skipif mysql # not compatible
query I rowsort label-1948
SELECT + + 71 / ( col1 ) - col0 AS col0 FROM tab1 AS cor0
----
-1
-57
-75

query I rowsort
SELECT 93 * col0 + + col2 + ( col0 + cor0.col0 ) AS col2 FROM tab2 AS cor0
----
692
7436
7543

query I rowsort
SELECT DISTINCT + + col1 + 77 * - col2 FROM tab1 AS cor0
----
-4132
-4379
-7379

query I rowsort
SELECT 45 + 45 + + col2 FROM tab0 AS cor0
----
123
172
91

query I rowsort
SELECT ALL + col2 * 24 AS col0 FROM tab2 cor0
----
624
648
912

onlyif mysql # use DIV operator for integer division
query I rowsort label-1953
SELECT DISTINCT 96 + col2 DIV ( 14 + cor0.col0 ) FROM tab2 AS cor0
----
96
97

skipif mysql # not compatible
query I rowsort label-1953
SELECT DISTINCT 96 + col2 / ( 14 + cor0.col0 ) FROM tab2 AS cor0
----
96
97

query I rowsort
SELECT + 81 + col0 AS col2 FROM tab2 AS cor0
----
159
160
88

query I rowsort
SELECT - col0 * + col0 + + col0 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT DISTINCT col0 * 90 FROM tab2 AS cor0
----
630
7020
7110

query I rowsort
SELECT ALL 17 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

query I rowsort
SELECT DISTINCT + - col1 + ( - 11 ) * col2 AS col2 FROM tab1 cor0
----
-1069
-620
-637

query I rowsort
SELECT ALL - col1 * - 20 FROM tab1 AS cor0
----
200
260
520

query I rowsort
SELECT + col2 * ( + 77 ) AS col0 FROM tab2 AS cor0
----
2002
2079
2926

query I rowsort
SELECT 91 AS col1 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to deebbcfb9c7803a34dca6bd860849afe

query I rowsort
SELECT + + ( - col0 ) + + cor0.col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 * col0 - col0 FROM tab2
----
1264
210
4524

query I rowsort
SELECT DISTINCT cor1.col0 FROM tab0, tab1 AS cor0, tab2 cor1
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-1965
SELECT + col2 + + col2 DIV + col2 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-1965
SELECT + col2 + + col2 / + col2 FROM tab1
----
55
58
97

query I rowsort
SELECT col0 * col2 + - col0 * tab0.col0 AS col2 FROM tab0
----
-1190
-623
216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 12 + - col2 * - col1 col2 FROM tab0 AS cor0
----
109
2850
7474

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col1 col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT + col1 * 2 AS col1 FROM tab0 AS cor0
----
172
182
194

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0, tab1 AS cor1, tab2, tab2 cor2
----
3645 values hashing to b62c1ebc681aca72d13feadb888b3be7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1971
SELECT - CAST( NULL AS DECIMAL ) * col0 * - cor0.col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1971
SELECT - CAST ( NULL AS REAL ) * col0 * - cor0.col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 87 AS col1 FROM tab0, tab2 cor0
----
87

query I rowsort
SELECT 96 AS col2 FROM tab2 cor0
----
96
96
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1974
SELECT ALL CAST( cor0.col2 AS SIGNED ) AS col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

skipif mysql # not compatible
query I rowsort label-1974
SELECT ALL CAST ( cor0.col2 AS INTEGER ) AS col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT ALL cor0.col1 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT cor0.col2 * cor0.col0 AS col0 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 421c686606be6ea267ac0dc7521bf659

query I rowsort
SELECT DISTINCT + col0 * + col2 + 83 + - cor0.col2 FROM tab0 AS cor0
----
117
7299
842

query I rowsort
SELECT ALL + 69 AS col0 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 2810c3097fe4771e273cfff903357b40

query I rowsort
SELECT - col0 * - ( - 46 ) AS col0 FROM tab1 cor0
----
-138
-2944
-3680

query I rowsort
SELECT + col1 * 72 AS col0 FROM tab0 AS cor0
----
6192
6552
6984

query I rowsort
SELECT + col1 + + ( - col2 ) * + col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT - col1 + col0 + col0 * col0 * 93 AS col0 FROM tab0 AS cor0
----
113863
53506
736651

query I rowsort
SELECT + col1 * - 88 AS col0 FROM tab2 AS cor0
----
-1496
-2728
-5192

query I rowsort
SELECT col0 + col0 * col2 AS col0 FROM tab1 cor0
----
165
3712
7760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1985
SELECT DISTINCT - CAST( NULL AS SIGNED ) AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-1985
SELECT DISTINCT - CAST ( NULL AS INTEGER ) AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
NULL

query I rowsort
SELECT - 69 * cor0.col1 AS col0 FROM tab2 AS cor0
----
-1173
-2139
-4071

query I rowsort
SELECT - 43 AS col2 FROM tab0, tab2 cor0
----
9 values hashing to ab0c314d2b589ccedb9a875beeb1f86a

query I rowsort
SELECT ALL - + cor0.col2 - + col0 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT ALL + 66 FROM tab1, tab1 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

onlyif mysql # use DIV operator for integer division
query I rowsort label-1990
SELECT DISTINCT - - ( + col1 ) DIV - col0 AS col2 FROM tab1 AS cor0
----
-8
0

skipif mysql # not compatible
query I rowsort label-1990
SELECT DISTINCT - - ( + col1 ) / - col0 AS col2 FROM tab1 AS cor0
----
-8
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1991
SELECT ALL + cor0.col0 DIV - 69 AS col1 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1991
SELECT ALL + cor0.col0 / - 69 AS col1 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT - - col1 - - cor0.col2 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL - + col1 + col1 * - 58 FROM tab2 AS cor0
----
-1003
-1829
-3481

query I rowsort
SELECT - col2 + 42 FROM tab0 AS cor0
----
-40
41
9

query I rowsort
SELECT DISTINCT + col0 * + 31 + - 52 * cor0.col2 FROM tab2 AS cor0
----
-1187
1066
473

query I rowsort
SELECT ALL + + col2 * col0 + - 55 FROM tab2 AS cor0
----
134
1973
2947

onlyif mysql # use DIV operator for integer division
query I rowsort label-1997
SELECT DISTINCT + cor0.col0 - - 93 DIV col2 FROM tab0 AS cor0
----
128
26
90

skipif mysql # not compatible
query I rowsort label-1997
SELECT DISTINCT + cor0.col0 - - 93 / col2 FROM tab0 AS cor0
----
128
26
90

query I rowsort
SELECT ALL 2 * tab2.col0 FROM tab2
----
14
156
158

query I rowsort
SELECT - cor0.col2 * col1 * 36 + col0 FROM tab2 AS cor0
----
-23177
-30125
-55146

query I rowsort
SELECT ALL + cor0.col0 + ( col1 ) AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + col0 - + ( + col1 ) AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT + col1 + - 72 * - col0 - col2 FROM tab0 cor0
----
1781
2616
6417

query I rowsort
SELECT ALL 61 * col0 AS col1 FROM tab2
----
427
4758
4819

onlyif mysql # use DIV operator for integer division
query I rowsort label-2004
SELECT + ( - col0 ) DIV + col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2004
SELECT + ( - col0 ) / + col2 FROM tab1 AS cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2005
SELECT CAST( + col2 AS SIGNED ) + - col2 + 80 DIV col1 AS col0 FROM tab2 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-2005
SELECT CAST ( + col2 AS INTEGER ) + - col2 + 80 / col1 AS col0 FROM tab2 AS cor0
----
1
2
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2006
SELECT + CAST( col1 AS SIGNED ) * col0 * ( cor0.col2 * col2 ) FROM tab2 AS cor0
----
158193
1939292
3110952

skipif mysql # not compatible
query I rowsort label-2006
SELECT + CAST ( col1 AS INTEGER ) * col0 * ( cor0.col2 * col2 ) FROM tab2 AS cor0
----
158193
1939292
3110952

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2007
SELECT + CAST( col1 AS SIGNED ) + cor0.col0 + + ( - col2 ) * + col0 AS col1 FROM tab1 AS cor0
----
-133
-3574
-7587

skipif mysql # not compatible
query I rowsort label-2007
SELECT + CAST ( col1 AS INTEGER ) + cor0.col0 + + ( - col2 ) * + col0 AS col1 FROM tab1 AS cor0
----
-133
-3574
-7587

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2008
SELECT ALL + CAST( NULL AS SIGNED ) + col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2008
SELECT ALL + CAST ( NULL AS INTEGER ) + col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + ( col2 ) * - col2 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2010
SELECT + - 69 * + col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2010
SELECT + - 69 * + col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query IIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0 CROSS JOIN tab1 cor1
----
243 values hashing to 098e223d780e18b6582523fd6f55eec9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2012
SELECT + + CAST( 8 AS SIGNED ) + + cor0.col2 * col2 FROM tab1 AS cor0
----
2924
3257
9224

skipif mysql # not compatible
query I rowsort label-2012
SELECT + + CAST ( 8 AS INTEGER ) + + cor0.col2 * col2 FROM tab1 AS cor0
----
2924
3257
9224

query I rowsort
SELECT + + col0 * - 85 AS col0 FROM tab2 AS cor0
----
-595
-6630
-6715

query I rowsort
SELECT DISTINCT col0 * - col2 + col2 + col0 AS col2 FROM tab2
----
-155
-1924
-2885

query I rowsort
SELECT ALL ( col2 ) + - col0 AS col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT ( - tab0.col0 ) - + col0 AS col0 FROM tab0
----
-178
-48
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-2017
SELECT ALL - col1 DIV cor0.col0 FROM tab0 cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-2017
SELECT ALL - col1 / cor0.col0 FROM tab0 cor0
----
-1
-2
-3

query I rowsort
SELECT DISTINCT - 22 * col1 FROM tab0 AS cor0
----
-1892
-2002
-2134

query I rowsort
SELECT DISTINCT tab2.col2 + + tab2.col1 FROM tab2
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-2020
SELECT DISTINCT - 79 + + 49 DIV - col0 FROM tab2
----
-79
-86

skipif mysql # not compatible
query I rowsort label-2020
SELECT DISTINCT - 79 + + 49 / - col0 FROM tab2
----
-79
-86

query I rowsort
SELECT ( 23 ) FROM tab0, tab1, tab1 cor0
----
27 values hashing to 546d49aa433406dd83ea19885588e658

query I rowsort
SELECT - 64 * - tab0.col0 * col2 + - col1 * col0 * + col1 FROM tab0
----
-126816
-269937
-327075

query I rowsort
SELECT 99 + - col2 FROM tab1
----
3
42
45

query I rowsort
SELECT 5 + - col1 * tab1.col0 AS col1 FROM tab1
----
-1035
-635
-73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2025
SELECT CAST( NULL AS SIGNED ) * 21 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2025
SELECT CAST ( NULL AS INTEGER ) * 21 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT col1 * - col0 + + ( col2 ) FROM tab1
----
-24
-583
-944

query I rowsort
SELECT DISTINCT col0 * + col0 + + 63 AS col2 FROM tab0 AS cor0
----
1288
639
7984

query I rowsort
SELECT DISTINCT - - 39 * - col0 AS col2 FROM tab1 AS cor0
----
-117
-2496
-3120

query I rowsort
SELECT ALL + - col0 + col2 * + 86 * ( - col1 * 21 ) FROM tab1 AS cor0
----
-1029484
-2253968
-2535627

query I rowsort
SELECT ALL - 77 + col1 + - cor0.col0 * cor0.col2 AS col2 FROM tab2 AS cor0
----
-2046
-235
-3062

query I rowsort
SELECT - 40 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f02f17e9bc17e514af018c6f245ed7a9

query I rowsort
SELECT DISTINCT - tab2.col2 - 38 FROM tab2
----
-64
-65
-76

query IIIIIIIIIIII rowsort
SELECT * FROM tab1 cor0 CROSS JOIN tab2, tab0 AS cor1, tab1 cor2
----
972 values hashing to 0210050fb1701e2797a9b17e1ebac91e

query I rowsort
SELECT DISTINCT + col1 + + 5 AS col2 FROM tab1 AS cor0
----
15
18
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-2035
SELECT ALL + + cor0.col0 + - 58 - - col2 DIV col0 FROM tab2 AS cor0
----
-48
20
21

skipif mysql # not compatible
query I rowsort label-2035
SELECT ALL + + cor0.col0 + - 58 - - col2 / col0 FROM tab2 AS cor0
----
-48
20
21

query I rowsort
SELECT ALL - cor0.col0 AS col2 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT - + col0 * + 54 * - col0 AS col1 FROM tab0 AS cor0
----
31104
427734
66150

onlyif mysql # use DIV operator for integer division
query I rowsort label-2038
SELECT - - col1 - + col1 DIV col0 AS col0 FROM tab0 AS cor0
----
83
90
95

skipif mysql # not compatible
query I rowsort label-2038
SELECT - - col1 - + col1 / col0 AS col0 FROM tab0 AS cor0
----
83
90
95

query I rowsort
SELECT - col2 * 48 + col0 AS col0 FROM tab0 AS cor0
----
-13
-1560
-3847

query I rowsort
SELECT DISTINCT 99 FROM tab1, tab1 AS cor0
----
99

query I rowsort
SELECT ALL col2 * col1 * - col2 + cor0.col1 FROM tab1 AS cor0
----
-119795
-32480
-75790

query I rowsort
SELECT ALL + ( cor0.col1 ) AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL - col1 + + 76 FROM tab2 AS cor0
----
17
45
59

query I rowsort
SELECT DISTINCT - + cor0.col1 - - ( + col1 ) AS col2 FROM tab2 cor0
----
0

query I rowsort
SELECT - - 98 * + col1 + - col2 FROM tab0 AS cor0
----
8395
8836
9505

query I rowsort
SELECT tab2.col1 * ( + 73 ) FROM tab2
----
1241
2263
4307

onlyif mysql # use DIV operator for integer division
query I rowsort label-2047
SELECT col0 DIV - cor0.col0 + col0 * + ( + col2 ) FROM tab2 AS cor0
----
188
2027
3001

skipif mysql # not compatible
query I rowsort label-2047
SELECT col0 / - cor0.col0 + col0 * + ( + col2 ) FROM tab2 AS cor0
----
188
2027
3001

query I rowsort
SELECT - 95 + - col2 * col1 FROM tab0 AS cor0
----
-192
-2933
-7557

query I rowsort
SELECT DISTINCT 60 * 49 AS col2 FROM tab1 AS cor0
----
2940

query I rowsort
SELECT ALL - 21 + - 78 * col2 * col1 FROM tab2 AS cor0
----
-119673
-50409
-65307

query I rowsort
SELECT ALL - - col2 - - 77 * - col0 FROM tab0 AS cor0
----
-1815
-2694
-6771

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2052
SELECT - - CAST( NULL AS DECIMAL ) * + col2 * - col1 + - 34 * cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2052
SELECT - - CAST ( NULL AS REAL ) * + col2 * - col1 + - 34 * cor0.col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 1 * - col0 + - col2 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT ALL + 23 + cor0.col2 * - cor0.col1 + col1 FROM tab1 AS cor0
----
-1212
-1355
-537

query I rowsort
SELECT ALL + - col0 * + col2 * col2 AS col2 FROM tab2 AS cor0
----
-114076
-5103
-52728

query I rowsort
SELECT + + cor0.col0 * cor0.col0 AS col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT - col2 + + 97 * - cor0.col0 * - cor0.col0 FROM tab2 AS cor0
----
4726
590122
605339

query I rowsort
SELECT - ( col2 ) * 15 AS col1 FROM tab0
----
-1230
-15
-495

onlyif mysql # use DIV operator for integer division
query I rowsort label-2059
SELECT col1 DIV 63 + col0 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-2059
SELECT col1 / 63 + col0 FROM tab1 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 34 * + col0 col1 FROM tab2
----
-238
-2652
-2686

query I rowsort
SELECT ALL - col2 - - 32 AS col0 FROM tab2 AS cor0
----
-6
5
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2062
SELECT ALL - CAST( - cor0.col2 AS SIGNED ) - col1 * CAST( NULL AS SIGNED ) * 16 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2062
SELECT ALL - CAST ( - cor0.col2 AS INTEGER ) - col1 * CAST ( NULL AS INTEGER ) * 16 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( + col0 ) * + col0 + col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT ALL + - col0 + + 75 FROM tab2 AS cor0
----
-3
-4
68

query I rowsort
SELECT ALL - 89 * + col0 AS col2 FROM tab0 AS cor0
----
-2136
-3115
-7921

query I rowsort
SELECT 41 * col0 + - col0 AS col2 FROM tab2 AS cor0
----
280
3120
3160

query I rowsort
SELECT DISTINCT - 94 + - col1 FROM tab2 AS cor0
----
-111
-125
-153

query I rowsort
SELECT DISTINCT + cor0.col0 * col0 + - cor0.col0 * + 83 FROM tab2 AS cor0
----
-316
-390
-532

query I rowsort
SELECT - - 38 + - col2 AS col1 FROM tab2 AS cor0
----
0
11
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col0 ) * col1 * col1 + col2 col2 FROM tab0 AS cor0
----
177537
329316
737091

query I rowsort
SELECT ALL + cor0.col0 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT ( col1 ) + 3 + 27 FROM tab2 AS cor0
----
47
61
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2073
SELECT - CAST( col2 AS SIGNED ) - col0 FROM tab2
----
-104
-117
-34

skipif mysql # not compatible
query I rowsort label-2073
SELECT - CAST ( col2 AS INTEGER ) - col0 FROM tab2
----
-104
-117
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col2 * + col0 * + col0 col0 FROM tab1
----
233472
486
614400

query I rowsort
SELECT - col1 * - tab0.col1 + - col1 AS col1 FROM tab0
----
7310
8190
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-2076
SELECT ALL + + 89 DIV - col1 FROM tab1 AS cor0
----
-3
-6
-8

skipif mysql # not compatible
query I rowsort label-2076
SELECT ALL + + 89 / - col1 FROM tab1 AS cor0
----
-3
-6
-8

query I rowsort
SELECT - 37 + + col1 AS col2 FROM tab0 AS cor0
----
49
54
60

query I rowsort
SELECT ALL + 69 * - col0 FROM tab1
----
-207
-4416
-5520

query I rowsort
SELECT + col2 * 93 FROM tab2 AS cor0
----
2418
2511
3534

query I rowsort
SELECT col2 * 23 * + col1 AS col1 FROM tab1 AS cor0
----
13110
28704
32292

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 96 col1 FROM tab2
----
96
96
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2082
SELECT - 24 DIV ( + col1 ) + - 94 FROM tab0 AS cor0
----
-94
-94
-94

skipif mysql # not compatible
query I rowsort label-2082
SELECT - 24 / ( + col1 ) + - 94 FROM tab0 AS cor0
----
-94
-94
-94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2083
SELECT ALL + CAST( NULL AS SIGNED ) * 92 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2083
SELECT ALL + CAST ( NULL AS INTEGER ) * 92 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ( col0 ) * - col1 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-2085
SELECT + - col1 + + col0 DIV - cor0.col1 col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2085
SELECT + - col1 + + col0 / - cor0.col1 col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ( - col2 ) + - cor0.col1 * col2 * col0 FROM tab1 AS cor0
----
-36537
-4266
-99936

query I rowsort
SELECT col2 + - col1 + col0 FROM tab0
----
-29
-61
80

query I rowsort
SELECT + col0 * 37 FROM tab0
----
1295
3293
888

query I rowsort
SELECT 37 * 27 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 3ae59fec0bbf20fe99439eab2e41ac87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2090
SELECT DISTINCT + col1 + + CAST( 75 * - col0 AS SIGNED ) FROM tab1
----
-199
-4790
-5987

skipif mysql # not compatible
query I rowsort label-2090
SELECT DISTINCT + col1 + + CAST ( 75 * - col0 AS INTEGER ) FROM tab1
----
-199
-4790
-5987

query I rowsort
SELECT + col2 * - tab0.col1 + col2 AS col2 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT ALL tab2.col0 + + 60 FROM tab2
----
138
139
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2093
SELECT DISTINCT + CAST( NULL AS SIGNED ) * tab0.col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-2093
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * tab0.col1 FROM tab0
----
NULL

query I rowsort
SELECT + + 80 + + cor0.col2 * + col0 * + col1 FROM tab2 cor0
----
119732
51114
5939

query I rowsort
SELECT DISTINCT + tab0.col1 AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
86
91
97

query I rowsort
SELECT ALL - col2 + 43 AS col2 FROM tab0 cor0
----
-39
10
42

query I rowsort
SELECT - + col1 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT + + col2 + + col2 AS col2 FROM tab0 cor0
----
164
2
66

query I rowsort
SELECT - col1 + - col0 * + col0 * + ( cor0.col1 + - col1 ) AS col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL 84 + col1 + cor0.col0 AS col2 FROM tab1 AS cor0
----
113
158
177

query I rowsort
SELECT DISTINCT + col2 - 2 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
-64
-71
48

query I rowsort
SELECT col0 - - 48 FROM tab0
----
137
72
83

query I rowsort
SELECT ALL tab1.col2 + ( - tab1.col0 * + col2 ) FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT - col0 + - 8 AS col0 FROM tab2
----
-15
-86
-87

query I rowsort
SELECT - - col2 + 81 * col2 * - cor0.col0 FROM tab2 cor0
----
-15282
-164242
-243124

query I rowsort
SELECT - - col1 + col0 * - 24 FROM tab0 AS cor0
----
-2045
-490
-743

query I rowsort
SELECT DISTINCT 78 * col2 AS col2 FROM tab0 cor0
----
2574
6396
78

query I rowsort
SELECT - 63 * + col2 AS col0 FROM tab0 AS cor0
----
-2079
-5166
-63

query I rowsort
SELECT DISTINCT + col2 + 57 * col1 AS col0 FROM tab2 AS cor0
----
1007
1794
3389

query I rowsort
SELECT ALL + - col1 * col0 + - cor0.col1 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT DISTINCT - ( col2 ) - col1 * - 93 * col0 FROM tab0 AS cor0
----
191919
315734
753125

query I rowsort
SELECT + + 46 FROM tab0 AS cor0
----
46
46
46

query I rowsort
SELECT DISTINCT - col1 + cor0.col1 * - col0 * + 55 AS col1 FROM tab0 AS cor0
----
-113606
-186822
-445536

query I rowsort
SELECT - tab1.col1 + 74 AS col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to b6bbc15ea089e522f19b667213191b67

query I rowsort
SELECT ALL + 17 + + col1 FROM tab1 AS cor0
----
27
30
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-2116
SELECT ALL - col2 DIV - cor0.col0 + col0 * ( - col0 ) AS col2 FROM tab1 AS cor0
----
-4096
-6399
9

skipif mysql # not compatible
query I rowsort label-2116
SELECT ALL - col2 / - cor0.col0 + col0 * ( - col0 ) AS col2 FROM tab1 AS cor0
----
-4096
-6399
9

query I rowsort
SELECT DISTINCT ( + cor0.col1 ) - col1 * + 78 * - col2 FROM tab2 AS cor0
----
119711
50405
65317

query I rowsort
SELECT DISTINCT + 24 * 70 - + col1 AS col2 FROM tab0 AS cor0
----
1583
1589
1594

query I rowsort
SELECT ALL + 23 * - 69 FROM tab0 AS cor0
----
-1587
-1587
-1587

onlyif mysql # use DIV operator for integer division
query I rowsort label-2120
SELECT ALL - - col2 DIV 81 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2120
SELECT ALL - - col2 / 81 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT + 19 + + col1 AS col0 FROM tab1 AS cor0
----
29
32
45

query I rowsort
SELECT + col1 + - col0 * - col0 - col2 * + cor0.col0 FROM tab1 AS cor0
----
-1267
-127
458

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + - col0 col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL + 35 * - col0 FROM tab1 cor0
----
-105
-2240
-2800

onlyif mysql # use DIV operator for integer division
query I rowsort label-2125
SELECT - cor0.col1 + + col2 DIV col0 col1 FROM tab0 AS cor0
----
-85
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2125
SELECT - cor0.col1 + + col2 / col0 col1 FROM tab0 AS cor0
----
-85
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2126
SELECT - ( - col1 ) DIV + col1 AS col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2126
SELECT - ( - col1 ) / + col1 AS col0 FROM tab2
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2127
SELECT + 67 DIV + col1 AS col1 FROM tab2
----
1
2
3

skipif mysql # not compatible
query I rowsort label-2127
SELECT + 67 / + col1 AS col1 FROM tab2
----
1
2
3

query I rowsort
SELECT + + col2 + col2 - + ( cor0.col0 * col2 ) FROM tab1 AS cor0
----
-3534
-54
-7488

query I rowsort
SELECT - col1 + col1 + + 70 AS col1 FROM tab2 AS cor0
----
70
70
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-2130
SELECT DISTINCT col0 DIV - col2 + - 72 AS col2 FROM tab1 AS cor0
----
-72
-73

skipif mysql # not compatible
query I rowsort label-2130
SELECT DISTINCT col0 / - col2 + - 72 AS col2 FROM tab1 AS cor0
----
-72
-73

query I rowsort
SELECT ALL col0 * - ( 37 ) - cor0.col0 * col1 FROM tab2 AS cor0
----
-4266
-476
-7488

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2132
SELECT ALL + col2 * - CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2132
SELECT ALL + col2 * - CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2133
SELECT ALL col0 * + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2133
SELECT ALL col0 * + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col1 * col2 + 83 FROM tab1 cor0
----
-1165
-1321
-487

query I rowsort
SELECT ALL col2 + + col0 + + col1 * + col2 AS col0 FROM tab1 AS cor0
----
1424
1461
691

query I rowsort
SELECT DISTINCT - col2 * ( col0 ) * - col1 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT + - cor0.col2 + col2 * col0 AS col0 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT DISTINCT - - col1 * 92 * 75 FROM tab0 AS cor0
----
593400
627900
669300

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2139
SELECT + cor0.col1 + + CAST( 70 AS SIGNED ) FROM tab1 AS cor0
----
80
83
96

skipif mysql # not compatible
query I rowsort label-2139
SELECT + cor0.col1 + + CAST ( 70 AS INTEGER ) FROM tab1 AS cor0
----
80
83
96

query I rowsort
SELECT cor0.col2 + - ( + 74 + + col2 * col1 ) FROM tab1 AS cor0
----
-1226
-1424
-587

query I rowsort
SELECT + - cor0.col1 + - 72 FROM tab0 AS cor0
----
-158
-163
-169

query I rowsort
SELECT ALL - + col2 * 86 FROM tab1 AS cor0
----
-4644
-4902
-8256

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 * - col2 + col2 col2 FROM tab0 AS cor0
----
-3394
-664036
-68079

query I rowsort
SELECT ALL + 71 - - col2 AS col2 FROM tab1
----
125
128
167

onlyif mysql # use DIV operator for integer division
query I rowsort label-2145
SELECT + tab0.col0 * col0 DIV col0 AS col2 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2145
SELECT + tab0.col0 * col0 / col0 AS col2 FROM tab0
----
24
35
89

query I rowsort
SELECT ALL - col2 + + 73 * col1 AS col0 FROM tab1 AS cor0
----
1844
673
853

onlyif mysql # use DIV operator for integer division
query I rowsort label-2147
SELECT - col1 + col1 DIV - cor0.col2 FROM tab0 AS cor0
----
-194
-88
-92

skipif mysql # not compatible
query I rowsort label-2147
SELECT - col1 + col1 / - cor0.col2 FROM tab0 AS cor0
----
-194
-88
-92

query I rowsort
SELECT col1 * + col0 - - col1 AS col1 FROM tab1 cor0
----
104
1053
650

query I rowsort
SELECT ALL col2 + - 28 * - tab1.col1 AS col1 FROM tab1
----
337
460
782

query I rowsort
SELECT DISTINCT - - col1 + - 94 AS col1 FROM tab0 AS cor0
----
-3
-8
3

query I rowsort
SELECT cor0.col1 * - ( col1 ) * cor0.col1 + col1 AS col1 FROM tab1 AS cor0
----
-17550
-2184
-990

query I rowsort
SELECT + cor0.col1 * ( cor0.col2 + - col1 ) AS col1 FROM tab1 AS cor0
----
1079
470
728

query I rowsort
SELECT ALL + 4 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT DISTINCT col2 * 31 + col2 AS col2 FROM tab2
----
1216
832
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-2155
SELECT + cor0.col1 + col1 DIV ( + col2 * col1 ) FROM tab0 AS cor0
----
86
91
98

skipif mysql # not compatible
query I rowsort label-2155
SELECT + cor0.col1 + col1 / ( + col2 * col1 ) FROM tab0 AS cor0
----
86
91
98

query I rowsort
SELECT + + 12 * - 57 + + col1 FROM tab2 cor0
----
-625
-653
-667

onlyif mysql # use DIV operator for integer division
query I rowsort label-2157
SELECT 93 DIV - col1 - - tab0.col2 * ( 73 ) AS col1 FROM tab0
----
2408
5985
73

skipif mysql # not compatible
query I rowsort label-2157
SELECT 93 / - col1 - - tab0.col2 * ( 73 ) AS col1 FROM tab0
----
2408
5985
73

query I rowsort
SELECT + 66 + - col0 + col2 * - col2 FROM tab0
----
-1047
-6747
30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2159
SELECT col0 * col1 * CAST( NULL AS SIGNED ) col0 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2159
SELECT col0 * col1 * CAST ( NULL AS INTEGER ) col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab1.col0 * + col1 + - ( col2 ) + + col1 AS col1 FROM tab1
----
50
593
957

query I rowsort
SELECT DISTINCT + 76 FROM tab1 cor0
----
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-2162
SELECT + col2 - - col1 DIV - col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2162
SELECT + col2 - - col1 / - col2 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2163
SELECT + - 79 DIV + col1 AS col0 FROM tab1 cor0
----
-3
-6
-7

skipif mysql # not compatible
query I rowsort label-2163
SELECT + - 79 / + col1 AS col0 FROM tab1 cor0
----
-3
-6
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 82 * - col2 col1 FROM tab2 AS cor0
----
2132
2214
3116

query I rowsort
SELECT 83 * + col0 * col0 AS col2 FROM tab2 AS cor0
----
4067
504972
518003

query I rowsort
SELECT - ( - col1 ) * - cor0.col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - ( 90 * tab0.col1 ) AS col0 FROM tab0
----
-7740
-8190
-8730

onlyif mysql # use DIV operator for integer division
query I rowsort label-2168
SELECT col2 DIV tab2.col0 + - col0 FROM tab2
----
-4
-78
-79

skipif mysql # not compatible
query I rowsort label-2168
SELECT col2 / tab2.col0 + - col0 FROM tab2
----
-4
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-2169
SELECT - ( col2 ) DIV - tab1.col2 + 47 FROM tab1
----
48
48
48

skipif mysql # not compatible
query I rowsort label-2169
SELECT - ( col2 ) / - tab1.col2 + 47 FROM tab1
----
48
48
48

query I rowsort
SELECT ALL - 17 + cor0.col2 AS col0 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to f5e5856188e2c1ea74b16bf2d7011cfa

query I rowsort
SELECT ALL + tab2.col1 AS col1 FROM tab2, tab1 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to a5b6acb471910ea4ad7f31cae3b818f7

query I rowsort
SELECT ALL + 61 + col1 FROM tab1 AS cor0
----
71
74
87

query I rowsort
SELECT ALL - - 8 + col0 AS col0 FROM tab1 cor0
----
11
72
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-2174
SELECT DISTINCT + col2 DIV - col0 + + col0 AS col1 FROM tab0 cor0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-2174
SELECT DISTINCT + col2 / - col0 + + col0 AS col1 FROM tab0 cor0
----
23
35
89

query I rowsort
SELECT ALL + col0 + ( col1 + - col2 ) FROM tab1
----
-25
-3
17

query I rowsort
SELECT DISTINCT tab1.col2 + - tab1.col1 * - 15 * + col1 FROM tab1
----
10194
1557
2631

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( cor0.col1 ) col1 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

query I rowsort
SELECT ALL - + col0 + - ( + ( col0 ) ) AS col1 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT col2 * cor0.col1 * col0 AS col1 FROM tab0 AS cor0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-2180
SELECT + col2 DIV ( 67 + col2 ) AS col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2180
SELECT + col2 / ( 67 + col2 ) AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ( 96 ) * + tab0.col0 * col2 AS col1 FROM tab0
----
3360
700608
76032

query I rowsort
SELECT + + col1 + 74 * col2 AS col0 FROM tab1 AS cor0
----
4022
4228
7117

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + + col0 + - col0 * col1 col1 FROM tab1 AS cor0
----
-21
-519
-864

query I rowsort
SELECT DISTINCT - ( + col2 ) + col0 AS col1 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2185
SELECT CAST( NULL AS SIGNED ) * - col0 + - col2 * col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2185
SELECT CAST ( NULL AS INTEGER ) * - col0 + - col2 * col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( - ( + col0 ) ) * + col0 + + col2 * col0 * - col0 FROM tab0 cor0
----
-19584
-2450
-657443

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2187
SELECT - col0 * col2 + CAST( - col2 AS SIGNED ) * col1 AS col0 FROM tab1 AS cor0
----
-1566
-4218
-8928

skipif mysql # not compatible
query I rowsort label-2187
SELECT - col0 * col2 + CAST ( - col2 AS INTEGER ) * col1 AS col0 FROM tab1 AS cor0
----
-1566
-4218
-8928

query I rowsort
SELECT ALL - col1 + col1 + col1 FROM tab0
----
86
91
97

query I rowsort
SELECT ALL 1 - + col1 AS col1 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT DISTINCT + 79 * + tab2.col2 FROM tab2
----
2054
2133
3002

query I rowsort
SELECT - 66 * - cor0.col2 + 49 * col0 * col0 AS col1 FROM tab0 AS cor0
----
30402
393541
60091

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2192
SELECT DISTINCT CAST( NULL AS DECIMAL ) FROM tab0, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2192
SELECT DISTINCT CAST ( NULL AS REAL ) FROM tab0, tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2193
SELECT - col0 / - CAST( NULL AS SIGNED ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2193
SELECT - col0 / - CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + 3 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
3

skipif mysql # not compatible
query I rowsort
SELECT + - cor0.col0 * CAST ( + col1 AS REAL ) 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 - + 20 * + 74 FROM tab0 AS cor0
----
-1480
-1480
-1480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2198
SELECT DISTINCT col0 + - CAST( NULL AS DECIMAL ) * tab2.col2 AS col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-2198
SELECT DISTINCT col0 + - CAST ( NULL AS REAL ) * tab2.col2 AS col1 FROM tab2
----
NULL

query I rowsort
SELECT - - col0 - - col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + 73 + + col1 AS col2 FROM tab0 AS cor0
----
159
164
170

query I rowsort
SELECT col1 * col1 * - ( - col0 * + ( - col2 ) ) AS col2 FROM tab0
----
-329315
-5857632
-60434738

query I rowsort
SELECT DISTINCT col1 * ( col0 ) FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-2203
SELECT col0 DIV 6 AS col1 FROM tab1
----
0
10
13

skipif mysql # not compatible
query I rowsort label-2203
SELECT col0 / 6 AS col1 FROM tab1
----
0
10
13

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2204
SELECT + col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2204
SELECT + col0 + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col2 + col1 * - col1 * col0 FROM tab1 AS cor0
----
-13424
-1974
-6343

query I rowsort
SELECT DISTINCT col1 + col0 * - col0 AS col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT col2 - col2 * 71 FROM tab2
----
-1820
-1890
-2660

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2208
SELECT DISTINCT - col0 + - CAST( NULL AS SIGNED ) + 24 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-2208
SELECT DISTINCT - col0 + - CAST ( NULL AS INTEGER ) + 24 FROM tab0
----
NULL

query I rowsort
SELECT ALL col2 + ( - col0 ) FROM tab2
----
-41
-52
20

query I rowsort
SELECT - col0 + + 17 AS col0 FROM tab2
----
-61
-62
10

query I rowsort
SELECT DISTINCT + col1 + + ( - col2 + + col2 ) * 49 AS col2 FROM tab0
----
86
91
97

query I rowsort
SELECT ALL col1 * ( + col1 ) AS col0 FROM tab1 AS cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 65 + + col0 col1 FROM tab1 AS cor0
----
198
4224
5280

query I rowsort
SELECT ALL col1 * + 43 FROM tab2 AS cor0
----
1333
2537
731

query I rowsort
SELECT DISTINCT + - col2 * cor0.col2 + 66 * col2 FROM tab2 AS cor0
----
1040
1053
1064

query I rowsort
SELECT col0 + 44 FROM tab2
----
122
123
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 6 col1 FROM tab2
----
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2218
SELECT ALL - + CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2218
SELECT ALL - + CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + col0 - ( col2 + - col2 * 99 ) AS col0 FROM tab1
----
5295
5650
9488

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2220
SELECT - CAST( NULL AS SIGNED ) * - 8 + - tab2.col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2220
SELECT - CAST ( NULL AS INTEGER ) * - 8 + - tab2.col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( + col0 ) * tab0.col0 AS col0 FROM tab0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-2222
SELECT 66 DIV col1 AS col0 FROM tab1
----
2
5
6

skipif mysql # not compatible
query I rowsort label-2222
SELECT 66 / col1 AS col0 FROM tab1
----
2
5
6

query I rowsort
SELECT + - col0 * col2 + - col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT + col1 * - col2 - + col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT - + col0 - - col2 * col1 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT DISTINCT - - col1 + - col1 - + col1 * col1 AS col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL + + cor0.col1 + + cor0.col2 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT DISTINCT col0 + - col1 * - ( col0 ) * col1 + + col0 AS col0 FROM tab1 AS cor0
----
13680
2034
6528

query I rowsort
SELECT DISTINCT col2 * - col2 + cor0.col0 AS col0 FROM tab2 AS cor0
----
-1365
-598
-722

onlyif mysql # use DIV operator for integer division
query I rowsort label-2230
SELECT ALL - + col0 * + col0 DIV col0 + 31 FROM tab0 AS cor0
----
-4
-58
7

skipif mysql # not compatible
query I rowsort label-2230
SELECT ALL - + col0 * + col0 / col0 + 31 FROM tab0 AS cor0
----
-4
-58
7

query I rowsort
SELECT - 87 - col1 * col0 * cor0.col0 FROM tab2 AS cor0
----
-106184
-1606
-359043

query I rowsort
SELECT DISTINCT + col1 * col1 + 99 FROM tab1 cor0
----
199
268
775

onlyif mysql # use DIV operator for integer division
query I rowsort label-2233
SELECT ALL - col2 DIV col0 + - ( + col0 * + tab0.col1 ) FROM tab0
----
-2065
-3395
-8099

skipif mysql # not compatible
query I rowsort label-2233
SELECT ALL - col2 / col0 + - ( + col0 * + tab0.col1 ) FROM tab0
----
-2065
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2234
SELECT col0 + + cor0.col2 * + CAST( NULL AS SIGNED ) * - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2234
SELECT col0 + + cor0.col2 * + CAST ( NULL AS INTEGER ) * - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( + cor0.col1 ) FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - col1 * - col2 * - 4 FROM tab0 AS cor0
----
-11352
-29848
-388

onlyif mysql # use DIV operator for integer division
query I rowsort label-2237
SELECT ALL 36 DIV - col0 - + cor0.col0 * col2 FROM tab0 AS cor0
----
-36
-7298
-793

skipif mysql # not compatible
query I rowsort label-2237
SELECT ALL 36 / - col0 - + cor0.col0 * col2 FROM tab0 AS cor0
----
-36
-7298
-793

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2238
SELECT DISTINCT + ( col1 ) * - CAST( 1 + + col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-194
-2924
-7553

skipif mysql # not compatible
query I rowsort label-2238
SELECT DISTINCT + ( col1 ) * - CAST ( 1 + + col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT ALL + col1 + + col2 * + col1 - + 63 FROM tab1 cor0
----
1198
1367
517

query I rowsort
SELECT + col1 + - col1 * ( - 64 * col0 + col2 ) FROM tab1 AS cor0
----
3614
40400
65325

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + + col1 col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - cor0.col2 * + col0 + cor0.col2 * - col2 FROM tab2 AS cor0
----
-2704
-4446
-918

query I rowsort
SELECT ALL col0 * 60 + col0 FROM tab0 AS cor0
----
1464
2135
5429

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2244
SELECT DISTINCT col0 * - CAST( col1 AS SIGNED ) + + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

skipif mysql # not compatible
query I rowsort label-2244
SELECT DISTINCT col0 * - CAST ( col1 AS INTEGER ) + + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL - col1 + col0 * col1 * col2 FROM tab0 AS cor0
----
3298
664027
68026

query I rowsort
SELECT col1 * - 84 * col0 - col0 FROM tab0 AS cor0
----
-173400
-285215
-680405

query I rowsort
SELECT DISTINCT - + col0 + - 0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - + cor0.col1 * - col0 + + ( - col1 ) * - col2 * col2 AS col1 FROM tab2 cor0
----
22816
25891
44486

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2249
SELECT ALL + 52 * col2 - CAST( col1 + - col2 AS SIGNED ) FROM tab1
----
2836
3011
5075

skipif mysql # not compatible
query I rowsort label-2249
SELECT ALL + 52 * col2 - CAST ( col1 + - col2 AS INTEGER ) FROM tab1
----
2836
3011
5075

query I rowsort
SELECT ALL + col1 * col2 * - col1 + + col2 FROM tab0
----
-244035
-678960
-9408

query I rowsort
SELECT + + col2 * ( col0 ) + col0 AS col0 FROM tab0 AS cor0
----
70
7387
816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 - col1 col1 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT ALL ( 75 ) * + cor0.col0 AS col1 FROM tab2 AS cor0
----
525
5850
5925

query I rowsort
SELECT DISTINCT + ( col2 ) + col2 * - 79 AS col2 FROM tab0 AS cor0
----
-2574
-6396
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2255
SELECT ALL - + col0 DIV 33 FROM tab1 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-2255
SELECT ALL - + col0 / 33 FROM tab1 AS cor0
----
-1
-2
0

query I rowsort
SELECT - ( + 35 ) * col1 AS col2 FROM tab2 AS cor0
----
-1085
-2065
-595

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2257
SELECT ALL - col1 + ( - col1 + CAST( - col2 AS SIGNED ) ) FROM tab2 AS cor0
----
-144
-72
-89

skipif mysql # not compatible
query I rowsort label-2257
SELECT ALL - col1 + ( - col1 + CAST ( - col2 AS INTEGER ) ) FROM tab2 AS cor0
----
-144
-72
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2258
SELECT DISTINCT + col0 DIV + col1 - col1 FROM tab2 AS cor0
----
-13
-31
-58

skipif mysql # not compatible
query I rowsort label-2258
SELECT DISTINCT + col0 / + col1 - col1 FROM tab2 AS cor0
----
-13
-31
-58

query I rowsort
SELECT + 88 * + ( - col2 ) AS col1 FROM tab0 AS cor0
----
-2904
-7216
-88

query I rowsort
SELECT DISTINCT - - cor0.col0 * col2 - - col1 FROM tab0 cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-2261
SELECT DISTINCT + - col0 DIV col1 AS col1 FROM tab2 cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-2261
SELECT DISTINCT + - col0 / col1 AS col1 FROM tab2 cor0
----
-1
-4
0

query I rowsort
SELECT ALL - - 62 * col2 AS col0 FROM tab2 AS cor0
----
1612
1674
2356

query I rowsort
SELECT DISTINCT tab0.col1 + - 58 * col1 FROM tab0
----
-4902
-5187
-5529

query I rowsort
SELECT ALL + - 31 * col0 FROM tab1 AS cor0
----
-1984
-2480
-93

query I rowsort
SELECT ALL ( - col1 ) * - col2 AS col1 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2266
SELECT DISTINCT - 66 + + col1 DIV col0 FROM tab1 AS cor0
----
-58
-66

skipif mysql # not compatible
query I rowsort label-2266
SELECT DISTINCT - 66 + + col1 / col0 FROM tab1 AS cor0
----
-58
-66

query I rowsort
SELECT - ( col2 ) * - tab0.col0 + - col2 * 46 FROM tab0
----
-11
-726
3526

query I rowsort
SELECT DISTINCT col1 * 56 FROM tab1
----
1456
560
728

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2269
SELECT + CAST( NULL AS SIGNED ) + 63 * col1 * + col2 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2269
SELECT + CAST ( NULL AS INTEGER ) + 63 * col1 * + col2 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab1.col2 AS col1 FROM tab1, tab0 AS cor0, tab1 cor1
----
54
57
96

query I rowsort
SELECT ALL + - col2 * ( + col0 ) FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - col0 * + 36 FROM tab2 AS cor0
----
-252
-2808
-2844

query I rowsort
SELECT DISTINCT - - col1 * - col2 - + col1 AS col2 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT ALL + cor0.col1 + - cor0.col0 * col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT - col2 + - col2 * 58 * cor0.col0 FROM tab2 AS cor0
----
-10989
-117650
-174154

query I rowsort
SELECT col2 * cor0.col1 + + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT - + col1 + ( + col0 ) FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT col0 + col2 * + 58 AS col0 FROM tab1
----
3135
3370
5648

query I rowsort
SELECT - 45 * col1 FROM tab2
----
-1395
-2655
-765

query I rowsort
SELECT - col2 * + ( 41 ) FROM tab2 AS cor0
----
-1066
-1107
-1558

query I rowsort
SELECT - + col0 * 44 + col0 * col2 FROM tab0 AS cor0
----
-1505
-264
3382

query I rowsort
SELECT col0 + + 73 FROM tab1
----
137
153
76

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0, tab0 cor1, tab1 cor2
----
972 values hashing to 88213a0de4c0a44aaefe8bbffbcaf44a

query I rowsort
SELECT + col0 * col1 * col1 + col1 AS col0 FROM tab2 AS cor0
----
22848
271577
6758

query I rowsort
SELECT ALL + + 0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2286
SELECT ALL col1 DIV + tab1.col0 FROM tab1
----
0
0
8

skipif mysql # not compatible
query I rowsort label-2286
SELECT ALL col1 / + tab1.col0 FROM tab1
----
0
0
8

query I rowsort
SELECT - 47 + + tab2.col0 + col1 * + col0 FROM tab2
----
1375
177
4633

query I rowsort
SELECT DISTINCT 93 + col2 FROM tab1
----
147
150
189

query I rowsort
SELECT + 51 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

query I rowsort
SELECT ALL + 63 * col2 FROM tab1
----
3402
3591
6048

query I rowsort
SELECT ALL - ( + col1 * ( 80 ) ) FROM tab0
----
-6880
-7280
-7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + cor0.col0 - ( - col1 ) col0 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT cor0.col0 + - ( tab2.col0 ) AS col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to fe77e742ee356950e73e6d48a37f2637

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2294
SELECT col2 + CAST( NULL AS SIGNED ) / col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2294
SELECT col2 + CAST ( NULL AS INTEGER ) / col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 46 AS col0 FROM tab2, tab2 AS cor0
----
46

query I rowsort
SELECT + col1 * 31 AS col2 FROM tab0
----
2666
2821
3007

query I rowsort
SELECT ALL + col1 * 5 AS col0 FROM tab2
----
155
295
85

query I rowsort
SELECT DISTINCT - col1 - tab2.col0 AS col0 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT - 33 + col0 AS col2 FROM tab2 AS cor0
----
-26
45
46

query I rowsort
SELECT ALL 87 + + col1 * col2 FROM tab2 AS cor0
----
1621
733
924

query I rowsort
SELECT 21 * col2 FROM tab2 AS cor0
----
546
567
798

query I rowsort
SELECT DISTINCT 39 * - cor0.col1 AS col1 FROM tab0, tab0 AS cor0
----
-3354
-3549
-3783

onlyif mysql # use DIV operator for integer division
query I rowsort label-2303
SELECT col0 DIV - col2 - - 5 AS col2 FROM tab0 AS cor0
----
-30
4
5

skipif mysql # not compatible
query I rowsort label-2303
SELECT col0 / - col2 - - 5 AS col2 FROM tab0 AS cor0
----
-30
4
5

query I rowsort
SELECT + 82 * cor0.col1 AS col0 FROM tab1 cor0
----
1066
2132
820

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2305
SELECT ( - col0 ) + + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2305
SELECT ( - col0 ) + + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( - col2 + - col1 ) AS col0 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT 14 + col2 * - col2 AS col2 FROM tab0
----
-1075
-6710
13

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2308
SELECT - CAST( + col0 AS SIGNED ) + col2 col1 FROM tab2
----
-41
-52
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2308
SELECT - CAST ( + col0 AS INTEGER ) + col2 col1 FROM tab2
----
-41
-52
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 4 * - cor0.col1 col1 FROM tab1 cor0
----
104
40
52

query I rowsort
SELECT ALL + - col2 * 65 AS col0 FROM tab0 AS cor0
----
-2145
-5330
-65

query I rowsort
SELECT DISTINCT - 48 + cor0.col0 FROM tab2, tab1 cor0
----
-45
16
32

query I rowsort
SELECT DISTINCT - 42 * col2 AS col2 FROM tab1 AS cor0
----
-2268
-2394
-4032

query I rowsort
SELECT ALL - - 6 * col0 AS col1 FROM tab2 AS cor0
----
42
468
474

query I rowsort
SELECT + - 94 * col2 AS col1 FROM tab1 AS cor0
----
-5076
-5358
-9024

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 85 * - ( col1 ) col0 FROM tab2 AS cor0
----
1445
2635
5015

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2316
SELECT - CAST( NULL AS SIGNED ) + + 99 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2316
SELECT - CAST ( NULL AS INTEGER ) + + 99 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * col0 + - col2 + - 14 FROM tab2 AS cor0
----
-1395
-258
-4642

onlyif mysql # use DIV operator for integer division
query I rowsort label-2318
SELECT - cor1.col2 DIV - 23 + cor0.col0 AS col1 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 673e8c402af6ec31c928fed03a917dc2

skipif mysql # not compatible
query I rowsort label-2318
SELECT - cor1.col2 / - 23 + cor0.col0 AS col1 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 673e8c402af6ec31c928fed03a917dc2

query I rowsort
SELECT DISTINCT col0 + col0 * 60 AS col0 FROM tab2 AS cor0
----
427
4758
4819

query I rowsort
SELECT - col1 * + 9 FROM tab2
----
-153
-279
-531

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2321
SELECT DISTINCT col1 * col0 + - tab0.col1 * CAST( + 81 AS SIGNED ) FROM tab0
----
-4462
-4902
728

skipif mysql # not compatible
query I rowsort label-2321
SELECT DISTINCT col1 * col0 + - tab0.col1 * CAST ( + 81 AS INTEGER ) FROM tab0
----
-4462
-4902
728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + col0 + col0 col1 FROM tab1
----
185
256
60

query I rowsort
SELECT ( + col1 ) * - col2 + - col0 AS col0 FROM tab2
----
-1612
-725
-844

query I rowsort
SELECT ALL + col2 + col1 + + col0 FROM tab2
----
134
163
65

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col1 AS REAL ) - + col1 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT tab0.col2 + tab0.col0 FROM tab0
----
171
36
57

query I rowsort
SELECT - 29 + - col2 * col2 FROM tab2
----
-1473
-705
-758

onlyif mysql # use DIV operator for integer division
query I rowsort label-2328
SELECT DISTINCT col2 DIV + tab0.col0 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-2328
SELECT DISTINCT col2 / + tab0.col0 FROM tab0
----
0
1

query I rowsort
SELECT DISTINCT + col2 + 60 FROM tab1 AS cor0
----
114
117
156

query I rowsort
SELECT DISTINCT - col0 + + col0 * - 29 FROM tab1 AS cor0
----
-1920
-2400
-90

query I rowsort
SELECT + col2 * + 60 FROM tab0 AS cor0
----
1980
4920
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-2332
SELECT col1 DIV - 81 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2332
SELECT col1 / - 81 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2333
SELECT ALL + ( tab1.col1 ) DIV + col2 + + tab1.col2 AS col1 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-2333
SELECT ALL + ( tab1.col1 ) / + col2 + + tab1.col2 AS col1 FROM tab1
----
54
57
96

query I rowsort
SELECT + col2 * ( + col1 ) AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + col2 * 82 FROM tab1 AS cor0
----
4428
4674
7872

query I rowsort
SELECT - - cor0.col1 + + 88 FROM tab0 AS cor0
----
174
179
185

query I rowsort
SELECT DISTINCT - col2 * + 72 * col1 FROM tab0
----
-204336
-537264
-6984

query I rowsort
SELECT - col2 * + ( - col1 ) * - col2 - ( + col1 * col0 ) FROM tab1
----
-120848
-33130
-75894

query I rowsort
SELECT + 95 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT DISTINCT + col0 + 69 + - 69 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - col1 + + ( - ( + cor0.col1 ) ) FROM tab2 AS cor0
----
-118
-34
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2342
SELECT ALL CAST( 62 AS SIGNED ) AS col0 FROM tab0 cor0
----
62
62
62

skipif mysql # not compatible
query I rowsort label-2342
SELECT ALL CAST ( 62 AS INTEGER ) AS col0 FROM tab0 cor0
----
62
62
62

query I rowsort
SELECT DISTINCT ( + col2 ) * col1 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + - col1 * - col1 * col1 + col0 FROM tab1 AS cor0
----
1064
17579
2277

query I rowsort
SELECT 11 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

query I rowsort
SELECT DISTINCT + 10 * col1 AS col2 FROM tab1 AS cor0
----
100
130
260

query I rowsort
SELECT 59 * - col2 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
-39884
-43011
-85196

query I rowsort
SELECT DISTINCT 5 + col2 + col1 FROM tab2 AS cor0
----
60
63
90

query I rowsort
SELECT ALL + col1 + cor0.col2 + + col2 * ( col0 + col0 ) AS col1 FROM tab0 AS cor0
----
14769
168
1703

query I rowsort
SELECT ALL - ( + 44 ) + - col2 FROM tab0 AS cor0
----
-126
-45
-77

query I rowsort
SELECT DISTINCT - 25 + + col0 FROM tab2 AS cor0
----
-18
53
54

query I rowsort
SELECT ALL - col2 * + col2 - col0 AS col0 FROM tab1 AS cor0
----
-2919
-3313
-9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-2353
SELECT - col1 * col0 + - col2 DIV - cor0.col0 FROM tab2 AS cor0
----
-1343
-214
-4602

skipif mysql # not compatible
query I rowsort label-2353
SELECT - col1 * col0 + - col2 / - cor0.col0 FROM tab2 AS cor0
----
-1343
-214
-4602

query I rowsort
SELECT ALL 82 * - col0 + col2 FROM tab2 cor0
----
-547
-6370
-6440

query I rowsort
SELECT - col1 + + col1 * col2 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT 97 * - cor1.col2 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ca28b071849a842598f1560055e194a4

query I rowsort
SELECT ALL - 7 * cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 2b1a70ceeb411b724d39aa76e42e10a0

query I rowsort
SELECT ALL - - col2 * col0 + 9 AS col0 FROM tab2 AS cor0
----
198
2037
3011

query I rowsort
SELECT DISTINCT + - col1 * + col2 - - col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT + ( + cor0.col2 ) * + 38 - cor0.col2 FROM tab2 AS cor0
----
1406
962
999

query I rowsort
SELECT DISTINCT + col1 + col2 * - cor0.col0 AS col2 FROM tab0 cor0
----
-706
-7207
62

query I rowsort
SELECT ALL - - ( col2 ) + - 57 - + 55 FROM tab0 AS cor0
----
-111
-30
-79

query I rowsort
SELECT 15 + col1 FROM tab0 AS cor0
----
101
106
112

query I rowsort
SELECT DISTINCT + + ( + col0 ) + + 45 AS col1 FROM tab1 AS cor0
----
109
125
48

query I rowsort
SELECT DISTINCT + 82 * - col0 FROM tab2 cor0
----
-574
-6396
-6478

query I rowsort
SELECT - + ( col2 ) + 27 * col0 AS col1 FROM tab0 cor0
----
2321
615
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-2367
SELECT ALL + + 33 + cor0.col0 DIV - 86 AS col2 FROM tab0 AS cor0
----
32
33
33

skipif mysql # not compatible
query I rowsort label-2367
SELECT ALL + + 33 + cor0.col0 / - 86 AS col2 FROM tab0 AS cor0
----
32
33
33

query I rowsort
SELECT ALL col1 * - 27 - cor0.col1 AS col2 FROM tab0 AS cor0
----
-2408
-2548
-2716

query I rowsort
SELECT - col0 * - cor0.col1 + ( - col1 ) FROM tab0 AS cor0
----
1978
3298
8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2370
SELECT ALL - + col0 + + CAST( - col0 * - col2 AS SIGNED ) FROM tab2 AS cor0
----
182
1950
2923

skipif mysql # not compatible
query I rowsort label-2370
SELECT ALL - + col0 + + CAST ( - col0 * - col2 AS INTEGER ) FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT DISTINCT - col1 * + ( + col0 ) * col2 AS col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT + - cor0.col1 + col1 AS col1 FROM tab0 cor0
----
0

query I rowsort
SELECT ALL - - col0 + ( ( col1 ) ) AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT ( 10 ) * tab1.col0 + + tab1.col2 * + 24 + - col1 FROM tab1
----
1300
1998
3091

query I rowsort
SELECT 59 * - col2 + + col1 + col1 AS col2 FROM tab2
----
-1416
-1531
-2208

query I rowsort
SELECT + - col0 * cor0.col0 - - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT DISTINCT - ( - col2 * col1 ) AS col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT col1 + + cor0.col0 * col1 AS col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT - cor0.col1 * col0 + col2 * - col2 FROM tab1 AS cor0
----
-10256
-2994
-3889

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( col1 ) * 56 col2 FROM tab2 AS cor0
----
-1736
-3304
-952

query I rowsort
SELECT + col1 + - col1 * - col0 * col0 FROM tab0 AS cor0
----
118922
49622
720902

onlyif mysql # use DIV operator for integer division
query I rowsort label-2382
SELECT + col1 + 83 DIV col1 col2 FROM tab1
----
18
19
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2382
SELECT + col1 + 83 / col1 col2 FROM tab1
----
18
19
29

query I rowsort
SELECT - ( - col1 ) + + col0 + col1 AS col0 FROM tab2
----
113
196
69

query I rowsort
SELECT DISTINCT ( - col0 ) + - col0 AS col0 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT DISTINCT - col2 * - 56 + - col2 AS col2 FROM tab1
----
2970
3135
5280

query I rowsort
SELECT 47 * - col0 + - col2 * - col2 AS col0 FROM tab1 AS cor0
----
241
2775
5456

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - + cor0.col0 col0 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT - - 53 + + col1 * col0 FROM tab0 AS cor0
----
2117
3448
8152

onlyif mysql # use DIV operator for integer division
query I rowsort label-2389
SELECT DISTINCT + col1 DIV + 10 + - col0 + col0 col1 FROM tab1 AS cor0
----
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2389
SELECT DISTINCT + col1 / + 10 + - col0 + col0 col1 FROM tab1 AS cor0
----
1
2

query I rowsort
SELECT ALL + cor0.col1 - col2 * - 20 AS col2 FROM tab0 AS cor0
----
117
1731
746

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - 72 col1 FROM tab1 AS cor0
----
216
4608
5760

query I rowsort
SELECT col0 * - 20 AS col1 FROM tab1 AS cor0
----
-1280
-1600
-60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2393
SELECT ALL col0 + CAST( col1 + col0 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
138
173
32

skipif mysql # not compatible
query I rowsort label-2393
SELECT ALL col0 + CAST ( col1 + col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
138
173
32

query I rowsort
SELECT ALL + - 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-2395
SELECT + CAST( + ( - col0 ) AS SIGNED ) + col2 AS col2 FROM tab2 cor0
----
-41
-52
20

skipif mysql # not compatible
query I rowsort label-2395
SELECT + CAST ( + ( - col0 ) AS INTEGER ) + col2 AS col2 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT ALL + ( 81 ) FROM tab0, tab2 cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT ( 35 ) FROM tab1, tab1 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT ( - col2 ) + - cor0.col1 * col0 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT - 2 + - col0 * col1 AS col1 FROM tab1 AS cor0
----
-1042
-642
-80

query I rowsort
SELECT - 26 + + ( col0 ) * - 38 FROM tab0 AS cor0
----
-1356
-3408
-938

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2401
SELECT + + tab0.col1 + CAST( NULL AS SIGNED ) FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2401
SELECT + + tab0.col1 + CAST ( NULL AS INTEGER ) FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 42 + + col0 col2 FROM tab0 AS cor0
----
131
66
77

query I rowsort
SELECT DISTINCT + 43 * col0 AS col0 FROM tab1 cor0
----
129
2752
3440

query I rowsort
SELECT DISTINCT ( + 85 + col0 ) AS col2 FROM tab0
----
109
120
174

query I rowsort
SELECT ALL - - 91 * + col2 + ( + col1 ) FROM tab1 AS cor0
----
4940
5197
8749

query I rowsort
SELECT DISTINCT 80 * 54 FROM tab2
----
4320

query I rowsort
SELECT cor1.col0 - - 60 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 51a3d4876b425f1071c936c226417447

query I rowsort
SELECT - col0 * 85 * col1 + + col1 AS col1 FROM tab2 AS cor0
----
-114138
-18414
-391111

query I rowsort
SELECT DISTINCT cor1.col1 FROM tab2, tab0 AS cor0, tab1 AS cor1, tab1, tab2 AS cor2
----
10
13
26

query I rowsort
SELECT 84 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to e8cd683fe8cea77b4326d9b80f21c74a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2411
SELECT DISTINCT + col2 * CAST( + col1 AS SIGNED ) * - col2 FROM tab1
----
-119808
-32490
-75816

skipif mysql # not compatible
query I rowsort label-2411
SELECT DISTINCT + col2 * CAST ( + col1 AS INTEGER ) * - col2 FROM tab1
----
-119808
-32490
-75816

query I rowsort
SELECT + 44 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 80 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 4dde3bd5652d30396b9cadd0e2cfb680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - col0 col0 FROM tab2 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2415
SELECT col2 + - CAST( col0 AS SIGNED ) col2 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2415
SELECT col2 + - CAST ( col0 AS INTEGER ) col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT col0 + + tab1.col1 * col1 AS col0 FROM tab1
----
164
249
679

query I rowsort
SELECT + 1 AS col1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2418
SELECT ALL 77 * col1 + 53 DIV - 96 AS col1 FROM tab1 cor0
----
1001
2002
770

skipif mysql # not compatible
query I rowsort label-2418
SELECT ALL 77 * col1 + 53 / - 96 AS col1 FROM tab1 cor0
----
1001
2002
770

query I rowsort
SELECT DISTINCT + 2 + + col0 * - col2 + col0 * col0 FROM tab2 AS cor0
----
-138
3241
4058

onlyif mysql # use DIV operator for integer division
query I rowsort label-2420
SELECT DISTINCT cor0.col0 - col1 * ( - col2 ) DIV col1 FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-2420
SELECT DISTINCT cor0.col0 - col1 * ( - col2 ) / col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - 73 - + col2 FROM tab2 AS cor0
----
-100
-111
-99

query I rowsort
SELECT - col1 + 61 AS col0 FROM tab2 AS cor0
----
2
30
44

query I rowsort
SELECT DISTINCT - col2 + ( col1 + col2 ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - 26 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 47d0574274146de273829785364ada39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2425
SELECT - - CAST( col2 AS SIGNED ) * col1 FROM tab0 cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-2425
SELECT - - CAST ( col2 AS INTEGER ) * col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT + ( - col0 ) * col0 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT + 80 * - col0 + + col1 AS col2 FROM tab1 AS cor0
----
-214
-5110
-6387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + cor0.col1 * col2 col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + col2 * 62 FROM tab0
----
2046
5084
62

query I rowsort
SELECT DISTINCT cor1.col1 * + 0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2431
SELECT CAST( NULL AS SIGNED ) * col1 * + col0 + + 6 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2431
SELECT CAST ( NULL AS INTEGER ) * col1 * + col0 + + 6 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 84 * col0 * col1 FROM tab1 AS cor0
----
53760
6552
87360

onlyif mysql # use DIV operator for integer division
query I rowsort label-2433
SELECT + 72 + col0 DIV - col0 AS col1 FROM tab0 AS cor0
----
71
71
71

skipif mysql # not compatible
query I rowsort label-2433
SELECT + 72 + col0 / - col0 AS col1 FROM tab0 AS cor0
----
71
71
71

query I rowsort
SELECT - col1 + - col2 * cor0.col2 FROM tab0 cor0
----
-1175
-6815
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col1 col1 FROM tab2, tab0 cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

onlyif mysql # use DIV operator for integer division
query I rowsort label-2436
SELECT DISTINCT 59 + + col0 DIV 7 AS col0 FROM tab0 AS cor0
----
62
64
71

skipif mysql # not compatible
query I rowsort label-2436
SELECT DISTINCT 59 + + col0 / 7 AS col0 FROM tab0 AS cor0
----
62
64
71

query I rowsort
SELECT ALL col0 + + col1 * 46 AS col2 FROM tab2 AS cor0
----
1433
2792
861

query I rowsort
SELECT DISTINCT + 41 + + col0 FROM tab1 AS cor0
----
105
121
44

query I rowsort
SELECT DISTINCT - + col1 * - col2 + ( + col1 ) * col0 * + ( + col2 * cor0.col2 ) + - col1 * - 50 * + col1 FROM tab1 AS cor0
----
2084930
262652
9594338

query I rowsort
SELECT ALL ( - 45 ) + - col0 + col0 FROM tab1
----
-45
-45
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2441
SELECT tab1.col2 * 88 DIV col2 + ( - col0 ) AS col2 FROM tab1
----
24
8
85

skipif mysql # not compatible
query I rowsort label-2441
SELECT tab1.col2 * 88 / col2 + ( - col0 ) AS col2 FROM tab1
----
24
8
85

query I rowsort
SELECT 22 * - ( col1 ) + + 69 * + col2 FROM tab0
----
-2065
3656
385

query I rowsort
SELECT DISTINCT 26 + - col1 * + tab0.col2 AS col0 FROM tab0
----
-2812
-71
-7436

query I rowsort
SELECT - col0 - tab2.col1 * col2 AS col2 FROM tab2
----
-1612
-725
-844

query I rowsort
SELECT - 67 - col0 * tab1.col0 AS col1 FROM tab1
----
-4163
-6467
-76

query I rowsort
SELECT ALL - col1 * - col2 + - col0 + col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + col2 * + col1 * col2 + col2 AS col2 FROM tab1 AS cor0
----
119904
32547
75870

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2448
SELECT + col2 * cor0.col1 + CAST( col2 AS SIGNED ) * + cor0.col0 col2 FROM tab0 AS cor0
----
132
14760
3630

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2448
SELECT + col2 * cor0.col1 + CAST ( col2 AS INTEGER ) * + cor0.col0 col2 FROM tab0 AS cor0
----
132
14760
3630

query I rowsort
SELECT ALL col0 * - col0 + tab2.col1 * col0 * - col2 FROM tab2
----
-125736
-57275
-5908

onlyif mysql # use DIV operator for integer division
query I rowsort label-2450
SELECT DISTINCT + tab2.col2 DIV - tab2.col1 + + tab2.col1 + 31 AS col2 FROM tab2
----
46
62
90

skipif mysql # not compatible
query I rowsort label-2450
SELECT DISTINCT + tab2.col2 / - tab2.col1 + + tab2.col1 + 31 AS col2 FROM tab2
----
46
62
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2451
SELECT ALL - tab2.col2 * + col1 + col1 DIV + ( + col0 ) AS col0 FROM tab2
----
-1534
-646
-833

skipif mysql # not compatible
query I rowsort label-2451
SELECT ALL - tab2.col2 * + col1 + col1 / + ( + col0 ) AS col0 FROM tab2
----
-1534
-646
-833

query I rowsort
SELECT ALL + ( + col0 ) * - ( col0 ) * col1 AS col0 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT DISTINCT 10 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
10

query I rowsort
SELECT cor0.col0 + - col0 * col2 AS col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT ALL tab2.col0 - 10 FROM tab2
----
-3
68
69

query I rowsort
SELECT ALL col0 * - 71 - col0 AS col1 FROM tab2
----
-504
-5616
-5688

query I rowsort
SELECT 39 * - cor0.col2 FROM tab2 AS cor0
----
-1014
-1053
-1482

query I rowsort
SELECT col1 * 65 FROM tab1
----
1690
650
845

query I rowsort
SELECT DISTINCT - col1 + col2 * + 59 * col0 FROM tab2
----
11120
119593
177101

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + 90 * + col0 + col2 col0 FROM tab2
----
630
7020
7110

query I rowsort
SELECT DISTINCT + ( + col1 ) * cor0.col0 AS col1 FROM tab2 cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-2462
SELECT - 25 + - col1 DIV - col2 AS col2 FROM tab0 AS cor0
----
-23
-24
72

skipif mysql # not compatible
query I rowsort label-2462
SELECT - 25 + - col1 / - col2 AS col2 FROM tab0 AS cor0
----
-23
-24
72

query I rowsort
SELECT ALL col0 * col0 + - col2 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-140
3239
4056

query I rowsort
SELECT 71 + col0 * col1 FROM tab1 AS cor0
----
1111
149
711

query I rowsort
SELECT ALL + 51 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query IIIIIIIII rowsort
SELECT * FROM tab1, tab1 AS cor0 CROSS JOIN tab0 WHERE NULL <= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 25 * - col1 + cor0.col1 + ( col0 * col2 ) col2 FROM tab2 AS cor0
----
-555
2594
612

query I rowsort
SELECT - + ( - 75 ) * - col0 - col0 AS col1 FROM tab0 cor0
----
-1824
-2660
-6764

query I rowsort
SELECT + 72 * + col2 + col2 AS col0 FROM tab2 AS cor0
----
1898
1971
2774

query I rowsort
SELECT DISTINCT + col1 + - ( - cor0.col1 ) FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL + - col2 * - col1 * + col1 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT + + ( 26 ) + col2 FROM tab1 AS cor0
----
122
80
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2473
SELECT ALL col0 DIV 34 + cor0.col1 AS col0 FROM tab2 AS cor0
----
19
31
61

skipif mysql # not compatible
query I rowsort label-2473
SELECT ALL col0 / 34 + cor0.col1 AS col0 FROM tab2 AS cor0
----
19
31
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 11 * cor0.col0 col1 FROM tab1 AS cor0
----
-33
-704
-880

onlyif mysql # use DIV operator for integer division
query I rowsort label-2475
SELECT + ( + col1 ) + cor0.col1 DIV col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-2475
SELECT + ( + col1 ) + cor0.col1 / col1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT DISTINCT - - cor0.col1 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + - 82 * - ( - col1 ) * col1 FROM tab0 AS cor0
----
-606472
-679042
-771538

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2478
SELECT CAST( ( col0 ) AS SIGNED ) + - col1 * 20 AS col2 FROM tab2 AS cor0
----
-1102
-261
-613

skipif mysql # not compatible
query I rowsort label-2478
SELECT CAST ( ( col0 ) AS INTEGER ) + - col1 * 20 AS col2 FROM tab2 AS cor0
----
-1102
-261
-613

onlyif mysql # use DIV operator for integer division
query I rowsort label-2479
SELECT 51 DIV 18 FROM tab2 cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-2479
SELECT 51 / 18 FROM tab2 cor0
----
2
2
2

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT col1 < NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 - col2 * col1 col0 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT ALL col1 - - col1 FROM tab0 WHERE NOT ( col0 ) NOT IN ( + tab0.col0 + - col0 * + col2 )
----

query I rowsort
SELECT ALL - tab2.col1 + tab2.col1 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT col1 + col0 * - col1 AS col2 FROM tab0
----
-1978
-3298
-8008

query III rowsort
SELECT * FROM tab2 WHERE NULL BETWEEN - col1 / - tab2.col1 AND ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col1 col0 FROM tab0 WHERE - col0 * + col2 NOT IN ( col1 )
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-2487
SELECT col2 + col0 DIV + tab1.col0 + - col0 FROM tab1
----
-6
17
52

skipif mysql # not compatible
query I rowsort label-2487
SELECT col2 + col0 / + tab1.col0 + - col0 FROM tab1
----
-6
17
52

query I rowsort
SELECT ALL - col2 * - col0 + col1 FROM tab2
----
2087
220
3019

query I rowsort
SELECT - col2 AS col2 FROM tab1 WHERE NOT NULL BETWEEN NULL AND NULL
----

query I rowsort
SELECT + tab2.col2 + col2 * - col1 * + col0 AS col1 FROM tab2
----
-119626
-50996
-5832

query III rowsort
SELECT ALL * FROM tab1 WHERE ( NULL ) > NULL
----

query III rowsort
SELECT * FROM tab0 WHERE NOT ( col0 * - col2 ) NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL + col0 AS col2 FROM tab2 WHERE NOT ( col2 ) BETWEEN + col0 * - tab2.col0 AND NULL
----

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL <> - col1
----

query I rowsort
SELECT col0 * col0 + tab1.col1 AS col2 FROM tab1
----
35
4106
6413

query I rowsort
SELECT ALL tab2.col1 * + col1 + - col1 - - tab2.col0 FROM tab2
----
3500
351
937

onlyif mysql # use DIV operator for integer division
query I rowsort label-2497
SELECT + col2 * col1 DIV col2 - + col2 * col0 * + col1 AS col0 FROM tab0
----
-3298
-664027
-68026

skipif mysql # not compatible
query I rowsort label-2497
SELECT + col2 * col1 / col2 - + col2 * col0 * + col1 AS col0 FROM tab0
----
-3298
-664027
-68026

onlyif mysql # use DIV operator for integer division
query I rowsort label-2498
SELECT ALL + col1 DIV col1 + - col2 * + col0 * + col0 + col0 * + col2 FROM tab2
----
-1133
-156155
-234155

skipif mysql # not compatible
query I rowsort label-2498
SELECT ALL + col1 / col1 + - col2 * + col0 * + col0 + col0 * + col2 FROM tab2
----
-1133
-156155
-234155

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( col1 ) = col0 * - col2
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2500
SELECT ALL + col2 DIV col1 AS col1 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-2500
SELECT ALL + col2 / col1 AS col1 FROM tab2
----
0
0
2

query I rowsort
SELECT + col2 * col0 + col1 - col1 AS col2 FROM tab1
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2502
SELECT DISTINCT - tab1.col0 * col1 DIV - col0 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2502
SELECT DISTINCT - tab1.col0 * col1 / - col0 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL + col2 + + col0 + col1 AS col1 FROM tab1
----
131
189
83

query I rowsort
SELECT ALL - tab0.col1 AS col1 FROM tab0 WHERE NOT NULL BETWEEN - col1 * col2 + col2 AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col2 * - cor0.col0 col1 FROM tab1 cor0
----
-216
-3705
-7776

query I rowsort
SELECT ALL + cor0.col2 - cor0.col0 AS col1 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-2507
SELECT ALL + col0 DIV + col2 AS col0 FROM tab0 cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-2507
SELECT ALL + col0 / + col2 AS col0 FROM tab0 cor0
----
0
1
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - col2 * cor0.col0 col1 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT - + col1 + - col0 * - col1 FROM tab0 AS cor0
----
1978
3298
8008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + col1 * col1 col2 FROM tab1 cor0
----
36
673
89

query I rowsort
SELECT DISTINCT + col2 - cor0.col0 AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT col2 * col2 + + col1 * col0 AS col1 FROM tab1 AS cor0
----
10256
2994
3889

onlyif mysql # use DIV operator for integer division
query I rowsort label-2513
SELECT DISTINCT - - col1 * + col0 * col1 + + col0 DIV col1 AS col1 FROM tab0 AS cor0
----
177504
329315
737009

skipif mysql # not compatible
query I rowsort label-2513
SELECT DISTINCT - - col1 * + col0 * col1 + + col0 / col1 AS col1 FROM tab0 AS cor0
----
177504
329315
737009

query III rowsort
SELECT DISTINCT * FROM tab0 cor0 WHERE NOT cor0.col1 BETWEEN NULL AND NULL
----

query I rowsort
SELECT + col2 * + col2 * + cor0.col0 AS col0 FROM tab0 cor0 WHERE NOT col2 + - col0 * cor0.col2 > NULL
----

query I rowsort
SELECT + col2 + col1 FROM tab2 AS cor0 WHERE - col1 >= + col2 + + col2 + - col1
----

query I rowsort
SELECT DISTINCT + - 20 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
-20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2518
SELECT - + cor0.col0 * - CAST( NULL AS DECIMAL ) * + col1 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2518
SELECT - + cor0.col0 * - CAST ( NULL AS REAL ) * + col1 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col0 * ( - col1 ) + col0 FROM tab0 cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL - ( col0 ) + cor0.col0 * 85 * cor0.col2 FROM tab1 AS cor0
----
13767
310016
652720

query I rowsort
SELECT DISTINCT - + col2 * 28 + - col2 FROM tab1 AS cor0
----
-1566
-1653
-2784

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 74 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

query I rowsort
SELECT cor0.col0 * + col2 + + cor0.col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT + - ( + cor0.col0 ) + col1 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query III rowsort
SELECT * FROM tab0 WHERE NULL > ( col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2526
SELECT - col2 DIV col1 - col0 * + col2 * col0 FROM tab1
----
-233477
-488
-614407

skipif mysql # not compatible
query I rowsort label-2526
SELECT - col2 / col1 - col0 * + col2 * col0 FROM tab1
----
-233477
-488
-614407

query I rowsort
SELECT ALL col0 - - col2 * - tab2.col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT - tab0.col2 * - col0 * tab0.col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT - - col2 + - 14 AS col0 FROM tab0 AS cor0
----
-13
19
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-2530
SELECT DISTINCT col2 DIV + col2 - col0 * col0 FROM tab1 AS cor0
----
-4095
-6399
-8

skipif mysql # not compatible
query I rowsort label-2530
SELECT DISTINCT col2 / + col2 - col0 * col0 FROM tab1 AS cor0
----
-4095
-6399
-8

query I rowsort
SELECT ALL - col0 + 32 AS col2 FROM tab2
----
-46
-47
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 47 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + 82 col0 FROM tab1 AS cor0
----
108
92
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2534
SELECT col1 DIV col2 + + col1 + col2 AS col1 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-2534
SELECT col1 / col2 + + col1 + col2 AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT col1 * - col2 + - col1 * + col0 FROM tab1
----
-1210
-1482
-2288

onlyif mysql # use DIV operator for integer division
query I rowsort label-2536
SELECT DISTINCT + + col2 + + col2 DIV col0 FROM tab2 cor0
----
26
30
38

skipif mysql # not compatible
query I rowsort label-2536
SELECT DISTINCT + + col2 + + col2 / col0 FROM tab2 cor0
----
26
30
38

query I rowsort
SELECT + - 47 * col1 * - col2 FROM tab1 AS cor0
----
26790
58656
65988

query I rowsort
SELECT ALL + col1 + + col1 + col0 * col2 FROM tab2 AS cor0
----
2146
251
3036

query I rowsort
SELECT DISTINCT + 49 FROM tab1 cor0
----
49

query I rowsort
SELECT + - ( cor0.col1 ) * + col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL 53 + + 4 FROM tab0 AS cor0
----
57
57
57

query I rowsort
SELECT DISTINCT - 49 + - col1 FROM tab2
----
-108
-66
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2543
SELECT ALL + 17 DIV tab0.col1 AS col2 FROM tab0, tab2, tab2 cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-2543
SELECT ALL + 17 / tab0.col1 AS col2 FROM tab0, tab2, tab2 cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT ALL tab2.col2 - tab2.col2 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT - 35 - + col1 FROM tab0
----
-121
-126
-132

query I rowsort
SELECT 75 * - col2 FROM tab1
----
-4050
-4275
-7200

query I rowsort
SELECT ALL - 65 * + 33 FROM tab0, tab1 AS cor0
----
9 values hashing to cf1fec7f72b4a4c298dddf34b3c50ec3

query I rowsort
SELECT DISTINCT 31 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
31

query I rowsort
SELECT + col0 * col2 * - ( - col1 ) + + col0 * - col0 AS col0 FROM tab1 AS cor0
----
32384
4203
93440

query I rowsort
SELECT DISTINCT + col0 * 2 + 75 AS col0 FROM tab1 AS cor0
----
203
235
81

query I rowsort
SELECT ALL cor0.col2 * ( + 89 ) FROM tab2 AS cor0
----
2314
2403
3382

query I rowsort
SELECT - col1 + + ( 83 ) AS col0 FROM tab1 AS cor0
----
57
70
73

query I rowsort
SELECT DISTINCT - + col0 + col1 + col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - col2 + - 38 + col1 FROM tab1 cor0
----
-121
-66
-85

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col2 * - CAST ( col2 AS REAL ) + - col0 FROM tab1 AS cor0
----
-2919
-3313
-9296

query I rowsort
SELECT + col0 + cor0.col2 * - col2 * col0 FROM tab1 AS cor0
----
-207872
-737200
-8745

query I rowsort
SELECT ALL - col2 * + col0 + + 82 * cor0.col0 + col1 FROM tab1 AS cor0
----
-1107
110
1610

query I rowsort
SELECT ALL 7 - - col0 * 91 * - col2 AS col2 FROM tab2
----
-17192
-184541
-273175

query I rowsort
SELECT DISTINCT - cor0.col1 * - 44 + - col2 AS col2 FROM tab0 AS cor0
----
3751
3922
4267

query I rowsort
SELECT col0 + col0 * + ( - col2 ) AS col2 FROM tab1 AS cor0
----
-159
-3584
-7600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2561
SELECT ALL + cor0.col1 + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2561
SELECT ALL + cor0.col1 + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col0 * + cor0.col0 + col0 FROM tab0 AS cor0
----
1260
600
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * col0 + col2 * + col0 * col1 col2 FROM tab0 AS cor0
----
3360
656820
67320

onlyif mysql # use DIV operator for integer division
query I rowsort label-2564
SELECT DISTINCT col0 * col2 DIV + col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-2564
SELECT DISTINCT col0 * col2 / + col0 FROM tab2 AS cor0
----
26
27
38

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE NOT ( NULL ) <> col0 OR - col2 IN ( - col2 + col1 )
----

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 IIIIIIIII rowsort
SELECT * FROM tab1, tab2, tab1 cor0 WHERE NOT NULL < NULL
----

query I rowsort
SELECT DISTINCT + col0 * tab2.col1 + col0 AS col2 FROM tab2
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col1 + col1 * col1 * - col0 col0 FROM tab1
----
-13507
-2002
-6390

query I rowsort
SELECT - + col1 + + col1 * col2 FROM tab1 AS cor0
----
1235
1378
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-2571
SELECT + col2 * col0 + col0 DIV tab1.col1 col0 FROM tab1
----
162
3654
7686

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2571
SELECT + col2 * col0 + col0 / tab1.col1 col0 FROM tab1
----
162
3654
7686

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - col2 col0 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2573
SELECT - col0 * tab0.col1 DIV - col2 + col0 AS col2 FROM tab0
----
187
3430
86

skipif mysql # not compatible
query I rowsort label-2573
SELECT - col0 * tab0.col1 / - col2 + col0 AS col2 FROM tab0
----
187
3430
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-2574
SELECT col0 DIV tab1.col2 + - col0 * tab1.col1 DIV tab1.col2 FROM tab1
----
-1
-10
-10

skipif mysql # not compatible
query I rowsort label-2574
SELECT col0 / tab1.col2 + - col0 * tab1.col1 / tab1.col2 FROM tab1
----
-1
-10
-10

query I rowsort
SELECT DISTINCT + col1 * - col1 + - col2 FROM tab1
----
-157
-265
-730

query I rowsort
SELECT DISTINCT col1 + - col2 * + col1 + - col1 * + col0 FROM tab2
----
-1023
-1972
-6077

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * - col1 col2 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 77 + cor0.col1 * + col2 * col2 col2 FROM tab1 AS cor0
----
119885
32567
75893

query I rowsort
SELECT + + col2 * cor0.col2 * + col1 AS col1 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT ALL + + cor0.col2 * cor0.col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT cor0.col1 + - col1 * - col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT DISTINCT + col2 * cor0.col1 + + cor0.col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT - 29 AS col1 FROM tab0
----
-29
-29
-29

onlyif mysql # use DIV operator for integer division
query I rowsort label-2584
SELECT - CAST( + col2 AS SIGNED ) DIV col0 + col0 FROM tab0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-2584
SELECT - CAST ( + col2 AS INTEGER ) / col0 + col0 FROM tab0
----
23
35
89

query I rowsort
SELECT 47 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * ( col1 * - col0 ) col1 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT 61 + ( - col2 ) * + col1 AS col0 FROM tab0
----
-2777
-36
-7401

query I rowsort
SELECT ALL ( tab0.col1 ) + col0 AS col1 FROM tab0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-2589
SELECT + 55 DIV col0 AS col0 FROM tab2
----
0
0
7

skipif mysql # not compatible
query I rowsort label-2589
SELECT + 55 / col0 AS col0 FROM tab2
----
0
0
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2590
SELECT cor0.col1 + col2 DIV + col0 AS col0 FROM tab2 AS cor0
----
17
34
59

skipif mysql # not compatible
query I rowsort label-2590
SELECT cor0.col1 + col2 / + col0 AS col0 FROM tab2 AS cor0
----
17
34
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-2591
SELECT + ( - col2 ) DIV cor0.col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2591
SELECT + ( - col2 ) / cor0.col0 FROM tab0 AS cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2592
SELECT ALL - + 51 DIV col0 FROM tab0 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-2592
SELECT ALL - + 51 / col0 FROM tab0 AS cor0
----
-1
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col2 col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT - cor0.col1 + - col0 * 58 AS col1 FROM tab0 AS cor0
----
-1478
-2127
-5253

query I rowsort
SELECT DISTINCT - cor2.col1 FROM tab0, tab0 AS cor0, tab2 AS cor1, tab2, tab0 AS cor2
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * + cor0.col2 col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - col2 * 68 FROM tab0 cor0
----
-2244
-5576
-68

query I rowsort
SELECT + tab0.col0 - - cor0.col0 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 218174566e316faf7def1869e4f9f1b6

query I rowsort
SELECT - - col2 + 21 * - cor0.col1 FROM tab2 AS cor0
----
-1213
-319
-624

query I rowsort
SELECT + col1 + - col0 + col1 AS col2 FROM tab0
----
148
159
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2601
SELECT col2 + CAST( NULL AS SIGNED ) * col1 col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2601
SELECT col2 + CAST ( NULL AS INTEGER ) * col1 col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * - 13 AS col2 FROM tab0
----
-1066
-13
-429

query I rowsort
SELECT - ( 27 ) + + col2 AS col1 FROM tab1 cor0
----
27
30
69

query I rowsort
SELECT DISTINCT + ( tab1.col2 ) FROM tab1, tab0 cor0
----
54
57
96

query I rowsort
SELECT DISTINCT col2 + + col1 + col2 FROM tab0
----
152
255
99

query I rowsort
SELECT DISTINCT - col2 + + 34 AS col1 FROM tab1
----
-20
-23
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( 40 ) col1 FROM tab1
----
40
40
40

query I rowsort
SELECT ALL 44 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT - ( 95 ) * - col0 FROM tab0 AS cor0
----
2280
3325
8455

query I rowsort
SELECT col2 + 63 AS col0 FROM tab2 cor0
----
101
89
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2611
SELECT + cor0.col0 + col0 DIV col0 AS col1 FROM tab1 cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-2611
SELECT + cor0.col0 + col0 / col0 AS col1 FROM tab1 cor0
----
4
65
81

query I rowsort
SELECT ALL + 45 FROM tab0, tab2 cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT DISTINCT col0 + + cor0.col0 * col2 * col0 FROM tab0 cor0
----
1260
19032
649611

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 84 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 975e2ef2a3bf1ee2622362f4e435752f

query I rowsort
SELECT + col1 + col0 * - col2 * 35 FROM tab2 cor0
----
-105053
-6584
-70921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - col1 col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL - 13 * - col2 * 89 AS col1 FROM tab0 AS cor0
----
1157
38181
94874

query I rowsort
SELECT ( ( tab1.col0 ) ) * - col0 + 28 AS col2 FROM tab1
----
-4068
-6372
19

query I rowsort
SELECT DISTINCT col0 * col0 - - tab1.col2 FROM tab1
----
4153
63
6496

onlyif mysql # use DIV operator for integer division
query I rowsort label-2620
SELECT ALL col2 DIV + col1 + - col0 FROM tab2
----
-7
-77
-78

skipif mysql # not compatible
query I rowsort label-2620
SELECT ALL col2 / + col1 + - col0 FROM tab2
----
-7
-77
-78

query I rowsort
SELECT ALL - 44 * - cor0.col0 - - 16 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 5031d9b5c4414e51c0b4528fdaf80342

query I rowsort
SELECT - col0 * + 23 AS col2 FROM tab2
----
-161
-1794
-1817

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2623
SELECT - col0 + col0 + CAST( col0 + - col1 AS SIGNED ) col2 FROM tab0 AS cor0
----
-2
-62
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2623
SELECT - col0 + col0 + CAST ( col0 + - col1 AS INTEGER ) col2 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT + 57 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

query I rowsort
SELECT + 80 * + cor0.col1 FROM tab1 cor0
----
1040
2080
800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2626
SELECT DISTINCT + 9 + col2 * + CAST( NULL AS SIGNED ) col0 FROM tab0 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2626
SELECT DISTINCT + 9 + col2 * + CAST ( NULL AS INTEGER ) col0 FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL - 10 * + col0 FROM tab0 AS cor0
----
-240
-350
-890

query I rowsort
SELECT 22 * + col2 * - 34 + col1 AS col0 FROM tab2 cor0
----
-19389
-20165
-28407

onlyif mysql # use DIV operator for integer division
query I rowsort label-2629
SELECT cor0.col1 DIV + col0 + cor0.col2 FROM tab0 AS cor0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-2629
SELECT cor0.col1 / + col0 + cor0.col2 FROM tab0 AS cor0
----
3
36
83

query I rowsort
SELECT DISTINCT - - col1 * col1 + - cor0.col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT - 29 + col1 * col2 FROM tab0 cor0
----
2809
68
7433

onlyif mysql # use DIV operator for integer division
query I rowsort label-2632
SELECT + 99 DIV + col1 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2632
SELECT + 99 / + col1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL + col1 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT - + 55 * col0 FROM tab0 AS cor0
----
-1320
-1925
-4895

query I rowsort
SELECT ALL - 6 + cor0.col2 AS col0 FROM tab1 AS cor0
----
48
51
90

query I rowsort
SELECT col2 * + 56 * col1 + col2 AS col0 FROM tab0
----
158961
417954
5433

query I rowsort
SELECT + col1 * cor0.col1 * col0 AS col0 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT col0 + 91 AS col2 FROM tab1 AS cor0
----
155
171
94

query I rowsort
SELECT + ( 46 ) + + col2 * + 45 AS col2 FROM tab0 AS cor0
----
1531
3736
91

query I rowsort
SELECT 77 + col0 AS col1 FROM tab2 AS cor0
----
155
156
84

query I rowsort
SELECT col1 * + col2 + - col2 * 36 AS col0 FROM tab0 AS cor0
----
1650
4510
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + 13 col1 FROM tab1 AS cor0
----
109
67
70

query I rowsort
SELECT ALL col0 + - col2 * col2 AS col0 FROM tab0 AS cor0
----
-1065
-6635
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2644
SELECT ALL + col1 * + 31 - 34 DIV - col1 AS col2 FROM tab0 AS cor0
----
2666
2821
3007

skipif mysql # not compatible
query I rowsort label-2644
SELECT ALL + col1 * + 31 - 34 / - col1 AS col2 FROM tab0 AS cor0
----
2666
2821
3007

query I rowsort
SELECT ALL + col2 + 10 AS col0 FROM tab1 AS cor0
----
106
64
67

query I rowsort
SELECT + col2 * 41 - - ( col1 + 88 ) FROM tab0 AS cor0
----
1527
226
3541

query I rowsort
SELECT ALL + - cor0.col1 * - ( col1 ) * col0 FROM tab2 cor0
----
22831
271518
6727

query I rowsort
SELECT - col0 + - col2 + 32 FROM tab1 cor0
----
-144
-25
-89

query I rowsort
SELECT ALL col2 + ( cor0.col2 ) FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT + - cor0.col0 * 9 + + col2 AS col1 FROM tab2 AS cor0
----
-36
-673
-676

query I rowsort
SELECT DISTINCT - cor0.col1 * + 93 + - cor0.col2 * - col0 * - ( + col2 + col1 ) FROM tab0 AS cor0
----
-102246
-12451
-1271017

query I rowsort
SELECT DISTINCT - - col2 * + col1 + 94 * + col0 FROM tab1 AS cor0
----
1686
6586
8768

query I rowsort
SELECT ALL - col2 + ( + col0 ) - col1 FROM tab1 cor0
----
-29
-3
-77

query I rowsort
SELECT ALL col1 + - col2 * - col2 - - 70 FROM tab1
----
3012
3329
9299

query I rowsort
SELECT - col0 * + 25 + 15 AS col2 FROM tab0 AS cor0
----
-2210
-585
-860

query I rowsort
SELECT + 5 * - col1 AS col2 FROM tab1
----
-130
-50
-65

query I rowsort
SELECT ALL col0 * col1 * col0 + col0 FROM tab1
----
237
41024
83280

query I rowsort
SELECT - - col2 * + 18 FROM tab0 AS cor0
----
1476
18
594

onlyif mysql # use DIV operator for integer division
query I rowsort label-2659
SELECT ALL - col2 DIV + cor0.col0 AS col1 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-2659
SELECT ALL - col2 / + cor0.col0 AS col1 FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT + 20 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

onlyif mysql # use DIV operator for integer division
query I rowsort label-2661
SELECT DISTINCT cor0.col2 DIV col0 AS col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-2661
SELECT DISTINCT cor0.col2 / col0 AS col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT - - col2 + - col0 * + 60 AS col0 FROM tab0 cor0
----
-1407
-2099
-5258

query I rowsort
SELECT + col2 * col1 + 46 * col1 + + col2 FROM tab2
----
1466
2290
4274

query I rowsort
SELECT - - col0 + col1 - cor0.col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT 90 + - col0 AS col0 FROM tab1
----
10
26
87

query I rowsort
SELECT 79 + + col1 * - 65 * - col1 FROM tab2 AS cor0
----
18864
226344
62544

query I rowsort
SELECT - - cor0.col2 * col0 + - col2 * col2 + + col0 AS col1 FROM tab0 AS cor0
----
-273
663
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - col1 ) + + col2 * 54 col0 FROM tab0 cor0
----
-43
1696
4337

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor1.col1 + 80 col0 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 27b34094c0a295f5e17e3f6d990e5a4a

query I rowsort
SELECT - 5 * + col1 FROM tab2
----
-155
-295
-85

query I rowsort
SELECT DISTINCT - 64 * - col0 + 14 AS col2 FROM tab2 AS cor0
----
462
5006
5070

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2672
SELECT ALL + + col2 + col0 * - CAST( - col1 AS SIGNED ) + col0 AS col0 FROM tab2 AS cor0
----
1460
251
4706

skipif mysql # not compatible
query I rowsort label-2672
SELECT ALL + + col2 + col0 * - CAST ( - col1 AS INTEGER ) + col0 AS col0 FROM tab2 AS cor0
----
1460
251
4706

query I rowsort
SELECT ALL + + 72 AS col0 FROM tab0 cor0
----
72
72
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-2674
SELECT col1 DIV ( 31 * + col1 ) AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2674
SELECT col1 / ( 31 * + col1 ) AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL col0 * ( col1 * col0 ) AS col2 FROM tab0
----
118825
49536
720811

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2676
SELECT + + col0 * + CAST( NULL AS DECIMAL ) + - 55 * col0 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2676
SELECT + + col0 * + CAST ( NULL AS REAL ) + - 55 * col0 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + - 63 FROM tab2 AS cor0
----
-32
-4
-46

query I rowsort
SELECT - col1 + - 13 * 56 AS col2 FROM tab0 AS cor0
----
-814
-819
-825

query I rowsort
SELECT - col1 * ( + col2 ) AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - + 14 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to d321461994ba49c3a70fa6373032fc94

query I rowsort
SELECT ALL - + col1 + ( - col0 ) AS col1 FROM tab1 AS cor0
----
-29
-74
-93

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0, tab1 AS cor1, tab1, tab2 cor2
----
3645 values hashing to 4406ccc71f02ae9c1e947ffcd89b0db7

query I rowsort
SELECT ALL - + ( cor0.col2 ) * col1 - - 93 AS col1 FROM tab1 AS cor0
----
-1155
-1311
-477

query I rowsort
SELECT ALL 50 * - col2 FROM tab2 AS cor0
----
-1300
-1350
-1900

query I rowsort
SELECT DISTINCT + ( + col0 ) - - cor0.col2 * + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT + col1 * ( col1 ) + 16 FROM tab1 cor0
----
116
185
692

query I rowsort
SELECT ALL col1 * - col1 * - col0 + - ( col1 ) * + col0 FROM tab2 AS cor0
----
21488
266916
6510

query I rowsort
SELECT DISTINCT - 48 + + col0 FROM tab1 AS cor0
----
-45
16
32

query I rowsort
SELECT DISTINCT col1 * ( + col2 ) - ( 53 * - col0 ) FROM tab1 AS cor0
----
1563
3962
5488

query I rowsort
SELECT - - 1 * - 50 FROM tab1 AS cor0
----
-50
-50
-50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2691
SELECT - + 48 * col1 / - CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2691
SELECT - + 48 * col1 / - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col2 * - col0 + - 36 AS col0 FROM tab2 cor0
----
153
1992
2966

query I rowsort
SELECT DISTINCT + + col0 * + col0 + + col2 + 50 * col1 AS col1 FROM tab2 AS cor0
----
1626
7129
9060

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 29 + col1 * - 72 col1 FROM tab2 AS cor0
----
-1195
-2203
-4219

onlyif mysql # use DIV operator for integer division
query I rowsort label-2695
SELECT DISTINCT + col1 + col0 DIV - cor0.col1 AS col0 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2695
SELECT DISTINCT + col1 + col0 / - cor0.col1 AS col0 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT ALL - ( col2 ) * - col2 - - ( + col1 ) FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT ALL + col1 * + cor0.col2 * 64 FROM tab0 AS cor0
----
181632
477568
6208

onlyif mysql # use DIV operator for integer division
query I rowsort label-2698
SELECT DISTINCT - ( col2 ) DIV - 59 FROM tab1 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-2698
SELECT DISTINCT - ( col2 ) / - 59 FROM tab1 cor0
----
0
1

query I rowsort
SELECT ALL + ( col0 * - col0 ) AS col2 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT + + 75 FROM tab2 cor0
----
75
75
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 64 col2 FROM tab1
----
192
4096
5120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2702
SELECT ALL - col2 * col2 + col2 * col1 * CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
1296
33231
90624

skipif mysql # not compatible
query I rowsort label-2702
SELECT ALL - col2 * col2 + col2 * col1 * CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
1296
33231
90624

query I rowsort
SELECT + 88 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

query I rowsort
SELECT col2 * col0 + ( + col2 ) FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT - + 4 AS col0 FROM tab1 AS cor0
----
-4
-4
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( 30 ) + + col1 col0 FROM tab2 AS cor0
----
47
61
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2707
SELECT - col2 + col0 DIV + col0 AS col1 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-2707
SELECT - col2 + col0 / + col0 AS col1 FROM tab1 AS cor0
----
-53
-56
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 25 + - 15 col0 FROM tab1 AS cor0
----
10
10
10

query I rowsort
SELECT 87 - + col0 AS col2 FROM tab0 AS cor0
----
-2
52
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 57 * + col0 - 57 col1 FROM tab1 AS cor0
----
-228
-3705
-4617

query I rowsort
SELECT ALL + + 54 * col2 AS col2 FROM tab1 AS cor0
----
2916
3078
5184

query I rowsort
SELECT DISTINCT - col1 + + col1 * + cor0.col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT ALL - 12 - - col0 FROM tab2 cor0
----
-5
66
67

query I rowsort
SELECT col0 + + col2 + + col2 AS col0 FROM tab0
----
253
37
90

query I rowsort
SELECT - 21 FROM tab0, tab0 cor0
----
9 values hashing to 631fbd1fd929405aba54a22c2a06c757

query I rowsort
SELECT DISTINCT 68 * 54 FROM tab2
----
3672

query I rowsort
SELECT DISTINCT 56 AS col1 FROM tab1, tab1 cor0
----
56

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2718
SELECT + 33 * + col2 + - CAST( NULL AS DECIMAL ) * col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2718
SELECT + 33 * + col2 + - CAST ( NULL AS REAL ) * col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - ( + col1 ) * col2 - - cor0.col2 AS col1 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2720
SELECT + 69 DIV col1 FROM tab1
----
2
5
6

skipif mysql # not compatible
query I rowsort label-2720
SELECT + 69 / col1 FROM tab1
----
2
5
6

query I rowsort
SELECT 52 * 13 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 7b31cda57598da9267befbfd4fca9b1b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * 64 col1 FROM tab2 AS cor0
----
-1664
-1728
-2432

query I rowsort
SELECT - col0 * - cor0.col2 + 6 FROM tab0 AS cor0
----
41
7304
798

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2724
SELECT ALL - col1 * - CAST( - 0 AS SIGNED ) + - col2 FROM tab2 cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-2724
SELECT ALL - col1 * - CAST ( - 0 AS INTEGER ) + - col2 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT + col2 + - col2 * - 70 - col1 AS col2 FROM tab0 cor0
----
-26
2257
5731

query I rowsort
SELECT - + col2 + - 52 AS col2 FROM tab0 AS cor0
----
-134
-53
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + col2 * 74 col0 FROM tab0 AS cor0
----
109
2466
6157

query I rowsort
SELECT DISTINCT - tab1.col0 AS col1 FROM tab1, tab0, tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2729
SELECT ALL - col0 - + CAST( - col0 + col0 AS SIGNED ) DIV col0 AS col2 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-2729
SELECT ALL - col0 - + CAST ( - col0 + col0 AS INTEGER ) / col0 AS col2 FROM tab0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2730
SELECT tab0.col2 * CAST( NULL AS SIGNED ) * - ( - col0 ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2730
SELECT tab0.col2 * CAST ( NULL AS INTEGER ) * - ( - col0 ) AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 70 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT - - col2 + - col1 * - col2 AS col2 FROM tab0 cor0
----
2871
7544
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2733
SELECT - col2 + - CAST( NULL AS SIGNED ) + col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2733
SELECT - col2 + - CAST ( NULL AS INTEGER ) + col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 + 95 FROM tab2
----
36
64
78

query I rowsort
SELECT + col2 + + col2 * cor0.col0 + col0 FROM tab2 AS cor0
----
2132
223
3119

query I rowsort
SELECT + cor0.col0 AS col2 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT - col1 + 61 * col1 FROM tab2 AS cor0
----
1020
1860
3540

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab0 cor1, tab2, tab1 cor2
----
3645 values hashing to 7ccb6e2515d95809a8c30b73a5cf5f46

query I rowsort
SELECT ALL - col2 * col1 * - col2 AS col2 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT ALL + col2 * col0 + col2 AS col0 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT ALL - col1 * + col2 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + - 30 - + 5 * col1 FROM tab0 AS cor0
----
-460
-485
-515

query I rowsort
SELECT col2 + + 36 AS col0 FROM tab1 AS cor0
----
132
90
93

query I rowsort
SELECT DISTINCT - - ( + col0 ) * - col2 + + ( col0 ) FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT DISTINCT col1 + - col1 * - col2 FROM tab1 AS cor0
----
1261
1430
580

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2746
SELECT - - CAST( + col2 AS SIGNED ) + - col2 * 17 FROM tab0 AS cor0
----
-1312
-16
-528

skipif mysql # not compatible
query I rowsort label-2746
SELECT - - CAST ( + col2 AS INTEGER ) + - col2 * 17 FROM tab0 AS cor0
----
-1312
-16
-528

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 80 * - col0 col2 FROM tab1 AS cor0
----
240
5120
6400

query I rowsort
SELECT DISTINCT - 50 * cor0.col2 FROM tab0 AS cor0
----
-1650
-4100
-50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2749
SELECT DISTINCT - ( col2 ) + col2 * CAST( + col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
1152
1350
513

skipif mysql # not compatible
query I rowsort label-2749
SELECT DISTINCT - ( col2 ) + col2 * CAST ( + col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT 3 + - col2 * col0 FROM tab0 AS cor0
----
-32
-7295
-789

query I rowsort
SELECT ALL 49 * - 56 FROM tab0 AS cor0
----
-2744
-2744
-2744

query I rowsort
SELECT DISTINCT ( col2 ) * - col2 * ( + 66 ) FROM tab0 AS cor0
----
-443784
-66
-71874

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2753
SELECT ALL - CAST( NULL AS SIGNED ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2753
SELECT ALL - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2754
SELECT - - 83 DIV - col0 - - col0 * 35 FROM tab0 AS cor0
----
1223
3115
837

skipif mysql # not compatible
query I rowsort label-2754
SELECT - - 83 / - col0 - - col0 * 35 FROM tab0 AS cor0
----
1223
3115
837

query I rowsort
SELECT DISTINCT + col2 * - 81 AS col1 FROM tab0 AS cor0
----
-2673
-6642
-81

query I rowsort
SELECT DISTINCT col2 * + col1 * cor0.col2 + - 66 FROM tab2 AS cor0
----
22533
24482
39818

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2757
SELECT ALL - - col2 * ( col2 ) - + CAST( NULL AS SIGNED ) * col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2757
SELECT ALL - - col2 * ( col2 ) - + CAST ( NULL AS INTEGER ) * col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 49 + col0 FROM tab2 AS cor0
----
-42
29
30

query I rowsort
SELECT DISTINCT col2 * + col2 * col1 + + col1 * + col1 * + col1 FROM tab1 AS cor0
----
122005
33490
93392

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2760
SELECT col2 * + 22 + tab2.col2 + + CAST( NULL AS SIGNED ) / + col2 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2760
SELECT col2 * + 22 + tab2.col2 + + CAST ( NULL AS INTEGER ) / + col2 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 - - col0 AS col0 FROM tab0 AS cor0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - col1 col1 FROM tab1
----
28
47
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-2763
SELECT + 77 * + col0 + col2 * col2 - col2 DIV col1 AS col2 FROM tab2
----
1268
6682
7525

skipif mysql # not compatible
query I rowsort label-2763
SELECT + 77 * + col0 + col2 * col2 - col2 / col1 AS col2 FROM tab2
----
1268
6682
7525

onlyif mysql # use DIV operator for integer division
query I rowsort label-2764
SELECT DISTINCT - col1 * 1 DIV + col0 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-2764
SELECT DISTINCT - col1 * 1 / + col0 FROM tab0 AS cor0
----
-1
-2
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-2765
SELECT - col1 DIV 64 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2765
SELECT - col1 / 64 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 * + 19 * cor0.col0 - cor0.col0 * col0 * cor0.col1 AS col2 FROM tab0 AS cor0
----
-38592
-570312
-95550

query I rowsort
SELECT + 78 AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT col0 - + tab0.col1 AS col1 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT ALL col0 * tab0.col2 * - col2 FROM tab0
----
-26136
-35
-598436

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 43 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + + col2 * + 29 col0 FROM tab1 AS cor0
----
1620
1710
2880

query I rowsort
SELECT ALL - col0 + - ( - col1 ) AS col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT col2 * + col0 + - col0 AS col1 FROM tab1
----
159
3584
7600

query I rowsort
SELECT ALL - tab0.col0 * - 49 FROM tab0
----
1176
1715
4361

query I rowsort
SELECT - tab0.col0 AS col2 FROM tab0, tab1, tab0 AS cor0, tab2
----
81 values hashing to 26e45cd9fe71a2b90a8bdef20c88e70d

query I rowsort
SELECT DISTINCT - cor1.col2 AS col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
-54
-57
-96

query I rowsort
SELECT + + ( - col1 ) * + col2 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + col2 + - col0 * + 63 FROM tab2
----
-414
-4888
-4939

query I rowsort
SELECT DISTINCT - ( col2 * - col0 ) FROM tab0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-2780
SELECT DISTINCT col1 DIV ( - col2 ) FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-2780
SELECT DISTINCT col1 / ( - col2 ) FROM tab1
----
0

query I rowsort
SELECT ALL - ( - col0 ) * + col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - 21 + ( + col2 ) * ( ( + col2 ) ) AS col1 FROM tab1 AS cor0
----
2895
3228
9195

query I rowsort
SELECT DISTINCT col0 * + col1 + + col2 AS col1 FROM tab0 AS cor0
----
2097
3396
8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-2784
SELECT - 31 DIV - 73 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2784
SELECT - 31 / - 73 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - + col0 * 2 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT DISTINCT - col2 * 37 AS col0 FROM tab0 AS cor0
----
-1221
-3034
-37

query I rowsort
SELECT DISTINCT - ( + cor0.col1 ) AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL 8 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 33069adc3c1142d31511ec88fcfa40af

query I rowsort
SELECT ALL + col1 * tab1.col2 + ( + 6 ) AS col0 FROM tab1
----
1254
1410
576

query I rowsort
SELECT DISTINCT 26 + col2 * col1 AS col2 FROM tab1
----
1274
1430
596

query I rowsort
SELECT col0 * col2 + ( - col1 ) * col0 AS col2 FROM tab2
----
-2574
-28
1659

onlyif mysql # use DIV operator for integer division
query I rowsort label-2792
SELECT DISTINCT col0 DIV col0 + col1 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-2792
SELECT DISTINCT col0 / col0 + col1 FROM tab0
----
87
92
98

query I rowsort
SELECT DISTINCT + 89 + col0 + col1 AS col1 FROM tab0
----
199
221
269

query I rowsort
SELECT 32 + col2 AS col2 FROM tab2
----
58
59
70

query I rowsort
SELECT ALL - col1 * + col1 + + col2 AS col0 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT - col2 * col0 + ( - 73 + col0 ) * - col1 FROM tab1 AS cor0
----
-3558
-7771
1658

query I rowsort
SELECT DISTINCT + 77 * col2 FROM tab1 cor0
----
4158
4389
7392

onlyif mysql # use DIV operator for integer division
query I rowsort label-2798
SELECT + col0 DIV 60 AS col0 FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-2798
SELECT + col0 / 60 AS col0 FROM tab2 AS cor0
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - col2 * + col2 col1 FROM tab1 cor0
----
-2913
-3185
-9136

query I rowsort
SELECT col2 * + ( 74 ) + - col1 + + 38 FROM tab0 AS cor0
----
15
2394
6015

query I rowsort
SELECT col0 + - col2 + + col0 AS col1 FROM tab2 AS cor0
----
-13
120
130

query I rowsort
SELECT DISTINCT + col2 * - 67 FROM tab0 AS cor0
----
-2211
-5494
-67

query I rowsort
SELECT DISTINCT + col0 * ( - col2 * cor0.col0 ) FROM tab0 AS cor0
----
-1225
-19008
-649522

onlyif mysql # use DIV operator for integer division
query I rowsort label-2804
SELECT ALL - col1 DIV + 86 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2804
SELECT ALL - col1 / + 86 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 + - col2 * col0 FROM tab2 cor0
----
-158
-1969
-2985

query I rowsort
SELECT - tab2.col1 * tab2.col1 * col0 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT + 36 + + cor0.col0 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 67d581e2a26212bafa36a5b3a22acdff

query I rowsort
SELECT ALL - cor0.col1 + col0 * - col2 + - col2 FROM tab1 cor0
----
-242
-3715
-7789

query I rowsort
SELECT ALL + cor0.col0 * + col0 + col1 FROM tab0 AS cor0
----
1322
662
8012

onlyif mysql # use DIV operator for integer division
query I rowsort label-2810
SELECT DISTINCT col0 * col0 DIV + col1 FROM tab2
----
1
103
367

skipif mysql # not compatible
query I rowsort label-2810
SELECT DISTINCT col0 * col0 / + col1 FROM tab2
----
1
103
367

query I rowsort
SELECT DISTINCT - col2 FROM tab0 WHERE ( col1 * col2 ) NOT IN ( col2 )
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col1 col0 FROM tab2 WHERE NOT + col2 / col0 >= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2813
SELECT DISTINCT col2 * col0 DIV + col1 FROM tab1
----
364
590
6

skipif mysql # not compatible
query I rowsort label-2813
SELECT DISTINCT col2 * col0 / + col1 FROM tab1
----
364
590
6

query IIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0 WHERE NOT NULL NOT IN ( tab0.col0 )
----

query I rowsort
SELECT - col2 * - col2 * + col1 + + col1 FROM tab0
----
194
611975
93740

query I rowsort
SELECT col0 * col2 + - col2 AS col0 FROM tab0 WHERE NOT ( NULL ) BETWEEN ( + col2 / - col2 ) AND ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col2 col2 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT ALL - col1 * - col1 + tab0.col2 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT col1 + + col2 + col0 * col1 AS col1 FROM tab0
----
2183
3493
8272

query I rowsort
SELECT - col2 AS col1 FROM tab2 WHERE ( NULL ) NOT IN ( tab2.col0 - - col1 )
----

query I rowsort
SELECT col0 * + col0 * col1 + col1 AS col2 FROM tab0 AS cor0
----
118922
49622
720902

query I rowsort
SELECT - col1 + cor0.col2 * col2 AS col0 FROM tab1 cor0
----
2890
3239
9203

query I rowsort
SELECT cor0.col1 * cor0.col1 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 9708a433b981d9b5fd095bfe2ea45aea

query I rowsort
SELECT + col0 + + col0 + col0 FROM tab1 AS cor0
----
192
240
9

query I rowsort
SELECT - col2 * + col1 + col1 * - col1 AS col0 FROM tab0 AS cor0
----
-10234
-15743
-9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-2826
SELECT + - col2 DIV cor0.col2 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2826
SELECT + - col2 / cor0.col2 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT ALL 9 AS col2 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to ebef7303942834ca1e6ca8604ec18a07

query I rowsort
SELECT ALL - col2 * - cor0.col1 AS col0 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ALL 49 + col2 * 29 + - col0 AS col1 FROM tab1 AS cor0
----
1612
1638
2753

query I rowsort
SELECT DISTINCT col0 * + col2 - 12 FROM tab2 AS cor0
----
177
2016
2990

query I rowsort
SELECT - col2 + - 52 + - col1 * col2 * col2 FROM tab2 AS cor0
----
-22678
-24638
-39962

query I rowsort
SELECT ALL + - cor0.col2 + 20 * cor0.col0 FROM tab2 AS cor0
----
113
1534
1542

query I rowsort
SELECT cor0.col1 * cor0.col2 + - col0 * col0 AS col2 FROM tab0 AS cor0
----
-1128
-459
2262

onlyif mysql # use DIV operator for integer division
query I rowsort label-2834
SELECT ALL - + col2 DIV 32 AS col0 FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2834
SELECT ALL - + col2 / 32 AS col0 FROM tab2 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT + col0 * col0 + - col1 AS col2 FROM tab0 AS cor0
----
1128
490
7830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + 65 * col0 col2 FROM tab0 AS cor0
----
1584
2310
5874

onlyif mysql # use DIV operator for integer division
query I rowsort label-2837
SELECT + - col1 * ( col0 ) + col0 * col1 DIV col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

skipif mysql # not compatible
query I rowsort label-2837
SELECT + - col1 * ( col0 ) + col0 * col1 / col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL + + cor0.col1 * col2 - - col2 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2839
SELECT - col0 + CAST( NULL AS SIGNED ) * col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2839
SELECT - col0 + CAST ( NULL AS INTEGER ) * col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2840
SELECT DISTINCT + col0 + CAST( NULL AS SIGNED ) * col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2840
SELECT DISTINCT + col0 + CAST ( NULL AS INTEGER ) * col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + col1 + - tab2.col1 AS col1 FROM tab2
----
0
0
0

query III rowsort
SELECT * FROM tab0 WHERE NOT - col0 * + col0 = NULL
----

query I rowsort
SELECT - col2 * col0 + col1 * col2 * + col2 FROM tab0
----
604586
62
92862

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( NULL ) NOT IN ( col2 / tab2.col2 )
----

query III rowsort
SELECT * FROM tab0 WHERE NOT ( - col1 ) <> - col0
----

query I rowsort
SELECT tab2.col2 FROM tab2 WHERE NOT NULL NOT BETWEEN col0 AND NULL
----

query I rowsort
SELECT ALL + tab1.col2 + - col2 * col0 AS col0 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT col1 + + col0 + col2 * - col1 AS col0 FROM tab0
----
-2728
-7282
35

query I rowsort
SELECT ALL tab1.col0 AS col1 FROM tab1, tab2, tab0 AS cor0, tab0
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

query I rowsort
SELECT ALL - col0 * - col2 * - 72 + - col1 FROM tab0 AS cor0
----
-2617
-525547
-57110

query I rowsort
SELECT ALL - ( col2 ) + + col0 * + col1 * - col0 AS col0 FROM tab1 AS cor0
----
-288
-41017
-83296

onlyif mysql # use DIV operator for integer division
query I rowsort label-2852
SELECT ALL col2 * - col1 DIV col1 AS col1 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-2852
SELECT ALL col2 * - col1 / col1 AS col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT + tab1.col2 AS col1 FROM tab1, tab1 cor0
----
54
57
96

query I rowsort
SELECT DISTINCT + + col1 * 94 + ( - cor0.col2 ) FROM tab1 AS cor0
----
1126
2390
883

query I rowsort
SELECT - col1 * 61 AS col1 FROM tab1 AS cor0
----
-1586
-610
-793

query I rowsort
SELECT ALL + col1 * + 8 * col2 AS col1 FROM tab1 AS cor0
----
11232
4560
9984

query I rowsort
SELECT col1 + + cor0.col2 * 31 AS col1 FROM tab1 AS cor0
----
1700
1777
2989

onlyif mysql # use DIV operator for integer division
query I rowsort label-2858
SELECT col2 * 45 DIV - 51 FROM tab1 AS cor0
----
-47
-50
-84

skipif mysql # not compatible
query I rowsort label-2858
SELECT col2 * 45 / - 51 FROM tab1 AS cor0
----
-47
-50
-84

query I rowsort
SELECT ALL + col0 + cor0.col1 * + col2 FROM tab0 AS cor0
----
132
2862
7551

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col1 * - CAST ( + col0 AS REAL ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-2861
SELECT + col2 DIV + col1 + + col0 FROM tab2 cor0
----
7
78
81

skipif mysql # not compatible
query I rowsort label-2861
SELECT + col2 / + col1 + + col0 FROM tab2 cor0
----
7
78
81

query I rowsort
SELECT ALL - + 66 * 12 AS col0 FROM tab0 AS cor0
----
-792
-792
-792

query I rowsort
SELECT DISTINCT col0 + + col2 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT 66 * ( col0 ) FROM tab1
----
198
4224
5280

query I rowsort
SELECT ALL - col0 * 54 + col1 - 31 AS col2 FROM tab1 AS cor0
----
-167
-3477
-4338

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2866
SELECT - + CAST( + col1 AS SIGNED ) + col2 * - cor0.col0 col0 FROM tab1 AS cor0
----
-188
-3658
-7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2866
SELECT - + CAST ( + col1 AS INTEGER ) + col2 * - cor0.col0 col0 FROM tab1 AS cor0
----
-188
-3658
-7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-2867
SELECT ALL col0 + + col0 DIV col0 + - col1 FROM tab2 AS cor0
----
-23
20
63

skipif mysql # not compatible
query I rowsort label-2867
SELECT ALL col0 + + col0 / col0 + - col1 FROM tab2 AS cor0
----
-23
20
63

query I rowsort
SELECT DISTINCT + + col1 * col0 * col0 - - 92 AS col2 FROM tab0 AS cor0
----
118917
49628
720903

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2869
SELECT DISTINCT CAST( col1 AS SIGNED ) + + col2 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-2869
SELECT DISTINCT CAST ( col1 AS INTEGER ) + + col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT + - col1 * + 37 + - col2 + col1 AS col2 FROM tab2 AS cor0
----
-1143
-2150
-650

query I rowsort
SELECT + 85 + 79 FROM tab0 AS cor0
----
164
164
164

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2872
SELECT ALL - - CAST( cor0.col2 AS SIGNED ) col2 FROM tab2 AS cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2872
SELECT ALL - - CAST ( cor0.col2 AS INTEGER ) col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT 3 * col1 + col2 + - 25 * + col2 AS col0 FROM tab0 AS cor0
----
-1695
-534
267

query I rowsort
SELECT ALL + + col2 - - col0 AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT cor0.col2 * - 79 + col2 AS col2 FROM tab0 AS cor0
----
-2574
-6396
-78

query I rowsort
SELECT DISTINCT - - 3 * + col2 FROM tab2 AS cor0
----
114
78
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 84 * col2 + - cor0.col0 col0 FROM tab2 cor0
----
-2262
-2275
-3271

onlyif mysql # use DIV operator for integer division
query I rowsort label-2878
SELECT DISTINCT + - col2 + + col1 DIV + col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-2878
SELECT DISTINCT + - col2 + + col1 / + col2 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2879
SELECT - ( cor0.col0 ) + col2 DIV - col0 AS col2 FROM tab0 AS cor0
----
-25
-35
-89

skipif mysql # not compatible
query I rowsort label-2879
SELECT - ( cor0.col0 ) + col2 / - col0 AS col2 FROM tab0 AS cor0
----
-25
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2880
SELECT col1 + - cor0.col0 * CAST( - 32 AS SIGNED ) + - col1 * cor0.col0 AS col0 FROM tab2 cor0
----
-2047
1202
38

skipif mysql # not compatible
query I rowsort label-2880
SELECT col1 + - cor0.col0 * CAST ( - 32 AS INTEGER ) + - col1 * cor0.col0 AS col0 FROM tab2 cor0
----
-2047
1202
38

query I rowsort
SELECT DISTINCT + col2 + col1 * + col0 * 53 AS col2 FROM tab0 cor0
----
109425
179936
429329

query I rowsort
SELECT DISTINCT + - 43 + + col0 * 32 FROM tab1 AS cor0
----
2005
2517
53

query I rowsort
SELECT DISTINCT 86 + - col1 AS col1 FROM tab1
----
60
73
76

query I rowsort
SELECT - 74 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 5a567947d14593676e3825756f8e6130

query I rowsort
SELECT + tab0.col0 + col0 * - col2 * - col0 AS col0 FROM tab0
----
1260
19032
649611

query I rowsort
SELECT ALL - col2 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT ALL - col0 * + col1 * col0 AS col2 FROM tab2 AS cor0
----
-106097
-1519
-358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 46 col1 FROM tab1 AS cor0
----
46
46
46

query I rowsort
SELECT DISTINCT 66 * tab1.col2 FROM tab1
----
3564
3762
6336

onlyif mysql # use DIV operator for integer division
query I rowsort label-2890
SELECT ALL - col1 DIV + col2 + - col1 * + col1 FROM tab1 AS cor0
----
-100
-169
-676

skipif mysql # not compatible
query I rowsort label-2890
SELECT ALL - col1 / + col2 + - col1 * + col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT + 98 + - 21 * - tab2.col0 * + col2 AS col0 FROM tab2
----
4067
42686
63140

query I rowsort
SELECT - ( + col1 ) * col2 + col0 AS col2 FROM tab0
----
-2814
-62
-7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col1 ) + + col0 * col1 * cor0.col1 col1 FROM tab2 cor0
----
22848
271577
6758

query I rowsort
SELECT + 86 * - col0 + col1 FROM tab2 AS cor0
----
-571
-6649
-6777

query I rowsort
SELECT + + 47 * + col1 + col2 AS col1 FROM tab0 AS cor0
----
4075
4359
4560

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab0, tab0 cor1, tab2, tab1 AS cor2
----
3645 values hashing to b2cff03af5bc7306c5e3322cc78563c1

query I rowsort
SELECT DISTINCT + - col1 + cor0.col2 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL + 7 + cor0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 4783baa6da1fee30680b9c489c91bcaf

query I rowsort
SELECT col0 + ( - col1 ) + + col2 * + tab2.col2 FROM tab2
----
1506
695
705

query I rowsort
SELECT - col0 * 94 * col2 FROM tab2
----
-17766
-190632
-282188

query I rowsort
SELECT - 24 * col0 FROM tab0
----
-2136
-576
-840

onlyif mysql # use DIV operator for integer division
query I rowsort label-2902
SELECT DISTINCT tab0.col1 * - col1 + - col1 + col0 DIV col2 AS col0 FROM tab0
----
-7482
-8371
-9471

skipif mysql # not compatible
query I rowsort label-2902
SELECT DISTINCT tab0.col1 * - col1 + - col1 + col0 / col2 AS col0 FROM tab0
----
-7482
-8371
-9471

query I rowsort
SELECT ALL col1 + + col2 * + col0 AS col0 FROM tab1
----
188
3658
7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-2904
SELECT DISTINCT - col2 DIV tab0.col1 + col1 AS col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2904
SELECT DISTINCT - col2 / tab0.col1 + col1 AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT + - ( - 17 ) AS col1 FROM tab2 AS cor0
----
17

query I rowsort
SELECT DISTINCT - + cor0.col1 * col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT - 50 * col0 * col1 AS col0 FROM tab1
----
-32000
-3900
-52000

query I rowsort
SELECT + 65 * col1 FROM tab2
----
1105
2015
3835

query I rowsort
SELECT - - col2 * 41 FROM tab1 cor0
----
2214
2337
3936

query I rowsort
SELECT + ( ( + col1 ) ) * col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT 72 FROM tab0, tab2 cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT DISTINCT - ( col1 ) * tab2.col0 * tab2.col1 AS col2 FROM tab2
----
-22831
-271518
-6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-2913
SELECT - 82 DIV + tab2.col1 AS col1 FROM tab2
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-2913
SELECT - 82 / + tab2.col1 AS col1 FROM tab2
----
-1
-2
-4

query I rowsort
SELECT + cor0.col2 * 73 AS col1 FROM tab0 AS cor0
----
2409
5986
73

query I rowsort
SELECT ALL + 5 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT + col2 * 98 AS col0 FROM tab0 AS cor0
----
3234
8036
98

query I rowsort
SELECT + ( - tab1.col0 ) * + col0 * - col1 FROM tab1
----
234
40960
83200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2918
SELECT ALL + - ( col1 ) * CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
-289
-3481
-961

skipif mysql # not compatible
query I rowsort label-2918
SELECT ALL + - ( col1 ) * CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT 93 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
93

query I rowsort
SELECT + 65 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 1c9d0bf96cd3361942fadad668138b9c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2921
SELECT + col0 / CAST( NULL AS SIGNED ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2921
SELECT + col0 / CAST ( NULL AS INTEGER ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + ( 96 ) FROM tab0 AS cor0
----
-1
10
5

query I rowsort
SELECT - - col2 + - col2 * cor0.col0 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT col1 + - ( tab1.col0 + - col2 ) FROM tab1
----
29
3
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-2925
SELECT DISTINCT - col2 * tab1.col0 + col2 DIV col0 + col2 col2 FROM tab1
----
-3591
-7583
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2925
SELECT DISTINCT - col2 * tab1.col0 + col2 / col0 + col2 col2 FROM tab1
----
-3591
-7583
-90

query I rowsort
SELECT DISTINCT - col1 + 99 FROM tab0
----
13
2
8

query I rowsort
SELECT - tab0.col1 - + col1 * ( col1 ) AS col2 FROM tab0
----
-7482
-8372
-9506

query I rowsort
SELECT 13 AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT 13 + - col0 * + col0 AS col0 FROM tab0 AS cor0
----
-1212
-563
-7908

query I rowsort
SELECT DISTINCT + + 40 * cor0.col0 FROM tab2 AS cor0
----
280
3120
3160

query I rowsort
SELECT DISTINCT - + 1 * - col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL - + ( ( - col2 ) ) FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL + + 32 AS col2 FROM tab1 AS cor0
----
32
32
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col0 ) * - cor0.col2 + + col2 * col1 * col0 col1 FROM tab2 AS cor0
----
117624
48032
5670

query I rowsort
SELECT - col2 * - 71 * col0 FROM tab1 AS cor0
----
11502
259008
545280

query I rowsort
SELECT ALL + 76 * col2 * col1 AS col0 FROM tab1 AS cor0
----
106704
43320
94848

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2937
SELECT + CAST( 88 AS SIGNED ) FROM tab1 AS cor0
----
88
88
88

skipif mysql # not compatible
query I rowsort label-2937
SELECT + CAST ( 88 AS INTEGER ) FROM tab1 AS cor0
----
88
88
88

query I rowsort
SELECT ALL col1 * - 9 AS col1 FROM tab2 AS cor0
----
-153
-279
-531

query I rowsort
SELECT ALL + + ( + 57 ) + col1 FROM tab0 AS cor0
----
143
148
154

query I rowsort
SELECT ALL - + 3 AS col0 FROM tab1 AS cor0
----
-3
-3
-3

query I rowsort
SELECT - col1 - col1 * 78 AS col0 FROM tab2 AS cor0
----
-1343
-2449
-4661

query I rowsort
SELECT ALL - 45 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 71160abf09589695379a70558726f0ba

query I rowsort
SELECT ALL 99 + cor0.col0 FROM tab1 AS cor0
----
102
163
179

query I rowsort
SELECT ALL col2 + - cor0.col0 * - col0 * - col2 AS col2 FROM tab0 cor0
----
-1224
-18975
-649440

query I rowsort
SELECT + ( 46 ) * + col1 FROM tab1
----
1196
460
598

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2946
SELECT cor0.col2 * col0 + - CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
216
3705
7776

skipif mysql # not compatible
query I rowsort label-2946
SELECT cor0.col2 * col0 + - CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT - 3 + - col0 * ( + col0 ) FROM tab2 AS cor0
----
-52
-6087
-6244

onlyif mysql # use DIV operator for integer division
query I rowsort label-2948
SELECT + + ( col0 ) + - col2 DIV - 7 AS col2 FROM tab1 AS cor0
----
10
72
93

skipif mysql # not compatible
query I rowsort label-2948
SELECT + + ( col0 ) + - col2 / - 7 AS col2 FROM tab1 AS cor0
----
10
72
93

query I rowsort
SELECT DISTINCT + - col2 * - col0 + + col1 AS col2 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-2950
SELECT ALL col0 DIV + col0 + - col2 FROM tab0 AS cor0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-2950
SELECT ALL col0 / + col0 + - col2 FROM tab0 AS cor0
----
-32
-81
0

query I rowsort
SELECT ALL 72 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT ALL + - col2 + - col0 AS col2 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT ALL - - col2 + col1 + col2 AS col0 FROM tab2 AS cor0
----
111
85
93

query I rowsort
SELECT DISTINCT + ( - col0 ) + + ( - col1 * col1 ) AS col1 FROM tab0
----
-7420
-8370
-9444

query I rowsort
SELECT DISTINCT + ( - 89 ) * col2 + - 68 + - col1 FROM tab1
----
-4900
-5151
-8625

query I rowsort
SELECT ( col0 ) * col2 * col1 + tab2.col0 AS col1 FROM tab2
----
119730
51113
5866

query I rowsort
SELECT ALL + - cor0.col0 + - col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT DISTINCT - + cor0.col1 - + col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT + - col0 * + cor0.col2 + - col1 * 96 AS col1 FROM tab1 AS cor0
----
-2658
-4608
-8928

query I rowsort
SELECT DISTINCT 37 + + tab2.col2 + - tab2.col1 * col0 AS col0 FROM tab2
----
-1268
-153
-4539

query I rowsort
SELECT 82 + tab0.col0 * - col0 AS col0 FROM tab0
----
-1143
-494
-7839

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - col2 * col0 + - ( - col1 * - col2 ) + col0 * - 99 col0 FROM tab0
----
-2337
13794
633249

query I rowsort
SELECT DISTINCT cor0.col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
54
57
96

query I rowsort
SELECT DISTINCT col0 + 39 FROM tab1
----
103
119
42

query I rowsort
SELECT cor0.col0 * - tab1.col0 + + 11 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 5de2ecef3eb53fe480fad8efa25176e1

query I rowsort
SELECT 26 + col0 AS col2 FROM tab1
----
106
29
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2967
SELECT DISTINCT + CAST( NULL AS SIGNED ) + col0 + col0 * ( + col1 ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-2967
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + col0 + col0 * ( + col1 ) FROM tab2
----
NULL

query I rowsort
SELECT + 20 * col1 * + col0 + col1 FROM tab1
----
12810
1586
20813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2969
SELECT DISTINCT - ( tab2.col2 + CAST( 61 AS SIGNED ) ) AS col2 FROM tab2
----
-87
-88
-99

skipif mysql # not compatible
query I rowsort label-2969
SELECT DISTINCT - ( tab2.col2 + CAST ( 61 AS INTEGER ) ) AS col2 FROM tab2
----
-87
-88
-99

query I rowsort
SELECT DISTINCT - 36 * - col2 AS col1 FROM tab2
----
1368
936
972

query I rowsort
SELECT ALL - - col0 + - col0 * 51 FROM tab1 AS cor0
----
-150
-3200
-4000

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * cor0.col2 col2 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT - col2 * col0 + 29 AS col0 FROM tab1 AS cor0
----
-133
-3619
-7651

onlyif mysql # use DIV operator for integer division
query I rowsort label-2974
SELECT ALL + col1 + - col1 DIV + 14 AS col1 FROM tab1 AS cor0
----
10
13
25

skipif mysql # not compatible
query I rowsort label-2974
SELECT ALL + col1 + - col1 / + 14 AS col1 FROM tab1 AS cor0
----
10
13
25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2975
SELECT col1 + - CAST( NULL AS SIGNED ) + 30 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2975
SELECT col1 + - CAST ( NULL AS INTEGER ) + 30 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2976
SELECT - col2 * 6 * - col0 - + col1 DIV col0 FROM tab2 cor0
----
1130
12168
18012

skipif mysql # not compatible
query I rowsort label-2976
SELECT - col2 * 6 * - col0 - + col1 / col0 FROM tab2 cor0
----
1130
12168
18012

query I rowsort
SELECT DISTINCT cor0.col1 * 15 + col0 FROM tab2 AS cor0
----
334
472
963

query I rowsort
SELECT + + ( - 32 ) + - col1 AS col2 FROM tab0 cor0
----
-118
-123
-129

query I rowsort
SELECT ALL + 64 * ( cor0.col2 + col2 ) AS col1 FROM tab1 AS cor0
----
12288
6912
7296

onlyif mysql # use DIV operator for integer division
query I rowsort label-2980
SELECT + col0 * col0 DIV - col0 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-2980
SELECT + col0 * col0 / - col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL + cor0.col0 + - col0 * - col2 FROM tab0 AS cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-2982
SELECT DISTINCT - - col2 + - col0 DIV col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2982
SELECT DISTINCT - - col2 + - col0 / col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL + ( - col1 ) * cor0.col2 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 40 * + cor0.col1 + col1 col2 FROM tab1 AS cor0
----
1066
410
533

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) * cor0.col0 + - 87 FROM tab2 AS cor0
----
1256
130
4515

query I rowsort
SELECT + + ( + 34 ) + - col1 FROM tab1 AS cor0
----
21
24
8

query I rowsort
SELECT ALL 64 FROM tab0, tab1 AS cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT DISTINCT col2 + - cor0.col0 FROM tab0 cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2989
SELECT - - cor0.col2 DIV 87 + + col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2989
SELECT - - cor0.col2 / 87 + + col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - col0 * 66 FROM tab0 AS cor0
----
-1584
-2310
-5874

query I rowsort
SELECT - ( + 96 ) - - cor0.col1 * ( col0 ) FROM tab2 AS cor0
----
121
1247
4506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 57 + col1 col1 FROM tab2 cor0
----
116
74
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2993
SELECT CAST( 14 AS SIGNED ) - + col2 * + col1 FROM tab0 AS cor0
----
-2824
-7448
-83

skipif mysql # not compatible
query I rowsort label-2993
SELECT CAST ( 14 AS INTEGER ) - + col2 * + col1 FROM tab0 AS cor0
----
-2824
-7448
-83

query I rowsort
SELECT + col1 * - col2 + col0 AS col1 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT - + ( col1 ) + cor0.col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT ALL + - col1 + + 36 * - col2 * ( + 82 ) AS col2 FROM tab2 AS cor0
----
-112193
-76811
-79735

skipif mysql # not compatible
query I rowsort
SELECT + - CAST ( col2 AS REAL ) + col1 / 10 AS col1 FROM tab1 AS cor0
----
-52
-56
-95

query I rowsort
SELECT DISTINCT - - col1 + 7 * col0 FROM tab2 AS cor0
----
570
605
80

query I rowsort
SELECT ALL + 2 * - 28 + - col0 AS col1 FROM tab0 AS cor0
----
-145
-80
-91

query I rowsort
SELECT ALL - + cor0.col2 * - ( col0 * col1 ) + col2 FROM tab2 AS cor0
----
119678
51072
5886

query I rowsort
SELECT ( col2 ) * + col0 + - col1 + col2 FROM tab1 AS cor0
----
190
3695
7763

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3002
SELECT + col0 * col0 + - CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3002
SELECT + col0 * col0 + - CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + + col0 + col1 AS col0 FROM tab1 AS cor0
----
106
55
84

query I rowsort
SELECT DISTINCT tab0.col2 AS col0 FROM tab1, tab0 cor0 CROSS JOIN tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3005
SELECT DISTINCT + - cor0.col2 * - 82 - + col0 DIV cor0.col1 AS col1 FROM tab2 AS cor0
----
2131
2214
3112

skipif mysql # not compatible
query I rowsort label-3005
SELECT DISTINCT + - cor0.col2 * - 82 - + col0 / cor0.col1 AS col1 FROM tab2 AS cor0
----
2131
2214
3112

onlyif mysql # use DIV operator for integer division
query I rowsort label-3006
SELECT 35 DIV cor0.col1 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-3006
SELECT 35 / cor0.col1 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + ( 31 * col2 ) col0 FROM tab1 AS cor0
----
1700
1777
2989

onlyif mysql # use DIV operator for integer division
query I rowsort label-3008
SELECT ALL - col2 DIV 4 col0 FROM tab1 AS cor0
----
-13
-14
-24

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3008
SELECT ALL - col2 / 4 col0 FROM tab1 AS cor0
----
-13
-14
-24

query I rowsort
SELECT DISTINCT + col1 * + 14 + + cor0.col0 + - col0 * 36 FROM tab0 cor0
----
-1841
133
364

query I rowsort
SELECT - - col1 + - ( - 84 ) * + col1 AS col2 FROM tab2 AS cor0
----
1445
2635
5015

query I rowsort
SELECT ALL - col0 * + 26 + - col1 * col0 * col2 FROM tab1
----
-101920
-38144
-4290

query I rowsort
SELECT + col2 + col0 + - col2 AS col0 FROM tab2
----
7
78
79

query I rowsort
SELECT + 7 + + col1 AS col2 FROM tab1 AS cor0
----
17
20
33

query I rowsort
SELECT + + col0 - 92 * + col0 FROM tab0 AS cor0
----
-2184
-3185
-8099

query I rowsort
SELECT DISTINCT + col2 * ( 46 ) + + col2 AS col2 FROM tab0
----
1551
3854
47

query I rowsort
SELECT - col2 + + 4 + col2 FROM tab2
----
4
4
4

query I rowsort
SELECT + + cor0.col0 * col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT - - 42 FROM tab1 cor0
----
42

query I rowsort
SELECT ALL + - col2 * - col0 + - col0 * ( - col2 ) AS col0 FROM tab2 AS cor0
----
378
4056
6004

query I rowsort
SELECT - ( col1 ) + - ( - col1 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + + 30 * col2 + 48 FROM tab1 AS cor0
----
1668
1758
2928

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3022
SELECT cor0.col2 + CAST( + 53 AS SIGNED ) * - col1 AS col0 FROM tab0 AS cor0
----
-4525
-4741
-5140

skipif mysql # not compatible
query I rowsort label-3022
SELECT cor0.col2 + CAST ( + 53 AS INTEGER ) * - col1 AS col0 FROM tab0 AS cor0
----
-4525
-4741
-5140

query I rowsort
SELECT - col2 + - 45 * 19 AS col1 FROM tab1 cor0
----
-909
-912
-951

query I rowsort
SELECT ALL - 91 AS col1 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to 6ec4feac5c635ab8e5da71006896acab

onlyif mysql # use DIV operator for integer division
query I rowsort label-3025
SELECT DISTINCT col1 DIV + 17 AS col0 FROM tab0 AS cor0
----
5

skipif mysql # not compatible
query I rowsort label-3025
SELECT DISTINCT col1 / + 17 AS col0 FROM tab0 AS cor0
----
5

query I rowsort
SELECT ALL + col2 * + ( col0 ) FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT + col2 * - 7 * 76 FROM tab0 AS cor0
----
-17556
-43624
-532

query I rowsort
SELECT + 67 + col0 AS col1 FROM tab0 AS cor0
----
102
156
91

query I rowsort
SELECT + col1 + - col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT + + col1 * col1 + - cor0.col0 FROM tab1 AS cor0
----
36
673
89

query I rowsort
SELECT DISTINCT + cor0.col1 + - 52 AS col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
34
39
45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3032
SELECT ALL - CAST( 53 AS SIGNED ) AS col0 FROM tab0
----
-53
-53
-53

skipif mysql # not compatible
query I rowsort label-3032
SELECT ALL - CAST ( 53 AS INTEGER ) AS col0 FROM tab0
----
-53
-53
-53

query I rowsort
SELECT ALL - - col1 - col1 * + col2 FROM tab2 cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL 53 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-36
18
29

query I rowsort
SELECT - 64 * + ( - col0 ) FROM tab2
----
448
4992
5056

query I rowsort
SELECT + + col2 * col1 + - col2 AS col1 FROM tab2 AS cor0
----
1508
608
810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3037
SELECT CAST( - 45 AS SIGNED ) * - col0 FROM tab2
----
315
3510
3555

skipif mysql # not compatible
query I rowsort label-3037
SELECT CAST ( - 45 AS INTEGER ) * - col0 FROM tab2
----
315
3510
3555

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3038
SELECT ALL - + col2 * + col1 * - CAST( col1 AS SIGNED ) - - col1 FROM tab1 AS cor0
----
16237
36530
5710

skipif mysql # not compatible
query I rowsort label-3038
SELECT ALL - + col2 * + col1 * - CAST ( col1 AS INTEGER ) - - col1 FROM tab1 AS cor0
----
16237
36530
5710

query I rowsort
SELECT DISTINCT 75 + - col1 * - ( + 89 ) AS col1 FROM tab2 cor0
----
1588
2834
5326

query I rowsort
SELECT ALL + - cor0.col1 + - col1 * - cor0.col1 AS col1 FROM tab2 cor0
----
272
3422
930

query I rowsort
SELECT + 63 * col2 FROM tab2
----
1638
1701
2394

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3042
SELECT tab1.col0 * - tab1.col1 + - CAST( NULL AS DECIMAL ) / + col2 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3042
SELECT tab1.col0 * - tab1.col1 + - CAST ( NULL AS REAL ) / + col2 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 + - col2 * ( + col1 * tab0.col1 ) FROM tab0
----
-244035
-678960
-9408

query I rowsort
SELECT - col1 - tab2.col0 * + col0 AS col2 FROM tab2
----
-6143
-6258
-80

query I rowsort
SELECT DISTINCT col2 + col2 + col1 * - col0 AS col1 FROM tab0
----
-1998
-3393
-7935

query I rowsort
SELECT + col2 + + 46 + col0 FROM tab2
----
150
163
80

query I rowsort
SELECT ALL col2 - 93 FROM tab0
----
-11
-60
-92

query I rowsort
SELECT col2 + - 89 * + col2 FROM tab1
----
-4752
-5016
-8448

query I rowsort
SELECT + col0 * ( - col1 * col0 ) FROM tab2
----
-106097
-1519
-358956

query I rowsort
SELECT DISTINCT cor1.col2 FROM tab1, tab0 AS cor0, tab1 cor1
----
54
57
96

query I rowsort
SELECT + + col1 + 5 * cor0.col1 - 24 AS col2 FROM tab2 AS cor0
----
162
330
78

query I rowsort
SELECT ALL + 74 * col0 FROM tab2 AS cor0
----
518
5772
5846

query I rowsort
SELECT - 24 + col0 * + col2 * 19 AS col1 FROM tab2 AS cor0
----
3567
38508
57014

query I rowsort
SELECT - col1 + cor0.col2 - + col0 FROM tab2 AS cor0
----
-11
-111
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( ( - cor0.col2 ) ) col2 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3056
SELECT + col2 * 55 + col1 DIV col2 + cor0.col1 * + col0 AS col2 FROM tab1 AS cor0
----
3048
3775
6320

skipif mysql # not compatible
query I rowsort label-3056
SELECT + col2 * 55 + col1 / col2 + cor0.col1 * + col0 AS col2 FROM tab1 AS cor0
----
3048
3775
6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3057
SELECT ALL - ( 34 ) * - col1 + - CAST( - col1 AS SIGNED ) FROM tab2 AS cor0
----
1085
2065
595

skipif mysql # not compatible
query I rowsort label-3057
SELECT ALL - ( 34 ) * - col1 + - CAST ( - col1 AS INTEGER ) FROM tab2 AS cor0
----
1085
2065
595

query I rowsort
SELECT DISTINCT - ( col0 ) * cor0.col1 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - - col1 * col2 * col1 AS col0 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT ALL + + cor0.col0 * - 40 * col1 + + col1 FROM tab2 AS cor0
----
-184021
-53703
-8649

query I rowsort
SELECT + col1 + ( - col1 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col2 + ( - col1 ) * col2 AS col1 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT - 93 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
-93

query I rowsort
SELECT - col2 + - ( 62 + col2 ) FROM tab2 AS cor0
----
-114
-116
-138

onlyif mysql # use DIV operator for integer division
query I rowsort label-3065
SELECT + col1 * + cor0.col2 + - col1 DIV - cor0.col2 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-3065
SELECT + col1 * + cor0.col2 + - col1 / - cor0.col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + col1 + 54 FROM tab0 AS cor0
----
140
145
151

onlyif mysql # use DIV operator for integer division
query I rowsort label-3067
SELECT - - col2 + col0 DIV - col0 + cor0.col2 AS col0 FROM tab1 AS cor0
----
107
113
191

skipif mysql # not compatible
query I rowsort label-3067
SELECT - - col2 + col0 / - col0 + cor0.col2 AS col0 FROM tab1 AS cor0
----
107
113
191

query I rowsort
SELECT col0 - - 65 AS col0 FROM tab1
----
129
145
68

query I rowsort
SELECT + col0 * + col1 + - col2 AS col1 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT DISTINCT + ( cor0.col1 + cor0.col1 ) * - 78 FROM tab2, tab1 cor0, tab0 AS cor1
----
-1560
-2028
-4056

query I rowsort
SELECT - tab0.col0 + 67 FROM tab0
----
-22
32
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3072
SELECT col2 * CAST( + 23 + col1 AS SIGNED ) FROM tab1
----
1881
2646
3456

skipif mysql # not compatible
query I rowsort label-3072
SELECT col2 * CAST ( + 23 + col1 AS INTEGER ) FROM tab1
----
1881
2646
3456

query I rowsort
SELECT ALL + + cor0.col1 + - col1 AS col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3074
SELECT DISTINCT + 36 DIV cor0.col1 - - col2 DIV cor0.col0 AS col1 FROM tab2 AS cor0
----
0
2
4

skipif mysql # not compatible
query I rowsort label-3074
SELECT DISTINCT + 36 / cor0.col1 - - col2 / cor0.col0 AS col1 FROM tab2 AS cor0
----
0
2
4

query I rowsort
SELECT DISTINCT col2 + - col2 * col1 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT - col1 + ( + tab0.col2 ) * - col2 * + 70 FROM tab0
----
-167
-470771
-76316

query I rowsort
SELECT ALL + ( + 97 ) AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

query I rowsort
SELECT DISTINCT 22 + + col1 AS col0 FROM tab0
----
108
113
119

query I rowsort
SELECT DISTINCT - + cor0.col0 * + col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT + cor0.col2 - + col1 * + 77 FROM tab2 AS cor0
----
-1271
-2360
-4517

query I rowsort
SELECT ALL col0 * col1 + - ( col1 ) AS col0 FROM tab2
----
1326
186
4543

query I rowsort
SELECT - 75 FROM tab0 cor0
----
-75
-75
-75

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1, tab2 cor0, tab1 cor1
----
972 values hashing to dd771e0c15d524f62127686e9bd43f9a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3084
SELECT + col0 * - CAST( + col2 AS SIGNED ) FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-3084
SELECT + col0 * - CAST ( + col2 AS INTEGER ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - col1 * col2 - - col0 AS col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT + 7 * + col0 FROM tab0
----
168
245
623

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3087
SELECT ALL col1 + + CAST( - col1 * col0 AS SIGNED ) FROM tab1 AS cor0
----
-1027
-52
-630

skipif mysql # not compatible
query I rowsort label-3087
SELECT ALL col1 + + CAST ( - col1 * col0 AS INTEGER ) FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT + - col2 + cor0.col1 AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT + col0 + + 27 + 69 AS col2 FROM tab1 AS cor0
----
160
176
99

query I rowsort
SELECT + + col2 - - cor0.col2 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT DISTINCT + + cor0.col0 * col0 - 53 FROM tab2 AS cor0
----
-4
6031
6188

query I rowsort
SELECT col1 * 79 - 22 FROM tab2 AS cor0
----
1321
2427
4639

onlyif mysql # use DIV operator for integer division
query I rowsort label-3093
SELECT - col2 DIV + col2 + - 78 * col0 + 41 AS col0 FROM tab1 cor0
----
-194
-4952
-6200

skipif mysql # not compatible
query I rowsort label-3093
SELECT - col2 / + col2 + - 78 * col0 + 41 AS col0 FROM tab1 cor0
----
-194
-4952
-6200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col1 * col1 + col1 ) col1 FROM tab2
----
-306
-3540
-992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - 76 ) col1 FROM tab0 AS cor0
----
-76

query I rowsort
SELECT DISTINCT - - col1 + 77 * + col2 AS col0 FROM tab0 AS cor0
----
174
2627
6405

query I rowsort
SELECT ( 10 ) + - col2 AS col2 FROM tab1 AS cor0
----
-44
-47
-86

query I rowsort
SELECT ALL + - 72 + + col2 FROM tab1 AS cor0
----
-15
-18
24

query I rowsort
SELECT ALL + 41 * + 18 + col1 FROM tab1 AS cor0
----
748
751
764

query I rowsort
SELECT DISTINCT + col1 * + 85 AS col2 FROM tab0
----
7310
7735
8245

query I rowsort
SELECT DISTINCT + ( col1 ) + + col0 * ( col2 ) FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL col2 * + 33 FROM tab1 AS cor0
----
1782
1881
3168

query I rowsort
SELECT - - ( - col1 ) * + ( 33 ) FROM tab1 AS cor0
----
-330
-429
-858

query I rowsort
SELECT DISTINCT + ( - col2 ) + ( + ( + cor0.col0 ) ) FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT - 72 * cor0.col2 AS col1 FROM tab0 cor0
----
-2376
-5904
-72

query I rowsort
SELECT + 63 + - cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 2d9aa21a10ec4a9a6c7e9904869cbdc6

query IIIIIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab1, tab0 AS cor2, tab0
----
13122 values hashing to 8718ce71186c0fb3b188ed4f5cf992d1

query I rowsort
SELECT DISTINCT + + 42 AS col2 FROM tab2, tab1 cor0, tab1, tab1 AS cor1
----
42

query I rowsort
SELECT + + col0 * - col2 + 70 AS col0 FROM tab1 cor0
----
-3578
-7610
-92

query I rowsort
SELECT - cor0.col1 * col0 + - 33 * col1 FROM tab1 AS cor0
----
-1469
-936
-970

onlyif mysql # use DIV operator for integer division
query I rowsort label-3111
SELECT + col0 DIV 10 col2 FROM tab1 AS cor0
----
0
6
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3111
SELECT + col0 / 10 col2 FROM tab1 AS cor0
----
0
6
8

query I rowsort
SELECT col0 + + 38 AS col0 FROM tab0 AS cor0
----
127
62
73

query I rowsort
SELECT + col2 * - col2 + col0 + - col0 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT 99 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query I rowsort
SELECT + cor0.col1 * col0 * col0 FROM tab0 AS cor0
----
118825
49536
720811

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + col0 * col0 col2 FROM tab1
----
-234
-40960
-83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 ) col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL + col2 * 16 + col2 + 53 FROM tab1 AS cor0
----
1022
1685
971

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3119
SELECT - CAST( NULL AS SIGNED ) * - col0 + col1 + cor0.col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3119
SELECT - CAST ( NULL AS INTEGER ) * - col0 + col1 + cor0.col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( tab2.col1 ) FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 75 col1 FROM tab1 AS cor0
----
-75
-75
-75

query I rowsort
SELECT - col0 * col0 + 42 * - col2 FROM tab0 AS cor0
----
-11365
-1267
-1962

query I rowsort
SELECT - - col0 * + ( - col1 ) + - col2 FROM tab2 AS cor0
----
-1381
-244
-4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3124
SELECT DISTINCT - - col0 * - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3124
SELECT DISTINCT - - col0 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + col1 - col1 * cor0.col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - cor0.col0 * 14 * + col1 + col2 FROM tab0 cor0
----
-113304
-28863
-47529

query I rowsort
SELECT - col2 * - col0 * col2 + col2 + - col2 * - col0 FROM tab0
----
26961
605816
71

query I rowsort
SELECT col2 * col2 * - ( + ( col2 ) ) FROM tab2
----
-17576
-19683
-54872

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + - 40 col1 FROM tab0 AS cor0
----
-16
-5
49

query I rowsort
SELECT - col1 + ( - 0 ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL - - cor0.col2 * + 15 AS col0 FROM tab2 AS cor0
----
390
405
570

query I rowsort
SELECT ALL cor0.col0 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3133
SELECT DISTINCT + cor0.col1 * - CAST( col0 AS SIGNED ) * - cor0.col2 + + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3133
SELECT DISTINCT + cor0.col1 * - CAST ( col0 AS INTEGER ) * - cor0.col2 + + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + + 16 FROM tab1, tab0 cor0
----
16

query I rowsort
SELECT DISTINCT - 70 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3136
SELECT DISTINCT + - cor0.col2 * - 59 + ( + cor0.col2 ) * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3136
SELECT DISTINCT + - cor0.col2 * - 59 + ( + cor0.col2 ) * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT col0 + - tab0.col2 * tab0.col2 AS col2 FROM tab0
----
-1065
-6635
34

query I rowsort
SELECT + col0 + - ( col1 * col1 ) AS col2 FROM tab2
----
-210
-3403
-954

query I rowsort
SELECT + + col1 + + 5 AS col2 FROM tab0 AS cor0
----
102
91
96

query I rowsort
SELECT + col1 * - 33 AS col2 FROM tab1 cor0
----
-330
-429
-858

query I rowsort
SELECT ALL - col2 + - 41 * col2 AS col0 FROM tab1 AS cor0
----
-2268
-2394
-4032

query I rowsort
SELECT DISTINCT - + col1 + - 68 * + col1 - col0 AS col2 FROM tab0 AS cor0
----
-5958
-6368
-6728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + 77 col2 FROM tab0
----
110
159
78

query I rowsort
SELECT col1 + - ( tab2.col1 * col2 ) + 48 AS col1 FROM tab2
----
-1427
-581
-758

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3145
SELECT + CAST( + 46 AS SIGNED ) FROM tab1, tab1 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

skipif mysql # not compatible
query I rowsort label-3145
SELECT + CAST ( + 46 AS INTEGER ) FROM tab1, tab1 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT - col1 * col0 + col1 * col2 * + col1 + col0 FROM tab2
----
25737
85982
9718

onlyif mysql # use DIV operator for integer division
query I rowsort label-3147
SELECT ALL + col0 DIV col0 + col1 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-3147
SELECT ALL + col0 / col0 + col1 FROM tab0
----
87
92
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3148
SELECT ALL - col1 DIV col1 + 26 AS col1 FROM tab1 AS cor0
----
25
25
25

skipif mysql # not compatible
query I rowsort label-3148
SELECT ALL - col1 / col1 + 26 AS col1 FROM tab1 AS cor0
----
25
25
25

query I rowsort
SELECT DISTINCT + + ( col0 ) * ( - cor0.col2 ) * col0 - cor0.col0 * col0 FROM tab1 AS cor0
----
-237568
-495
-620800

query I rowsort
SELECT DISTINCT - col2 * + 19 FROM tab1
----
-1026
-1083
-1824

query I rowsort
SELECT DISTINCT ( cor0.col1 ) FROM tab2, tab0, tab1 AS cor0
----
10
13
26

query I rowsort
SELECT 44 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT ALL - - 76 * + cor0.col1 + - col1 * col0 + - col0 * col1 * + col2 AS col2 FROM tab1 AS cor0
----
-2314
-36360
-99892

query I rowsort
SELECT DISTINCT 79 * col1 AS col1 FROM tab1 AS cor0
----
1027
2054
790

onlyif mysql # use DIV operator for integer division
query I rowsort label-3155
SELECT - CAST( col2 AS SIGNED ) DIV - col0 + 37 AS col0 FROM tab2
----
37
37
40

skipif mysql # not compatible
query I rowsort label-3155
SELECT - CAST ( col2 AS INTEGER ) / - col0 + 37 AS col0 FROM tab2
----
37
37
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-3156
SELECT DISTINCT 40 DIV tab2.col1 FROM tab2
----
0
1
2

skipif mysql # not compatible
query I rowsort label-3156
SELECT DISTINCT 40 / tab2.col1 FROM tab2
----
0
1
2

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 ALL + col1 * - col2 * + 18 AS col1 FROM tab2
----
-11628
-15066
-27612

onlyif mysql # use DIV operator for integer division
query I rowsort label-3159
SELECT + tab0.col0 DIV + tab0.col2 + - 2 FROM tab0
----
-1
-2
33

skipif mysql # not compatible
query I rowsort label-3159
SELECT + tab0.col0 / + tab0.col2 + - 2 FROM tab0
----
-1
-2
33

query I rowsort
SELECT tab0.col0 + col0 * - col2 AS col1 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT col2 * col0 - - 88 * - 50 AS col1 FROM tab2
----
-1398
-2372
-4211

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3162
SELECT ALL + CAST( NULL AS SIGNED ) * 12 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3162
SELECT ALL + CAST ( NULL AS INTEGER ) * 12 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 48 * - col0 col0 FROM tab1 AS cor0
----
144
3072
3840

query I rowsort
SELECT + - cor0.col1 * + col1 * + ( - 30 ) AS col2 FROM tab2 AS cor0
----
104430
28830
8670

query I rowsort
SELECT ALL + + cor0.col2 * col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - ( cor0.col1 ) + ( 57 ) AS col2 FROM tab1 AS cor0
----
31
44
47

query I rowsort
SELECT - ( col0 * + col1 ) + col1 + + 3 AS col1 FROM tab2
----
-1323
-183
-4540

query I rowsort
SELECT 52 * col2 AS col1 FROM tab2
----
1352
1404
1976

onlyif mysql # use DIV operator for integer division
query I rowsort label-3169
SELECT ALL + col1 * col2 + - col2 DIV + ( col1 ) FROM tab0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-3169
SELECT ALL + col1 * col2 + - col2 / + ( col1 ) FROM tab0
----
2838
7462
97

query I rowsort
SELECT ALL - ( col1 ) * col2 + col1 + col1 * - col1 FROM tab1 AS cor0
----
-1404
-2054
-660

query I rowsort
SELECT DISTINCT + ( 21 ) + - col1 FROM tab2 AS cor0
----
-10
-38
4

query I rowsort
SELECT DISTINCT + 94 * + col2 + col0 FROM tab0 AS cor0
----
129
3126
7797

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col0 * - 13 col2 FROM tab2 cor0
----
-1092
-1106
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3174
SELECT + col0 * col1 * CAST( NULL AS SIGNED ) + - col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3174
SELECT + col0 * col1 * CAST ( NULL AS INTEGER ) + - col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3175
SELECT + 34 * col1 DIV + 1 AS col2 FROM tab1 AS cor0
----
340
442
884

skipif mysql # not compatible
query I rowsort label-3175
SELECT + 34 * col1 / + 1 AS col2 FROM tab1 AS cor0
----
340
442
884

query I rowsort
SELECT ALL col1 * - col2 + - col1 AS col1 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT DISTINCT - 83 * + col1 FROM tab1 AS cor0
----
-1079
-2158
-830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3178
SELECT - col0 * cor0.col0 * + CAST( NULL AS SIGNED ) + col1 / + cor0.col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3178
SELECT - col0 * cor0.col0 * + CAST ( NULL AS INTEGER ) + col1 / + cor0.col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + col2 * + col0 + - 19 FROM tab2 cor0
----
170
2009
2983

query I rowsort
SELECT ALL cor0.col1 * col2 + - 10 AS col2 FROM tab2 AS cor0
----
1524
636
827

query I rowsort
SELECT ALL - + 58 + + col0 FROM tab0 AS cor0
----
-23
-34
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-3182
SELECT ALL ( - col2 ) + tab0.col0 DIV + col0 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-3182
SELECT ALL ( - col2 ) + tab0.col0 / + col0 FROM tab0
----
-32
-81
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3183
SELECT + col1 + col2 DIV ( - col0 ) FROM tab1 AS cor0
----
10
12
8

skipif mysql # not compatible
query I rowsort label-3183
SELECT + col1 + col2 / ( - col0 ) FROM tab1 AS cor0
----
10
12
8

query I rowsort
SELECT ALL col1 + col0 - - col2 AS col1 FROM tab0
----
133
143
262

query I rowsort
SELECT ALL - + col0 + + col0 * 40 FROM tab0 AS cor0
----
1365
3471
936

query I rowsort
SELECT + col2 + - ( col2 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col0 + col1 * col1 + col2 * + 50 AS col0 FROM tab1 AS cor0
----
2886
3373
4889

query I rowsort
SELECT ALL + col1 + - 58 FROM tab2 AS cor0
----
-27
-41
1

query I rowsort
SELECT ALL col1 + + ( cor0.col1 ) FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT ALL col1 * + 8 - + col0 FROM tab0 AS cor0
----
639
664
741

query I rowsort
SELECT - - cor0.col0 + + 88 FROM tab0 AS cor0
----
112
123
177

query I rowsort
SELECT ALL - col0 + 29 * 45 FROM tab2 AS cor0
----
1226
1227
1298

query I rowsort
SELECT - col1 * - col2 * + ( - col1 ) FROM tab0 cor0
----
-244068
-679042
-9409

query I rowsort
SELECT ALL col0 * 3 FROM tab0 AS cor0
----
105
267
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3195
SELECT - col1 * + CAST( NULL AS SIGNED ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3195
SELECT - col1 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + ( - cor0.col2 * + col1 ) - - col1 col0 FROM tab2 cor0
----
22630
24565
39943

query I rowsort
SELECT DISTINCT + + cor0.col1 * + 33 FROM tab0 AS cor0
----
2838
3003
3201

query I rowsort
SELECT DISTINCT + - col0 * 96 - - col2 FROM tab2 AS cor0
----
-645
-7462
-7546

query I rowsort
SELECT - + col1 + + cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL cor3.col1 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2, tab0 AS cor3
----
243 values hashing to c6425afc100dd55de8d45dec18c469ea

query I rowsort
SELECT DISTINCT + ( col1 ) + col0 + col0 FROM tab0 AS cor0
----
134
167
269

query I rowsort
SELECT - - ( + col0 ) + cor0.col2 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3203
SELECT tab2.col0 DIV col1 + col0 col2 FROM tab2
----
7
79
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3203
SELECT tab2.col0 / col1 + col0 col2 FROM tab2
----
7
79
83

query I rowsort
SELECT - 85 * - 24 AS col0 FROM tab2 AS cor0
----
2040
2040
2040

query I rowsort
SELECT + - 76 * col1 AS col1 FROM tab0 AS cor0
----
-6536
-6916
-7372

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3206
SELECT - CAST( cor0.col0 AS SIGNED ) AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

skipif mysql # not compatible
query I rowsort label-3206
SELECT - CAST ( cor0.col0 AS INTEGER ) AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT col1 + 55 * col1 FROM tab0
----
4816
5096
5432

query I rowsort
SELECT + tab0.col1 * - ( + 11 ) + - col1 FROM tab0
----
-1032
-1092
-1164

query I rowsort
SELECT + 33 * + 88 * col0 AS col0 FROM tab1 cor0
----
185856
232320
8712

query I rowsort
SELECT 45 * 41 AS col0 FROM tab1 AS cor0
----
1845
1845
1845

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 24 col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT ALL + col0 * col0 + ( + col0 ) AS col0 FROM tab1
----
12
4160
6480

query I rowsort
SELECT ALL col0 * + tab0.col1 + col1 * + ( - col1 + ( + col1 ) ) AS col1 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3214
SELECT ALL - + col1 DIV - col0 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-3214
SELECT ALL - + col1 / - col0 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT DISTINCT + - 21 + - col2 AS col0 FROM tab1 AS cor0
----
-117
-75
-78

query I rowsort
SELECT - + 16 FROM tab2 cor0 CROSS JOIN tab1 cor1
----
9 values hashing to be22ac76b42c6f7212ecc0ba7c89eb34

query I rowsort
SELECT ALL col1 * col0 * + col1 AS col2 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT - col2 * 54 + cor0.col1 FROM tab2 AS cor0
----
-1345
-1427
-2035

query I rowsort
SELECT col0 + - col2 * + col2 AS col0 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT ALL col2 * - 50 FROM tab1 AS cor0
----
-2700
-2850
-4800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col2 col0 FROM tab1 cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3222
SELECT col1 - - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3222
SELECT col1 - - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 + + ( col1 * col1 ) col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT - + col1 * - 13 AS col0 FROM tab2 AS cor0
----
221
403
767

onlyif mysql # use DIV operator for integer division
query I rowsort label-3225
SELECT 75 DIV - col2 FROM tab0
----
-2
-75
0

skipif mysql # not compatible
query I rowsort label-3225
SELECT 75 / - col2 FROM tab0
----
-2
-75
0

query I rowsort
SELECT 64 * col0 FROM tab0
----
1536
2240
5696

query I rowsort
SELECT - + col0 - cor0.col2 * col0 FROM tab2 cor0
----
-196
-2106
-3081

query I rowsort
SELECT col0 + - ( + col0 ) + col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT 10 * col2 AS col1 FROM tab0
----
10
330
820

query I rowsort
SELECT ALL 25 - col1 AS col0 FROM tab0
----
-61
-66
-72

onlyif mysql # use DIV operator for integer division
query I rowsort label-3231
SELECT col2 DIV + col2 col2 FROM tab1
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3231
SELECT col2 / + col2 col2 FROM tab1
----
1
1
1

query I rowsort
SELECT 54 * + col1 AS col2 FROM tab2
----
1674
3186
918

query I rowsort
SELECT - cor1.col0 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 08e380e50b0cb64601bc84e5254deef4

query I rowsort
SELECT col2 * 10 + cor0.col2 * + col2 * ( 52 ) FROM tab0 AS cor0
----
350468
56958
62

query I rowsort
SELECT DISTINCT col1 * + 33 FROM tab0
----
2838
3003
3201

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3236
SELECT - CAST( NULL AS SIGNED ) / col1 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3236
SELECT - CAST ( NULL AS INTEGER ) / col1 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 63 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to fc0b533c2773a0a802e1fc8317dcebf2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 - col2 * col2 col1 FROM tab2
----
-1427
-617
-698

query I rowsort
SELECT DISTINCT + col0 * + col2 - - ( col2 ) * - col1 AS col2 FROM tab1
----
-1242
3078
6432

query I rowsort
SELECT - - ( - col0 ) * 6 AS col2 FROM tab1 AS cor0
----
-18
-384
-480

query I rowsort
SELECT DISTINCT - ( col0 ) + ( + cor0.col2 ) FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT - + col1 * - col2 * col0 FROM tab2 AS cor0
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 17 * - col2 col2 FROM tab0 AS cor0
----
-1394
-17
-561

onlyif mysql # use DIV operator for integer division
query I rowsort label-3244
SELECT ALL - + 89 * col0 DIV cor0.col1 FROM tab2 cor0
----
-117
-20
-413

skipif mysql # not compatible
query I rowsort label-3244
SELECT ALL - + 89 * col0 / cor0.col1 FROM tab2 cor0
----
-117
-20
-413

query I rowsort
SELECT ALL - 33 + col1 AS col2 FROM tab1 cor0
----
-20
-23
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3246
SELECT ALL + col1 * - col1 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3246
SELECT ALL + col1 * - col1 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3247
SELECT ALL - col2 * + col2 + + CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3247
SELECT ALL - col2 * + col2 + + CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 38 * cor0.col1 AS col1 FROM tab1 AS cor0
----
-380
-494
-988

query I rowsort
SELECT DISTINCT + col1 * col2 + col2 * 8 AS col0 FROM tab1 AS cor0
----
1026
1836
2016

query I rowsort
SELECT + 8 * + col0 FROM tab0 AS cor0
----
192
280
712

query I rowsort
SELECT DISTINCT - + cor0.col2 * - ( col0 ) + col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT - + col2 * + col2 + - 20 AS col0 FROM tab2 cor0
----
-1464
-696
-749

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3253
SELECT DISTINCT + + cor0.col2 * CAST( NULL AS SIGNED ) col1 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3253
SELECT DISTINCT + + cor0.col2 * CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - + col2 - + ( col2 ) AS col2 FROM tab2 cor0
----
-52
-54
-76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3255
SELECT ALL + cor0.col2 * + CAST( col0 AS SIGNED ) * col0 FROM tab2 cor0
----
1323
158184
237158

skipif mysql # not compatible
query I rowsort label-3255
SELECT ALL + cor0.col2 * + CAST ( col0 AS INTEGER ) * col0 FROM tab2 cor0
----
1323
158184
237158

query I rowsort
SELECT + cor1.col1 AS col0 FROM tab0, tab0 cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( col0 ) * col2 * - ( 81 * - col0 ) + + col1 col2 FROM tab2 AS cor0
----
107194
12812963
19209815

query I rowsort
SELECT - 96 + + col2 + col0 AS col1 FROM tab0 cor0
----
-39
-60
75

query I rowsort
SELECT ALL - 67 * col0 * col1 AS col2 FROM tab2 AS cor0
----
-14539
-308334
-89981

query I rowsort
SELECT ALL + 91 + - 32 FROM tab2 AS cor0
----
59
59
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col2 ) * + col1 col0 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3262
SELECT DISTINCT + CAST( + ( - col0 ) AS SIGNED ) * - col0 + - col0 FROM tab1 AS cor0
----
4032
6
6320

skipif mysql # not compatible
query I rowsort label-3262
SELECT DISTINCT + CAST ( + ( - col0 ) AS INTEGER ) * - col0 + - col0 FROM tab1 AS cor0
----
4032
6
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-3263
SELECT DISTINCT - 72 * - col1 + col2 + - ( col1 ) * cor0.col0 DIV 25 AS col0 FROM tab0 AS cor0
----
6143
6311
6850

skipif mysql # not compatible
query I rowsort label-3263
SELECT DISTINCT - 72 * - col1 + col2 + - ( col1 ) * cor0.col0 / 25 AS col0 FROM tab0 AS cor0
----
6143
6311
6850

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * 93 + - col1 col2 FROM tab2 AS cor0
----
1564
2852
5428

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3265
SELECT ALL + CAST( NULL AS SIGNED ) - + col1 * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3265
SELECT ALL + CAST ( NULL AS INTEGER ) - + col1 * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 + 92 * col1 FROM tab1 cor0
----
1209
2418
930

query I rowsort
SELECT ( + 12 ) AS col2 FROM tab0
----
12
12
12

onlyif mysql # use DIV operator for integer division
query I rowsort label-3268
SELECT ALL - 42 DIV + col0 FROM tab2 AS cor0
----
-6
0
0

skipif mysql # not compatible
query I rowsort label-3268
SELECT ALL - 42 / + col0 FROM tab2 AS cor0
----
-6
0
0

query I rowsort
SELECT ALL col1 + col2 * + 34 * + col1 FROM tab0 AS cor0
----
253799
3395
96578

onlyif mysql # use DIV operator for integer division
query I rowsort label-3270
SELECT ALL + col0 DIV col1 + - 69 DIV - ( + col1 ) FROM tab1 cor0
----
11
12
2

skipif mysql # not compatible
query I rowsort label-3270
SELECT ALL + col0 / col1 + - 69 / - ( + col1 ) FROM tab1 cor0
----
11
12
2

query I rowsort
SELECT 40 + col0 * col1 AS col0 FROM tab1 AS cor0
----
1080
118
680

query I rowsort
SELECT - ( ( - col2 ) ) AS col2 FROM tab1
----
54
57
96

query I rowsort
SELECT + 41 + - ( col2 ) * - ( + col1 ) * tab0.col2 AS col1 FROM tab0
----
138
611925
93695

query I rowsort
SELECT DISTINCT - col0 * 53 FROM tab1
----
-159
-3392
-4240

query I rowsort
SELECT - 2 * tab2.col2 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 7a2e0645e15b3844a0d89b13fc219077

query I rowsort
SELECT col2 + 32 FROM tab0
----
114
33
65

query I rowsort
SELECT DISTINCT 35 + - col0 * col1 AS col1 FROM tab2 AS cor0
----
-1308
-182
-4567

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3278
SELECT DISTINCT CAST( 93 AS SIGNED ) + + cor0.col0 * - CAST( NULL AS SIGNED ) * + col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3278
SELECT DISTINCT CAST ( 93 AS INTEGER ) + + cor0.col0 * - CAST ( NULL AS INTEGER ) * + col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + cor0.col1 * 76 AS col0 FROM tab0 AS cor0
----
6536
6916
7372

query I rowsort
SELECT ( 54 ) * - col1 FROM tab0 AS cor0
----
-4644
-4914
-5238

query I rowsort
SELECT ALL + 45 * col0 + - col1 * - col0 - col2 AS col0 FROM tab1 AS cor0
----
159
3463
4544

query I rowsort
SELECT - 69 * - col0 AS col0 FROM tab2
----
483
5382
5451

query I rowsort
SELECT + ( col2 ) + - 16 FROM tab1
----
38
41
80

query I rowsort
SELECT DISTINCT col0 + - tab0.col2 + - 95 * + 83 FROM tab0
----
-7851
-7878
-7894

query I rowsort
SELECT + col0 + - col2 * ( - col1 * col2 + col0 ) AS col2 FROM tab1
----
112208
28906
75657

query I rowsort
SELECT ALL - - col1 * + col1 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT 90 * + col2 + col0 FROM tab2 cor0
----
2418
2437
3499

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col2 col2 FROM tab1, tab2, tab1 AS cor0, tab0
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT DISTINCT col0 + - col2 * + cor0.col2 * col1 AS col0 FROM tab2 AS cor0
----
-22592
-24469
-39806

query I rowsort
SELECT ALL - col2 + col1 * ( + col0 ) FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT ALL + col1 * - 83 FROM tab0 cor0
----
-7138
-7553
-8051

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3292
SELECT ALL + cor0.col2 + col0 / - 81 + col2 * CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3292
SELECT ALL + cor0.col2 + col0 / - 81 + col2 * CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * 45 AS col1 FROM tab2 cor0
----
1170
1215
1710

onlyif mysql # use DIV operator for integer division
query I rowsort label-3294
SELECT ALL + col1 DIV + col1 AS col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3294
SELECT ALL + col1 / + col1 AS col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT 25 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT DISTINCT - tab0.col1 AS col2 FROM tab0, tab1, tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + col0 * ( col0 ) + col1 + col1 * - 39 * cor0.col1 FROM tab1 AS cor0
----
-178
-26329
206

query I rowsort
SELECT - - col0 + col0 + 50 FROM tab0 AS cor0
----
120
228
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + 79 * 67 * col1 col0 FROM tab1 AS cor0
----
137644
52940
68822

query I rowsort
SELECT + + 70 * col2 AS col0 FROM tab2 AS cor0
----
1820
1890
2660

query I rowsort
SELECT + - col0 * + col0 * - col2 AS col0 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT - 22 AS col0 FROM tab2 AS cor0
----
-22
-22
-22

query I rowsort
SELECT DISTINCT - - col0 + + col0 * cor0.col2 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT 20 * + col2 FROM tab0 AS cor0
----
1640
20
660

query I rowsort
SELECT + 54 - - col2 AS col1 FROM tab2 AS cor0
----
80
81
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-3306
SELECT ALL - cor0.col0 + col1 * ( - col2 ) DIV + col2 + 67 * col1 FROM tab1 cor0
----
1713
596
778

skipif mysql # not compatible
query I rowsort label-3306
SELECT ALL - cor0.col0 + col1 * ( - col2 ) / + col2 + 67 * col1 FROM tab1 cor0
----
1713
596
778

query I rowsort
SELECT - - col2 * + col1 + col0 FROM tab2 cor0
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * col1 - ( - col0 + col1 ) * - col2 col0 FROM tab1 AS cor0
----
-2508
-5184
2646

query I rowsort
SELECT DISTINCT + tab1.col0 - cor0.col2 AS col0 FROM tab1, tab0, tab2 cor0
----
9 values hashing to f6ef2c0a6038e26ee09c3a6f94052755

query I rowsort
SELECT ALL 86 + col1 AS col1 FROM tab1
----
112
96
99

query I rowsort
SELECT ALL ( - tab2.col0 ) AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + + col0 col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT + cor0.col2 * col0 + + col2 AS col1 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT + + 58 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ef6e63aeed2581a168f07646d258f666

query I rowsort
SELECT - + col1 + cor0.col2 * 57 FROM tab1 AS cor0
----
3052
3239
5459

query I rowsort
SELECT + col1 * ( col2 ) * - col2 + + col0 FROM tab0 AS cor0
----
-611795
-62
-93630

query I rowsort
SELECT ALL + 70 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

query I rowsort
SELECT + cor0.col2 + - ( 32 ) FROM tab2 cor0
----
-5
-6
6

query I rowsort
SELECT - 24 * cor0.col2 FROM tab2 AS cor0
----
-624
-648
-912

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3320
SELECT + + CAST( NULL AS SIGNED ) * col0 + + col1 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3320
SELECT + + CAST ( NULL AS INTEGER ) * col0 + + col1 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 + col1 * col2 AS col0 FROM tab2 cor0
----
1475
629
806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3322
SELECT - + CAST( cor0.col0 AS SIGNED ) FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-3322
SELECT - + CAST ( cor0.col0 AS INTEGER ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + - ( + 66 ) * col1 FROM tab0 AS cor0
----
-5676
-6006
-6402

query I rowsort
SELECT ALL + + ( col2 ) * col1 + - col1 AS col0 FROM tab0 AS cor0
----
0
2752
7371

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor1.col1 col0 FROM tab1, tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-3326
SELECT DISTINCT ( - col0 ) + col2 DIV - col0 AS col1 FROM tab2 AS cor0
----
-10
-78
-79

skipif mysql # not compatible
query I rowsort label-3326
SELECT DISTINCT ( - col0 ) + col2 / - col0 AS col1 FROM tab2 AS cor0
----
-10
-78
-79

query I rowsort
SELECT DISTINCT + col1 * col0 * 59 + cor0.col0 * + col2 FROM tab2 AS cor0
----
12992
273546
82239

onlyif mysql # use DIV operator for integer division
query I rowsort label-3328
SELECT DISTINCT - - col2 * col1 DIV col0 FROM tab0 AS cor0
----
118
2
83

skipif mysql # not compatible
query I rowsort label-3328
SELECT DISTINCT - - col2 * col1 / col0 FROM tab0 AS cor0
----
118
2
83

query I rowsort
SELECT DISTINCT + col2 + col2 * + col2 * col0 AS col1 FROM tab2 cor0
----
114114
5130
52754

query I rowsort
SELECT DISTINCT - 97 AS col1 FROM tab1
----
-97

query I rowsort
SELECT DISTINCT 85 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
85

query I rowsort
SELECT + col0 + + 80 * + ( - col2 ) FROM tab2 AS cor0
----
-2002
-2153
-2961

onlyif mysql # use DIV operator for integer division
query I rowsort label-3333
SELECT + col1 + ( - 55 ) DIV - col1 col1 FROM tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3333
SELECT + col1 + ( - 55 ) / - col1 col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3334
SELECT col0 DIV - ( + ( - col1 ) ) AS col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-3334
SELECT col0 / - ( + ( - col1 ) ) AS col1 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT ALL - col1 * ( + col1 * - col2 ) FROM tab2
----
10982
25947
90506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col1 ) col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL - 31 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to f4b05206ee2fc0cf8007d9c3514885fa

query I rowsort
SELECT + 60 AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 1ef27a1d2784b3ab642571630db70349

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col1 ) * col0 col2 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT + col0 + col1 * + col1 * - col0 AS col2 FROM tab0 AS cor0
----
-177480
-329280
-736920

query I rowsort
SELECT DISTINCT + ( col1 ) + col0 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + - 66 * col0 FROM tab2 cor0
----
-462
-5148
-5214

query I rowsort
SELECT 76 + col1 AS col0 FROM tab2 AS cor0
----
107
135
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3344
SELECT ALL - col2 DIV col2 col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3344
SELECT ALL - col2 / col2 col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - col2 + + col2 + + col1 * col0 AS col2 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL + col0 * - col0 + - 17 FROM tab2
----
-6101
-6258
-66

query I rowsort
SELECT ALL + tab1.col0 + - tab1.col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT DISTINCT col2 + - col1 * - 54 AS col1 FROM tab1
----
1458
597
798

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - tab2.col2 col0 FROM tab2
----
0

query I rowsort
SELECT tab1.col0 * col0 + - ( 84 + + col2 ) AS col1 FROM tab1
----
-129
3955
6220

onlyif mysql # use DIV operator for integer division
query I rowsort label-3351
SELECT ALL - 32 DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3351
SELECT ALL - 32 / col2 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3352
SELECT - + cor0.col0 DIV col0 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3352
SELECT - + cor0.col0 / col0 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT + 55 * - col2 + ( col0 + col0 ) FROM tab0 AS cor0
----
-1767
-4332
15

query I rowsort
SELECT ALL + + col0 * - ( 33 ) * - col2 + ( + 72 ) * - col0 FROM tab2 AS cor0
----
5733
61308
93378

query I rowsort
SELECT col0 * - ( col0 ) + + col0 * 67 FROM tab1 cor0
----
-1040
192
192

query I rowsort
SELECT col2 * + ( - col2 + col2 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 * col1 * + col2 AS col1 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT ALL + - cor0.col2 + + col1 FROM tab1 cor0
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort
SELECT - col0 * ( 9 ) + col2 * - CAST ( 87 AS REAL ) * - cor0.col0 AS col0 FROM tab0 AS cor0
----
2730
634125
68688

query I rowsort
SELECT ALL - cor0.col2 + - ( - col0 + col2 ) AS col2 FROM tab2 AS cor0
----
-47
26
3

query I rowsort
SELECT DISTINCT + col1 + + col2 * - col0 + - col0 * cor0.col1 * + 78 AS col2 FROM tab1 AS cor0
----
-53558
-6220
-88787

query I rowsort
SELECT ALL - col2 * - col1 + - 66 AS col1 FROM tab1 cor0
----
1182
1338
504

query I rowsort
SELECT + col2 + + ( col2 + cor0.col1 ) AS col0 FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT - 57 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 0b74bbd7631afe9b2eeb9f18b9dc6505

query I rowsort
SELECT ALL col1 + - col2 * + col2 AS col2 FROM tab1
----
-2890
-3239
-9203

query I rowsort
SELECT - + cor0.col1 + 34 * + cor0.col1 FROM tab1 AS cor0
----
330
429
858

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col1 * CAST ( col1 AS REAL ) FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT 78 * col1 AS col1 FROM tab2
----
1326
2418
4602

query I rowsort
SELECT DISTINCT + col0 * - col1 * col1 AS col2 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT + tab2.col0 AS col2 FROM tab2, tab0, tab1 AS cor0, tab1
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query I rowsort
SELECT ALL + + col2 + col0 AS col0 FROM tab1 cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3372
SELECT + col0 * col2 + + cor0.col1 DIV - cor0.col1 FROM tab2 AS cor0
----
188
2027
3001

skipif mysql # not compatible
query I rowsort label-3372
SELECT + col0 * col2 + + cor0.col1 / - cor0.col1 FROM tab2 AS cor0
----
188
2027
3001

query I rowsort
SELECT - 36 FROM tab2, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to 3bcd07d22b62d2042b499253b1c13d9e

query I rowsort
SELECT tab1.col1 + - col0 * + col1 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT + col0 * col1 - 45 * - cor0.col2 FROM tab1 cor0
----
2508
3205
5360

onlyif mysql # use DIV operator for integer division
query I rowsort label-3376
SELECT ALL + col2 - - cor0.col1 DIV col1 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-3376
SELECT ALL + col2 - - cor0.col1 / col1 FROM tab0 AS cor0
----
2
34
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 16 + + col1 col0 FROM tab1 AS cor0
----
-3
-6
10

onlyif mysql # use DIV operator for integer division
query I rowsort label-3378
SELECT ALL - col0 + col2 * col1 + col0 DIV + 33 FROM tab0
----
2814
63
7375

skipif mysql # not compatible
query I rowsort label-3378
SELECT ALL - col0 + col2 * col1 + col0 / + 33 FROM tab0
----
2814
63
7375

query I rowsort
SELECT col2 + - 49 AS col0 FROM tab2
----
-11
-22
-23

query I rowsort
SELECT - col2 + tab2.col2 * tab2.col0 FROM tab2
----
162
2002
2964

query I rowsort
SELECT ALL + + col1 + col1 - cor0.col0 FROM tab1 AS cor0
----
-44
-54
49

query I rowsort
SELECT col2 * col2 + col1 FROM tab0 cor0
----
1175
6815
98

query I rowsort
SELECT ALL + - 45 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
-14
-28
14

query I rowsort
SELECT DISTINCT - - ( + col0 ) - + col1 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT ALL + ( 8 ) FROM tab2 AS cor0
----
8
8
8

query I rowsort
SELECT DISTINCT + + col1 * col0 + + col1 AS col2 FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-3387
SELECT ALL - + 91 DIV - col1 FROM tab0 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-3387
SELECT ALL - + 91 / - col1 FROM tab0 AS cor0
----
0
1
1

query I rowsort
SELECT - + 32 + col0 FROM tab0 AS cor0
----
-8
3
57

query I rowsort
SELECT ALL + 59 * col0 + col1 * - 96 FROM tab0 AS cor0
----
-3485
-6840
-7247

query I rowsort
SELECT 12 * - col1 AS col1 FROM tab2 AS cor0
----
-204
-372
-708

onlyif mysql # use DIV operator for integer division
query I rowsort label-3391
SELECT DISTINCT col1 DIV 22 - - col1 AS col2 FROM tab1 AS cor0
----
10
13
27

skipif mysql # not compatible
query I rowsort label-3391
SELECT DISTINCT col1 / 22 - - col1 AS col2 FROM tab1 AS cor0
----
10
13
27

query I rowsort
SELECT DISTINCT + ( + 80 ) + + cor0.col0 * 82 AS col2 FROM tab2 AS cor0
----
6476
654
6558

query I rowsort
SELECT + col2 + 9 AS col1 FROM tab0 cor0
----
10
42
91

query I rowsort
SELECT ALL - + ( 33 ) + cor0.col0 * + 4 * ( col1 ) AS col2 FROM tab2 AS cor0
----
18375
5339
835

query I rowsort
SELECT 87 + + col1 FROM tab2 AS cor0
----
104
118
146

query I rowsort
SELECT + 83 + - ( col1 ) AS col2 FROM tab2 AS cor0
----
24
52
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3397
SELECT DISTINCT - - CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3397
SELECT DISTINCT - - CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + 48 * tab1.col2 AS col1 FROM tab1
----
2592
2736
4608

query I rowsort
SELECT DISTINCT ( 18 ) + col0 AS col1 FROM tab1
----
21
82
98

query I rowsort
SELECT - 90 + col2 FROM tab1 AS cor0
----
-33
-36
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3401
SELECT ALL + 33 DIV 10 FROM tab0
----
3
3
3

skipif mysql # not compatible
query I rowsort label-3401
SELECT ALL + 33 / 10 FROM tab0
----
3
3
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col1 col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - col0 + - col2 * - 51 AS col0 FROM tab0 AS cor0
----
16
1659
4093

query I rowsort
SELECT + + cor0.col2 * 49 + 46 * + col2 FROM tab0 AS cor0
----
3135
7790
95

query I rowsort
SELECT ALL - col1 * + cor0.col0 + col2 AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col2 col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT + - col2 + 78 AS col1 FROM tab0 AS cor0
----
-4
45
77

query I rowsort
SELECT ALL + col0 * + col1 * 46 FROM tab0 AS cor0
----
156170
372554
94944

query I rowsort
SELECT - ( + cor0.col2 ) + + cor0.col0 * cor0.col2 AS col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT ALL - 42 FROM tab1, tab1 cor0
----
9 values hashing to 9894093f29c0defae91347934f060329

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3411
SELECT DISTINCT - col1 + CAST( NULL AS DECIMAL ) AS col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-3411
SELECT DISTINCT - col1 + CAST ( NULL AS REAL ) AS col2 FROM tab2
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3412
SELECT ALL 53 DIV col2 AS col1 FROM tab0
----
0
1
53

skipif mysql # not compatible
query I rowsort label-3412
SELECT ALL 53 / col2 AS col1 FROM tab0
----
0
1
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-3413
SELECT 81 DIV col0 - 2 FROM tab0
----
-2
0
1

skipif mysql # not compatible
query I rowsort label-3413
SELECT 81 / col0 - 2 FROM tab0
----
-2
0
1

query I rowsort
SELECT col1 + col1 + + ( + col1 ) * cor0.col0 AS col1 FROM tab2 AS cor0
----
1377
279
4720

query I rowsort
SELECT ALL + 29 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT - + 26 * col1 + 24 + col1 * col1 FROM tab0 AS cor0
----
5184
5939
6911

query I rowsort
SELECT col2 + cor0.col1 * - ( + col2 ) FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT - col0 * ( col1 ) FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3419
SELECT - col1 DIV + ( col0 * col2 ) FROM tab0 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-3419
SELECT - col1 / + ( col0 * col2 ) FROM tab0 AS cor0
----
-2
0
0

query I rowsort
SELECT + - col0 * 55 FROM tab0 AS cor0
----
-1320
-1925
-4895

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3421
SELECT - col0 + CAST( - 4 AS SIGNED ) * - col1 AS col1 FROM tab2 AS cor0
----
-11
117
158

skipif mysql # not compatible
query I rowsort label-3421
SELECT - col0 + CAST ( - 4 AS INTEGER ) * - col1 AS col1 FROM tab2 AS cor0
----
-11
117
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-3422
SELECT DISTINCT - col2 DIV 5 FROM tab0 AS cor0
----
-16
-6
0

skipif mysql # not compatible
query I rowsort label-3422
SELECT DISTINCT - col2 / 5 FROM tab0 AS cor0
----
-16
-6
0

query I rowsort
SELECT DISTINCT col1 * - ( col2 ) AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + col1 * + col0 * - 81 FROM tab2
----
-108783
-17577
-372762

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3425
SELECT DISTINCT - col2 + CAST( col2 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3425
SELECT DISTINCT - col2 + CAST ( col2 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL - col1 * + 28 FROM tab0 cor0
----
-2408
-2548
-2716

onlyif mysql # use DIV operator for integer division
query I rowsort label-3427
SELECT + + CAST( + col2 AS SIGNED ) - col2 DIV ( col1 ) FROM tab1 AS cor0
----
52
52
89

skipif mysql # not compatible
query I rowsort label-3427
SELECT + + CAST ( + col2 AS INTEGER ) - col2 / ( col1 ) FROM tab1 AS cor0
----
52
52
89

query I rowsort
SELECT + - 71 + col0 AS col0 FROM tab1 AS cor0
----
-68
-7
9

query I rowsort
SELECT + + col2 * 86 AS col2 FROM tab2 AS cor0
----
2236
2322
3268

query I rowsort
SELECT ALL - + ( col1 ) * - col2 + col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT 36 - - col1 * - col2 AS col1 FROM tab1 AS cor0
----
-1212
-1368
-534

query I rowsort
SELECT DISTINCT + + col2 + - col2 * col0 AS col1 FROM tab1 cor0
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-3433
SELECT ALL - cor0.col1 DIV 83 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3433
SELECT ALL - cor0.col1 / 83 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 33 + - 75 * col2 FROM tab1 AS cor0
----
-4017
-4242
-7167

onlyif mysql # use DIV operator for integer division
query I rowsort label-3435
SELECT DISTINCT - 63 DIV col0 + col2 * col2 AS col0 FROM tab2 AS cor0
----
1444
676
720

skipif mysql # not compatible
query I rowsort label-3435
SELECT DISTINCT - 63 / col0 + col2 * col2 AS col0 FROM tab2 AS cor0
----
1444
676
720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 43 col1 FROM tab0 AS cor0
----
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-3437
SELECT + + col1 + - ( + col2 ) DIV - col1 FROM tab1 AS cor0
----
15
20
28

skipif mysql # not compatible
query I rowsort label-3437
SELECT + + col1 + - ( + col2 ) / - col1 FROM tab1 AS cor0
----
15
20
28

query I rowsort
SELECT ALL - 39 + col2 AS col1 FROM tab1 AS cor0
----
15
18
57

query I rowsort
SELECT DISTINCT ( cor0.col2 ) * col1 + + col1 + + cor0.col2 * - col2 FROM tab2 AS cor0
----
-781
139
917

query I rowsort
SELECT - col2 - + 6 AS col0 FROM tab1
----
-102
-60
-63

query I rowsort
SELECT ALL + 64 AS col0 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

query I rowsort
SELECT + col0 + - cor0.col1 * + col0 AS col1 FROM tab1 AS cor0
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-3443
SELECT DISTINCT - - col0 + col1 DIV - 80 - col2 FROM tab2 AS cor0
----
-20
41
52

skipif mysql # not compatible
query I rowsort label-3443
SELECT DISTINCT - - col0 + col1 / - 80 - col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT - - 28 AS col0 FROM tab2 AS cor0
----
28
28
28

query I rowsort
SELECT - 19 + col0 * + cor0.col1 FROM tab0 AS cor0
----
2045
3376
8080

query I rowsort
SELECT ALL col1 * col1 + + 96 + col2 AS col1 FROM tab1 AS cor0
----
253
361
826

query I rowsort
SELECT ALL 73 * col2 FROM tab0 cor0
----
2409
5986
73

query I rowsort
SELECT DISTINCT + col1 * col1 * + col2 - col0 FROM tab1 AS cor0
----
16144
36501
5636

onlyif mysql # use DIV operator for integer division
query I rowsort label-3449
SELECT ALL + col1 DIV + cor0.col1 + + col0 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-3449
SELECT ALL + col1 / + cor0.col1 + + col0 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT ALL + + ( - col1 ) * - ( col1 ) + col0 FROM tab1 cor0
----
164
249
679

query I rowsort
SELECT DISTINCT + col0 + - col1 * col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT - 79 - + col1 * - col0 FROM tab2
----
1264
138
4523

query I rowsort
SELECT ALL + tab2.col1 + col0 * col0 * tab2.col2 AS col2 FROM tab2
----
1354
158243
237175

query I rowsort
SELECT DISTINCT + 11 + col1 * col1 AS col0 FROM tab1
----
111
180
687

query I rowsort
SELECT ALL + + 12 * + col0 + - cor0.col1 FROM tab2 AS cor0
----
53
877
931

query I rowsort
SELECT ALL 93 * col2 + + col2 FROM tab0 AS cor0
----
3102
7708
94

query I rowsort
SELECT DISTINCT col1 + - col0 * - col0 FROM tab0
----
1322
662
8012

query I rowsort
SELECT - 59 AS col1 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 1e6537c922fa953e0fd2f59430803703

query I rowsort
SELECT - col2 + + 24 * 87 AS col2 FROM tab0
----
2006
2055
2087

query I rowsort
SELECT 93 - ( - col0 ) AS col0 FROM tab1 cor0
----
157
173
96

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab2 AS cor2, tab0 AS cor3
----
3645 values hashing to 66d12da55ea14263893cfc3170a3c57e

query I rowsort
SELECT - col0 + 4 FROM tab0
----
-20
-31
-85

query I rowsort
SELECT DISTINCT + col1 * col0 + col0 AS col2 FROM tab2
----
1422
224
4680

query I rowsort
SELECT - 74 * col1 * col2 FROM tab0
----
-210012
-552188
-7178

query I rowsort
SELECT + col2 * + 27 * col2 AS col0 FROM tab1
----
248832
78732
87723

query I rowsort
SELECT ALL + col2 * tab1.col1 + + col2 AS col2 FROM tab1
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-3467
SELECT ALL ( + col2 ) * + col2 DIV ( - 1 ) + - tab1.col2 FROM tab1
----
-2970
-3306
-9312

skipif mysql # not compatible
query I rowsort label-3467
SELECT ALL ( + col2 ) * + col2 / ( - 1 ) + - tab1.col2 FROM tab1
----
-2970
-3306
-9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-3468
SELECT ( - col0 ) DIV - col1 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3468
SELECT ( - col0 ) / - col1 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT + col0 + - 38 FROM tab2 cor0
----
-31
40
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-3470
SELECT + + cor0.col0 DIV col2 - col0 AS col2 FROM tab1 AS cor0
----
-3
-63
-80

skipif mysql # not compatible
query I rowsort label-3470
SELECT + + cor0.col0 / col2 - col0 AS col2 FROM tab1 AS cor0
----
-3
-63
-80

query I rowsort
SELECT DISTINCT + ( col0 ) - + col0 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - 94 + + col2 FROM tab0 cor0
----
-12
-61
-93

query I rowsort
SELECT ALL ( + ( + cor0.col1 ) ) * - col2 * col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT ALL + 60 * 47 FROM tab0 AS cor0
----
2820
2820
2820

query I rowsort
SELECT DISTINCT + + cor0.col0 * col1 + - col2 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT DISTINCT - col0 * - 62 AS col0 FROM tab0 cor0
----
1488
2170
5518

query I rowsort
SELECT cor0.col0 * col1 * - ( - col2 ) + - ( col2 ) FROM tab2 AS cor0
----
119626
50996
5832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3478
SELECT - - cor0.col1 * - CAST( NULL AS SIGNED ) - col0 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3478
SELECT - - cor0.col1 * - CAST ( NULL AS INTEGER ) - col0 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * - ( col1 * col1 ) + ( 4 ) - - col2 * + cor0.col1 * col2 AS col2 FROM tab2 AS cor0
----
-165491
-7188
19639

query I rowsort
SELECT - - col2 + - ( col0 ) AS col0 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-3481
SELECT - - col0 + col1 DIV - col2 col2 FROM tab0 AS cor0
----
-62
22
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3481
SELECT - - col0 + col1 / - col2 col2 FROM tab0 AS cor0
----
-62
22
88

query I rowsort
SELECT DISTINCT + col1 + 16 * - 79 AS col2 FROM tab2 AS cor0
----
-1205
-1233
-1247

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 - cor0.col1 * 88 * col1 AS col2 FROM tab0 AS cor0
----
-650848
-728728
-827992

query I rowsort
SELECT - col2 + - col2 * col2 FROM tab2 cor0
----
-1482
-702
-756

onlyif mysql # use DIV operator for integer division
query I rowsort label-3486
SELECT - - col2 DIV 41 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3486
SELECT - - col2 / 41 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col2 + + ( - col2 * - col0 + col2 ) AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT 93 AS col0 FROM tab1, tab0 cor0
----
93

query I rowsort
SELECT DISTINCT - col0 - col2 * col2 FROM tab0 cor0
----
-1113
-36
-6813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 11 + col0 col2 FROM tab2 AS cor0
----
-4
67
68

query I rowsort
SELECT ALL 55 * col1 FROM tab1 AS cor0
----
1430
550
715

query I rowsort
SELECT ALL + col2 + col1 * + 37 FROM tab2 AS cor0
----
1174
2209
667

query I rowsort
SELECT ALL + + col1 + + col1 * col2 AS col2 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL - col2 * + col1 * + 91 FROM tab0 cor0
----
-258258
-679042
-8827

query I rowsort
SELECT DISTINCT - 7 + col2 AS col1 FROM tab0 cor0
----
-6
26
75

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 ALL - 85 + - tab2.col1 AS col2 FROM tab2
----
-102
-116
-144

query I rowsort
SELECT ALL col0 * col1 + + ( 31 ) FROM tab2
----
1374
248
4633

query I rowsort
SELECT col2 * - col1 + 94 * + col1 * col2 FROM tab0 AS cor0
----
263934
693966
9021

query I rowsort
SELECT - tab2.col2 + col1 * 50 + col0 FROM tab2
----
1530
3002
891

query I rowsort
SELECT DISTINCT + tab0.col1 + + col1 * - 53 * - ( - col1 ) + - tab0.col2 FROM tab0
----
-391935
-438884
-498581

query I rowsort
SELECT DISTINCT + + col2 + 88 FROM tab0 cor0
----
121
170
89

query I rowsort
SELECT ALL - 65 - - 67 * cor0.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to dc5807b4257f0f12d88dc4c89724497b

query I rowsort
SELECT - ( 53 ) AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to fee5c00ad71c23e23683a32c71fe6e7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * + 68 col1 FROM tab1
----
1768
680
884

query I rowsort
SELECT + col2 * 20 FROM tab2
----
520
540
760

query I rowsort
SELECT cor0.col2 + + cor0.col0 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-3508
SELECT col1 DIV + 81 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3508
SELECT col1 / + 81 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL col2 - col1 * 14 FROM tab1
----
-310
-83
-86

query I rowsort
SELECT DISTINCT ( 89 ) AS col0 FROM tab1
----
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3511
SELECT ALL CAST( NULL AS SIGNED ) / col0 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3511
SELECT ALL CAST ( NULL AS INTEGER ) / col0 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + ( col1 ) * - col2 * - 45 FROM tab2
----
29070
37665
69030

query I rowsort
SELECT ALL + col1 * + 23 AS col1 FROM tab0
----
1978
2093
2231

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3514
SELECT 71 + col1 * - col2 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3514
SELECT 71 + col1 * - col2 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 16 + 90 * col1 AS col0 FROM tab2 AS cor0
----
1546
2806
5326

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3516
SELECT DISTINCT + - CAST( NULL AS SIGNED ) + - col0 * - col0 / + 82 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3516
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) + - col0 * - col0 / + 82 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + - col0 + - col0 * cor0.col0 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT ALL + 74 * col0 AS col0 FROM tab1
----
222
4736
5920

query I rowsort
SELECT - + col0 * col0 * col1 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT + col2 + - col1 * + cor0.col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col1 * + col1 + - col2 * tab0.col0 * col2 col0 FROM tab0
----
-18716
-590066
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-3522
SELECT + col1 DIV - col0 AS col2 FROM tab2 cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-3522
SELECT + col1 / - col0 AS col2 FROM tab2 cor0
----
-4
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col0 + col1 + col1 * col1 col2 FROM tab0
----
7506
8461
9541

query I rowsort
SELECT + col1 * + col0 + col0 AS col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT - - col1 + col1 * col2 * cor0.col2 FROM tab2 AS cor0
----
22630
24565
39943

onlyif mysql # use DIV operator for integer division
query I rowsort label-3526
SELECT + col2 + + col0 * + col0 DIV - col0 AS col1 FROM tab2 cor0
----
-41
-52
20

skipif mysql # not compatible
query I rowsort label-3526
SELECT + col2 + + col0 * + col0 / - col0 AS col1 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT ALL + - col0 * - cor0.col0 AS col1 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT ALL + col0 + - col1 * + col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT + col1 * - cor0.col2 * cor0.col0 + col2 FROM tab0 cor0
----
-3394
-664036
-68079

query I rowsort
SELECT ALL col0 - - col0 AS col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT - 93 + col2 - col0 * - cor0.col2 FROM tab1 AS cor0
----
123
3612
7683

query I rowsort
SELECT DISTINCT col0 - + col0 * col1 * tab0.col2 AS col2 FROM tab0
----
-3360
-664029
-68088

onlyif mysql # use DIV operator for integer division
query I rowsort label-3533
SELECT + col1 DIV + col1 AS col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3533
SELECT + col1 / + col1 AS col2 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT + + col2 + col2 * - col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT + - col2 * + cor0.col1 AS col1 FROM tab2 cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-3536
SELECT + col1 DIV - cor0.col2 + + col1 - col2 FROM tab1 AS cor0
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort label-3536
SELECT + col1 / - cor0.col2 + + col1 - col2 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-3537
SELECT + + col0 + + col0 DIV - col2 AS col0 FROM tab0 AS cor0
----
0
24
88

skipif mysql # not compatible
query I rowsort label-3537
SELECT + + col0 + + col0 / - col2 AS col0 FROM tab0 AS cor0
----
0
24
88

query I rowsort
SELECT DISTINCT + cor0.col0 + - col1 * col0 FROM tab2 AS cor0
----
-1264
-210
-4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-3539
SELECT ALL - tab2.col1 DIV tab2.col1 AS col0 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3539
SELECT ALL - tab2.col1 / tab2.col1 AS col0 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - tab1.col2 * + col0 * col0 AS col0 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT - col2 AS col0 FROM tab2 WHERE NOT NULL NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT col2 + tab1.col1 * col2 AS col2 FROM tab1
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-3543
SELECT ALL col1 DIV col1 - col2 col2 FROM tab0
----
-32
-81
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3543
SELECT ALL col1 / col1 - col2 col2 FROM tab0
----
-32
-81
0

query I rowsort
SELECT col1 * + tab1.col2 * tab1.col2 FROM tab1
----
119808
32490
75816

query III rowsort
SELECT * FROM tab1 WHERE NOT ( - col1 ) BETWEEN NULL AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3546
SELECT + col1 DIV tab1.col0 + col1 * - tab1.col1 * - col2 FROM tab1
----
16224
36512
5700

skipif mysql # not compatible
query I rowsort label-3546
SELECT + col1 / tab1.col0 + col1 * - tab1.col1 * - col2 FROM tab1
----
16224
36512
5700

query I rowsort
SELECT + col1 AS col0 FROM tab0 WHERE NOT ( col2 ) NOT BETWEEN NULL AND + col0
----

query I rowsort
SELECT ALL + + col1 * col0 + col2 AS col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT 27 + + col0 AS col0 FROM tab1 AS cor0
----
107
30
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - tab1.col0 col2 FROM tab1
----
0
0
0

query I rowsort
SELECT col0 AS col2 FROM tab0 WHERE NOT ( + col1 - + col0 ) >= ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3552
SELECT ALL - col1 * col1 DIV col2 AS col1 FROM tab1
----
-1
-1
-12

skipif mysql # not compatible
query I rowsort label-3552
SELECT ALL - col1 * col1 / col2 AS col1 FROM tab1
----
-1
-1
-12

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3553
SELECT DISTINCT + col0 * cor0.col1 + + CAST( col0 AS SIGNED ) * cor0.col0 * 35 AS col1 FROM tab2 AS cor0
----
1932
217542
219778

skipif mysql # not compatible
query I rowsort label-3553
SELECT DISTINCT + col0 * cor0.col1 + + CAST ( col0 AS INTEGER ) * cor0.col0 * 35 AS col1 FROM tab2 AS cor0
----
1932
217542
219778

query I rowsort
SELECT DISTINCT col2 + col1 - tab2.col1 FROM tab2
----
26
27
38

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE col1 + col2 * col2 / + col0 BETWEEN NULL AND ( - col0 )
----

query I rowsort
SELECT ALL - col2 FROM tab0 WHERE ( NULL ) IN ( - col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3557
SELECT DISTINCT - col0 DIV + col0 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-3557
SELECT DISTINCT - col0 / + col0 FROM tab0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3558
SELECT DISTINCT - col0 * tab1.col2 DIV - col2 AS col2 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3558
SELECT DISTINCT - col0 * tab1.col2 / - col2 AS col2 FROM tab1
----
3
64
80

query I rowsort
SELECT + col0 + - tab1.col0 + col2 AS col0 FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT - tab1.col0 * + col1 * - tab1.col1 AS col1 FROM tab1
----
13520
2028
6400

query I rowsort
SELECT ALL col2 + col2 - cor0.col0 AS col0 FROM tab2 AS cor0
----
-26
-3
47

query I rowsort
SELECT DISTINCT col2 + + col2 AS col0 FROM tab2 WHERE ( - col1 ) <> col1
----
52
54
76

query I rowsort
SELECT col2 + tab0.col0 FROM tab0 WHERE NOT NULL IN ( col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3564
SELECT - tab0.col1 + col2 DIV + col2 - col2 * col0 FROM tab0
----
-131
-7388
-877

skipif mysql # not compatible
query I rowsort label-3564
SELECT - tab0.col1 + col2 / + col2 - col2 * col0 FROM tab0
----
-131
-7388
-877

query I rowsort
SELECT + tab1.col1 FROM tab1 WHERE NULL NOT IN ( - col2 + - col2 )
----

query I rowsort
SELECT DISTINCT + col1 * - col0 + col1 AS col1 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT col1 + - tab2.col2 * + col2 FROM tab2 WHERE NOT NULL IN ( tab2.col2 )
----

query I rowsort
SELECT DISTINCT col0 + + col2 * - col0 * - col2 FROM tab2
----
114155
5110
52806

query I rowsort
SELECT DISTINCT col0 + + col1 + col2 * - col0 AS col2 FROM tab2 WHERE NULL >= NULL
----

query I rowsort
SELECT tab0.col0 + col2 - col0 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT col2 AS col2 FROM tab2 AS cor0 WHERE NOT NULL IN ( + col1 )
----

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE cor0.col0 BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT col1 * - col1 AS col1 FROM tab2 WHERE col1 IN ( col0 + col1 )
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL NOT BETWEEN col2 AND col0
----

query I rowsort
SELECT - col0 + + col1 * col1 FROM tab2
----
210
3403
954

query I rowsort
SELECT DISTINCT + col0 + 63 + col0 FROM tab2
----
219
221
77

query I rowsort
SELECT + + cor0.col1 * + 69 FROM tab2 cor0
----
1173
2139
4071

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * 14 col1 FROM tab1 AS cor0
----
1120
42
896

query I rowsort
SELECT DISTINCT - col0 + + col0 * + cor0.col0 * + ( - col1 * - cor0.col1 ) AS col1 FROM tab2 AS cor0
----
1803570
21178326
47082

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( ( col2 ) ) * ( - ( - col1 ) ) col0 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT - col1 + col1 * - col1 FROM tab2 cor0
----
-306
-3540
-992

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3582
SELECT ALL + + 99 + col2 * CAST( NULL AS DECIMAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3582
SELECT ALL + + 99 + col2 * CAST ( NULL AS REAL ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - 40 AS col2 FROM tab0 AS cor0
----
40

query I rowsort
SELECT - col0 * col0 + + col0 * 60 FROM tab0 AS cor0
----
-2581
864
875

query I rowsort
SELECT + + col1 * col2 + - ( + col2 ) AS col0 FROM tab2 AS cor0
----
1508
608
810

onlyif mysql # use DIV operator for integer division
query I rowsort label-3586
SELECT DISTINCT + col0 + + ( + col2 ) * col2 DIV - ( col1 ) FROM tab2 AS cor0
----
-16
-5
67

skipif mysql # not compatible
query I rowsort label-3586
SELECT DISTINCT + col0 + + ( + col2 ) * col2 / - ( col1 ) FROM tab2 AS cor0
----
-16
-5
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-3587
SELECT ALL + cor0.col0 DIV + col1 + + cor0.col1 FROM tab1 cor0
----
16
19
26

skipif mysql # not compatible
query I rowsort label-3587
SELECT ALL + cor0.col0 / + col1 + + cor0.col1 FROM tab1 cor0
----
16
19
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * - 93 col2 FROM tab2, tab2 cor0
----
9 values hashing to 71a6d7b6bc9860893da82b5ecb91faa3

query I rowsort
SELECT - + col0 * ( + col1 ) FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT - 18 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

query I rowsort
SELECT DISTINCT - + cor0.col0 + col0 * + 92 AS col1 FROM tab2 AS cor0
----
637
7098
7189

query I rowsort
SELECT ALL - col0 + + 76 * col1 FROM tab1 cor0
----
1973
696
908

query I rowsort
SELECT - cor0.col1 * cor0.col2 * + 84 FROM tab2 AS cor0
----
-128856
-54264
-70308

query I rowsort
SELECT + - 3 * col0 FROM tab2 cor0
----
-21
-234
-237

query I rowsort
SELECT col0 + + 66 FROM tab1 AS cor0
----
130
146
69

query I rowsort
SELECT - + ( - col0 ) + - col1 * + 53 FROM tab0 AS cor0
----
-4534
-4734
-5106

query I rowsort
SELECT ALL col2 + 23 FROM tab2 AS cor0
----
49
50
61

query I rowsort
SELECT DISTINCT 48 AS col1 FROM tab2 AS cor0
----
48

query I rowsort
SELECT ALL + ( + col2 ) * + col1 * col2 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT DISTINCT + 48 + + col2 * + col0 * ( + col1 * col2 ) FROM tab1 cor0
----
2079408
227496
9584688

query I rowsort
SELECT ALL col2 * 56 AS col0 FROM tab2
----
1456
1512
2128

query I rowsort
SELECT DISTINCT 28 AS col0 FROM tab2, tab1 AS cor0
----
28

query I rowsort
SELECT + col0 + col0 * 73 AS col2 FROM tab0
----
1776
2590
6586

query I rowsort
SELECT + 89 + 40 FROM tab1 AS cor0
----
129
129
129

query I rowsort
SELECT col0 * col2 + + 69 AS col0 FROM tab2
----
2097
258
3071

query I rowsort
SELECT - col0 + ( col2 ) AS col1 FROM tab1
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-3607
SELECT + col0 * ( col1 ) + + col2 DIV + ( - 15 ) col1 FROM tab0
----
2062
3395
8094

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3607
SELECT + col0 * ( col1 ) + + col2 / + ( - 15 ) col1 FROM tab0
----
2062
3395
8094

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 24 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT ALL col1 * col0 + - col1 AS col0 FROM tab2 AS cor0
----
1326
186
4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 1 col0 FROM tab0
----
1

query I rowsort
SELECT 30 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 36 * - col1 col1 FROM tab2
----
1116
2124
612

query I rowsort
SELECT ( - 31 ) AS col0 FROM tab0
----
-31
-31
-31

query I rowsort
SELECT DISTINCT - ( 7 ) AS col2 FROM tab2
----
-7

query I rowsort
SELECT - col2 * ( cor0.col2 ) + + col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT DISTINCT - ( - col1 ) * - col1 AS col1 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT 80 * + col1 * - 35 AS col1 FROM tab0
----
-240800
-254800
-271600

query I rowsort
SELECT - 12 - cor0.col2 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to 90bf549d2c0570fa22f7c0ff7e8cf37a

query I rowsort
SELECT DISTINCT + 15 * cor0.col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
255
465
885

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3620
SELECT + col0 * CAST( - col1 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-3620
SELECT + col0 * CAST ( - col1 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3621
SELECT ALL + - col0 DIV col2 AS col0 FROM tab1 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3621
SELECT ALL + - col0 / col2 AS col0 FROM tab1 cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3622
SELECT col2 * - col2 * col2 + + col0 DIV - col1 FROM tab0 AS cor0
----
-1
-35937
-551368

skipif mysql # not compatible
query I rowsort label-3622
SELECT col2 * - col2 * col2 + + col0 / - col1 FROM tab0 AS cor0
----
-1
-35937
-551368

query I rowsort
SELECT ALL + + col2 * + col1 + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT + col2 - + col0 * - 39 FROM tab2 AS cor0
----
300
3068
3119

query I rowsort
SELECT + cor0.col0 * + col1 + col2 * col0 FROM tab2 AS cor0
----
406
4345
6630

query I rowsort
SELECT ALL - col1 + ( + 21 ) AS col1 FROM tab2 AS cor0
----
-10
-38
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( 59 + + cor0.col0 ) col1 FROM tab1, tab1 AS cor0
----
9 values hashing to c736ff918a4ab622c617f2650b532fbc

query I rowsort
SELECT DISTINCT col2 + col1 * - col1 AS col1 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT DISTINCT - - col2 * - col0 + + col1 + col1 AS col2 FROM tab2 AS cor0
----
-127
-1910
-2968

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 * - 97 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 0cabdf99b89b6403892255197f81d042

query I rowsort
SELECT ALL - col0 + - ( + ( cor0.col0 ) ) AS col0 FROM tab2 cor0
----
-14
-156
-158

query I rowsort
SELECT + col2 * + col1 + - col1 * col2 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL - tab2.col0 + + ( col2 ) FROM tab2
----
-41
-52
20

query I rowsort
SELECT DISTINCT + col1 + 1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT - + col1 * col1 + col2 + col2 FROM tab2 AS cor0
----
-213
-3429
-907

query I rowsort
SELECT ALL cor0.col0 * - ( col1 ) * cor0.col0 FROM tab1 cor0
----
-234
-40960
-83200

query I rowsort
SELECT + ( 6 ) * + col0 + 7 * + col0 FROM tab1 AS cor0
----
1040
39
832

query I rowsort
SELECT col0 * + 13 AS col0 FROM tab0
----
1157
312
455

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * col0 + - col2 * col1 col2 FROM tab0
----
-164
-2046
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3640
SELECT ALL col0 * - CAST( NULL AS SIGNED ) * ( col1 ) + - 17 + ( col1 ) AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3640
SELECT ALL col0 * - CAST ( NULL AS INTEGER ) * ( col1 ) + - 17 + ( col1 ) AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 46 * col0 - col2 * col2 FROM tab1 AS cor0
----
-12896
-3054
-6193

query I rowsort
SELECT ALL + 63 + col0 AS col2 FROM tab1 AS cor0
----
127
143
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-3643
SELECT DISTINCT 14 DIV - col0 + + col1 AS col2 FROM tab1 AS cor0
----
10
13
22

skipif mysql # not compatible
query I rowsort label-3643
SELECT DISTINCT 14 / - col0 + + col1 AS col2 FROM tab1 AS cor0
----
10
13
22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 50 * cor0.col0 + col1 * col2 col2 FROM tab0 cor0
----
11912
1847
4038

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 + + col2 - - 21 col0 FROM tab2 cor0
----
106
76
79

query I rowsort
SELECT DISTINCT - col0 * 86 * + tab0.col1 AS col1 FROM tab0
----
-177504
-291970
-696514

onlyif mysql # use DIV operator for integer division
query I rowsort label-3647
SELECT col2 DIV col1 + col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-3647
SELECT col2 / col1 + col2 FROM tab0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col1 - 17 * col1 * + col1 col2 FROM tab1 AS cor0
----
-11440
-1680
-2847

query I rowsort
SELECT DISTINCT - col2 - col2 * 72 AS col0 FROM tab0 cor0
----
-2409
-5986
-73

query I rowsort
SELECT col2 * col2 * + 81 FROM tab1 AS cor0
----
236196
263169
746496

query I rowsort
SELECT ALL 7 FROM tab1, tab2, tab0 cor0
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col2 * col1 + ( col0 ) col2 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT - 68 * tab1.col1 - 59 AS col0 FROM tab1
----
-1827
-739
-943

query I rowsort
SELECT DISTINCT - 42 * + tab0.col1 AS col0 FROM tab0
----
-3612
-3822
-4074

query I rowsort
SELECT ALL 57 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3656
SELECT DISTINCT + col2 DIV + cor0.col0 AS col1 FROM tab0 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-3656
SELECT DISTINCT + col2 / + cor0.col0 AS col1 FROM tab0 cor0
----
0
1

query I rowsort
SELECT 3 AS col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT - cor0.col0 + col1 * - col0 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT ALL + 28 * - col2 AS col0 FROM tab0 AS cor0
----
-2296
-28
-924

query I rowsort
SELECT ALL - 16 AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 71c8b08964ab47ce12158975c0ee1fd9

query I rowsort
SELECT DISTINCT + 41 * col2 FROM tab0
----
1353
3362
41

query I rowsort
SELECT - col2 * + cor0.col0 + - col1 + col2 FROM tab1 AS cor0
----
-134
-3601
-7597

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col0 * + col1 + - col2 col0 FROM tab0 AS cor0
----
-2011
-3299
-8090

skipif mysql # not compatible
query I rowsort
SELECT ALL + col0 + + CAST ( col0 AS REAL ) * col1 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + col1 * ( col0 ) AS col2 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3666
SELECT ALL + col2 * CAST( NULL AS SIGNED ) * - col1 + + col2 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3666
SELECT ALL + col2 * CAST ( NULL AS INTEGER ) * - col1 + + col2 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * ( col2 * col0 ) FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT ALL + col1 - 70 FROM tab0 AS cor0
----
16
21
27

query I rowsort
SELECT - col1 + ( - 26 ) * col2 AS col1 FROM tab1 cor0
----
-1430
-1492
-2509

query I rowsort
SELECT ALL - col0 + ( - col1 ) * + col2 FROM tab0 AS cor0
----
-132
-2862
-7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - 67 col2 FROM tab0 AS cor0
----
-32
-43
22

query I rowsort
SELECT DISTINCT + - col1 * + col1 + - col0 * + col1 AS col0 FROM tab1 cor0
----
-1209
-740
-754

query I rowsort
SELECT ALL col1 * - col2 - - ( - col0 ) AS col1 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT DISTINCT - col2 * + col2 + + 41 FROM tab2 AS cor0
----
-1403
-635
-688

query I rowsort
SELECT ALL - - col1 + col0 + col0 AS col1 FROM tab0 AS cor0
----
134
167
269

query I rowsort
SELECT ALL + col2 + - 4 FROM tab2 AS cor0
----
22
23
34

query I rowsort
SELECT DISTINCT ( - 63 ) * col1 AS col1 FROM tab2 cor0
----
-1071
-1953
-3717

query I rowsort
SELECT ALL col0 * 95 FROM tab2
----
665
7410
7505

query I rowsort
SELECT 27 + + col0 FROM tab1 AS cor0
----
107
30
91

query I rowsort
SELECT DISTINCT 45 * + col2 FROM tab2 AS cor0
----
1170
1215
1710

query I rowsort
SELECT ALL + col2 * - ( - col2 ) + + col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT ALL - + ( ( + col1 ) ) FROM tab0 cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3683
SELECT - - 86 DIV - col2 + - col0 AS col0 FROM tab1 AS cor0
----
-4
-65
-80

skipif mysql # not compatible
query I rowsort label-3683
SELECT - - 86 / - col2 + - col0 AS col0 FROM tab1 AS cor0
----
-4
-65
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col2 ) * col0 * ( col2 ) col1 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT 13 + col1 * + col1 FROM tab1 AS cor0
----
113
182
689

query I rowsort
SELECT ( - 42 ) + - col2 + col1 FROM tab2 AS cor0
----
-38
-63
-9

query I rowsort
SELECT ALL - + col2 * - 16 * - col2 FROM tab1 AS cor0
----
-147456
-46656
-51984

query I rowsort
SELECT DISTINCT - cor0.col0 + col2 * + col2 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT + ( col1 ) + - cor0.col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col1 * col0 * - col1 + 46 * col0 + - ( col1 ) AS col1 FROM tab0 AS cor0
----
-176486
-327802
-733006

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 64 * col1 col0 FROM tab0 AS cor0
----
5504
5824
6208

query I rowsort
SELECT DISTINCT cor1.col0 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3693
SELECT ALL - 89 + - col0 DIV - col1 FROM tab2 AS cor0
----
-85
-88
-89

skipif mysql # not compatible
query I rowsort label-3693
SELECT ALL - 89 + - col0 / - col1 FROM tab2 AS cor0
----
-85
-88
-89

query I rowsort
SELECT DISTINCT - ( - cor1.col0 ) FROM tab1, tab0 AS cor0, tab2 AS cor1
----
7
78
79

query I rowsort
SELECT + ( - col0 ) * + col0 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + col1 * 12 AS col0 FROM tab0
----
1032
1092
1164

query I rowsort
SELECT col1 * + col0 + + col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT + - ( col0 ) * + col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + ( ( col0 ) ) AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - col0 + 20 FROM tab1 cor0
----
-44
-60
17

query I rowsort
SELECT - 73 AS col0 FROM tab0 cor0
----
-73
-73
-73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3702
SELECT DISTINCT - CAST( 20 AS SIGNED ) AS col1 FROM tab1, tab2 AS cor0
----
-20

skipif mysql # not compatible
query I rowsort label-3702
SELECT DISTINCT - CAST ( 20 AS INTEGER ) AS col1 FROM tab1, tab2 AS cor0
----
-20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 76 * col1 col2 FROM tab0 cor0
----
6536
6916
7372

query I rowsort
SELECT DISTINCT + 8 FROM tab2 cor0
----
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-3705
SELECT DISTINCT + + 59 + + col0 DIV - col0 FROM tab2 AS cor0
----
58

skipif mysql # not compatible
query I rowsort label-3705
SELECT DISTINCT + + 59 + + col0 / - col0 FROM tab2 AS cor0
----
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-3706
SELECT ALL - 10 DIV + col0 AS col2 FROM tab1
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-3706
SELECT ALL - 10 / + col0 AS col2 FROM tab1
----
-3
0
0

query I rowsort
SELECT - - col1 * - 29 FROM tab1 AS cor0
----
-290
-377
-754

query I rowsort
SELECT + tab0.col0 + + col1 AS col2 FROM tab0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3709
SELECT DISTINCT - + col0 + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3709
SELECT DISTINCT - + col0 + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT tab0.col0 * - 54 + 18 AS col1 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to ba6cf0f5b29966679b3f05b85321e267

query I rowsort
SELECT + col1 * ( - 26 ) FROM tab2 AS cor0
----
-1534
-442
-806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3712
SELECT - + col2 * + CAST( col0 AS SIGNED ) + col2 FROM tab2 AS cor0
----
-162
-2002
-2964

skipif mysql # not compatible
query I rowsort label-3712
SELECT - + col2 * + CAST ( col0 AS INTEGER ) + col2 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-3713
SELECT + col0 + col2 DIV 86 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3713
SELECT + col0 + col2 / 86 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - cor0.col1 + 9 * col1 AS col1 FROM tab0 AS cor0
----
688
728
776

query I rowsort
SELECT + col0 + + 65 FROM tab1
----
129
145
68

query I rowsort
SELECT ( col1 ) * - col1 + col1 AS col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-3717
SELECT - - col0 + 60 DIV col2 AS col0 FROM tab0 cor0
----
25
89
95

skipif mysql # not compatible
query I rowsort label-3717
SELECT - - col0 + 60 / col2 AS col0 FROM tab0 cor0
----
25
89
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-3718
SELECT ( col1 ) * col0 DIV 14 + cor0.col0 * cor0.col2 * 34 AS col0 FROM tab0 AS cor0
----
1432
248710
27075

skipif mysql # not compatible
query I rowsort label-3718
SELECT ( col1 ) * col0 / 14 + cor0.col0 * cor0.col2 * 34 AS col0 FROM tab0 AS cor0
----
1432
248710
27075

query I rowsort
SELECT + + col1 * - col2 - - 57 * ( - col0 ) * cor0.col1 FROM tab0 AS cor0
----
-120486
-193612
-469105

query I rowsort
SELECT ALL col1 * + col1 - ( ( + col2 ) ) FROM tab2
----
251
3455
934

query I rowsort
SELECT + + col0 * col1 + - 45 * + col1 FROM tab2 AS cor0
----
-1178
1947
578

query I rowsort
SELECT + + cor0.col0 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + + 94 col1 FROM tab2 cor0
----
101
172
173

query I rowsort
SELECT ALL - col0 * 27 FROM tab0 AS cor0
----
-2403
-648
-945

query I rowsort
SELECT ALL - col1 * + 56 + - 96 AS col1 FROM tab0 AS cor0
----
-4912
-5192
-5528

query I rowsort
SELECT - col1 * + cor0.col0 + - col0 * col1 AS col1 FROM tab2 AS cor0
----
-2686
-434
-9204

query I rowsort
SELECT - col2 * - 44 + col2 AS col2 FROM tab0 AS cor0
----
1485
3690
45

query I rowsort
SELECT + 68 * + col2 AS col0 FROM tab2
----
1768
1836
2584

query I rowsort
SELECT ALL + 89 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 860d55eb6785972467218a9c3badb5ad

query I rowsort
SELECT + + cor0.col0 + 30 FROM tab1 AS cor0
----
110
33
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-3731
SELECT ALL + 62 DIV col1 AS col0 FROM tab2
----
1
2
3

skipif mysql # not compatible
query I rowsort label-3731
SELECT ALL + 62 / col1 AS col0 FROM tab2
----
1
2
3

query I rowsort
SELECT ALL - ( + 95 ) AS col1 FROM tab2 AS cor0
----
-95
-95
-95

query I rowsort
SELECT DISTINCT cor0.col1 + col0 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
-4086
-6387
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3734
SELECT + - CAST( - ( + col0 ) AS SIGNED ) FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-3734
SELECT + - CAST ( - ( + col0 ) AS INTEGER ) FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3735
SELECT CAST( NULL AS SIGNED ) AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-3735
SELECT CAST ( NULL AS INTEGER ) AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT 17 * cor0.col2 + + ( + col2 ) * col2 - + cor0.col1 FROM tab2 AS cor0
----
1059
1157
2073

onlyif mysql # use DIV operator for integer division
query I rowsort label-3737
SELECT + cor0.col2 * col1 DIV - 52 - - col0 FROM tab0 AS cor0
----
-30
-54
34

skipif mysql # not compatible
query I rowsort label-3737
SELECT + cor0.col2 * col1 / - 52 - - col0 FROM tab0 AS cor0
----
-30
-54
34

query I rowsort
SELECT DISTINCT + - cor0.col0 * col1 + - col2 * + cor0.col1 FROM tab1 AS cor0
----
-1210
-1482
-2288

query I rowsort
SELECT DISTINCT cor0.col2 * + col1 + + 86 * col2 * + col0 + 62 AS col2 FROM tab0 AS cor0
----
3169
635152
71012

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3740
SELECT 97 * col0 - CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
652
7540
7625

skipif mysql # not compatible
query I rowsort label-3740
SELECT 97 * col0 - CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
652
7540
7625

query I rowsort
SELECT DISTINCT col0 * col1 * col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL - - col0 * cor0.col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL + col1 + - col2 * - cor0.col2 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT - - 0 * + col0 + + cor0.col0 AS col2 FROM tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 + - col0 + col1 col1 FROM tab1 AS cor0
----
-111
-163
-31

query I rowsort
SELECT ( col0 ) * col1 + + 16 AS col2 FROM tab0 AS cor0
----
2080
3411
8115

query I rowsort
SELECT ALL - col0 * - col0 * - col0 FROM tab2 AS cor0
----
-343
-474552
-493039

onlyif mysql # use DIV operator for integer division
query I rowsort label-3748
SELECT + tab1.col0 DIV 34 FROM tab1
----
0
1
2

skipif mysql # not compatible
query I rowsort label-3748
SELECT + tab1.col0 / 34 FROM tab1
----
0
1
2

query I rowsort
SELECT - ( col0 ) * - col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT col0 + 5 FROM tab0
----
29
40
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-3751
SELECT ALL cor0.col1 DIV + col0 col0 FROM tab1 AS cor0
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3751
SELECT ALL cor0.col1 / + col0 col0 FROM tab1 AS cor0
----
0
0
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-3752
SELECT ALL - col2 + + 20 DIV col0 FROM tab1 AS cor0
----
-48
-57
-96

skipif mysql # not compatible
query I rowsort label-3752
SELECT ALL - col2 + + 20 / col0 FROM tab1 AS cor0
----
-48
-57
-96

query I rowsort
SELECT DISTINCT - col0 - + 55 FROM tab1 AS cor0
----
-119
-135
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-3754
SELECT col1 DIV - ( cor0.col2 ) + - cor0.col0 AS col0 FROM tab1 cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3754
SELECT col1 / - ( cor0.col2 ) + - cor0.col0 AS col0 FROM tab1 cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col2 col1 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT ALL + col2 + ( - 4 ) * col1 FROM tab1 AS cor0
----
-50
17
44

query I rowsort
SELECT DISTINCT - col0 * cor0.col0 * 69 FROM tab1 AS cor0
----
-282624
-441600
-621

query I rowsort
SELECT col1 * - 18 + - col0 * col2 * - col0 FROM tab2 AS cor0
----
157122
236852
765

query I rowsort
SELECT ALL cor0.col2 + cor0.col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 8a206af99264e378e55b667df888459e

query I rowsort
SELECT DISTINCT + cor0.col2 * col0 * - 4 FROM tab1 AS cor0
----
-14592
-30720
-648

onlyif mysql # use DIV operator for integer division
query I rowsort label-3761
SELECT DISTINCT col2 DIV col1 + col0 FROM tab1 cor0
----
5
69
87

skipif mysql # not compatible
query I rowsort label-3761
SELECT DISTINCT col2 / col1 + col0 FROM tab1 cor0
----
5
69
87

query I rowsort
SELECT cor0.col2 * + 65 AS col0 FROM tab2 AS cor0
----
1690
1755
2470

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3763
SELECT + CAST( NULL AS SIGNED ) * 78 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3763
SELECT + CAST ( NULL AS INTEGER ) * 78 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + + col1 * - ( 41 ) AS col1 FROM tab1 AS cor0
----
-1066
-410
-533

query I rowsort
SELECT col1 * 93 * - 6 + col1 AS col0 FROM tab0
----
-47902
-50687
-54029

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3766
SELECT DISTINCT + CAST( NULL AS DECIMAL ) * + col0 + - col2 * col0 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3766
SELECT DISTINCT + CAST ( NULL AS REAL ) * + col0 + - col2 * col0 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + ( - col1 ) * - col0 - cor0.col1 AS col0 FROM tab0 cor0
----
1978
3298
8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3768
SELECT ALL + ( col0 ) * col0 * - CAST( - col0 AS SIGNED ) - + col2 * + ( cor0.col2 ) AS col0 FROM tab1 AS cor0
----
-2889
258895
502784

skipif mysql # not compatible
query I rowsort label-3768
SELECT ALL + ( col0 ) * col0 * - CAST ( - col0 AS INTEGER ) - + col2 * + ( cor0.col2 ) AS col0 FROM tab1 AS cor0
----
-2889
258895
502784

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3769
SELECT ALL CAST( - 42 AS SIGNED ) FROM tab0 cor0
----
-42
-42
-42

skipif mysql # not compatible
query I rowsort label-3769
SELECT ALL CAST ( - 42 AS INTEGER ) FROM tab0 cor0
----
-42
-42
-42

query I rowsort
SELECT DISTINCT 53 * tab2.col0 FROM tab2, tab1 cor0, tab0 AS cor1
----
371
4134
4187

query I rowsort
SELECT col0 + + ( 55 ) * - tab1.col2 AS col1 FROM tab1
----
-2967
-3071
-5200

query I rowsort
SELECT DISTINCT 46 AS col2 FROM tab0, tab1 AS cor0
----
46

query I rowsort
SELECT + col1 * + col0 + + col1 AS col0 FROM tab1
----
104
1053
650

query I rowsort
SELECT DISTINCT + tab1.col2 + + tab1.col1 AS col2 FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT tab0.col0 * ( - col2 ) + tab0.col2 AS col1 FROM tab0
----
-34
-7216
-759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3776
SELECT col2 * CAST( col0 AS SIGNED ) + - col1 AS col2 FROM tab1
----
136
3638
7667

skipif mysql # not compatible
query I rowsort label-3776
SELECT col2 * CAST ( col0 AS INTEGER ) + - col1 AS col2 FROM tab1
----
136
3638
7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col1 col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 cor0 CROSS JOIN tab2, tab0 AS cor1
----
972 values hashing to 95de14c88adc44eda4adb5267fe9ebd1

query I rowsort
SELECT col2 + - tab0.col1 * + col2 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT 17 * cor0.col1 - col1 * + col1 * - col0 AS col1 FROM tab1 AS cor0
----
13741
2470
6570

query I rowsort
SELECT ALL ( + 69 ) + col1 * + col1 + col2 FROM tab0 AS cor0
----
7498
8432
9479

query I rowsort
SELECT DISTINCT + col1 + - col0 + col0 AS col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - 76 AS col2 FROM tab2
----
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-3784
SELECT ALL + col2 DIV col0 + + col2 + ( + col1 ) FROM tab1 AS cor0
----
110
67
98

skipif mysql # not compatible
query I rowsort label-3784
SELECT ALL + col2 / col0 + + col2 + ( + col1 ) FROM tab1 AS cor0
----
110
67
98

query I rowsort
SELECT + ( col0 ) * col2 AS col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + - ( cor0.col1 ) + col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT - col0 * + 71 AS col1 FROM tab0 AS cor0
----
-1704
-2485
-6319

onlyif mysql # use DIV operator for integer division
query I rowsort label-3788
SELECT ALL + 98 DIV + col1 + cor0.col1 col1 FROM tab1 AS cor0
----
19
20
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3788
SELECT ALL + 98 / + col1 + cor0.col1 col1 FROM tab1 AS cor0
----
19
20
29

query I rowsort
SELECT - + 12 + col2 FROM tab1 AS cor0
----
42
45
84

query I rowsort
SELECT + col0 + col0 * 1 AS col0 FROM tab0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col0 - + col0 col1 FROM tab0
----
86
91
97

query I rowsort
SELECT + 51 - + col1 * + ( - col0 ) FROM tab0 AS cor0
----
2115
3446
8150

query I rowsort
SELECT + - cor0.col2 + col0 * col0 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT 21 + + tab0.col0 FROM tab0
----
110
45
56

query I rowsort
SELECT + cor0.col1 + + col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT ALL col0 * 1 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3797
SELECT ALL - col1 + + 62 DIV - col2 AS col2 FROM tab0 cor0
----
-159
-87
-91

skipif mysql # not compatible
query I rowsort label-3797
SELECT ALL - col1 + + 62 / - col2 AS col2 FROM tab0 cor0
----
-159
-87
-91

query I rowsort
SELECT - col2 * - 20 AS col0 FROM tab1
----
1080
1140
1920

query I rowsort
SELECT DISTINCT col1 * + ( cor0.col1 ) FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT + col1 * 56 AS col2 FROM tab0 AS cor0
----
4816
5096
5432

query I rowsort
SELECT + col1 * - col0 + col2 * col2 FROM tab1 AS cor0
----
2609
2838
8176

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - ( - 68 ) + cor0.col2 col0 FROM tab0 AS cor0
----
-5815
-6106
-6595

query I rowsort
SELECT - col0 + col1 * col2 AS col1 FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3804
SELECT DISTINCT - + col0 - - CAST( + col2 AS SIGNED ) * + col1 FROM tab1 cor0
----
1168
1401
506

skipif mysql # not compatible
query I rowsort label-3804
SELECT DISTINCT - + col0 - - CAST ( + col2 AS INTEGER ) * + col1 FROM tab1 cor0
----
1168
1401
506

query I rowsort
SELECT ALL col0 * col1 * + col0 + ( col0 + 5 ) FROM tab2 AS cor0
----
106181
1531
359039

query I rowsort
SELECT ALL + 13 FROM tab2 AS cor0
----
13
13
13

query I rowsort
SELECT + 8 * + cor0.col2 + ( + ( - col1 ) ) FROM tab2 AS cor0
----
149
185
287

query I rowsort
SELECT 15 AS col0 FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

query I rowsort
SELECT DISTINCT - col1 + cor0.col0 + - 70 * col1 FROM tab0 cor0
----
-6082
-6372
-6852

query I rowsort
SELECT DISTINCT + col0 * - col0 + + 98 FROM tab1 AS cor0
----
-3998
-6302
89

query I rowsort
SELECT DISTINCT ( - col2 * - col0 ) + - 62 * 17 FROM tab2
----
-865
1948
974

onlyif mysql # use DIV operator for integer division
query I rowsort label-3812
SELECT - cor0.col1 + - cor0.col0 DIV col0 + col1 * - col1 FROM tab2 AS cor0
----
-307
-3541
-993

skipif mysql # not compatible
query I rowsort label-3812
SELECT - cor0.col1 + - cor0.col0 / col0 + col1 * - col1 FROM tab2 AS cor0
----
-307
-3541
-993

skipif mysql # not compatible
query I rowsort
SELECT col2 * CAST ( 94 AS REAL ) * - col1 AS col0 FROM tab2 AS cor0
----
-144196
-60724
-78678

onlyif mysql # use DIV operator for integer division
query I rowsort label-3814
SELECT + col2 DIV 1 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3814
SELECT + col2 / 1 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT - + col1 * - col1 * 7 FROM tab1 AS cor0
----
1183
4732
700

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3816
SELECT ALL CAST( NULL AS SIGNED ) / 22 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3816
SELECT ALL CAST ( NULL AS INTEGER ) / 22 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL - 38 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e8c064543bf0f2e57329db1bb0a411e3

query I rowsort
SELECT + + cor0.col0 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT + col1 * - col1 + + col0 + - cor0.col0 AS col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT 40 * col1 + col1 * + col0 FROM tab2 AS cor0
----
1457
2023
6962

query I rowsort
SELECT ALL - col2 + col2 + - col2 AS col0 FROM tab2 cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3822
SELECT tab0.col0 DIV tab0.col2 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-3822
SELECT tab0.col0 / tab0.col2 FROM tab0
----
0
1
35

query I rowsort
SELECT 46 - 58 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to e698dd57d3aac30af14ce35da434bb45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - col1 * tab1.col0 + col2 col1 FROM tab1
----
-526
-848
30

query I rowsort
SELECT - col1 * - col2 * - col2 + col2 + - col0 * col2 AS col2 FROM tab2
----
-22761
-27512
-41886

query I rowsort
SELECT col1 * - tab0.col1 * + col1 AS col2 FROM tab0
----
-636056
-753571
-912673

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3827
SELECT DISTINCT CAST( + col0 AS SIGNED ) AS col2 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3827
SELECT DISTINCT CAST ( + col0 AS INTEGER ) AS col2 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT 73 * 63 FROM tab0
----
4599

query I rowsort
SELECT DISTINCT + 47 * tab1.col2 AS col1 FROM tab1, tab2 AS cor0
----
2538
2679
4512

query I rowsort
SELECT ( 39 ) * tab1.col1 FROM tab1
----
1014
390
507

query I rowsort
SELECT 91 * 77 FROM tab2
----
7007
7007
7007

query I rowsort
SELECT DISTINCT + + 71 * 6 FROM tab2 AS cor0
----
426

query I rowsort
SELECT DISTINCT - cor0.col2 * - 32 FROM tab1 AS cor0
----
1728
1824
3072

query I rowsort
SELECT DISTINCT + ( + 65 ) FROM tab1 AS cor0
----
65

query I rowsort
SELECT ALL - 19 * + tab2.col0 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 934d1dd9454bfc140d1959bcd7db01c4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3836
SELECT DISTINCT col0 DIV - col0 FROM tab0 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-3836
SELECT DISTINCT col0 / - col0 FROM tab0 cor0
----
-1

query I rowsort
SELECT col2 + col2 - ( + col2 ) AS col0 FROM tab1 cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3838
SELECT CAST( NULL AS SIGNED ) - + col1 * tab0.col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3838
SELECT CAST ( NULL AS INTEGER ) - + col1 * tab0.col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col0 col0 FROM tab1, tab0, tab1 AS cor0, tab2
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

onlyif mysql # use DIV operator for integer division
query I rowsort label-3840
SELECT + col0 * cor0.col0 + - ( + cor0.col2 ) DIV col2 FROM tab1 cor0
----
4095
6399
8

skipif mysql # not compatible
query I rowsort label-3840
SELECT + col0 * cor0.col0 + - ( + cor0.col2 ) / col2 FROM tab1 cor0
----
4095
6399
8

query I rowsort
SELECT + + ( + col2 ) + - col1 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT + - 33 - + 41 AS col1 FROM tab2, tab0, tab0 AS cor0, tab1
----
81 values hashing to 83dc6c0e38784f5f5c6b91de33ab4ff1

query I rowsort
SELECT - + tab1.col0 AS col0 FROM tab1, tab0, tab1 cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3844
SELECT DISTINCT col0 * + CAST( NULL AS DECIMAL ) AS col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-3844
SELECT DISTINCT col0 * + CAST ( NULL AS REAL ) AS col2 FROM tab1
----
NULL

query I rowsort
SELECT + col2 + - col1 + col1 * + cor0.col2 * - col1 AS col1 FROM tab2 AS cor0
----
-10961
-25951
-90539

query I rowsort
SELECT + + col2 * + col0 - - col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT cor0.col1 * 14 + - col2 + ( ( col2 ) ) FROM tab0 AS cor0
----
1204
1274
1358

query I rowsort
SELECT - col2 * col1 + col2 * - col2 + - col2 FROM tab2 AS cor0
----
-1593
-2128
-2236

query I rowsort
SELECT + col1 + - col1 - col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT - ( cor0.col1 ) * col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT cor0.col2 * + col2 - + cor0.col0 AS col1 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT + - ( 2 ) * - col2 AS col0 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT col2 + + ( - col0 ) FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT + ( 90 ) * - col0 FROM tab0 AS cor0
----
-2160
-3150
-8010

query I rowsort
SELECT col0 + col2 * col0 AS col1 FROM tab2
----
196
2106
3081

query I rowsort
SELECT - cor0.col1 * col1 AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT 2 * col2 + col0 FROM tab0
----
253
37
90

query I rowsort
SELECT ALL col0 - - col1 * col0 * col1 FROM tab1 AS cor0
----
13600
2031
6464

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * tab2.col1 col0 FROM tab2
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-3860
SELECT DISTINCT + cor0.col0 DIV + col0 - col1 DIV - cor0.col2 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-3860
SELECT DISTINCT + cor0.col0 / + col0 - col1 / - cor0.col2 FROM tab1 AS cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-3861
SELECT DISTINCT - col1 DIV + cor0.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-3861
SELECT DISTINCT - col1 / + cor0.col2 col2 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT DISTINCT - col0 + col2 * col1 AS col0 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT ALL col1 + + col2 + col2 AS col2 FROM tab1
----
124
134
205

onlyif mysql # use DIV operator for integer division
query I rowsort label-3864
SELECT col0 DIV col1 + col1 * col2 - col0 * - col0 * + col2 col0 FROM tab0
----
1322
21846
656984

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3864
SELECT col0 / col1 + col1 * col2 - col0 * - col0 * + col2 col0 FROM tab0
----
1322
21846
656984

query I rowsort
SELECT DISTINCT + 61 + - 59 + - col0 FROM tab2
----
-5
-76
-77

query I rowsort
SELECT + tab0.col1 + + 32 AS col0 FROM tab0
----
118
123
129

onlyif mysql # use DIV operator for integer division
query I rowsort label-3867
SELECT ALL 35 + - 96 DIV col0 AS col0 FROM tab0
----
31
33
34

skipif mysql # not compatible
query I rowsort label-3867
SELECT ALL 35 + - 96 / col0 AS col0 FROM tab0
----
31
33
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-3868
SELECT ALL 52 + col0 DIV col0 + col1 FROM tab1
----
63
66
79

skipif mysql # not compatible
query I rowsort label-3868
SELECT ALL 52 + col0 / col0 + col1 FROM tab1
----
63
66
79

query I rowsort
SELECT + 71 * 80 + + col0 FROM tab1 AS cor0
----
5683
5744
5760

query I rowsort
SELECT + + col2 + col2 * + col2 AS col1 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT + + 79 + + col0 FROM tab0 AS cor0
----
103
114
168

query I rowsort
SELECT - - 82 * + col1 AS col0 FROM tab0 cor0
----
7052
7462
7954

query I rowsort
SELECT col2 * col2 * col1 + + col1 FROM tab2 AS cor0
----
22630
24565
39943

query I rowsort
SELECT ALL - col2 * + col1 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT ALL - 35 + col0 FROM tab0 AS cor0
----
-11
0
54

query I rowsort
SELECT - - ( col2 ) * - cor0.col0 + + cor0.col0 FROM tab2 AS cor0
----
-182
-1950
-2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 90 * col2 col1 FROM tab0 AS cor0
----
2970
7380
90

query I rowsort
SELECT - - col2 + cor0.col2 AS col0 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT - col0 + - col0 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT DISTINCT - col2 * col0 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT + 5 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-165
-410
-5

query I rowsort
SELECT ALL - 26 * col0 FROM tab1 AS cor0
----
-1664
-2080
-78

query I rowsort
SELECT + ( 0 ) * col2 FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * col2 + col1 col0 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT 78 * cor0.col1 * col1 + col0 * col2 * - col1 FROM tab1 AS cor0
----
-28680
-86658
48516

onlyif mysql # use DIV operator for integer division
query I rowsort label-3886
SELECT + ( col1 ) DIV - cor0.col1 + col2 DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3886
SELECT + ( col1 ) / - cor0.col1 + col2 / col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col1 * col2 * col2 FROM tab1 cor0
----
-119808
-32490
-75816

query I rowsort
SELECT DISTINCT + col1 * - col0 + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT col0 AS col1 FROM tab1 cor0 WHERE NOT NULL = ( NULL )
----

query I rowsort
SELECT ALL col0 * + col2 * col2 + - col2 * - col1 AS col0 FROM tab1 cor0
----
10152
208506
738528

query I rowsort
SELECT ALL - col2 FROM tab0 AS cor0 WHERE NULL NOT IN ( - col2 * col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col0 * - col2 col0 FROM tab2 cor0
----
-114076
-5103
-52728

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NULL NOT IN ( col2 )
----

query I rowsort
SELECT col2 * - tab1.col1 + + col1 AS col2 FROM tab1
----
-1235
-1378
-560

query III rowsort
SELECT * FROM tab2 WHERE NOT col0 NOT IN ( + col1 * col0 + + col2 )
----

query I rowsort
SELECT ALL + col2 * cor0.col1 + col2 AS col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + col1 FROM tab2 AS cor0 WHERE NULL <= NULL
----

query I rowsort
SELECT ALL cor0.col1 * col1 * col1 FROM tab0 AS cor0
----
636056
753571
912673

query I rowsort
SELECT DISTINCT - cor0.col0 * col2 + col0 AS col0 FROM tab0 AS cor0
----
-7209
-768
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 col2 FROM tab1 WHERE NOT - col2 * + col2 * col2 + + col1 IN ( col2 * - col0 + col2 )
----
3
64
80

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-3902
SELECT col0 DIV tab1.col1 AS col2 FROM tab1
----
0
6
6

skipif mysql # not compatible
query I rowsort label-3902
SELECT col0 / tab1.col1 AS col2 FROM tab1
----
0
6
6

query I rowsort
SELECT DISTINCT + col1 * + col1 * col0 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT + col0 + col1 + tab2.col0 FROM tab2
----
175
215
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 col2 FROM tab0 WHERE NOT ( NULL ) = ( col2 )
----

query I rowsort
SELECT tab2.col1 + - col2 * col1 - col2 AS col0 FROM tab2
----
-1501
-667
-833

query I rowsort
SELECT DISTINCT tab2.col2 * tab2.col1 * + col1 FROM tab2
----
10982
25947
90506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + col2 * col0 col0 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT DISTINCT + col0 FROM tab2 WHERE ( NULL ) NOT IN ( col1 * tab2.col0 )
----

query I rowsort
SELECT DISTINCT - col1 + col1 * - col2 AS col2 FROM tab1
----
-1261
-1430
-580

query III rowsort
SELECT ALL * FROM tab2 WHERE ( NULL ) <= col0
----

query I rowsort
SELECT ALL + col0 * - col2 + + col2 - + col1 * col2 * - col0 FROM tab2 cor0
----
117650
48070
5697

query I rowsort
SELECT ALL - cor0.col1 + + col2 * col2 FROM tab2 AS cor0
----
1427
617
698

onlyif mysql # use DIV operator for integer division
query I rowsort label-3914
SELECT ALL + col1 * col2 DIV col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-3914
SELECT ALL + col1 * col2 / col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + + col0 + - col0 + col1 * + col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT tab1.col2 * col1 - col0 * col0 AS col2 FROM tab1
----
-3526
-5152
1395

query I rowsort
SELECT DISTINCT col0 FROM tab2 WHERE NOT NULL <= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + col0 * + col1 + col2 col2 FROM tab0
----
2121
3431
8270

query I rowsort
SELECT ALL - col0 * - col1 + - col2 * + col1 AS col1 FROM tab2
----
-620
3068
697

query I rowsort
SELECT - col1 * col2 + + col0 + + col0 FROM tab0
----
-27
-2790
-7284

query I rowsort
SELECT DISTINCT col0 * - col2 + + col1 * col2 AS col2 FROM tab1
----
-3078
-6432
1242

query I rowsort
SELECT - col0 + col1 - col1 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3923
SELECT DISTINCT - - cor0.col2 DIV - col1 FROM tab2 AS cor0
----
-2
0

skipif mysql # not compatible
query I rowsort label-3923
SELECT DISTINCT - - cor0.col2 / - col1 FROM tab2 AS cor0
----
-2
0

query I rowsort
SELECT + + col2 * col1 - + col0 * col2 AS col1 FROM tab2 AS cor0
----
-2356
-494
648

query I rowsort
SELECT DISTINCT + col1 * + col0 + col1 * col2 FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT - col1 - - cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + tab2.col1 + + col2 * col2 * col2 FROM tab2 WHERE NOT ( NULL ) NOT BETWEEN NULL AND - col1 * + col2
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3928
SELECT tab1.col2 * CAST( + col1 AS SIGNED ) AS col1 FROM tab1
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-3928
SELECT tab1.col2 * CAST ( + col1 AS INTEGER ) AS col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT col0 * 0 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 * 7 AS col2 FROM tab2
----
-119
-217
-413

query I rowsort
SELECT DISTINCT col1 * 18 AS col1 FROM tab0
----
1548
1638
1746

query I rowsort
SELECT - 68 + - col1 FROM tab2 cor0
----
-127
-85
-99

query I rowsort
SELECT + 28 - + tab2.col0 AS col2 FROM tab2
----
-50
-51
21

query I rowsort
SELECT - - col0 + + 36 AS col2 FROM tab1 AS cor0
----
100
116
39

query I rowsort
SELECT DISTINCT 49 * col2 AS col2 FROM tab0 AS cor0
----
1617
4018
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col1 col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT ALL + + col0 + + col0 * - ( cor0.col0 ) * - col1 FROM tab0 AS cor0
----
118860
49560
720900

query I rowsort
SELECT DISTINCT col2 * col0 + - 34 AS col2 FROM tab0 AS cor0
----
1
7264
758

query I rowsort
SELECT ALL - 71 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

onlyif mysql # use DIV operator for integer division
query I rowsort label-3940
SELECT - - 23 DIV + col2 FROM tab0 AS cor0
----
0
0
23

skipif mysql # not compatible
query I rowsort label-3940
SELECT - - 23 / + col2 FROM tab0 AS cor0
----
0
0
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col2 * cor0.col1 col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-3942
SELECT 9 DIV col0 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3942
SELECT 9 / col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT + - 18 AS col2 FROM tab2 AS cor0
----
-18
-18
-18

query I rowsort
SELECT 29 * col1 FROM tab2 AS cor0
----
1711
493
899

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 + + col1 - - col1 col2 FROM tab1 AS cor0
----
30
39
78

query I rowsort
SELECT + + col2 * + ( - col1 ) AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT col0 + ( + 72 ) AS col2 FROM tab0 cor0
----
107
161
96

query I rowsort
SELECT DISTINCT + col2 * 47 * + col1 + + col0 FROM tab1 AS cor0
----
26854
58736
65991

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col0 + col2 col0 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT DISTINCT - - col1 * cor0.col2 + col1 AS col2 FROM tab1 AS cor0
----
1261
1430
580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 - ( - cor0.col2 + + col1 ) col0 FROM tab2 AS cor0
----
100
3
45

query I rowsort
SELECT col0 * - col1 + col0 AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col2 ) * cor0.col0 col1 FROM tab2 cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 33 col2 FROM tab0 AS cor0
----
33
33
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-3955
SELECT + 13 DIV ( col1 ) + + col1 FROM tab1 AS cor0
----
11
14
26

skipif mysql # not compatible
query I rowsort label-3955
SELECT + 13 / ( col1 ) + + col1 FROM tab1 AS cor0
----
11
14
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col2 * ( col0 * + col1 ) + + col1 * col2 col1 FROM tab1 AS cor0
----
-2808
-35910
-98592

query I rowsort
SELECT - col2 - - tab2.col0 AS col2 FROM tab2
----
-20
41
52

query I rowsort
SELECT DISTINCT + col0 + + 46 * - col1 - col2 FROM tab1
----
-1247
-453
-614

query I rowsort
SELECT DISTINCT - + 72 + cor0.col0 FROM tab2 AS cor0
----
-65
6
7

query I rowsort
SELECT col0 + + 14 FROM tab2
----
21
92
93

query I rowsort
SELECT + cor0.col1 * + col2 + 4 AS col1 FROM tab2 AS cor0
----
1538
650
841

query I rowsort
SELECT DISTINCT + 25 AS col1 FROM tab1, tab2 cor0
----
25

query I rowsort
SELECT ( + col1 + - ( + tab0.col0 ) ) FROM tab0
----
2
62
62

query I rowsort
SELECT + 18 + + tab0.col1 FROM tab0
----
104
109
115

query I rowsort
SELECT - - 22 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT ( + col2 + col1 ) AS col0 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL - + 41 + - col2 AS col0 FROM tab0 AS cor0
----
-123
-42
-74

query I rowsort
SELECT DISTINCT - col2 * cor0.col1 * col0 + - col2 - cor0.col0 FROM tab1 AS cor0
----
-100016
-36601
-4269

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 36 col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 4d1892e880125dc90345721151acb22c

query I rowsort
SELECT ALL ( col2 ) + col1 * - ( + col1 ) FROM tab2 cor0
----
-251
-3455
-934

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 63 col1 FROM tab2 AS cor0
----
-63

query I rowsort
SELECT 90 * - col2 + col1 AS col0 FROM tab2
----
-2281
-2399
-3403

query I rowsort
SELECT DISTINCT 43 * col1 AS col1 FROM tab0
----
3698
3913
4171

query I rowsort
SELECT DISTINCT + ( col2 + - ( - col2 ) ) FROM tab0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col2 * 8 col0 FROM tab1 AS cor0
----
435
520
848

query I rowsort
SELECT tab2.col1 + col1 * + col2 AS col0 FROM tab2
----
1593
663
868

query I rowsort
SELECT col1 + cor0.col1 * - cor0.col2 FROM tab2 AS cor0
----
-1475
-629
-806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3978
SELECT + CAST( NULL AS SIGNED ) * - 72 FROM tab0, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3978
SELECT + CAST ( NULL AS INTEGER ) * - 72 FROM tab0, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3979
SELECT DISTINCT col1 * - CAST( + 27 AS SIGNED ) - - col0 col2 FROM tab0
----
-2298
-2368
-2584

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3979
SELECT DISTINCT col1 * - CAST ( + 27 AS INTEGER ) - - col0 col2 FROM tab0
----
-2298
-2368
-2584

query I rowsort
SELECT - col0 + + col2 + ( - tab1.col1 + + 2 ) AS col2 FROM tab1
----
-15
27
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3981
SELECT + col0 / + CAST( NULL AS SIGNED ) AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3981
SELECT + col0 / + CAST ( NULL AS INTEGER ) AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 31 AS col1 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to c6c8eebeb1a59f7c046402e25630c0ac

query I rowsort
SELECT ALL 13 FROM tab0, tab2 cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query I rowsort
SELECT ALL - tab1.col0 * 58 FROM tab1
----
-174
-3712
-4640

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3985
SELECT - CAST( col1 AS SIGNED ) + - cor0.col0 * - col0 AS col0 FROM tab1 AS cor0
----
-17
4086
6387

skipif mysql # not compatible
query I rowsort label-3985
SELECT - CAST ( col1 AS INTEGER ) + - cor0.col0 * - col0 AS col0 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT - - col1 + + 80 + + col0 FROM tab0 AS cor0
----
190
212
260

query I rowsort
SELECT + 76 + + col2 AS col0 FROM tab1
----
130
133
172

query I rowsort
SELECT DISTINCT + - col0 * - cor0.col0 + col2 AS col0 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT ALL 99 + ( col2 ) FROM tab2 AS cor0
----
125
126
137

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 38 * + ( col0 * 22 ) + col0 - col2 col2 FROM tab1 AS cor0
----
2457
53511
66864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 54 * - 65 col1 FROM tab2 AS cor0
----
-3510
-3510
-3510

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3992
SELECT DISTINCT - CAST( - 57 AS SIGNED ) FROM tab0 AS cor0
----
57

skipif mysql # not compatible
query I rowsort label-3992
SELECT DISTINCT - CAST ( - 57 AS INTEGER ) FROM tab0 AS cor0
----
57

query I rowsort
SELECT DISTINCT - col1 + col2 + + cor0.col1 * ( + 8 + - col0 ) * cor0.col2 FROM tab1 AS cor0
----
-31873
-89773
7048

query I rowsort
SELECT DISTINCT - + 28 + cor0.col1 * cor0.col1 AS col1 FROM tab0 cor0
----
7368
8253
9381

query I rowsort
SELECT ALL + tab0.col0 * 11 * - col0 + - 31 * 75 + tab0.col2 * + col2 FROM tab0
----
-15799
-7572
-82732

query I rowsort
SELECT DISTINCT + col0 + - col0 + col2 AS col0 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT - 35 AS col0 FROM tab0, tab0 AS cor0
----
-35

query I rowsort
SELECT ALL col2 + 82 + - col0 AS col0 FROM tab1
----
133
75
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3999
SELECT ALL + + CAST( col2 AS SIGNED ) * col1 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-3999
SELECT ALL + + CAST ( col2 AS INTEGER ) * col1 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 * + col1 + col0 + - 52 col1 FROM tab0 AS cor0
----
7368
8318
9392

query I rowsort
SELECT col1 - 43 AS col2 FROM tab1 cor0
----
-17
-30
-33

query I rowsort
SELECT ALL 71 * col2 AS col1 FROM tab1 cor0
----
3834
4047
6816

query I rowsort
SELECT - - ( col0 ) + - 52 + - ( col0 ) AS col2 FROM tab0 AS cor0
----
-52
-52
-52

query I rowsort
SELECT + 88 * + cor0.col2 + col0 AS col1 FROM tab1 AS cor0
----
4755
5080
8528

query I rowsort
SELECT + col1 * + col1 + + 59 - col0 AS col1 FROM tab1 AS cor0
----
148
732
95

query I rowsort
SELECT DISTINCT 30 * cor0.col2 FROM tab0 AS cor0
----
2460
30
990

query I rowsort
SELECT - ( + col0 ) * ( + ( + col1 ) ) FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT col0 + col0 - + 82 FROM tab0 AS cor0
----
-12
-34
96

query I rowsort
SELECT ALL 40 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-14
-17
-56

onlyif mysql # use DIV operator for integer division
query I rowsort label-4010
SELECT DISTINCT + - col2 + col2 DIV col0 AS col1 FROM tab1 AS cor0
----
-36
-57
-95

skipif mysql # not compatible
query I rowsort label-4010
SELECT DISTINCT + - col2 + col2 / col0 AS col1 FROM tab1 AS cor0
----
-36
-57
-95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4011
SELECT ALL - - CAST( NULL AS DECIMAL ) AS col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4011
SELECT ALL - - CAST ( NULL AS REAL ) AS col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - 22 AS col0 FROM tab0, tab0 cor0
----
9 values hashing to fae46f8148b02964f7145eb6ed5819f9

query I rowsort
SELECT - col0 * + col1 + - 13 AS col2 FROM tab0 AS cor0
----
-2077
-3408
-8112

query I rowsort
SELECT + - 4 + - col0 * col2 FROM tab1 AS cor0
----
-166
-3652
-7684

onlyif mysql # use DIV operator for integer division
query I rowsort label-4015
SELECT - col2 DIV col0 - col0 AS col0 FROM tab1 cor0
----
-21
-64
-81

skipif mysql # not compatible
query I rowsort label-4015
SELECT - col2 / col0 - col0 AS col0 FROM tab1 cor0
----
-21
-64
-81

query I rowsort
SELECT DISTINCT tab2.col2 + 16 FROM tab2
----
42
43
54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4017
SELECT ALL - col1 * - CAST( NULL AS SIGNED ) + col2 * + col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4017
SELECT ALL - col1 * - CAST ( NULL AS INTEGER ) + col2 * + col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + col2 + - 12 FROM tab2 cor0
----
-38
-39
-50

onlyif mysql # use DIV operator for integer division
query I rowsort label-4019
SELECT DISTINCT - cor0.col0 + CAST( + 79 AS SIGNED ) * col1 * col1 + - cor0.col2 * col1 DIV col1 FROM tab0 AS cor0
----
584227
654028
743275

skipif mysql # not compatible
query I rowsort label-4019
SELECT DISTINCT - cor0.col0 + CAST ( + 79 AS INTEGER ) * col1 * col1 + - cor0.col2 * col1 / col1 FROM tab0 AS cor0
----
584227
654028
743275

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + cor0.col0 col2 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL - col1 * col1 * - col1 FROM tab0 AS cor0
----
636056
753571
912673

query I rowsort
SELECT - ( cor1.col0 ) AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT DISTINCT + + col2 * + ( col2 ) * - col1 FROM tab0 AS cor0
----
-611884
-93654
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4024
SELECT ALL + col1 + - CAST( 33 + col2 * + 63 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-2026
-5108
1

skipif mysql # not compatible
query I rowsort label-4024
SELECT ALL + col1 + - CAST ( 33 + col2 * + 63 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-2026
-5108
1

query I rowsort
SELECT + col1 * 25 AS col1 FROM tab0 AS cor0
----
2150
2275
2425

query I rowsort
SELECT DISTINCT + col1 * - ( col2 ) AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 - - col0 col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + col0 - col1 * col1 FROM tab0 AS cor0
----
-7372
-8192
-9374

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab1, tab0 cor1, tab0 cor2, tab1 cor3
----
3645 values hashing to 71d467ba3372dfdd21847af1687c92e7

query I rowsort
SELECT ( - cor0.col2 ) * - col1 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - col0 - 66 FROM tab0 cor0
----
-101
-155
-90

query I rowsort
SELECT + - col2 - + col0 AS col2 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4033
SELECT - - col1 + 10 DIV + col1 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-4033
SELECT - - col1 + 10 / + col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT 54 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 81150d59d6c3fc48b4ef5a4a5495bc7a

query I rowsort
SELECT DISTINCT - 53 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
-53

query I rowsort
SELECT - col1 + 93 AS col2 FROM tab1 AS cor0
----
67
80
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - ( 6 ) * + col2 col2 FROM tab2 AS cor0
----
-193
-215
-245

query I rowsort
SELECT + col1 * + 37 + cor0.col1 AS col1 FROM tab2 AS cor0
----
1178
2242
646

query I rowsort
SELECT - tab2.col1 + - col2 + - tab2.col0 * tab2.col1 FROM tab2 WHERE NOT ( - col0 * + col1 ) NOT IN ( col0 )
----

query III rowsort
SELECT ALL * FROM tab0 WHERE ( + col0 ) IN ( + col1 * + tab0.col2 )
----

query I rowsort
SELECT DISTINCT col1 - - col0 AS col0 FROM tab0
----
110
132
180

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT ( col1 * - col2 * col1 ) BETWEEN col2 AND ( NULL )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT col1 + - col1 * - col0 FROM tab2
----
1360
248
4661

query I rowsort
SELECT col1 * - col2 / - col0 AS col0 FROM tab0 WHERE NULL > - col0 * col1
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT + col1 * col1 * - col2 NOT BETWEEN col1 * col2 AND col0 * + col0
----

query I rowsort
SELECT DISTINCT + col1 FROM tab1 WHERE NOT NULL = NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 7 * + col0 col2 FROM tab2 AS cor0
----
-49
-546
-553

query I rowsort
SELECT - - 0 + col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + col2 * cor0.col2 * - col1 FROM tab2 cor0
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT + - 93 * - col0 - + 90 FROM tab2 AS cor0
----
561
7164
7257

query I rowsort
SELECT ALL col0 * col0 FROM tab0 WHERE col0 * - col1 IN ( + col2 + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4052
SELECT + col2 - - col2 DIV col1 col0 FROM tab1
----
103
56
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4052
SELECT + col2 - - col2 / col1 col0 FROM tab1
----
103
56
62

query I rowsort
SELECT DISTINCT - + ( - col2 ) + 62 AS col0 FROM tab0 AS cor0
----
144
63
95

query I rowsort
SELECT + + ( + col0 ) AS col1 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4055
SELECT + + col1 + ( + col2 ) DIV col0 FROM tab1 cor0
----
10
14
44

skipif mysql # not compatible
query I rowsort label-4055
SELECT + + col1 + ( + col2 ) / col0 FROM tab1 cor0
----
10
14
44

query I rowsort
SELECT ALL + col0 + + col0 * + col0 FROM tab0 AS cor0
----
1260
600
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * 1 col2 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4058
SELECT - + cor0.col0 DIV 88 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4058
SELECT - + cor0.col0 / 88 FROM tab0 cor0
----
-1
0
0

query I rowsort
SELECT + col2 + + ( col2 ) * - col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT - ( col2 ) * - 17 AS col0 FROM tab2
----
442
459
646

query I rowsort
SELECT ALL - 14 * col2 AS col1 FROM tab1
----
-1344
-756
-798

query I rowsort
SELECT - 65 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 4ca93c42a91c7dff917e7b7090ba9e57

query I rowsort
SELECT + 67 * 6 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to ccdd50b3df2b7e7214d9b33545877a2a

query I rowsort
SELECT - cor0.col1 * cor0.col2 + + col1 AS col2 FROM tab2 AS cor0
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-4065
SELECT - 57 * + 89 + - col1 DIV 39 FROM tab2 AS cor0
----
-5073
-5073
-5074

skipif mysql # not compatible
query I rowsort label-4065
SELECT - 57 * + 89 + - col1 / 39 FROM tab2 AS cor0
----
-5073
-5073
-5074

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4066
SELECT CAST( NULL AS SIGNED ) - 88 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4066
SELECT CAST ( NULL AS INTEGER ) - 88 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor1.col2 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
-1
-33
-82

query I rowsort
SELECT - col1 * - col1 + - col0 * col2 + col2 FROM tab0 AS cor0
----
1065
6637
9375

query I rowsort
SELECT ALL + ( + col2 ) * col1 * col2 AS col2 FROM tab2 cor0
----
22599
24548
39884

query I rowsort
SELECT DISTINCT + 55 + col2 + + col2 * col0 AS col0 FROM tab1 AS cor0
----
271
3760
7831

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 73 col1 FROM tab0 AS cor0
----
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-4072
SELECT DISTINCT - col0 DIV - col1 + 85 + col0 AS col1 FROM tab1 AS cor0
----
155
171
88

skipif mysql # not compatible
query I rowsort label-4072
SELECT DISTINCT - col0 / - col1 + 85 + col0 AS col1 FROM tab1 AS cor0
----
155
171
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * ( - col1 ) col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL - col0 * 28 + + tab0.col2 FROM tab0
----
-2410
-639
-979

query I rowsort
SELECT DISTINCT + + col1 * col2 * + col1 AS col1 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT ALL - - col1 * col0 + - 47 AS col2 FROM tab2 AS cor0
----
1296
170
4555

onlyif mysql # use DIV operator for integer division
query I rowsort label-4077
SELECT - - col2 * + ( 48 ) + + col2 DIV col2 col2 FROM tab1 AS cor0
----
2593
2737
4609

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4077
SELECT - - col2 * + ( 48 ) + + col2 / col2 col2 FROM tab1 AS cor0
----
2593
2737
4609

query I rowsort
SELECT col0 + ( + col2 * + col2 ) FROM tab1 cor0
----
2919
3313
9296

query I rowsort
SELECT + + col0 * 6 - - 45 AS col0 FROM tab0 AS cor0
----
189
255
579

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4080
SELECT ALL - col2 + CAST( NULL AS SIGNED ) + col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4080
SELECT ALL - col2 + CAST ( NULL AS INTEGER ) + col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col0 + - cor0.col1 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT + + col1 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
54
57
96

query I rowsort
SELECT DISTINCT col2 + + 43 * + col2 AS col0 FROM tab1
----
2376
2508
4224

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4085
SELECT DISTINCT - + 67 * + col2 - CAST( NULL AS SIGNED ) * col1 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4085
SELECT DISTINCT - + 67 * + col2 - CAST ( NULL AS INTEGER ) * col1 AS col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 93 col1 FROM tab1 AS cor0
----
93
93
93

query I rowsort
SELECT DISTINCT + ( 1 ) FROM tab2, tab0 AS cor0
----
1

query I rowsort
SELECT ALL col2 + cor0.col2 * - col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT ALL 94 * col1 + col1 FROM tab0 AS cor0
----
8170
8645
9215

query I rowsort
SELECT DISTINCT 43 FROM tab1 cor0
----
43

query I rowsort
SELECT DISTINCT + col2 + cor0.col1 + ( + 1 ) FROM tab0 AS cor0
----
120
174
99

query I rowsort
SELECT + col2 * + col0 - - col1 * - 5 * col2 FROM tab2
----
-228
-3996
-5642

query I rowsort
SELECT - col0 * - col0 - + tab2.col0 FROM tab2
----
42
6006
6162

query I rowsort
SELECT + col1 - tab0.col1 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT 13 + col0 FROM tab1
----
16
77
93

query I rowsort
SELECT - col0 + + tab1.col1 * ( ( col2 ) ) - - 18 * col0 FROM tab1
----
1455
1658
2608

query I rowsort
SELECT DISTINCT + ( col2 ) * 11 AS col0 FROM tab0
----
11
363
902

onlyif mysql # use DIV operator for integer division
query I rowsort label-4098
SELECT col0 DIV col2 + - ( - col0 ) * + col2 AS col1 FROM tab1
----
162
3649
7680

skipif mysql # not compatible
query I rowsort label-4098
SELECT col0 / col2 + - ( - col0 ) * + col2 AS col1 FROM tab1
----
162
3649
7680

query I rowsort
SELECT ( col1 ) + - ( - 79 ) * col1 AS col0 FROM tab1
----
1040
2080
800

query I rowsort
SELECT DISTINCT cor0.col0 * + 54 - + cor1.col2 * - 61 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
9 values hashing to fd5e64981e815d0d3fbd7e08250c451d

query I rowsort
SELECT ( - cor0.col1 + + tab2.col2 ) FROM tab2, tab0 AS cor0
----
9 values hashing to 76b1d8548f1c7689108ab6ccf6c2516e

query I rowsort
SELECT 91 * cor0.col0 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 19c8b1036a90459dfc9565efcd72d83d

onlyif mysql # use DIV operator for integer division
query I rowsort label-4103
SELECT + col1 DIV 65 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4103
SELECT + col1 / 65 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4104
SELECT DISTINCT - col0 DIV cor0.col1 AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4104
SELECT DISTINCT - col0 / cor0.col1 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col1 + 11 * + col0 FROM tab0 AS cor0
----
1070
350
482

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * - 22 + 65 * + col1 - - 50 col2 FROM tab0 AS cor0
----
4007
5112
5585

query I rowsort
SELECT ALL 90 * - col2 AS col1 FROM tab0
----
-2970
-7380
-90

query I rowsort
SELECT 80 * + tab2.col1 + col1 AS col2 FROM tab2
----
1377
2511
4779

query I rowsort
SELECT col1 * col1 + + col2 * tab1.col2 AS col0 FROM tab1
----
3349
3592
9385

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4110
SELECT + ( col0 * col1 ) + CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4110
SELECT + ( col0 * col1 ) + CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4111
SELECT - CAST( NULL AS SIGNED ) + col1 / + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4111
SELECT - CAST ( NULL AS INTEGER ) + col1 / + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 91 + col1 FROM tab1 AS cor0
----
101
104
117

query I rowsort
SELECT DISTINCT + col0 * - col0 * col2 + + 81 FROM tab2 AS cor0
----
-1242
-158103
-237077

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( - col0 AS REAL ) AS col2 FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4115
SELECT - + cor0.col2 DIV + 60 col1 FROM tab1 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4115
SELECT - + cor0.col2 / + 60 col1 FROM tab1 AS cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4116
SELECT DISTINCT + - 47 DIV 81 AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4116
SELECT DISTINCT + - 47 / 81 AS col0 FROM tab0 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4117
SELECT DISTINCT + col1 * + col1 + + CAST( + col2 AS SIGNED ) FROM tab0 AS cor0
----
7429
8363
9410

skipif mysql # not compatible
query I rowsort label-4117
SELECT DISTINCT + col1 * + col1 + + CAST ( + col2 AS INTEGER ) FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT ALL + col2 + cor0.col1 - + ( col0 * cor0.col2 ) FROM tab0 AS cor0
----
-673
-7125
63

query I rowsort
SELECT ALL - + cor0.col0 + - col0 AS col1 FROM tab2 AS cor0
----
-14
-156
-158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + cor0.col2 * - ( + 15 ) col2 FROM tab0 AS cor0
----
-1319
-50
-519

query I rowsort
SELECT ALL - - col0 - cor0.col2 AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT - + 76 AS col2 FROM tab0 AS cor0
----
-76
-76
-76

query I rowsort
SELECT ALL col0 * col1 * 15 - - col0 FROM tab2 cor0
----
20224
3262
69108

query I rowsort
SELECT ALL - - 59 * - col1 FROM tab2 AS cor0
----
-1003
-1829
-3481

query I rowsort
SELECT + cor0.col2 * - cor0.col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT + col1 * 75 AS col2 FROM tab0 AS cor0
----
6450
6825
7275

query I rowsort
SELECT + col0 + col1 * + col1 AS col2 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT + ( col1 ) + - col0 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL + cor0.col1 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + col2 + ( - col1 ) AS col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL ( 47 ) * + tab1.col1 AS col2 FROM tab1
----
1222
470
611

query I rowsort
SELECT + - ( + col2 ) FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT ALL - 6 AS col2 FROM tab1 cor0
----
-6
-6
-6

query I rowsort
SELECT + - 20 AS col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to eb3a66728062963cccbd15bd2f5c9eee

query I rowsort
SELECT col0 - + ( - col2 ) FROM tab1
----
121
176
57

query I rowsort
SELECT DISTINCT + col0 * - tab0.col1 * tab0.col2 FROM tab0
----
-3395
-664118
-68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4137
SELECT CAST( + col1 * col0 AS SIGNED ) FROM tab1
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-4137
SELECT CAST ( + col1 * col0 AS INTEGER ) FROM tab1
----
1040
640
78

query I rowsort
SELECT col0 + ( - col0 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + 21 + col0 + - 41 FROM tab2
----
-13
58
59

query I rowsort
SELECT + col1 + 30 AS col1 FROM tab0 cor0
----
116
121
127

query I rowsort
SELECT DISTINCT - 32 * col0 FROM tab1
----
-2048
-2560
-96

query I rowsort
SELECT DISTINCT + ( + col0 ) AS col2 FROM tab1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4143
SELECT col1 + - col0 + col2 DIV col2 FROM tab1
----
-53
-66
24

skipif mysql # not compatible
query I rowsort label-4143
SELECT col1 + - col0 + col2 / col2 FROM tab1
----
-53
-66
24

query I rowsort
SELECT - 30 AS col2 FROM tab2
----
-30
-30
-30

query I rowsort
SELECT + col2 + + 9 AS col1 FROM tab0 AS cor0
----
10
42
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4146
SELECT - col0 * + CAST( NULL AS SIGNED ) * col1 + - col2 * cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4146
SELECT - col0 * + CAST ( NULL AS INTEGER ) * col1 + - col2 * cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col2 * ( col1 ) + - cor0.col2 FROM tab1 AS cor0
----
-1344
-1458
-627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - ( cor0.col1 ) ) col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL 3 - - col1 FROM tab0 AS cor0
----
100
89
94

query I rowsort
SELECT DISTINCT - - col0 * + 67 AS col2 FROM tab0 AS cor0
----
1608
2345
5963

query I rowsort
SELECT ALL + - col1 * + col1 + - cor0.col0 FROM tab0 AS cor0
----
-7420
-8370
-9444

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - 14 col0 FROM tab0
----
-1246
-336
-490

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 98 col2 FROM tab2, tab0, tab1 cor0, tab1
----
98

query I rowsort
SELECT cor0.col2 + 18 * + col1 FROM tab1 AS cor0
----
237
330
522

query I rowsort
SELECT col2 * cor0.col1 + + col0 AS col0 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT + + 16 * cor0.col2 FROM tab0 AS cor0
----
1312
16
528

query I rowsort
SELECT ( - 42 ) FROM tab0 AS cor0
----
-42
-42
-42

query I rowsort
SELECT DISTINCT - 18 + cor0.col2 * col1 FROM tab2 AS cor0
----
1516
628
819

query I rowsort
SELECT ALL col1 * col2 + col0 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
132
14760
3630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 * - ( - col0 ) col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - + col1 * + 50 + col1 * cor0.col2 FROM tab0 cor0
----
-1462
-4753
2912

query I rowsort
SELECT DISTINCT - 72 * 22 * col2 FROM tab2 AS cor0
----
-41184
-42768
-60192

onlyif mysql # use DIV operator for integer division
query I rowsort label-4163
SELECT cor0.col2 + col0 * 74 * - col0 + col0 DIV - col0 FROM tab2 cor0
----
-3600
-450191
-461797

skipif mysql # not compatible
query I rowsort label-4163
SELECT cor0.col2 + col0 * 74 * - col0 + col0 / - col0 FROM tab2 cor0
----
-3600
-450191
-461797

query I rowsort
SELECT + col0 + col0 * + ( col1 ) + - cor0.col2 AS col2 FROM tab1 AS cor0
----
1024
27
647

query I rowsort
SELECT + 87 * + col0 AS col0 FROM tab2 cor0
----
609
6786
6873

query I rowsort
SELECT - cor0.col0 * 88 + - col1 AS col2 FROM tab2 AS cor0
----
-647
-6923
-6969

query I rowsort
SELECT DISTINCT - col1 * - col2 + 94 * - col1 FROM tab2 AS cor0
----
-2077
-4012
-952

query I rowsort
SELECT + col2 * + 87 AS col0 FROM tab2 AS cor0
----
2262
2349
3306

query I rowsort
SELECT DISTINCT - 63 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
-63

query I rowsort
SELECT - cor0.col2 + - 82 AS col1 FROM tab2 AS cor0
----
-108
-109
-120

query I rowsort
SELECT ALL - col0 * + 49 FROM tab2 AS cor0
----
-343
-3822
-3871

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4172
SELECT DISTINCT + - col2 * CAST( NULL AS SIGNED ) * - cor0.col0 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4172
SELECT DISTINCT + - col2 * CAST ( NULL AS INTEGER ) * - cor0.col0 FROM tab1 cor0
----
NULL

query I rowsort
SELECT DISTINCT + 94 * - col2 AS col2 FROM tab0
----
-3102
-7708
-94

query I rowsort
SELECT ALL 4 * - col1 AS col1 FROM tab1
----
-104
-40
-52

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( - col2 AS REAL ) * + col0 + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT + 85 * col2 FROM tab2 cor0
----
2210
2295
3230

query I rowsort
SELECT ALL + 86 * - 23 AS col2 FROM tab0 AS cor0
----
-1978
-1978
-1978

query I rowsort
SELECT DISTINCT cor0.col0 * + 80 FROM tab1 AS cor0
----
240
5120
6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + 19 * - col2 col2 FROM tab1 AS cor0
----
-1026
-1728
-972

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col2 col2 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 91 + - 61 * col1 col2 FROM tab1 AS cor0
----
-1677
-701
-884

onlyif mysql # use DIV operator for integer division
query I rowsort label-4182
SELECT DISTINCT + tab2.col1 DIV - col0 AS col0 FROM tab2
----
-4
0

skipif mysql # not compatible
query I rowsort label-4182
SELECT DISTINCT + tab2.col1 / - col0 AS col0 FROM tab2
----
-4
0

query I rowsort
SELECT ALL 92 + col0 FROM tab1 cor0
----
156
172
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-4184
SELECT + - 82 DIV + 28 AS col0 FROM tab1 AS cor0
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-4184
SELECT + - 82 / + 28 AS col0 FROM tab1 AS cor0
----
-2
-2
-2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col0 + - col0 col2 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT ALL 42 * cor0.col2 AS col0 FROM tab0 AS cor0
----
1386
3444
42

query I rowsort
SELECT DISTINCT - - 98 + + col1 AS col0 FROM tab1 AS cor0
----
108
111
124

query I rowsort
SELECT ALL - 3 + - cor1.col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 588aa17a6e3f077c26bc2f44edf37d02

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 85 + col0 * - col1 col2 FROM tab1 AS cor0
----
-555
-955
7

query I rowsort
SELECT ALL - - col2 + + col2 * + col0 AS col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT - - 88 + - col0 * - 92 FROM tab2 AS cor0
----
7264
732
7356

query I rowsort
SELECT DISTINCT + - col1 + + col2 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT col0 + col0 + 68 AS col1 FROM tab2 AS cor0
----
224
226
82

query I rowsort
SELECT ( 2 ) AS col2 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( col0 ) + + ( + cor0.col0 + col0 ) col1 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + col2 + - col0 * 64 AS col2 FROM tab1 AS cor0
----
-138
-4039
-5024

query I rowsort
SELECT DISTINCT - col0 * - col1 * cor0.col2 AS col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT + 18 * - col2 FROM tab0 AS cor0
----
-1476
-18
-594

query I rowsort
SELECT ALL col1 + 51 * 94 + + col2 * + col0 AS col2 FROM tab2 AS cor0
----
5014
6881
7813

query I rowsort
SELECT DISTINCT col0 * col1 + 75 FROM tab1 cor0
----
1115
153
715

query I rowsort
SELECT ALL + col0 + + 89 * - 57 * col1 + - col2 FROM tab0 AS cor0
----
-436287
-461636
-492047

onlyif mysql # use DIV operator for integer division
query I rowsort label-4202
SELECT DISTINCT - col1 * tab0.col2 DIV col1 AS col1 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-4202
SELECT DISTINCT - col1 * tab0.col2 / col1 AS col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT + - cor0.col0 + 74 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1337
-2301
-4444

query I rowsort
SELECT - col0 * col1 + + col1 + + col1 AS col2 FROM tab1 AS cor0
----
-1014
-26
-620

query I rowsort
SELECT 2 AS col2 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

query I rowsort
SELECT DISTINCT col1 + + col0 * col1 + + col0 FROM tab0 AS cor0
----
2174
3527
8279

query I rowsort
SELECT + col0 * ( + col1 ) + col2 AS col0 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT ALL - col1 * 90 + - cor0.col0 + - col0 FROM tab2 AS cor0
----
-1688
-2804
-5466

query I rowsort
SELECT ALL - col0 * cor0.col0 + + cor0.col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT 96 AS col2 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to f1d978c2d5bfc6f26e0907ac777be83e

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( col0 AS REAL ) * cor0.col2 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-4212
SELECT ALL - ( 36 ) DIV col1 AS col2 FROM tab1 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-4212
SELECT ALL - ( 36 ) / col1 AS col2 FROM tab1 AS cor0
----
-1
-2
-3

query I rowsort
SELECT + col2 + - cor0.col1 * col2 FROM tab2 cor0
----
-1508
-608
-810

query I rowsort
SELECT 50 AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 314aace40e704c20a6be06204a329f80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4215
SELECT DISTINCT - CAST( NULL AS SIGNED ) + 97 FROM tab0, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4215
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + 97 FROM tab0, tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4216
SELECT col1 * + CAST( NULL AS SIGNED ) + col2 * + tab1.col1 col0 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4216
SELECT col1 * + CAST ( NULL AS INTEGER ) + col2 * + tab1.col1 col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * ( cor0.col1 ) * + col2 + + 50 * cor0.col0 AS col2 FROM tab0 cor0
----
5145
668568
69312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( col0 ) + cor0.col0 col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + cor1.col2 AS col2 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL - ( col1 ) + - col1 AS col1 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT - - ( + col1 ) + + cor0.col1 FROM tab0 AS cor0
----
172
182
194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * - 49 + cor0.col2 col1 FROM tab2 AS cor0
----
-1492
-2865
-795

query I rowsort
SELECT DISTINCT - col2 * col1 + - col0 * col2 AS col0 FROM tab0 AS cor0
----
-132
-14760
-3630

query I rowsort
SELECT + col1 + 94 FROM tab1
----
104
107
120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 46 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT - - 93 AS col1 FROM tab2 AS cor0
----
93
93
93

query I rowsort
SELECT + 62 + col2 AS col1 FROM tab0
----
144
63
95

query I rowsort
SELECT col2 + - 68 * col0 AS col2 FROM tab2
----
-449
-5278
-5334

query I rowsort
SELECT col0 + + 83 * col1 AS col2 FROM tab2
----
1490
2580
4975

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + col0 col0 FROM tab0 AS cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * + 29 col2 FROM tab0 AS cor0
----
2494
2639
2813

onlyif mysql # use DIV operator for integer division
query I rowsort label-4232
SELECT - ( + col1 ) DIV + 7 + - col1 + col2 col0 FROM tab2
----
-41
-8
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4232
SELECT - ( + col1 ) / + 7 + - col1 + col2 col0 FROM tab2
----
-41
-8
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + ( col0 ) col1 FROM tab2 AS cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col0 * 59 col2 FROM tab1
----
-215232
-453120
-9558

query I rowsort
SELECT tab2.col2 * - col0 * 36 FROM tab2
----
-108072
-6804
-73008

query I rowsort
SELECT ALL ( col1 ) + ( col2 ) AS col2 FROM tab1
----
109
67
80

query I rowsort
SELECT ALL 38 AS col2 FROM tab2, tab1, tab0 cor0
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

query I rowsort
SELECT ALL col0 * - tab0.col2 + + col0 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT ALL + 48 + + col0 FROM tab2
----
126
127
55

query I rowsort
SELECT ( cor0.col2 ) FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT DISTINCT - col2 * ( + cor0.col0 ) + + col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT - + col2 + 2 * - col2 * col1 AS col0 FROM tab0 AS cor0
----
-15006
-195
-5709

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4243
SELECT DISTINCT - col1 * - CAST( NULL AS SIGNED ) AS col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4243
SELECT DISTINCT - col1 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4244
SELECT - - col1 + + CAST( 46 + col2 * - cor0.col2 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-1381
-571
-652

skipif mysql # not compatible
query I rowsort label-4244
SELECT - - col1 + + CAST ( 46 + col2 * - cor0.col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-1381
-571
-652

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - cor0.col1 + col1 * col1 col1 FROM tab0 AS cor0
----
7343
8272
9313

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 + ( + col2 ) * col1 col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL col0 * - col2 + - col2 AS col2 FROM tab1 AS cor0
----
-216
-3705
-7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-4248
SELECT ALL - col2 + col1 DIV col1 AS col0 FROM tab0 AS cor0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-4248
SELECT ALL - col2 + col1 / col1 AS col0 FROM tab0 AS cor0
----
-32
-81
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4249
SELECT + - col0 * - CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-4249
SELECT + - col0 * - CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col0 + 22 * - ( - col1 ) AS col1 FROM tab2 cor0
----
1220
295
675

onlyif mysql # use DIV operator for integer division
query I rowsort label-4251
SELECT DISTINCT - + cor0.col2 + col0 DIV + col1 AS col0 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-4251
SELECT DISTINCT - + cor0.col2 + col0 / + col1 AS col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + col0 * + col1 + 5 * + col0 AS col0 FROM tab2 AS cor0
----
1738
252
4992

onlyif mysql # use DIV operator for integer division
query I rowsort label-4253
SELECT + 94 * + col1 DIV col1 + + col0 AS col0 FROM tab1 AS cor0
----
158
174
97

skipif mysql # not compatible
query I rowsort label-4253
SELECT + 94 * + col1 / col1 + + col0 AS col0 FROM tab1 AS cor0
----
158
174
97

query I rowsort
SELECT 33 AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 76da8bc7cae18ecf856438f872430c80

query I rowsort
SELECT - 6 + cor0.col2 FROM tab1 AS cor0
----
48
51
90

query I rowsort
SELECT + - 6 AS col1 FROM tab2 cor0
----
-6
-6
-6

query I rowsort
SELECT + + ( col0 ) * col1 + 86 FROM tab0 AS cor0
----
2150
3481
8185

query I rowsort
SELECT col1 + 20 FROM tab0 cor0
----
106
111
117

query I rowsort
SELECT col1 * 78 AS col1 FROM tab1 AS cor0
----
1014
2028
780

query I rowsort
SELECT 38 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

query I rowsort
SELECT + col2 * col0 * 3 AS col0 FROM tab1 AS cor0
----
10944
23040
486

onlyif mysql # use DIV operator for integer division
query I rowsort label-4262
SELECT + - cor0.col2 DIV col2 FROM tab0 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4262
SELECT + - cor0.col2 / col2 FROM tab0 cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col2 * + 94 FROM tab1 cor0
----
5076
5358
9024

query I rowsort
SELECT DISTINCT ( tab0.col0 ) * + col2 AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT - ( - col1 ) - cor0.col2 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL col0 * col0 + + col0 AS col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT - + ( - col2 ) + + col1 AS col2 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4268
SELECT ALL - tab1.col0 + ( - 30 ) DIV - tab1.col2 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-4268
SELECT ALL - tab1.col0 + ( - 30 ) / - tab1.col2 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT ALL + col2 + col2 * - tab2.col2 * - tab2.col2 + + ( - 82 ) AS col0 FROM tab2
----
17520
19628
54828

query I rowsort
SELECT ALL col0 * 99 + - 25 FROM tab0
----
2351
3440
8786

query I rowsort
SELECT + - col0 + - ( - cor0.col2 ) FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT col2 * ( col2 ) * - col0 - 76 FROM tab1 AS cor0
----
-208012
-737356
-8824

query I rowsort
SELECT - col1 + 39 FROM tab0 AS cor0
----
-47
-52
-58

query I rowsort
SELECT - col1 + cor0.col0 * - col2 AS col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT DISTINCT tab2.col1 AS col0 FROM tab2, tab1 AS cor0, tab1, tab1 AS cor1
----
17
31
59

query I rowsort
SELECT DISTINCT + + ( + col2 ) * col0 + - col2 AS col2 FROM tab2 cor0
----
162
2002
2964

query I rowsort
SELECT + ( + col2 ) + col2 * + 64 AS col0 FROM tab0 AS cor0
----
2145
5330
65

query I rowsort
SELECT ALL - + col1 * - col0 + col2 AS col1 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT ALL cor0.col0 - col2 * - 57 FROM tab2 AS cor0
----
1546
1560
2245

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 ) * col1 + + 35 * cor0.col2 col2 FROM tab0 AS cor0
----
10969
3219
3430

query I rowsort
SELECT ALL + - 89 * col1 FROM tab1 cor0
----
-1157
-2314
-890

query I rowsort
SELECT DISTINCT - - 42 + + col2 * + ( - col2 + col2 ) * - col0 FROM tab1 AS cor0
----
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-4283
SELECT - col1 + col1 DIV + col0 FROM tab2 AS cor0
----
-17
-27
-59

skipif mysql # not compatible
query I rowsort label-4283
SELECT - col1 + col1 / + col0 FROM tab2 AS cor0
----
-17
-27
-59

query I rowsort
SELECT 36 * ( col2 ) FROM tab0
----
1188
2952
36

query I rowsort
SELECT ALL + 32 - - col1 * col1 * col0 FROM tab2
----
22863
271550
6759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4286
SELECT + CAST( col0 * + col0 AS SIGNED ) + - ( - 95 ) + + tab2.col1 AS col0 FROM tab2
----
175
6238
6353

skipif mysql # not compatible
query I rowsort label-4286
SELECT + CAST ( col0 * + col0 AS INTEGER ) + - ( - 95 ) + + tab2.col1 AS col0 FROM tab2
----
175
6238
6353

query I rowsort
SELECT - 64 - col2 FROM tab1
----
-118
-121
-160

onlyif mysql # use DIV operator for integer division
query I rowsort label-4288
SELECT + ( cor0.col0 ) DIV - ( col1 ) - col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-4288
SELECT + ( cor0.col0 ) / - ( col1 ) - col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT 70 * col1 + 28 * col0 FROM tab1
----
1904
2492
3150

query I rowsort
SELECT - col1 * + col1 * 84 + col0 * col0 AS col0 FROM tab1 AS cor0
----
-4304
-56775
-7796

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * 19 col0 FROM tab2
----
494
513
722

query I rowsort
SELECT - cor1.col2 * - cor1.col1 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to 7623ebe74018211e6a4da91fc8c37d6d

query I rowsort
SELECT ALL - col2 + - col2 * - col0 AS col1 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT - - col1 * 81 AS col1 FROM tab2 AS cor0
----
1377
2511
4779

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - tab0.col2 col1 FROM tab0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4296
SELECT DISTINCT - col2 DIV col1 - + col1 AS col2 FROM tab1
----
-15
-20
-28

skipif mysql # not compatible
query I rowsort label-4296
SELECT DISTINCT - col2 / col1 - + col1 AS col2 FROM tab1
----
-15
-20
-28

query I rowsort
SELECT DISTINCT col2 - 94 AS col2 FROM tab2
----
-56
-67
-68

query I rowsort
SELECT ALL - tab2.col2 - ( col1 * + col2 ) FROM tab2
----
-1560
-684
-864

query I rowsort
SELECT ALL + 47 - + col1 FROM tab0
----
-39
-44
-50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4300
SELECT DISTINCT + CAST( NULL AS SIGNED ) - - 72 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-4300
SELECT DISTINCT + CAST ( NULL AS INTEGER ) - - 72 FROM tab1
----
NULL

query I rowsort
SELECT ALL 96 - + 42 * col1 AS col1 FROM tab0
----
-3516
-3726
-3978

query I rowsort
SELECT DISTINCT + 18 * - col1 FROM tab2 cor0
----
-1062
-306
-558

query I rowsort
SELECT + col0 * col1 * - col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + 48 col0 FROM tab0 AS cor0
----
-38
-43
-49

query I rowsort
SELECT + col2 + - ( col2 ) * + col2 * + 29 FROM tab1
----
-267168
-84510
-94164

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 67 col2 FROM tab0, tab0 cor0, tab1 AS cor1
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4307
SELECT CAST( + ( + col1 ) AS SIGNED ) * col2 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-4307
SELECT CAST ( + ( + col1 ) AS INTEGER ) * col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - 33 + ( + col1 ) FROM tab1 AS cor0
----
-20
-23
-7

query I rowsort
SELECT ALL 49 + tab1.col2 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 8923edc07b7b33eca718ba7f411534a1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4310
SELECT ALL + CAST( ( col1 ) AS SIGNED ) DIV col1 + + col1 * + cor0.col1 col2 FROM tab0 AS cor0
----
7397
8282
9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4310
SELECT ALL + CAST ( ( col1 ) AS INTEGER ) / col1 + + col1 * + cor0.col1 col2 FROM tab0 AS cor0
----
7397
8282
9410

query I rowsort
SELECT DISTINCT + 78 + + col0 * - col1 FROM tab1 AS cor0
----
-562
-962
0

query I rowsort
SELECT ALL ( cor0.col1 ) + col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - 63 + col2 * + col2 FROM tab1 AS cor0
----
2853
3186
9153

query I rowsort
SELECT 27 * + col2 FROM tab0 cor0
----
2214
27
891

onlyif mysql # use DIV operator for integer division
query I rowsort label-4315
SELECT ALL + col0 DIV col2 + - col2 * - 92 AS col0 FROM tab1 AS cor0
----
4968
5245
8832

skipif mysql # not compatible
query I rowsort label-4315
SELECT ALL + col0 / col2 + - col2 * - 92 AS col0 FROM tab1 AS cor0
----
4968
5245
8832

query I rowsort
SELECT - 33 + col0 FROM tab1 AS cor0
----
-30
31
47

query I rowsort
SELECT ALL 27 * col0 + col1 * + col1 * + ( + col0 ) AS col1 FROM tab0 cor0
----
178152
330260
739412

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4318
SELECT ALL + CAST( col0 AS SIGNED ) * col0 FROM tab2 AS cor0
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-4318
SELECT ALL + CAST ( col0 AS INTEGER ) * col0 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-4319
SELECT DISTINCT + 4 DIV ( col0 * ( cor0.col0 ) ) + col0 + + col0 * col1 FROM tab0 AS cor0
----
2088
3430
8188

skipif mysql # not compatible
query I rowsort label-4319
SELECT DISTINCT + 4 / ( col0 * ( cor0.col0 ) ) + col0 + + col0 * col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT + + col1 * - 11 + + cor0.col1 AS col2 FROM tab0 AS cor0
----
-860
-910
-970

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col2 + + col1 col1 FROM tab1
----
109
67
80

query I rowsort
SELECT ALL - tab1.col2 + + tab1.col1 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + col0 + tab2.col1 AS col2 FROM tab2
----
137
38
96

query I rowsort
SELECT DISTINCT - - col1 * col2 AS col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT ALL 91 AS col2 FROM tab1 AS cor0
----
91
91
91

query I rowsort
SELECT - col0 + col0 - col0 AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT col0 * + col0 * - 59 AS col1 FROM tab0 AS cor0
----
-33984
-467339
-72275

onlyif mysql # use DIV operator for integer division
query I rowsort label-4328
SELECT ALL - 25 * cor0.col1 * col2 + 76 DIV col2 AS col0 FROM tab0 AS cor0
----
-186550
-2349
-70948

skipif mysql # not compatible
query I rowsort label-4328
SELECT ALL - 25 * cor0.col1 * col2 + 76 / col2 AS col0 FROM tab0 AS cor0
----
-186550
-2349
-70948

query I rowsort
SELECT ALL - cor0.col0 - - cor0.col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 66 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to a408108d423d7784b7d610cb779e515a

query I rowsort
SELECT ALL + col1 * + 57 AS col2 FROM tab1 AS cor0
----
1482
570
741

query I rowsort
SELECT DISTINCT + cor0.col0 * 60 + 39 AS col0 FROM tab1 AS cor0
----
219
3879
4839

query I rowsort
SELECT DISTINCT - col0 - 40 * + 52 FROM tab0 cor0
----
-2104
-2115
-2169

onlyif mysql # use DIV operator for integer division
query I rowsort label-4334
SELECT - + cor0.col2 + col0 DIV + col2 FROM tab0 AS cor0
----
-33
-81
34

skipif mysql # not compatible
query I rowsort label-4334
SELECT - + cor0.col2 + col0 / + col2 FROM tab0 AS cor0
----
-33
-81
34

query I rowsort
SELECT - col1 * col2 + - col2 AS col1 FROM tab0
----
-2871
-7544
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4336
SELECT ALL - col0 DIV cor0.col1 + - col0 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-4336
SELECT ALL - col0 / cor0.col1 + - col0 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT + col0 + col1 * 53 FROM tab0 AS cor0
----
4582
4912
5176

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4338
SELECT + col2 * + CAST( NULL AS SIGNED ) + 80 * col2 * 55 + - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4338
SELECT + col2 * + CAST ( NULL AS INTEGER ) + 80 * col2 * 55 + - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4339
SELECT ALL + col0 + CAST( col0 AS SIGNED ) * cor0.col1 col2 FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4339
SELECT ALL + col0 + CAST ( col0 AS INTEGER ) * cor0.col1 col2 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT + cor0.col1 * + col2 + - cor0.col2 * - col0 AS col2 FROM tab1 AS cor0
----
1566
4218
8928

query I rowsort
SELECT col2 + + 42 FROM tab1 cor0
----
138
96
99

query I rowsort
SELECT DISTINCT cor0.col2 * + col2 - col2 * col0 AS col1 FROM tab0 AS cor0
----
-34
-574
297

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col0 * - CAST ( - col0 * + col1 AS REAL ) AS col2 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT + col1 + 35 FROM tab2 cor0
----
52
66
94

query I rowsort
SELECT cor0.col1 * 74 + col1 FROM tab0 AS cor0
----
6450
6825
7275

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4346
SELECT + col0 * CAST( - col2 AS SIGNED ) + - col0 AS col2 FROM tab0 AS cor0
----
-70
-7387
-816

skipif mysql # not compatible
query I rowsort label-4346
SELECT + col0 * CAST ( - col2 AS INTEGER ) + - col0 AS col2 FROM tab0 AS cor0
----
-70
-7387
-816

onlyif mysql # use DIV operator for integer division
query I rowsort label-4347
SELECT ALL + col1 + ( col1 ) DIV + col0 FROM tab2 AS cor0
----
17
35
59

skipif mysql # not compatible
query I rowsort label-4347
SELECT ALL + col1 + ( col1 ) / + col0 FROM tab2 AS cor0
----
17
35
59

query I rowsort
SELECT - cor0.col0 * ( 81 ) FROM tab2 cor0
----
-567
-6318
-6399

query I rowsort
SELECT DISTINCT - col0 + - 52 AS col1 FROM tab1 AS cor0
----
-116
-132
-55

query I rowsort
SELECT - cor0.col1 * - col1 + + col1 AS col0 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT col2 + 77 AS col2 FROM tab2 cor0
----
103
104
115

query I rowsort
SELECT DISTINCT - 50 * + col1 + - col0 * + col1 FROM tab2 AS cor0
----
-1767
-2193
-7552

query I rowsort
SELECT ALL 77 + + 84 AS col0 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to 224757d88ffd580705ec0718cf055dee

query I rowsort
SELECT + ( col0 ) + ( col2 * col0 ) FROM tab2
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-4355
SELECT ALL + col2 * col1 + col2 DIV + col1 + + tab2.col1 FROM tab2
----
1593
665
868

skipif mysql # not compatible
query I rowsort label-4355
SELECT ALL + col2 * col1 + col2 / + col1 + + tab2.col1 FROM tab2
----
1593
665
868

query I rowsort
SELECT col1 * col0 + + col0 AS col0 FROM tab2 AS cor0
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4357
SELECT col2 * col1 DIV + col2 AS col0 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4357
SELECT col2 * col1 / + col2 AS col0 FROM tab1
----
10
13
26

query I rowsort
SELECT 7 * col0 AS col2 FROM tab2
----
49
546
553

query I rowsort
SELECT + col0 * + col0 * - col1 + + col1 * col1 FROM tab1
----
-40860
-83031
442

query I rowsort
SELECT + col1 * + col2 + col0 FROM tab2
----
1612
725
844

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT + col0 IN ( - col0 * + col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT DISTINCT col2 + + cor0.col2 + 37 FROM tab0 AS cor0
----
103
201
39

query I rowsort
SELECT + col1 * col0 + + 73 AS col2 FROM tab0 AS cor0
----
2137
3468
8172

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 64 * - col2 + + col0 + - cor0.col2 col0 FROM tab1 AS cor0
----
-3507
-3641
-6160

query I rowsort
SELECT DISTINCT col2 * col1 + - 81 * col0 FROM tab1 AS cor0
----
-4614
-5232
1161

onlyif mysql # use DIV operator for integer division
query I rowsort label-4366
SELECT + 29 * col2 + col1 DIV col0 AS col1 FROM tab1 AS cor0
----
1574
1653
2784

skipif mysql # not compatible
query I rowsort label-4366
SELECT + 29 * col2 + col1 / col0 AS col1 FROM tab1 AS cor0
----
1574
1653
2784

query I rowsort
SELECT - + cor0.col1 - col2 AS col0 FROM tab1 AS cor0
----
-109
-67
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4368
SELECT ALL col0 * col2 DIV - col1 + + col0 DIV + col1 - col1 FROM tab0
----
-171
-95
-97

skipif mysql # not compatible
query I rowsort label-4368
SELECT ALL col0 * col2 / - col1 + + col0 / + col1 - col1 FROM tab0
----
-171
-95
-97

query I rowsort
SELECT tab1.col0 * + col0 * col1 AS col1 FROM tab1
----
234
40960
83200

query I rowsort
SELECT ALL col2 - col0 * col2 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT - col1 - tab2.col1 AS col2 FROM tab2
----
-118
-34
-62

query I rowsort
SELECT 66 AS col0 FROM tab0, tab2 cor0, tab2 cor1
----
27 values hashing to 897b6122ac98340b78905f39d81897fc

onlyif mysql # use DIV operator for integer division
query I rowsort label-4373
SELECT ALL - col2 + + col2 DIV col1 FROM tab1
----
-52
-52
-89

skipif mysql # not compatible
query I rowsort label-4373
SELECT ALL - col2 + + col2 / col1 FROM tab1
----
-52
-52
-89

query I rowsort
SELECT - - col1 + + col0 AS col2 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT + col0 + - col0 * - col1 * + col1 AS col0 FROM tab0 AS cor0
----
177528
329350
737098

query I rowsort
SELECT DISTINCT col1 * + col0 + + col0 FROM tab2
----
1422
224
4680

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE tab1.col1 IN ( tab1.col1 + tab1.col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4378
SELECT ALL col0 DIV - tab2.col1 + col0 * col1 AS col1 FROM tab2
----
1339
217
4601

skipif mysql # not compatible
query I rowsort label-4378
SELECT ALL col0 / - tab2.col1 + col0 * col1 AS col1 FROM tab2
----
1339
217
4601

query III rowsort
SELECT * FROM tab2 WHERE - col2 * col0 <> - col2 * + col1 * col2
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-4380
SELECT ALL col2 DIV col2 + - col2 FROM tab1
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-4380
SELECT ALL col2 / col2 + - col2 FROM tab1
----
-53
-56
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 - + cor0.col0 col2 FROM tab2, tab2 AS cor0
----
-41
-52
20

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( - col2 * - col1 ) = NULL
----

query I rowsort
SELECT cor0.col2 * - col1 AS col2 FROM tab2 cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-4384
SELECT ALL - tab0.col0 DIV tab0.col0 AS col1 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4384
SELECT ALL - tab0.col0 / tab0.col0 AS col1 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT ALL col1 + col2 * + col2 + + col0 AS col0 FROM tab2
----
1540
767
813

query I rowsort
SELECT ALL col0 * - col0 * - col1 AS col1 FROM tab2
----
106097
1519
358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-4387
SELECT + col1 * - col0 DIV col0 AS col2 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-4387
SELECT + col1 * - col0 / col0 AS col2 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT col0 + col1 + + col2 FROM tab2
----
134
163
65

query I rowsort
SELECT col2 * - col0 * + col0 AS col0 FROM tab0
----
-1225
-19008
-649522

query I rowsort
SELECT ALL tab2.col0 - - col0 * col0 AS col0 FROM tab2
----
56
6162
6320

query III rowsort
SELECT ALL * FROM tab2 WHERE - col0 IN ( col0 )
----

query I rowsort
SELECT - col0 * - col1 * col2 + tab0.col2 + col2 * col0 * + col0 FROM tab0
----
1313722
4621
87153

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL <> ( + col0 / - col0 + col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + col2 ) col1 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ALL - 79 - tab1.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 9b4e235553ea8586a4eda401d8ebfb1a

query I rowsort
SELECT ALL + 90 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT ALL + + col1 * - col2 * col2 FROM tab0 cor0
----
-611884
-93654
-97

query I rowsort
SELECT ALL + cor0.col0 * col1 * col0 AS col0 FROM tab2 cor0
----
106097
1519
358956

query I rowsort
SELECT DISTINCT - ( col1 ) * + col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT + cor0.col2 * + 82 * + col1 AS col2 FROM tab0 AS cor0
----
232716
611884
7954

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 4 col0 FROM tab0 AS cor0
----
4
4
4

query I rowsort
SELECT + col0 + + col2 * ( - col0 ) FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT ALL 22 * + col0 FROM tab1 AS cor0
----
1408
1760
66

query I rowsort
SELECT - col1 + - col0 - - col2 * col0 FROM tab1 AS cor0
----
133
3574
7587

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + - col2 col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT + col2 * + col2 + - 53 * 92 + + col2 AS col2 FROM tab2 AS cor0
----
-3394
-4120
-4174

query I rowsort
SELECT ALL + col2 * - col0 + 80 FROM tab1 AS cor0
----
-3568
-7600
-82

query I rowsort
SELECT ALL col1 * - col2 + col0 * 81 * + col2 FROM tab2 AS cor0
----
14472
162734
242516

query I rowsort
SELECT DISTINCT - 33 + + col2 - col2 * + col0 FROM tab0 AS cor0
----
-67
-7249
-792

query I rowsort
SELECT - - col1 * - col0 - - 36 * + col0 FROM tab2 AS cor0
----
-1794
1501
35

query I rowsort
SELECT - col1 * col0 - - ( col0 ) AS col1 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT DISTINCT + col2 + + ( col1 ) - - col0 * tab1.col1 AS col2 FROM tab1
----
1149
158
707

onlyif mysql # use DIV operator for integer division
query I rowsort label-4413
SELECT - col0 + + col0 DIV col1 + 36 AS col0 FROM tab1
----
-22
-38
33

skipif mysql # not compatible
query I rowsort label-4413
SELECT - col0 + + col0 / col1 + 36 AS col0 FROM tab1
----
-22
-38
33

query I rowsort
SELECT ( - col1 ) * col0 - col1 * col2 AS col1 FROM tab2
----
-1054
-1989
-6136

query I rowsort
SELECT + 95 * col2 FROM tab2
----
2470
2565
3610

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4416
SELECT DISTINCT + CAST( - col1 AS SIGNED ) - col2 FROM tab0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-4416
SELECT DISTINCT + CAST ( - col1 AS INTEGER ) - col2 FROM tab0
----
-119
-173
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4417
SELECT DISTINCT CAST( col2 + + col2 AS SIGNED ) FROM tab2
----
52
54
76

skipif mysql # not compatible
query I rowsort label-4417
SELECT DISTINCT CAST ( col2 + + col2 AS INTEGER ) FROM tab2
----
52
54
76

query I rowsort
SELECT DISTINCT - ( + 75 ) - - col2 * tab2.col1 AS col1 FROM tab2
----
1459
571
762

query I rowsort
SELECT col2 * cor0.col1 * - col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT ALL - col0 + 67 FROM tab0 AS cor0
----
-22
32
43

query I rowsort
SELECT ALL col0 + cor0.col2 + + col0 AS col0 FROM tab2 AS cor0
----
182
196
41

query I rowsort
SELECT DISTINCT - cor0.col0 + 6 FROM tab2 AS cor0
----
-1
-72
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-4423
SELECT - col0 DIV - ( 69 + col1 ) FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4423
SELECT - col0 / - ( 69 + col1 ) FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4424
SELECT + + col1 DIV col0 col1 FROM tab2 AS cor0
----
0
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4424
SELECT + + col1 / col0 col1 FROM tab2 AS cor0
----
0
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 * 57 + + col1 * - col0 * + 35 col2 FROM tab1 AS cor0
----
-22970
-37141
-4212

query I rowsort
SELECT ALL - + col2 * - 72 + 18 AS col0 FROM tab2 AS cor0
----
1890
1962
2754

query I rowsort
SELECT DISTINCT tab0.col1 * 14 FROM tab0
----
1204
1274
1358

query I rowsort
SELECT ALL - 59 + + col2 AS col1 FROM tab1 AS cor0
----
-2
-5
37

query I rowsort
SELECT DISTINCT 27 FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2, tab1 AS cor3
----
27

query I rowsort
SELECT + tab0.col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4431
SELECT - - col0 * CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4431
SELECT - - col0 * CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1, tab1 AS cor2
----
243 values hashing to 1d38a1a4aacea9827ed2338191291f0e

query I rowsort
SELECT - ( + col1 ) * - 92 FROM tab1 AS cor0
----
1196
2392
920

onlyif mysql # use DIV operator for integer division
query I rowsort label-4434
SELECT ALL col2 DIV col1 + - ( + 95 ) DIV col1 FROM tab0 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4434
SELECT ALL col2 / col1 + - ( + 95 ) / col1 FROM tab0 AS cor0
----
-1
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4435
SELECT ALL + + cor0.col0 + col0 + CAST( NULL AS SIGNED ) * - 62 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4435
SELECT ALL + + cor0.col0 + col0 + CAST ( NULL AS INTEGER ) * - 62 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * - col1 + + ( + ( - col1 ) + - ( + col0 ) ) FROM tab2 cor0
----
-3618
-385
-999

query I rowsort
SELECT - - col2 * - col2 + + ( ( - col1 ) ) FROM tab1 AS cor0
----
-2942
-3259
-9229

query I rowsort
SELECT DISTINCT - cor0.col2 + - col1 * + col0 AS col1 FROM tab1 cor0
----
-1136
-132
-697

query I rowsort
SELECT + col2 + col0 + + 73 FROM tab0 AS cor0
----
109
130
244

query I rowsort
SELECT - col2 + + col1 + ( 21 ) AS col1 FROM tab1 AS cor0
----
-26
-62
-7

query I rowsort
SELECT ALL + - 58 + - col0 * + 72 AS col2 FROM tab1 AS cor0
----
-274
-4666
-5818

query I rowsort
SELECT col2 * 80 FROM tab2
----
2080
2160
3040

query I rowsort
SELECT ALL col0 + + 10 + + col0 AS col2 FROM tab0
----
188
58
80

query I rowsort
SELECT col1 * + 59 FROM tab2
----
1003
1829
3481

query I rowsort
SELECT ALL 61 * col2 * col1 + 80 * col1 + - col0 FROM tab1
----
35506
77088
87721

onlyif mysql # use DIV operator for integer division
query I rowsort label-4446
SELECT ALL - + 95 + + col1 DIV col0 FROM tab0 AS cor0
----
-92
-93
-94

skipif mysql # not compatible
query I rowsort label-4446
SELECT ALL - + 95 + + col1 / col0 FROM tab0 AS cor0
----
-92
-93
-94

query I rowsort
SELECT - ( cor0.col2 ) + + ( + 44 + + col0 ) FROM tab2 AS cor0
----
24
85
96

query I rowsort
SELECT ALL - col1 * + col0 * col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4449
SELECT CAST( + col2 AS SIGNED ) * col2 + - col2 FROM tab1 AS cor0
----
2862
3192
9120

skipif mysql # not compatible
query I rowsort label-4449
SELECT CAST ( + col2 AS INTEGER ) * col2 + - col2 FROM tab1 AS cor0
----
2862
3192
9120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - col1 col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT ALL - 50 AS col0 FROM tab2 AS cor0
----
-50
-50
-50

onlyif mysql # use DIV operator for integer division
query I rowsort label-4452
SELECT DISTINCT - col0 DIV col0 + + cor0.col1 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-4452
SELECT DISTINCT - col0 / col0 + + cor0.col1 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT - 39 + - col0 FROM tab1 AS cor0
----
-103
-119
-42

query I rowsort
SELECT + col0 * col1 * + col1 + col2 * cor0.col1 AS col1 FROM tab0 cor0
----
180342
329412
744471

query I rowsort
SELECT DISTINCT 24 + - col2 AS col0 FROM tab1 AS cor0
----
-30
-33
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + 70 col1 FROM tab0 AS cor0
----
103
152
71

query I rowsort
SELECT - col1 * col0 + - col2 AS col2 FROM tab1
----
-1136
-132
-697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 32 * col2 + ( + col0 ) * + col2 col2 FROM tab0
----
10004
1881
68

query I rowsort
SELECT ALL - col0 + 74 FROM tab1
----
-6
10
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4460
SELECT ALL - - CAST( NULL AS DECIMAL ) + col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4460
SELECT ALL - - CAST ( NULL AS REAL ) + col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 33 + + ( - col1 ) FROM tab0
----
-53
-58
-64

onlyif mysql # use DIV operator for integer division
query I rowsort label-4462
SELECT ALL - 91 DIV + col1 + + col2 * + 42 * + tab1.col2 FROM tab1
----
122469
136449
387065

skipif mysql # not compatible
query I rowsort label-4462
SELECT ALL - 91 / + col1 + + col2 * + 42 * + tab1.col2 FROM tab1
----
122469
136449
387065

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4463
SELECT DISTINCT - CAST( + 5 AS SIGNED ) + col0 * - col0 * col1 FROM tab1
----
-239
-40965
-83205

skipif mysql # not compatible
query I rowsort label-4463
SELECT DISTINCT - CAST ( + 5 AS INTEGER ) + col0 * - col0 * col1 FROM tab1
----
-239
-40965
-83205

query I rowsort
SELECT cor0.col2 + cor1.col1 + - 39 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to e517c1fe8d7c759ba90aa45bd431028c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4465
SELECT ALL + CAST( ( + col0 ) * + 72 AS SIGNED ) FROM tab2
----
504
5616
5688

skipif mysql # not compatible
query I rowsort label-4465
SELECT ALL + CAST ( ( + col0 ) * + 72 AS INTEGER ) FROM tab2
----
504
5616
5688

query I rowsort
SELECT ALL + + col0 * col1 - + col0 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT DISTINCT col0 * + col1 + - col0 + col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + - col1 * - col0 + col0 * col2 FROM tab2 AS cor0
----
406
4345
6630

query I rowsort
SELECT 29 + col2 AS col2 FROM tab0 cor0
----
111
30
62

query I rowsort
SELECT - ( + tab1.col1 ) * - col1 AS col0 FROM tab1
----
100
169
676

query I rowsort
SELECT + + col2 + + col2 * + col1 + + col1 FROM tab2 AS cor0
----
1619
701
895

query I rowsort
SELECT cor1.col0 FROM tab2, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

query I rowsort
SELECT DISTINCT col2 * ( col0 ) AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL col1 * + 44 FROM tab1
----
1144
440
572

query I rowsort
SELECT ALL + 4 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT + col1 * - ( col2 ) AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - col2 + 30 AS col0 FROM tab0 AS cor0
----
-3
-52
29

query I rowsort
SELECT ALL + - cor0.col1 + 80 FROM tab1 AS cor0
----
54
67
70

query I rowsort
SELECT + - col0 + + col2 * + cor0.col0 + - cor0.col2 FROM tab2 AS cor0
----
155
1924
2885

query I rowsort
SELECT DISTINCT - col0 + - col0 + + col1 FROM tab0 AS cor0
----
-87
27
38

query I rowsort
SELECT ALL - 30 FROM tab2, tab2 AS cor0, tab2 AS cor1, tab0, tab0 AS cor2
----
243 values hashing to 66abe02e4ad1487acd927138a1f5c437

query I rowsort
SELECT col1 + + ( - cor0.col2 ) FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - 47 + col0 * + cor0.col2 FROM tab0 AS cor0
----
-12
7251
745

query I rowsort
SELECT DISTINCT - + cor0.col0 - + col2 * col1 AS col0 FROM tab1 cor0
----
-1328
-1407
-634

query I rowsort
SELECT ALL - col0 + 69 * - col2 FROM tab2 AS cor0
----
-1870
-1872
-2701

query I rowsort
SELECT DISTINCT + col0 * - 49 - - col1 FROM tab2 AS cor0
----
-312
-3763
-3854

query I rowsort
SELECT - tab2.col1 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT ALL - 77 AS col1 FROM tab1, tab2 AS cor0, tab2 cor1
----
27 values hashing to c7e5f48ecd3843d54a76808ed1f43ff6

query I rowsort
SELECT + 7 * col0 * + col2 FROM tab2 cor0
----
1323
14196
21014

query I rowsort
SELECT col0 * 4 + col1 FROM tab1 AS cor0
----
266
333
38

query I rowsort
SELECT - + col2 * - 19 + + col0 FROM tab0 AS cor0
----
1647
54
651

query I rowsort
SELECT DISTINCT cor0.col2 * + 59 AS col1 FROM tab2, tab0 AS cor0
----
1947
4838
59

query I rowsort
SELECT + col0 * col2 * col0 + + col0 AS col2 FROM tab1
----
233536
489
614480

query I rowsort
SELECT DISTINCT ( 6 ) FROM tab0, tab2 AS cor0
----
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 75 col0 FROM tab0, tab0 cor0, tab2 cor1
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT ALL + 47 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4497
SELECT - - col1 DIV 37 + + cor0.col0 * - col2 - cor0.col2 AS col0 FROM tab1 AS cor0
----
-216
-3705
-7776

skipif mysql # not compatible
query I rowsort label-4497
SELECT - - col1 / 37 + + cor0.col0 * - col2 - cor0.col2 AS col0 FROM tab1 AS cor0
----
-216
-3705
-7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 * col0 * col0 col2 FROM tab2
----
1350
158210
237196

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4499
SELECT + tab2.col2 * + CAST( NULL AS DECIMAL ) + col0 * + tab2.col2 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4499
SELECT + tab2.col2 * + CAST ( NULL AS REAL ) + col0 * + tab2.col2 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 1 FROM tab0, tab1, tab1 cor0
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

query I rowsort
SELECT DISTINCT - 59 AS col0 FROM tab2, tab2 AS cor0
----
-59

query I rowsort
SELECT ( 48 ) + col0 * 73 * - col2 AS col2 FROM tab0
----
-2507
-532706
-57768

query I rowsort
SELECT ( - 9 ) FROM tab1
----
-9
-9
-9

query I rowsort
SELECT - + cor0.col2 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT + 62 * - col2 * ( + ( col0 ) ) AS col2 FROM tab1
----
-10044
-226176
-476160

query I rowsort
SELECT DISTINCT - col1 * col1 * ( col0 ) AS col2 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT - 19 + col0 AS col2 FROM tab2
----
-12
59
60

query I rowsort
SELECT - 50 * + col0 - - col1 AS col0 FROM tab0
----
-1114
-1653
-4359

onlyif mysql # use DIV operator for integer division
query I rowsort label-4509
SELECT - col1 DIV col1 + 25 FROM tab1
----
24
24
24

skipif mysql # not compatible
query I rowsort label-4509
SELECT - col1 / col1 + 25 FROM tab1
----
24
24
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 43 col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4511
SELECT DISTINCT - cor1.col2 DIV 49 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
-1
0

skipif mysql # not compatible
query I rowsort label-4511
SELECT DISTINCT - cor1.col2 / 49 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4512
SELECT - + ( - col1 ) DIV - cor0.col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-4512
SELECT - + ( - col1 ) / - cor0.col0 FROM tab1 AS cor0
----
-8
0
0

query I rowsort
SELECT - col2 + col2 * ( + col2 * + col1 ) AS col1 FROM tab0 AS cor0
----
611802
93621
96

query I rowsort
SELECT DISTINCT + col0 * - col1 * 80 - cor0.col0 AS col2 FROM tab1 cor0
----
-51264
-6243
-83280

onlyif mysql # use DIV operator for integer division
query I rowsort label-4515
SELECT - 38 DIV + col0 FROM tab1 AS cor0
----
-12
0
0

skipif mysql # not compatible
query I rowsort label-4515
SELECT - 38 / + col0 FROM tab1 AS cor0
----
-12
0
0

query I rowsort
SELECT ( + col2 ) + + col2 * col2 AS col2 FROM tab2 AS cor0
----
1482
702
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-4517
SELECT ALL + col2 DIV + 4 AS col2 FROM tab2 AS cor0
----
6
6
9

skipif mysql # not compatible
query I rowsort label-4517
SELECT ALL + col2 / + 4 AS col2 FROM tab2 AS cor0
----
6
6
9

query I rowsort
SELECT ALL + cor0.col0 * + col1 + + col1 * - col2 FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT ALL - col0 * + 80 - ( col0 * + col2 ) FROM tab0 AS cor0
----
-14418
-2712
-2835

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4520
SELECT DISTINCT - + col1 * CAST( - cor0.col2 * col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
16224
36504
5700

skipif mysql # not compatible
query I rowsort label-4520
SELECT DISTINCT - + col1 * CAST ( - cor0.col2 * col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-4521
SELECT DISTINCT col1 + ( + col2 ) * col0 DIV - col2 FROM tab0 AS cor0
----
2
62

skipif mysql # not compatible
query I rowsort label-4521
SELECT DISTINCT col1 + ( + col2 ) * col0 / - col2 FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT DISTINCT - col0 * - 75 FROM tab1 AS cor0
----
225
4800
6000

onlyif mysql # use DIV operator for integer division
query I rowsort label-4523
SELECT DISTINCT - col0 DIV + 43 AS col1 FROM tab0 AS cor0
----
-2
0

skipif mysql # not compatible
query I rowsort label-4523
SELECT DISTINCT - col0 / + 43 AS col1 FROM tab0 AS cor0
----
-2
0

query I rowsort
SELECT + cor0.col2 * + 30 FROM tab0 AS cor0
----
2460
30
990

query I rowsort
SELECT DISTINCT + cor0.col0 + + 16 * + col0 FROM tab0 AS cor0
----
1513
408
595

query I rowsort
SELECT col2 * 64 AS col1 FROM tab2 AS cor0
----
1664
1728
2432

query I rowsort
SELECT - - col1 * - 73 FROM tab2 cor0
----
-1241
-2263
-4307

onlyif mysql # use DIV operator for integer division
query I rowsort label-4528
SELECT - - ( - col1 ) DIV - col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-4528
SELECT - - ( - col1 ) / - col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT - 61 * + col0 * col2 + cor0.col0 FROM tab2 AS cor0
----
-11522
-123630
-183043

onlyif mysql # use DIV operator for integer division
query I rowsort label-4530
SELECT ALL - col1 + col2 DIV + col0 FROM tab1 AS cor0
----
-10
-12
-8

skipif mysql # not compatible
query I rowsort label-4530
SELECT ALL - col1 + col2 / + col0 FROM tab1 AS cor0
----
-10
-12
-8

query I rowsort
SELECT ALL ( ( col1 ) ) FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-4532
SELECT - col0 DIV 48 AS col1 FROM tab2
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4532
SELECT - col0 / 48 AS col1 FROM tab2
----
-1
-1
0

query I rowsort
SELECT + - 39 * + col0 FROM tab1 AS cor0
----
-117
-2496
-3120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 + col0 col1 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT 80 * + col0 FROM tab2 AS cor0
----
560
6240
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-4536
SELECT ALL + 1 * col0 DIV col2 FROM tab1 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4536
SELECT ALL + 1 * col0 / col2 FROM tab1 cor0
----
0
0
1

query I rowsort
SELECT + col0 + col1 + col0 FROM tab2 cor0
----
175
215
45

query I rowsort
SELECT - ( 52 * col2 ) FROM tab2
----
-1352
-1404
-1976

query I rowsort
SELECT tab0.col0 + + col2 + col0 AS col1 FROM tab0
----
260
71
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col1 + ( col1 ) col2 FROM tab0
----
-2752
-7371
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4541
SELECT ALL + col2 * col1 + - col0 * col1 DIV + ( + col1 ) AS col0 FROM tab0
----
2814
62
7373

skipif mysql # not compatible
query I rowsort label-4541
SELECT ALL + col2 * col1 + - col0 * col1 / + ( + col1 ) AS col0 FROM tab0
----
2814
62
7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * ( 32 + col2 ) col1 FROM tab0
----
10374
3201
5590

query I rowsort
SELECT ALL - tab1.col0 * 96 * col1 + + tab1.col1 AS col1 FROM tab1
----
-61430
-7462
-99827

query I rowsort
SELECT ALL + col1 * - 85 + 22 AS col2 FROM tab1
----
-1083
-2188
-828

query I rowsort
SELECT ALL cor0.col1 + - 98 FROM tab0 AS cor0
----
-1
-12
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4546
SELECT - - col1 + - CAST( + col2 AS SIGNED ) * - col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

skipif mysql # not compatible
query I rowsort label-4546
SELECT - - col1 + - CAST ( + col2 AS INTEGER ) * - col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT + + 18 + col1 * col1 + + col2 * - 47 FROM tab2 cor0
----
-1479
-290
2277

query I rowsort
SELECT 25 + cor0.col1 * col2 AS col1 FROM tab1 cor0
----
1273
1429
595

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col0 ) + col2 col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT + col1 + col0 * + cor0.col1 AS col0 FROM tab1 cor0
----
104
1053
650

query I rowsort
SELECT ALL + - 60 + col1 FROM tab1 AS cor0
----
-34
-47
-50

onlyif mysql # use DIV operator for integer division
query I rowsort label-4552
SELECT ALL + col2 * + col1 + col0 + + 1 DIV - col2 FROM tab1 AS cor0
----
1328
1407
634

skipif mysql # not compatible
query I rowsort label-4552
SELECT ALL + col2 * + col1 + col0 + + 1 / - col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT + ( - 27 ) + col1 FROM tab1 AS cor0
----
-1
-14
-17

query I rowsort
SELECT ( col0 ) + - col1 FROM tab1 cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 74 * - col1 col1 FROM tab1 AS cor0
----
-1924
-740
-962

query I rowsort
SELECT DISTINCT - + ( + 65 ) * col1 AS col2 FROM tab1 AS cor0
----
-1690
-650
-845

query I rowsort
SELECT DISTINCT - tab0.col0 + - col1 * col0 + + col1 FROM tab0
----
-2002
-3333
-8097

query I rowsort
SELECT ALL cor0.col0 AS col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL col1 * + col1 + 9 AS col0 FROM tab1
----
109
178
685

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + ( col2 ) * col1 col2 FROM tab0
----
2871
7544
98

query I rowsort
SELECT + ( - col2 ) + - col1 - + col2 AS col0 FROM tab2 AS cor0
----
-111
-85
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 83 col1 FROM tab2 AS cor0
----
83
83
83

query I rowsort
SELECT DISTINCT ( col1 ) * + ( - 49 ) FROM tab0 AS cor0
----
-4214
-4459
-4753

onlyif mysql # use DIV operator for integer division
query I rowsort label-4564
SELECT ALL + col0 * col2 * + ( + col2 ) + + col2 DIV col0 FROM tab2 AS cor0
----
114076
5106
52728

skipif mysql # not compatible
query I rowsort label-4564
SELECT ALL + col0 * col2 * + ( + col2 ) + + col2 / col0 FROM tab2 AS cor0
----
114076
5106
52728

query I rowsort
SELECT + 26 * col2 AS col0 FROM tab0 cor0
----
2132
26
858

query I rowsort
SELECT ALL + col0 * - col2 * + col1 + col1 AS col1 FROM tab0 AS cor0
----
-3298
-664027
-68026

query I rowsort
SELECT + - col0 * + ( - 18 ) FROM tab1 cor0
----
1152
1440
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-4568
SELECT DISTINCT ( col1 ) DIV - ( tab1.col1 ) FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-4568
SELECT DISTINCT ( col1 ) / - ( tab1.col1 ) FROM tab1
----
-1

query I rowsort
SELECT ALL - 77 * col1 FROM tab2
----
-1309
-2387
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-4570
SELECT + + col2 DIV - col1 FROM tab1 cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-4570
SELECT + + col2 / - col1 FROM tab1 cor0
----
-2
-5
-7

query I rowsort
SELECT 21 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 312c166f4dc412730c43555105b1f44b

query I rowsort
SELECT tab1.col0 * - tab1.col1 + 96 AS col2 FROM tab1
----
-544
-944
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - cor0.col0 ) col0 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

onlyif mysql # use DIV operator for integer division
query I rowsort label-4574
SELECT DISTINCT col1 DIV - col1 AS col1 FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-4574
SELECT DISTINCT col1 / - col1 AS col1 FROM tab1
----
-1

query I rowsort
SELECT - col1 * 81 + tab1.col0 + - col1 FROM tab1
----
-2129
-756
-986

query I rowsort
SELECT ALL - col0 + col2 + - ( col0 + ( - col2 ) ) AS col1 FROM tab2
----
-104
-82
40

query I rowsort
SELECT - col2 * 6 AS col2 FROM tab1 cor0
----
-324
-342
-576

onlyif mysql # use DIV operator for integer division
query I rowsort label-4578
SELECT DISTINCT + col0 DIV 5 FROM tab0
----
17
4
7

skipif mysql # not compatible
query I rowsort label-4578
SELECT DISTINCT + col0 / 5 FROM tab0
----
17
4
7

query I rowsort
SELECT - 32 + col1 AS col0 FROM tab2
----
-1
-15
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 64 + + col2 col2 FROM tab1 AS cor0
----
118
121
160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 28 + - col0 col1 FROM tab1 AS cor0
----
-36
-52
25

query I rowsort
SELECT + cor1.col0 * + 84 + 44 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to db25d7e08f1a1182824e5d54a7f40e5d

query I rowsort
SELECT DISTINCT + col2 + + col1 * cor0.col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + 34 + + cor0.col2 FROM tab2 AS cor0
----
60
61
72

query I rowsort
SELECT - + col1 + - col1 * cor0.col1 AS col2 FROM tab1 cor0
----
-110
-182
-702

query I rowsort
SELECT col1 + col2 * + col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL + 93 + col1 * - col1 FROM tab0 AS cor0
----
-7303
-8188
-9316

query I rowsort
SELECT + - col1 + col1 * + col1 AS col0 FROM tab1 AS cor0
----
156
650
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4589
SELECT - CAST( - 79 AS SIGNED ) * - cor0.col2 FROM tab0 AS cor0
----
-2607
-6478
-79

skipif mysql # not compatible
query I rowsort label-4589
SELECT - CAST ( - 79 AS INTEGER ) * - cor0.col2 FROM tab0 AS cor0
----
-2607
-6478
-79

query I rowsort
SELECT DISTINCT col0 + col0 * - col2 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT + + cor0.col1 * + col2 * - 21 AS col1 FROM tab2 AS cor0
----
-13566
-17577
-32214

query I rowsort
SELECT 43 * - col0 * - 78 AS col1 FROM tab0 AS cor0
----
117390
298506
80496

query I rowsort
SELECT + cor0.col0 + + col1 + + 80 FROM tab0 AS cor0
----
190
212
260

query I rowsort
SELECT DISTINCT 12 AS col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
12

query I rowsort
SELECT + col0 + col1 * col1 AS col1 FROM tab2 cor0
----
3559
368
968

query I rowsort
SELECT 12 * - cor0.col2 + ( + 63 ) * + cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 6f70c4c24ab265eb2ea533d87d5a7e06

query I rowsort
SELECT col1 * 76 + col0 + - col1 FROM tab0 AS cor0
----
6474
6914
7310

query I rowsort
SELECT ALL 64 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT col2 * + 30 + col0 AS col2 FROM tab2 AS cor0
----
1219
817
858

query I rowsort
SELECT + col2 * + 42 + - cor0.col2 * - col1 FROM tab2 AS cor0
----
1971
2242
2626

query I rowsort
SELECT DISTINCT - col0 * 54 + + 10 FROM tab0 AS cor0
----
-1286
-1880
-4796

query I rowsort
SELECT ALL ( + col2 ) + col2 + col0 AS col2 FROM tab2 cor0
----
130
155
61

query I rowsort
SELECT DISTINCT ( + col0 ) * col0 AS col1 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT + - col1 + ( col1 ) * - col1 * + col2 AS col0 FROM tab0 AS cor0
----
-244154
-679133
-9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col0 col2 FROM tab0
----
178
48
70

query I rowsort
SELECT + col2 * 35 AS col1 FROM tab0
----
1155
2870
35

query I rowsort
SELECT - col1 * - col2 * + col0 + - 75 + col2 AS col1 FROM tab2 AS cor0
----
119603
50997
5811

query I rowsort
SELECT ALL - 31 + + col2 * col2 * + ( + 33 ) AS col2 FROM tab2 AS cor0
----
22277
24026
47621

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4609
SELECT + - ( col0 ) + cor0.col2 * CAST( 47 AS SIGNED ) + - cor0.col1 FROM tab0 AS cor0
----
-85
1441
3674

skipif mysql # not compatible
query I rowsort label-4609
SELECT + - ( col0 ) + cor0.col2 * CAST ( 47 AS INTEGER ) + - cor0.col1 FROM tab0 AS cor0
----
-85
1441
3674

query I rowsort
SELECT DISTINCT - ( cor0.col1 ) * + col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT col1 + - ( - 92 ) AS col2 FROM tab2
----
109
123
151

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 cor0 CROSS JOIN tab1, tab0 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to 181d902c42955a43a374f13a73d8b0a1

query I rowsort
SELECT + col2 + - 72 AS col0 FROM tab1
----
-15
-18
24

query I rowsort
SELECT ALL ( ( col1 ) + col2 ) * 67 FROM tab0
----
11591
6566
7973

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4615
SELECT CAST( NULL AS SIGNED ) * + col0 + - col0 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4615
SELECT CAST ( NULL AS INTEGER ) * + col0 + - col0 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT tab2.col2 AS col1 FROM tab2, tab1, tab1 cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT + 0 - + 68 FROM tab2
----
-68
-68
-68

query I rowsort
SELECT DISTINCT + 94 + col0 * + col2 + + col2 FROM tab1 AS cor0
----
310
3799
7870

query I rowsort
SELECT + col2 * 25 + col2 FROM tab1 AS cor0
----
1404
1482
2496

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4620
SELECT - CAST( + col0 * - col1 AS SIGNED ) FROM tab2
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-4620
SELECT - CAST ( + col0 * - col1 AS INTEGER ) FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL + + 14 + + col1 FROM tab1 AS cor0
----
24
27
40

query I rowsort
SELECT DISTINCT - ( - col1 ) + col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT 16 * tab2.col0 + - tab2.col0 * col2 FROM tab2
----
-1738
-77
-780

query I rowsort
SELECT 59 * tab2.col1 AS col0 FROM tab2
----
1003
1829
3481

query I rowsort
SELECT + ( - tab0.col2 ) * - 96 AS col0 FROM tab0
----
3168
7872
96

query I rowsort
SELECT - ( col0 ) + - col0 * + col1 + - col0 AS col0 FROM tab2
----
-1501
-231
-4758

query I rowsort
SELECT DISTINCT 6 - + col1 FROM tab0
----
-80
-85
-91

query I rowsort
SELECT DISTINCT - col0 * - 52 AS col0 FROM tab1 AS cor0
----
156
3328
4160

query I rowsort
SELECT + cor0.col0 * col1 + + cor0.col2 FROM tab0 AS cor0
----
2097
3396
8181

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4630
SELECT DISTINCT + - col2 * - CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4630
SELECT DISTINCT + - col2 * - CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL

query I rowsort
SELECT - 95 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 1c7934db0632c123332c43f17b661d6c

query I rowsort
SELECT + tab2.col1 * - 8 FROM tab2
----
-136
-248
-472

query I rowsort
SELECT DISTINCT col1 * - ( col2 ) * - col1 - - ( - 94 ) AS col0 FROM tab1 AS cor0
----
16130
36410
5606

query I rowsort
SELECT ALL + col1 * ( 89 ) AS col2 FROM tab1 AS cor0
----
1157
2314
890

query I rowsort
SELECT DISTINCT col1 + + ( col0 ) AS col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL + col0 * 77 FROM tab1 AS cor0
----
231
4928
6160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4637
SELECT DISTINCT + - col1 + - CAST( NULL AS DECIMAL ) AS col2 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4637
SELECT DISTINCT + - col1 + - CAST ( NULL AS REAL ) AS col2 FROM tab1 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4638
SELECT col0 * 69 + col0 DIV col0 FROM tab0 AS cor0
----
1657
2416
6142

skipif mysql # not compatible
query I rowsort label-4638
SELECT col0 * 69 + col0 / col0 FROM tab0 AS cor0
----
1657
2416
6142

onlyif mysql # use DIV operator for integer division
query I rowsort label-4639
SELECT ALL - + col0 DIV cor0.col1 + - 74 * col2 + cor0.col0 DIV - col0 FROM tab2 AS cor0
----
-1926
-1999
-2817

skipif mysql # not compatible
query I rowsort label-4639
SELECT ALL - + col0 / cor0.col1 + - 74 * col2 + cor0.col0 / - col0 FROM tab2 AS cor0
----
-1926
-1999
-2817

query I rowsort
SELECT DISTINCT - col0 * 37 AS col0 FROM tab1 AS cor0
----
-111
-2368
-2960

query I rowsort
SELECT col2 + 32 * + 84 FROM tab1 AS cor0
----
2742
2745
2784

query I rowsort
SELECT ALL + - col0 + + 35 AS col2 FROM tab2 AS cor0
----
-43
-44
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-4643
SELECT DISTINCT - col1 DIV - col0 - + 27 * cor0.col0 FROM tab0 AS cor0
----
-2402
-645
-943

skipif mysql # not compatible
query I rowsort label-4643
SELECT DISTINCT - col1 / - col0 - + 27 * cor0.col0 FROM tab0 AS cor0
----
-2402
-645
-943

query I rowsort
SELECT ( - 63 ) + col1 * col0 AS col0 FROM tab1
----
15
577
977

onlyif mysql # use DIV operator for integer division
query I rowsort label-4645
SELECT + 90 DIV + col1 + col2 * - col2 * col2 col2 FROM tab1
----
-157461
-185184
-884730

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4645
SELECT + 90 / + col1 + col2 * - col2 * col2 col2 FROM tab1
----
-157461
-185184
-884730

query I rowsort
SELECT 23 * - 38 + col2 FROM tab2
----
-836
-847
-848

query I rowsort
SELECT ( + col0 ) + col0 AS col1 FROM tab0
----
178
48
70

query I rowsort
SELECT ALL - 9 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to caf28657beb43049740febe1fa9ded5a

query I rowsort
SELECT + col0 + 24 * tab1.col0 FROM tab1
----
1600
2000
75

query I rowsort
SELECT + ( + col2 * col2 ) FROM tab2
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( 19 ) col1 FROM tab2
----
19

query I rowsort
SELECT col0 - - tab1.col1 * + col1 FROM tab1
----
164
249
679

query I rowsort
SELECT ALL + cor0.col0 + cor0.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to d994d266bacb99d3939b70b2c7903ce8

query I rowsort
SELECT ALL + col1 * + ( + col2 * + cor0.col1 ) AS col1 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4655
SELECT DISTINCT + CAST( - cor0.col1 AS SIGNED ) + - col2 AS col0 FROM tab0 AS cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-4655
SELECT DISTINCT + CAST ( - cor0.col1 AS INTEGER ) + - col2 AS col0 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4656
SELECT ALL + col2 * - col0 DIV col0 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-4656
SELECT ALL + col2 * - col0 / col0 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - col2 * col1 + col1 * - col2 * cor0.col1 col2 FROM tab0 cor0
----
-14924
-175956
-6014

query I rowsort
SELECT - ( + col1 * + col1 ) + col2 FROM tab1
----
-43
-622
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-4659
SELECT + + ( - col1 ) * cor0.col0 + - col0 DIV col1 AS col0 FROM tab2 cor0
----
-1347
-217
-4603

skipif mysql # not compatible
query I rowsort label-4659
SELECT + + ( - col1 ) * cor0.col0 + - col0 / col1 AS col0 FROM tab2 cor0
----
-1347
-217
-4603

query I rowsort
SELECT ALL - - col1 * col2 + + col0 AS col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT + col1 + col1 - + col1 AS col0 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 53 * - col0 col2 FROM tab1 AS cor0
----
159
3392
4240

query I rowsort
SELECT - 64 * col2 + col0 AS col0 FROM tab1 AS cor0
----
-3453
-3584
-6064

query I rowsort
SELECT ALL - col2 + + col1 * col1 AS col0 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT + 22 + col0 AS col1 FROM tab1 cor0
----
102
25
86

query I rowsort
SELECT DISTINCT - - 65 * + col0 - col2 FROM tab1 AS cor0
----
141
4103
5104

query I rowsort
SELECT ALL 7 * col2 FROM tab1 AS cor0
----
378
399
672

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 33 col1 FROM tab0 AS cor0
----
33
33
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 2 * col0 * + cor0.col0 + - col2 * + col1 - cor0.col2 col0 FROM tab0 cor0
----
-1719
2352
8298

query I rowsort
SELECT ALL cor0.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT ( 44 ) FROM tab0, tab0 AS cor0
----
44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4672
SELECT - - col0 / + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4672
SELECT - - col0 / + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * + 79 FROM tab1 cor0
----
237
5056
6320

query I rowsort
SELECT ALL - cor0.col2 * + col1 * cor0.col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT - + cor0.col0 * col1 + col1 AS col0 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT ALL + col2 * - col2 + - col1 * col2 FROM tab0 AS cor0
----
-14186
-3927
-98

query I rowsort
SELECT DISTINCT - + col2 * 80 + col0 AS col0 FROM tab1 AS cor0
----
-4317
-4496
-7600

query I rowsort
SELECT + col1 + cor0.col1 * + 61 FROM tab0 AS cor0
----
5332
5642
6014

onlyif mysql # use DIV operator for integer division
query I rowsort label-4679
SELECT + col1 + + ( - col0 ) DIV - cor0.col0 AS col0 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-4679
SELECT + col1 + + ( - col0 ) / - cor0.col0 AS col0 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT DISTINCT + col2 * + 22 AS col0 FROM tab0 AS cor0
----
1804
22
726

query I rowsort
SELECT col0 * - col1 * 21 FROM tab1 cor0
----
-13440
-1638
-21840

query I rowsort
SELECT - - 51 + ( col1 ) * col0 FROM tab0 AS cor0
----
2115
3446
8150

query I rowsort
SELECT ALL 73 + + 39 FROM tab2 AS cor0
----
112
112
112

query I rowsort
SELECT + 1 FROM tab1, tab2 cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT col1 + - col1 * col1 + cor0.col2 AS col0 FROM tab1 AS cor0
----
-33
-596
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-4686
SELECT DISTINCT col2 + - col1 DIV - col0 FROM tab2 AS cor0
----
26
31
38

skipif mysql # not compatible
query I rowsort label-4686
SELECT DISTINCT col2 + - col1 / - col0 FROM tab2 AS cor0
----
26
31
38

query I rowsort
SELECT ALL col1 * cor0.col2 FROM tab1 cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col2 * + col1 + - col0 col0 FROM tab2 AS cor0
----
-119730
-51113
-5866

query I rowsort
SELECT DISTINCT - col1 + - col1 AS col2 FROM tab2 WHERE NOT ( NULL ) <> col0
----

query I rowsort
SELECT - col1 / - cor0.col2 + col1 / cor0.col2 FROM tab1 AS cor0 WHERE NULL = NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + - cor0.col0 + + col0 col2 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4692
SELECT - col2 DIV - col2 col1 FROM tab1
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4692
SELECT - col2 / - col2 col1 FROM tab1
----
1
1
1

query I rowsort
SELECT col1 + - col0 * tab2.col1 + - col0 AS col1 FROM tab2
----
-1405
-193
-4621

query I rowsort
SELECT ALL col1 * - col0 + col0 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT ( col2 ) + col1 AS col1 FROM tab0
----
119
173
98

query I rowsort
SELECT col1 + col2 * col2 * col2 FROM tab1
----
157490
185203
884749

query I rowsort
SELECT tab2.col0 * col2 * tab2.col1 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT DISTINCT col1 * - col2 * tab0.col2 AS col0 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT + tab2.col1 * - col2 * tab2.col2 AS col1 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT - col2 * + col0 * col2 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT ALL col1 * - col2 AS col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - col0 + + cor0.col0 * col1 + + col1 FROM tab1 AS cor0
----
101
586
973

query I rowsort
SELECT - 70 * + col0 AS col0 FROM tab0 AS cor0
----
-1680
-2450
-6230

query I rowsort
SELECT + col1 * + col2 + col0 * col0 * - col1 FROM tab0 AS cor0
----
-118728
-46698
-713349

query I rowsort
SELECT tab1.col0 * col0 + - col2 FROM tab1
----
-45
4039
6304

query I rowsort
SELECT ALL col2 - + 12 AS col1 FROM tab1 AS cor0
----
42
45
84

query I rowsort
SELECT ALL cor0.col1 AS col0 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL tab2.col1 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

onlyif mysql # use DIV operator for integer division
query I rowsort label-4709
SELECT + 70 DIV - col2 FROM tab0
----
-2
-70
0

skipif mysql # not compatible
query I rowsort label-4709
SELECT + 70 / - col2 FROM tab0
----
-2
-70
0

query I rowsort
SELECT col0 * + 84 FROM tab2
----
588
6552
6636

query I rowsort
SELECT ALL 14 - col0 FROM tab0
----
-10
-21
-75

query I rowsort
SELECT ( tab0.col1 ) + tab0.col2 * - col0 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT + col0 * - 71 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
-504
-5616
-5688

query I rowsort
SELECT + col0 * + 66 AS col0 FROM tab0 AS cor0
----
1584
2310
5874

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 - + 37 col1 FROM tab2 AS cor0
----
-30
41
42

query I rowsort
SELECT ALL - cor0.col1 + - cor0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 66e198acca624efd182aa551bb5de4c7

query I rowsort
SELECT + - cor0.col0 * ( - cor0.col1 ) FROM tab1, tab2 cor0
----
9 values hashing to bc669a3cc969c7619ebcffb5400ba0ba

query I rowsort
SELECT ALL - 85 + - col1 * 56 AS col1 FROM tab1 AS cor0
----
-1541
-645
-813

query I rowsort
SELECT + + col0 + - col2 * + col2 AS col1 FROM tab0 AS cor0
----
-1065
-6635
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 34 * col0 + 47 col1 FROM tab1 AS cor0
----
149
2223
2767

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 80 col0 FROM tab0 AS cor0
----
-80
-80
-80

query I rowsort
SELECT + - col2 + + col0 * ( 73 ) FROM tab0 AS cor0
----
1719
2554
6415

onlyif mysql # use DIV operator for integer division
query I rowsort label-4723
SELECT DISTINCT ( - col1 ) DIV + col2 AS col0 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-4723
SELECT DISTINCT ( - col1 ) / + col2 AS col0 FROM tab1
----
0

query I rowsort
SELECT - ( tab0.col2 ) * col2 AS col2 FROM tab0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-4725
SELECT - col0 + col0 DIV + col1 FROM tab2 cor0
----
-7
-75
-77

skipif mysql # not compatible
query I rowsort label-4725
SELECT - col0 + col0 / + col1 FROM tab2 cor0
----
-7
-75
-77

query I rowsort
SELECT ALL + 59 * col1 AS col2 FROM tab2 AS cor0
----
1003
1829
3481

query I rowsort
SELECT ALL + - 77 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
1309
2387
4543

query I rowsort
SELECT - - col2 * col1 * col2 + + col1 AS col2 FROM tab2 AS cor0
----
22630
24565
39943

query I rowsort
SELECT - ( - col2 ) * col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4730
SELECT DISTINCT + 41 + col0 DIV - ( col1 ) FROM tab2 AS cor0
----
37
40
41

skipif mysql # not compatible
query I rowsort label-4730
SELECT DISTINCT + 41 + col0 / - ( col1 ) FROM tab2 AS cor0
----
37
40
41

query I rowsort
SELECT - col2 * - col1 + cor0.col0 AS col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT - + col0 + + col2 * 43 FROM tab2 AS cor0
----
1040
1154
1555

onlyif mysql # use DIV operator for integer division
query I rowsort label-4733
SELECT DISTINCT - col2 * + col1 + col0 DIV 92 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-4733
SELECT DISTINCT - col2 * + col1 + col0 / 92 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + 71 * col0 + + col0 AS col0 FROM tab0
----
1728
2520
6408

query I rowsort
SELECT ALL + col2 + tab0.col1 + + col1 FROM tab0
----
195
205
264

query I rowsort
SELECT - col2 * + col1 * + col0 AS col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT ALL - col1 + cor0.col0 * + col2 AS col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT col0 * 71 AS col0 FROM tab1 AS cor0
----
213
4544
5680

query I rowsort
SELECT ALL col2 + - col0 * 34 FROM tab0
----
-1189
-2944
-783

onlyif mysql # use DIV operator for integer division
query I rowsort label-4740
SELECT ALL - col2 + + col0 * - tab2.col0 + + col0 DIV - col0 FROM tab2
----
-6111
-6280
-77

skipif mysql # not compatible
query I rowsort label-4740
SELECT ALL - col2 + + col0 * - tab2.col0 + + col0 / - col0 FROM tab2
----
-6111
-6280
-77

query I rowsort
SELECT + 23 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

query I rowsort
SELECT ALL + + 26 * - col2 + + cor0.col1 * 36 + + 10 AS col0 FROM tab2 AS cor0
----
-366
1458
424

query I rowsort
SELECT + ( 59 ) * cor0.col0 FROM tab1 AS cor0
----
177
3776
4720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4744
SELECT ALL + CAST( NULL AS SIGNED ) + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4744
SELECT ALL + CAST ( NULL AS INTEGER ) + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 73 * col0 * + col1 FROM tab2 AS cor0
----
15841
335946
98039

query I rowsort
SELECT ALL col1 * + col1 + col2 * + col2 FROM tab2 AS cor0
----
1690
1733
4157

query I rowsort
SELECT DISTINCT + - ( 4 ) FROM tab2 AS cor0
----
-4

query I rowsort
SELECT - col0 - ( col1 ) FROM tab1
----
-29
-74
-93

query I rowsort
SELECT tab0.col0 * - col0 - + 48 AS col0 FROM tab0
----
-1273
-624
-7969

onlyif mysql # use DIV operator for integer division
query I rowsort label-4750
SELECT CAST( col1 AS SIGNED ) DIV - col0 + + col2 + 21 FROM tab1
----
117
67
78

skipif mysql # not compatible
query I rowsort label-4750
SELECT CAST ( col1 AS INTEGER ) / - col0 + + col2 + 21 FROM tab1
----
117
67
78

query I rowsort
SELECT col0 * col0 + + col2 * + ( col2 * - col1 ) FROM tab1
----
-113408
-28394
-75807

query I rowsort
SELECT - col2 + 90 * col2 AS col1 FROM tab2
----
2314
2403
3382

query I rowsort
SELECT + 54 * col1 FROM tab1 cor0
----
1404
540
702

query I rowsort
SELECT ALL - + 36 + col2 * - col0 FROM tab1 AS cor0
----
-198
-3684
-7716

query I rowsort
SELECT ( + 75 ) FROM tab2 AS cor0
----
75
75
75

query I rowsort
SELECT ALL + col0 * - col0 + col2 - - col0 FROM tab1 AS cor0
----
-3975
-6224
48

query I rowsort
SELECT ALL + 99 * col1 + - col1 + col2 FROM tab2 AS cor0
----
1704
3065
5808

query I rowsort
SELECT DISTINCT - - 63 * + col1 FROM tab0 AS cor0
----
5418
5733
6111

query I rowsort
SELECT ALL 84 - cor0.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 53ccb09d58ae97921962c60deb66eaac

query I rowsort
SELECT DISTINCT 92 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab0 cor2
----
92

query I rowsort
SELECT - - col0 * + 17 FROM tab0 AS cor0
----
1513
408
595

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 * - 15 col2 FROM tab2 AS cor0
----
390
405
570

query I rowsort
SELECT 46 + - cor0.col1 FROM tab1 cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to cbdfdd04b6483b24d8eb7861f0cadf04

query I rowsort
SELECT cor0.col2 + + cor0.col1 + + col1 FROM tab2 AS cor0
----
144
72
89

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab2, tab2 cor1, tab1, tab2 AS cor2
----
3645 values hashing to 6726a15019c52908f1f1d0df0cd4c1b8

query I rowsort
SELECT - col0 * col2 + col2 AS col0 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT - ( + col1 * col1 ) FROM tab1
----
-100
-169
-676

query I rowsort
SELECT - col1 * + 79 + col1 FROM tab1
----
-1014
-2028
-780

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4769
SELECT + CAST( + 32 AS SIGNED ) col2 FROM tab0 AS cor0
----
32
32
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4769
SELECT + CAST ( + 32 AS INTEGER ) col2 FROM tab0 AS cor0
----
32
32
32

query I rowsort
SELECT DISTINCT - 81 + - col2 AS col0 FROM tab1
----
-135
-138
-177

query I rowsort
SELECT col0 * col2 + + ( + col1 ) FROM tab2
----
2087
220
3019

query I rowsort
SELECT col1 * 51 FROM tab2 AS cor0
----
1581
3009
867

query I rowsort
SELECT DISTINCT - 95 + + tab2.col2 FROM tab2
----
-57
-68
-69

query I rowsort
SELECT DISTINCT col1 * + col0 * + col2 + col0 FROM tab0 AS cor0
----
3430
664207
68136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4775
SELECT DISTINCT - - col2 + + CAST( NULL AS SIGNED ) + + col1 / col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4775
SELECT DISTINCT - - col2 + + CAST ( NULL AS INTEGER ) + + col1 / col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT col2 + ( cor0.col1 ) AS col2 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-4777
SELECT DISTINCT - + cor0.col0 DIV - col2 + 31 + + cor0.col1 AS col1 FROM tab0 AS cor0
----
117
123
163

skipif mysql # not compatible
query I rowsort label-4777
SELECT DISTINCT - + cor0.col0 / - col2 + 31 + + cor0.col1 AS col1 FROM tab0 AS cor0
----
117
123
163

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4778
SELECT cor0.col0 / CAST( NULL AS SIGNED ) + + col0 * - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4778
SELECT cor0.col0 / CAST ( NULL AS INTEGER ) + + col0 * - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4779
SELECT ALL + col0 - - CAST( NULL AS SIGNED ) * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4779
SELECT ALL + col0 - - CAST ( NULL AS INTEGER ) * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col1 + col1 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT ALL + col0 + + ( + 89 ) + col1 * - ( + col0 ) FROM tab0 AS cor0
----
-1951
-3271
-7921

query I rowsort
SELECT ALL + + col0 + - col2 * + 86 * - cor0.col1 FROM tab2 cor0
----
132002
55635
71989

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + 74 + 45 col0 FROM tab2 AS cor0
----
145
146
157

query I rowsort
SELECT DISTINCT col2 + 98 AS col0 FROM tab1 AS cor0
----
152
155
194

query I rowsort
SELECT - + col0 * col1 + col0 AS col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-4786
SELECT + col0 * - col1 + + cor0.col1 DIV + col0 FROM tab2 AS cor0
----
-1343
-213
-4602

skipif mysql # not compatible
query I rowsort label-4786
SELECT + col0 * - col1 + + cor0.col1 / + col0 FROM tab2 AS cor0
----
-1343
-213
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4787
SELECT - CAST( NULL AS SIGNED ) * + 62 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4787
SELECT - CAST ( NULL AS INTEGER ) * + 62 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT 62 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

skipif mysql # not compatible
query I rowsort
SELECT + col2 * - CAST ( + col2 + col2 AS REAL ) AS col2 FROM tab1
----
-18432
-5832
-6498

query I rowsort
SELECT + col0 + 2 * + col0 AS col0 FROM tab1 AS cor0
----
192
240
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col1 * - 51 col1 FROM tab0
----
-4386
-4641
-4947

query I rowsort
SELECT - col1 * - col1 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT + 52 + cor0.col2 * - col1 AS col1 FROM tab1 AS cor0
----
-1196
-1352
-518

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 2 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

query I rowsort
SELECT - col2 * 54 * + col1 + - col0 FROM tab2 AS cor0
----
-34963
-45205
-82914

query I rowsort
SELECT - 71 + col2 AS col0 FROM tab2 AS cor0
----
-33
-44
-45

query I rowsort
SELECT - 78 * + ( col2 ) + - col2 FROM tab1 AS cor0
----
-4266
-4503
-7584

query I rowsort
SELECT ALL + cor0.col1 * col1 + col2 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT ALL tab0.col2 * - col0 FROM tab0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4800
SELECT CAST( NULL AS SIGNED ) + ( col1 ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4800
SELECT CAST ( NULL AS INTEGER ) + ( col1 ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 + - col0 * - col1 AS col2 FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 75 col0 FROM tab0 AS cor0
----
75

query I rowsort
SELECT + + 13 * + col2 FROM tab2 AS cor0
----
338
351
494

query I rowsort
SELECT col1 + - col1 * + 11 FROM tab1 AS cor0
----
-100
-130
-260

query I rowsort
SELECT + col1 + + col0 * 60 FROM tab2 AS cor0
----
451
4739
4757

query I rowsort
SELECT + col0 + 66 * - 82 * col0 AS col0 FROM tab2 AS cor0
----
-37877
-422058
-427469

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4807
SELECT col1 * - CAST( NULL AS SIGNED ) + + 80 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4807
SELECT col1 * - CAST ( NULL AS INTEGER ) + + 80 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4808
SELECT 31 DIV col1 AS col1 FROM tab1
----
1
2
3

skipif mysql # not compatible
query I rowsort label-4808
SELECT 31 / col1 AS col1 FROM tab1
----
1
2
3

query I rowsort
SELECT + 24 * - col2 FROM tab0 AS cor0
----
-1968
-24
-792

query I rowsort
SELECT - 2 * - col2 + - col2 AS col2 FROM tab0 cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 9 * col1 col1 FROM tab0 AS cor0
----
774
819
873

onlyif mysql # use DIV operator for integer division
query I rowsort label-4812
SELECT ALL - + cor0.col2 DIV - col1 FROM tab2 cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-4812
SELECT ALL - + cor0.col2 / - col1 FROM tab2 cor0
----
0
0
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4813
SELECT + CAST( col0 AS SIGNED ) * + col2 FROM tab2
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-4813
SELECT + CAST ( col0 AS INTEGER ) * + col2 FROM tab2
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * + col1 + + col2 col0 FROM tab1 cor0
----
-43
-622
-73

query I rowsort
SELECT DISTINCT 63 - + col0 FROM tab0 AS cor0
----
-26
28
39

query I rowsort
SELECT ALL - col1 * + col0 * 44 AS col0 FROM tab0 AS cor0
----
-149380
-356356
-90816

onlyif mysql # use DIV operator for integer division
query I rowsort label-4817
SELECT - col0 + - col2 DIV + col1 FROM tab1 AS cor0
----
-5
-69
-87

skipif mysql # not compatible
query I rowsort label-4817
SELECT - col0 + - col2 / + col1 FROM tab1 AS cor0
----
-5
-69
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-4818
SELECT 80 DIV 2 FROM tab2
----
40
40
40

skipif mysql # not compatible
query I rowsort label-4818
SELECT 80 / 2 FROM tab2
----
40
40
40

query I rowsort
SELECT tab1.col2 * 95 FROM tab1
----
5130
5415
9120

query I rowsort
SELECT DISTINCT + 38 + - col2 FROM tab2
----
0
11
12

query I rowsort
SELECT - 37 + + cor0.col1 * col2 + + ( + col1 ) * - 14 FROM tab1 AS cor0
----
1003
1029
393

query I rowsort
SELECT + - ( + col0 ) * cor0.col0 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT tab2.col2 * + col1 * + col2 + 10 FROM tab2
----
22609
24558
39894

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab1, tab0 cor2
----
3645 values hashing to 2e3240e8d3c0c7c6ff427f9572ba362d

query I rowsort
SELECT 86 + ( + col1 ) + - ( - col1 ) FROM tab2
----
120
148
204

onlyif mysql # use DIV operator for integer division
query I rowsort label-4826
SELECT - + ( col0 ) DIV cor0.col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4826
SELECT - + ( col0 ) / cor0.col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4827
SELECT - cor0.col0 * cor0.col2 DIV - 52 FROM tab1, tab1 AS cor0
----
9 values hashing to 21865767209fd6492ecbfb212546b274

skipif mysql # not compatible
query I rowsort label-4827
SELECT - cor0.col0 * cor0.col2 / - 52 FROM tab1, tab1 AS cor0
----
9 values hashing to 21865767209fd6492ecbfb212546b274

query I rowsort
SELECT col2 + 24 - - col1 AS col1 FROM tab0
----
122
143
197

query I rowsort
SELECT ( ( col0 ) ) + ( + 38 ) + tab0.col1 * 20 * + 27 AS col2 FROM tab0
----
46502
49267
52453

query I rowsort
SELECT DISTINCT + - 57 * + ( - col2 ) + - ( col2 * - cor0.col2 ) AS col1 FROM tab2 cor0
----
2158
2268
3610

query I rowsort
SELECT DISTINCT - - col1 + - 13 FROM tab0 AS cor0
----
73
78
84

query I rowsort
SELECT DISTINCT - col1 + + col0 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT + 94 + + col0 * - col2 AS col1 FROM tab2 AS cor0
----
-1934
-2908
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-4834
SELECT col2 * 6 DIV - col0 + col0 DIV - col2 AS col2 FROM tab1
----
-108
-6
-7

skipif mysql # not compatible
query I rowsort label-4834
SELECT col2 * 6 / - col0 + col0 / - col2 AS col2 FROM tab1
----
-108
-6
-7

query I rowsort
SELECT - col0 + + col2 * + col0 AS col1 FROM tab0 cor0
----
0
7209
768

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4836
SELECT DISTINCT CAST( NULL AS DECIMAL ) * col2 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4836
SELECT DISTINCT CAST ( NULL AS REAL ) * col2 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - 98 * col2 FROM tab1 cor0
----
-5292
-5586
-9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-4838
SELECT ALL + 99 DIV - col0 FROM tab1 AS cor0
----
-1
-1
-33

skipif mysql # not compatible
query I rowsort label-4838
SELECT ALL + 99 / - col0 FROM tab1 AS cor0
----
-1
-1
-33

query I rowsort
SELECT DISTINCT ( col0 ) - + col2 * 9 AS col2 FROM tab1 AS cor0
----
-449
-483
-784

query I rowsort
SELECT - ( col2 ) * + col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4841
SELECT DISTINCT - CAST( + col2 AS SIGNED ) * + col0 * + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4841
SELECT DISTINCT - CAST ( + col2 AS INTEGER ) * + col0 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4842
SELECT DISTINCT ( col2 ) + col2 DIV col1 AS col0 FROM tab2 AS cor0
----
26
27
40

skipif mysql # not compatible
query I rowsort label-4842
SELECT DISTINCT ( col2 ) + col2 / col1 AS col0 FROM tab2 AS cor0
----
26
27
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-4843
SELECT + col2 DIV - col2 + - col2 DIV + col2 AS col2 FROM tab1 cor0
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-4843
SELECT + col2 / - col2 + - col2 / + col2 AS col2 FROM tab1 cor0
----
-2
-2
-2

query I rowsort
SELECT DISTINCT col2 * col1 * col0 AS col2 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT DISTINCT cor0.col2 + col2 * - col1 FROM tab2 cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL - col1 * col0 * 92 AS col0 FROM tab1 AS cor0
----
-58880
-7176
-95680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 1 + col2 * 99 col0 FROM tab0 AS cor0
----
3266
8117
98

query I rowsort
SELECT 47 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

query I rowsort
SELECT DISTINCT col0 * + 11 FROM tab0 AS cor0
----
264
385
979

query I rowsort
SELECT DISTINCT - col0 * 81 AS col2 FROM tab0 AS cor0
----
-1944
-2835
-7209

query I rowsort
SELECT col1 * - ( col0 ) + + col2 AS col2 FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT - + col1 * + 87 AS col1 FROM tab0 AS cor0
----
-7482
-7917
-8439

query I rowsort
SELECT ALL - - col2 * ( - cor0.col2 ) AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT - col1 + col0 * col2 + col1 AS col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT + - col2 + 11 * - 23 AS col2 FROM tab1 AS cor0
----
-307
-310
-349

query I rowsort
SELECT DISTINCT cor0.col1 * col2 + ( + col0 ) FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT - ( + 39 ) * col0 FROM tab1 AS cor0
----
-117
-2496
-3120

query I rowsort
SELECT ALL 83 * + col0 FROM tab2 cor0
----
581
6474
6557

query I rowsort
SELECT ALL + 54 * cor0.col1 FROM tab2 cor0
----
1674
3186
918

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4860
SELECT DISTINCT + col0 * col2 + - col0 - - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4860
SELECT DISTINCT + col0 * col2 + - col0 - - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4861
SELECT CAST( - 95 AS SIGNED ) FROM tab1 AS cor0
----
-95
-95
-95

skipif mysql # not compatible
query I rowsort label-4861
SELECT CAST ( - 95 AS INTEGER ) FROM tab1 AS cor0
----
-95
-95
-95

query I rowsort
SELECT + - ( - 33 ) FROM tab2 AS cor0
----
33
33
33

query I rowsort
SELECT ALL - col0 * 99 - col2 FROM tab1 AS cor0
----
-351
-6393
-8016

onlyif mysql # use DIV operator for integer division
query I rowsort label-4864
SELECT ALL 25 DIV cor0.col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

skipif mysql # not compatible
query I rowsort label-4864
SELECT ALL 25 / cor0.col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 953562d3ce2a62a1679a1ae0451294c6

query I rowsort
SELECT DISTINCT - col1 * 13 * 12 FROM tab0
----
-13416
-14196
-15132

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 - - 26 col0 FROM tab0
----
108
27
59

query I rowsort
SELECT DISTINCT col0 * cor0.col0 + - cor0.col1 AS col2 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT - col1 * col0 + - col0 * - col0 FROM tab0 cor0
----
-1488
-178
-2170

query I rowsort
SELECT ALL + ( cor0.col0 ) FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 71 col0 FROM tab1 AS cor0
----
-71
-71
-71

query I rowsort
SELECT col0 + - col2 * col2 AS col1 FROM tab0 cor0
----
-1065
-6635
34

query I rowsort
SELECT DISTINCT + tab2.col1 * col0 * + ( col0 ) FROM tab2
----
106097
1519
358956

query I rowsort
SELECT + - 20 * - col1 + col0 * col0 - col2 FROM tab2 AS cor0
----
642
6543
7238

onlyif mysql # use DIV operator for integer division
query I rowsort label-4874
SELECT col2 * ( cor0.col2 ) DIV + ( - cor0.col1 + col2 ) AS col1 FROM tab1 AS cor0
----
104
111
69

skipif mysql # not compatible
query I rowsort label-4874
SELECT col2 * ( cor0.col2 ) / + ( - cor0.col1 + col2 ) AS col1 FROM tab1 AS cor0
----
104
111
69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4875
SELECT - CAST( NULL AS SIGNED ) + - col2 - + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4875
SELECT - CAST ( NULL AS INTEGER ) + - col2 - + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 95 * + col2 + + col0 AS col1 FROM tab0 AS cor0
----
-3111
-60
-7701

query I rowsort
SELECT DISTINCT - col0 + - col2 + col2 AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL - - ( + ( col2 ) ) AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL + + cor0.col0 * 6 FROM tab0 AS cor0
----
144
210
534

query I rowsort
SELECT - 93 + ( col1 ) FROM tab1 AS cor0
----
-67
-80
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col0 + col2 col0 FROM tab0
----
171
36
57

query I rowsort
SELECT + tab2.col0 - - ( col1 ) AS col1 FROM tab2
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - + ( + col1 ) * + col0 col0 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT ALL 94 * - tab1.col1 + + col1 AS col1 FROM tab1
----
-1209
-2418
-930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col1 ) * col1 + col2 col0 FROM tab2
----
327
3507
988

onlyif mysql # use DIV operator for integer division
query I rowsort label-4886
SELECT ALL col1 * - tab1.col2 + - col1 DIV 46 FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-4886
SELECT ALL col1 * - tab1.col2 + - col1 / 46 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT + 86 + col2 * col1 FROM tab2
----
1620
732
923

query I rowsort
SELECT - col2 + + 25 * col2 FROM tab0 AS cor0
----
1968
24
792

query I rowsort
SELECT ALL - - ( col0 ) * col1 * 30 + - 47 * cor0.col2 AS col1 FROM tab0 AS cor0
----
101803
239116
60369

query I rowsort
SELECT col0 + - 38 FROM tab2 AS cor0
----
-31
40
41

query I rowsort
SELECT ALL - 66 + + col0 FROM tab2 cor0
----
-59
12
13

query I rowsort
SELECT 52 - col1 FROM tab2 AS cor0
----
-7
21
35

query I rowsort
SELECT DISTINCT cor0.col2 * + col0 AS col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-4894
SELECT - col0 + + col0 + col0 DIV + ( 79 ) FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4894
SELECT - col0 + + col0 + col0 / + ( 79 ) FROM tab0
----
0
0
1

query I rowsort
SELECT + - 55 - - col2 FROM tab2 AS cor0
----
-17
-28
-29

query I rowsort
SELECT + cor0.col1 + col2 * + col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL tab2.col0 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL - 44 AS col1 FROM tab2
----
-44
-44
-44

query I rowsort
SELECT cor0.col2 * col2 - 10 FROM tab2 AS cor0
----
1434
666
719

query I rowsort
SELECT - 85 + - col0 * + cor0.col2 * col1 AS col2 FROM tab1 AS cor0
----
-36565
-4297
-99925

query I rowsort
SELECT + - col1 - cor0.col2 * + 97 AS col2 FROM tab1 cor0
----
-5264
-5539
-9325

query I rowsort
SELECT DISTINCT + ( - cor0.col1 ) FROM tab1, tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + col0 + col1 * 84 AS col0 FROM tab2 AS cor0
----
1507
2611
5034

query I rowsort
SELECT + col0 * + 10 FROM tab2 AS cor0
----
70
780
790

query I rowsort
SELECT ALL + col1 * - cor0.col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - cor0.col2 * + ( - 55 * col1 ) AS col2 FROM tab1 AS cor0
----
31350
68640
77220

query I rowsort
SELECT - - 4 * cor0.col1 + col0 FROM tab2 AS cor0
----
131
147
314

query I rowsort
SELECT - 48 + cor2.col0 FROM tab2, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 8a9f241ddcaf942dbde7fbbafaf8654f

query I rowsort
SELECT ALL 24 + - col2 AS col2 FROM tab0 cor0
----
-58
-9
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4910
SELECT + CAST( col0 AS SIGNED ) * + col1 AS col2 FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-4910
SELECT + CAST ( col0 AS INTEGER ) * + col1 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + 68 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

query I rowsort
SELECT - col0 - + col2 * col1 AS col2 FROM tab1 AS cor0
----
-1328
-1407
-634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * 51 * col2 col1 FROM tab2 cor0
----
32946
42687
78234

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4914
SELECT col0 * CAST( col0 + col2 AS SIGNED ) FROM tab2 AS cor0
----
238
8112
9243

skipif mysql # not compatible
query I rowsort label-4914
SELECT col0 * CAST ( col0 + col2 AS INTEGER ) FROM tab2 AS cor0
----
238
8112
9243

query I rowsort
SELECT ALL + + col0 * - col2 + - 81 AS col0 FROM tab0 AS cor0
----
-116
-7379
-873

query I rowsort
SELECT DISTINCT + col2 + col0 * 73 AS col0 FROM tab0 AS cor0
----
1785
2556
6579

query I rowsort
SELECT DISTINCT + tab0.col1 * col2 * col2 AS col2 FROM tab0
----
611884
93654
97

query I rowsort
SELECT ALL tab1.col1 + cor0.col1 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to f0be2d144c9987543bc40de00d980c15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4919
SELECT DISTINCT + + CAST( NULL AS SIGNED ) + + ( + col0 ) * + col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4919
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) + + ( + col0 ) * + col1 FROM tab2 cor0
----
NULL

query I rowsort
SELECT ALL col2 + 44 FROM tab1 AS cor0
----
101
140
98

query I rowsort
SELECT ALL - + col0 + ( col1 ) AS col1 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT ALL - col2 * + col0 + + col1 - col2 * col2 AS col1 FROM tab0 AS cor0
----
-13931
-1795
61

query I rowsort
SELECT - col0 * + ( + col1 ) - 83 * col1 AS col0 FROM tab0 AS cor0
----
-11446
-15652
-9202

query I rowsort
SELECT ALL tab1.col1 + col2 - 30 AS col0 FROM tab1
----
37
50
79

query I rowsort
SELECT ALL 66 + 90 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 4de85b31fd319b557570fc53828d1dd3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + col1 - + col2 * + tab0.col2 col2 FROM tab0
----
-6542
-917
193

query I rowsort
SELECT - 20 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to eb3a66728062963cccbd15bd2f5c9eee

query I rowsort
SELECT DISTINCT cor1.col1 + + cor0.col2 FROM tab2, tab1 cor0, tab2 AS cor1
----
113
116
127
155
71
74
85
88

query I rowsort
SELECT 73 + + col2 * + col2 AS col0 FROM tab2
----
1517
749
802

onlyif mysql # use DIV operator for integer division
query I rowsort label-4930
SELECT - col1 * + tab2.col0 DIV ( col0 ) + - col0 DIV - col1 AS col1 FROM tab2
----
-13
-31
-58

skipif mysql # not compatible
query I rowsort label-4930
SELECT - col1 * + tab2.col0 / ( col0 ) + - col0 / - col1 AS col1 FROM tab2
----
-13
-31
-58

query I rowsort
SELECT 98 + - col1 AS col2 FROM tab2
----
39
67
81

query I rowsort
SELECT ALL + cor0.col0 * - cor0.col0 FROM tab2, tab1 AS cor0
----
9 values hashing to b1a10d0ce1bd78a97a3f25900325a81f

query I rowsort
SELECT 16 + cor0.col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to ec4dc0a9a1fd02c4e386952d96b337fa

query I rowsort
SELECT DISTINCT - + col0 + ( col1 ) FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT ALL + 57 AS col0 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4936
SELECT ALL col0 DIV col2 - - col2 * + col0 AS col1 FROM tab0 AS cor0
----
70
7299
792

skipif mysql # not compatible
query I rowsort label-4936
SELECT ALL col0 / col2 - - col2 * + col0 AS col1 FROM tab0 AS cor0
----
70
7299
792

query I rowsort
SELECT DISTINCT - - col0 + - 55 AS col2 FROM tab1 AS cor0
----
-52
25
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + ( 82 ) col2 FROM tab1 AS cor0
----
18
2
79

query I rowsort
SELECT ALL + col2 * col2 + - col0 AS col1 FROM tab0
----
-34
1065
6635

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + 14 * - col2 col1 FROM tab0
----
-1059
-438
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-4941
SELECT col1 DIV + 70 + col1 AS col2 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-4941
SELECT col1 / + 70 + col1 AS col2 FROM tab0
----
87
92
98

query I rowsort
SELECT - + 0 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - + 23 * + col2 + + col1 FROM tab2 AS cor0
----
-539
-590
-857

query I rowsort
SELECT DISTINCT - cor0.col0 + cor0.col1 AS col0 FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT ALL - ( + col0 ) * + col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT cor0.col2 - + cor0.col0 * - col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT DISTINCT - ( col2 ) * col0 + - col0 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT DISTINCT - + 74 * - col1 FROM tab1 AS cor0
----
1924
740
962

onlyif mysql # use DIV operator for integer division
query I rowsort label-4949
SELECT ALL - + col1 DIV + col0 AS col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-4949
SELECT ALL - + col1 / + col0 AS col0 FROM tab1 AS cor0
----
-8
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4950
SELECT + col2 + col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4950
SELECT + col2 + col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 91 + + cor0.col0 AS col1 FROM tab2 AS cor0
----
-12
-13
-84

query I rowsort
SELECT DISTINCT + - col2 - - cor0.col2 * - 62 FROM tab0 AS cor0
----
-2079
-5166
-63

query I rowsort
SELECT + 73 + + col2 AS col1 FROM tab1 AS cor0
----
127
130
169

query I rowsort
SELECT ALL 24 + cor0.col2 * 74 FROM tab0 AS cor0
----
2466
6092
98

query I rowsort
SELECT + + 17 AS col2 FROM tab1 AS cor0
----
17
17
17

query I rowsort
SELECT ALL + - 64 + - col2 AS col2 FROM tab1 AS cor0
----
-118
-121
-160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col2 + + 69 col1 FROM tab1 AS cor0
----
-2847
-3180
-9147

query I rowsort
SELECT + col1 * + cor0.col1 + - col1 FROM tab1 cor0
----
156
650
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4959
SELECT + CAST( NULL AS SIGNED ) + - col2 - - col1 * col1 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4959
SELECT + CAST ( NULL AS INTEGER ) + - col2 - - col1 * col1 AS col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4960
SELECT DISTINCT + col0 DIV + col0 + + 37 * cor0.col1 + + cor0.col2 FROM tab2 cor0
----
1175
2210
668

skipif mysql # not compatible
query I rowsort label-4960
SELECT DISTINCT + col0 / + col0 + + 37 * cor0.col1 + + cor0.col2 FROM tab2 cor0
----
1175
2210
668

query I rowsort
SELECT ALL - - ( + col2 ) * 45 AS col2 FROM tab2 AS cor0
----
1170
1215
1710

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4962
SELECT + col0 * + CAST( NULL AS SIGNED ) + col2 + col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4962
SELECT + col0 * + CAST ( NULL AS INTEGER ) + col2 + col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + tab1.col2 + + ( - col1 ) FROM tab1
----
28
47
83

query I rowsort
SELECT DISTINCT - col0 + col1 + col0 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL - + col1 * col1 * col1 FROM tab1 cor0
----
-1000
-17576
-2197

query I rowsort
SELECT DISTINCT col2 + + ( col1 ) AS col1 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4967
SELECT ALL col0 + CAST( NULL AS DECIMAL ) * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4967
SELECT ALL col0 + CAST ( NULL AS REAL ) * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + ( ( col0 ) ) AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - col2 * - col2 + col1 * + col2 FROM tab1 AS cor0
----
10464
3819
4320

query I rowsort
SELECT ALL - + col0 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + - 52 + - col2 * cor0.col2 * + cor0.col0 + - col1 * - col2 AS col0 FROM tab1 AS cor0
----
-207418
-736084
-7396

query I rowsort
SELECT 33 * - ( - cor0.col2 * + col0 ) FROM tab0 cor0
----
1155
240834
26136

query I rowsort
SELECT - 55 * col0 * - col0 FROM tab0
----
31680
435655
67375

query I rowsort
SELECT + 87 * col0 FROM tab0
----
2088
3045
7743

query I rowsort
SELECT DISTINCT 52 FROM tab0, tab0 AS cor0
----
52

query I rowsort
SELECT col1 + - 14 * + col0 FROM tab0 AS cor0
----
-1155
-250
-393

onlyif mysql # use DIV operator for integer division
query I rowsort label-4977
SELECT 60 DIV cor0.col1 + - col2 FROM tab2 AS cor0
----
-25
-26
-35

skipif mysql # not compatible
query I rowsort label-4977
SELECT 60 / cor0.col1 + - col2 FROM tab2 AS cor0
----
-25
-26
-35

query I rowsort
SELECT + - 60 + - cor0.col0 * col2 FROM tab2 cor0
----
-2088
-249
-3062

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4979
SELECT + CAST( NULL AS SIGNED ) + 74 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4979
SELECT + CAST ( NULL AS INTEGER ) + 74 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4980
SELECT - + col0 + col1 * CAST( 71 AS SIGNED ) FROM tab2 AS cor0
----
1128
2194
4111

skipif mysql # not compatible
query I rowsort label-4980
SELECT - + col0 + col1 * CAST ( 71 AS INTEGER ) FROM tab2 AS cor0
----
1128
2194
4111

query I rowsort
SELECT ALL + col1 + - cor0.col1 * + 22 FROM tab1 cor0
----
-210
-273
-546

query I rowsort
SELECT ALL - 10 + col0 * + col0 - 80 FROM tab0 AS cor0
----
1135
486
7831

query I rowsort
SELECT DISTINCT + col1 + col2 - ( + col0 ) * cor0.col2 FROM tab0 AS cor0
----
-673
-7125
63

onlyif mysql # use DIV operator for integer division
query I rowsort label-4984
SELECT 15 DIV + 48 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-4984
SELECT 15 / + 48 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 col0 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT DISTINCT col1 * cor0.col2 * col0 FROM tab2 AS cor0
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-4987
SELECT - col0 * col0 DIV - 76 + col1 FROM tab0
----
113
195
93

skipif mysql # not compatible
query I rowsort label-4987
SELECT - col0 * col0 / - 76 + col1 FROM tab0
----
113
195
93

query I rowsort
SELECT 40 AS col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to e4d10f7d6c34a281f524e45e82ebd2a0

query I rowsort
SELECT DISTINCT col1 * col1 * ( col0 * - col0 ) AS col2 FROM tab1
----
-1081600
-409600
-6084

query I rowsort
SELECT + - cor0.col1 + col2 * col2 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT - - col1 + col0 * + cor0.col1 + - col0 AS col2 FROM tab1 AS cor0
----
101
586
973

query I rowsort
SELECT + cor0.col2 * - col2 * col0 + - col0 * col1 * - col1 + cor0.col1 AS col1 FROM tab2 cor0
----
-91228
1655
218849

query I rowsort
SELECT DISTINCT + col2 + - col0 * - col0 * + col2 FROM tab1 AS cor0
----
233529
540
614496

query I rowsort
SELECT + col0 - col2 AS col0 FROM tab1
----
-16
-51
7

query I rowsort
SELECT col1 * - col2 - + col1 FROM tab1
----
-1261
-1430
-580

query I rowsort
SELECT col1 FROM tab1 WHERE col1 BETWEEN NULL AND col2 AND NOT NULL NOT BETWEEN NULL AND ( - col0 * col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 79 * col2 + col1 + col1 col2 FROM tab0 cor0
----
-2435
-6296
115

query I rowsort
SELECT col1 * cor0.col0 AS col2 FROM tab0 cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-4999
SELECT col2 DIV + col2 + - tab0.col0 AS col2 FROM tab0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-4999
SELECT col2 / + col2 + - tab0.col0 AS col2 FROM tab0
----
-23
-34
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 11 ) * col2 col1 FROM tab2
----
286
297
418

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5001
SELECT CAST( NULL AS SIGNED ) * col2 * + col1 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5001
SELECT CAST ( NULL AS INTEGER ) * col2 * + col1 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 * + 67 * col2 AS col2 FROM tab2
----
-45292
-48843
-96748

query I rowsort
SELECT ALL + 55 * col1 FROM tab2
----
1705
3245
935

query I rowsort
SELECT 88 + col2 * + cor0.col2 FROM tab0 AS cor0
----
1177
6812
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5005
SELECT - 40 + + col0 DIV - col2 AS col2 FROM tab0
----
-40
-41
-75

skipif mysql # not compatible
query I rowsort label-5005
SELECT - 40 + + col0 / - col2 AS col2 FROM tab0
----
-40
-41
-75

query I rowsort
SELECT ALL - cor0.col1 * 7 FROM tab0 AS cor0
----
-602
-637
-679

query I rowsort
SELECT 35 + - col2 AS col1 FROM tab0
----
-47
2
34

query I rowsort
SELECT ( + 21 ) + - col1 AS col1 FROM tab0 AS cor0
----
-65
-70
-76

query I rowsort
SELECT ALL - + col0 * + col0 + col0 FROM tab0 AS cor0
----
-1190
-552
-7832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col0 ) + - col2 * + col2 + col0 * - cor0.col2 * col0 col2 FROM tab0 AS cor0
----
-1191
-20073
-656157

query I rowsort
SELECT ALL + - col1 * + col2 + - col2 * - col0 AS col2 FROM tab0 cor0
----
-164
-2046
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5012
SELECT DISTINCT + col1 * - col1 * col0 + cor0.col0 DIV + cor0.col2 FROM tab0 AS cor0
----
-177504
-329280
-737008

skipif mysql # not compatible
query I rowsort label-5012
SELECT DISTINCT + col1 * - col1 * col0 + cor0.col0 / + cor0.col2 FROM tab0 AS cor0
----
-177504
-329280
-737008

query I rowsort
SELECT ALL - + col0 * + col2 - - col0 FROM tab0 cor0
----
-7209
-768
0

query I rowsort
SELECT ALL + 55 AS col2 FROM tab1
----
55
55
55

query I rowsort
SELECT ALL + 84 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT DISTINCT - col0 * col1 * 20 + 7 FROM tab2 cor0
----
-26853
-4333
-92033

query I rowsort
SELECT ALL - 35 * + col1 + + col0 AS col2 FROM tab1 AS cor0
----
-286
-375
-907

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - col0 + col0 col2 FROM tab0 AS cor0
----
1260
600
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-5019
SELECT DISTINCT - col0 + col2 DIV - col2 FROM tab1 AS cor0
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-5019
SELECT DISTINCT - col0 + col2 / - col2 FROM tab1 AS cor0
----
-4
-65
-81

query I rowsort
SELECT DISTINCT - ( col1 ) + col0 + + col1 FROM tab2 AS cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col0 col1 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT + cor0.col1 * + 78 + col1 FROM tab1 AS cor0
----
1027
2054
790

query I rowsort
SELECT col2 + + col1 * - col0 AS col2 FROM tab1 AS cor0
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-5024
SELECT DISTINCT + + cor0.col2 DIV col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-5024
SELECT DISTINCT + + cor0.col2 / col1 FROM tab1 AS cor0
----
2
5
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5025
SELECT ALL - + cor0.col0 + CAST( + 42 AS SIGNED ) * col2 FROM tab1 AS cor0
----
2265
2330
3952

skipif mysql # not compatible
query I rowsort label-5025
SELECT ALL - + cor0.col0 + CAST ( + 42 AS INTEGER ) * col2 FROM tab1 AS cor0
----
2265
2330
3952

onlyif mysql # use DIV operator for integer division
query I rowsort label-5026
SELECT - col0 DIV col0 + col1 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-5026
SELECT - col0 / col0 + col1 FROM tab1 AS cor0
----
12
25
9

query I rowsort
SELECT + col2 * 73 + - col2 AS col1 FROM tab2 AS cor0
----
1872
1944
2736

query I rowsort
SELECT ( + col2 ) + col0 AS col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + + col0 + col1 * - col1 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT - - col1 + + ( cor0.col1 ) FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT 67 * cor0.col2 FROM tab1, tab2 AS cor0
----
9 values hashing to b11f3c4c7d7b4f88c2926815f7598a2f

query I rowsort
SELECT DISTINCT - + col2 * 55 + + col1 FROM tab2 AS cor0
----
-1371
-1454
-2073

query I rowsort
SELECT - - 82 AS col0 FROM tab2 cor0
----
82
82
82

query I rowsort
SELECT ALL - ( 87 ) * col2 AS col2 FROM tab2 cor0
----
-2262
-2349
-3306

query I rowsort
SELECT - col0 - + ( tab2.col2 ) FROM tab2
----
-104
-117
-34

query I rowsort
SELECT - 63 * cor0.col1 AS col0 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 727559296eb3cde53fae38266ab5c3d7

query I rowsort
SELECT ALL + 19 * col1 AS col2 FROM tab1 AS cor0
----
190
247
494

query I rowsort
SELECT 6 AS col2 FROM tab0 cor0
----
6
6
6

query I rowsort
SELECT ALL 21 + - col0 AS col1 FROM tab1 cor0
----
-43
-59
18

query I rowsort
SELECT - - 73 * col2 AS col0 FROM tab1 AS cor0
----
3942
4161
7008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * col1 col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT 17 FROM tab1 cor0
----
17

query I rowsort
SELECT 52 * - 29 FROM tab1 AS cor0
----
-1508
-1508
-1508

query I rowsort
SELECT - - 17 + 65 FROM tab0 AS cor0
----
82
82
82

query I rowsort
SELECT 0 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT - col0 + col0 * col2 * tab0.col1 + - tab0.col2 FROM tab0
----
3359
663947
68055

query I rowsort
SELECT ALL tab1.col0 * + 8 + ( col1 ) * - 72 + col2 AS col2 FROM tab1
----
-151
-1794
-200

query I rowsort
SELECT col1 - - col2 * + col0 FROM tab1
----
188
3658
7693

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5049
SELECT ALL CAST( 62 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
62
62
62

skipif mysql # not compatible
query I rowsort label-5049
SELECT ALL CAST ( 62 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
62
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5050
SELECT - 54 DIV - col0 + col0 FROM tab1 AS cor0
----
21
64
80

skipif mysql # not compatible
query I rowsort label-5050
SELECT - 54 / - col0 + col0 FROM tab1 AS cor0
----
21
64
80

query I rowsort
SELECT - 17 + col0 AS col0 FROM tab0 AS cor0
----
18
7
72

query I rowsort
SELECT col1 - col0 * 96 FROM tab0
----
-2218
-3263
-8453

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 61 col0 FROM tab1
----
61
61
61

query I rowsort
SELECT + 61 + - col0 FROM tab1 AS cor0
----
-19
-3
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-5055
SELECT ( col1 ) + col2 DIV col0 AS col2 FROM tab2
----
17
34
59

skipif mysql # not compatible
query I rowsort label-5055
SELECT ( col1 ) + col2 / col0 AS col2 FROM tab2
----
17
34
59

query I rowsort
SELECT - - cor0.col1 + 43 * col1 FROM tab1 AS cor0
----
1144
440
572

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5057
SELECT DISTINCT - CAST( - cor0.col0 AS SIGNED ) * cor0.col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-5057
SELECT DISTINCT - CAST ( - cor0.col0 AS INTEGER ) * cor0.col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-5058
SELECT ALL col2 DIV col1 + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-5058
SELECT ALL col2 / col1 + col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5059
SELECT ALL col0 + - CAST( - col0 AS SIGNED ) FROM tab1 AS cor0
----
128
160
6

skipif mysql # not compatible
query I rowsort label-5059
SELECT ALL col0 + - CAST ( - col0 AS INTEGER ) FROM tab1 AS cor0
----
128
160
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5060
SELECT ALL cor0.col2 * + CAST( NULL AS DECIMAL ) + - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5060
SELECT ALL cor0.col2 * + CAST ( NULL AS REAL ) + - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col0 * col1 + col0 AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT - - col1 - - ( cor0.col0 + - col1 ) * + col0 FROM tab1 cor0
----
-43
3466
5373

query I rowsort
SELECT 82 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

onlyif mysql # use DIV operator for integer division
query I rowsort label-5064
SELECT ALL tab0.col1 - + col0 DIV col0 FROM tab0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-5064
SELECT ALL tab0.col1 - + col0 / col0 FROM tab0
----
85
90
96

query I rowsort
SELECT col1 + + tab1.col2 + col0 FROM tab1
----
131
189
83

query I rowsort
SELECT ALL tab1.col1 + + 56 * - tab1.col1 FROM tab1
----
-1430
-550
-715

query I rowsort
SELECT cor0.col2 * + col2 + + col0 FROM tab2 cor0
----
1523
736
754

query I rowsort
SELECT DISTINCT + 88 AS col2 FROM tab1, tab2 AS cor0, tab1 cor1
----
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-5069
SELECT ALL col1 DIV + 72 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5069
SELECT ALL col1 / + 72 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT cor0.col1 * cor0.col0 * col1 + + col0 FROM tab2 cor0
----
22910
271596
6734

query I rowsort
SELECT col2 * 26 FROM tab0
----
2132
26
858

query I rowsort
SELECT + cor0.col2 + + 79 FROM tab1 AS cor0
----
133
136
175

onlyif mysql # use DIV operator for integer division
query I rowsort label-5073
SELECT - col0 + + col1 DIV col0 col1 FROM tab2 AS cor0
----
-3
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5073
SELECT - col0 + + col1 / col0 col1 FROM tab2 AS cor0
----
-3
-78
-79

query I rowsort
SELECT - 8 + col0 AS col0 FROM tab2
----
-1
70
71

query I rowsort
SELECT + cor0.col2 * - cor0.col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 309d8ba6d1ea89e6795c82dda466e1ce

query I rowsort
SELECT - 90 + col0 FROM tab1
----
-10
-26
-87

query I rowsort
SELECT ALL - + col2 * + col1 + - cor0.col1 * + 96 FROM tab1 cor0
----
-1530
-2496
-3900

query I rowsort
SELECT + 5 + - col0 FROM tab0
----
-19
-30
-84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5079
SELECT CAST( NULL AS SIGNED ) * - 53 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5079
SELECT CAST ( NULL AS INTEGER ) * - 53 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 - col2 col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + ( - 86 ) AS col1 FROM tab1 AS cor0
----
-86
-86
-86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5082
SELECT DISTINCT CAST( + col1 AS SIGNED ) + - col1 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5082
SELECT DISTINCT CAST ( + col1 AS INTEGER ) + - col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT 33 * + col1 + - col0 AS col1 FROM tab1 AS cor0
----
266
349
855

query I rowsort
SELECT DISTINCT - 5 * - cor0.col0 + col0 + - col1 * col1 AS col1 FROM tab2 AS cor0
----
-3013
-919
185

query I rowsort
SELECT DISTINCT - ( + col0 ) * col0 + + col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT ALL - ( + cor0.col1 ) * cor0.col2 AS col2 FROM tab2 cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-5087
SELECT ALL + 96 DIV col0 FROM tab0 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-5087
SELECT ALL + 96 / col0 FROM tab0 AS cor0
----
1
2
4

query I rowsort
SELECT DISTINCT + col1 * + col0 - col2 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT col1 * - col2 * 99 AS col1 FROM tab0 AS cor0
----
-280962
-738738
-9603

query I rowsort
SELECT ALL + - col2 + - col0 AS col2 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5091
SELECT ALL col0 DIV + cor0.col1 AS col2 FROM tab2 cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-5091
SELECT ALL col0 / + cor0.col1 AS col2 FROM tab2 cor0
----
0
1
4

query I rowsort
SELECT DISTINCT 97 + cor0.col1 AS col1 FROM tab1 AS cor0
----
107
110
123

query I rowsort
SELECT + 93 * - col2 AS col0 FROM tab2 cor0
----
-2418
-2511
-3534

onlyif mysql # use DIV operator for integer division
query I rowsort label-5094
SELECT + col2 DIV col0 + - tab0.col0 * ( col0 ) AS col1 FROM tab0
----
-1225
-575
-7921

skipif mysql # not compatible
query I rowsort label-5094
SELECT + col2 / col0 + - tab0.col0 * ( col0 ) AS col1 FROM tab0
----
-1225
-575
-7921

query I rowsort
SELECT - cor1.col1 FROM tab1, tab2 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 96e9ef2950805bca93a295eeea43ef5b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * ( col1 ) col2 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT 63 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

query I rowsort
SELECT ALL + col1 * + col0 * + col1 + col2 * + cor0.col0 + - col1 * - col1 FROM tab2 cor0
----
26122
277027
7877

query I rowsort
SELECT DISTINCT + col0 * + col0 - - 46 AS col2 FROM tab2 AS cor0
----
6130
6287
95

query I rowsort
SELECT - - col2 * - ( 30 ) FROM tab2 AS cor0
----
-1140
-780
-810

query I rowsort
SELECT ALL + col1 * 34 FROM tab0 AS cor0
----
2924
3094
3298

query I rowsort
SELECT DISTINCT cor0.col1 + 93 FROM tab1 AS cor0
----
103
106
119

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5103
SELECT CAST( - cor0.col2 AS SIGNED ) * - col0 - ( 63 ) * cor0.col2 AS col1 FROM tab1 AS cor0
----
-3240
1632
57

skipif mysql # not compatible
query I rowsort label-5103
SELECT CAST ( - cor0.col2 AS INTEGER ) * - col0 - ( 63 ) * cor0.col2 AS col1 FROM tab1 AS cor0
----
-3240
1632
57

query I rowsort
SELECT + ( ( + col1 ) ) + - cor0.col1 * - col2 AS col2 FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT - col2 * - col2 - - col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT DISTINCT ( 54 ) + col0 * + 12 FROM tab0 AS cor0
----
1122
342
474

query I rowsort
SELECT + col0 * 0 + cor0.col2 AS col0 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5108
SELECT - ( + ( col0 ) ) * 62 + col0 DIV + col0 AS col2 FROM tab0 AS cor0
----
-1487
-2169
-5517

skipif mysql # not compatible
query I rowsort label-5108
SELECT - ( + ( col0 ) ) * 62 + col0 / + col0 AS col2 FROM tab0 AS cor0
----
-1487
-2169
-5517

query I rowsort
SELECT + col1 * col2 + + col2 * - ( 67 ) FROM tab1 AS cor0
----
-2214
-3249
-5184

query I rowsort
SELECT + 25 * + col0 AS col1 FROM tab0 cor0
----
2225
600
875

onlyif mysql # use DIV operator for integer division
query I rowsort label-5111
SELECT 90 DIV + 30 + + col0 FROM tab0 AS cor0
----
27
38
92

skipif mysql # not compatible
query I rowsort label-5111
SELECT 90 / + 30 + + col0 FROM tab0 AS cor0
----
27
38
92

query I rowsort
SELECT - + col0 * + col0 + 75 FROM tab2 AS cor0
----
-6009
-6166
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 71 col1 FROM tab1
----
-71
-71
-71

query I rowsort
SELECT DISTINCT + col1 * col0 + + col2 * + col2 AS col1 FROM tab0
----
14823
3153
3396

query I rowsort
SELECT ALL - col1 + + col0 * col2 + - col1 FROM tab0
----
-159
620
7116

onlyif mysql # use DIV operator for integer division
query I rowsort label-5116
SELECT tab2.col2 * col0 - tab2.col0 DIV + col0 FROM tab2
----
188
2027
3001

skipif mysql # not compatible
query I rowsort label-5116
SELECT tab2.col2 * col0 - tab2.col0 / + col0 FROM tab2
----
188
2027
3001

query I rowsort
SELECT - col2 - col0 AS col2 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT col0 AS col0 FROM tab0 WHERE ( + col0 ) <> col2
----
24
35
89

query I rowsort
SELECT ALL + col0 + col0 * - col0 FROM tab2
----
-42
-6006
-6162

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT - col0 + + col2 / + col0 IN ( - col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT col0 AS col1 FROM tab0 WHERE NOT NULL BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT + col1 * + tab2.col1 * + col0 AS col1 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT col0 * - col0 + - col2 AS col1 FROM tab1
----
-4153
-63
-6496

query I rowsort
SELECT - tab2.col1 AS col0 FROM tab2 WHERE NULL NOT IN ( + col1 * col2 )
----

query I rowsort
SELECT + col0 AS col2 FROM tab0 WHERE + col0 * col1 / col0 <> + col1 + + col0
----
24
35
89

query I rowsort
SELECT - col2 + - col0 * col1 + col1 * col0 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT ALL + col1 * col0 - col0 FROM tab1
----
576
75
960

query I rowsort
SELECT DISTINCT - col1 + col2 * + col1 FROM tab2
----
1475
629
806

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE - col0 * col1 / col0 < ( col1 + col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-5130
SELECT col0 DIV - col0 AS col1 FROM tab1 WHERE NOT ( + col1 ) NOT BETWEEN col1 AND + col2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5130
SELECT col0 / - col0 AS col1 FROM tab1 WHERE NOT ( + col1 ) NOT BETWEEN col1 AND + col2
----
-1
-1
-1

query I rowsort
SELECT + col0 FROM tab0 WHERE - col0 NOT IN ( tab0.col0 )
----
24
35
89

query I rowsort
SELECT + col2 - + col2 AS col1 FROM tab2 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - col2 col1 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT col1 + col0 + col0 AS col1 FROM tab2 cor0
----
175
215
45

query I rowsort
SELECT + col1 - + cor0.col0 * + col2 AS col2 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT col1 * col1 FROM tab2 AS cor0 WHERE NOT ( NULL ) BETWEEN ( + col2 ) AND + col2 - + col2
----

query I rowsort
SELECT DISTINCT col2 * col0 * + col0 + - col1 * + col2 * - col1 AS col1 FROM tab2 AS cor0
----
248140
248690
27270

query I rowsort
SELECT ALL col2 + col1 + - col0 FROM tab1 AS cor0
----
29
3
77

query III rowsort
SELECT ALL * FROM tab2 cor0 WHERE NOT NULL BETWEEN col0 AND NULL
----

query I rowsort
SELECT DISTINCT + col2 * - col2 + + col2 AS col0 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT col2 * - col2 * + tab0.col0 AS col1 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT ALL - col2 AS col1 FROM tab2 WHERE col1 * col1 + + col2 NOT BETWEEN + col1 AND + col0 * col2
----
-26
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-5143
SELECT ALL col2 DIV col0 + - col0 * - col0 + col0 * col2 FROM tab2 AS cor0
----
241
8112
9243

skipif mysql # not compatible
query I rowsort label-5143
SELECT ALL col2 / col0 + - col0 * - col0 + col0 * col2 FROM tab2 AS cor0
----
241
8112
9243

onlyif mysql # use DIV operator for integer division
query I rowsort label-5144
SELECT ALL col2 * + col1 + cor0.col2 + col1 * cor0.col2 DIV + col1 AS col1 FROM tab2 AS cor0
----
1586
722
891

skipif mysql # not compatible
query I rowsort label-5144
SELECT ALL col2 * + col1 + cor0.col2 + col1 * cor0.col2 / + col1 AS col1 FROM tab2 AS cor0
----
1586
722
891

onlyif mysql # use DIV operator for integer division
query I rowsort label-5145
SELECT DISTINCT col1 + col2 - - ( col2 ) DIV col1 FROM tab2 AS cor0
----
57
58
85

skipif mysql # not compatible
query I rowsort label-5145
SELECT DISTINCT col1 + col2 - - ( col2 ) / col1 FROM tab2 AS cor0
----
57
58
85

query I rowsort
SELECT + cor0.col2 * col1 - + col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT DISTINCT col2 * + ( cor0.col2 ) * col2 + + ( - col2 + col1 ) AS col2 FROM tab1 AS cor0
----
157436
185146
884653

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5148
SELECT ALL - col0 * + CAST( col0 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-5148
SELECT ALL - col0 * + CAST ( col0 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL col1 * + 44 * col0 AS col2 FROM tab2 AS cor0
----
202488
59092
9548

query I rowsort
SELECT DISTINCT - col0 + + cor0.col1 * - col0 AS col2 FROM tab1 cor0
----
-1120
-704
-81

query I rowsort
SELECT - col1 * - col2 - + 53 FROM tab2 cor0
----
1481
593
784

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5152
SELECT DISTINCT + + col0 * CAST( NULL AS SIGNED ) * + cor0.col2 col0 FROM tab1 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5152
SELECT DISTINCT + + col0 * CAST ( NULL AS INTEGER ) * + cor0.col2 col0 FROM tab1 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5153
SELECT ALL + col1 DIV - CAST( + col2 AS SIGNED ) FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5153
SELECT ALL + col1 / - CAST ( + col2 AS INTEGER ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - - col0 + col1 * - 38 AS col2 FROM tab0 cor0
----
-3244
-3369
-3651

query I rowsort
SELECT + - col2 + - 35 * + col2 * + col1 AS col0 FROM tab0 AS cor0
----
-261252
-3396
-99363

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5156
SELECT + CAST( 72 AS SIGNED ) + - col2 * col0 col1 FROM tab2 AS cor0
----
-117
-1956
-2930

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5156
SELECT + CAST ( 72 AS INTEGER ) + - col2 * col0 col1 FROM tab2 AS cor0
----
-117
-1956
-2930

onlyif mysql # use DIV operator for integer division
query I rowsort label-5157
SELECT ALL - col1 DIV + col0 + col2 FROM tab1
----
46
57
96

skipif mysql # not compatible
query I rowsort label-5157
SELECT ALL - col1 / + col0 + col2 FROM tab1
----
46
57
96

query I rowsort
SELECT DISTINCT + col0 * 89 FROM tab0 AS cor0
----
2136
3115
7921

query I rowsort
SELECT 48 + col2 FROM tab2 AS cor0
----
74
75
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-5160
SELECT ALL + ( col2 ) * col1 + + col2 DIV cor0.col1 FROM tab1 AS cor0
----
1255
1406
575

skipif mysql # not compatible
query I rowsort label-5160
SELECT ALL + ( col2 ) * col1 + + col2 / cor0.col1 FROM tab1 AS cor0
----
1255
1406
575

query I rowsort
SELECT tab1.col1 + + col2 + + col1 FROM tab1
----
106
122
77

query I rowsort
SELECT + col2 + - col1 + tab2.col2 * - col2 * col2 AS col0 FROM tab2
----
-17609
-19687
-54851

query I rowsort
SELECT DISTINCT 99 - - 95 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
194

onlyif mysql # use DIV operator for integer division
query I rowsort label-5164
SELECT + 0 + col1 DIV ( cor0.col1 ) AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5164
SELECT + 0 + col1 / ( cor0.col1 ) AS col0 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 + - col2 col2 FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT DISTINCT + col0 * col1 + 10 AS col2 FROM tab1 AS cor0
----
1050
650
88

query I rowsort
SELECT ALL 64 * + col2 AS col2 FROM tab2 AS cor0
----
1664
1728
2432

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT ( + col2 ) BETWEEN col0 * - col1 AND col2
----

query I rowsort
SELECT ALL - col0 * - col2 - col2 AS col1 FROM tab1
----
108
3591
7584

query I rowsort
SELECT DISTINCT - tab1.col1 * + col0 - + col0 FROM tab1
----
-1120
-704
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-5171
SELECT + col0 * - col0 DIV col0 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-5171
SELECT + col0 * - col0 / col0 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5172
SELECT col0 + - col2 DIV col2 col1 FROM tab1
----
2
63
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5172
SELECT col0 + - col2 / col2 col1 FROM tab1
----
2
63
79

query I rowsort
SELECT 10 * - col2 + col1 * col1 FROM tab0
----
7066
7461
9399

query I rowsort
SELECT + col2 - col1 * 7 FROM tab1
----
-128
-13
5

query I rowsort
SELECT DISTINCT 84 AS col1 FROM tab1, tab2, tab0 AS cor0
----
84

query I rowsort
SELECT tab2.col2 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT DISTINCT col0 - + col1 * - col1 AS col1 FROM tab0
----
7420
8370
9444

query I rowsort
SELECT - ( + 48 ) + - col0 AS col0 FROM tab1 AS cor0
----
-112
-128
-51

skipif mysql # not compatible
query I rowsort
SELECT - + CAST ( + 11 AS REAL ) AS col0 FROM tab0 AS cor0
----
-11
-11
-11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5180
SELECT - CAST( NULL AS SIGNED ) * 17 + + col0 * cor0.col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5180
SELECT - CAST ( NULL AS INTEGER ) * 17 + + col0 * cor0.col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5181
SELECT DISTINCT - + CAST( + col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-5181
SELECT DISTINCT - + CAST ( + col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL col0 + col2 * + col2 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT - + col0 * - 62 + col0 FROM tab2 AS cor0
----
441
4914
4977

query I rowsort
SELECT - cor0.col0 + 11 * col1 AS col2 FROM tab2 AS cor0
----
108
334
571

query I rowsort
SELECT + col0 * + 0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + - ( - col2 ) * - col2 + col2 AS col0 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT + 90 + - col1 * col2 AS col0 FROM tab2 AS cor0
----
-1444
-556
-747

query I rowsort
SELECT - cor0.col0 + col2 * col0 * col0 AS col2 FROM tab2 AS cor0
----
1316
158106
237079

query I rowsort
SELECT tab2.col2 * ( + 99 ) FROM tab2
----
2574
2673
3762

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5190
SELECT ALL tab2.col1 * CAST( ( + col0 ) AS SIGNED ) AS col2 FROM tab2
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-5190
SELECT ALL tab2.col1 * CAST ( ( + col0 ) AS INTEGER ) AS col2 FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT col0 * 12 FROM tab0
----
1068
288
420

query I rowsort
SELECT - col1 * 98 + + 13 AS col1 FROM tab2
----
-1653
-3025
-5769

query I rowsort
SELECT + col1 + 51 AS col2 FROM tab2
----
110
68
82

query I rowsort
SELECT DISTINCT col1 * 38 FROM tab0 AS cor0
----
3268
3458
3686

query I rowsort
SELECT + - col0 * + ( - col0 ) FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL - 27 FROM tab1, tab2 cor0, tab0 AS cor1
----
27 values hashing to 0259a67676b131a4843853be4811b775

query I rowsort
SELECT + col2 * + 63 FROM tab2
----
1638
1701
2394

onlyif mysql # use DIV operator for integer division
query I rowsort label-5198
SELECT ALL + col1 DIV + ( col0 ) AS col2 FROM tab1
----
0
0
8

skipif mysql # not compatible
query I rowsort label-5198
SELECT ALL + col1 / + ( col0 ) AS col2 FROM tab1
----
0
0
8

query I rowsort
SELECT ALL 11 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5200
SELECT ALL + CAST( NULL AS SIGNED ) * col2 * + col0 + - 81 * + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5200
SELECT ALL + CAST ( NULL AS INTEGER ) * col2 * + col0 + - 81 * + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col0 * + cor0.col0 + + col0 + col0 FROM tab2 cor0
----
6240
63
6399

query I rowsort
SELECT DISTINCT + + 74 - ( col0 ) AS col1 FROM tab0 AS cor0
----
-15
39
50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5203
SELECT - + CAST( NULL AS SIGNED ) * + col1 + + col0 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5203
SELECT - + CAST ( NULL AS INTEGER ) * + col1 + + col0 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

query IIIIIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 cor0 CROSS JOIN tab2, tab0 AS cor1, tab1, tab0 AS cor2, tab0
----
13122 values hashing to 8718ce71186c0fb3b188ed4f5cf992d1

query I rowsort
SELECT 25 * - 75 FROM tab1 AS cor0
----
-1875
-1875
-1875

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * 2 col0 FROM tab1
----
20
26
52

query I rowsort
SELECT ALL ( - col2 ) + + col0 AS col1 FROM tab1
----
-16
-51
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5208
SELECT + 2 + + col0 + col2 * + CAST( NULL AS SIGNED ) * col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5208
SELECT + 2 + + col0 + col2 * + CAST ( NULL AS INTEGER ) * col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + cor0.col2 * col1 * col1 + col0 * 90 AS col0 FROM tab0 AS cor0
----
12559
246228
687052

query I rowsort
SELECT ALL - 55 + - cor0.col2 * cor0.col2 AS col1 FROM tab1, tab1 AS cor0, tab2 cor1, tab2 AS cor2
----
81 values hashing to c88751cf1f81730c2906a30a0f1db306

onlyif mysql # use DIV operator for integer division
query I rowsort label-5211
SELECT - - ( col1 ) * - col0 + col1 * col1 + col2 DIV 76 AS col1 FROM tab1 AS cor0
----
-540
-870
598

skipif mysql # not compatible
query I rowsort label-5211
SELECT - - ( col1 ) * - col0 + col1 * col1 + col2 / 76 AS col1 FROM tab1 AS cor0
----
-540
-870
598

onlyif mysql # use DIV operator for integer division
query I rowsort label-5212
SELECT cor0.col0 DIV - ( + col1 ) + - col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-5212
SELECT cor0.col0 / - ( + col1 ) + - col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col0 ) + - col1 * 4 col2 FROM tab0 AS cor0
----
-275
-320
-353

onlyif mysql # use DIV operator for integer division
query I rowsort label-5214
SELECT col0 DIV + ( 87 ) FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5214
SELECT col0 / + ( 87 ) FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT - - col1 + - col1 + col2 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT - col0 - - 89 * col1 FROM tab0 AS cor0
----
7630
8010
8598

query I rowsort
SELECT ALL col1 + col0 * - col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ( - col2 + - 18 ) FROM tab1
----
-114
-72
-75

query I rowsort
SELECT col0 - ( col2 ) AS col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT - - col2 + col0 * + cor0.col0 AS col0 FROM tab0 AS cor0
----
1226
609
8003

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5221
SELECT ALL - - col1 * CAST( col0 + + col1 AS SIGNED ) FROM tab0 cor0
----
12804
16380
9460

skipif mysql # not compatible
query I rowsort label-5221
SELECT ALL - - col1 * CAST ( col0 + + col1 AS INTEGER ) FROM tab0 cor0
----
12804
16380
9460

query I rowsort
SELECT DISTINCT 17 + + col0 FROM tab2 AS cor0
----
24
95
96

query I rowsort
SELECT - 2 + + col2 AS col1 FROM tab2 AS cor0
----
24
25
36

query I rowsort
SELECT DISTINCT - ( col1 ) + + ( col0 ) FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT + col2 * col1 * col1 + col1 FROM tab2 cor0
----
10999
25978
90565

query I rowsort
SELECT + + col1 * + col0 + - col1 AS col1 FROM tab0 AS cor0
----
1978
3298
8008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 30 col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5228
SELECT + col2 * cor0.col2 + + CAST( + col2 AS SIGNED ) * col0 AS col1 FROM tab1 AS cor0
----
16896
3078
6897

skipif mysql # not compatible
query I rowsort label-5228
SELECT + col2 * cor0.col2 + + CAST ( + col2 AS INTEGER ) * col0 AS col1 FROM tab1 AS cor0
----
16896
3078
6897

query I rowsort
SELECT ALL + 20 * + col1 FROM tab1 AS cor0
----
200
260
520

query I rowsort
SELECT + cor0.col0 + col1 * 76 FROM tab0 AS cor0
----
6560
7005
7407

query I rowsort
SELECT DISTINCT - col0 + col0 * 90 AS col2 FROM tab2 AS cor0
----
623
6942
7031

query I rowsort
SELECT - - col2 * ( col0 + - col2 ) AS col2 FROM tab2 AS cor0
----
-540
1352
1558

onlyif mysql # use DIV operator for integer division
query I rowsort label-5233
SELECT ALL - col2 + 4 DIV 88 AS col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-5233
SELECT ALL - col2 + 4 / 88 AS col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + col0 * col0 + + col0 * - cor0.col2 FROM tab0 AS cor0
----
-216
1190
623

query I rowsort
SELECT DISTINCT col2 + 63 FROM tab2 AS cor0
----
101
89
90

query I rowsort
SELECT DISTINCT - 46 + + col2 AS col2 FROM tab2
----
-19
-20
-8

query I rowsort
SELECT cor0.col2 + - 79 AS col1 FROM tab2 AS cor0
----
-41
-52
-53

query I rowsort
SELECT ALL + 28 + col1 + + col1 * col2 FROM tab2
----
1621
691
896

query I rowsort
SELECT ALL - col0 + - col2 * col2 * col1 + - col2 AS col2 FROM tab2
----
-22633
-24665
-39988

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( + ( col1 ) AS REAL ) + 76 col0 FROM tab1 AS cor0
----
102
86
89

query I rowsort
SELECT - ( 93 ) * cor0.col2 + col0 FROM tab1 cor0
----
-5019
-5237
-8848

query I rowsort
SELECT DISTINCT col0 + col1 + + col0 * - col2 * + cor0.col0 AS col2 FROM tab0 cor0
----
-1093
-18898
-649342

query I rowsort
SELECT DISTINCT + 23 + cor0.col0 FROM tab1 AS cor0
----
103
26
87

query I rowsort
SELECT DISTINCT - 23 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
-1242
-1311
-2208

query I rowsort
SELECT ALL 54 + + 27 FROM tab2 AS cor0
----
81
81
81

query I rowsort
SELECT ALL + - cor0.col0 * 2 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT ALL - tab1.col1 * - 33 * col0 AS col2 FROM tab1
----
21120
2574
34320

onlyif mysql # use DIV operator for integer division
query I rowsort label-5248
SELECT ALL col0 - + 89 * + col1 DIV + col1 AS col2 FROM tab2
----
-10
-11
-82

skipif mysql # not compatible
query I rowsort label-5248
SELECT ALL col0 - + 89 * + col1 / + col1 AS col2 FROM tab2
----
-10
-11
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 - col2 col1 FROM tab1
----
-16
-51
7

query I rowsort
SELECT - 88 * + cor0.col0 FROM tab1 cor0
----
-264
-5632
-7040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5251
SELECT DISTINCT CAST( + cor0.col1 AS SIGNED ) + col0 FROM tab0 cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-5251
SELECT DISTINCT CAST ( + cor0.col1 AS INTEGER ) + col0 FROM tab0 cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5252
SELECT + CAST( NULL AS SIGNED ) * 80 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5252
SELECT + CAST ( NULL AS INTEGER ) * 80 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( + col0 ) + col0 - 50 AS col1 FROM tab0 AS cor0
----
-2
128
20

query I rowsort
SELECT - - ( - col0 ) + col1 + ( - col2 * + col1 ) AS col0 FROM tab0 AS cor0
----
-2776
-35
-7460

query I rowsort
SELECT + 80 * col0 + col1 FROM tab1 cor0
----
266
5130
6413

query I rowsort
SELECT DISTINCT + ( - tab0.col1 ) * + col1 FROM tab0
----
-7396
-8281
-9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5257
SELECT DISTINCT cor0.col1 * + CAST( NULL AS SIGNED ) FROM tab0, tab0 AS cor0, tab1 cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-5257
SELECT DISTINCT cor0.col1 * + CAST ( NULL AS INTEGER ) FROM tab0, tab0 AS cor0, tab1 cor1
----
NULL

query I rowsort
SELECT + ( - col1 * col0 ) FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + + 57 * + col0 - col2 FROM tab0 cor0
----
1335
1994
4991

query I rowsort
SELECT ALL + ( - 31 ) AS col2 FROM tab1
----
-31
-31
-31

query I rowsort
SELECT ALL - col0 * + col2 AS col1 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - 85 * col2 AS col1 FROM tab0 AS cor0
----
-2805
-6970
-85

query I rowsort
SELECT col1 * + cor0.col2 + col0 - col1 AS col0 FROM tab1 cor0
----
1315
1381
624

query I rowsort
SELECT + col0 * - col1 + + cor0.col0 FROM tab1 cor0
----
-576
-75
-960

query I rowsort
SELECT DISTINCT 80 + col0 * - ( col2 ) FROM tab1 cor0
----
-3568
-7600
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5266
SELECT ALL - + col1 * col0 DIV col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-5266
SELECT ALL - + col1 * col0 / col1 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5267
SELECT + + col2 + col1 DIV col1 - col1 AS col1 FROM tab1 cor0
----
29
48
84

skipif mysql # not compatible
query I rowsort label-5267
SELECT + + col2 + col1 / col1 - col1 AS col1 FROM tab1 cor0
----
29
48
84

query I rowsort
SELECT ALL - col1 * + cor0.col0 + col0 AS col1 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT - - col0 * cor0.col1 + - ( + col1 ) FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT ALL + col0 + - col0 + + 70 FROM tab0 AS cor0
----
70
70
70

query I rowsort
SELECT ALL - col0 * + 32 FROM tab0
----
-1120
-2848
-768

query I rowsort
SELECT DISTINCT - + col2 + - col1 * col0 + - col2 AS col0 FROM tab2 AS cor0
----
-1419
-271
-4654

query I rowsort
SELECT ALL + col1 + 53 FROM tab0 cor0
----
139
144
150

query I rowsort
SELECT ALL - col0 - cor0.col1 AS col0 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT + col1 * 11 AS col0 FROM tab2 AS cor0
----
187
341
649

query I rowsort
SELECT col0 + - col1 * + col0 AS col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-5277
SELECT DISTINCT + cor0.col2 * cor0.col0 - col2 * col2 DIV - 8 AS col0 FROM tab1 AS cor0
----
4054
526
8832

skipif mysql # not compatible
query I rowsort label-5277
SELECT DISTINCT + cor0.col2 * cor0.col0 - col2 * col2 / - 8 AS col0 FROM tab1 AS cor0
----
4054
526
8832

query I rowsort
SELECT ALL col1 + + ( + col1 ) AS col0 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT - col1 * + 70 + + col0 AS col0 FROM tab0 cor0
----
-5996
-6281
-6755

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * - col0 col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT - ( - cor0.col2 ) * col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5282
SELECT DISTINCT - - CAST( NULL AS SIGNED ) - + col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5282
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) - + col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - - cor0.col2 * - cor0.col0 + 87 FROM tab0, tab0 cor0
----
9 values hashing to 2d06044afe90eb2262fed4b77eeda9ae

query I rowsort
SELECT + col1 * ( - col0 ) + + col2 * tab0.col1 AS col1 FROM tab0
----
-3298
-637
774

query I rowsort
SELECT + - ( + cor0.col0 ) AS col2 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - + col2 + + col2 * col2 AS col2 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT DISTINCT - col0 * + col2 + - 97 FROM tab0 AS cor0
----
-132
-7395
-889

query I rowsort
SELECT - col0 * + 79 + col2 AS col0 FROM tab0 AS cor0
----
-1863
-2764
-6949

query I rowsort
SELECT - 56 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to a228dfb9ede9780b082a5a3dfb2fca80

query I rowsort
SELECT + col1 + + col1 * - col1 AS col2 FROM tab1 AS cor0
----
-156
-650
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5291
SELECT + + cor0.col1 / + CAST( NULL AS SIGNED ) FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5291
SELECT + + cor0.col1 / + CAST ( NULL AS INTEGER ) FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT col0 * 50 * - col0 FROM tab2 AS cor0
----
-2450
-304200
-312050

onlyif mysql # use DIV operator for integer division
query I rowsort label-5293
SELECT 1 DIV + col2 col2 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5293
SELECT 1 / + col2 col2 FROM tab1
----
0
0
0

query I rowsort
SELECT + ( + col0 + tab2.col1 ) FROM tab2
----
137
38
96

query I rowsort
SELECT - 30 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 6993f5c634597e63319c949df6b4733d

query I rowsort
SELECT 36 + cor0.col1 FROM tab0, tab0 cor0
----
9 values hashing to 96a36532d2e3ba8ab0280a4a3f3ede3f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5297
SELECT - col0 * col1 + CAST( + col2 AS SIGNED ) FROM tab2 AS cor0
----
-1305
-190
-4576

skipif mysql # not compatible
query I rowsort label-5297
SELECT - col0 * col1 + CAST ( + col2 AS INTEGER ) FROM tab2 AS cor0
----
-1305
-190
-4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-5298
SELECT + ( - 79 ) + + tab0.col2 * - 42 * tab0.col0 + - col2 DIV - 75 FROM tab0
----
-1549
-306594
-33343

skipif mysql # not compatible
query I rowsort label-5298
SELECT + ( - 79 ) + + tab0.col2 * - 42 * tab0.col0 + - col2 / - 75 FROM tab0
----
-1549
-306594
-33343

query I rowsort
SELECT col0 * col1 * col1 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT ALL ( ( col1 ) ) AS col2 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL col0 * + col0 * col2 FROM tab1
----
233472
486
614400

query I rowsort
SELECT DISTINCT - tab2.col2 * tab2.col1 * + tab2.col0 FROM tab2
----
-119652
-51034
-5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-5303
SELECT - col1 DIV col2 + col0 * 74 FROM tab0 AS cor0
----
1774
2493
6585

skipif mysql # not compatible
query I rowsort label-5303
SELECT - col1 / col2 + col0 * 74 FROM tab0 AS cor0
----
1774
2493
6585

query I rowsort
SELECT + + col2 * + col0 + col0 FROM tab1 cor0
----
165
3712
7760

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + col0 AS REAL ) AS col0 FROM tab1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - col2 ) * - col1 * 44 col0 FROM tab0
----
-124872
-328328
-4268

onlyif mysql # use DIV operator for integer division
query I rowsort label-5307
SELECT col0 * col1 DIV - tab2.col0 AS col0 FROM tab2
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-5307
SELECT col0 * col1 / - tab2.col0 AS col0 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT + 95 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + col0 - + 90 * tab0.col2 col2 FROM tab0
----
-2860
-7200
42

query I rowsort
SELECT ALL + ( + col0 ) - + col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT ALL 29 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT + 51 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

query I rowsort
SELECT ALL + 98 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5314
SELECT DISTINCT col2 / - CAST( NULL AS SIGNED ) AS col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5314
SELECT DISTINCT col2 / - CAST ( NULL AS INTEGER ) AS col0 FROM tab0
----
NULL

query I rowsort
SELECT ALL + + col0 + - col2 * - col1 AS col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT - - col0 + - col2 * - col2 FROM tab2 AS cor0
----
1523
736
754

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 85 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5318
SELECT + 9 DIV - tab0.col0 AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-5318
SELECT + 9 / - tab0.col0 AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

onlyif mysql # use DIV operator for integer division
query I rowsort label-5319
SELECT + - 45 DIV - 19 AS col1 FROM tab2 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-5319
SELECT + - 45 / - 19 AS col1 FROM tab2 AS cor0
----
2
2
2

query I rowsort
SELECT ( 95 ) FROM tab0 cor0
----
95
95
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-5321
SELECT - col1 + + cor0.col0 DIV col2 AS col1 FROM tab1 AS cor0
----
-13
-26
-9

skipif mysql # not compatible
query I rowsort label-5321
SELECT - col1 + + cor0.col0 / col2 AS col1 FROM tab1 AS cor0
----
-13
-26
-9

query I rowsort
SELECT DISTINCT - col1 - 24 AS col1 FROM tab2
----
-41
-55
-83

query I rowsort
SELECT DISTINCT - col1 + col1 * 91 * col1 FROM tab2 AS cor0
----
26282
316712
87420

query I rowsort
SELECT + - col1 * - 71 + col0 AS col0 FROM tab2 AS cor0
----
1286
2208
4267

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5325
SELECT ALL + col0 + CAST( - col0 AS SIGNED ) col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5325
SELECT ALL + col0 + CAST ( - col0 AS INTEGER ) col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 29 AS col0 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT 38 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5328
SELECT ALL col2 / CAST( NULL AS SIGNED ) 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-5328
SELECT ALL col2 / CAST ( NULL AS INTEGER ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 80 col1 FROM tab0 AS cor0
----
80

query I rowsort
SELECT DISTINCT col2 + + ( + col1 ) * 9 * - col0 FROM tab0 cor0
----
-18543
-30554
-72809

query I rowsort
SELECT - + 3 + - cor0.col1 FROM tab2 AS cor0
----
-20
-34
-62

query I rowsort
SELECT ALL - ( + cor0.col0 ) * cor0.col1 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + + col0 * col1 + + col2 FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5334
SELECT + col1 / - col2 + - col2 * - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5334
SELECT + col1 / - col2 + - col2 * - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + col2 * col2 + + col0 FROM tab2 AS cor0
----
-1365
-598
-722

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5336
SELECT DISTINCT - CAST( NULL AS DECIMAL ) * + cor0.col1 - - col2 col2 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5336
SELECT DISTINCT - CAST ( NULL AS REAL ) * + cor0.col1 - - col2 col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT ( 58 ) + col2 FROM tab0 AS cor0
----
140
59
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5338
SELECT - - CAST( NULL AS DECIMAL ) + - col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5338
SELECT - - CAST ( NULL AS REAL ) + - col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 56 * col1 + + col1 FROM tab0 AS cor0
----
4902
5187
5529

query I rowsort
SELECT DISTINCT + cor0.col1 * - 60 FROM tab2 AS cor0
----
-1020
-1860
-3540

query I rowsort
SELECT - col2 * + 71 AS col1 FROM tab1 AS cor0
----
-3834
-4047
-6816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + tab1.col0 col2 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT 49 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT + col0 * col2 + 89 FROM tab2
----
2117
278
3091

onlyif mysql # use DIV operator for integer division
query I rowsort label-5345
SELECT + col1 DIV ( - 10 ) AS col2 FROM tab0
----
-8
-9
-9

skipif mysql # not compatible
query I rowsort label-5345
SELECT + col1 / ( - 10 ) AS col2 FROM tab0
----
-8
-9
-9

query I rowsort
SELECT DISTINCT - 58 * - col0 AS col2 FROM tab0 AS cor0
----
1392
2030
5162

query I rowsort
SELECT col0 * col2 - + col1 * col1 FROM tab2
----
-1453
-772
2713

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 - - col0 col2 FROM tab2
----
14
156
158

query I rowsort
SELECT + col2 * + ( - 29 ) * col1 FROM tab0
----
-216398
-2813
-82302

query I rowsort
SELECT + col1 + col2 * - col0 FROM tab1 cor0
----
-136
-3638
-7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-5351
SELECT + 21 DIV col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5351
SELECT + 21 / col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT tab0.col0 AS col1 FROM tab0, tab2 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT 62 + + col0 FROM tab0 AS cor0
----
151
86
97

query I rowsort
SELECT - + 0 * + col0 + - col2 + - cor0.col2 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT - col1 * col1 + + 68 * 32 AS col1 FROM tab2 AS cor0
----
-1305
1215
1887

query I rowsort
SELECT ALL - 18 * + col2 AS col2 FROM tab1 cor0
----
-1026
-1728
-972

query I rowsort
SELECT - 18 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 09afafec657a5e9f082beb6a16ec85de

query I rowsort
SELECT + - 38 * + 9 * - cor0.col2 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 241a2f6b68b8766f3633b6e2f537800a

onlyif mysql # use DIV operator for integer division
query I rowsort label-5359
SELECT - 28 + + col0 DIV col1 AS col1 FROM tab0
----
-28
-28
-28

skipif mysql # not compatible
query I rowsort label-5359
SELECT - 28 + + col0 / col1 AS col1 FROM tab0
----
-28
-28
-28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 14 col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

query I rowsort
SELECT ALL 66 * col2 AS col0 FROM tab2
----
1716
1782
2508

query I rowsort
SELECT + - col2 * 52 * col0 AS col0 FROM tab1 AS cor0
----
-189696
-399360
-8424

query I rowsort
SELECT ALL + col0 + cor0.col2 * + ( col2 ) AS col2 FROM tab0 AS cor0
----
1113
36
6813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 + - 23 col2 FROM tab1 AS cor0
----
-10
-13
3

query I rowsort
SELECT + col0 + + 65 * - col0 FROM tab2 AS cor0
----
-448
-4992
-5056

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col2 col1 FROM tab1, tab0, tab0 AS cor0, tab2 AS cor1
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5367
SELECT ALL + col2 DIV + col0 col1 FROM tab0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5367
SELECT ALL + col2 / + col0 col1 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort
SELECT ALL + col0 + - CAST ( col0 AS REAL ) * - col2 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5369
SELECT col2 * + CAST( 65 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
2145
5330
65

skipif mysql # not compatible
query I rowsort label-5369
SELECT col2 * + CAST ( 65 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
2145
5330
65

query I rowsort
SELECT DISTINCT - col2 * col2 + col1 * + col0 AS col1 FROM tab1 cor0
----
-2609
-2838
-8176

query I rowsort
SELECT DISTINCT col1 + + col2 * 92 FROM tab1 AS cor0
----
4994
5254
8845

query I rowsort
SELECT - + cor0.col2 * - col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT - col1 + ( cor0.col2 ) * col1 AS col1 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT - + tab0.col1 FROM tab0, tab0 AS cor0, tab2, tab0 cor1
----
81 values hashing to 786a240f80bef6f9c6a190e92cd4f9e8

query I rowsort
SELECT - col0 - + 76 FROM tab0
----
-100
-111
-165

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 61 * + col2 * - col2 + + col2 col1 FROM tab0
----
410246
62
66462

query I rowsort
SELECT col2 * + 9 + col1 * col2 - + col0 FROM tab0
----
3111
71
8111

query I rowsort
SELECT - - col2 + - col2 * + col1 AS col0 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL 69 + 19 * col2 FROM tab2 AS cor0
----
563
582
791

query I rowsort
SELECT ALL - ( + col1 ) * col0 * + col0 AS col2 FROM tab0 cor0
----
-118825
-49536
-720811

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5381
SELECT - col0 * col0 * col1 - + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5381
SELECT - col0 * col0 * col1 - + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 + + col1 + - col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL cor0.col2 * 51 FROM tab1 AS cor0
----
2754
2907
4896

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 AS cor2
----
3645 values hashing to 35707ade138fec4b370f5140a4cd2963

query I rowsort
SELECT DISTINCT - tab1.col2 * cor0.col1 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 3e351fdfa2fd88779f2d7b6136dc00d1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 80 * + col2 col2 FROM tab0 cor0
----
2640
6560
80

query I rowsort
SELECT DISTINCT + 81 * + col2 FROM tab2 AS cor0
----
2106
2187
3078

query I rowsort
SELECT + cor0.col1 + cor0.col2 + - ( 12 ) * col0 FROM tab0 AS cor0
----
-169
-322
-895

query I rowsort
SELECT ALL 98 AS col1 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to c758e8afbdfa6aae279045b0e9cbacc2

query I rowsort
SELECT ALL - 86 * + cor0.col2 * 83 + + col0 * + col0 AS col2 FROM tab1 AS cor0
----
-385443
-402770
-678848

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5391
SELECT ALL + cor0.col0 * - col1 * CAST( NULL AS SIGNED ) + 12 * col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5391
SELECT ALL + cor0.col0 * - col1 * CAST ( NULL AS INTEGER ) + 12 * col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 84 + col1 + - col2 FROM tab2 AS cor0
----
117
63
88

query I rowsort
SELECT col1 + col2 * ( + ( - col0 ) + - ( - col2 ) ) FROM tab0 AS cor0
----
-483
383
63

query I rowsort
SELECT DISTINCT + col1 * + col2 + - col1 AS col0 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT DISTINCT - col0 + + 62 * + tab1.col2 FROM tab1
----
3345
3470
5872

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5396
SELECT ALL - CAST( NULL AS SIGNED ) * + 34 AS col2 FROM tab2, tab0, tab2 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5396
SELECT ALL - CAST ( NULL AS INTEGER ) * + 34 AS col2 FROM tab2, tab0, tab2 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - col0 * col1 - + col0 FROM tab2 AS cor0
----
-1422
-224
-4680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5398
SELECT + 52 * + col1 + - CAST( + col2 * - col2 AS SIGNED ) FROM tab2 AS cor0
----
2328
2341
3744

skipif mysql # not compatible
query I rowsort label-5398
SELECT + 52 * + col1 + - CAST ( + col2 * - col2 AS INTEGER ) FROM tab2 AS cor0
----
2328
2341
3744

query I rowsort
SELECT ALL 57 * - tab2.col1 FROM tab2
----
-1767
-3363
-969

query I rowsort
SELECT DISTINCT - ( ( - col2 ) ) AS col2 FROM tab2
----
26
27
38

query I rowsort
SELECT ALL tab2.col0 * col1 * col0 FROM tab2
----
106097
1519
358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-5402
SELECT col1 * col0 + col2 DIV + cor0.col1 col0 FROM tab2 AS cor0
----
1345
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5402
SELECT col1 * col0 + col2 / + cor0.col1 col0 FROM tab2 AS cor0
----
1345
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 74 * col1 - + col0 * + 2 col0 FROM tab1 AS cor0
----
-1122
-1930
-868

query I rowsort
SELECT DISTINCT 27 AS col1 FROM tab0, tab1 AS cor0
----
27

query I rowsort
SELECT 55 + cor0.col0 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 155b397adecdafdd0a7d3f4fc2adf6a5

query I rowsort
SELECT ALL - col0 + + 62 + col2 AS col1 FROM tab0 AS cor0
----
28
55
71

query I rowsort
SELECT DISTINCT + + col1 * ( col2 ) + col0 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT - - col0 * + 72 FROM tab0 cor0
----
1728
2520
6408

query I rowsort
SELECT ALL + 91 FROM tab2, tab1 AS cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

query I rowsort
SELECT - ( tab1.col2 + + tab1.col0 ) AS col1 FROM tab1
----
-121
-176
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( cor0.col2 ) * col2 col1 FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL - 78 AS col0 FROM tab2, tab1 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to afa1a417c354fab37e0e421ec67035c7

query I rowsort
SELECT ALL 84 FROM tab1, tab2 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 3c092ed1a99ddb5afc7049fd2b9427f9

query I rowsort
SELECT 26 AS col2 FROM tab2, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to ede8226bb7e602e221f9d98345b4da37

query I rowsort
SELECT DISTINCT col0 * + col2 * - col0 AS col0 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT DISTINCT - col1 * cor0.col2 + - col1 AS col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT ALL - - ( + col2 ) * col0 - - col2 FROM tab2 AS cor0
----
2054
216
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 91 col2 FROM tab2 AS cor0
----
91
91
91

query I rowsort
SELECT - - 86 * col0 FROM tab1 cor0
----
258
5504
6880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 26 ) col1 FROM tab0 AS cor0
----
26
26
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-5421
SELECT DISTINCT - 83 DIV - cor0.col2 col1 FROM tab1 AS cor0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5421
SELECT DISTINCT - 83 / - cor0.col2 col1 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT + 66 - 66 AS col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT ALL - 86 * cor0.col1 FROM tab0 AS cor0
----
-7396
-7826
-8342

query I rowsort
SELECT DISTINCT 48 AS col0 FROM tab0, tab0 AS cor0 CROSS JOIN tab2, tab0 cor1
----
48

query I rowsort
SELECT ALL 68 + - col1 FROM tab1 AS cor0
----
42
55
58

query I rowsort
SELECT + col0 * - 1 * + col2 + + col1 * 61 FROM tab1 AS cor0
----
-3038
-6887
1424

query I rowsort
SELECT DISTINCT 54 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
54

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * col1 + 49 * - cor0.col0 col2 FROM tab1 AS cor0
----
-3036
-3751
529

query I rowsort
SELECT 98 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT ALL - col0 * col2 * 48 AS col1 FROM tab2 AS cor0
----
-144096
-9072
-97344

query I rowsort
SELECT col2 * ( + col0 ) + col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT + 40 AS col0 FROM tab2, tab2 AS cor0
----
40

query I rowsort
SELECT - col1 * 68 FROM tab0 cor0
----
-5848
-6188
-6596

query I rowsort
SELECT cor0.col1 + 9 FROM tab0, tab1 cor0
----
9 values hashing to 3c1a00c6b738db92e0262ff5bda63bd9

query I rowsort
SELECT DISTINCT + 56 * - 35 AS col0 FROM tab0 AS cor0
----
-1960

query I rowsort
SELECT DISTINCT + 19 AS col1 FROM tab2, tab0 AS cor0
----
19

query I rowsort
SELECT 88 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 80 col2 FROM tab1, tab0 AS cor0
----
80

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE col2 + - col0 + - col0 >= + col2
----

query I rowsort
SELECT col2 AS col0 FROM tab1 WHERE NOT NULL IN ( col2 )
----

query I rowsort
SELECT tab1.col1 + - col2 * - tab1.col1 AS col2 FROM tab1
----
1261
1430
580

onlyif mysql # use DIV operator for integer division
query I rowsort label-5442
SELECT + col2 - + col2 DIV + col0 FROM tab1
----
36
57
95

skipif mysql # not compatible
query I rowsort label-5442
SELECT + col2 - + col2 / + col0 FROM tab1
----
36
57
95

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT col2 + col2 BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL - tab0.col0 * - col0 + col2 FROM tab0
----
1226
609
8003

query I rowsort
SELECT col0 * col2 + - tab2.col1 AS col0 FROM tab2
----
158
1969
2985

query I rowsort
SELECT ALL - col0 + col0 * + col2 AS col0 FROM tab0 cor0
----
0
7209
768

query I rowsort
SELECT ALL + col2 + col2 * + col2 * col1 FROM tab1 cor0
----
119904
32547
75870

query I rowsort
SELECT DISTINCT + - col1 * - cor0.col2 + + col1 + - col1 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + col1 * - col0 * - col2 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT DISTINCT + + cor0.col1 * + col0 + col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL - col2 * col0 - col2 AS col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT ALL + col1 * col2 * - col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT + col1 * - col1 + - col0 * + col0 AS col2 FROM tab2 AS cor0
----
-1010
-6530
-9565

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + col1 - + col2 col2 FROM tab2
----
17
31
59

query I rowsort
SELECT + col1 + + col2 * - cor0.col2 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
22630
24565
39943

query I rowsort
SELECT ALL - cor0.col0 * col0 + + col1 FROM tab2 cor0
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT + col2 + col1 * - cor0.col1 * + col0 FROM tab2 AS cor0
----
-22793
-271492
-6700

query I rowsort
SELECT DISTINCT - 56 + col0 * 15 FROM tab0 AS cor0
----
1279
304
469

query I rowsort
SELECT + 0 + col2 * + col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - - col0 * col2 + col1 AS col0 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT col2 * col1 * col1 AS col0 FROM tab1
----
16224
36504
5700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 + tab1.col0 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 8733ba2dd568938e338b27ad757d3e3b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col1 * - 66 * col0 col1 FROM tab2 AS cor0
----
-14291
-303673
-88621

query I rowsort
SELECT + cor0.col1 * + col0 + + 60 * col0 * col2 FROM tab2 AS cor0
----
11557
126282
181463

query I rowsort
SELECT DISTINCT col2 + - cor0.col1 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT - col1 + + cor0.col1 * - 90 FROM tab0 AS cor0
----
-7826
-8281
-8827

query I rowsort
SELECT + col0 * - 89 FROM tab0 AS cor0
----
-2136
-3115
-7921

query I rowsort
SELECT + col1 * + col0 + + col2 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT ( col2 ) * + 56 FROM tab0
----
1848
4592
56

query I rowsort
SELECT 6 * cor0.col1 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 687d40698910b137efdf952c513255fa

query I rowsort
SELECT ALL - col2 FROM tab0 WHERE NULL < col2 * + col2 * + col2
----

query I rowsort
SELECT ALL tab1.col0 * - col0 * - col2 + col2 AS col1 FROM tab1
----
233529
540
614496

query I rowsort
SELECT col2 * col2 + + tab0.col0 AS col2 FROM tab0
----
1113
36
6813

query I rowsort
SELECT col2 FROM tab1 WHERE NOT ( NULL ) IN ( tab1.col1 + - col1 )
----

query I rowsort
SELECT ALL + col2 - col2 AS col1 FROM tab2 WHERE NULL NOT IN ( col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5476
SELECT - col0 * col0 - col1 DIV + tab0.col2 FROM tab0
----
-1322
-578
-7922

skipif mysql # not compatible
query I rowsort label-5476
SELECT - col0 * col0 - col1 / + tab0.col2 FROM tab0
----
-1322
-578
-7922

query I rowsort
SELECT ALL - tab2.col2 AS col1 FROM tab2 WHERE NOT col2 * - col2 NOT BETWEEN col2 * col0 AND - col1 * col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5478
SELECT + col0 + col2 DIV - col0 + col0 AS col2 FROM tab1
----
-12
128
159

skipif mysql # not compatible
query I rowsort label-5478
SELECT + col0 + col2 / - col0 + col0 AS col2 FROM tab1
----
-12
128
159

onlyif mysql # use DIV operator for integer division
query I rowsort label-5479
SELECT ALL + col0 DIV + col1 AS col0 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-5479
SELECT ALL + col0 / + col1 AS col0 FROM tab2
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - col2 + + col2 + col2 col1 FROM tab1
----
1440
1512
684

query I rowsort
SELECT col2 * + tab2.col1 + + col0 * col1 + - col2 AS col0 FROM tab2
----
1027
1951
6110

query I rowsort
SELECT - col1 * col1 + + tab1.col0 FROM tab1
----
-36
-673
-89

query III rowsort
SELECT * FROM tab0 WHERE col0 + col2 >= ( NULL )
----

query I rowsort
SELECT ALL col1 * col0 * col0 AS col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT DISTINCT - col1 * col0 * col2 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT + col0 * - col2 + col2 - + tab2.col1 AS col1 FROM tab2
----
-193
-2061
-2981

query I rowsort
SELECT DISTINCT tab0.col1 + col0 * - col1 - + tab0.col1 * + col1 * + col1 FROM tab0
----
-638034
-761579
-915971

onlyif mysql # use DIV operator for integer division
query I rowsort label-5488
SELECT - tab0.col2 + col1 DIV - col1 + col2 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5488
SELECT - tab0.col2 + col1 / - col1 + col2 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT - tab0.col1 * tab0.col0 * - col2 FROM tab0
----
3395
664118
68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * - col1 col0 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT + col2 * col0 + tab2.col1 FROM tab2
----
2087
220
3019

query I rowsort
SELECT DISTINCT - col2 + + col0 + col1 FROM tab0 WHERE NULL > NULL
----

query I rowsort
SELECT tab2.col0 AS col0 FROM tab2 WHERE NOT col2 <> NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5494
SELECT - col1 DIV + ( 11 + col0 ) FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5494
SELECT - col1 / + ( 11 + col0 ) FROM tab2 AS cor0
----
-1
0
0

query I rowsort
SELECT + cor0.col0 + - col0 AS col1 FROM tab0 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5496
SELECT - + col1 + 19 DIV + col0 FROM tab2 AS cor0
----
-17
-29
-59

skipif mysql # not compatible
query I rowsort label-5496
SELECT - + col1 + 19 / + col0 FROM tab2 AS cor0
----
-17
-29
-59

query I rowsort
SELECT ALL - 80 AS col0 FROM tab2
----
-80
-80
-80

query I rowsort
SELECT - + col2 * 44 AS col2 FROM tab2 AS cor0
----
-1144
-1188
-1672

onlyif mysql # use DIV operator for integer division
query I rowsort label-5499
SELECT DISTINCT col1 DIV 16 AS col2 FROM tab2
----
1
3

skipif mysql # not compatible
query I rowsort label-5499
SELECT DISTINCT col1 / 16 AS col2 FROM tab2
----
1
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5500
SELECT DISTINCT col0 DIV - 39 FROM tab1 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-5500
SELECT DISTINCT col0 / - 39 FROM tab1 AS cor0
----
-1
-2
0

query I rowsort
SELECT DISTINCT + col0 * col0 + col2 AS col1 FROM tab1
----
4153
63
6496

query I rowsort
SELECT ALL 50 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT - cor0.col2 * + 21 FROM tab2 AS cor0
----
-546
-567
-798

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5504
SELECT CAST( NULL AS SIGNED ) + - col1 * + col0 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5504
SELECT CAST ( NULL AS INTEGER ) + - col1 * + col0 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col0 FROM tab0, tab2 cor0, tab2 cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT DISTINCT + 92 + - 24 AS col0 FROM tab1 AS cor0
----
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5507
SELECT ( tab0.col1 * CAST( NULL AS SIGNED ) + col2 ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5507
SELECT ( tab0.col1 * CAST ( NULL AS INTEGER ) + col2 ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col2 * - col1 + 81 AS col2 FROM tab1 cor0
----
-1167
-1323
-489

query I rowsort
SELECT ALL + 89 * + col2 FROM tab1 AS cor0
----
4806
5073
8544

query I rowsort
SELECT - - col1 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL - + cor1.col2 + 70 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 77f784dc30f2ad5690182dc7e6063d44

query I rowsort
SELECT - tab1.col2 - col2 * - 64 AS col1 FROM tab1
----
3402
3591
6048

query I rowsort
SELECT DISTINCT col2 + - col2 * + 50 * + col2 FROM tab1 AS cor0
----
-145746
-162393
-460704

query I rowsort
SELECT ALL + col2 + 15 * col0 FROM tab2 cor0
----
1196
1223
132

query I rowsort
SELECT col1 + 87 AS col1 FROM tab1 AS cor0
----
100
113
97

query I rowsort
SELECT ALL + + col1 * cor0.col2 + - 46 FROM tab0 cor0
----
2792
51
7416

query I rowsort
SELECT 81 - - tab1.col1 AS col1 FROM tab1
----
107
91
94

query I rowsort
SELECT ( cor0.col2 ) + col1 AS col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT + tab1.col2 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 2 * + tab0.col2 col0 FROM tab0
----
164
2
66

query I rowsort
SELECT DISTINCT col1 - ( + col1 * col2 ) FROM tab1
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-5522
SELECT col0 DIV + 21 FROM tab0
----
1
1
4

skipif mysql # not compatible
query I rowsort label-5522
SELECT col0 / + 21 FROM tab0
----
1
1
4

query I rowsort
SELECT ALL - tab2.col0 * col1 * col2 - col1 FROM tab2
----
-119711
-51051
-5890

query I rowsort
SELECT + + ( 48 ) + - col1 - 14 FROM tab0 AS cor0
----
-52
-57
-63

query I rowsort
SELECT DISTINCT - 49 * 92 FROM tab1 AS cor0
----
-4508

query I rowsort
SELECT ALL 36 + - col1 AS col2 FROM tab2 AS cor0
----
-23
19
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5527
SELECT ALL + col0 + col1 * - CAST( 27 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-206
-271
-699

skipif mysql # not compatible
query I rowsort label-5527
SELECT ALL + col0 + col1 * - CAST ( 27 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-206
-271
-699

query I rowsort
SELECT DISTINCT col2 + + col0 * - ( + 15 ) FROM tab0 AS cor0
----
-1253
-327
-524

onlyif mysql # use DIV operator for integer division
query I rowsort label-5529
SELECT + cor0.col0 DIV col0 + col2 * col0 col1 FROM tab1 cor0
----
163
3649
7681

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5529
SELECT + cor0.col0 / col0 + col2 * col0 col1 FROM tab1 cor0
----
163
3649
7681

query I rowsort
SELECT + + 33 + cor0.col2 * 89 AS col2 FROM tab0 cor0
----
122
2970
7331

query I rowsort
SELECT - ( + cor0.col1 ) FROM tab1, tab1 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT - col0 * col1 * - col2 AS col0 FROM tab1
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-5533
SELECT - 67 * col1 DIV + col0 col1 FROM tab2
----
-14
-296
-50

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5533
SELECT - 67 * col1 / + col0 col1 FROM tab2
----
-14
-296
-50

query I rowsort
SELECT ALL - 67 + + tab2.col2 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to bbde94b77851d0996e8c23ede3026c9f

query I rowsort
SELECT ALL + cor0.col2 * col1 * col2 FROM tab0 AS cor0
----
611884
93654
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5536
SELECT ALL - col2 * cor0.col0 * + col2 + 9 DIV - col0 FROM tab0 AS cor0
----
-26136
-35
-598436

skipif mysql # not compatible
query I rowsort label-5536
SELECT ALL - col2 * cor0.col0 * + col2 + 9 / - col0 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT DISTINCT 16 + col2 + + col1 FROM tab0 AS cor0
----
114
135
189

query I rowsort
SELECT col0 * + col2 * + col1 + + col1 AS col2 FROM tab0
----
3492
664209
68198

query I rowsort
SELECT + tab1.col2 - ( + 95 ) * col0 AS col0 FROM tab1
----
-231
-6023
-7504

query I rowsort
SELECT + tab2.col0 * + 13 + - col0 AS col2 FROM tab2
----
84
936
948

query I rowsort
SELECT + col2 * tab2.col2 * col1 + + col0 AS col0 FROM tab2
----
22606
24627
39962

query I rowsort
SELECT 57 + + col1 FROM tab0
----
143
148
154

query I rowsort
SELECT + ( col1 ) + col0 * 19 FROM tab2
----
1518
1541
164

query IIIIIIIII rowsort
SELECT * FROM tab1, tab2, tab2 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT col2 * - tab2.col0 + - col1 FROM tab2
----
-2087
-220
-3019

query I rowsort
SELECT DISTINCT - cor1.col0 AS col2 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
-7
-78
-79

query I rowsort
SELECT ALL - ( 97 ) * + col2 FROM tab2 cor0
----
-2522
-2619
-3686

query I rowsort
SELECT DISTINCT ( + 38 ) AS col0 FROM tab2
----
38

query I rowsort
SELECT - - col0 * cor0.col0 + col2 * + ( col0 ) + col1 FROM tab2 AS cor0
----
269
8171
9260

query I rowsort
SELECT DISTINCT - col2 * 97 AS col0 FROM tab1 AS cor0
----
-5238
-5529
-9312

query I rowsort
SELECT DISTINCT - col0 * 34 * col0 AS col1 FROM tab0 cor0
----
-19584
-269314
-41650

query I rowsort
SELECT DISTINCT col1 - + tab2.col2 AS col2 FROM tab2
----
-21
33
4

query I rowsort
SELECT DISTINCT + 2 - col0 AS col2 FROM tab0
----
-22
-33
-87

query I rowsort
SELECT col2 - - col0 * tab1.col1 * + 93 AS col2 FROM tab1
----
59577
7308
96816

onlyif mysql # use DIV operator for integer division
query I rowsort label-5555
SELECT DISTINCT col0 DIV col0 + - tab0.col0 - 14 FROM tab0
----
-102
-37
-48

skipif mysql # not compatible
query I rowsort label-5555
SELECT DISTINCT col0 / col0 + - tab0.col0 - 14 FROM tab0
----
-102
-37
-48

query I rowsort
SELECT + 80 - col2 * + col2 FROM tab1
----
-2836
-3169
-9136

query I rowsort
SELECT 83 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

skipif mysql # not compatible
query I rowsort
SELECT col2 + col1 + - CAST ( col2 AS REAL ) AS col2 FROM tab1
----
10
13
26

query I rowsort
SELECT - + cor0.col2 * col0 * + ( - col0 ) + col0 FROM tab1 AS cor0
----
233536
489
614480

query I rowsort
SELECT DISTINCT - cor0.col1 + + cor0.col2 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT col1 + + 99 * + col0 * + col0 AS col1 FROM tab2
----
4882
602375
617876

query I rowsort
SELECT ALL cor0.col0 + - 21 FROM tab1 AS cor0
----
-18
43
59

query I rowsort
SELECT ALL + - cor0.col0 + 52 FROM tab1 AS cor0
----
-12
-28
49

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5564
SELECT + + col1 + + CAST( NULL AS SIGNED ) * - col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5564
SELECT + + col1 + + CAST ( NULL AS INTEGER ) * - col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 - + ( - 31 ) * - col0 FROM tab1 AS cor0
----
-1920
-2400
-90

query I rowsort
SELECT DISTINCT col2 * 31 FROM tab1 AS cor0
----
1674
1767
2976

query I rowsort
SELECT DISTINCT col1 * - ( + cor0.col2 ) FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5568
SELECT ALL + col2 DIV - 69 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5568
SELECT ALL + col2 / - 69 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT - - col1 * + 23 FROM tab0 AS cor0
----
1978
2093
2231

query I rowsort
SELECT + col1 * cor0.col1 + + col1 AS col2 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT ALL col1 + ( - 95 * - col0 ) FROM tab1
----
311
6090
7613

query I rowsort
SELECT col0 + 14 * col0 AS col0 FROM tab2 AS cor0
----
105
1170
1185

query I rowsort
SELECT ALL col0 * 85 FROM tab0 cor0
----
2040
2975
7565

query I rowsort
SELECT DISTINCT + col0 * col1 + - col1 FROM tab0 cor0
----
1978
3298
8008

query I rowsort
SELECT ALL - cor0.col2 * - cor0.col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5576
SELECT DISTINCT - + col1 DIV 63 + col0 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-5576
SELECT DISTINCT - + col1 / 63 + col0 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT + - cor0.col0 + ( 47 ) AS col0 FROM tab0 AS cor0
----
-42
12
23

query I rowsort
SELECT DISTINCT - + col0 * 3 FROM tab0 AS cor0
----
-105
-267
-72

query I rowsort
SELECT ALL + cor0.col2 + - 13 * + col0 - col0 FROM tab0 AS cor0
----
-1164
-303
-489

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + ( col2 ) col2 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5581
SELECT DISTINCT ( col1 ) + + col2 + - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5581
SELECT DISTINCT ( col1 ) + + col2 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5582
SELECT - CAST( NULL AS SIGNED ) * cor0.col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5582
SELECT - CAST ( NULL AS INTEGER ) * cor0.col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL ( + col2 ) + + col0 - - ( col0 ) FROM tab0 AS cor0
----
260
71
81

query I rowsort
SELECT - ( - col1 ) + col0 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + ( 19 ) * cor0.col1 + col2 + + col2 * col0 FROM tab0 cor0
----
1879
2459
9109

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5586
SELECT ALL + CAST( + col2 AS SIGNED ) * col1 - 86 AS col0 FROM tab1 AS cor0
----
1162
1318
484

skipif mysql # not compatible
query I rowsort label-5586
SELECT ALL + CAST ( + col2 AS INTEGER ) * col1 - 86 AS col0 FROM tab1 AS cor0
----
1162
1318
484

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5587
SELECT - col0 + - ( - tab1.col1 ) * tab1.col2 * CAST( NULL AS SIGNED ) + 75 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5587
SELECT - col0 + - ( - tab1.col1 ) * tab1.col2 * CAST ( NULL AS INTEGER ) + 75 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 + col1 * 19 AS col2 FROM tab1
----
254
327
497

onlyif mysql # use DIV operator for integer division
query I rowsort label-5589
SELECT DISTINCT - 54 - cor1.col1 DIV - ( 56 ) AS col1 FROM tab2, tab2 cor0, tab1 AS cor1
----
-54

skipif mysql # not compatible
query I rowsort label-5589
SELECT DISTINCT - 54 - cor1.col1 / - ( 56 ) AS col1 FROM tab2, tab2 cor0, tab1 AS cor1
----
-54

query I rowsort
SELECT - 54 + 8 AS col0 FROM tab1 cor0
----
-46
-46
-46

query I rowsort
SELECT DISTINCT + 99 * + col1 * + ( - ( - col1 ) ) FROM tab0 AS cor0
----
732204
819819
931491

query I rowsort
SELECT ALL - - col0 * cor0.col1 + col2 * - 82 FROM tab0 cor0
----
-642
1375
3313

query I rowsort
SELECT ALL + col2 - + col1 * ( col2 * col1 ) AS col2 FROM tab1 AS cor0
----
-16128
-36450
-5643

query I rowsort
SELECT DISTINCT - - col0 + + col0 * - 53 FROM tab2 AS cor0
----
-364
-4056
-4108

query I rowsort
SELECT ALL - col0 + cor0.col1 * + 63 AS col1 FROM tab0 AS cor0
----
5394
5644
6076

query I rowsort
SELECT + cor0.col0 + col2 * 56 AS col1 FROM tab0 AS cor0
----
1872
4681
91

query I rowsort
SELECT DISTINCT col1 + col0 - 26 AS col1 FROM tab0 AS cor0
----
106
154
84

query I rowsort
SELECT ALL + - col1 * - col2 + - col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT + col0 + + col1 * cor0.col1 * col1 FROM tab0 AS cor0
----
636080
753660
912708

query I rowsort
SELECT DISTINCT - ( + col0 + col2 ) * col0 AS col0 FROM tab1
----
-14080
-171
-7744

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5601
SELECT + CAST( col1 AS SIGNED ) * col1 AS col2 FROM tab0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-5601
SELECT + CAST ( col1 AS INTEGER ) * col1 AS col2 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT + col2 + 90 * + col1 FROM tab2 AS cor0
----
1568
2817
5336

query I rowsort
SELECT + + cor0.col2 + 64 AS col2 FROM tab1 AS cor0
----
118
121
160

query I rowsort
SELECT DISTINCT col1 * col0 + - 6 FROM tab1 AS cor0
----
1034
634
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-5605
SELECT - + 87 DIV - col1 FROM tab2 AS cor0
----
1
2
5

skipif mysql # not compatible
query I rowsort label-5605
SELECT - + 87 / - col1 FROM tab2 AS cor0
----
1
2
5

query I rowsort
SELECT + + cor0.col0 + col0 AS col0 FROM tab2 cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * col2 col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT col1 + - col1 - col2 AS col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT - col1 + + col0 * cor0.col2 FROM tab1 AS cor0
----
136
3638
7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + - col2 col1 FROM tab0 AS cor0
----
-119
-173
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col2 ) + + tab2.col0 col2 FROM tab2
----
104
117
34

query I rowsort
SELECT DISTINCT - tab2.col0 + + col1 AS col2 FROM tab2
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-5613
SELECT ( - col2 ) * col1 DIV - col1 AS col0 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-5613
SELECT ( - col2 ) * col1 / - col1 AS col0 FROM tab1
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 35 col1 FROM tab0 AS cor0
----
-3010
-3185
-3395

query I rowsort
SELECT + + col1 * col2 + + col2 * cor0.col1 AS col1 FROM tab1 AS cor0
----
1140
2496
2808

query I rowsort
SELECT - 35 + 6 * cor0.col2 AS col1 FROM tab1 AS cor0
----
289
307
541

query I rowsort
SELECT DISTINCT 80 - col0 AS col1 FROM tab1 AS cor0
----
0
16
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-5618
SELECT ALL + - col1 DIV 84 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5618
SELECT ALL + - col1 / 84 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ( - col2 ) * col2 + ( col2 ) FROM tab0 cor0
----
-1056
-6642
0

query I rowsort
SELECT ALL + ( + col0 ) + + col2 * - col1 AS col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT col1 * + 98 + col1 FROM tab2 AS cor0
----
1683
3069
5841

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5622
SELECT + CAST( + col0 AS SIGNED ) * + col1 + cor0.col1 AS col0 FROM tab2 AS cor0
----
1360
248
4661

skipif mysql # not compatible
query I rowsort label-5622
SELECT + CAST ( + col0 AS INTEGER ) * + col1 + cor0.col1 AS col0 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-5623
SELECT tab0.col0 + + 76 DIV - 51 AS col1 FROM tab0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-5623
SELECT tab0.col0 + + 76 / - 51 AS col1 FROM tab0
----
23
34
88

query I rowsort
SELECT col0 * 36 FROM tab1
----
108
2304
2880

query I rowsort
SELECT DISTINCT col1 * col2 + tab1.col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT - - cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT 23 + + col0 * col0 AS col1 FROM tab1
----
32
4119
6423

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 AS cor2
----
3645 values hashing to 76903cfa3a27727fd541d9dcdf362a4c

query I rowsort
SELECT ALL tab1.col0 * 77 + + col1 AS col0 FROM tab1
----
257
4938
6173

query I rowsort
SELECT + ( + col1 ) * col2 FROM tab0 cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col0 * 82 col1 FROM tab1 AS cor0
----
-246
-5248
-6560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5632
SELECT DISTINCT 92 + col2 * + col0 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5632
SELECT DISTINCT 92 + col2 * + col0 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

query I rowsort
SELECT + + 15 * - col1 AS col2 FROM tab2 AS cor0
----
-255
-465
-885

query I rowsort
SELECT ( col2 * 26 ) FROM tab1
----
1404
1482
2496

onlyif mysql # use DIV operator for integer division
query I rowsort label-5635
SELECT DISTINCT - col2 + + col1 DIV col1 AS col1 FROM tab1
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-5635
SELECT DISTINCT - col2 + + col1 / col1 AS col1 FROM tab1
----
-53
-56
-95

query I rowsort
SELECT - + col2 + + 16 FROM tab0 cor0
----
-17
-66
15

query I rowsort
SELECT - - 32 FROM tab0, tab2 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT DISTINCT tab2.col0 - col1 * + 66 AS col0 FROM tab2
----
-1043
-2039
-3816

query I rowsort
SELECT DISTINCT + col0 + + col2 - + col1 FROM tab1
----
111
163
31

query I rowsort
SELECT + col1 * - 57 FROM tab2 AS cor0
----
-1767
-3363
-969

skipif mysql # not compatible
query I rowsort
SELECT ALL - col1 + CAST ( - col0 AS REAL ) * - col1 AS col1 FROM tab2 AS cor0
----
1326
186
4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT - + col0 * CAST ( - col2 AS REAL ) + col1 col2 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT 11 * - col1 FROM tab1 AS cor0
----
-110
-143
-286

query I rowsort
SELECT cor0.col1 - - col0 AS col2 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT DISTINCT + + cor0.col2 * col1 - ( 22 + - col0 * cor0.col0 ) AS col2 FROM tab1 AS cor0
----
1391
4644
7626

query I rowsort
SELECT + - col2 * col1 - ( + col2 ) AS col0 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT - - col0 * + col0 - ( - 3 * col1 ) FROM tab0 AS cor0
----
1516
8194
834

query I rowsort
SELECT 11 + - col2 * - cor0.col2 AS col0 FROM tab2 cor0
----
1455
687
740

query I rowsort
SELECT DISTINCT col2 * col0 * 32 AS col1 FROM tab1 cor0
----
116736
245760
5184

query I rowsort
SELECT + col0 - cor0.col1 AS col0 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT ALL - - 21 * + col1 + - ( + 19 ) FROM tab1 cor0
----
191
254
527

query I rowsort
SELECT DISTINCT - col2 * cor0.col1 * ( col2 + col2 * col0 ) FROM tab2 AS cor0
----
-180792
-1963840
-3150836

query I rowsort
SELECT DISTINCT - - col0 + cor0.col0 AS col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT - col2 + + 49 FROM tab2 cor0
----
11
22
23

query I rowsort
SELECT DISTINCT - + col1 + ( cor0.col1 ) FROM tab0 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + col1 + + 80 col2 FROM tab2 AS cor0
----
114
142
198

query I rowsort
SELECT ALL + 32 + + col2 AS col0 FROM tab1
----
128
86
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5658
SELECT ALL - 42 + + cor0.col2 DIV col1 AS col0 FROM tab1 AS cor0
----
-35
-37
-40

skipif mysql # not compatible
query I rowsort label-5658
SELECT ALL - 42 + + cor0.col2 / col1 AS col0 FROM tab1 AS cor0
----
-35
-37
-40

query I rowsort
SELECT col2 + - col2 * cor0.col0 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL 98 * col1 AS col1 FROM tab2 AS cor0
----
1666
3038
5782

query I rowsort
SELECT 78 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to f0487ba81d377516702723e098c02ba1

query I rowsort
SELECT - tab0.col1 + + cor0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 058c984b3f4456ee2c7744387482643c

query I rowsort
SELECT + col0 - ( tab1.col1 ) * tab1.col2 AS col0 FROM tab1
----
-1168
-1401
-506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5664
SELECT ALL - - CAST( NULL AS SIGNED ) col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5664
SELECT ALL - - CAST ( NULL AS INTEGER ) col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 34 * - col0 AS col0 FROM tab1 cor0
----
-102
-2176
-2720

query I rowsort
SELECT DISTINCT + ( - tab1.col2 ) FROM tab1, tab0 AS cor0
----
-54
-57
-96

query I rowsort
SELECT + ( + col0 ) * col2 + - col0 FROM tab1
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-5668
SELECT 18 + 25 + + col2 DIV col0 FROM tab1
----
43
44
61

skipif mysql # not compatible
query I rowsort label-5668
SELECT 18 + 25 + + col2 / col0 FROM tab1
----
43
44
61

query I rowsort
SELECT + col2 + 91 - col1 FROM tab0
----
-5
38
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 13 - - col2 col0 FROM tab1
----
41
44
83

query I rowsort
SELECT DISTINCT - 7 + - col0 FROM tab0 AS cor0
----
-31
-42
-96

query I rowsort
SELECT ALL col0 * - col1 + + cor0.col1 AS col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT tab0.col1 + + tab0.col1 * - col2 AS col2 FROM tab0
----
-2752
-7371
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5674
SELECT CAST( NULL AS DECIMAL ) FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5674
SELECT CAST ( NULL AS REAL ) FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - 35 * + col1 * 22 FROM tab2 AS cor0
----
-13090
-23870
-45430

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + cor0.col2 * col1 col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL - tab0.col1 * col1 * + col1 AS col2 FROM tab0
----
-636056
-753571
-912673

query I rowsort
SELECT DISTINCT cor0.col1 * 15 + 48 AS col1 FROM tab2, tab0 cor0
----
1338
1413
1503

query I rowsort
SELECT DISTINCT - 41 * - cor0.col2 * - 57 FROM tab2 AS cor0
----
-60762
-63099
-88806

query IIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0 WHERE NULL IN ( - cor0.col0 )
----

query I rowsort
SELECT + 96 AS col1 FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to f1d978c2d5bfc6f26e0907ac777be83e

query I rowsort
SELECT - + col2 + 98 AS col1 FROM tab1 AS cor0
----
2
41
44

query I rowsort
SELECT DISTINCT - col1 + + ( + col2 ) FROM tab2 AS cor0
----
-33
-4
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col0 col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT col0 * + 26 AS col1 FROM tab1
----
1664
2080
78

query I rowsort
SELECT DISTINCT - ( ( - col0 ) ) AS col1 FROM tab0 cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5687
SELECT DISTINCT 65 + col0 DIV - col0 AS col1 FROM tab0 AS cor0
----
64

skipif mysql # not compatible
query I rowsort label-5687
SELECT DISTINCT 65 + col0 / - col0 AS col1 FROM tab0 AS cor0
----
64

query I rowsort
SELECT ALL + + col2 * 34 + col0 * + cor0.col2 * cor0.col2 FROM tab0 AS cor0
----
27258
601224
69

query I rowsort
SELECT + + 46 + 69 AS col1 FROM tab0 AS cor0
----
115
115
115

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 96 + - col0 * col0 col2 FROM tab2 AS cor0
----
-5988
-6145
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 56 col2 FROM tab2 AS cor0
----
56

query I rowsort
SELECT col0 * - 98 + + col2 FROM tab2 AS cor0
----
-659
-7618
-7704

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 - 62 col1 FROM tab0 AS cor0
----
-151
-86
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5694
SELECT DISTINCT CAST( NULL AS SIGNED ) / 40 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-5694
SELECT DISTINCT CAST ( NULL AS INTEGER ) / 40 FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT - ( + col2 ) + col2 AS col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT 80 * - col0 FROM tab0 AS cor0
----
-1920
-2800
-7120

query I rowsort
SELECT DISTINCT - cor0.col0 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + 16 * 4 FROM tab0 cor0
----
64
64
64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5699
SELECT CAST( NULL AS SIGNED ) / + 84 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5699
SELECT CAST ( NULL AS INTEGER ) / + 84 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 11 AS col0 FROM tab1, tab0, tab1 cor0
----
27 values hashing to 69116737f3f57e2e3273f6dbb04d036c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5701
SELECT tab1.col0 * - col0 * + CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5701
SELECT tab1.col0 * - col0 * + CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT 46 * + col2 FROM tab2
----
1196
1242
1748

query I rowsort
SELECT 3 * + col2 * - col1 AS col2 FROM tab2
----
-1938
-2511
-4602

query I rowsort
SELECT DISTINCT 16 FROM tab2, tab1 AS cor0
----
16

query I rowsort
SELECT ALL - - 2 FROM tab1, tab2 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT DISTINCT - 38 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 0 col0 FROM tab1
----
0

query I rowsort
SELECT - 39 + - col0 - + 74 FROM tab1
----
-116
-177
-193

query I rowsort
SELECT - col2 + - col0 * - 16 FROM tab2
----
1222
1226
85

query I rowsort
SELECT + col2 * + 12 + cor0.col2 FROM tab2 AS cor0
----
338
351
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-5711
SELECT + + col0 * ( + cor0.col2 ) DIV col1 + + col0 AS col1 FROM tab0 cor0
----
169
33
35

skipif mysql # not compatible
query I rowsort label-5711
SELECT + + col0 * ( + cor0.col2 ) / col1 + + col0 AS col1 FROM tab0 cor0
----
169
33
35

query I rowsort
SELECT ALL tab0.col2 + 35 * tab0.col0 + col2 FROM tab0
----
1227
3279
906

query I rowsort
SELECT cor1.col0 + + cor0.col2 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
27 values hashing to 69aef5111c4de6da0dae514eae0942b5

query I rowsort
SELECT + col2 * - ( - ( - col1 ) * - col0 ) FROM tab1
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-5715
SELECT - col0 DIV ( 9 ) + col2 * col0 * col1 + + col1 AS col2 FROM tab0 AS cor0
----
3489
664200
68196

skipif mysql # not compatible
query I rowsort label-5715
SELECT - col0 / ( 9 ) + col2 * col0 * col1 + + col1 AS col2 FROM tab0 AS cor0
----
3489
664200
68196

query I rowsort
SELECT DISTINCT col2 + + cor0.col2 + + col2 FROM tab1 AS cor0
----
162
171
288

query I rowsort
SELECT col0 + col1 * cor0.col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT - 41 AS col0 FROM tab2, tab0 cor0
----
-41

query I rowsort
SELECT - ( 12 ) AS col0 FROM tab0 AS cor0
----
-12
-12
-12

query I rowsort
SELECT - - 31 + col1 AS col1 FROM tab2 AS cor0
----
48
62
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-5721
SELECT col2 DIV col1 + - col2 FROM tab1 AS cor0
----
-52
-52
-89

skipif mysql # not compatible
query I rowsort label-5721
SELECT col2 / col1 + - col2 FROM tab1 AS cor0
----
-52
-52
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5722
SELECT - ( - 77 ) DIV - col1 AS col0 FROM tab2
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-5722
SELECT - ( - 77 ) / - col1 AS col0 FROM tab2
----
-1
-2
-4

query I rowsort
SELECT DISTINCT + 99 + + col2 * + col0 FROM tab0
----
134
7397
891

query I rowsort
SELECT - 77 + col1 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
-25
-51
-57

query I rowsort
SELECT 1 * col2 - col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 54 * - col2 + col2 FROM tab0 AS cor0
----
1815
4510
55

query I rowsort
SELECT ALL col1 * col2 * - col1 - col2 AS col1 FROM tab2 AS cor0
----
-11020
-25974
-90532

query I rowsort
SELECT + 11 + - col2 * col0 AS col0 FROM tab0 AS cor0
----
-24
-7287
-781

query I rowsort
SELECT ALL + col1 * + 69 AS col0 FROM tab2
----
1173
2139
4071

query I rowsort
SELECT ALL + col1 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT - 18 * col0 + - col1 + - col2 FROM tab0 cor0
----
-1775
-551
-728

query I rowsort
SELECT ALL - col1 * col2 * col0 + - col0 AS col1 FROM tab0 AS cor0
----
-3430
-664207
-68136

query I rowsort
SELECT col0 + - col1 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT DISTINCT - + col1 * col2 * cor0.col1 + col2 AS col0 FROM tab1 AS cor0
----
-16128
-36450
-5643

query I rowsort
SELECT ALL + col1 - - col2 AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL 14 - - col2 FROM tab1
----
110
68
71

query I rowsort
SELECT ALL + col1 - + col0 * - col0 * + tab0.col0 AS col0 FROM tab0
----
13910
42972
705060

query I rowsort
SELECT DISTINCT + col0 * - col1 + + col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT + ( + col0 ) * - col1 AS col0 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT + col2 * 21 FROM tab2 cor0
----
546
567
798

query I rowsort
SELECT - cor0.col2 - + cor0.col0 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to aac9661904614ee295157ea355327523

query I rowsort
SELECT ALL + col0 * - col1 + col1 AS col2 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL - + 18 * col1 * + col0 + + col0 FROM tab2 AS cor0
----
-24095
-3899
-82758

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5744
SELECT DISTINCT - CAST( + 2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-2

skipif mysql # not compatible
query I rowsort label-5744
SELECT DISTINCT - CAST ( + 2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-2

query I rowsort
SELECT DISTINCT - cor0.col0 FROM tab1, tab2, tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL + 47 * - col2 FROM tab0
----
-1551
-3854
-47

query I rowsort
SELECT ALL - 47 FROM tab2, tab2 AS cor0
----
9 values hashing to 6942a0d9558277afd0d00408d65cf5aa

query I rowsort
SELECT DISTINCT + - col0 + + 95 AS col1 FROM tab2 cor0
----
16
17
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5749
SELECT DISTINCT - + col1 + CAST( NULL AS SIGNED ) * - cor0.col2 col2 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5749
SELECT DISTINCT - + col1 + CAST ( NULL AS INTEGER ) * - cor0.col2 col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col1 * col1 + + col1 * + col2 FROM tab1 AS cor0
----
1417
2080
670

query I rowsort
SELECT ALL + col1 + + 96 * - ( cor0.col1 ) + ( col2 * + cor0.col1 ) FROM tab1 AS cor0
----
-1066
-380
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + - ( + col2 ) col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL - + col2 * 47 - + col0 AS col0 FROM tab0 AS cor0
----
-1575
-3943
-82

query I rowsort
SELECT DISTINCT col0 * + cor0.col2 + - 38 + col1 * - 70 * ( - cor0.col2 ) FROM tab2 AS cor0
----
109370
48184
58741

query I rowsort
SELECT col1 + + cor0.col0 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT + col2 * + col0 + - col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT DISTINCT - + col0 + - 48 AS col2 FROM tab1 AS cor0
----
-112
-128
-51

onlyif mysql # use DIV operator for integer division
query I rowsort label-5758
SELECT col2 DIV 60 + col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-5758
SELECT col2 / 60 + col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + + ( + 72 ) * + col0 AS col1 FROM tab2 AS cor0
----
504
5616
5688

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5760
SELECT ALL - + CAST( - col1 AS SIGNED ) * + col1 FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-5760
SELECT ALL - + CAST ( - col1 AS INTEGER ) * + col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL 5 AS col2 FROM tab1, tab0 cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 0da436460d6fcea5a1eb4b1d2219d7c9

query I rowsort
SELECT DISTINCT col0 * col0 - - col0 FROM tab1
----
12
4160
6480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5763
SELECT + CAST( - col1 AS SIGNED ) - col0 col2 FROM tab0 cor0
----
-110
-132
-180

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5763
SELECT + CAST ( - col1 AS INTEGER ) - col0 col2 FROM tab0 cor0
----
-110
-132
-180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * 47 + + col0 * 80 col0 FROM tab0 AS cor0
----
11397
5962
7359

query I rowsort
SELECT DISTINCT - 51 * + col1 FROM tab1 AS cor0
----
-1326
-510
-663

query I rowsort
SELECT DISTINCT + - 60 AS col2 FROM tab0 AS cor0
----
-60

query I rowsort
SELECT ALL 89 * - col1 + 61 FROM tab0 AS cor0
----
-7593
-8038
-8572

query I rowsort
SELECT ALL 87 * col1 AS col0 FROM tab1 AS cor0
----
1131
2262
870

query I rowsort
SELECT ALL col1 * + col2 * col2 - - col2 AS col2 FROM tab0 AS cor0
----
611966
93687
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5770
SELECT DISTINCT + cor0.col0 DIV col0 + col2 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-5770
SELECT DISTINCT + cor0.col0 / col0 + col2 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT DISTINCT + 8 * - col0 FROM tab0 cor0
----
-192
-280
-712

query I rowsort
SELECT DISTINCT + col1 * cor0.col2 - col2 AS col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT ALL + col0 * - 10 + 28 FROM tab2 AS cor0
----
-42
-752
-762

query I rowsort
SELECT DISTINCT - col0 - + col1 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT ALL col1 * 96 AS col2 FROM tab1 AS cor0
----
1248
2496
960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5776
SELECT CAST( NULL AS DECIMAL ) AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5776
SELECT CAST ( NULL AS REAL ) AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL + - col1 + - cor0.col1 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT ALL col2 + - ( col1 ) AS col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT col2 + 85 - col2 * + col2 FROM tab0 AS cor0
----
-6557
-971
85

query I rowsort
SELECT DISTINCT col2 * 28 - 53 * col0 AS col0 FROM tab1 AS cor0
----
-1552
-1796
1353

query I rowsort
SELECT col0 + 3 * 27 AS col0 FROM tab2 cor0
----
159
160
88

query I rowsort
SELECT ALL + col2 + ( cor0.col0 ) * col2 AS col2 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT tab0.col2 + 68 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 3f5021a255431cf91513da287feefb13

query I rowsort
SELECT DISTINCT - 37 AS col2 FROM tab0, tab1, tab0 AS cor0
----
-37

query I rowsort
SELECT ALL - col0 + + 88 FROM tab0 AS cor0
----
-1
53
64

query I rowsort
SELECT - - cor0.col1 * ( col2 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - cor0.col2 + 87 * col2 AS col0 FROM tab1 AS cor0
----
4644
4902
8256

query I rowsort
SELECT DISTINCT + col0 * + col0 + cor0.col0 AS col1 FROM tab2 cor0
----
56
6162
6320

query I rowsort
SELECT cor0.col1 + 33 AS col2 FROM tab0 AS cor0
----
119
124
130

query I rowsort
SELECT + + col2 * col1 + - col2 AS col2 FROM tab2 AS cor0
----
1508
608
810

onlyif mysql # use DIV operator for integer division
query I rowsort label-5791
SELECT col2 DIV 15 + col2 FROM tab0
----
1
35
87

skipif mysql # not compatible
query I rowsort label-5791
SELECT col2 / 15 + col2 FROM tab0
----
1
35
87

query I rowsort
SELECT + col2 * ( cor0.col1 ) FROM tab0 cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5793
SELECT ALL + col0 DIV + 5 FROM tab1 AS cor0
----
0
12
16

skipif mysql # not compatible
query I rowsort label-5793
SELECT ALL + col0 / + 5 FROM tab1 AS cor0
----
0
12
16

query I rowsort
SELECT 61 - 21 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT + ( tab1.col0 ) FROM tab1, tab0 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT ALL + 50 + + col2 AS col1 FROM tab2
----
76
77
88

query I rowsort
SELECT ALL tab0.col0 + + tab0.col0 FROM tab0
----
178
48
70

query I rowsort
SELECT col0 + + col1 + col1 AS col2 FROM tab0
----
196
229
271

query I rowsort
SELECT 51 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

query I rowsort
SELECT + 47 * col0 * - col2 FROM tab2 AS cor0
----
-141094
-8883
-95316

query I rowsort
SELECT + 51 FROM tab2, tab0 AS cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT DISTINCT - 69 + col2 AS col2 FROM tab2
----
-31
-42
-43

query I rowsort
SELECT - ( - tab0.col1 + + col1 ) * col2 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT tab2.col0 * + col2 * + ( col0 ) FROM tab2
----
1323
158184
237158

query I rowsort
SELECT DISTINCT + ( + col2 ) * - col0 + - col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT - - 46 * - col0 AS col0 FROM tab2 AS cor0
----
-322
-3588
-3634

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5807
SELECT - + col2 * col1 * + CAST( col2 AS SIGNED ) + + col1 + - col1 AS col1 FROM tab2 AS cor0
----
-22599
-24548
-39884

skipif mysql # not compatible
query I rowsort label-5807
SELECT - + col2 * col1 * + CAST ( col2 AS INTEGER ) + + col1 + - col1 AS col1 FROM tab2 AS cor0
----
-22599
-24548
-39884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5808
SELECT + col1 * col1 + - CAST( 64 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
225
3417
897

skipif mysql # not compatible
query I rowsort label-5808
SELECT + col1 * col1 + - CAST ( 64 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
225
3417
897

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col1 * col2 col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT col0 * - cor0.col2 * + col0 + + col0 + col2 FROM tab0 AS cor0
----
-1189
-18951
-649351

onlyif mysql # use DIV operator for integer division
query I rowsort label-5811
SELECT - col2 DIV + 80 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5811
SELECT - col2 / + 80 FROM tab0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5812
SELECT DISTINCT - 38 - col0 DIV - 99 AS col0 FROM tab0
----
-38

skipif mysql # not compatible
query I rowsort label-5812
SELECT DISTINCT - 38 - col0 / - 99 AS col0 FROM tab0
----
-38

query I rowsort
SELECT 96 + + col1 FROM tab2 cor0
----
113
127
155

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5814
SELECT + tab1.col1 + tab1.col2 + + CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5814
SELECT + tab1.col1 + tab1.col2 + + CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 96 * + col2 - 65 AS col0 FROM tab0
----
-161
-3233
-7937

onlyif mysql # use DIV operator for integer division
query I rowsort label-5816
SELECT - 90 DIV col0 FROM tab1 AS cor0
----
-1
-1
-30

skipif mysql # not compatible
query I rowsort label-5816
SELECT - 90 / col0 FROM tab1 AS cor0
----
-1
-1
-30

query I rowsort
SELECT ALL + + col2 * - col1 * - col0 FROM tab0 AS cor0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-5818
SELECT DISTINCT ( + col1 ) DIV - cor0.col0 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-5818
SELECT DISTINCT ( + col1 ) / - cor0.col0 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT - 77 + - 99 FROM tab2, tab1 AS cor0
----
9 values hashing to 5422b73687e5d07933bd6d3933181a00

query I rowsort
SELECT ALL - 77 + col0 FROM tab1 AS cor0
----
-13
-74
3

query I rowsort
SELECT - cor0.col2 FROM tab2, tab1, tab0 cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

onlyif mysql # use DIV operator for integer division
query I rowsort label-5822
SELECT ALL - col1 DIV - tab0.col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5822
SELECT ALL - col1 / - tab0.col1 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col0 * - 29 + col2 + + col2 col1 FROM tab0
----
-1013
-2417
-630

query I rowsort
SELECT ALL + ( 83 ) AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

query I rowsort
SELECT + + cor0.col2 + - col0 * col0 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT + + col2 * - col1 + + col0 AS col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT - ( cor0.col1 ) * + cor0.col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT + 54 FROM tab0, tab1, tab0 AS cor0
----
54

query I rowsort
SELECT + + col1 * + 81 AS col1 FROM tab2 AS cor0
----
1377
2511
4779

query I rowsort
SELECT + - 43 AS col0 FROM tab2 AS cor0
----
-43
-43
-43

query I rowsort
SELECT DISTINCT - col2 * ( - col2 ) * + ( col0 * col2 ) + + col1 * col2 FROM tab1 cor0
----
11852922
473796
70780128

query I rowsort
SELECT DISTINCT + ( - col2 + col1 ) FROM tab0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5833
SELECT ALL col0 DIV 91 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5833
SELECT ALL col0 / 91 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - col2 * - col2 + - col0 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT ALL + 3 * - col1 + - 70 FROM tab2 AS cor0
----
-121
-163
-247

onlyif mysql # use DIV operator for integer division
query I rowsort label-5836
SELECT ALL + + col0 * - col2 + + ( 17 ) DIV + col0 FROM tab1 AS cor0
----
-157
-3648
-7680

skipif mysql # not compatible
query I rowsort label-5836
SELECT ALL + + col0 * - col2 + + ( 17 ) / + col0 FROM tab1 AS cor0
----
-157
-3648
-7680

query I rowsort
SELECT DISTINCT col2 * col2 * col1 + + cor0.col1 + col1 * ( col2 ) AS col0 FROM tab2 AS cor0
----
23467
25211
41477

onlyif mysql # use DIV operator for integer division
query I rowsort label-5838
SELECT + col2 DIV cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5838
SELECT + col2 / cor0.col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT ( - cor0.col1 ) * + col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL + 57 * - col0 FROM tab0
----
-1368
-1995
-5073

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5841
SELECT ALL col1 + + cor0.col1 * CAST( NULL AS DECIMAL ) + + ( - col2 * 70 ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5841
SELECT ALL col1 + + cor0.col1 * CAST ( NULL AS REAL ) + + ( - col2 * 70 ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( + col1 ) col1 FROM tab2 AS cor0
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5843
SELECT + + col2 * - col0 + - CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5843
SELECT + + col2 * - col0 + - CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 92 + + col1 FROM tab0 cor0
----
178
183
189

query I rowsort
SELECT DISTINCT + 53 + + col2 * 42 FROM tab0 AS cor0
----
1439
3497
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * 68 col2 FROM tab1 AS cor0
----
1768
680
884

query I rowsort
SELECT - col1 + 6 FROM tab2 cor0
----
-11
-25
-53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5848
SELECT col2 + - CAST( 21 AS SIGNED ) FROM tab1
----
33
36
75

skipif mysql # not compatible
query I rowsort label-5848
SELECT col2 + - CAST ( 21 AS INTEGER ) FROM tab1
----
33
36
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5849
SELECT - col2 + - CAST( NULL AS SIGNED ) * 69 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5849
SELECT - col2 + - CAST ( NULL AS INTEGER ) * 69 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5850
SELECT DISTINCT - col1 + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5850
SELECT DISTINCT - col1 + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col2 - col0 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL + col2 + - ( 14 ) FROM tab2 AS cor0
----
12
13
24

query I rowsort
SELECT ALL - col1 + + 98 FROM tab2 AS cor0
----
39
67
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * ( 69 ) col1 FROM tab2 AS cor0
----
1794
1863
2622

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5855
SELECT ALL - col0 + CAST( NULL AS SIGNED ) - + 15 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-5855
SELECT ALL - col0 + CAST ( NULL AS INTEGER ) - + 15 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 + - 99 AS col2 FROM tab0 AS cor0
----
-10
-64
-75

query I rowsort
SELECT ALL - + ( + 59 ) - - col0 * ( + 53 ) FROM tab2 AS cor0
----
312
4075
4128

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) + col0 * + 9 FROM tab0 cor0
----
183
314
719

query I rowsort
SELECT DISTINCT - + 98 * 71 AS col0 FROM tab2 AS cor0
----
-6958

query I rowsort
SELECT - 67 + - col0 * col1 FROM tab0 AS cor0
----
-2131
-3462
-8166

query I rowsort
SELECT ALL - 46 * - col2 FROM tab2 AS cor0
----
1196
1242
1748

query I rowsort
SELECT ALL + + 61 * 26 FROM tab0 AS cor0
----
1586
1586
1586

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 17 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT col1 * - cor0.col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5865
SELECT DISTINCT - 67 DIV - col1 AS col2 FROM tab2
----
1
2
3

skipif mysql # not compatible
query I rowsort label-5865
SELECT DISTINCT - 67 / - col1 AS col2 FROM tab2
----
1
2
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5866
SELECT ALL - + col0 * + CAST( 27 + - cor0.col2 * + col1 AS SIGNED ) FROM tab1 AS cor0
----
34752
4131
97680

skipif mysql # not compatible
query I rowsort label-5866
SELECT ALL - + col0 * + CAST ( 27 + - cor0.col2 * + col1 AS INTEGER ) FROM tab1 AS cor0
----
34752
4131
97680

query I rowsort
SELECT col1 * 35 * col0 AS col1 FROM tab2 AS cor0
----
161070
47005
7595

query I rowsort
SELECT + col2 * - 92 FROM tab0 AS cor0
----
-3036
-7544
-92

query I rowsort
SELECT ALL 76 * col0 AS col1 FROM tab0
----
1824
2660
6764

query I rowsort
SELECT ALL + ( - 40 ) FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 01aad4539198a6509248e086869f90a6

query I rowsort
SELECT + 22 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( ( + cor0.col0 ) ) + + 86 col0 FROM tab0, tab0 cor0
----
9 values hashing to 38581a1fe8f1669eda0dcbf2332e7c4a

onlyif mysql # use DIV operator for integer division
query I rowsort label-5873
SELECT ALL - col0 + col1 DIV 28 AS col2 FROM tab0 AS cor0
----
-21
-32
-86

skipif mysql # not compatible
query I rowsort label-5873
SELECT ALL - col0 + col1 / 28 AS col2 FROM tab0 AS cor0
----
-21
-32
-86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5874
SELECT ALL + - col0 + CAST( + col1 + col2 AS SIGNED ) FROM tab1 cor0
----
29
3
77

skipif mysql # not compatible
query I rowsort label-5874
SELECT ALL + - col0 + CAST ( + col1 + col2 AS INTEGER ) FROM tab1 cor0
----
29
3
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5875
SELECT DISTINCT + col1 * cor0.col1 - - col0 * col1 / - CAST( NULL AS DECIMAL ) FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5875
SELECT DISTINCT + col1 * cor0.col1 - - col0 * col1 / - CAST ( NULL AS REAL ) FROM tab1 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5876
SELECT DISTINCT col0 + CAST( NULL AS SIGNED ) * cor0.col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5876
SELECT DISTINCT col0 + CAST ( NULL AS INTEGER ) * cor0.col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - cor0.col2 - + 47 FROM tab1 cor0
----
-101
-104
-143

query I rowsort
SELECT DISTINCT + col0 * col0 + + 23 - col0 AS col0 FROM tab2 AS cor0
----
6029
6185
65

query I rowsort
SELECT DISTINCT col0 * + col0 + col0 FROM tab1
----
12
4160
6480

query I rowsort
SELECT col0 + + col2 * + col1 AS col1 FROM tab0
----
132
2862
7551

query I rowsort
SELECT 77 + - col0 * + col0 AS col1 FROM tab0
----
-1148
-499
-7844

query I rowsort
SELECT ALL 79 + 60 * + col0 * + col1 AS col0 FROM tab0 AS cor0
----
123919
203779
486019

query I rowsort
SELECT cor0.col2 + + 46 AS col0 FROM tab2 AS cor0
----
72
73
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-5884
SELECT DISTINCT + - col2 DIV col2 AS col0 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-5884
SELECT DISTINCT + - col2 / col2 AS col0 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT ALL - - ( col2 ) * + col2 + cor0.col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT col0 * 6 + col0 + cor0.col0 FROM tab0 cor0
----
192
280
712

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - col1 AS REAL ) * - col0 * + cor0.col1 + + 95 FROM tab2 cor0
----
22926
271613
6822

query I rowsort
SELECT DISTINCT 83 * cor0.col2 AS col2 FROM tab0 AS cor0
----
2739
6806
83

query I rowsort
SELECT + + col2 * cor0.col1 * + col0 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL - - col2 * 98 + col2 * ( + col2 ) * col2 AS col1 FROM tab0 AS cor0
----
39171
559404
99

query I rowsort
SELECT col0 + - col2 * col1 + + col1 * col0 FROM tab0 AS cor0
----
-750
3333
726

query I rowsort
SELECT ALL 0 AS col0 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT DISTINCT - 35 * - col2 + - col1 * - 10 * col2 + + 75 FROM tab0 AS cor0
----
1080
29610
77565

query I rowsort
SELECT DISTINCT + 3 + - col0 * ( + 83 ) AS col2 FROM tab1 AS cor0
----
-246
-5309
-6637

query I rowsort
SELECT DISTINCT - col0 * + col1 + + 16 FROM tab1 AS cor0
----
-1024
-62
-624

onlyif mysql # use DIV operator for integer division
query I rowsort label-5896
SELECT - col2 * - col1 * - 46 + - 43 DIV - tab2.col1 col2 FROM tab2
----
-29714
-38501
-70564

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5896
SELECT - col2 * - col1 * - 46 + - 43 / - tab2.col1 col2 FROM tab2
----
-29714
-38501
-70564

query I rowsort
SELECT - 32 * - col1 AS col1 FROM tab1
----
320
416
832

query I rowsort
SELECT + col1 + cor0.col0 + 78 FROM tab1 AS cor0
----
107
152
171

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5899
SELECT DISTINCT cor0.col0 / + CAST( NULL AS SIGNED ) FROM tab2, tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5899
SELECT DISTINCT cor0.col0 / + CAST ( NULL AS INTEGER ) FROM tab2, tab1 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 93 + + col2 col0 FROM tab0 AS cor0
----
126
175
94

query I rowsort
SELECT + + 28 * col1 + - col0 + 73 FROM tab1 AS cor0
----
289
357
798

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + col2 col0 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT - 35 - col2 * col2 AS col0 FROM tab0 cor0
----
-1124
-36
-6759

query I rowsort
SELECT ALL - 0 + col1 + + cor0.col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT - 65 + col1 AS col2 FROM tab2 AS cor0
----
-34
-48
-6

query I rowsort
SELECT DISTINCT - 71 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
-71

query I rowsort
SELECT col0 + - 40 AS col0 FROM tab2 cor0
----
-33
38
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5908
SELECT ALL + CAST( NULL AS SIGNED ) * + 93 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5908
SELECT ALL + CAST ( NULL AS INTEGER ) * + 93 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + tab1.col0 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL + ( - cor0.col2 ) AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - - col0 + + col0 * col2 FROM tab0 AS cor0
----
70
7387
816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * cor0.col2 col1 FROM tab2, tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ( + col2 ) * col1 + - col0 + + 8 FROM tab2
----
1464
575
838

onlyif mysql # use DIV operator for integer division
query I rowsort label-5914
SELECT - 32 DIV - col1 + cor0.col2 AS col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-5914
SELECT - 32 / - col1 + cor0.col2 AS col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + 16 + col1 AS col2 FROM tab2 AS cor0
----
33
47
75

query I rowsort
SELECT - - 87 + col0 AS col1 FROM tab1 AS cor0
----
151
167
90

query I rowsort
SELECT + ( - 44 ) * - tab0.col1 AS col0 FROM tab0
----
3784
4004
4268

query I rowsort
SELECT ALL + col1 + col2 * + col2 * col0 AS col2 FROM tab1
----
207946
737293
8774

query I rowsort
SELECT DISTINCT - ( 63 ) + col1 AS col2 FROM tab1
----
-37
-50
-53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5920
SELECT - CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab1, tab2 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5920
SELECT - CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab1, tab2 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL + cor1.col2 * cor1.col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 255bedb67400f83d272763889db4ca4f

query I rowsort
SELECT + 90 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT DISTINCT tab2.col2 * + ( col1 ) FROM tab2
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-5924
SELECT + cor0.col0 DIV - 5 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to 08eb9e8a6957ae479bddfb006029afa6

skipif mysql # not compatible
query I rowsort label-5924
SELECT + cor0.col0 / - 5 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to 08eb9e8a6957ae479bddfb006029afa6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 27 - - 93 col2 FROM tab1 AS cor0
----
120
120
120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5926
SELECT ALL + CAST( col0 AS SIGNED ) + cor0.col1 FROM tab0 cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-5926
SELECT ALL + CAST ( col0 AS INTEGER ) + cor0.col1 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL 71 + col0 AS col1 FROM tab2 AS cor0
----
149
150
78

query I rowsort
SELECT DISTINCT + 41 + col0 AS col0 FROM tab1 AS cor0
----
105
121
44

query I rowsort
SELECT DISTINCT 31 * col2 AS col0 FROM tab2 AS cor0
----
1178
806
837

query I rowsort
SELECT DISTINCT - - 96 * col2 * col0 AS col0 FROM tab1 AS cor0
----
15552
350208
737280

skipif mysql # not compatible
query I rowsort
SELECT ALL - ( - col2 ) * - col1 + CAST ( cor0.col1 AS REAL ) FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT 8 * + 68 FROM tab2 AS cor0
----
544
544
544

query I rowsort
SELECT ALL + - ( + col1 ) * - col2 + col0 * 52 AS col1 FROM tab1 cor0
----
1560
3898
5408

query I rowsort
SELECT DISTINCT - col0 - cor0.col1 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT col2 + ( - 80 ) * col2 FROM tab1
----
-4266
-4503
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-5936
SELECT col2 - col0 * col1 DIV col0 FROM tab1
----
28
47
83

skipif mysql # not compatible
query I rowsort label-5936
SELECT col2 - col0 * col1 / col0 FROM tab1
----
28
47
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5937
SELECT + - 88 + col1 * - col0 + - cor0.col0 * - col2 * - CAST( - col1 + col0 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-197720
-515688
3560

skipif mysql # not compatible
query I rowsort label-5937
SELECT + - 88 + col1 * - col0 + - cor0.col0 * - col2 * - CAST ( - col1 + col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-197720
-515688
3560

query I rowsort
SELECT + - 96 FROM tab0 cor0
----
-96
-96
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 81 * + col2 * - col2 col1 FROM tab2
----
-116964
-54756
-59049

query I rowsort
SELECT - 39 * col2 FROM tab1
----
-2106
-2223
-3744

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5941
SELECT ALL CAST( NULL AS SIGNED ) * + col0 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5941
SELECT ALL CAST ( NULL AS INTEGER ) * + col0 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - 51 AS col1 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to 27bcc31433ce90833ed76619cbd8d6a4

query I rowsort
SELECT + col1 + - col2 * col0 AS col2 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT + 63 AS col2 FROM tab0
----
63
63
63

query I rowsort
SELECT + 8 * - col1 - 87 FROM tab0
----
-775
-815
-863

query I rowsort
SELECT ALL - col1 * ( col1 ) AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL + col0 * 42 AS col0 FROM tab2 AS cor0
----
294
3276
3318

query I rowsort
SELECT + col2 * - 20 FROM tab0 cor0
----
-1640
-20
-660

query I rowsort
SELECT DISTINCT col2 + 11 * col2 AS col2 FROM tab0 AS cor0
----
12
396
984

query I rowsort
SELECT ALL col0 + - col2 + col0 FROM tab0 AS cor0
----
15
69
96

query I rowsort
SELECT ALL - 20 + + col2 + col0 FROM tab2
----
14
84
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5952
SELECT ALL 73 * col1 * CAST( 42 AS SIGNED ) + col1 AS col0 FROM tab0
----
263762
279097
297499

skipif mysql # not compatible
query I rowsort label-5952
SELECT ALL 73 * col1 * CAST ( 42 AS INTEGER ) + col1 AS col0 FROM tab0
----
263762
279097
297499

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab2.col0 + - col0 * ( + tab2.col1 + col1 ) * - tab2.col2 col1 FROM tab2
----
102147
11725
239382

query I rowsort
SELECT - col2 + 22 * + 11 AS col0 FROM tab1 AS cor0
----
146
185
188

query I rowsort
SELECT - tab1.col1 * + 16 + - col2 * tab1.col0 AS col1 FROM tab1
----
-3808
-578
-7888

query I rowsort
SELECT - - col0 + ( col1 ) FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT col1 * ( - col0 ) * - col2 FROM tab2 AS cor0
----
119652
51034
5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5958
SELECT DISTINCT - - col0 * - CAST( NULL AS DECIMAL ) FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5958
SELECT DISTINCT - - col0 * - CAST ( NULL AS REAL ) FROM tab2 cor0
----
NULL

query I rowsort
SELECT - + col1 * 44 * - col2 FROM tab0 AS cor0
----
124872
328328
4268

query I rowsort
SELECT + col2 + - 51 * + cor0.col0 AS col2 FROM tab0 cor0
----
-1191
-1784
-4457

query I rowsort
SELECT ALL col1 - + tab1.col0 AS col0 FROM tab1
----
-54
-67
23

query I rowsort
SELECT + ( cor0.col0 ) * - col0 + - col2 AS col1 FROM tab2 AS cor0
----
-6110
-6279
-76

query I rowsort
SELECT - - cor0.col2 + 57 AS col1 FROM tab1 AS cor0
----
111
114
153

query I rowsort
SELECT + 86 + 33 AS col0 FROM tab2 AS cor0
----
119
119
119

query I rowsort
SELECT col2 * + cor0.col0 * - col0 + - col0 * - col1 FROM tab2 cor0
----
-1106
-153582
-235815

query I rowsort
SELECT - ( 93 ) + cor0.col2 * cor0.col2 FROM tab1 AS cor0
----
2823
3156
9123

query I rowsort
SELECT - col2 * col1 - col1 FROM tab2 AS cor0
----
-1593
-663
-868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 ) * col0 * 99 - + col1 * col2 col2 FROM tab1 AS cor0
----
-513
404934
632352

query I rowsort
SELECT ALL - 6 * - cor0.col1 + col0 * 87 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
7054
7218
802

query I rowsort
SELECT DISTINCT - col2 * + cor0.col2 + + col1 FROM tab0 cor0
----
-1003
-6633
96

query I rowsort
SELECT DISTINCT + col0 * col0 + + cor0.col1 * col1 FROM tab2 AS cor0
----
1010
6530
9565

query I rowsort
SELECT DISTINCT + col1 * col2 + col1 AS col0 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT - 88 - - col2 * col0 FROM tab2 AS cor0
----
101
1940
2914

query I rowsort
SELECT + ( - cor0.col2 ) * 16 - + col0 FROM tab1 AS cor0
----
-1616
-867
-976

query I rowsort
SELECT ALL - cor0.col1 * + col2 * + col0 FROM tab2 cor0
----
-119652
-51034
-5859

query I rowsort
SELECT ALL - cor0.col0 FROM tab1, tab1 AS cor0, tab2 cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT - - col1 + - col1 * cor0.col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT 36 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
36

query I rowsort
SELECT - + 93 AS col2 FROM tab0 cor0
----
-93
-93
-93

query I rowsort
SELECT + col2 * ( - cor0.col0 ) + + cor0.col0 AS col1 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL + ( + 48 ) * + col0 AS col2 FROM tab0 AS cor0
----
1152
1680
4272

query I rowsort
SELECT + col2 + - ( col0 * + col1 ) AS col0 FROM tab1 AS cor0
----
-24
-583
-944

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + col1 col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - 96 AS col1 FROM tab2 AS cor0
----
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5985
SELECT ALL CAST( - 23 AS SIGNED ) * + cor0.col0 FROM tab1 AS cor0
----
-1472
-1840
-69

skipif mysql # not compatible
query I rowsort label-5985
SELECT ALL CAST ( - 23 AS INTEGER ) * + cor0.col0 FROM tab1 AS cor0
----
-1472
-1840
-69

onlyif mysql # use DIV operator for integer division
query I rowsort label-5986
SELECT DISTINCT + col1 DIV - 97 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5986
SELECT DISTINCT + col1 / - 97 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5987
SELECT DISTINCT CAST( NULL AS SIGNED ) * 94 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5987
SELECT DISTINCT CAST ( NULL AS INTEGER ) * 94 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + 14 + - 84 * col1 FROM tab0 AS cor0
----
-7210
-7630
-8134

query I rowsort
SELECT ALL + col2 + col1 * - col0 AS col0 FROM tab1 AS cor0
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-5990
SELECT ALL - + col2 DIV col0 col1 FROM tab0 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5990
SELECT ALL - + col2 / col0 col1 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT col0 + + 63 AS col0 FROM tab0
----
152
87
98

query I rowsort
SELECT ALL tab0.col1 * col1 * - col1 + + col1 FROM tab0
----
-635970
-753480
-912576

query I rowsort
SELECT DISTINCT + 31 + col0 AS col2 FROM tab2 AS cor0
----
109
110
38

query I rowsort
SELECT + ( cor0.col0 ) + col2 * + col2 AS col1 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT + 71 + + col1 FROM tab1 AS cor0
----
81
84
97

query I rowsort
SELECT 38 * col1 + col1 FROM tab2 AS cor0
----
1209
2301
663

query I rowsort
SELECT - cor1.col0 * + cor1.col2 FROM tab1, tab2 cor0, tab2 cor1
----
27 values hashing to b0121644d0817627bc8036c50f8e780d

query I rowsort
SELECT - - ( 7 ) AS col1 FROM tab1 AS cor0
----
7
7
7

query I rowsort
SELECT DISTINCT - - col0 * + 77 - col2 AS col1 FROM tab2 AS cor0
----
512
5980
6045

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6000
SELECT DISTINCT + cor0.col1 + CAST( col0 AS SIGNED ) * col1 col2 FROM tab0 AS cor0
----
2150
3492
8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6000
SELECT DISTINCT + cor0.col1 + CAST ( col0 AS INTEGER ) * col1 col2 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL - col2 * + col0 + col2 - + col2 FROM tab1
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6002
SELECT + + col0 * col0 + col2 DIV + col0 FROM tab1 AS cor0
----
27
4096
6401

skipif mysql # not compatible
query I rowsort label-6002
SELECT + + col0 * col0 + col2 / + col0 FROM tab1 AS cor0
----
27
4096
6401

query I rowsort
SELECT - col1 * 22 + col0 + col2 AS col1 FROM tab0 AS cor0
----
-1831
-1835
-2098

query I rowsort
SELECT ALL - col2 * ( - col1 * tab1.col0 ) AS col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT DISTINCT + tab2.col1 - - cor0.col2 FROM tab2, tab0 cor0
----
9 values hashing to 57351d452a382e227a12f019d3a3f0c9

query I rowsort
SELECT ALL - col0 * + 1 + + 96 + col0 FROM tab1
----
96
96
96

query I rowsort
SELECT ALL col0 * col2 + col1 AS col1 FROM tab0
----
132
7389
878

query I rowsort
SELECT DISTINCT + - col0 + ( - col1 ) AS col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT + - col2 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL - 44 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 07457d9e571e036a9a3a0f5a5a2e1ef2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6011
SELECT ALL + col1 + col1 + - 15 DIV col2 FROM tab0
----
172
179
182

skipif mysql # not compatible
query I rowsort label-6011
SELECT ALL + col1 + col1 + - 15 / col2 FROM tab0
----
172
179
182

query I rowsort
SELECT ALL - col2 * - ( - 76 ) + col0 FROM tab0 AS cor0
----
-2484
-41
-6143

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * ( + cor0.col2 ) col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + + col2 * + col2 + - 4 FROM tab2 AS cor0
----
1440
672
725

query I rowsort
SELECT - - col2 * 55 + - col0 FROM tab0 AS cor0
----
1791
20
4421

query I rowsort
SELECT + cor0.col1 AS col0 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ALL - ( + col0 ) * - col2 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6018
SELECT ( + col0 ) * col2 + CAST( col1 AS SIGNED ) * - col0 AS col2 FROM tab0 cor0
----
-1272
-3360
-801

skipif mysql # not compatible
query I rowsort label-6018
SELECT ( + col0 ) * col2 + CAST ( col1 AS INTEGER ) * - col0 AS col2 FROM tab0 cor0
----
-1272
-3360
-801

query I rowsort
SELECT 70 + col0 AS col2 FROM tab1 cor0
----
134
150
73

query I rowsort
SELECT + col0 * - col0 * + col0 AS col0 FROM tab0
----
-13824
-42875
-704969

query I rowsort
SELECT col0 * - col1 * - col0 AS col0 FROM tab1
----
234
40960
83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col0 + col2 col2 FROM tab0 AS cor0
----
63
84
95

query I rowsort
SELECT ALL + + 65 - - col0 FROM tab2 AS cor0
----
143
144
72

query I rowsort
SELECT DISTINCT 95 AS col1 FROM tab1
----
95

query I rowsort
SELECT ALL 5 + cor0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to b2ebf49c24091b76a4280a8ad4875abe

onlyif mysql # use DIV operator for integer division
query I rowsort label-6026
SELECT DISTINCT + cor0.col2 + 60 DIV + col0 FROM tab1 AS cor0
----
57
74
96

skipif mysql # not compatible
query I rowsort label-6026
SELECT DISTINCT + cor0.col2 + 60 / + col0 FROM tab1 AS cor0
----
57
74
96

query I rowsort
SELECT + cor0.col1 * + col0 + 2 * col1 AS col0 FROM tab2 AS cor0
----
1377
279
4720

onlyif mysql # use DIV operator for integer division
query I rowsort label-6028
SELECT col0 - - 38 DIV 52 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6028
SELECT col0 - - 38 / 52 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 63 + tab2.col0 col0 FROM tab2
----
-56
15
16

query I rowsort
SELECT + col0 * ( col1 ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT 83 FROM tab2, tab1 cor0
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

onlyif mysql # use DIV operator for integer division
query I rowsort label-6032
SELECT - ( + col1 ) DIV + col2 AS col2 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-6032
SELECT - ( + col1 ) / + col2 AS col2 FROM tab0 AS cor0
----
-1
-2
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6033
SELECT col0 * - col1 * - col0 + + col0 + + col2 DIV cor0.col1 FROM tab1 AS cor0
----
239
41029
83287

skipif mysql # not compatible
query I rowsort label-6033
SELECT col0 * - col1 * - col0 + + col0 + + col2 / cor0.col1 FROM tab1 AS cor0
----
239
41029
83287

query I rowsort
SELECT - - cor0.col2 + 49 * + col1 * - ( ( col1 ) ) FROM tab2 cor0
----
-14123
-170543
-47062

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6035
SELECT - CAST( NULL AS SIGNED ) + + ( col2 ) + + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6035
SELECT - CAST ( NULL AS INTEGER ) + + ( col2 ) + + col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * + col0 * - col2 FROM tab1 AS cor0
----
-207936
-737280
-8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-6037
SELECT 97 DIV 5 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

skipif mysql # not compatible
query I rowsort label-6037
SELECT 97 / 5 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

query I rowsort
SELECT + + 29 + + col0 FROM tab1 AS cor0
----
109
32
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6039
SELECT DISTINCT + col2 + col1 * - CAST( col1 AS SIGNED ) FROM tab1 AS cor0
----
-43
-622
-73

skipif mysql # not compatible
query I rowsort label-6039
SELECT DISTINCT + col2 + col1 * - CAST ( col1 AS INTEGER ) FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT ALL + 29 * - col1 * ( 28 ) AS col2 FROM tab0 cor0
----
-69832
-73892
-78764

onlyif mysql # use DIV operator for integer division
query I rowsort label-6041
SELECT tab2.col1 DIV 87 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6041
SELECT tab2.col1 / 87 FROM tab2
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col0 + - 29 col2 FROM tab0
----
1196
547
7892

onlyif mysql # use DIV operator for integer division
query I rowsort label-6043
SELECT - - col1 + 28 DIV - col0 AS col0 FROM tab0 AS cor0
----
85
91
97

skipif mysql # not compatible
query I rowsort label-6043
SELECT - - col1 + 28 / - col0 AS col0 FROM tab0 AS cor0
----
85
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6044
SELECT col1 - 49 DIV - ( + cor0.col0 ) FROM tab1 AS cor0
----
10
13
42

skipif mysql # not compatible
query I rowsort label-6044
SELECT col1 - 49 / - ( + cor0.col0 ) FROM tab1 AS cor0
----
10
13
42

query I rowsort
SELECT ALL 74 + - 97 FROM tab0 AS cor0
----
-23
-23
-23

query I rowsort
SELECT ALL col0 * 91 + - cor0.col1 + + col2 AS col2 FROM tab2 AS cor0
----
633
7065
7210

query I rowsort
SELECT + + 98 + col1 FROM tab1 AS cor0
----
108
111
124

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( cor0.col2 ) + + col2 + - col1 col0 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + col0 * + ( col2 ) * - col0 AS col2 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT + col0 * ( + 18 * + col1 ) AS col1 FROM tab2
----
24174
3906
82836

query I rowsort
SELECT col2 * 65 * - 27 AS col0 FROM tab0
----
-143910
-1755
-57915

query I rowsort
SELECT DISTINCT - 51 FROM tab0, tab2 AS cor0
----
-51

onlyif mysql # use DIV operator for integer division
query I rowsort label-6053
SELECT - ( ( col1 ) ) * col2 + - col2 DIV - col0 AS col0 FROM tab1 AS cor0
----
-1247
-1386
-570

skipif mysql # not compatible
query I rowsort label-6053
SELECT - ( ( col1 ) ) * col2 + - col2 / - col0 AS col0 FROM tab1 AS cor0
----
-1247
-1386
-570

query I rowsort
SELECT ALL - 16 + + 91 * col0 * - col0 FROM tab0 AS cor0
----
-111491
-52432
-720827

query I rowsort
SELECT ALL - col1 + col2 * col0 AS col1 FROM tab1 AS cor0
----
136
3638
7667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6056
SELECT DISTINCT - CAST( NULL AS SIGNED ) + + col0 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6056
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + + col0 FROM tab1 cor0
----
NULL

query I rowsort
SELECT + ( + cor0.col1 ) * - col1 + - cor0.col2 * col2 FROM tab2 cor0
----
-1690
-1733
-4157

query I rowsort
SELECT ALL + - 20 FROM tab2 AS cor0
----
-20
-20
-20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6059
SELECT ALL CAST( NULL AS SIGNED ) * cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6059
SELECT ALL CAST ( NULL AS INTEGER ) * cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + cor0.col1 * - 20 AS col2 FROM tab0 AS cor0
----
1720
1820
1940

query I rowsort
SELECT - + col0 * - 52 + + col0 - col1 FROM tab0 AS cor0
----
1186
1758
4626

query I rowsort
SELECT + + col1 * col2 + + col0 * col0 * cor0.col0 + + col0 FROM tab2 AS cor0
----
1187
476164
493764

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6063
SELECT ALL - CAST( NULL AS DECIMAL ) * + col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6063
SELECT ALL - CAST ( NULL AS REAL ) * + col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 94 + col0 * cor0.col0 * + cor0.col0 FROM tab1 AS cor0
----
121
262238
512094

query I rowsort
SELECT ALL + 14 + col0 + col2 * - col0 AS col2 FROM tab2 AS cor0
----
-168
-1936
-2909

query I rowsort
SELECT + 93 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT + col2 + ( tab0.col2 ) FROM tab0
----
164
2
66

query I rowsort
SELECT DISTINCT - col0 * - col1 + + col0 AS col2 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT ALL 42 * col1 AS col1 FROM tab0 AS cor0
----
3612
3822
4074

query I rowsort
SELECT - col2 * col1 + col2 AS col1 FROM tab2 cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL + col2 + - tab2.col0 AS col1 FROM tab2
----
-41
-52
20

query I rowsort
SELECT ALL col0 + 47 * - col2 AS col0 FROM tab1
----
-2535
-2615
-4432

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6073
SELECT CAST( NULL AS SIGNED ) * - 8 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6073
SELECT CAST ( NULL AS INTEGER ) * - 8 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( col0 ) + col1 * col2 AS col1 FROM tab1
----
1168
1401
506

query I rowsort
SELECT ALL + - col0 + ( + 33 ) FROM tab1 AS cor0
----
-31
-47
30

query I rowsort
SELECT - col0 * + 29 AS col1 FROM tab0 AS cor0
----
-1015
-2581
-696

query I rowsort
SELECT ALL - cor0.col1 * + col0 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL - - col0 + ( + 2 ) FROM tab1 cor0
----
5
66
82

query I rowsort
SELECT col1 + ( - 43 ) * - col2 FROM tab2 AS cor0
----
1177
1192
1651

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6080
SELECT DISTINCT - col0 + CAST( NULL AS SIGNED ) * + col2 * col1 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6080
SELECT DISTINCT - col0 + CAST ( NULL AS INTEGER ) * + col2 * col1 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - + col1 + - 75 * col0 AS col0 FROM tab1 AS cor0
----
-251
-4810
-6013

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - col0 col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT 94 - + col1 FROM tab0
----
-3
3
8

query I rowsort
SELECT ALL 15 * - col2 FROM tab2
----
-390
-405
-570

query I rowsort
SELECT + tab0.col1 * - 44 * + tab0.col1 FROM tab0, tab1 cor0
----
9 values hashing to 1f1997c4c71b67e2fbc309d85e079b47

query I rowsort
SELECT ALL col1 - - col1 * 59 AS col2 FROM tab1
----
1560
600
780

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to 803a5565701c4ced6bba69940782c17a

query I rowsort
SELECT - tab2.col0 + 4 AS col0 FROM tab2
----
-3
-74
-75

query I rowsort
SELECT DISTINCT - + col0 * - 88 * ( col1 ) FROM tab1 AS cor0
----
56320
6864
91520

query I rowsort
SELECT col0 - 35 AS col0 FROM tab2 AS cor0
----
-28
43
44

query I rowsort
SELECT DISTINCT + + col0 - ( col0 ) FROM tab2 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6092
SELECT ALL - - col1 + + CAST( col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
137
38
96

skipif mysql # not compatible
query I rowsort label-6092
SELECT ALL - - col1 + + CAST ( col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT cor0.col1 + ( - 60 + col2 ) FROM tab0 AS cor0
----
113
38
59

query I rowsort
SELECT + col1 + - col1 - - col2 AS col2 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT + col0 + + col2 * - col1 * - col1 + cor0.col1 * col2 FROM tab2 AS cor0
----
11707
26791
92118

query I rowsort
SELECT col1 - - ( + col2 + col2 ) * + col2 FROM tab0 AS cor0
----
13539
2264
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6097
SELECT DISTINCT - col0 + - col2 + CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-6097
SELECT DISTINCT - col0 + - col2 + CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6098
SELECT ALL - 14 DIV + col0 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6098
SELECT ALL - 14 / + col0 AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6099
SELECT + 70 + - col1 DIV col1 FROM tab2 AS cor0
----
69
69
69

skipif mysql # not compatible
query I rowsort label-6099
SELECT + 70 + - col1 / col1 FROM tab2 AS cor0
----
69
69
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-6100
SELECT 68 DIV col1 + 50 FROM tab0 AS cor0
----
50
50
50

skipif mysql # not compatible
query I rowsort label-6100
SELECT 68 / col1 + 50 FROM tab0 AS cor0
----
50
50
50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6101
SELECT DISTINCT - + col0 + col1 * CAST( + 15 AS SIGNED ) FROM tab0 AS cor0
----
1266
1276
1420

skipif mysql # not compatible
query I rowsort label-6101
SELECT DISTINCT - + col0 + col1 * CAST ( + 15 AS INTEGER ) FROM tab0 AS cor0
----
1266
1276
1420

query I rowsort
SELECT DISTINCT + 32 * cor0.col2 + col2 + col1 AS col2 FROM tab2 AS cor0
----
1271
917
922

query I rowsort
SELECT + col0 + - cor0.col1 * + col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT - - col0 * + 65 + + col2 AS col0 FROM tab1 cor0
----
249
4217
5296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6105
SELECT col0 * CAST( NULL AS SIGNED ) + + col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6105
SELECT col0 * CAST ( NULL AS INTEGER ) + + col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col2 + col1 * + col2 + - col2 * 4 AS col2 FROM tab0 AS cor0
----
2739
7216
94

query I rowsort
SELECT DISTINCT - - col1 * + col1 + - col1 FROM tab1 AS cor0
----
156
650
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - ( + col0 ) col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - col0 * - col0 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT ( - col2 ) + ( col2 ) + col2 FROM tab1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6111
SELECT col0 DIV col0 + + col1 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-6111
SELECT col0 / col0 + + col1 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT ALL + - 95 * cor0.col2 + col0 AS col2 FROM tab2 AS cor0
----
-2392
-2558
-3531

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + col1 AS REAL ) + + col1 FROM tab0 AS cor0
----
172
182
194

onlyif mysql # use DIV operator for integer division
query I rowsort label-6114
SELECT DISTINCT + col0 + col1 + - col1 DIV - col2 AS col0 FROM tab0 AS cor0
----
112
181
229

skipif mysql # not compatible
query I rowsort label-6114
SELECT DISTINCT + col0 + col1 + - col1 / - col2 AS col0 FROM tab0 AS cor0
----
112
181
229

query I rowsort
SELECT ALL col0 + + 10 * + cor0.col1 FROM tab1 AS cor0
----
164
210
263

onlyif mysql # use DIV operator for integer division
query I rowsort label-6116
SELECT DISTINCT cor0.col1 DIV - 87 + col1 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-6116
SELECT DISTINCT cor0.col1 / - 87 + col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL - ( tab0.col1 + + tab0.col2 ) AS col0 FROM tab0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-6118
SELECT ALL - - 86 DIV - col2 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
-85
31
81

skipif mysql # not compatible
query I rowsort label-6118
SELECT ALL - - 86 / - col2 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
-85
31
81

query I rowsort
SELECT DISTINCT col0 * + cor0.col1 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6120
SELECT - CAST( col0 AS SIGNED ) * cor0.col2 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-6120
SELECT - CAST ( col0 AS INTEGER ) * cor0.col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - col1 * cor0.col1 * col1 + 94 FROM tab0 AS cor0
----
-635962
-753477
-912579

onlyif mysql # use DIV operator for integer division
query I rowsort label-6122
SELECT ALL col2 DIV 1 col0 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6122
SELECT ALL col2 / 1 col0 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 96 + - col2 - col1 col1 FROM tab1 AS cor0
----
-13
16
29

query I rowsort
SELECT DISTINCT - ( + 78 ) AS col0 FROM tab2 AS cor0
----
-78

query I rowsort
SELECT ALL 43 * col2 FROM tab2 cor0
----
1118
1161
1634

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6126
SELECT DISTINCT + CAST( NULL AS SIGNED ) + + col2 col0 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6126
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + + col2 col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + 45 FROM tab1, tab2 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT DISTINCT 2 AS col2 FROM tab1, tab0 AS cor0
----
2

query I rowsort
SELECT ALL 85 - + 0 FROM tab1, tab0 cor0 CROSS JOIN tab2, tab1 AS cor1
----
81 values hashing to 5e8deeabad7bbbaf313fcdcb4adc75eb

query I rowsort
SELECT + + ( - col2 ) * 86 AS col1 FROM tab0 AS cor0
----
-2838
-7052
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 56 col2 FROM tab0
----
56
56
56

query I rowsort
SELECT + + cor0.col2 + col2 * col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT - col0 + col2 * + 43 FROM tab0 AS cor0
----
1395
3437
8

query I rowsort
SELECT ALL - col0 + 12 FROM tab0 cor0
----
-12
-23
-77

query I rowsort
SELECT 67 + tab1.col1 + + 2 FROM tab1
----
79
82
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + - cor0.col1 col1 FROM tab2 cor0
----
-118
-34
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6137
SELECT 51 DIV col0 FROM tab2
----
0
0
7

skipif mysql # not compatible
query I rowsort label-6137
SELECT 51 / col0 FROM tab2
----
0
0
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6138
SELECT ALL col1 * - CAST( NULL AS DECIMAL ) * + col2 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6138
SELECT ALL col1 * - CAST ( NULL AS REAL ) * + col2 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 3 col1 FROM tab2
----
3
3
3

query I rowsort
SELECT + 25 * col0 FROM tab0 AS cor0
----
2225
600
875

query I rowsort
SELECT DISTINCT ( 47 ) AS col0 FROM tab0
----
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6142
SELECT CAST( NULL AS SIGNED ) * - col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6142
SELECT CAST ( NULL AS INTEGER ) * - col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 9 + cor0.col2 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 62eabbed21c8d12c3a0b7b427fb027f8

query I rowsort
SELECT ALL + 66 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT - - ( 6 ) * col1 FROM tab2 AS cor0
----
102
186
354

query I rowsort
SELECT + cor0.col0 * 94 + + col2 FROM tab2 AS cor0
----
685
7358
7464

query I rowsort
SELECT DISTINCT + cor0.col1 * 93 FROM tab0 AS cor0
----
7998
8463
9021

query I rowsort
SELECT - + col2 * col1 * + col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT 52 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT ALL - ( - col0 * - tab1.col0 ) + - col2 AS col0 FROM tab1
----
-4153
-63
-6496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( tab0.col1 ) col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

onlyif mysql # use DIV operator for integer division
query I rowsort label-6152
SELECT col1 * col1 - col0 DIV col0 AS col0 FROM tab1
----
168
675
99

skipif mysql # not compatible
query I rowsort label-6152
SELECT col1 * col1 - col0 / col0 AS col0 FROM tab1
----
168
675
99

query I rowsort
SELECT - col1 + + 98 * - col1 FROM tab2
----
-1683
-3069
-5841

query I rowsort
SELECT ALL ( col0 ) * + tab0.col2 + + col1 * - 33 * + col1 AS col1 FROM tab0
----
-243276
-265975
-310462

query I rowsort
SELECT - ( + col2 ) * col0 AS col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT - - col0 + - 74 * col1 AS col0 FROM tab1 AS cor0
----
-1921
-676
-882

query I rowsort
SELECT - col2 + - 4 FROM tab1 AS cor0
----
-100
-58
-61

query I rowsort
SELECT 23 AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 546d49aa433406dd83ea19885588e658

query I rowsort
SELECT + col0 * col2 + ( 82 ) AS col1 FROM tab2 AS cor0
----
2110
271
3084

query I rowsort
SELECT col2 * + col2 + + 53 AS col1 FROM tab0 AS cor0
----
1142
54
6777

query I rowsort
SELECT - cor0.col2 * 70 * ( + col2 ) + 7 AS col0 FROM tab2 cor0
----
-101073
-47313
-51023

query I rowsort
SELECT - + col0 + cor0.col1 * col1 AS col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT + - col1 * - ( + 82 ) AS col0 FROM tab0 cor0
----
7052
7462
7954

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 + 29 col1 FROM tab1 AS cor0
----
125
83
86

query I rowsort
SELECT DISTINCT - - col1 * - col1 + + 56 AS col0 FROM tab0 AS cor0
----
-7340
-8225
-9353

query I rowsort
SELECT + col0 + - col0 * + col0 AS col0 FROM tab0 cor0
----
-1190
-552
-7832

query I rowsort
SELECT - cor0.col2 * col1 + col0 * + col1 AS col0 FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT col2 * col0 + col0 + - col1 * + col2 FROM tab0
----
-2022
-27
-75

query I rowsort
SELECT - + col0 * col2 * cor0.col1 - - col1 FROM tab1 AS cor0
----
-36470
-4186
-99827

query I rowsort
SELECT ALL col2 * - col2 * + col1 + col2 FROM tab1 AS cor0
----
-119712
-32433
-75762

query I rowsort
SELECT ALL + col0 * ( + ( col2 ) * - ( + col1 ) ) FROM tab0 AS cor0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + ( col0 ) col2 FROM tab0
----
-9
34
7

query I rowsort
SELECT + col1 * + 27 + + 27 AS col0 FROM tab2
----
1620
486
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-6174
SELECT col1 + + col1 DIV tab0.col2 + col0 * 35 AS col0 FROM tab0
----
1419
3207
928

skipif mysql # not compatible
query I rowsort label-6174
SELECT col1 + + col1 / tab0.col2 + col0 * 35 AS col0 FROM tab0
----
1419
3207
928

query I rowsort
SELECT + col0 * + 92 FROM tab2
----
644
7176
7268

query I rowsort
SELECT DISTINCT - - col0 * ( col0 ) + col1 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT DISTINCT col2 + + 29 * + col1 FROM tab0 AS cor0
----
2527
2721
2814

onlyif mysql # use DIV operator for integer division
query I rowsort label-6178
SELECT ALL ( 99 ) + col2 DIV - col0 AS col2 FROM tab0 AS cor0
----
98
99
99

skipif mysql # not compatible
query I rowsort label-6178
SELECT ALL ( 99 ) + col2 / - col0 AS col2 FROM tab0 AS cor0
----
98
99
99

query I rowsort
SELECT + col0 * 71 - + col2 FROM tab0 AS cor0
----
1671
2484
6237

query I rowsort
SELECT ALL - + ( + col1 ) - col1 AS col2 FROM tab0 cor0
----
-172
-182
-194

onlyif mysql # use DIV operator for integer division
query I rowsort label-6181
SELECT ALL + 45 DIV + col1 + - col2 FROM tab1 AS cor0
----
-53
-53
-93

skipif mysql # not compatible
query I rowsort label-6181
SELECT ALL + 45 / + col1 + - col2 FROM tab1 AS cor0
----
-53
-53
-93

query I rowsort
SELECT DISTINCT + 46 * 10 AS col0 FROM tab2 AS cor0
----
460

onlyif mysql # use DIV operator for integer division
query I rowsort label-6183
SELECT DISTINCT - + 66 DIV - col0 col2 FROM tab2 AS cor0
----
0
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6183
SELECT DISTINCT - + 66 / - col0 col2 FROM tab2 AS cor0
----
0
9

query I rowsort
SELECT ALL - - col0 * + col2 + + col2 AS col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT + - 76 + col1 * col2 FROM tab2 AS cor0
----
1458
570
761

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - 2 - col1 col1 FROM tab0
----
-11
-55
-98

query I rowsort
SELECT + col1 + col2 * + 3 - + col2 * tab2.col1 AS col0 FROM tab2
----
-1397
-515
-725

query I rowsort
SELECT DISTINCT - col1 - 65 FROM tab0
----
-151
-156
-162

query I rowsort
SELECT ALL + + cor0.col1 * - 37 FROM tab0 AS cor0
----
-3182
-3367
-3589

query I rowsort
SELECT ALL col1 + + ( + col1 * - col1 ) - - tab1.col1 FROM tab1
----
-143
-624
-80

query I rowsort
SELECT DISTINCT + - col2 * + col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT col2 + col2 * col1 AS col0 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL - 9 * - col1 AS col2 FROM tab1 AS cor0
----
117
234
90

query I rowsort
SELECT - ( col1 ) * + col0 AS col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT ALL - col1 + - col2 * - col1 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6196
SELECT - col2 + col1 * CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6196
SELECT - col2 + col1 * CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 78 * + 24 FROM tab0
----
1872
1872
1872

query I rowsort
SELECT ( col2 ) * + col2 - - 30 FROM tab2
----
1474
706
759

query I rowsort
SELECT ALL ( - 73 * cor0.col1 ) FROM tab2, tab2 AS cor0
----
9 values hashing to ea993991fba20e7617d5ae162cbb9577

query I rowsort
SELECT ALL - tab1.col0 * + 22 * cor0.col1 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to dfea26809defc991939ef118dd3e1688

query I rowsort
SELECT DISTINCT + col1 * + col1 * + 50 FROM tab0
----
369800
414050
470450

query I rowsort
SELECT col1 * + col0 * col0 + + col1 * col2 - col0 FROM tab2 AS cor0
----
106664
2349
360412

query I rowsort
SELECT DISTINCT + tab2.col1 * col2 * + col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT col2 + col2 * col0 AS col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT tab0.col1 + + col1 * col0 AS col2 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - cor0.col2 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL cor0.col1 + - col0 AS col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL col0 FROM tab1 WHERE NOT NULL NOT BETWEEN col2 AND - tab1.col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6210
SELECT - - cor0.col2 DIV - col0 - + col0 FROM tab1 AS cor0
----
-21
-64
-81

skipif mysql # not compatible
query I rowsort label-6210
SELECT - - cor0.col2 / - col0 - + col0 FROM tab1 AS cor0
----
-21
-64
-81

query I rowsort
SELECT ALL + col1 + col0 * - col1 * - col1 FROM tab0 AS cor0
----
177590
329412
737100

query I rowsort
SELECT + + col0 - col1 * + col1 AS col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT DISTINCT - col1 * col1 + col2 + + cor0.col2 FROM tab1 AS cor0
----
-568
14
23

query I rowsort
SELECT DISTINCT - 11 + - col0 * - col1 AS col2 FROM tab0 AS cor0
----
2053
3384
8088

onlyif mysql # use DIV operator for integer division
query I rowsort label-6215
SELECT ALL - col0 * col2 + col1 DIV col0 FROM tab1 AS cor0
----
-154
-3648
-7680

skipif mysql # not compatible
query I rowsort label-6215
SELECT ALL - col0 * col2 + col1 / col0 FROM tab1 AS cor0
----
-154
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6216
SELECT + - 64 + col0 * col0 DIV + col1 AS col1 FROM tab2 cor0
----
-63
303
39

skipif mysql # not compatible
query I rowsort label-6216
SELECT + - 64 + col0 * col0 / + col1 AS col1 FROM tab2 cor0
----
-63
303
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-6217
SELECT ALL + col0 + - cor0.col0 DIV - col2 AS col2 FROM tab0 AS cor0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-6217
SELECT ALL + col0 + - cor0.col0 / - col2 AS col2 FROM tab0 AS cor0
----
24
70
90

query I rowsort
SELECT ALL 18 AS col0 FROM tab0 cor0
----
18
18
18

query I rowsort
SELECT DISTINCT - - 45 - + col2 * - col1 AS col0 FROM tab0 AS cor0
----
142
2883
7507

query I rowsort
SELECT DISTINCT + ( - col2 ) + + col0 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT ALL - col0 * col0 * + col1 AS col2 FROM tab0 AS cor0
----
-118825
-49536
-720811

query III rowsort
SELECT ALL * FROM tab1 WHERE ( NULL ) NOT IN ( - tab1.col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6223
SELECT - col1 DIV col0 + + tab0.col1 + + col0 col2 FROM tab0
----
107
130
179

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6223
SELECT - col1 / col0 + + tab0.col1 + + col0 col2 FROM tab0
----
107
130
179

query I rowsort
SELECT + tab2.col2 + col0 * col0 * + col1 FROM tab2
----
106135
1546
358982

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT ( NULL ) = NULL
----

query I rowsort
SELECT DISTINCT col1 - col2 AS col1 FROM tab1 WHERE ( + tab1.col1 ) >= col1 + col1 / col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6227
SELECT - col2 * tab0.col0 + col2 + col2 DIV col0 FROM tab0
----
-34
-7216
-758

skipif mysql # not compatible
query I rowsort label-6227
SELECT - col2 * tab0.col0 + col2 + col2 / col0 FROM tab0
----
-34
-7216
-758

query I rowsort
SELECT DISTINCT + 44 * col1 FROM tab2 AS cor0
----
1364
2596
748

query I rowsort
SELECT + col0 AS col2 FROM tab0 WHERE NOT ( + col1 ) IN ( + col2 * tab0.col0 + + col1 )
----
24
35
89

query I rowsort
SELECT DISTINCT - col1 AS col2 FROM tab0 WHERE NOT NULL = NULL
----

query I rowsort
SELECT + col2 + - col2 * + col0 FROM tab2 AS cor0
----
-162
-2002
-2964

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE ( NULL ) = + cor0.col2
----

query I rowsort
SELECT + col2 * + col1 + + col1 + - col0 AS col2 FROM tab0
----
159
2900
7464

onlyif mysql # use DIV operator for integer division
query I rowsort label-6234
SELECT DISTINCT - col2 DIV + col2 + col2 * + col0 + - col1 col1 FROM tab0
----
-63
705
7206

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6234
SELECT DISTINCT - col2 / + col2 + col2 * + col0 + - col1 col1 FROM tab0
----
-63
705
7206

query III rowsort
SELECT * FROM tab1 WHERE - col2 >= col0
----

query I rowsort
SELECT - col2 + + col2 FROM tab0 WHERE NOT col2 <= col1
----

query I rowsort
SELECT - col2 * col0 + - col0 FROM tab0
----
-70
-7387
-816

query I rowsort
SELECT DISTINCT col0 + col1 * col2 * col0 FROM tab1 cor0
----
36544
4215
99920

query I rowsort
SELECT ALL cor0.col2 + cor0.col2 * col1 * cor0.col2 FROM tab2 AS cor0
----
22626
24586
39910

query I rowsort
SELECT DISTINCT + - col1 * + col0 + + cor0.col0 AS col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-6241
SELECT col0 * col1 DIV col0 + - col0 AS col2 FROM tab0 AS cor0
----
2
62
62

skipif mysql # not compatible
query I rowsort label-6241
SELECT col0 * col1 / col0 + - col0 AS col2 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL + - col1 * col2 AS col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT - - col0 + - cor0.col1 + 84 FROM tab0 cor0
----
22
22
82

query I rowsort
SELECT - 90 FROM tab1, tab2, tab0 cor0
----
27 values hashing to c0d96679aba507520916e8654e5a6618

query I rowsort
SELECT ALL + cor0.col1 + col2 * - col2 FROM tab2 AS cor0
----
-1427
-617
-698

query I rowsort
SELECT - - col1 - - col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT col0 + col0 * ( cor0.col0 ) + - cor0.col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + + 66 + + col1 AS col1 FROM tab2 AS cor0
----
125
83
97

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 + col0 * - col1 * 72 - + col1 FROM tab2 AS cor0
----
-15655
-331403
-96713

query I rowsort
SELECT DISTINCT - - col1 * + col1 + col1 AS col2 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT ALL - cor1.col1 * cor1.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 79ea663c5f468cc57a869fc826cf04a5

query I rowsort
SELECT - - col0 + 84 + col1 AS col2 FROM tab1 cor0
----
113
158
177

query I rowsort
SELECT ALL - cor0.col0 + + cor0.col2 + 37 FROM tab1 AS cor0
----
30
53
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6255
SELECT - CAST( NULL AS DECIMAL ) * + cor0.col1 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6255
SELECT - CAST ( NULL AS REAL ) * + cor0.col1 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + ( - 95 ) FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to cf302b83f15b730fe35c19bdd9363c13

query I rowsort
SELECT col1 * col2 - col1 * col1 * + col1 AS col0 FROM tab1
----
-16172
-430
-949

query I rowsort
SELECT ALL - ( col0 ) - ( + 24 * col0 ) AS col1 FROM tab1
----
-1600
-2000
-75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 col0 FROM tab1, tab0 AS cor0 WHERE NULL NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT + 44 * col2 FROM tab0 cor0
----
1452
3608
44

query I rowsort
SELECT ALL - 69 - - 43 FROM tab2 AS cor0
----
-26
-26
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-6262
SELECT DISTINCT - CAST( + cor0.col2 AS SIGNED ) + + cor0.col0 DIV + col2 AS col2 FROM tab0 AS cor0
----
-33
-81
34

skipif mysql # not compatible
query I rowsort label-6262
SELECT DISTINCT - CAST ( + cor0.col2 AS INTEGER ) + + cor0.col0 / + col2 AS col2 FROM tab0 AS cor0
----
-33
-81
34

query I rowsort
SELECT ALL - 12 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 3983bffe2adf88cb2efc3be93ee620c0

query I rowsort
SELECT DISTINCT col2 * ( - col1 ) FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT cor0.col2 * - tab0.col1 FROM tab0, tab1 cor0
----
9 values hashing to 3e351fdfa2fd88779f2d7b6136dc00d1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6266
SELECT 69 DIV + ( col2 + + 4 ) AS col1 FROM tab2 AS cor0
----
1
2
2

skipif mysql # not compatible
query I rowsort label-6266
SELECT 69 / + ( col2 + + 4 ) AS col1 FROM tab2 AS cor0
----
1
2
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 5 col1 FROM tab0
----
-5
-5
-5

query I rowsort
SELECT DISTINCT + ( - 38 ) * col1 FROM tab0
----
-3268
-3458
-3686

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6269
SELECT - CAST( 87 AS SIGNED ) FROM tab2
----
-87
-87
-87

skipif mysql # not compatible
query I rowsort label-6269
SELECT - CAST ( 87 AS INTEGER ) FROM tab2
----
-87
-87
-87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6270
SELECT DISTINCT CAST( - col1 AS SIGNED ) FROM tab2
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-6270
SELECT DISTINCT CAST ( - col1 AS INTEGER ) FROM tab2
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * - cor0.col2 * col2 col2 FROM tab1 cor0
----
-207936
-737280
-8748

query I rowsort
SELECT + cor1.col1 + 48 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to baa3880a16e4ff665796379a71bd1bd1

query I rowsort
SELECT ALL - 46 AS col2 FROM tab0 AS cor0
----
-46
-46
-46

query I rowsort
SELECT DISTINCT + 52 + col1 * 93 FROM tab0 AS cor0
----
8050
8515
9073

query I rowsort
SELECT DISTINCT - ( - cor0.col1 ) AS col0 FROM tab2 cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 75 col0 FROM tab0
----
75
75
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-6277
SELECT + col0 DIV - col2 + - 19 * 99 * + tab0.col2 AS col0 FROM tab0
----
-154243
-1916
-62073

skipif mysql # not compatible
query I rowsort label-6277
SELECT + col0 / - col2 + - 19 * 99 * + tab0.col2 AS col0 FROM tab0
----
-154243
-1916
-62073

query I rowsort
SELECT DISTINCT 51 * + col0 FROM tab1 AS cor0
----
153
3264
4080

query I rowsort
SELECT ALL - cor0.col2 * col0 + cor0.col0 AS col1 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT + 12 + col1 FROM tab1 cor0
----
22
25
38

query I rowsort
SELECT - col2 * + col1 AS col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL ( col1 ) * col1 * + 45 FROM tab0 AS cor0
----
332820
372645
423405

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6283
SELECT + CAST( NULL AS DECIMAL ) col0 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6283
SELECT + CAST ( NULL AS REAL ) col0 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6284
SELECT ALL + col1 + - CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6284
SELECT ALL + col1 + - CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6285
SELECT col1 + - 9 * + ( + col1 * tab2.col1 ) + - ( col1 + - CAST( + ( col2 ) AS SIGNED ) ) FROM tab2
----
-2563
-31303
-8622

skipif mysql # not compatible
query I rowsort label-6285
SELECT col1 + - 9 * + ( + col1 * tab2.col1 ) + - ( col1 + - CAST ( + ( col2 ) AS INTEGER ) ) FROM tab2
----
-2563
-31303
-8622

onlyif mysql # use DIV operator for integer division
query I rowsort label-6286
SELECT DISTINCT col2 DIV + col0 + col0 + col2 * col0 FROM tab1
----
183
3712
7761

skipif mysql # not compatible
query I rowsort label-6286
SELECT DISTINCT col2 / + col0 + col0 + col2 * col0 FROM tab1
----
183
3712
7761

query I rowsort
SELECT ALL + col1 + + ( col0 ) + + cor0.col0 FROM tab0 AS cor0
----
134
167
269

onlyif mysql # use DIV operator for integer division
query I rowsort label-6288
SELECT - - col0 * + 60 * + 33 + col2 * - col0 DIV - col0 + + col0 AS col1 FROM tab1 cor0
----
126841
158576
5997

skipif mysql # not compatible
query I rowsort label-6288
SELECT - - col0 * + 60 * + 33 + col2 * - col0 / - col0 + + col0 AS col1 FROM tab1 cor0
----
126841
158576
5997

query I rowsort
SELECT ALL + - col0 * + 16 AS col1 FROM tab0 AS cor0
----
-1424
-384
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-6290
SELECT DISTINCT - col0 + ( + col0 ) * col1 DIV - 39 FROM tab1 AS cor0
----
-106
-5
-80

skipif mysql # not compatible
query I rowsort label-6290
SELECT DISTINCT - col0 + ( + col0 ) * col1 / - 39 FROM tab1 AS cor0
----
-106
-5
-80

query I rowsort
SELECT + cor0.col1 + + 12 + + col1 FROM tab0 AS cor0
----
184
194
206

query I rowsort
SELECT + + col2 * 53 + cor0.col1 FROM tab1 AS cor0
----
2888
3031
5101

query I rowsort
SELECT DISTINCT col0 + col0 * 66 * + col0 FROM tab1 AS cor0
----
270400
422480
597

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + ( + col2 ) * col1 col2 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-6295
SELECT DISTINCT + - col1 DIV col0 col2 FROM tab0 AS cor0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6295
SELECT DISTINCT + - col1 / col0 col2 FROM tab0 AS cor0
----
-1
-2
-3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6296
SELECT col0 + 49 * - col0 / + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6296
SELECT col0 + 49 * - col0 / + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( + 92 AS REAL ) FROM tab1 AS cor0
----
-92
-92
-92

query I rowsort
SELECT DISTINCT 7 * + col0 FROM tab2 AS cor0
----
49
546
553

query I rowsort
SELECT + col1 + - cor0.col2 * + col2 * + 44 + 95 * col2 AS col0 FROM tab1 AS cor0
----
-123148
-137531
-396371

onlyif mysql # use DIV operator for integer division
query I rowsort label-6300
SELECT DISTINCT - ( col2 ) + col1 DIV - col0 AS col2 FROM tab0 AS cor0
----
-3
-36
-83

skipif mysql # not compatible
query I rowsort label-6300
SELECT DISTINCT - ( col2 ) + col1 / - col0 AS col2 FROM tab0 AS cor0
----
-3
-36
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6301
SELECT ALL - 35 DIV - col2 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6301
SELECT ALL - 35 / - col2 AS col2 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6302
SELECT ALL CAST( - col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6302
SELECT ALL CAST ( - col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 77 col2 FROM tab2 AS cor0
----
77
77
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( ( col0 ) ) col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT - col2 * + col1 + - col0 FROM tab0
----
-132
-2862
-7551

query I rowsort
SELECT col1 * col0 * 83 FROM tab1
----
53120
6474
86320

query I rowsort
SELECT DISTINCT - tab0.col0 + 81 FROM tab0
----
-8
46
57

query I rowsort
SELECT DISTINCT + + 13 * + col0 + col1 * + cor0.col2 + col2 FROM tab1 AS cor0
----
1459
1497
2384

query I rowsort
SELECT - 52 + - 33 FROM tab2 AS cor0
----
-85
-85
-85

query I rowsort
SELECT DISTINCT col1 + col0 * + col1 AS col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL - 56 + col1 AS col1 FROM tab2 AS cor0
----
-25
-39
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + 10 * - col0 col2 FROM tab0 AS cor0
----
-273
-351
-972

query I rowsort
SELECT ALL + + ( + 22 ) FROM tab1 AS cor0
----
22
22
22

query I rowsort
SELECT DISTINCT + - 48 AS col1 FROM tab1 cor0
----
-48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + - col0 * - cor0.col0 col2 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT DISTINCT - - col1 * 81 FROM tab0 AS cor0
----
6966
7371
7857

query I rowsort
SELECT + 86 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

query I rowsort
SELECT - cor0.col1 + 92 * cor0.col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to fd3753e05545fa635cd8e5a4d4017fe2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6319
SELECT ALL - + col0 DIV + col1 + - 76 AS col1 FROM tab0 AS cor0
----
-76
-76
-76

skipif mysql # not compatible
query I rowsort label-6319
SELECT ALL - + col0 / + col1 + - 76 AS col1 FROM tab0 AS cor0
----
-76
-76
-76

query I rowsort
SELECT col1 * - 10 + - col1 * - ( col0 ) * tab0.col2 AS col1 FROM tab0
----
2425
663208
67252

query I rowsort
SELECT + + col1 * col2 + col0 AS col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT + 33 * cor0.col1 FROM tab2 AS cor0
----
1023
1947
561

onlyif mysql # use DIV operator for integer division
query I rowsort label-6323
SELECT - col0 DIV + col0 + 9 FROM tab0 AS cor0
----
8
8
8

skipif mysql # not compatible
query I rowsort label-6323
SELECT - col0 / + col0 + 9 FROM tab0 AS cor0
----
8
8
8

query I rowsort
SELECT + - 5 + cor0.col0 AS col0 FROM tab1 cor0
----
-2
59
75

query I rowsort
SELECT - col0 * + col0 + + ( - col2 * col1 ) AS col0 FROM tab2 AS cor0
----
-6887
-7618
-886

query I rowsort
SELECT DISTINCT + 61 AS col1 FROM tab2, tab2 AS cor0
----
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-6327
SELECT DISTINCT 99 DIV col0 FROM tab1
----
1
33

skipif mysql # not compatible
query I rowsort label-6327
SELECT DISTINCT 99 / col0 FROM tab1
----
1
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-6328
SELECT ALL col1 * col1 DIV - col1 + + col0 AS col2 FROM tab0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort label-6328
SELECT ALL col1 * col1 / - col1 + + col0 AS col2 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT ALL col1 * - tab2.col1 * + 56 AS col1 FROM tab2
----
-16184
-194936
-53816

query I rowsort
SELECT col0 * + col0 + col2 * + col2 FROM tab2 AS cor0
----
6760
7685
778

onlyif mysql # use DIV operator for integer division
query I rowsort label-6331
SELECT DISTINCT - ( - col2 ) + - 89 DIV col2 FROM tab0 AS cor0
----
-88
31
81

skipif mysql # not compatible
query I rowsort label-6331
SELECT DISTINCT - ( - col2 ) + - 89 / col2 FROM tab0 AS cor0
----
-88
31
81

query I rowsort
SELECT + 6 * cor0.col1 FROM tab0 AS cor0
----
516
546
582

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 36 + col1 * - cor0.col1 col0 FROM tab2 AS cor0
----
-253
-3445
-925

query I rowsort
SELECT DISTINCT + col1 + col1 * col1 * - col2 FROM tab0 AS cor0
----
-243982
-678951
-9312

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 - ( col1 ) * cor0.col1 col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - 9 * + 15 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 899e4d5fe0f98daa3442473c18052f07

query I rowsort
SELECT col2 * - cor0.col2 * + col1 FROM tab1 cor0
----
-119808
-32490
-75816

query I rowsort
SELECT + + 35 + col0 * + col2 + col1 * col0 * - 49 FROM tab0 AS cor0
----
-100309
-166285
-389518

query I rowsort
SELECT - col1 * col1 * col0 + col2 * ( col0 + - col2 ) AS col0 FROM tab1 AS cor0
----
-15056
-4782
-6001

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6341
SELECT + col0 + CAST( NULL AS SIGNED ) / + ( - col0 ) + 92 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6341
SELECT + col0 + CAST ( NULL AS INTEGER ) / + ( - col0 ) + 92 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 * ( - col2 ) * tab2.col2 + tab2.col2 FROM tab2
----
-114038
-5076
-52702

query I rowsort
SELECT col0 + 36 * 39 * + col2 FROM tab0 AS cor0
----
115217
1439
46356

query I rowsort
SELECT ALL + col2 * + col0 + - 48 AS col1 FROM tab2 AS cor0
----
141
1980
2954

query I rowsort
SELECT - + col1 * 11 FROM tab0 AS cor0
----
-1001
-1067
-946

query I rowsort
SELECT col2 + 98 * - col0 FROM tab2 AS cor0
----
-659
-7618
-7704

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6347
SELECT - CAST( + 53 AS SIGNED ) - + col1 FROM tab2 AS cor0
----
-112
-70
-84

skipif mysql # not compatible
query I rowsort label-6347
SELECT - CAST ( + 53 AS INTEGER ) - + col1 FROM tab2 AS cor0
----
-112
-70
-84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + cor0.col2 col1 FROM tab0 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6349
SELECT col2 + + col2 * + col0 DIV - col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6349
SELECT col2 + + col2 * + col0 / - col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + + cor0.col1 + - col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + ( col2 ) + - ( col0 + col2 * 55 ) AS col1 FROM tab1 AS cor0
----
-2919
-3142
-5264

onlyif mysql # use DIV operator for integer division
query I rowsort label-6352
SELECT DISTINCT + 37 DIV - col1 AS col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-6352
SELECT DISTINCT + 37 / - col1 AS col1 FROM tab0
----
0

query I rowsort
SELECT cor0.col2 + - cor0.col2 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6354
SELECT col1 DIV col1 + + 29 * tab1.col2 FROM tab1
----
1567
1654
2785

skipif mysql # not compatible
query I rowsort label-6354
SELECT col1 / col1 + + 29 * tab1.col2 FROM tab1
----
1567
1654
2785

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6355
SELECT CAST( + ( - cor0.col1 ) AS DECIMAL ) * CAST( NULL AS SIGNED ) * 48 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6355
SELECT CAST ( + ( - cor0.col1 ) AS REAL ) * CAST ( NULL AS INTEGER ) * 48 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL - + col2 + - ( 77 ) * - col1 FROM tab0 AS cor0
----
6589
6925
7468

query I rowsort
SELECT DISTINCT + cor0.col2 * + ( - col1 ) FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - - col1 + col0 * - col1 * col0 AS col0 FROM tab1 AS cor0
----
-208
-40950
-83187

onlyif mysql # use DIV operator for integer division
query I rowsort label-6359
SELECT ALL col1 DIV + 88 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6359
SELECT ALL col1 / + 88 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col1 * - col0 + col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT ALL cor0.col2 * - cor0.col0 FROM tab2, tab1 cor0
----
9 values hashing to f7e57a354e4e5925116b9650d1011609

query I rowsort
SELECT cor0.col1 + + col1 * col2 + - col2 AS col2 FROM tab1 AS cor0
----
1165
1376
523

query I rowsort
SELECT ALL + + ( + 75 ) AS col0 FROM tab0 AS cor0
----
75
75
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( + col1 ) + col0 * cor0.col2 col1 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-6365
SELECT ALL + 60 * - col0 + - col2 DIV 31 + col1 AS col1 FROM tab2 AS cor0
----
-389
-4621
-4724

skipif mysql # not compatible
query I rowsort label-6365
SELECT ALL + 60 * - col0 + - col2 / 31 + col1 AS col1 FROM tab2 AS cor0
----
-389
-4621
-4724

query I rowsort
SELECT - 55 + col1 FROM tab0 AS cor0
----
31
36
42

query I rowsort
SELECT + col0 * - cor0.col1 + + ( col2 ) * - col2 FROM tab2 AS cor0
----
-2787
-5278
-946

query I rowsort
SELECT DISTINCT - ( + ( - col1 ) ) FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT + col1 * - col1 * - 61 AS col2 FROM tab2 cor0
----
17629
212341
58621

query I rowsort
SELECT DISTINCT 40 FROM tab2, tab2 cor0, tab1 AS cor1
----
40

query I rowsort
SELECT ALL + col0 + 70 AS col2 FROM tab0 AS cor0
----
105
159
94

query I rowsort
SELECT cor0.col1 * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - - col0 * - col0 + + col0 FROM tab2 AS cor0
----
-42
-6006
-6162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 63 * col2 + ( col1 ) * col2 * 72 col0 FROM tab2
----
112086
48906
61965

query I rowsort
SELECT col0 - + col2 * - col1 AS col2 FROM tab0
----
132
2862
7551

query I rowsort
SELECT DISTINCT + cor0.col1 * + 15 AS col0 FROM tab1 AS cor0
----
150
195
390

query I rowsort
SELECT - + col2 + - 49 FROM tab2 AS cor0
----
-75
-76
-87

query I rowsort
SELECT + col0 * - col0 + cor0.col1 AS col0 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT + col0 * + col1 * + 41 FROM tab2 AS cor0
----
188682
55063
8897

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6380
SELECT DISTINCT + CAST( 72 AS SIGNED ) FROM tab2, tab2 AS cor0, tab2 AS cor1
----
72

skipif mysql # not compatible
query I rowsort label-6380
SELECT DISTINCT + CAST ( 72 AS INTEGER ) FROM tab2, tab2 AS cor0, tab2 AS cor1
----
72

query I rowsort
SELECT DISTINCT - 75 * 62 FROM tab2, tab0 AS cor0
----
-4650

onlyif mysql # use DIV operator for integer division
query I rowsort label-6382
SELECT ALL + cor0.col1 - - col2 DIV - col0 AS col2 FROM tab0 AS cor0
----
85
91
97

skipif mysql # not compatible
query I rowsort label-6382
SELECT ALL + cor0.col1 - - col2 / - col0 AS col2 FROM tab0 AS cor0
----
85
91
97

query I rowsort
SELECT DISTINCT cor0.col1 * col0 + col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT ALL + - col1 - col1 AS col0 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT DISTINCT col2 * + 43 * col0 AS col2 FROM tab1
----
156864
330240
6966

query I rowsort
SELECT ALL + 49 - + col1 AS col1 FROM tab1
----
23
36
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-6387
SELECT DISTINCT - col1 + col1 - col0 DIV ( col0 * col1 ) FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-6387
SELECT DISTINCT - col1 + col1 - col0 / ( col0 * col1 ) FROM tab2
----
0

query I rowsort
SELECT DISTINCT - col1 * tab2.col1 + col2 * + 17 - col1 AS col0 FROM tab2
----
-3098
-533
340

query I rowsort
SELECT 28 - tab1.col2 * col0 AS col2 FROM tab1
----
-134
-3620
-7652

query I rowsort
SELECT DISTINCT tab0.col0 - 58 * + col1 FROM tab0
----
-4964
-5189
-5591

query I rowsort
SELECT DISTINCT - 49 * col2 AS col0 FROM tab1 AS cor0
----
-2646
-2793
-4704

query I rowsort
SELECT 94 + tab1.col1 AS col1 FROM tab1
----
104
107
120

onlyif mysql # use DIV operator for integer division
query I rowsort label-6393
SELECT - - col0 * col1 DIV - col2 FROM tab0 AS cor0
----
-3395
-62
-98

skipif mysql # not compatible
query I rowsort label-6393
SELECT - - col0 * col1 / - col2 FROM tab0 AS cor0
----
-3395
-62
-98

query I rowsort
SELECT DISTINCT 44 + col0 AS col0 FROM tab0
----
133
68
79

query I rowsort
SELECT + + cor0.col1 * + col1 + col1 FROM tab2 AS cor0
----
306
3540
992

onlyif mysql # use DIV operator for integer division
query I rowsort label-6396
SELECT + col1 DIV cor0.col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6396
SELECT + col1 / cor0.col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL + - 61 * col1 AS col0 FROM tab2 cor0
----
-1037
-1891
-3599

query I rowsort
SELECT DISTINCT - 74 * col2 AS col0 FROM tab2 AS cor0
----
-1924
-1998
-2812

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 59 col2 FROM tab1 AS cor0
----
59
59
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6400
SELECT ALL + 78 DIV col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-6400
SELECT ALL + 78 / col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT 21 * 56 FROM tab1 cor0 CROSS JOIN tab1 cor1
----
9 values hashing to fbeb9cbbe489fa80077c44af5d784ee9

query I rowsort
SELECT DISTINCT - - 98 + - col1 * - col1 FROM tab2 AS cor0
----
1059
3579
387

query I rowsort
SELECT ALL - 38 AS col2 FROM tab2 AS cor0
----
-38
-38
-38

query I rowsort
SELECT ( - col0 ) * + col2 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + cor0.col2 + - col0 * col1 AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-6406
SELECT + col2 + + col0 DIV + cor0.col2 FROM tab1 cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-6406
SELECT + col2 + + col0 / + cor0.col2 FROM tab1 cor0
----
54
58
96

query I rowsort
SELECT ALL - 42 * - col1 + + col1 AS col1 FROM tab2 AS cor0
----
1333
2537
731

query I rowsort
SELECT - - col2 * col2 * col0 AS col1 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT ALL - - ( + col0 ) * col1 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + 83 * - cor0.col1 FROM tab1 AS cor0
----
-1079
-2158
-830

onlyif mysql # use DIV operator for integer division
query I rowsort label-6411
SELECT - col2 DIV col2 col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6411
SELECT - col2 / col2 col2 FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6412
SELECT DISTINCT + ( cor0.col0 ) DIV 8 AS col0 FROM tab0, tab0 cor0
----
11
3
4

skipif mysql # not compatible
query I rowsort label-6412
SELECT DISTINCT + ( cor0.col0 ) / 8 AS col0 FROM tab0, tab0 cor0
----
11
3
4

query I rowsort
SELECT ALL - col1 * ( + cor0.col2 ) + col2 * + col2 AS col1 FROM tab0 cor0
----
-1749
-738
-96

query I rowsort
SELECT + - ( - 46 ) AS col1 FROM tab1 AS cor0
----
46
46
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-6415
SELECT ALL - 22 + col2 DIV + col0 AS col2 FROM tab2 AS cor0
----
-19
-22
-22

skipif mysql # not compatible
query I rowsort label-6415
SELECT ALL - 22 + col2 / + col0 AS col2 FROM tab2 AS cor0
----
-19
-22
-22

query I rowsort
SELECT ALL 84 + col1 FROM tab1 AS cor0
----
110
94
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6417
SELECT ( ( col0 ) ) * CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6417
SELECT ( ( col0 ) ) * CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 98 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT DISTINCT + cor0.col2 * + col0 + + col0 - + col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL - 24 + - ( cor0.col0 ) * + col0 FROM tab0 cor0
----
-1249
-600
-7945

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 16 col0 FROM tab1 AS cor0
----
-16
-16
-16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 36 col0 FROM tab0 AS cor0
----
-36
-36
-36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 + 97 * cor0.col2 * col2 col1 FROM tab1 AS cor0
----
282878
315163
893965

query I rowsort
SELECT - + col2 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT col0 + + col0 * - 85 FROM tab0 AS cor0
----
-2016
-2940
-7476

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 + + col2 col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + col1 + - 73 AS col0 FROM tab2 AS cor0
----
-14
-42
-56

onlyif mysql # use DIV operator for integer division
query I rowsort label-6428
SELECT DISTINCT + col0 * ( + ( cor0.col1 ) ) DIV - ( + col1 ) + col1 AS col0 FROM tab0 AS cor0
----
2
62

skipif mysql # not compatible
query I rowsort label-6428
SELECT DISTINCT + col0 * ( + ( cor0.col1 ) ) / - ( + col1 ) + col1 AS col0 FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT + 19 * tab2.col2 * + col0 FROM tab2
----
3591
38532
57038

query I rowsort
SELECT - col1 + col2 + col1 AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT - - col2 * + col0 - col2 AS col2 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT + + col0 - - ( - cor0.col2 ) FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT ALL + + col0 + - ( col0 ) + + col0 * 73 AS col1 FROM tab0 AS cor0
----
1752
2555
6497

query I rowsort
SELECT DISTINCT 28 * - col1 FROM tab1 AS cor0
----
-280
-364
-728

query I rowsort
SELECT cor0.col1 + ( + col1 ) * - col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT DISTINCT - col1 + 19 + col1 AS col0 FROM tab1
----
19

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * tab1.col2 col1 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT col0 * ( - col1 ) * - ( 45 ) + col0 AS col2 FROM tab2 AS cor0
----
207168
60514
9772

query I rowsort
SELECT - + col2 + - 90 * col2 FROM tab1 AS cor0
----
-4914
-5187
-8736

query I rowsort
SELECT + 43 + 81 FROM tab1 AS cor0
----
124
124
124

query I rowsort
SELECT col2 * - col2 - col0 FROM tab0 AS cor0
----
-1113
-36
-6813

query I rowsort
SELECT ALL + col0 * 31 AS col0 FROM tab2
----
217
2418
2449

query I rowsort
SELECT + + col0 * + ( - col2 ) - - col2 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT + col1 * 75 AS col1 FROM tab0 AS cor0
----
6450
6825
7275

query I rowsort
SELECT - 32 + cor0.col0 * + col2 - + col0 FROM tab2 AS cor0
----
150
1918
2891

query I rowsort
SELECT + - col1 * - 28 + col1 FROM tab0 AS cor0
----
2494
2639
2813

onlyif mysql # use DIV operator for integer division
query I rowsort label-6447
SELECT - col2 DIV + 66 AS col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6447
SELECT - col2 / + 66 AS col2 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT ALL + cor1.col2 AS col0 FROM tab1, tab2 AS cor0, tab0, tab1 cor1
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + col1 ) * + col1 col2 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL 48 * + col0 * cor0.col1 AS col2 FROM tab1 AS cor0
----
30720
3744
49920

onlyif mysql # use DIV operator for integer division
query I rowsort label-6451
SELECT ALL - + col1 DIV - col2 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6451
SELECT ALL - + col1 / - col2 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + - col1 + - col0 AS col0 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT + + col1 * ( + col2 ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + col1 * - col1 * col1 AS col2 FROM tab2
----
-205379
-29791
-4913

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6455
SELECT ALL CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6455
SELECT ALL CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + - 37 col2 FROM tab2 AS cor0
----
-10
-11
1

query I rowsort
SELECT ALL - + col1 - + col0 AS col2 FROM tab2 cor0
----
-137
-38
-96

query I rowsort
SELECT ALL col1 * + col2 - 69 * col2 FROM tab0 AS cor0
----
1804
28
561

query I rowsort
SELECT + col2 - col1 * tab2.col0 AS col1 FROM tab2
----
-1305
-190
-4576

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6460
SELECT ALL 31 + - col1 + + CAST( NULL AS SIGNED ) col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6460
SELECT ALL 31 + - col1 + + CAST ( NULL AS INTEGER ) col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 + col0 * 70 * + tab2.col0 FROM tab2
----
3437
425958
436949

onlyif mysql # use DIV operator for integer division
query I rowsort label-6462
SELECT DISTINCT 80 * - col2 + - 58 DIV - col1 FROM tab1
----
-4318
-4555
-7676

skipif mysql # not compatible
query I rowsort label-6462
SELECT DISTINCT 80 * - col2 + - 58 / - col1 FROM tab1
----
-4318
-4555
-7676

onlyif mysql # use DIV operator for integer division
query I rowsort label-6463
SELECT col0 DIV - tab1.col2 + tab1.col0 AS col2 FROM tab1
----
3
63
80

skipif mysql # not compatible
query I rowsort label-6463
SELECT col0 / - tab1.col2 + tab1.col0 AS col2 FROM tab1
----
3
63
80

query I rowsort
SELECT + - col1 * + 48 * cor0.col1 AS col0 FROM tab0 cor0
----
-355008
-397488
-451632

query I rowsort
SELECT DISTINCT col0 * - col2 * ( col2 ) FROM tab2
----
-114076
-5103
-52728

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6466
SELECT ALL - cor0.col1 * + CAST( 24 + col0 * col0 AS SIGNED ) FROM tab2 AS cor0
----
-106505
-2263
-360372

skipif mysql # not compatible
query I rowsort label-6466
SELECT ALL - cor0.col1 * + CAST ( 24 + col0 * col0 AS INTEGER ) FROM tab2 AS cor0
----
-106505
-2263
-360372

query I rowsort
SELECT ALL col2 * - 61 FROM tab0 cor0
----
-2013
-5002
-61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 + - ( 35 ) col0 FROM tab0 AS cor0
----
-124
-59
-70

query I rowsort
SELECT ALL + - col1 + + 91 - col1 FROM tab0 AS cor0
----
-103
-81
-91

query I rowsort
SELECT ALL - col0 + col1 * - 4 FROM tab0 AS cor0
----
-368
-423
-453

query I rowsort
SELECT DISTINCT col1 * - col1 AS col1 FROM tab2 cor0
----
-289
-3481
-961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 col2 FROM tab2 WHERE - col0 * + col2 * - col0 + col2 * col0 > col2 + col0
----
17
31
59

query I rowsort
SELECT ALL - tab1.col1 * col2 AS col1 FROM tab1
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6474
SELECT + col0 DIV + col0 + col0 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-6474
SELECT + col0 / + col0 + col0 FROM tab0
----
25
36
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6475
SELECT ALL - col2 DIV + tab0.col0 AS col0 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6475
SELECT ALL - col2 / + tab0.col0 AS col0 FROM tab0
----
-1
0
0

query I rowsort
SELECT DISTINCT col1 * - tab2.col1 AS col2 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT col2 + + col1 * - col1 FROM tab1
----
-43
-622
-73

query I rowsort
SELECT ALL - col0 * - col1 + tab1.col2 - - col0 AS col1 FROM tab1
----
1216
135
761

query I rowsort
SELECT DISTINCT - col1 / - col0 AS col0 FROM tab1 WHERE NOT NULL <> ( + col0 + col1 + col0 * - col1 )
----

query I rowsort
SELECT ( col2 ) * col0 + 80 + + col1 FROM tab2 cor0
----
2167
300
3099

query I rowsort
SELECT + col1 * col2 + col1 * + tab1.col1 * + col0 FROM tab1 WHERE ( NULL ) = + col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 - col0 * tab1.col2 col0 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT DISTINCT - col0 * + col2 - + col1 AS col0 FROM tab2
----
-2087
-220
-3019

query I rowsort
SELECT - - 76 + + col0 + ( + 9 ) AS col1 FROM tab0 AS cor0
----
109
120
174

query I rowsort
SELECT ALL col0 * col1 + - 75 * col0 FROM tab2 AS cor0
----
-1248
-308
-4582

query I rowsort
SELECT ALL + 55 * col1 + + col0 * cor0.col0 * + col1 AS col0 FROM tab2 AS cor0
----
107032
3224
362201

query I rowsort
SELECT DISTINCT - + 34 AS col0 FROM tab1 cor0 CROSS JOIN tab1 cor1
----
-34

query I rowsort
SELECT + - 82 * col2 * + col0 - col0 FROM tab1 AS cor0
----
-13287
-299200
-629840

query I rowsort
SELECT DISTINCT - col1 * col2 + + 82 * col1 FROM tab1 AS cor0
----
-182
250
728

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6490
SELECT + - col0 / col0 + + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6490
SELECT + - col0 / col0 + + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * cor0.col2 * col1 FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT col2 + + col2 * - col0 * 12 FROM tab1
----
-1890
-43719
-92064

onlyif mysql # use DIV operator for integer division
query I rowsort label-6493
SELECT ALL + 28 DIV + 10 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

skipif mysql # not compatible
query I rowsort label-6493
SELECT ALL + 28 / + 10 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT DISTINCT + ( col1 ) * 31 + + ( - col2 + + col0 ) FROM tab0
----
2657
2828
3041

query I rowsort
SELECT ALL + col1 + col0 * - 82 + + col2 FROM tab2 AS cor0
----
-516
-6311
-6423

query I rowsort
SELECT ALL + - col2 * col0 - col0 FROM tab2 AS cor0
----
-196
-2106
-3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6497
SELECT + 82 * - col2 - CAST( NULL AS SIGNED ) / + col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6497
SELECT + 82 * - col2 - CAST ( NULL AS INTEGER ) / + col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + - col2 + - cor0.col1 FROM tab1 cor0
----
-29
-3
-77

query I rowsort
SELECT DISTINCT col1 * + cor0.col0 * col1 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT ALL - ( col2 ) + 92 FROM tab1 AS cor0
----
-4
35
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-6501
SELECT col0 DIV - col0 + - col2 FROM tab1 AS cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-6501
SELECT col0 / - col0 + - col2 FROM tab1 AS cor0
----
-55
-58
-97

query I rowsort
SELECT + col2 * - 83 + cor0.col0 AS col0 FROM tab0 AS cor0
----
-2715
-48
-6717

query I rowsort
SELECT col2 + col1 + col1 FROM tab1 AS cor0
----
106
122
77

query I rowsort
SELECT + col0 + 77 AS col0 FROM tab0 AS cor0
----
101
112
166

query I rowsort
SELECT DISTINCT - + 69 * - col1 * cor0.col0 FROM tab1 AS cor0
----
44160
5382
71760

query I rowsort
SELECT DISTINCT + - ( - 40 ) * + col0 FROM tab0 AS cor0
----
1400
3560
960

query I rowsort
SELECT col1 + ( col1 ) * + col2 FROM tab1
----
1261
1430
580

query I rowsort
SELECT DISTINCT - 38 * 12 + - col0 FROM tab1 AS cor0
----
-459
-520
-536

query I rowsort
SELECT DISTINCT - col1 * 44 * + col1 + + 67 FROM tab0 AS cor0
----
-325357
-364297
-413929

query I rowsort
SELECT DISTINCT - 86 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab1 cor1, tab2 AS cor2
----
-86

query I rowsort
SELECT col0 * - col2 + col0 * + col2 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6512
SELECT ( + col1 ) DIV + col2 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-6512
SELECT ( + col1 ) / + col2 FROM tab0
----
1
2
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6513
SELECT DISTINCT + CAST( NULL AS SIGNED ) + - 51 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-6513
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + - 51 FROM tab2
----
NULL

query I rowsort
SELECT col1 * - tab0.col2 + + tab0.col1 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT ALL 94 - + col1 AS col1 FROM tab2
----
35
63
77

query I rowsort
SELECT - 81 * + col1 * + col2 + col2 FROM tab1
----
-100992
-113670
-46113

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6517
SELECT DISTINCT ( + col1 ) * col1 + CAST( NULL AS SIGNED ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-6517
SELECT DISTINCT ( + col1 ) * col1 + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6518
SELECT DISTINCT col1 DIV + col0 + - col2 FROM tab2
----
-23
-26
-38

skipif mysql # not compatible
query I rowsort label-6518
SELECT DISTINCT col1 / + col0 + - col2 FROM tab2
----
-23
-26
-38

query I rowsort
SELECT ALL + - 99 * + col0 FROM tab1 AS cor0
----
-297
-6336
-7920

onlyif mysql # use DIV operator for integer division
query I rowsort label-6520
SELECT + ( + col1 ) DIV col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6520
SELECT + ( + col1 ) / col1 FROM tab1
----
1
1
1

query I rowsort
SELECT - cor1.col2 AS col2 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT - col2 + col0 * col2 + - col1 FROM tab0
----
-63
673
7125

query I rowsort
SELECT DISTINCT - 6 + + col2 * col0 + tab1.col0 AS col0 FROM tab1
----
159
3706
7754

query I rowsort
SELECT ALL 44 * col0 * col1 + + col0 + col2 AS col2 FROM tab0
----
149416
356527
90873

query I rowsort
SELECT 7 * col2 + - col0 * col1 AS col2 FROM tab0 AS cor0
----
-1833
-3388
-7525

query I rowsort
SELECT + - col2 + cor0.col0 * + cor0.col1 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT - col2 + cor0.col1 * + col0 AS col2 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT col2 * - col1 + + col1 * + col0 FROM tab0 AS cor0
----
-774
3298
637

query I rowsort
SELECT DISTINCT + 98 AS col0 FROM tab2 cor0
----
98

query I rowsort
SELECT DISTINCT - 62 * col1 * + col2 FROM tab2
----
-40052
-51894
-95108

query I rowsort
SELECT ALL 99 * tab1.col1 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 6f145882e7bb0bbb2b1665f06415703e

query I rowsort
SELECT ( - 80 ) AS col0 FROM tab2
----
-80
-80
-80

query I rowsort
SELECT DISTINCT + - col2 + - ( - col2 ) FROM tab1 cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 76 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

query I rowsort
SELECT DISTINCT 27 + - 26 FROM tab2 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * col0 + cor0.col2 col1 FROM tab0 cor0
----
2097
3396
8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-6537
SELECT - - 46 + cor0.col2 DIV col0 - - col2 AS col1 FROM tab2 AS cor0
----
72
76
84

skipif mysql # not compatible
query I rowsort label-6537
SELECT - - 46 + cor0.col2 / col0 - - col2 AS col1 FROM tab2 AS cor0
----
72
76
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-6538
SELECT + 70 DIV + col1 + col1 col1 FROM tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6538
SELECT + 70 / + col1 + col1 col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - - col1 * + col0 + col0 - - col2 FROM tab2 AS cor0
----
1460
251
4706

query I rowsort
SELECT DISTINCT col0 + - tab0.col2 AS col0 FROM tab0
----
-9
34
7

query I rowsort
SELECT ALL col2 * - col2 + col2 FROM tab0
----
-1056
-6642
0

query I rowsort
SELECT DISTINCT col2 FROM tab2 WHERE NOT ( col1 ) < NULL
----

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NULL >= col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6544
SELECT ALL col0 * col0 + col0 DIV + col1 AS col1 FROM tab2
----
49
6085
6245

skipif mysql # not compatible
query I rowsort label-6544
SELECT ALL col0 * col0 + col0 / + col1 AS col1 FROM tab2
----
49
6085
6245

query I rowsort
SELECT col1 * + col0 - + col0 FROM tab1
----
576
75
960

query I rowsort
SELECT + col0 * - tab1.col2 * col2 FROM tab1
----
-207936
-737280
-8748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col0 + - tab1.col2 col0 FROM tab1
----
108
3591
7584

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col1 col0 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6549
SELECT col1 DIV col1 + col0 + col2 AS col0 FROM tab0
----
172
37
58

skipif mysql # not compatible
query I rowsort label-6549
SELECT col1 / col1 + col0 + col2 AS col0 FROM tab0
----
172
37
58

query I rowsort
SELECT DISTINCT col2 + + col2 AS col2 FROM tab0 WHERE NOT NULL IN ( col1 * - col0 )
----

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL <> + col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - col0 col1 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT col0 + + col2 * + cor0.col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL - + col0 - - cor0.col1 AS col2 FROM tab1 AS cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col2 col1 FROM tab0 cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * tab1.col1 + + tab1.col2 col0 FROM tab1 WHERE col0 + col0 * + col0 * + col1 - + col2 IN ( + tab1.col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6557
SELECT + + col0 DIV - col1 + + col0 FROM tab1 AS cor0
----
3
58
74

skipif mysql # not compatible
query I rowsort label-6557
SELECT + + col0 / - col1 + + col0 FROM tab1 AS cor0
----
3
58
74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6558
SELECT DISTINCT + ( + col0 ) * col2 + + CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6558
SELECT DISTINCT + ( + col0 ) * col2 + + CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL

query I rowsort
SELECT ALL - + col2 * col2 + - col0 * col0 FROM tab0 AS cor0
----
-1226
-14645
-1665

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col0 + + col0 * + col1 * - 12 col1 FROM tab0 AS cor0
----
-22704
-37345
-89089

query I rowsort
SELECT DISTINCT + ( - ( cor0.col2 ) ) * col1 - 56 * cor0.col2 AS col2 FROM tab0 AS cor0
----
-12054
-153
-4686

query I rowsort
SELECT ALL - 68 * col0 AS col2 FROM tab0 AS cor0
----
-1632
-2380
-6052

query I rowsort
SELECT - 15 + 96 AS col1 FROM tab0 AS cor0
----
81
81
81

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + CAST ( - col1 AS REAL ) * + col0 + + 5 FROM tab1 cor0
----
1045
645
83

query I rowsort
SELECT DISTINCT - 73 + + col0 FROM tab0 cor0
----
-38
-49
16

query I rowsort
SELECT - tab0.col0 - ( - col0 ) FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - col1 + 91 - col1 AS col2 FROM tab0
----
-103
-81
-91

query I rowsort
SELECT ALL - - 72 AS col2 FROM tab2 AS cor0
----
72
72
72

query I rowsort
SELECT ALL + col0 * + 17 * + 80 FROM tab1
----
108800
4080
87040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 26 col2 FROM tab1 AS cor0
----
26
26
26

query I rowsort
SELECT DISTINCT + ( col2 ) + col1 AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - 45 + col2 FROM tab0 cor0
----
-12
-44
37

query I rowsort
SELECT - + ( - 7 ) * col0 FROM tab0 AS cor0
----
168
245
623

query I rowsort
SELECT + cor1.col2 + - 81 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 17102fb1a99548ecd87ad6b39a109a02

onlyif mysql # use DIV operator for integer division
query I rowsort label-6575
SELECT DISTINCT 94 DIV + col2 FROM tab0
----
1
2
94

skipif mysql # not compatible
query I rowsort label-6575
SELECT DISTINCT 94 / + col2 FROM tab0
----
1
2
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 + col1 * + col2 col0 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT - col0 + - 73 FROM tab0 AS cor0
----
-108
-162
-97

skipif mysql # not compatible
query I rowsort
SELECT 91 + - col2 * - CAST ( - col2 AS REAL ) AS col0 FROM tab2
----
-1353
-585
-638

query I rowsort
SELECT DISTINCT col2 * col2 + 66 + - tab1.col1 FROM tab1
----
2956
3305
9269

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6580
SELECT col2 + - CAST( + col0 AS SIGNED ) * - col1 * tab2.col2 + - col2 * - col1 FROM tab2
----
121212
51718
6723

skipif mysql # not compatible
query I rowsort label-6580
SELECT col2 + - CAST ( + col0 AS INTEGER ) * - col1 * tab2.col2 + - col2 * - col1 FROM tab2
----
121212
51718
6723

query I rowsort
SELECT col1 * col1 - 69 * - col0 * + col2 FROM tab0
----
11824
511843
62044

onlyif mysql # use DIV operator for integer division
query I rowsort label-6582
SELECT col1 * col0 + 0 + - col2 DIV - col0 FROM tab1 AS cor0
----
1041
640
96

skipif mysql # not compatible
query I rowsort label-6582
SELECT col1 * col0 + 0 + - col2 / - col0 FROM tab1 AS cor0
----
1041
640
96

query I rowsort
SELECT - col0 + - 72 + + col1 FROM tab1 AS cor0
----
-126
-139
-49

query I rowsort
SELECT DISTINCT + - col2 * col2 - - ( + col2 ) * col0 AS col1 FROM tab0 AS cor0
----
-297
34
574

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6585
SELECT ALL - col2 + - CAST( col2 AS SIGNED ) FROM tab1
----
-108
-114
-192

skipif mysql # not compatible
query I rowsort label-6585
SELECT ALL - col2 + - CAST ( col2 AS INTEGER ) FROM tab1
----
-108
-114
-192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col1 - col2 * col1 col0 FROM tab2
----
-1416
-612
-775

query I rowsort
SELECT DISTINCT + + col0 + ( - col0 ) FROM tab1 cor0
----
0

query I rowsort
SELECT DISTINCT + + cor0.col1 + + cor0.col2 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT DISTINCT + col2 + col1 + + 26 * + col0 * cor0.col1 AS col0 FROM tab2 AS cor0
----
119737
34973
5700

query I rowsort
SELECT ALL - + 27 * col0 * + col2 AS col1 FROM tab0 AS cor0
----
-197046
-21384
-945

query I rowsort
SELECT DISTINCT + ( + col0 ) * + col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT 30 * + col2 FROM tab1 AS cor0
----
1620
1710
2880

query I rowsort
SELECT ALL ( - 86 ) * + col0 FROM tab2 AS cor0
----
-602
-6708
-6794

onlyif mysql # use DIV operator for integer division
query I rowsort label-6594
SELECT ALL - - 56 DIV - col1 AS col2 FROM tab1 AS cor0
----
-2
-4
-5

skipif mysql # not compatible
query I rowsort label-6594
SELECT ALL - - 56 / - col1 AS col2 FROM tab1 AS cor0
----
-2
-4
-5

query I rowsort
SELECT tab2.col1 + + col0 + ( + col2 ) FROM tab2
----
134
163
65

query I rowsort
SELECT - - col2 * + col2 + col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT ALL - col2 * - 64 * - col2 + - 58 AS col2 FROM tab2 AS cor0
----
-43322
-46714
-92474

query I rowsort
SELECT ALL 44 + - col2 AS col0 FROM tab1 cor0
----
-10
-13
-52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor1.col2 col1 FROM tab0, tab1 cor0, tab2 AS cor1
----
26
27
38

query I rowsort
SELECT DISTINCT 24 AS col2 FROM tab2
----
24

query I rowsort
SELECT DISTINCT - col0 + col2 * col2 * + col2 AS col1 FROM tab1 AS cor0
----
157461
185129
884656

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 23 * - cor0.col1 col2 FROM tab0 AS cor0
----
-1978
-2093
-2231

onlyif mysql # use DIV operator for integer division
query I rowsort label-6603
SELECT - cor0.col1 + + col2 DIV - 43 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-6603
SELECT - cor0.col1 + + col2 / - 43 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL + col1 + + 36 AS col2 FROM tab1 AS cor0
----
46
49
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - cor0.col1 * - 11 * - cor0.col0 col1 FROM tab0 AS cor0
----
-22671
-37344
-89007

skipif mysql # not compatible
query I rowsort
SELECT + - col0 / - CAST ( col0 AS REAL ) FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT ALL + - cor0.col1 + + 46 * - 64 AS col0 FROM tab1 AS cor0
----
-2954
-2957
-2970

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6608
SELECT - + col0 * + CAST( NULL AS SIGNED ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6608
SELECT - + col0 * + CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6609
SELECT ALL - col0 + col0 DIV - col1 AS col2 FROM tab1 AS cor0
----
-3
-70
-86

skipif mysql # not compatible
query I rowsort label-6609
SELECT ALL - col0 + col0 / - col1 AS col2 FROM tab1 AS cor0
----
-3
-70
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 66 col0 FROM tab2
----
66
66
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-6611
SELECT - col0 DIV col1 + - col1 AS col0 FROM tab1
----
-16
-19
-26

skipif mysql # not compatible
query I rowsort label-6611
SELECT - col0 / col1 + - col1 AS col0 FROM tab1
----
-16
-19
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 19 col2 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 0fbbff28a7b63c37b01cf369f9325662

onlyif mysql # use DIV operator for integer division
query I rowsort label-6613
SELECT ALL + 34 DIV 98 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6613
SELECT ALL + 34 / 98 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL cor0.col0 AS col1 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT col1 + col0 * 97 + - col0 AS col1 FROM tab1
----
314
6154
7693

query I rowsort
SELECT - ( + col2 ) * + col2 * col1 + col0 + col0 * + col0 FROM tab0 AS cor0
----
-603874
-93054
1163

query I rowsort
SELECT DISTINCT + tab1.col1 * + 46 FROM tab1
----
1196
460
598

query I rowsort
SELECT ALL - cor0.col0 * col2 + cor0.col1 * col1 + ( cor0.col0 + col1 ) AS col2 FROM tab1 AS cor0
----
-3474
-7418
543

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6619
SELECT ALL + col0 * - 67 + col0 * col0 * CAST( NULL AS SIGNED ) + + col2 * + col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6619
SELECT ALL + col0 * - 67 + col0 * col0 * CAST ( NULL AS INTEGER ) + + col2 * + col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col2 * + ( - 4 ) + - col2 AS col0 FROM tab2 AS cor0
----
-130
-135
-190

query I rowsort
SELECT DISTINCT 37 + + ( - cor0.col2 ) * + 63 AS col0 FROM tab1 AS cor0
----
-3365
-3554
-6011

query I rowsort
SELECT - ( - col0 ) + + cor0.col1 * + col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT col2 + - 92 * col1 FROM tab0 AS cor0
----
-7879
-8290
-8923

query I rowsort
SELECT DISTINCT + 63 * - 38 * - col0 AS col0 FROM tab2 AS cor0
----
16758
186732
189126

onlyif mysql # use DIV operator for integer division
query I rowsort label-6625
SELECT ALL - - 20 DIV col0 col2 FROM tab1 cor0
----
0
0
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6625
SELECT ALL - - 20 / col0 col2 FROM tab1 cor0
----
0
0
6

query I rowsort
SELECT + - cor0.col1 * cor0.col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + col2 * 89 FROM tab2 AS cor0
----
2314
2403
3382

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6628
SELECT CAST( NULL AS SIGNED ) * - col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6628
SELECT CAST ( NULL AS INTEGER ) * - col1 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6629
SELECT CAST( + col0 AS SIGNED ) * col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-6629
SELECT CAST ( + col0 AS INTEGER ) * col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + 95 + + cor0.col1 FROM tab1 AS cor0
----
105
108
121

query I rowsort
SELECT - col1 + + col0 * - col2 FROM tab0 AS cor0
----
-132
-7389
-878

onlyif mysql # use DIV operator for integer division
query I rowsort label-6632
SELECT ALL + col2 DIV + 51 + col2 AS col1 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-6632
SELECT ALL + col2 / + 51 + col2 AS col1 FROM tab1
----
55
58
97

query I rowsort
SELECT DISTINCT 70 * - col0 AS col1 FROM tab2
----
-490
-5460
-5530

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6634
SELECT ALL + CAST( 18 AS SIGNED ) FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 903ac227935c1532300db45a8537c595

skipif mysql # not compatible
query I rowsort label-6634
SELECT ALL + CAST ( 18 AS INTEGER ) FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 903ac227935c1532300db45a8537c595

query I rowsort
SELECT DISTINCT ( - 5 ) * - col0 FROM tab0
----
120
175
445

onlyif mysql # use DIV operator for integer division
query I rowsort label-6636
SELECT 17 DIV col2 + col2 + + cor0.col1 * + col0 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-13424
-1974
-6343

skipif mysql # not compatible
query I rowsort label-6636
SELECT 17 / col2 + col2 + + cor0.col1 * + col0 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-13424
-1974
-6343

query I rowsort
SELECT + ( - col2 ) * 58 FROM tab2 AS cor0
----
-1508
-1566
-2204

onlyif mysql # use DIV operator for integer division
query I rowsort label-6638
SELECT - col2 * col1 DIV + col0 AS col0 FROM tab1 AS cor0
----
-15
-468
-8

skipif mysql # not compatible
query I rowsort label-6638
SELECT - col2 * col1 / + col0 AS col0 FROM tab1 AS cor0
----
-15
-468
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 12 + + col0 * cor0.col1 col0 FROM tab2 AS cor0
----
1331
205
4590

query I rowsort
SELECT ALL + - col0 * - cor0.col1 + 70 FROM tab2 AS cor0
----
1413
287
4672

query I rowsort
SELECT DISTINCT + col1 * col2 + ( + col0 ) FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT + ( col1 ) + + ( + col1 ) * col2 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT - col1 * 52 AS col0 FROM tab2 AS cor0
----
-1612
-3068
-884

query I rowsort
SELECT - + col1 - ( - 3 ) * - col1 AS col1 FROM tab0 AS cor0
----
-344
-364
-388

query I rowsort
SELECT + col1 + cor0.col0 * + 93 * + col1 FROM tab1 AS cor0
----
59530
7280
96733

query I rowsort
SELECT - cor0.col1 * col1 + col0 AS col1 FROM tab0 cor0
----
-7372
-8192
-9374

query I rowsort
SELECT - col2 * + col0 + - col0 * + col2 FROM tab0 AS cor0
----
-14596
-1584
-70

query I rowsort
SELECT DISTINCT + ( col0 ) + + col0 AS col2 FROM tab1
----
128
160
6

query I rowsort
SELECT - col0 + col1 * col0 AS col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT ALL - + 48 * + col2 FROM tab2 AS cor0
----
-1248
-1296
-1824

query I rowsort
SELECT DISTINCT - - 92 AS col1 FROM tab2, tab1, tab2 AS cor0
----
92

query I rowsort
SELECT 96 * col0 AS col1 FROM tab2
----
672
7488
7584

query I rowsort
SELECT + col2 * + tab1.col1 AS col2 FROM tab1
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6654
SELECT ALL - - col0 * + col0 * CAST( col2 AS SIGNED ) + col2 col1 FROM tab0 AS cor0
----
1226
19041
649604

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6654
SELECT ALL - - col0 * + col0 * CAST ( col2 AS INTEGER ) + col2 col1 FROM tab0 AS cor0
----
1226
19041
649604

query I rowsort
SELECT + 84 * col2 + + col2 * 90 FROM tab2 AS cor0
----
4524
4698
6612

query I rowsort
SELECT + 68 * 82 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to f453cdc022d3e666c37b6eabb78d1cba

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6657
SELECT + col1 + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6657
SELECT + col1 + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * - 49 + col1 FROM tab2 AS cor0
----
-1488
-2832
-816

query I rowsort
SELECT + col0 + + 10 * col1 * col2 AS col1 FROM tab0 AS cor0
----
1005
28404
74709

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6660
SELECT col2 * CAST( NULL AS SIGNED ) + + 63 * col0 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6660
SELECT col2 * CAST ( NULL AS INTEGER ) + + 63 * col0 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor0.col1 * 6 FROM tab0 AS cor0
----
516
546
582

query I rowsort
SELECT - col1 * - ( + ( col1 ) * + col1 + col1 ) FROM tab0 AS cor0
----
643452
761852
922082

onlyif mysql # use DIV operator for integer division
query I rowsort label-6663
SELECT + col1 DIV col2 + - col0 * col1 FROM tab0 AS cor0
----
-2062
-3298
-8098

skipif mysql # not compatible
query I rowsort label-6663
SELECT + col1 / col2 + - col0 * col1 FROM tab0 AS cor0
----
-2062
-3298
-8098

query I rowsort
SELECT - col0 + tab0.col0 - tab0.col2 * col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + col1 * - col1 + 2 + + col2 FROM tab2
----
-249
-3453
-932

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col2 col0 FROM tab1, tab0 cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6667
SELECT ALL - CAST( + 99 AS SIGNED ) + col1 FROM tab1 cor0
----
-73
-86
-89

skipif mysql # not compatible
query I rowsort label-6667
SELECT ALL - CAST ( + 99 AS INTEGER ) + col1 FROM tab1 cor0
----
-73
-86
-89

query I rowsort
SELECT DISTINCT + col1 + ( + col0 ) + + col1 FROM tab2 AS cor0
----
113
196
69

query I rowsort
SELECT DISTINCT + cor0.col0 + ( - col0 ) * 13 * col0 AS col1 FROM tab2 AS cor0
----
-630
-79014
-81054

query I rowsort
SELECT DISTINCT ( col1 ) + col0 AS col2 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT 40 * col0 + - col0 AS col0 FROM tab0 AS cor0
----
1365
3471
936

query I rowsort
SELECT 60 + cor0.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 43c6fb86fa0e2eb4c1503adba165a543

query I rowsort
SELECT ALL tab0.col0 * 21 FROM tab0
----
1869
504
735

query I rowsort
SELECT DISTINCT tab1.col1 - - tab1.col2 FROM tab1, tab1 cor0, tab2 AS cor1
----
109
67
80

query I rowsort
SELECT DISTINCT - cor0.col1 + col0 * + col2 FROM tab2 AS cor0
----
158
1969
2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 45 * - col2 col0 FROM tab1 AS cor0
----
-2430
-2565
-4320

query I rowsort
SELECT ALL + 77 - ( - col1 ) FROM tab1 AS cor0
----
103
87
90

query I rowsort
SELECT DISTINCT ( - 20 ) * + col2 * 52 FROM tab1 AS cor0
----
-56160
-59280
-99840

query I rowsort
SELECT ALL - ( - col2 ) * + col1 + + 83 + + cor0.col1 FROM tab1 AS cor0
----
1344
1513
663

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 66 col1 FROM tab1, tab1 AS cor0, tab2, tab2 AS cor1
----
81 values hashing to dc112f70fecc29a6e605a39541192f43

query I rowsort
SELECT ALL + 89 * - cor0.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to d8e40f1ab07fa8f54a72b1dfc2909de7

query I rowsort
SELECT col2 + tab2.col1 * - col2 FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT + 43 * col0 AS col0 FROM tab1 AS cor0
----
129
2752
3440

query I rowsort
SELECT ALL + ( 77 ) FROM tab1
----
77
77
77

query I rowsort
SELECT 17 - - 47 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6686
SELECT ALL CAST( NULL AS DECIMAL ) * - 48 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6686
SELECT ALL CAST ( NULL AS REAL ) * - 48 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col2 AS col1 FROM tab1, tab1 AS cor0, tab2, tab0 AS cor1
----
81 values hashing to 2df272448a67587d4635afedff278dcc

query I rowsort
SELECT ALL + ( col0 * 81 ) AS col0 FROM tab2
----
567
6318
6399

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + col2 ) + + col0 col2 FROM tab1 AS cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 28 col2 FROM tab1 AS cor0
----
28
28
28

query I rowsort
SELECT DISTINCT + + ( col1 ) * + 77 FROM tab1 AS cor0
----
1001
2002
770

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab2 AS cor2, tab2 AS cor3
----
3645 values hashing to c670882ff9ea3f0bb08fc55ec569be96

query I rowsort
SELECT DISTINCT + - col1 + ( col2 ) * + col2 AS col1 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT DISTINCT col0 + + col1 * ( col0 ) FROM tab1 AS cor0
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * - 24 - 97 col0 FROM tab1 cor0
----
-337
-409
-721

onlyif mysql # use DIV operator for integer division
query I rowsort label-6696
SELECT DISTINCT - col0 * + col1 + col0 DIV - cor0.col1 FROM tab0 cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-6696
SELECT DISTINCT - col0 * + col1 + col0 / - cor0.col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - col0 * - 55 * + 50 AS col1 FROM tab1
----
176000
220000
8250

onlyif mysql # use DIV operator for integer division
query I rowsort label-6698
SELECT DISTINCT + - ( col1 ) DIV cor0.col0 - col0 * - col0 * - col2 AS col1 FROM tab0 AS cor0
----
-1227
-19011
-649523

skipif mysql # not compatible
query I rowsort label-6698
SELECT DISTINCT + - ( col1 ) / cor0.col0 - col0 * - col0 * - col2 AS col1 FROM tab0 AS cor0
----
-1227
-19011
-649523

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6699
SELECT + 33 * col2 + + col2 * CAST( NULL AS SIGNED ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6699
SELECT + 33 * col2 + + col2 * CAST ( NULL AS INTEGER ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - 94 * col1 FROM tab2 AS cor0
----
-1598
-2914
-5546

query I rowsort
SELECT + - col1 * + 11 AS col2 FROM tab1 AS cor0
----
-110
-143
-286

query I rowsort
SELECT + col2 * col1 + col0 AS col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT 95 * + 46 * col0 AS col0 FROM tab1 cor0
----
13110
279680
349600

query I rowsort
SELECT + cor0.col0 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL + + 61 + ( col1 ) AS col1 FROM tab0 cor0
----
147
152
158

query I rowsort
SELECT col1 * - ( + 86 ) FROM tab0 AS cor0
----
-7396
-7826
-8342

query I rowsort
SELECT + col0 + + 92 * - col1 FROM tab2 AS cor0
----
-1485
-2845
-5350

query I rowsort
SELECT col0 + ( 53 ) FROM tab0 AS cor0
----
142
77
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * - 79 + ( col1 ) col1 FROM tab2 AS cor0
----
584
6221
6258

onlyif mysql # use DIV operator for integer division
query I rowsort label-6710
SELECT + + col2 + 9 DIV + col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6710
SELECT + + col2 + 9 / + col0 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6711
SELECT DISTINCT - CAST( cor0.col2 AS SIGNED ) DIV + cor0.col2 col2 FROM tab0 AS cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6711
SELECT DISTINCT - CAST ( cor0.col2 AS INTEGER ) / + cor0.col2 col2 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT ( + 22 ) * col2 FROM tab2 AS cor0
----
572
594
836

query I rowsort
SELECT DISTINCT - ( + 9 ) AS col1 FROM tab1 AS cor0
----
-9

query I rowsort
SELECT ALL 26 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

query I rowsort
SELECT ALL 23 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 32 col1 FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 6bef041528d0147be26f7de162c66a5f

query I rowsort
SELECT DISTINCT - 98 FROM tab1, tab0 cor0
----
-98

query I rowsort
SELECT DISTINCT 16 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
16

query I rowsort
SELECT - col2 * col0 + col1 * cor0.col1 AS col0 FROM tab1 AS cor0
----
-3548
-7511
514

query I rowsort
SELECT + 87 + col0 * col1 AS col1 FROM tab1 AS cor0
----
1127
165
727

query I rowsort
SELECT + - col0 + - cor0.col2 * - col1 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT ALL 6 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * + col1 + col1 col0 FROM tab2 AS cor0
----
306
3540
992

onlyif mysql # use DIV operator for integer division
query I rowsort label-6724
SELECT DISTINCT + + col1 * + col1 + 74 DIV 83 FROM tab1 cor0
----
100
169
676

skipif mysql # not compatible
query I rowsort label-6724
SELECT DISTINCT + + col1 * + col1 + 74 / 83 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT ALL cor0.col2 - - col1 AS col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT - 99 FROM tab0, tab1, tab0 cor0
----
27 values hashing to 761f5f1a166a00db99360141565a85da

query I rowsort
SELECT + tab2.col0 * col2 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT ALL + col1 * col2 * 54 FROM tab2 AS cor0
----
34884
45198
82836

query I rowsort
SELECT cor0.col0 + 58 FROM tab1 AS cor0
----
122
138
61

query I rowsort
SELECT DISTINCT - col0 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-171
-36
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6731
SELECT ALL + - col0 * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6731
SELECT ALL + - col0 * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 13 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

onlyif mysql # use DIV operator for integer division
query I rowsort label-6733
SELECT DISTINCT col2 DIV + col2 + col1 AS col1 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-6733
SELECT DISTINCT col2 / + col2 + col1 AS col1 FROM tab0
----
87
92
98

query I rowsort
SELECT DISTINCT - col1 + + ( col0 ) * col0 AS col0 FROM tab2
----
18
6025
6224

query I rowsort
SELECT - col0 + - 82 FROM tab0 AS cor0
----
-106
-117
-171

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 95 col1 FROM tab0 AS cor0
----
-95
-95
-95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6737
SELECT CAST( NULL AS DECIMAL ) FROM tab1, tab2, tab2 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6737
SELECT CAST ( NULL AS REAL ) FROM tab1, tab2, tab2 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + 46 - col1 * + col1 FROM tab0
----
-7350
-8235
-9363

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( col2 ) * + col1 + - ( col0 + col0 ) col1 FROM tab2 cor0
----
1378
488
823

query I rowsort
SELECT ALL - 40 + col0 FROM tab0 AS cor0
----
-16
-5
49

query I rowsort
SELECT DISTINCT - 35 * - col1 FROM tab0 cor0
----
3010
3185
3395

query I rowsort
SELECT + col1 * cor0.col1 + col0 - col1 FROM tab1 cor0
----
154
236
653

query I rowsort
SELECT DISTINCT + 37 * + col2 AS col0 FROM tab1 AS cor0
----
1998
2109
3552

query I rowsort
SELECT ALL - col0 * ( 98 ) AS col2 FROM tab2 AS cor0
----
-686
-7644
-7742

query I rowsort
SELECT ALL col0 * col2 + col0 * - col1 FROM tab0 AS cor0
----
-1272
-3360
-801

query I rowsort
SELECT ALL 87 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT ALL + col1 * + ( col2 ) FROM tab2
----
1534
646
837

query I rowsort
SELECT ALL - ( - col1 ) + col2 AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ( + col0 ) * col1 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT 75 * + cor0.col0 + col0 * 41 FROM tab2 cor0
----
812
9048
9164

query I rowsort
SELECT DISTINCT 99 + col2 * - col2 * col0 AS col1 FROM tab2 AS cor0
----
-113977
-5004
-52629

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6752
SELECT + + CAST( - ( col1 ) AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-6752
SELECT + + CAST ( - ( col1 ) AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - - ( - col1 ) * + col0 * + col2 AS col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-6754
SELECT DISTINCT cor0.col2 DIV col1 + col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6754
SELECT DISTINCT cor0.col2 / col1 + col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL - ( 5 ) * + cor0.col2 AS col0 FROM tab2 AS cor0
----
-130
-135
-190

query I rowsort
SELECT ALL - - 83 + - cor0.col1 AS col2 FROM tab0 cor0
----
-14
-3
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6757
SELECT ALL - + CAST( cor0.col0 AS SIGNED ) FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-6757
SELECT ALL - + CAST ( cor0.col0 AS INTEGER ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT 91 + 45 * col2 FROM tab1 AS cor0
----
2521
2656
4411

onlyif mysql # use DIV operator for integer division
query I rowsort label-6759
SELECT + + ( col2 ) DIV cor0.col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6759
SELECT + + ( col2 ) / cor0.col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT 51 * col0 + col1 FROM tab0 AS cor0
----
1310
1882
4630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6761
SELECT - CAST( col2 AS SIGNED ) col1 FROM tab2 cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6761
SELECT - CAST ( col2 AS INTEGER ) col1 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + 89 + + col2 * cor0.col0 FROM tab0 AS cor0
----
124
7387
881

onlyif mysql # use DIV operator for integer division
query I rowsort label-6763
SELECT + col1 DIV 81 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6763
SELECT + col1 / 81 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL + ( - col0 ) * col0 * + 89 FROM tab2 AS cor0
----
-4361
-541476
-555449

query I rowsort
SELECT - 91 + col2 FROM tab1 AS cor0
----
-34
-37
5

query I rowsort
SELECT ALL + 8 + col1 + 60 FROM tab2
----
127
85
99

query I rowsort
SELECT DISTINCT col0 + col0 + col1 AS col1 FROM tab0 AS cor0
----
134
167
269

query I rowsort
SELECT + col2 + + cor0.col1 * + col0 AS col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL - - cor0.col1 * - col0 + 12 FROM tab1 AS cor0
----
-1028
-628
-66

query I rowsort
SELECT - + cor0.col0 + + col2 * col0 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT ALL + col2 - - cor0.col0 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT col1 * + col1 * 69 + - 86 AS col2 FROM tab1 AS cor0
----
11575
46558
6814

query I rowsort
SELECT ALL col0 + col1 * + ( col1 ) AS col2 FROM tab2 AS cor0
----
3559
368
968

onlyif mysql # use DIV operator for integer division
query I rowsort label-6774
SELECT DISTINCT ( col1 ) + + col1 DIV + 96 AS col0 FROM tab0 AS cor0
----
86
91
98

skipif mysql # not compatible
query I rowsort label-6774
SELECT DISTINCT ( col1 ) + + col1 / + 96 AS col0 FROM tab0 AS cor0
----
86
91
98

query I rowsort
SELECT DISTINCT col2 * - col0 + + 87 FROM tab1 AS cor0
----
-3561
-75
-7593

onlyif mysql # use DIV operator for integer division
query I rowsort label-6776
SELECT DISTINCT + - col1 DIV 84 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6776
SELECT DISTINCT + - col1 / 84 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6777
SELECT + col2 DIV + ( col1 * - cor0.col0 + - 99 ) AS col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6777
SELECT + col2 / + ( col1 * - cor0.col0 + - 99 ) AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 53 AS col1 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 866ae1b4ab9e5b4043ac1bcfd413aaa6

query I rowsort
SELECT + col0 + col2 * - col1 * - col2 AS col1 FROM tab2
----
22606
24627
39962

query I rowsort
SELECT ALL 85 + - col1 * - col2 AS col0 FROM tab2
----
1619
731
922

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col0 col0 FROM tab1, tab0 cor0, tab2, tab0 AS cor1
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

query I rowsort
SELECT DISTINCT - - col0 * ( - col0 ) * - col0 + col0 AS col2 FROM tab1 AS cor0
----
262208
30
512080

query I rowsort
SELECT col0 * ( - col1 ) FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6784
SELECT col0 + + CAST( - col1 AS SIGNED ) * col2 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

skipif mysql # not compatible
query I rowsort label-6784
SELECT col0 + + CAST ( - col1 AS INTEGER ) * col2 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6785
SELECT DISTINCT - col1 + CAST( NULL AS SIGNED ) / col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6785
SELECT DISTINCT - col1 + CAST ( NULL AS INTEGER ) / col2 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - 49 col0 FROM tab0 AS cor0
----
-16
-48
33

query I rowsort
SELECT ALL + cor0.col2 + cor0.col0 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + col0 + ( col0 ) AS col1 FROM tab1 AS cor0
----
128
160
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-6789
SELECT col0 * 31 + ( col1 ) DIV col0 AS col2 FROM tab0 AS cor0
----
1087
2760
747

skipif mysql # not compatible
query I rowsort label-6789
SELECT col0 * 31 + ( col1 ) / col0 AS col2 FROM tab0 AS cor0
----
1087
2760
747

query I rowsort
SELECT ALL - cor0.col2 + 99 AS col1 FROM tab2 AS cor0
----
61
72
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6791
SELECT col1 * - CAST( NULL AS SIGNED ) * 55 + + cor0.col0 * + col1 / col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6791
SELECT col1 * - CAST ( NULL AS INTEGER ) * 55 + + cor0.col0 * + col1 / col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor0.col2 AS col0 FROM tab0, tab2 cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-6793
SELECT + col0 DIV cor0.col1 + col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6793
SELECT + col0 / cor0.col1 + col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL col0 * + 82 AS col2 FROM tab1
----
246
5248
6560

query I rowsort
SELECT ALL + 84 + - tab0.col2 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 53ccb09d58ae97921962c60deb66eaac

onlyif mysql # use DIV operator for integer division
query I rowsort label-6796
SELECT 92 * + col2 + 63 DIV col1 AS col0 FROM tab0 AS cor0
----
3036
7544
92

skipif mysql # not compatible
query I rowsort label-6796
SELECT 92 * + col2 + 63 / col1 AS col0 FROM tab0 AS cor0
----
3036
7544
92

query I rowsort
SELECT DISTINCT + 42 + - cor0.col2 * - ( cor0.col1 ) FROM tab2 AS cor0
----
1576
688
879

query I rowsort
SELECT DISTINCT col0 * + col1 * cor0.col2 + 66 FROM tab0 AS cor0
----
3461
664184
68178

query I rowsort
SELECT 61 + + col1 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
161
230
737

query I rowsort
SELECT ALL - 5 + col1 - 37 AS col1 FROM tab1 cor0
----
-16
-29
-32

query I rowsort
SELECT ALL col1 + - col2 * col0 AS col0 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT ALL - col2 * col2 - - col1 * col2 FROM tab2
----
-798
108
858

query I rowsort
SELECT ALL + ( col0 ) + - col0 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL col2 * + col0 + 2 AS col2 FROM tab1
----
164
3650
7682

query I rowsort
SELECT col1 * col0 * - 37 + col1 AS col0 FROM tab0
----
-125518
-299572
-76282

query I rowsort
SELECT DISTINCT 93 + col0 FROM tab0
----
117
128
182

query I rowsort
SELECT DISTINCT + - 15 * - col0 AS col2 FROM tab1 AS cor0
----
1200
45
960

query I rowsort
SELECT + col1 * col2 + ( + col0 ) * + col0 AS col2 FROM tab0 AS cor0
----
1322
15383
3414

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 39 + - col0 col2 FROM tab0 AS cor0
----
-50
15
4

query I rowsort
SELECT DISTINCT + + ( cor0.col2 ) + + col2 AS col1 FROM tab1 AS cor0
----
108
114
192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 76 col0 FROM tab1
----
-76
-76
-76

query I rowsort
SELECT + 35 AS col0 FROM tab0 AS cor0
----
35
35
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * 67 + - col0 * col1 col2 FROM tab0 cor0
----
-2002
3104
3698

onlyif mysql # use DIV operator for integer division
query I rowsort label-6814
SELECT + col2 DIV col0 + 43 * ( col2 ) + col1 AS col2 FROM tab0 AS cor0
----
140
1506
3617

skipif mysql # not compatible
query I rowsort label-6814
SELECT + col2 / col0 + 43 * ( col2 ) + col1 AS col2 FROM tab0 AS cor0
----
140
1506
3617

query I rowsort
SELECT - ( - col0 ) + col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT + col1 + col1 + col1 AS col2 FROM tab0 AS cor0
----
258
273
291

query I rowsort
SELECT - 54 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to 71e27a12767d3a987ce05e4d6edad211

onlyif mysql # use DIV operator for integer division
query I rowsort label-6818
SELECT ALL - col2 DIV + 70 AS col0 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6818
SELECT ALL - col2 / + 70 AS col0 FROM tab1 AS cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6819
SELECT - col2 + col0 DIV - cor0.col0 FROM tab2 cor0
----
-27
-28
-39

skipif mysql # not compatible
query I rowsort label-6819
SELECT - col2 + col0 / - cor0.col0 FROM tab2 cor0
----
-27
-28
-39

query I rowsort
SELECT col2 * col1 * - col2 AS col1 FROM tab2 cor0
----
-22599
-24548
-39884

query I rowsort
SELECT col1 + - 56 FROM tab1 AS cor0
----
-30
-43
-46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6822
SELECT - + col1 + + CAST( NULL AS DECIMAL ) * ( + col2 ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6822
SELECT - + col1 + + CAST ( NULL AS REAL ) * ( + col2 ) FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6823
SELECT + col2 * CAST( NULL AS SIGNED ) + - col0 * cor0.col0 / col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6823
SELECT + col2 * CAST ( NULL AS INTEGER ) + - col0 * cor0.col0 / col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - tab0.col0 + 3 + - 94 AS col2 FROM tab0
----
-115
-126
-180

query I rowsort
SELECT DISTINCT col1 + + col1 * - 70 FROM tab1
----
-1794
-690
-897

query I rowsort
SELECT - + 37 * cor0.col1 AS col1 FROM tab1 AS cor0
----
-370
-481
-962

query I rowsort
SELECT + col1 + - col0 + + col1 FROM tab0 AS cor0
----
148
159
93

query I rowsort
SELECT - - col0 + - col1 * - col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL + cor1.col0 AS col1 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT - ( - col2 ) + + col0 * - cor0.col2 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-6831
SELECT + col2 DIV + tab0.col0 AS col1 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6831
SELECT + col2 / + tab0.col0 AS col1 FROM tab0
----
0
0
1

query I rowsort
SELECT - 7 * - col1 * + col2 + + 2 AS col2 FROM tab1 AS cor0
----
3992
8738
9830

query I rowsort
SELECT + cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT - col1 * + col0 * + col1 AS col2 FROM tab1
----
-13520
-2028
-6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-6835
SELECT DISTINCT + + cor0.col1 DIV - 7 FROM tab0, tab2 cor0
----
-2
-4
-8

skipif mysql # not compatible
query I rowsort label-6835
SELECT DISTINCT + + cor0.col1 / - 7 FROM tab0, tab2 cor0
----
-2
-4
-8

query I rowsort
SELECT + col1 * col0 * col1 + 55 AS col0 FROM tab2 AS cor0
----
22886
271573
6782

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 98 col1 FROM tab1, tab2 AS cor0
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

query I rowsort
SELECT DISTINCT 62 - col1 FROM tab0
----
-24
-29
-35

onlyif mysql # use DIV operator for integer division
query I rowsort label-6839
SELECT DISTINCT 36 DIV + col2 + col0 AS col2 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-6839
SELECT DISTINCT 36 / + col2 + col0 AS col2 FROM tab1
----
3
64
80

query I rowsort
SELECT 51 - 67 AS col0 FROM tab2
----
-16
-16
-16

query I rowsort
SELECT DISTINCT col2 * - cor0.col2 + col1 FROM tab2 AS cor0
----
-1427
-617
-698

query I rowsort
SELECT ALL col2 + - ( col2 ) * cor0.col2 AS col0 FROM tab1 cor0
----
-2862
-3192
-9120

query I rowsort
SELECT - ( tab2.col0 ) AS col2 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6844
SELECT DISTINCT - 97 DIV col0 FROM tab0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-6844
SELECT DISTINCT - 97 / col0 FROM tab0
----
-1
-2
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col0 + col0 ) * 39 col2 FROM tab2
----
546
6084
6162

query I rowsort
SELECT - 2 + cor0.col2 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 19f7d3b70505d41a59890d3ed1583920

onlyif mysql # use DIV operator for integer division
query I rowsort label-6847
SELECT + col0 DIV + 77 AS col2 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6847
SELECT + col0 / + 77 AS col2 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT ALL - - col2 * - 86 FROM tab0 AS cor0
----
-2838
-7052
-86

query I rowsort
SELECT DISTINCT col1 * + col0 * col2 + + col1 FROM tab1 AS cor0
----
36490
4238
99853

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6850
SELECT - col1 + - CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6850
SELECT - col1 + - CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 + ( col2 ) AS col2 FROM tab1 cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6852
SELECT ALL 54 DIV + col2 + - ( + col0 ) * col1 AS col0 FROM tab0
----
-2063
-3341
-8099

skipif mysql # not compatible
query I rowsort label-6852
SELECT ALL 54 / + col2 + - ( + col0 ) * col1 AS col0 FROM tab0
----
-2063
-3341
-8099

query I rowsort
SELECT tab2.col0 * + tab2.col1 - ( col0 ) AS col0 FROM tab2
----
1264
210
4524

query I rowsort
SELECT DISTINCT - 62 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6855
SELECT col1 DIV - tab2.col1 + 5 * - col0 * + 44 col0 FROM tab2
----
-1541
-17161
-17381

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6855
SELECT col1 / - tab2.col1 + 5 * - col0 * + 44 col0 FROM tab2
----
-1541
-17161
-17381

query I rowsort
SELECT DISTINCT + col2 * + 24 - col2 AS col0 FROM tab2 AS cor0
----
598
621
874

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6857
SELECT - - col0 * - CAST( col0 AS SIGNED ) AS col0 FROM tab0 cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-6857
SELECT - - col0 * - CAST ( col0 AS INTEGER ) AS col0 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT col2 * col1 + col0 AS col2 FROM tab2 cor0
----
1612
725
844

query I rowsort
SELECT - 35 AS col0 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to 6d967b3bac2e01a0318865f682f9a97b

query I rowsort
SELECT + col1 + col0 * + col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT ALL - + col0 + + col2 + col1 FROM tab1 AS cor0
----
29
3
77

query I rowsort
SELECT DISTINCT ( + 76 ) - + col0 FROM tab2
----
-2
-3
69

query I rowsort
SELECT DISTINCT col1 + 30 * - col2 FROM tab0
----
-2369
-904
67

query I rowsort
SELECT col2 + 20 - col1 FROM tab0
----
-33
-76
11

query I rowsort
SELECT ALL 96 * - tab1.col0 FROM tab1
----
-288
-6144
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6866
SELECT DISTINCT + 72 * + col0 * col2 - col2 DIV + col2 AS col0 FROM tab0
----
2519
525455
57023

skipif mysql # not compatible
query I rowsort label-6866
SELECT DISTINCT + 72 * + col0 * col2 - col2 / + col2 AS col0 FROM tab0
----
2519
525455
57023

query I rowsort
SELECT - col2 * ( - col0 ) AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT + - col0 + - cor0.col1 FROM tab1 cor0
----
-29
-74
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col2 + col1 col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT ALL + + col0 - col1 AS col1 FROM tab2 cor0
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 92 + - col2 col0 FROM tab1 AS cor0
----
-4
35
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * cor0.col0 - - col2 col2 FROM tab1 AS cor0
----
-4039
-6304
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-6873
SELECT ALL + col0 * col2 DIV 2 + + col1 * + col2 FROM tab2
----
2147
2548
931

skipif mysql # not compatible
query I rowsort label-6873
SELECT ALL + col0 * col2 / 2 + + col1 * + col2 FROM tab2
----
2147
2548
931

query I rowsort
SELECT - 43 * col1 AS col1 FROM tab1
----
-1118
-430
-559

query I rowsort
SELECT col0 + col0 * - 30 AS col2 FROM tab2
----
-203
-2262
-2291

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 - - col0 col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT 84 * col0 FROM tab1 AS cor0
----
252
5376
6720

query I rowsort
SELECT ( col2 ) + - col1 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + col0 * - col0 * col2 + col0 AS col1 FROM tab2 AS cor0
----
-1316
-158106
-237079

query I rowsort
SELECT DISTINCT - - cor0.col0 + col2 * 69 FROM tab2 AS cor0
----
1870
1872
2701

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 + col1 col1 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT cor0.col0 * col2 + col2 AS col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT - - cor0.col2 + - col2 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6884
SELECT - 89 * - col1 + + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6884
SELECT - 89 * - col1 + + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6885
SELECT DISTINCT - cor0.col2 * col1 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6885
SELECT DISTINCT - cor0.col2 * col1 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6886
SELECT - 96 + + col2 DIV cor0.col1 AS col2 FROM tab0 AS cor0
----
-96
-96
-96

skipif mysql # not compatible
query I rowsort label-6886
SELECT - 96 + + col2 / cor0.col1 AS col2 FROM tab0 AS cor0
----
-96
-96
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6887
SELECT - col1 * 14 + - col2 DIV - col0 AS col1 FROM tab0 AS cor0
----
-1203
-1274
-1358

skipif mysql # not compatible
query I rowsort label-6887
SELECT - col1 * 14 + - col2 / - col0 AS col1 FROM tab0 AS cor0
----
-1203
-1274
-1358

query I rowsort
SELECT col1 * + 65 FROM tab1 AS cor0
----
1690
650
845

query I rowsort
SELECT - + col1 * + col0 + + cor0.col0 * col0 FROM tab0 AS cor0
----
-1488
-178
-2170

onlyif mysql # use DIV operator for integer division
query I rowsort label-6890
SELECT - col2 DIV + 62 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6890
SELECT - col2 / + 62 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT ALL col1 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + col1 + ( + col1 ) * cor0.col1 * col1 FROM tab2 AS cor0
----
205438
29822
4930

query I rowsort
SELECT - 19 * col0 FROM tab0
----
-1691
-456
-665

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6894
SELECT ( - col2 ) * CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6894
SELECT ( - col2 ) * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * ( - col0 * + col0 ) AS col0 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT + - cor0.col1 + - col2 * col0 AS col2 FROM tab1 cor0
----
-188
-3658
-7693

query I rowsort
SELECT DISTINCT - cor0.col1 * ( + col0 ) AS col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT 16 + col0 FROM tab2 AS cor0
----
23
94
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-6899
SELECT ALL - col0 * col2 DIV cor0.col1 + - 92 AS col2 FROM tab1 AS cor0
----
-456
-682
-98

skipif mysql # not compatible
query I rowsort label-6899
SELECT ALL - col0 * col2 / cor0.col1 + - 92 AS col2 FROM tab1 AS cor0
----
-456
-682
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6900
SELECT DISTINCT - CAST( 13 AS SIGNED ) * + col1 AS col0 FROM tab0 cor0
----
-1118
-1183
-1261

skipif mysql # not compatible
query I rowsort label-6900
SELECT DISTINCT - CAST ( 13 AS INTEGER ) * + col1 AS col0 FROM tab0 cor0
----
-1118
-1183
-1261

query I rowsort
SELECT ALL + col0 * - 43 + col2 * - col0 + 5 FROM tab1 AS cor0
----
-11115
-286
-6395

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( + col0 AS REAL ) + + col1 * col2 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT ( 24 ) FROM tab0 AS cor0
----
24
24
24

query I rowsort
SELECT DISTINCT - - ( - col2 ) * - col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL - - 5 AS col0 FROM tab0 AS cor0
----
5
5
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-6906
SELECT - + col0 DIV 99 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6906
SELECT - + col0 / 99 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - + col2 * - 50 FROM tab0 cor0
----
1650
4100
50

query I rowsort
SELECT DISTINCT - col0 + cor0.col2 * - col2 FROM tab2 AS cor0
----
-1523
-736
-754

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6909
SELECT DISTINCT CAST( NULL AS SIGNED ) * + col2 + col2 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6909
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + col2 + col2 AS col1 FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6910
SELECT ALL - CAST( NULL AS SIGNED ) * + 64 + cor0.col0 * + col2 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6910
SELECT ALL - CAST ( NULL AS INTEGER ) * + 64 + cor0.col0 * + col2 col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + ( - col2 ) * col0 + + ( col2 ) FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-6912
SELECT col0 DIV 44 AS col1 FROM tab0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-6912
SELECT col0 / 44 AS col1 FROM tab0
----
0
0
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6913
SELECT cor0.col0 DIV cor0.col2 + - col1 FROM tab1 AS cor0
----
-13
-26
-9

skipif mysql # not compatible
query I rowsort label-6913
SELECT cor0.col0 / cor0.col2 + - col1 FROM tab1 AS cor0
----
-13
-26
-9

query I rowsort
SELECT + + 30 + + col0 AS col2 FROM tab0 AS cor0
----
119
54
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 98 col0 FROM tab1
----
98

query I rowsort
SELECT ALL - col0 + + 56 FROM tab1 AS cor0
----
-24
-8
53

skipif mysql # not compatible
query I rowsort
SELECT - + CAST ( + cor0.col0 AS REAL ) * + cor0.col1 + + col2 * col2 FROM tab2 AS cor0
----
-3926
101
512

query I rowsort
SELECT + col0 * ( 56 ) FROM tab2
----
392
4368
4424

query I rowsort
SELECT - 33 * - 45 + col1 - + col0 FROM tab1 AS cor0
----
1418
1431
1508

query I rowsort
SELECT DISTINCT + 54 * col0 + - col0 FROM tab2 AS cor0
----
371
4134
4187

query I rowsort
SELECT ALL + + col1 - - ( col1 ) FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT 55 AS col0 FROM tab0, tab1 cor0
----
55

query I rowsort
SELECT col2 * col0 + + col2 FROM tab1 cor0
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-6924
SELECT 3 DIV col0 + + col1 AS col2 FROM tab1 AS cor0
----
10
13
27

skipif mysql # not compatible
query I rowsort label-6924
SELECT 3 / col0 + + col1 AS col2 FROM tab1 AS cor0
----
10
13
27

query I rowsort
SELECT - col0 * + 79 + - col1 * col2 AS col2 FROM tab2 AS cor0
----
-1390
-6887
-7696

query I rowsort
SELECT - - 14 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

onlyif mysql # use DIV operator for integer division
query I rowsort label-6927
SELECT - col2 DIV cor0.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-6927
SELECT - col2 / cor0.col1 col2 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT ALL + 82 AS col2 FROM tab1 AS cor0
----
82
82
82

query I rowsort
SELECT DISTINCT - + 36 FROM tab1, tab1 AS cor0
----
-36

query I rowsort
SELECT col0 + col1 + - 31 FROM tab1
----
-2
43
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6931
SELECT - + cor0.col1 DIV + cor0.col2 AS col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6931
SELECT - + cor0.col1 / + cor0.col2 AS col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - tab1.col0 * tab1.col0 AS col0 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT 54 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6934
SELECT + col0 + - CAST( + 97 AS SIGNED ) * + col2 * + ( 48 * col2 ) FROM tab0
----
-31306855
-4621
-5070360

skipif mysql # not compatible
query I rowsort label-6934
SELECT + col0 + - CAST ( + 97 AS INTEGER ) * + col2 * + ( 48 * col2 ) FROM tab0
----
-31306855
-4621
-5070360

query I rowsort
SELECT DISTINCT + - col0 + - 25 FROM tab0 AS cor0
----
-114
-49
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-6936
SELECT col2 * - col1 + col1 DIV 23 FROM tab1 cor0
----
-1248
-1403
-570

skipif mysql # not compatible
query I rowsort label-6936
SELECT col2 * - col1 + col1 / 23 FROM tab1 cor0
----
-1248
-1403
-570

query I rowsort
SELECT DISTINCT - + 7 * + 70 AS col2 FROM tab2 AS cor0
----
-490

query I rowsort
SELECT 75 + col2 * col0 * 44 FROM tab1 AS cor0
----
160587
337995
7203

query I rowsort
SELECT + ( - 83 ) + col0 * - cor0.col0 FROM tab0 AS cor0
----
-1308
-659
-8004

query I rowsort
SELECT ALL - cor0.col2 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - ( 50 ) + col1 * col0 + - ( + cor0.col1 ) * + 94 * + ( + col1 ) AS col0 FROM tab1 AS cor0
----
-14896
-63516
-8810

query I rowsort
SELECT DISTINCT + 54 * + cor2.col2 FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 AS cor2, tab1 AS cor3
----
2916
3078
5184

query I rowsort
SELECT DISTINCT + col2 * col1 * col0 FROM tab1
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-6944
SELECT col0 + - col1 DIV + 67 AS col0 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-6944
SELECT col0 + - col1 / + 67 AS col0 FROM tab0 AS cor0
----
23
34
88

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2 cor2
----
3645 values hashing to b6efe6f7ec1a3daa3cc6ea9dd7d13455

query I rowsort
SELECT DISTINCT 96 * + col0 FROM tab0 AS cor0
----
2304
3360
8544

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 96 col1 FROM tab2 AS cor0
----
96
96
96

query I rowsort
SELECT - - col1 + col2 * - ( col1 ) * col0 AS col2 FROM tab0 AS cor0
----
-3298
-664027
-68026

onlyif mysql # use DIV operator for integer division
query I rowsort label-6949
SELECT - col0 + + col2 DIV col0 AS col2 FROM tab2 AS cor0
----
-4
-78
-79

skipif mysql # not compatible
query I rowsort label-6949
SELECT - col0 + + col2 / col0 AS col2 FROM tab2 AS cor0
----
-4
-78
-79

query I rowsort
SELECT + ( 33 ) FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 76da8bc7cae18ecf856438f872430c80

query I rowsort
SELECT DISTINCT - col0 * + col0 * - 59 FROM tab2
----
2891
358956
368219

query I rowsort
SELECT ALL - + col0 + 9 * - 91 AS col1 FROM tab1 AS cor0
----
-822
-883
-899

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - ( - col2 ) col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - col1 * 4 AS col1 FROM tab0 AS cor0
----
-344
-364
-388

query I rowsort
SELECT - col0 - col1 * col1 AS col1 FROM tab1
----
-164
-249
-679

query I rowsort
SELECT ALL - 22 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to fae46f8148b02964f7145eb6ed5819f9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6957
SELECT ALL 4 DIV - col0 + + col1 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6957
SELECT ALL 4 / - col0 + + col1 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT + col0 * cor0.col0 + cor0.col0 AS col2 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT col2 * 89 + - col2 + + col0 AS col0 FROM tab2 AS cor0
----
2366
2383
3423

query I rowsort
SELECT + col0 * col1 * - col2 AS col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT - - ( - col0 ) * - cor0.col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL + col1 * - 32 + cor0.col0 + col1 FROM tab1 AS cor0
----
-246
-323
-803

query I rowsort
SELECT DISTINCT 13 AS col2 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
13

query I rowsort
SELECT ALL - cor0.col0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

onlyif mysql # use DIV operator for integer division
query I rowsort label-6965
SELECT DISTINCT - ( + col0 ) + col1 DIV 43 + col2 AS col1 FROM tab2 AS cor0
----
-41
-51
20

skipif mysql # not compatible
query I rowsort label-6965
SELECT DISTINCT - ( + col0 ) + col1 / 43 + col2 AS col1 FROM tab2 AS cor0
----
-41
-51
20

query I rowsort
SELECT DISTINCT + ( - cor0.col2 ) + col2 * col0 + col2 AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + 79 + col0 FROM tab1 AS cor0
----
143
159
82

query I rowsort
SELECT - 1 + - col0 FROM tab2 AS cor0
----
-79
-8
-80

query I rowsort
SELECT DISTINCT ( + cor0.col1 ) + col1 AS col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT 41 AS col0 FROM tab1, tab2, tab2 cor0
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

onlyif mysql # use DIV operator for integer division
query I rowsort label-6971
SELECT ALL + col0 DIV - cor0.col1 + ( cor0.col1 + - col2 ) * 29 FROM tab1 AS cor0
----
-1369
-2413
-812

skipif mysql # not compatible
query I rowsort label-6971
SELECT ALL + col0 / - cor0.col1 + ( cor0.col1 + - col2 ) * 29 FROM tab1 AS cor0
----
-1369
-2413
-812

query I rowsort
SELECT + col2 * col0 * col0 + col0 FROM tab2
----
1330
158262
237237

query I rowsort
SELECT 52 * 93 FROM tab2
----
4836
4836
4836

query I rowsort
SELECT - col2 - - 24 AS col1 FROM tab0
----
-58
-9
23

query I rowsort
SELECT ALL col0 * 82 + col1 * + col1 AS col1 FROM tab0 AS cor0
----
12279
15579
9364

query I rowsort
SELECT ALL + col0 + + col1 * + col2 AS col1 FROM tab2 AS cor0
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * ( - col0 ) col1 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6978
SELECT + col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6978
SELECT + col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 * + 83 AS col2 FROM tab2 AS cor0
----
2158
2241
3154

onlyif mysql # use DIV operator for integer division
query I rowsort label-6980
SELECT ALL col1 + col1 DIV 73 col0 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6980
SELECT ALL col1 + col1 / 73 col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - col2 - + col0 * - ( + cor0.col0 ) FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT - cor0.col0 + 55 FROM tab1 AS cor0
----
-25
-9
52

query I rowsort
SELECT ALL cor0.col2 * col0 * - 16 + - col2 AS col2 FROM tab0 cor0
----
-116850
-12705
-561

onlyif mysql # use DIV operator for integer division
query I rowsort label-6984
SELECT DISTINCT + col0 DIV - ( col1 ) FROM tab1 cor0
----
-6
0

skipif mysql # not compatible
query I rowsort label-6984
SELECT DISTINCT + col0 / - ( col1 ) FROM tab1 cor0
----
-6
0

query I rowsort
SELECT ALL tab1.col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT + + col0 * + col1 + ( col1 ) FROM tab2 AS cor0
----
1360
248
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * - ( ( + cor0.col0 ) ) col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT col0 * + ( - 64 ) AS col2 FROM tab1 AS cor0
----
-192
-4096
-5120

onlyif mysql # use DIV operator for integer division
query I rowsort label-6989
SELECT ALL col2 DIV 98 - - 16 AS col0 FROM tab2 cor0
----
16
16
16

skipif mysql # not compatible
query I rowsort label-6989
SELECT ALL col2 / 98 - - 16 AS col0 FROM tab2 cor0
----
16
16
16

query I rowsort
SELECT - - col2 + ( + 75 ) AS col2 FROM tab2 AS cor0
----
101
102
113

query I rowsort
SELECT ALL + col1 * + 39 FROM tab1 AS cor0
----
1014
390
507

onlyif mysql # use DIV operator for integer division
query I rowsort label-6992
SELECT col1 * 39 DIV + 46 + + col2 DIV - ( + col0 ) FROM tab2 AS cor0
----
14
23
50

skipif mysql # not compatible
query I rowsort label-6992
SELECT col1 * 39 / + 46 + + col2 / - ( + col0 ) FROM tab2 AS cor0
----
14
23
50

query I rowsort
SELECT DISTINCT - - cor0.col0 * - cor0.col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL - col1 * - 80 FROM tab2 AS cor0
----
1360
2480
4720

query I rowsort
SELECT - + col2 + + 97 * col1 FROM tab1 AS cor0
----
1165
2468
913

onlyif mysql # use DIV operator for integer division
query I rowsort label-6996
SELECT - col2 DIV - cor0.col0 - col2 AS col1 FROM tab1 AS cor0
----
-36
-57
-95

skipif mysql # not compatible
query I rowsort label-6996
SELECT - col2 / - cor0.col0 - col2 AS col1 FROM tab1 AS cor0
----
-36
-57
-95

query I rowsort
SELECT DISTINCT + + col1 * col0 + col1 * cor0.col1 + - col2 FROM tab1 AS cor0
----
1113
683
700

query I rowsort
SELECT DISTINCT col1 * col1 * + 14 FROM tab0
----
103544
115934
131726

query I rowsort
SELECT col1 * col1 + 43 FROM tab1
----
143
212
719

query I rowsort
SELECT - tab1.col0 + - col0 + + col2 * col1 AS col0 FROM tab1
----
1088
1398
442

query I rowsort
SELECT - col0 + - col1 + - 24 AS col2 FROM tab0
----
-134
-156
-204

query I rowsort
SELECT DISTINCT tab2.col1 * + ( col0 ) AS col2 FROM tab2
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7003
SELECT + + CAST( NULL AS SIGNED ) * col2 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7003
SELECT + + CAST ( NULL AS INTEGER ) * col2 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + - 20 * col0 FROM tab1 AS cor0
----
-1223
-1504
-6

query I rowsort
SELECT ALL - 63 + - 92 * + col1 - col2 FROM tab1 cor0
----
-1040
-1355
-2509

query I rowsort
SELECT DISTINCT + - col2 * - 57 - col1 * + 97 AS col2 FROM tab2 AS cor0
----
-1468
-4241
517

query I rowsort
SELECT - ( - ( + cor0.col0 ) ) AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + col0 * cor0.col0 + col1 * + col0 FROM tab0 cor0
----
16020
2640
4620

query I rowsort
SELECT - + col0 + - col1 * + col0 FROM tab1 cor0
----
-1120
-704
-81

query I rowsort
SELECT - col0 + col2 * col1 * 20 + + col1 FROM tab1 AS cor0
----
11346
24893
28103

query I rowsort
SELECT ALL col1 + ( - col2 ) AS col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL 32 - 4 AS col0 FROM tab1 AS cor0
----
28
28
28

query I rowsort
SELECT ALL - 50 + + ( col2 ) AS col2 FROM tab0 AS cor0
----
-17
-49
32

query I rowsort
SELECT ALL - 51 * col1 FROM tab0 cor0
----
-4386
-4641
-4947

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * - col1 + + col1 col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-7016
SELECT ALL col0 DIV col1 + ( cor0.col2 ) * - col0 AS col2 FROM tab2 AS cor0
----
-189
-2027
-2998

skipif mysql # not compatible
query I rowsort label-7016
SELECT ALL col0 / col1 + ( cor0.col2 ) * - col0 AS col2 FROM tab2 AS cor0
----
-189
-2027
-2998

query I rowsort
SELECT ALL + - cor0.col2 + - col1 + cor0.col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT + cor0.col0 + + col2 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT ALL + col2 * col0 * col1 AS col1 FROM tab0 cor0
----
3395
664118
68112

query I rowsort
SELECT col1 + + col1 * - col1 FROM tab1 cor0
----
-156
-650
-90

query I rowsort
SELECT - + col0 * - 49 * + cor0.col0 FROM tab0 AS cor0
----
28224
388129
60025

onlyif mysql # use DIV operator for integer division
query I rowsort label-7022
SELECT 14 DIV 69 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-7022
SELECT 14 / 69 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT col1 * 2 AS col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT + col1 * ( 80 * + col0 ) AS col0 FROM tab2 AS cor0
----
107440
17360
368160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7025
SELECT ALL - col2 * + CAST( - col2 + col2 AS SIGNED ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7025
SELECT ALL - col2 * + CAST ( - col2 + col2 AS INTEGER ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + ( - col0 ) * + ( col0 ) - - col1 FROM tab2
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT + + cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
10
13
26

query I rowsort
SELECT - ( + col2 ) + 74 AS col1 FROM tab1 AS cor0
----
-22
17
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-7029
SELECT - + 98 DIV col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7029
SELECT - + 98 / col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - ( + col0 ) + 63 FROM tab2 AS cor0
----
-15
-16
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-7031
SELECT ( col2 ) DIV - col2 AS col2 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7031
SELECT ( col2 ) / - col2 AS col2 FROM tab0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7032
SELECT ALL 11 DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7032
SELECT ALL 11 / col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - - col1 * col1 + - col2 FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT DISTINCT col2 * + col0 * + col1 - col0 FROM tab2 AS cor0
----
119574
50955
5852

query I rowsort
SELECT - col0 * - 76 + - col2 AS col2 FROM tab0 cor0
----
1791
2659
6682

query I rowsort
SELECT DISTINCT + ( + col0 + - col0 ) AS col0 FROM tab1
----
0

query I rowsort
SELECT DISTINCT 67 AS col1 FROM tab0, tab2 cor0
----
67

query I rowsort
SELECT DISTINCT - ( 26 ) AS col1 FROM tab2, tab1 AS cor0
----
-26

query I rowsort
SELECT ( + 91 + col1 * ( col2 ) ) AS col2 FROM tab2
----
1625
737
928

query I rowsort
SELECT + 8 + ( col0 ) * + col0 AS col1 FROM tab1 cor0
----
17
4104
6408

query I rowsort
SELECT cor1.col2 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT + col2 + + cor0.col2 * - col1 FROM tab2 AS cor0
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 87 * - 51 * col2 + + 10 col1 FROM tab0 AS cor0
----
-146411
-363824
-4427

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col0 col1 FROM tab2
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 28 col1 FROM tab0
----
28
28
28

query I rowsort
SELECT DISTINCT - 9 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7047
SELECT DISTINCT - 94 + col2 / + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7047
SELECT DISTINCT - 94 + col2 / + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - 36 + col2 FROM tab0 AS cor0
----
-3
-35
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-7049
SELECT - - col0 + col2 * - col1 DIV + col1 AS col0 FROM tab1 AS cor0
----
-16
-51
7

skipif mysql # not compatible
query I rowsort label-7049
SELECT - - col0 + col2 * - col1 / + col1 AS col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT + tab1.col0 * 33 + tab1.col0 AS col1 FROM tab1
----
102
2176
2720

query I rowsort
SELECT - col2 + - col0 + - 34 FROM tab1 AS cor0
----
-155
-210
-91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7052
SELECT DISTINCT col2 + CAST( NULL AS SIGNED ) * 89 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-7052
SELECT DISTINCT col2 + CAST ( NULL AS INTEGER ) * 89 FROM tab0
----
NULL

query I rowsort
SELECT DISTINCT tab2.col0 + 42 + + 41 FROM tab2
----
161
162
90

query I rowsort
SELECT - cor0.col2 * col0 + - 78 AS col0 FROM tab0 AS cor0
----
-113
-7376
-870

onlyif mysql # use DIV operator for integer division
query I rowsort label-7055
SELECT + - cor0.col1 DIV - col1 + + 31 AS col1 FROM tab1 AS cor0
----
32
32
32

skipif mysql # not compatible
query I rowsort label-7055
SELECT + - cor0.col1 / - col1 + + 31 AS col1 FROM tab1 AS cor0
----
32
32
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-7056
SELECT 46 DIV cor1.col0 AS col2 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 023586865541c1c72e5b8f462acefafe

skipif mysql # not compatible
query I rowsort label-7056
SELECT 46 / cor1.col0 AS col2 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 023586865541c1c72e5b8f462acefafe

query I rowsort
SELECT - + col2 * - 21 + + 13 FROM tab0 AS cor0
----
1735
34
706

query I rowsort
SELECT col0 * + cor0.col1 + col1 * 39 FROM tab2 AS cor0
----
1426
2006
6903

query I rowsort
SELECT DISTINCT ( + col1 ) * cor0.col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT + 74 * + 60 AS col2 FROM tab1 cor0
----
4440
4440
4440

query I rowsort
SELECT 62 + 40 * - col1 FROM tab1 cor0
----
-338
-458
-978

query I rowsort
SELECT + 49 * + cor0.col0 + - col0 AS col2 FROM tab2 AS cor0
----
336
3744
3792

query I rowsort
SELECT DISTINCT + 94 * - col2 FROM tab1 AS cor0
----
-5076
-5358
-9024

query I rowsort
SELECT ALL ( + col2 ) * - col1 * 40 AS col0 FROM tab2 AS cor0
----
-25840
-33480
-61360

onlyif mysql # use DIV operator for integer division
query I rowsort label-7065
SELECT ALL + tab0.col0 DIV col0 AS col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7065
SELECT ALL + tab0.col0 / col0 AS col1 FROM tab0
----
1
1
1

query I rowsort
SELECT col2 * + 74 + - col2 * 21 * - 1 FROM tab1 AS cor0
----
5130
5415
9120

query I rowsort
SELECT DISTINCT + cor0.col0 * col2 * col2 AS col2 FROM tab0 cor0
----
26136
35
598436

query I rowsort
SELECT DISTINCT + + cor0.col2 * col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL - - col0 + col0 * + 97 FROM tab1 cor0
----
294
6272
7840

query I rowsort
SELECT + 57 * + col0 AS col1 FROM tab1 AS cor0
----
171
3648
4560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor1.col1 col0 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT ALL col1 + - tab2.col1 * 19 FROM tab2
----
-1062
-306
-558

query I rowsort
SELECT col2 + col0 * + ( col1 ) AS col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT - col2 + - ( col0 ) AS col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT + - col0 * - 23 + col2 AS col2 FROM tab0 AS cor0
----
2129
585
806

query I rowsort
SELECT DISTINCT - - col0 + - ( + col1 ) * + col1 FROM tab2 AS cor0
----
-210
-3403
-954

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col2 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT - col2 * - col1 + col0 AS col2 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7079
SELECT ALL - - col2 + CAST( NULL AS SIGNED ) 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-7079
SELECT ALL - - col2 + CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7080
SELECT + cor0.col1 DIV cor0.col2 AS col1 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-7080
SELECT + cor0.col1 / cor0.col2 AS col1 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT + + col0 * - 77 + - col2 FROM tab2 AS cor0
----
-566
-6032
-6121

query I rowsort
SELECT DISTINCT + 51 FROM tab2, tab2 cor0, tab2 cor1
----
51

query I rowsort
SELECT ALL col2 - - col2 * - 97 FROM tab0 AS cor0
----
-3168
-7872
-96

query I rowsort
SELECT 77 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT - col0 * + 71 - cor0.col1 AS col2 FROM tab1 AS cor0
----
-239
-4554
-5693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + 51 - - col2 col2 FROM tab2 AS cor0
----
51
51
51

query I rowsort
SELECT DISTINCT + + 40 * col0 FROM tab1 AS cor0
----
120
2560
3200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 99 + - col1 col1 FROM tab0
----
13
2
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 69 col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 3bd7460efa48c66c072ad5f3c2def7e9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + ( + col1 ) col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - + ( + 71 ) + + col2 AS col2 FROM tab1 AS cor0
----
-14
-17
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-7092
SELECT DISTINCT + - cor0.col0 DIV - 74 AS col1 FROM tab1 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-7092
SELECT DISTINCT + - cor0.col0 / - 74 AS col1 FROM tab1 cor0
----
0
1

query I rowsort
SELECT col1 + + col0 * col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT cor0.col0 + + 73 AS col2 FROM tab1 AS cor0
----
137
153
76

query I rowsort
SELECT ALL 8 * + col0 FROM tab1 AS cor0
----
24
512
640

query I rowsort
SELECT - col2 * ( col1 ) * - col2 FROM tab0 cor0
----
611884
93654
97

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0, tab2 cor1, tab1 cor2
----
972 values hashing to 980274175fafec015a83080672486a9a

query I rowsort
SELECT ALL + - ( col0 ) * - col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT + col0 + - col0 * - ( - col0 * col1 + + 38 ) FROM tab2 AS cor0
----
-103016
-1246
-355914

query I rowsort
SELECT + cor0.col2 * cor0.col2 * + ( cor0.col2 * col1 ) FROM tab1 cor0
----
11501568
1851930
4094064

query I rowsort
SELECT DISTINCT + col1 * - tab2.col2 * + tab2.col1 AS col1 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT ALL + 14 + col1 FROM tab1 AS cor0
----
24
27
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-7103
SELECT ALL + - col0 DIV + col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7103
SELECT ALL + - col0 / + col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + - 67 * col0 AS col1 FROM tab1 AS cor0
----
-201
-4288
-5360

query I rowsort
SELECT ALL 39 * 52 FROM tab1
----
2028
2028
2028

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 62 + + col2 col0 FROM tab1
----
116
119
158

query I rowsort
SELECT + col1 * + col1 - - col2 * + col1 FROM tab1
----
1417
2080
670

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * cor0.col2 + - 56 * cor0.col1 + col1 col1 FROM tab0 AS cor0
----
-12303
-5370
-5522

query I rowsort
SELECT - col2 + col1 * - col0 AS col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT DISTINCT 76 * col0 * + tab0.col1 AS col1 FROM tab0
----
156864
258020
615524

query I rowsort
SELECT ALL + - cor0.col2 * - tab0.col2 AS col2 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 3a284e2c11914d1b470b4242a365931a

query I rowsort
SELECT ALL + 60 * - col1 + col1 AS col0 FROM tab1 AS cor0
----
-1534
-590
-767

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7113
SELECT DISTINCT col2 * + col1 * + CAST( NULL AS SIGNED ) AS col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-7113
SELECT DISTINCT col2 * + col1 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7114
SELECT DISTINCT col2 DIV + col2 + + col0 AS col1 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-7114
SELECT DISTINCT col2 / + col2 + + col0 AS col1 FROM tab0
----
25
36
90

query I rowsort
SELECT - - col1 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + col1 + + 20 AS col1 FROM tab1
----
30
33
46

query I rowsort
SELECT + tab0.col1 + - col0 + - col2 * col1 FROM tab0
----
-2776
-35
-7460

query I rowsort
SELECT - col2 * ( tab1.col0 * col2 ) + + 76 AS col2 FROM tab1
----
-207860
-737204
-8672

query I rowsort
SELECT + col0 * + 55 AS col0 FROM tab2 AS cor0
----
385
4290
4345

query I rowsort
SELECT tab2.col0 * ( + tab2.col2 * col1 ) AS col1 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT ALL + col1 * - 11 + col2 * - col0 FROM tab2
----
-2677
-3189
-530

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7122
SELECT DISTINCT + col0 + CAST( - ( col2 ) AS SIGNED ) FROM tab2
----
-20
41
52

skipif mysql # not compatible
query I rowsort label-7122
SELECT DISTINCT + col0 + CAST ( - ( col2 ) AS INTEGER ) FROM tab2
----
-20
41
52

query I rowsort
SELECT ( tab2.col1 ) AS col0 FROM tab1, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT - tab1.col1 FROM tab2, tab2 cor0 CROSS JOIN tab1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT + 25 * - col1 + + col1 FROM tab1 AS cor0
----
-240
-312
-624

query I rowsort
SELECT ALL 29 * - col2 + col2 + - col1 * cor0.col2 FROM tab0 AS cor0
----
-125
-3762
-9758

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7127
SELECT CAST( col1 AS SIGNED ) * + col2 AS col1 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-7127
SELECT CAST ( col1 AS INTEGER ) * + col2 AS col1 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-7128
SELECT DISTINCT - col0 DIV 24 AS col1 FROM tab2 AS cor0
----
-3
0

skipif mysql # not compatible
query I rowsort label-7128
SELECT DISTINCT - col0 / 24 AS col1 FROM tab2 AS cor0
----
-3
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7129
SELECT DISTINCT - CAST( NULL AS SIGNED ) - col2 * - col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7129
SELECT DISTINCT - CAST ( NULL AS INTEGER ) - col2 * - col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - 19 * col2 + col0 FROM tab2 AS cor0
----
-416
-506
-643

query I rowsort
SELECT DISTINCT + col1 * + 64 - + col2 FROM tab2 cor0
----
1050
1957
3750

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7132
SELECT ALL + col2 * ( col0 * + CAST( NULL AS SIGNED ) + - 40 * + col1 ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7132
SELECT ALL + col2 * ( col0 * + CAST ( NULL AS INTEGER ) + - 40 * + col1 ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 * - ( - ( - col0 ) ) AS col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT - cor0.col1 * + ( col1 ) * col2 + 66 + + col2 FROM tab2 AS cor0
----
-10878
-25854
-90414

query I rowsort
SELECT ALL - + col1 * + 37 + col2 + - col2 FROM tab1 AS cor0
----
-370
-481
-962

query I rowsort
SELECT + col0 + + cor0.col1 * col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL + ( col2 ) * - col0 + col0 + col0 FROM tab2 AS cor0
----
-175
-1872
-2844

query I rowsort
SELECT DISTINCT - col2 - + 44 FROM tab2 AS cor0
----
-70
-71
-82

query I rowsort
SELECT DISTINCT + cor0.col0 * + 49 AS col0 FROM tab2 cor0
----
343
3822
3871

query I rowsort
SELECT ALL + + ( - col1 ) * - col2 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + 99 + cor0.col2 FROM tab2 AS cor0
----
125
126
137

query I rowsort
SELECT col1 * col2 + cor0.col0 AS col0 FROM tab1 AS cor0
----
1328
1407
634

onlyif mysql # use DIV operator for integer division
query I rowsort label-7143
SELECT - + col2 * col2 DIV ( col1 ) + col1 * - cor0.col0 * col0 AS col0 FROM tab0 AS cor0
----
-118825
-49548
-720884

skipif mysql # not compatible
query I rowsort label-7143
SELECT - + col2 * col2 / ( col1 ) + col1 * - cor0.col0 * col0 AS col0 FROM tab0 AS cor0
----
-118825
-49548
-720884

query I rowsort
SELECT + + col0 + + col0 + + col2 * col1 FROM tab1 AS cor0
----
1408
1410
698

query I rowsort
SELECT + - cor0.col1 * col2 + + ( cor0.col1 ) AS col1 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-7146
SELECT ALL ( + col0 ) * + 85 * cor0.col2 + col1 DIV + 35 + col2 * - col2 AS col1 FROM tab0 AS cor0
----
2976
613608
66233

skipif mysql # not compatible
query I rowsort label-7146
SELECT ALL ( + col0 ) * + 85 * cor0.col2 + col1 / + 35 + col2 * - col2 AS col1 FROM tab0 AS cor0
----
2976
613608
66233

query I rowsort
SELECT + 22 - - col1 FROM tab1 AS cor0
----
32
35
48

query I rowsort
SELECT 5 + col0 + + col0 * col1 FROM tab0 AS cor0
----
2093
3435
8193

query I rowsort
SELECT - 7 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to ba940cd66e21e94e95aada5f28e1faf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-7150
SELECT ALL 15 * col0 DIV 56 + + 85 FROM tab0
----
108
91
94

skipif mysql # not compatible
query I rowsort label-7150
SELECT ALL 15 * col0 / 56 + + 85 FROM tab0
----
108
91
94

query I rowsort
SELECT DISTINCT - - col0 * 72 AS col1 FROM tab0 AS cor0
----
1728
2520
6408

onlyif mysql # use DIV operator for integer division
query I rowsort label-7152
SELECT ALL + col2 + + col0 + col2 DIV col2 FROM tab0 AS cor0
----
172
37
58

skipif mysql # not compatible
query I rowsort label-7152
SELECT ALL + col2 + + col0 + col2 / col2 FROM tab0 AS cor0
----
172
37
58

query I rowsort
SELECT + cor0.col0 * 95 FROM tab2 AS cor0
----
665
7410
7505

query I rowsort
SELECT DISTINCT - + cor0.col0 + + col1 AS col2 FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT ALL - col2 * - 96 - - col0 AS col2 FROM tab0 AS cor0
----
131
3192
7961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + ( - col2 ) col2 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT + + col2 * - ( - col0 * - col1 ) - + col2 AS col1 FROM tab1 AS cor0
----
-36537
-4266
-99936

query I rowsort
SELECT DISTINCT col0 * + cor0.col1 + + cor0.col1 * + col1 AS col0 FROM tab2 AS cor0
----
1178
1632
8083

onlyif mysql # use DIV operator for integer division
query I rowsort label-7159
SELECT DISTINCT + col0 DIV 96 AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7159
SELECT DISTINCT + col0 / 96 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + - col2 + 27 AS col2 FROM tab2 AS cor0
----
-11
0
1

query I rowsort
SELECT DISTINCT - 25 * col0 + 71 FROM tab1
----
-1529
-1929
-4

query I rowsort
SELECT DISTINCT - 22 + + col0 FROM tab1
----
-19
42
58

query I rowsort
SELECT DISTINCT - - col0 * - col1 + + cor0.col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT ALL - col1 * - col0 + ( - col0 ) FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT ALL col1 + col2 * col0 * + col0 FROM tab0
----
1322
19094
649613

query I rowsort
SELECT - col2 * - col0 * + col2 + + col2 * - ( - cor0.col0 ) FROM tab1 AS cor0
----
211584
744960
8910

query I rowsort
SELECT ALL + col2 + + 20 FROM tab1 AS cor0
----
116
74
77

query I rowsort
SELECT col0 * cor0.col2 AS col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - 14 * 61 FROM tab1
----
-854
-854
-854

query I rowsort
SELECT + col0 * - 10 FROM tab2 AS cor0
----
-70
-780
-790

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col0 + col1 col1 FROM tab1
----
188
3658
7693

query I rowsort
SELECT + cor0.col0 * col1 + - 11 FROM tab0 AS cor0
----
2053
3384
8088

query I rowsort
SELECT - 89 * + col0 AS col2 FROM tab2 AS cor0
----
-623
-6942
-7031

query I rowsort
SELECT ALL - - 42 AS col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

query I rowsort
SELECT + tab2.col0 * + tab2.col2 * col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT 10 + + col2 + 78 FROM tab0
----
121
170
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7177
SELECT 4 * - col1 * - ( + col1 ) + - col2 DIV col0 AS col1 FROM tab2
----
1156
13924
3841

skipif mysql # not compatible
query I rowsort label-7177
SELECT 4 * - col1 * - ( + col1 ) + - col2 / col0 AS col1 FROM tab2
----
1156
13924
3841

query I rowsort
SELECT - col1 + + col0 * - col1 FROM tab0
----
-2150
-3492
-8190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7179
SELECT - CAST( NULL AS SIGNED ) AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7179
SELECT - CAST ( NULL AS INTEGER ) AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + 86 + + col0 FROM tab0
----
110
121
175

query I rowsort
SELECT ALL 28 FROM tab0, tab2 AS cor0, tab2 cor1
----
27 values hashing to 8a39580587f2831072e93c319ff94bbf

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7182
SELECT DISTINCT + - col2 * + cor0.col0 + - CAST( ( col2 ) AS SIGNED ) * col1 * - col2 AS col1 FROM tab2 AS cor0
----
21546
22410
37856

skipif mysql # not compatible
query I rowsort label-7182
SELECT DISTINCT + - col2 * + cor0.col0 + - CAST ( ( col2 ) AS INTEGER ) * col1 * - col2 AS col1 FROM tab2 AS cor0
----
21546
22410
37856

query I rowsort
SELECT - col0 + col2 * 15 AS col0 FROM tab2 AS cor0
----
312
398
491

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 + + col0 col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL 34 + col1 AS col1 FROM tab2 AS cor0
----
51
65
93

query I rowsort
SELECT DISTINCT col1 * col1 FROM tab2 WHERE NOT + col2 <= ( NULL )
----

query I rowsort
SELECT tab2.col2 + + col0 FROM tab2 WHERE NULL IN ( - col1 + + col2 * col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7188
SELECT + tab0.col0 * + col1 + + col0 DIV col0 + - col2 * + col2 AS col1 FROM tab0
----
1376
3395
976

skipif mysql # not compatible
query I rowsort label-7188
SELECT + tab0.col0 * + col1 + + col0 / col0 + - col2 * + col2 AS col1 FROM tab0
----
1376
3395
976

query III rowsort
SELECT * FROM tab2 WHERE NOT col1 < NULL
----

query I rowsort
SELECT DISTINCT + - col1 * + col1 - ( + col1 ) * col0 AS col1 FROM tab0 AS cor0
----
-12804
-16380
-9460

onlyif mysql # use DIV operator for integer division
query I rowsort label-7191
SELECT - tab0.col1 + + col2 + col1 DIV + col1 AS col2 FROM tab0
----
-52
-8
-95

skipif mysql # not compatible
query I rowsort label-7191
SELECT - tab0.col1 + + col2 + col1 / + col1 AS col2 FROM tab0
----
-52
-8
-95

query I rowsort
SELECT - ( - col1 ) * ( + col1 ) + tab2.col1 FROM tab2
----
306
3540
992

query I rowsort
SELECT DISTINCT 39 + - 36 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
3

query I rowsort
SELECT col0 * - col2 + - 20 AS col2 FROM tab0
----
-55
-7318
-812

query I rowsort
SELECT DISTINCT + + 65 AS col1 FROM tab2 AS cor0
----
65

query I rowsort
SELECT - 70 * - cor0.col1 FROM tab0 cor0
----
6020
6370
6790

query I rowsort
SELECT + + col1 + col2 * 94 AS col0 FROM tab2 AS cor0
----
2503
2569
3589

onlyif mysql # use DIV operator for integer division
query I rowsort label-7198
SELECT DISTINCT - + col0 * col1 DIV + 9 + 73 DIV + col1 FROM tab2 cor0
----
-145
-22
-510

skipif mysql # not compatible
query I rowsort label-7198
SELECT DISTINCT - + col0 * col1 / + 9 + 73 / + col1 FROM tab2 cor0
----
-145
-22
-510

query I rowsort
SELECT 14 * col1 AS col0 FROM tab0 cor0
----
1204
1274
1358

query I rowsort
SELECT DISTINCT tab1.col0 / - col0 AS col1 FROM tab1 WHERE NOT NULL = ( NULL )
----

query III rowsort
SELECT * FROM tab2 WHERE ( NULL ) NOT BETWEEN ( NULL ) AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7202
SELECT col0 * col2 + col0 DIV col0 FROM tab2
----
190
2029
3003

skipif mysql # not compatible
query I rowsort label-7202
SELECT col0 * col2 + col0 / col0 FROM tab2
----
190
2029
3003

query I rowsort
SELECT col1 / + col0 + col0 AS col0 FROM tab1 WHERE NOT NULL IN ( - col1 - tab1.col1 / + col1 )
----

query I rowsort
SELECT ALL col0 * col1 * col1 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT DISTINCT cor0.col0 + col1 * - col1 AS col2 FROM tab2 AS cor0
----
-210
-3403
-954

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND col2 + + col0
----

query I rowsort
SELECT col0 * + col1 * - col0 AS col0 FROM tab1 WHERE NOT NULL IN ( col1 )
----

query I rowsort
SELECT DISTINCT - col0 * - col2 * - cor0.col2 AS col0 FROM tab0 cor0
----
-26136
-35
-598436

query III rowsort
SELECT * FROM tab2 WHERE NOT + col1 * col2 NOT BETWEEN ( NULL ) AND NULL
----

query I rowsort
SELECT tab2.col1 + + col1 + + col1 FROM tab2
----
177
51
93

query I rowsort
SELECT DISTINCT col1 + + col2 * + tab1.col1 FROM tab1 WHERE NOT ( NULL ) IN ( tab1.col2 * + col1 )
----

query I rowsort
SELECT DISTINCT col2 * col2 * col2 AS col2 FROM tab1
----
157464
185193
884736

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL NOT IN ( + col1 + + col0 )
----

query I rowsort
SELECT col1 * col2 * col0 + + col1 + col2 FROM tab2
----
119737
51089
5917

query I rowsort
SELECT ALL - - ( cor0.col2 ) AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - col0 * cor0.col0 + col1 + - col1 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL - 21 + + 6 * col1 AS col1 FROM tab1 AS cor0
----
135
39
57

query I rowsort
SELECT DISTINCT ( + col0 * - col2 ) FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT 7 + - col2 + col0 AS col1 FROM tab1 AS cor0
----
-44
-9
14

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 4 + + col1 * col2 + - col0 col2 FROM tab2 AS cor0
----
1460
571
834

query I rowsort
SELECT + col0 * cor0.col1 + + col0 + + col1 AS col0 FROM tab1 cor0
----
107
1133
714

query I rowsort
SELECT - 73 * cor0.col1 FROM tab1 AS cor0
----
-1898
-730
-949

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * col2 * + col1 col1 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT + - 41 * - col0 FROM tab2 AS cor0
----
287
3198
3239

query I rowsort
SELECT - cor0.col0 * + col0 * + ( + 50 ) AS col0 FROM tab1 AS cor0
----
-204800
-320000
-450

onlyif mysql # use DIV operator for integer division
query I rowsort label-7226
SELECT ALL - ( 1 ) DIV col2 AS col0 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7226
SELECT ALL - ( 1 ) / col2 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - col1 * - 79 + cor0.col1 AS col2 FROM tab0 AS cor0
----
6880
7280
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 - + 55 col2 FROM tab2 AS cor0
----
-17
-28
-29

query I rowsort
SELECT + - col1 * - col1 + col1 AS col0 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT ALL - + col0 * 42 + col2 AS col2 FROM tab2 AS cor0
----
-267
-3250
-3280

query I rowsort
SELECT ALL + - col2 * + col0 + + col0 * col1 * + col1 AS col0 FROM tab2 AS cor0
----
19829
269490
6538

query I rowsort
SELECT - col2 * col0 + + col2 FROM tab2
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-7233
SELECT - col2 + tab1.col0 DIV col2 + + 27 FROM tab1
----
-27
-29
-69

skipif mysql # not compatible
query I rowsort label-7233
SELECT - col2 + tab1.col0 / col2 + + 27 FROM tab1
----
-27
-29
-69

onlyif mysql # use DIV operator for integer division
query I rowsort label-7234
SELECT - 47 DIV - col2 AS col0 FROM tab0
----
0
1
47

skipif mysql # not compatible
query I rowsort label-7234
SELECT - 47 / - col2 AS col0 FROM tab0
----
0
1
47

query I rowsort
SELECT 55 * - tab2.col1 * 75 FROM tab2
----
-127875
-243375
-70125

query I rowsort
SELECT + col0 * + ( + col2 ) - col0 * + 52 * col2 FROM tab2 AS cor0
----
-103428
-153102
-9639

query I rowsort
SELECT + col0 + ( 21 ) AS col2 FROM tab0 cor0
----
110
45
56

query I rowsort
SELECT cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + - 29 col2 FROM tab0 AS cor0
----
57
62
68

query I rowsort
SELECT ALL - + col1 * + 66 + - 28 FROM tab0 AS cor0
----
-5704
-6034
-6430

query I rowsort
SELECT + + col1 - 29 AS col2 FROM tab0 AS cor0
----
57
62
68

query I rowsort
SELECT ALL - col2 + ( col1 ) * + col0 + cor0.col2 AS col0 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT - ( - col0 ) * - col0 AS col1 FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT ( ( + col1 ) ) FROM tab1
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7245
SELECT DISTINCT CAST( NULL AS DECIMAL ) + - col0 * + col0 * col0 + col0 AS col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-7245
SELECT DISTINCT CAST ( NULL AS REAL ) + - col0 * + col0 * col0 + col0 AS col2 FROM tab2
----
NULL

query I rowsort
SELECT - 31 * + col0 + + col2 AS col0 FROM tab2 AS cor0
----
-190
-2392
-2411

query I rowsort
SELECT DISTINCT col1 * col2 * tab0.col2 AS col0 FROM tab0
----
611884
93654
97

query I rowsort
SELECT + + col0 + col1 * - col0 AS col2 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT - + cor0.col1 * cor0.col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-7250
SELECT ALL col1 + + col0 DIV + col1 AS col2 FROM tab2 AS cor0
----
21
31
60

skipif mysql # not compatible
query I rowsort label-7250
SELECT ALL col1 + + col0 / + col1 AS col2 FROM tab2 AS cor0
----
21
31
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( + col0 ) * col2 + - col2 col1 FROM tab2 AS cor0
----
-2054
-216
-3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 38 * - col0 col1 FROM tab1 cor0
----
114
2432
3040

query I rowsort
SELECT + col1 + + 59 FROM tab2 AS cor0
----
118
76
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-7254
SELECT - col2 * - col2 DIV - 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-7254
SELECT - col2 * - col2 / - col2 col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + col2 * 54 AS col0 FROM tab0 AS cor0
----
1782
4428
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-7256
SELECT - + col1 * col0 + col1 DIV + cor0.col0 FROM tab2 AS cor0
----
-1343
-213
-4602

skipif mysql # not compatible
query I rowsort label-7256
SELECT - + col1 * col0 + col1 / + cor0.col0 FROM tab2 AS cor0
----
-1343
-213
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7257
SELECT CAST( NULL AS SIGNED ) + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7257
SELECT CAST ( NULL AS INTEGER ) + col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col0 + col1 FROM tab0 cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7259
SELECT + - CAST( col2 AS SIGNED ) * col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort label-7259
SELECT + - CAST ( col2 AS INTEGER ) * col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT - cor0.col0 + - tab2.col2 FROM tab2, tab1 cor0
----
9 values hashing to bf101804f9dfd3a9ab127a66a196b731

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col0 * col1 col1 FROM tab0 AS cor0
----
2150
3492
8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 + + col2 col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL col2 + + cor0.col1 * - col0 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT - - col1 + col0 * - col0 FROM tab0 AS cor0
----
-1128
-490
-7830

onlyif mysql # use DIV operator for integer division
query I rowsort label-7265
SELECT DISTINCT col2 + col1 DIV + col2 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-7265
SELECT DISTINCT col2 + col1 / + col2 FROM tab1
----
54
57
96

query I rowsort
SELECT - col1 * + col2 + col2 AS col0 FROM tab0 cor0
----
-2805
-7380
-96

query I rowsort
SELECT + col2 * + col1 + col0 AS col1 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL - cor0.col1 * cor0.col0 + cor0.col0 FROM tab2 AS cor0
----
-1264
-210
-4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-7269
SELECT col0 DIV + col1 + - col2 * + cor0.col2 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif mysql # not compatible
query I rowsort label-7269
SELECT col0 / + col1 + - col2 * + cor0.col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT + + cor0.col2 * - col2 + - col1 AS col0 FROM tab0 AS cor0
----
-1175
-6815
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7271
SELECT DISTINCT col2 DIV - col0 + + tab0.col2 * - col2 - col1 * + col2 FROM tab0
----
-14186
-3928
-98

skipif mysql # not compatible
query I rowsort label-7271
SELECT DISTINCT col2 / - col0 + + tab0.col2 * - col2 - col1 * + col2 FROM tab0
----
-14186
-3928
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col0 * + col1 - col2 col0 FROM tab0
----
3394
664036
68079

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - tab0.col1 col0 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7274
SELECT DISTINCT + - cor0.col2 + col2 DIV col0 AS col0 FROM tab1 AS cor0
----
-36
-57
-95

skipif mysql # not compatible
query I rowsort label-7274
SELECT DISTINCT + - cor0.col2 + col2 / col0 AS col0 FROM tab1 AS cor0
----
-36
-57
-95

query I rowsort
SELECT ALL col2 + + col0 AS col2 FROM tab1 cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7276
SELECT ALL col2 * + col2 DIV + col2 col2 FROM tab1
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7276
SELECT ALL col2 * + col2 / + col2 col2 FROM tab1
----
54
57
96

query I rowsort
SELECT - col0 * + cor0.col2 + + cor0.col2 FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-7278
SELECT + col1 DIV col0 + + 17 FROM tab0 AS cor0
----
18
19
20

skipif mysql # not compatible
query I rowsort label-7278
SELECT + col1 / col0 + + 17 FROM tab0 AS cor0
----
18
19
20

query I rowsort
SELECT DISTINCT cor0.col2 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT - col0 + 24 * cor0.col2 FROM tab1 AS cor0
----
1293
1304
2224

query I rowsort
SELECT ALL + - col1 * ( - col0 ) FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col1 * + ( col2 ) + col2 AS col0 FROM tab2 AS cor0
----
1560
684
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-7283
SELECT ALL + col0 * + col2 + + col0 DIV + col0 FROM tab0 AS cor0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-7283
SELECT ALL + col0 * + col2 + + col0 / + col0 FROM tab0 AS cor0
----
36
7299
793

query I rowsort
SELECT DISTINCT - col0 * col2 + - col1 * 50 AS col1 FROM tab0
----
-11848
-4885
-5092

query I rowsort
SELECT ALL 34 + tab1.col0 FROM tab1
----
114
37
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7286
SELECT + col1 * + CAST( NULL AS SIGNED ) + col1 * col0 / - 14 + + 84 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7286
SELECT + col1 * + CAST ( NULL AS INTEGER ) + col1 * col0 / - 14 + + 84 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * col1 + + col0 * col2 + - col2 AS col1 FROM tab1 AS cor0
----
3691
7753
784

query I rowsort
SELECT + + cor0.col0 * - col2 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL col2 + + col0 + + col0 FROM tab1 AS cor0
----
185
256
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-7290
SELECT ALL col0 + col0 DIV + 43 FROM tab0 AS cor0
----
24
35
91

skipif mysql # not compatible
query I rowsort label-7290
SELECT ALL col0 + col0 / + 43 FROM tab0 AS cor0
----
24
35
91

query I rowsort
SELECT + col2 + col1 * + 31 * col0 AS col0 FROM tab0 AS cor0
----
105246
251151
64017

query I rowsort
SELECT ALL col0 * + 85 + + col0 FROM tab0
----
2064
3010
7654

query I rowsort
SELECT 15 * + col0 + - col2 AS col0 FROM tab0
----
1253
327
524

query I rowsort
SELECT + col0 + col0 + - tab0.col1 FROM tab0
----
-27
-38
87

query I rowsort
SELECT + 36 + col1 FROM tab1
----
46
49
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-7296
SELECT col2 + col1 DIV col0 AS col0 FROM tab0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-7296
SELECT col2 + col1 / col0 AS col0 FROM tab0
----
3
36
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7297
SELECT DISTINCT col1 * - col0 + + tab0.col2 DIV col1 FROM tab0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-7297
SELECT DISTINCT col1 * - col0 + + tab0.col2 / col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT col0 + col1 + 78 FROM tab2
----
116
174
215

query I rowsort
SELECT DISTINCT col1 * - col2 + 87 * + 63 * col1 + + 58 FROM tab0 AS cor0
----
468586
491367
531618

query I rowsort
SELECT ALL - + cor0.col2 + + col1 AS col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT cor0.col1 * - col2 + 66 * + col0 FROM tab2 cor0
----
-375
3614
4568

query I rowsort
SELECT DISTINCT + - 4 * + cor0.col1 FROM tab1 AS cor0
----
-104
-40
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-7303
SELECT ALL + cor0.col0 * col0 + col0 DIV + 8 + - col2 FROM tab0 AS cor0
----
1228
546
7850

skipif mysql # not compatible
query I rowsort label-7303
SELECT ALL + cor0.col0 * col0 + col0 / + 8 + - col2 FROM tab0 AS cor0
----
1228
546
7850

query I rowsort
SELECT ALL - 29 * - col0 FROM tab2 AS cor0
----
203
2262
2291

query I rowsort
SELECT + 43 AS col1 FROM tab0, tab0 AS cor0, tab1 AS cor1, tab1, tab0 AS cor2
----
243 values hashing to 9f059abb74645264a8907ee97b850de4

query I rowsort
SELECT DISTINCT + 32 * col1 AS col0 FROM tab1 AS cor0
----
320
416
832

query I rowsort
SELECT - - 83 + - col0 FROM tab0 AS cor0
----
-6
48
59

query I rowsort
SELECT DISTINCT - ( + col0 ) * 65 FROM tab2 AS cor0
----
-455
-5070
-5135

query I rowsort
SELECT - + ( - col1 ) + 44 FROM tab0 cor0
----
130
135
141

query I rowsort
SELECT DISTINCT + ( - 34 ) FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 36 col0 FROM tab1, tab0 AS cor0
----
36

query I rowsort
SELECT + tab0.col0 * ( 47 * + col2 ) FROM tab0
----
1645
343006
37224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 88 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT + col0 * + col0 + + col2 * col1 FROM tab0 cor0
----
1322
15383
3414

query I rowsort
SELECT + cor0.col2 * + col2 + col0 AS col1 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT - - 35 AS col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 0d13dfd4c4a9d51ace3582c31cadcdbc

query I rowsort
SELECT DISTINCT ( + col1 ) * col1 * col1 AS col2 FROM tab0
----
636056
753571
912673

query I rowsort
SELECT - - col2 * - 93 FROM tab0 AS cor0
----
-3069
-7626
-93

query I rowsort
SELECT + 97 * 14 AS col1 FROM tab0 cor0
----
1358
1358
1358

query I rowsort
SELECT ALL + 22 * - 78 AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 487e71abadc316501ddb17c530f9543e

query I rowsort
SELECT DISTINCT + + col0 * cor0.col1 + col2 AS col0 FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7322
SELECT + - CAST( NULL AS SIGNED ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7322
SELECT + - CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7323
SELECT - ( + cor0.col2 ) * + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7323
SELECT - ( + cor0.col2 ) * + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 16 + - col1 FROM tab2 AS cor0
----
-1
-15
-43

onlyif mysql # use DIV operator for integer division
query I rowsort label-7325
SELECT 66 * + cor0.col2 + col1 DIV 85 AS col0 FROM tab2 cor0
----
1716
1782
2508

skipif mysql # not compatible
query I rowsort label-7325
SELECT 66 * + cor0.col2 + col1 / 85 AS col0 FROM tab2 cor0
----
1716
1782
2508

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * col0 + + col0 col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT tab1.col1 * - 68 * col2 AS col2 FROM tab1
----
-38760
-84864
-95472

query I rowsort
SELECT - 2 + + col2 * + col2 AS col1 FROM tab2
----
1442
674
727

query I rowsort
SELECT ( + tab2.col2 * col0 ) AS col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT ALL 18 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 903ac227935c1532300db45a8537c595

query I rowsort
SELECT ALL - + 55 + + 49 FROM tab2 AS cor0
----
-6
-6
-6

skipif mysql # not compatible
query I rowsort
SELECT + - CAST ( + 21 AS REAL ) + col0 FROM tab2 AS cor0
----
-14
57
58

query I rowsort
SELECT - + col2 * 86 + - col1 FROM tab0 AS cor0
----
-183
-2924
-7143

query I rowsort
SELECT 35 * + cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 041bd8a38e4a8610d022df2fab72a685

query I rowsort
SELECT DISTINCT ( 0 ) * col2 * - 56 + - col2 * col1 * - 36 FROM tab0 AS cor0
----
102168
268632
3492

query I rowsort
SELECT cor0.col0 * + 9 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to dc861a07b7f747b9310163b0daf7a43e

query I rowsort
SELECT - col2 - col1 * col0 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT 55 AS col1 FROM tab1, tab0 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to c59acfbb70996777fa5053195838c3d6

query I rowsort
SELECT - ( 89 ) - - tab1.col1 AS col0 FROM tab1
----
-63
-76
-79

query I rowsort
SELECT DISTINCT cor0.col2 + + col1 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT 92 * - 95 * - col1 FROM tab1
----
113620
227240
87400

query I rowsort
SELECT DISTINCT + col2 * col0 + - col2 FROM tab0
----
34
7216
759

query I rowsort
SELECT DISTINCT 51 + 97 AS col2 FROM tab2
----
148

query I rowsort
SELECT DISTINCT - tab2.col2 * col0 + + col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT tab1.col0 - - ( tab1.col1 * - col1 ) FROM tab1
----
-36
-673
-89

query I rowsort
SELECT - tab2.col0 + - 2 - + col1 AS col1 FROM tab2
----
-139
-40
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 85 col1 FROM tab0
----
85
85
85

query I rowsort
SELECT DISTINCT cor0.col0 * - ( col2 ) * + col0 + - col0 * col1 * col1 - + 32 AS col1 FROM tab0 AS cor0
----
-1386563
-196544
-330572

query I rowsort
SELECT DISTINCT - + col0 + - 39 FROM tab2 AS cor0
----
-117
-118
-46

query I rowsort
SELECT DISTINCT + - cor0.col1 * col0 - col2 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT col1 * + col2 * - col2 AS col0 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT ( tab2.col1 ) AS col0 FROM tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col1 * col1 ) col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT col2 * - 9 + - ( col0 ) FROM tab2 AS cor0
----
-250
-312
-421

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 cor0, tab1, tab2 AS cor1 WHERE ( NULL ) < ( NULL )
----

skipif mysql # not compatible
query I rowsort
SELECT + cor0.col0 + CAST ( - col2 AS REAL ) AS col1 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7357
SELECT ALL - col2 * CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-7357
SELECT ALL - col2 * CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT - - col0 + 98 FROM tab2 AS cor0
----
105
176
177

query I rowsort
SELECT - col1 * - ( col2 ) AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL col2 * 63 FROM tab2
----
1638
1701
2394

query I rowsort
SELECT + col2 + 66 * col1 * + col0 FROM tab1
----
42297
5202
68736

query I rowsort
SELECT 70 + 7 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT ALL - + col2 + - cor0.col1 * col1 FROM tab0 AS cor0
----
-7429
-8363
-9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-7364
SELECT DISTINCT + cor0.col2 DIV + 48 AS col0 FROM tab1 cor0
----
1
2

skipif mysql # not compatible
query I rowsort label-7364
SELECT DISTINCT + cor0.col2 / + 48 AS col0 FROM tab1 cor0
----
1
2

query I rowsort
SELECT col1 * - 50 FROM tab0 AS cor0
----
-4300
-4550
-4850

query I rowsort
SELECT col2 + ( - 2 ) * col2 * + 95 AS col0 FROM tab2 AS cor0
----
-4914
-5103
-7182

query I rowsort
SELECT - col2 - 43 FROM tab0 AS cor0
----
-125
-44
-76

query I rowsort
SELECT DISTINCT + - 64 + + 80 FROM tab1 cor0
----
16

query I rowsort
SELECT ALL - + col2 + - 97 * + col0 * + col2 AS col1 FROM tab1 AS cor0
----
-15768
-353913
-745056

query I rowsort
SELECT + col1 * - 67 - - cor0.col1 FROM tab0 AS cor0
----
-5676
-6006
-6402

query I rowsort
SELECT ALL 62 * col2 + col1 FROM tab2
----
1671
1705
2373

query I rowsort
SELECT ALL + - ( col0 ) * + col1 * - 96 FROM tab2 AS cor0
----
128928
20832
441792

query I rowsort
SELECT ALL + - ( col1 ) + col0 * + 88 FROM tab1 AS cor0
----
238
5622
7027

query I rowsort
SELECT + ( - 17 ) - + col0 AS col2 FROM tab0 cor0
----
-106
-41
-52

query I rowsort
SELECT - + col0 + + 0 * - col2 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT col0 * 13 FROM tab2 AS cor0
----
1014
1027
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-7377
SELECT DISTINCT - - col1 DIV + col1 + - col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-7377
SELECT DISTINCT - - col1 / + col1 + - col0 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT + + ( ( + cor0.col0 ) ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL - 8 - 94 * col2 FROM tab2 AS cor0
----
-2452
-2546
-3580

query I rowsort
SELECT ALL + - col1 * col0 - - col0 AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT 61 + 10 * - col0 FROM tab2 AS cor0
----
-719
-729
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-7382
SELECT DISTINCT col0 DIV + col2 - col0 FROM tab0 AS cor0
----
-24
-88
0

skipif mysql # not compatible
query I rowsort label-7382
SELECT DISTINCT col0 / + col2 - col0 FROM tab0 AS cor0
----
-24
-88
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 27 ) * - col2 + - ( + col0 ) col2 FROM tab2 AS cor0
----
-1105
-736
-780

query I rowsort
SELECT ALL + - ( col0 ) * col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT 18 * cor0.col2 * col2 + col1 FROM tab1 AS cor0
----
165901
52514
58492

query I rowsort
SELECT DISTINCT + col1 * col0 + + col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT - + col0 - col0 AS col2 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT ALL + 5 * + col1 FROM tab0 AS cor0
----
430
455
485

query I rowsort
SELECT - col0 + col2 + - col0 * - col2 FROM tab2 AS cor0
----
1976
209
2961

onlyif mysql # use DIV operator for integer division
query I rowsort label-7390
SELECT DISTINCT + tab0.col0 * col2 DIV + col2 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-7390
SELECT DISTINCT + tab0.col0 * col2 / + col2 FROM tab0
----
24
35
89

query I rowsort
SELECT - col0 * col1 * - 31 AS col0 FROM tab1 AS cor0
----
19840
2418
32240

query I rowsort
SELECT ALL - col2 * col2 * - ( + col0 ) + col2 + ( 17 ) AS col0 FROM tab1 AS cor0
----
208010
737393
8819

query I rowsort
SELECT DISTINCT 31 + - cor0.col0 FROM tab1 cor0
----
-33
-49
28

query I rowsort
SELECT - 36 + - col2 FROM tab2 AS cor0
----
-62
-63
-74

onlyif mysql # use DIV operator for integer division
query I rowsort label-7395
SELECT ALL - col1 DIV col0 AS col0 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-7395
SELECT ALL - col1 / col0 AS col0 FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT ALL + + 18 * - col1 FROM tab1 AS cor0
----
-180
-234
-468

query I rowsort
SELECT + col2 * col1 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT ALL - + 59 * col1 FROM tab2 AS cor0
----
-1003
-1829
-3481

query I rowsort
SELECT ALL - cor0.col1 * col1 + cor0.col2 AS col2 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT ALL - col0 * ( col2 ) * + col1 + + cor0.col2 FROM tab2 AS cor0
----
-119626
-50996
-5832

query I rowsort
SELECT + col2 * + ( col0 ) * col0 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT DISTINCT - col2 + + 72 * cor0.col1 FROM tab0 AS cor0
----
6159
6470
6983

query I rowsort
SELECT + col1 + col0 * + ( col2 ) FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL ( col0 ) + col1 * col1 FROM tab0
----
7420
8370
9444

query I rowsort
SELECT - cor1.col1 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT ( 33 ) * col0 + + col2 AS col0 FROM tab1 AS cor0
----
153
2169
2736

query I rowsort
SELECT col0 - + 61 AS col0 FROM tab1 cor0
----
-58
19
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-7408
SELECT ALL + ( col2 ) DIV + col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-7408
SELECT ALL + ( col2 ) / + col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT ALL - + 45 * ( col0 ) AS col0 FROM tab0 AS cor0
----
-1080
-1575
-4005

query I rowsort
SELECT DISTINCT - ( 97 ) * + cor0.col2 AS col1 FROM tab1 AS cor0
----
-5238
-5529
-9312

query I rowsort
SELECT - ( - cor0.col0 ) * col0 AS col1 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT col0 * - col1 * col0 AS col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 72 + col0 * col1 col0 FROM tab2 AS cor0
----
1415
289
4674

onlyif mysql # use DIV operator for integer division
query I rowsort label-7414
SELECT - col2 DIV - col1 - - col2 FROM tab1 AS cor0
----
103
56
62

skipif mysql # not compatible
query I rowsort label-7414
SELECT - col2 / - col1 - - col2 FROM tab1 AS cor0
----
103
56
62

query I rowsort
SELECT ALL - + 59 AS col2 FROM tab2 AS cor0
----
-59
-59
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7416
SELECT DISTINCT - CAST( NULL AS SIGNED ) * col2 + - col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7416
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * col2 + - col2 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * ( col0 ) col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-7418
SELECT DISTINCT - 74 DIV - 66 col2 FROM tab2 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7418
SELECT DISTINCT - 74 / - 66 col2 FROM tab2 AS cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7419
SELECT 35 DIV - 92 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7419
SELECT 35 / - 92 AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7420
SELECT + col0 * col0 + - col2 DIV col1 FROM tab0 AS cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-7420
SELECT + col0 * col0 + - col2 / col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT + col0 + cor0.col1 * + col2 + 67 * col2 FROM tab2 cor0
----
2653
3271
3354

query I rowsort
SELECT DISTINCT + col2 + 59 AS col1 FROM tab2
----
85
86
97

query I rowsort
SELECT DISTINCT + col2 * - 51 + ( col0 ) * + col2 * + col1 AS col2 FROM tab1 AS cor0
----
1458
33573
94944

query I rowsort
SELECT ALL + col2 * 63 AS col0 FROM tab1 AS cor0
----
3402
3591
6048

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + col2 * - CAST ( + ( col1 ) AS REAL ) + + ( - col1 * + col1 ) AS col2 FROM tab0 AS cor0
----
-4558
-819
-9312

query I rowsort
SELECT - 92 * - col2 - tab0.col2 FROM tab0
----
3003
7462
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-7427
SELECT col2 DIV + 1 col0 FROM tab1
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7427
SELECT col2 / + 1 col0 FROM tab1
----
54
57
96

query I rowsort
SELECT - col1 * 38 FROM tab0
----
-3268
-3458
-3686

query I rowsort
SELECT DISTINCT col0 + - col0 + - col0 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT ( - col2 ) * col0 + + 62 * - col1 AS col2 FROM tab1 AS cor0
----
-1774
-4268
-8486

query I rowsort
SELECT + 46 + - col2 AS col1 FROM tab1 AS cor0
----
-11
-50
-8

query I rowsort
SELECT ALL - 64 * - 30 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to ae238516e1b5d49657112c7f27bba6ea

query I rowsort
SELECT DISTINCT tab0.col2 - 47 FROM tab0
----
-14
-46
35

query I rowsort
SELECT DISTINCT + col2 * + col0 + - tab0.col2 FROM tab0
----
34
7216
759

query I rowsort
SELECT DISTINCT - cor0.col1 AS col1 FROM tab0, tab2 cor0, tab2 AS cor1
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - tab2.col2 + - 58 * - col2 FROM tab2
----
1482
1539
2166

query I rowsort
SELECT - col1 + col1 + + tab0.col0 AS col0 FROM tab0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7438
SELECT - tab0.col0 DIV - ( + col2 + - tab0.col0 * - col0 ) AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7438
SELECT - tab0.col0 / - ( + col2 + - tab0.col0 * - col0 ) AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT + col0 * col0 + + 75 AS col2 FROM tab0
----
1300
651
7996

query I rowsort
SELECT - - col1 * col2 + + col2 AS col0 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT - ( - 50 ) * + col0 + + col1 * col0 AS col2 FROM tab1 AS cor0
----
228
3840
5040

query I rowsort
SELECT DISTINCT 25 FROM tab1, tab0, tab1 AS cor0
----
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * tab0.col1 col2 FROM tab0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-7444
SELECT DISTINCT - 89 DIV - cor0.col2 AS col0 FROM tab0, tab0 cor0, tab0 AS cor1
----
1
2
89

skipif mysql # not compatible
query I rowsort label-7444
SELECT DISTINCT - 89 / - cor0.col2 AS col0 FROM tab0, tab0 cor0, tab0 AS cor1
----
1
2
89

query I rowsort
SELECT ALL + ( - col0 ) * - 31 AS col2 FROM tab2 AS cor0
----
217
2418
2449

query I rowsort
SELECT + col0 * col0 + + col0 * col0 AS col1 FROM tab2 AS cor0
----
12168
12482
98

query I rowsort
SELECT - 64 * cor0.col2 * + col2 FROM tab0 cor0
----
-430336
-64
-69696

query I rowsort
SELECT 98 * - col2 * col1 AS col1 FROM tab1
----
-122304
-137592
-55860

query I rowsort
SELECT + 91 FROM tab0, tab2, tab1 cor0
----
27 values hashing to deebbcfb9c7803a34dca6bd860849afe

onlyif mysql # use DIV operator for integer division
query I rowsort label-7450
SELECT DISTINCT col2 DIV col1 + - 51 FROM tab2 cor0
----
-49
-51

skipif mysql # not compatible
query I rowsort label-7450
SELECT DISTINCT col2 / col1 + - 51 FROM tab2 cor0
----
-49
-51

query I rowsort
SELECT ALL - - cor0.col2 * col1 + - col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 * 16 - cor0.col0 FROM tab1 AS cor0
----
1200
45
960

query I rowsort
SELECT - col1 * ( 61 ) FROM tab0 cor0
----
-5246
-5551
-5917

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7454
SELECT DISTINCT col0 * + CAST( NULL AS SIGNED ) * col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-7454
SELECT DISTINCT col0 * + CAST ( NULL AS INTEGER ) * col2 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 * - 78 col1 FROM tab1 AS cor0
----
-1014
-2028
-780

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7456
SELECT - col2 + CAST( - col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-104
-117
-34

skipif mysql # not compatible
query I rowsort label-7456
SELECT - col2 + CAST ( - col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-104
-117
-34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col0 col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL + - col2 + 73 FROM tab0 AS cor0
----
-9
40
72

query I rowsort
SELECT ALL + - col2 * 48 + col2 * - col2 FROM tab2 AS cor0
----
-1924
-2025
-3268

query I rowsort
SELECT DISTINCT - cor0.col1 * + 42 + - 35 AS col0 FROM tab2 AS cor0
----
-1337
-2513
-749

query I rowsort
SELECT cor0.col2 - - ( - col2 ) * - col1 AS col0 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + - col0 + col0 * + col0 AS col0 FROM tab1 cor0
----
4032
6
6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * - col1 col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + col2 + col1 * + 80 FROM tab1 AS cor0
----
1136
2134
857

query I rowsort
SELECT DISTINCT col2 * ( ( col1 ) ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - col2 * col0 * col0 AS col2 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT - col1 * - col2 + col2 AS col1 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7468
SELECT ALL - col2 + + col0 * - col0 + - col1 DIV + 67 FROM tab0 cor0
----
-1227
-610
-8004

skipif mysql # not compatible
query I rowsort label-7468
SELECT ALL - col2 + + col0 * - col0 + - col1 / + 67 FROM tab0 cor0
----
-1227
-610
-8004

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col2 + col2 col0 FROM tab2 AS cor0
----
-1508
-608
-810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7470
SELECT ALL col1 + - tab1.col1 - + CAST( col1 AS SIGNED ) * col0 col0 FROM tab1
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7470
SELECT ALL col1 + - tab1.col1 - + CAST ( col1 AS INTEGER ) * col0 col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT + col2 * + col0 + 37 AS col1 FROM tab0
----
72
7335
829

onlyif mysql # use DIV operator for integer division
query I rowsort label-7472
SELECT ALL tab2.col0 * col2 DIV col1 AS col2 FROM tab2
----
176
34
6

skipif mysql # not compatible
query I rowsort label-7472
SELECT ALL tab2.col0 * col2 / col1 AS col2 FROM tab2
----
176
34
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-7473
SELECT + + col0 DIV - 11 AS col2 FROM tab0 AS cor0
----
-2
-3
-8

skipif mysql # not compatible
query I rowsort label-7473
SELECT + + col0 / - 11 AS col2 FROM tab0 AS cor0
----
-2
-3
-8

query I rowsort
SELECT - col0 * + ( cor0.col0 ) AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-7475
SELECT + 90 DIV + col1 AS col2 FROM tab1 AS cor0
----
3
6
9

skipif mysql # not compatible
query I rowsort label-7475
SELECT + 90 / + col1 AS col2 FROM tab1 AS cor0
----
3
6
9

query I rowsort
SELECT ALL - col0 + - 45 FROM tab1 AS cor0
----
-109
-125
-48

query I rowsort
SELECT cor0.col1 + tab1.col0 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to af3a539c18b07c0d2d3147e1b73e81ac

query I rowsort
SELECT ALL + 61 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 07149905a72bd87553381f34d19ed290

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7479
SELECT DISTINCT + col1 + - col2 * col1 * + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7479
SELECT DISTINCT + col1 + - col2 * col1 * + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col0 ) col2 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7481
SELECT ALL - ( - ( + tab1.col1 ) ) DIV + CAST( 3 * col0 AS SIGNED ) AS col0 FROM tab1
----
0
0
2

skipif mysql # not compatible
query I rowsort label-7481
SELECT ALL - ( - ( + tab1.col1 ) ) / + CAST ( 3 * col0 AS INTEGER ) AS col0 FROM tab1
----
0
0
2

query I rowsort
SELECT DISTINCT 85 * - ( + col0 ) AS col0 FROM tab1
----
-255
-5440
-6800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 54 * - col2 + col2 * col2 col2 FROM tab1
----
0
171
4032

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col1 ) col1 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT col1 * + col0 + - 20 * + 88 + + col2 AS col1 FROM tab1 cor0
----
-1063
-1628
-624

query I rowsort
SELECT DISTINCT + - cor0.col0 - col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT - 72 * + col1 FROM tab2 cor0
----
-1224
-2232
-4248

query I rowsort
SELECT ALL - - col2 + col1 * - ( + col0 ) * col1 AS col1 FROM tab1 AS cor0
----
-13424
-1974
-6343

query I rowsort
SELECT - 94 * col2 + + col2 AS col2 FROM tab0
----
-3069
-7626
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7490
SELECT + + CAST( NULL AS SIGNED ) FROM tab0, tab1, tab1 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7490
SELECT + + CAST ( NULL AS INTEGER ) FROM tab0, tab1, tab1 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ( col0 * + tab1.col2 ) AS col1 FROM tab1
----
162
3648
7680

query I rowsort
SELECT 23 * col2 - tab0.col2 AS col0 FROM tab0
----
1804
22
726

query I rowsort
SELECT DISTINCT 90 + tab1.col1 AS col2 FROM tab1
----
100
103
116

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7494
SELECT CAST( NULL AS SIGNED ) FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7494
SELECT CAST ( NULL AS INTEGER ) FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - col1 + - col2 * ( tab0.col2 * + col2 ) FROM tab0
----
-36023
-551459
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7496
SELECT ALL - - 55 DIV - col0 + + cor0.col2 FROM tab1 cor0
----
36
57
96

skipif mysql # not compatible
query I rowsort label-7496
SELECT ALL - - 55 / - col0 + + cor0.col2 FROM tab1 cor0
----
36
57
96

query I rowsort
SELECT ALL - col0 * + col2 + + col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT + ( + col0 ) + col2 FROM tab0 AS cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 27 + col2 col2 FROM tab0 AS cor0
----
109
28
60

query I rowsort
SELECT ALL + col1 * - cor0.col2 + + cor0.col0 AS col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT + 31 * col1 FROM tab2 cor0
----
1829
527
961

query I rowsort
SELECT - cor0.col2 + 63 - 38 * cor0.col0 FROM tab1 cor0
----
-105
-2426
-3073

query I rowsort
SELECT - + col1 * + cor0.col0 + col0 AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT col0 * - 61 + - col1 FROM tab2 AS cor0
----
-458
-4817
-4836

query I rowsort
SELECT + - col2 * - 88 AS col0 FROM tab2 AS cor0
----
2288
2376
3344

query I rowsort
SELECT + col1 + col2 - - col0 FROM tab1 AS cor0
----
131
189
83

query I rowsort
SELECT ALL + col1 * 36 AS col2 FROM tab0 cor0
----
3096
3276
3492

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7508
SELECT DISTINCT - CAST( + col1 AS SIGNED ) + col0 AS col2 FROM tab1 AS cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-7508
SELECT DISTINCT - CAST ( + col1 AS INTEGER ) + col0 AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL + 89 * col0 - + col1 AS col0 FROM tab2 cor0
----
592
6883
7014

query I rowsort
SELECT - - 81 * - col1 FROM tab2 AS cor0
----
-1377
-2511
-4779

query I rowsort
SELECT 56 * col2 + - col1 AS col0 FROM tab1 AS cor0
----
2998
3182
5363

query I rowsort
SELECT DISTINCT - col2 * 31 * col2 FROM tab1
----
-100719
-285696
-90396

query I rowsort
SELECT DISTINCT + 34 FROM tab1, tab2 cor0
----
34

query I rowsort
SELECT - 97 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to e4a6bd848a69226cbb7ad3d154be321b

query I rowsort
SELECT ALL + 1 - ( + col0 ) FROM tab2 AS cor0
----
-6
-77
-78

query I rowsort
SELECT DISTINCT + col2 + + 69 * col1 FROM tab0 AS cor0
----
5967
6361
6694

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL NOT IN ( tab1.col2 )
----

query I rowsort
SELECT DISTINCT col2 + tab0.col2 + - col1 AS col1 FROM tab0
----
-20
-95
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col2 - col0 col2 FROM tab0
----
2814
62
7373

query I rowsort
SELECT + col0 + col0 AS col2 FROM tab2 WHERE ( col2 + col1 ) NOT BETWEEN col2 AND ( NULL )
----

query I rowsort
SELECT + tab0.col0 * + col1 * - col2 AS col2 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT + col2 * + col2 * col0 AS col0 FROM tab1 WHERE NULL NOT IN ( + col2 * + col2 * - col1 )
----

query I rowsort
SELECT ALL + col0 * + col2 + col1 - - col0 FROM tab0
----
167
7478
902

query I rowsort
SELECT DISTINCT col0 * + tab2.col2 + + col1 AS col0 FROM tab2
----
2087
220
3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col2 + + tab0.col0 col0 FROM tab0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7526
SELECT col2 DIV + col2 + + col1 AS col2 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-7526
SELECT col2 / + col2 + + col1 AS col2 FROM tab0
----
87
92
98

query I rowsort
SELECT ALL col1 * - col1 - col0 AS col0 FROM tab1
----
-164
-249
-679

onlyif mysql # use DIV operator for integer division
query I rowsort label-7528
SELECT - col0 DIV col1 + + col2 AS col2 FROM tab2
----
25
27
34

skipif mysql # not compatible
query I rowsort label-7528
SELECT - col0 / col1 + + col2 AS col2 FROM tab2
----
25
27
34

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT ( NULL ) NOT BETWEEN + col2 * - col2 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7530
SELECT + col1 - col1 DIV + col0 FROM tab1
----
10
13
18

skipif mysql # not compatible
query I rowsort label-7530
SELECT + col1 - col1 / + col0 FROM tab1
----
10
13
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-7531
SELECT DISTINCT col0 * - col0 DIV + col0 FROM tab2
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-7531
SELECT DISTINCT col0 * - col0 / + col0 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT col0 * col0 * col0 + + col1 * col1 + + col2 FROM tab2
----
1331
478059
493366

query I rowsort
SELECT col2 * col1 + + col2 + - col2 * col1 AS col2 FROM tab1
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7534
SELECT DISTINCT tab2.col0 * col1 DIV - col1 FROM tab2
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-7534
SELECT DISTINCT tab2.col0 * col1 / - col1 FROM tab2
----
-7
-78
-79

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT col2 * + tab0.col2 - col0 * + col1 * + col2 BETWEEN NULL AND NULL
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE - col1 - + col0 BETWEEN NULL AND + col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7537
SELECT + col2 * - col2 + col2 DIV - col2 + col2 FROM tab0
----
-1
-1057
-6643

skipif mysql # not compatible
query I rowsort label-7537
SELECT + col2 * - col2 + col2 / - col2 + col2 FROM tab0
----
-1
-1057
-6643

query I rowsort
SELECT DISTINCT - tab0.col1 FROM tab0 WHERE ( NULL ) <> ( NULL )
----

query I rowsort
SELECT ALL - col0 FROM tab0 WHERE NULL <> ( NULL )
----

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT ( NULL ) IN ( + col2 * col1 * + col0 + col0 * tab1.col2 )
----

query I rowsort
SELECT ALL cor0.col1 + - col2 * - col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT + col1 + - col1 * col2 + - col0 AS col1 FROM tab2 cor0
----
-1553
-708
-813

onlyif mysql # use DIV operator for integer division
query I rowsort label-7543
SELECT DISTINCT - col2 + + col1 DIV + col2 FROM tab0 cor0
----
-31
-81
96

skipif mysql # not compatible
query I rowsort label-7543
SELECT DISTINCT - col2 + + col1 / + col2 FROM tab0 cor0
----
-31
-81
96

query I rowsort
SELECT DISTINCT - col0 * col1 - col2 * col1 AS col0 FROM tab0 AS cor0
----
-15561
-3492
-4902

query I rowsort
SELECT - col0 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-7546
SELECT ALL + col2 + - cor0.col1 DIV + col2 AS col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-7546
SELECT ALL + col2 + - cor0.col1 / + col2 AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + cor0.col1 * + col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 AS cor0 CROSS JOIN tab1 WHERE NOT NULL IN ( tab1.col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * tab2.col2 col0 FROM tab2
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * col0 col2 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT - col1 + - 77 * + 23 FROM tab1 AS cor0
----
-1781
-1784
-1797

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * - 49 * 52 col0 FROM tab0 AS cor0
----
-219128
-231868
-247156

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + - col1 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - col2 + - col1 * 43 AS col2 FROM tab2 cor0
----
-1306
-2511
-693

query I rowsort
SELECT col0 + + 94 AS col2 FROM tab2 cor0
----
101
172
173

query I rowsort
SELECT ALL + 0 * + col0 FROM tab0 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7557
SELECT DISTINCT - - col0 + col0 DIV - cor0.col1 AS col1 FROM tab1 AS cor0
----
3
58
74

skipif mysql # not compatible
query I rowsort label-7557
SELECT DISTINCT - - col0 + col0 / - cor0.col1 AS col1 FROM tab1 AS cor0
----
3
58
74

query I rowsort
SELECT 67 FROM tab0, tab1 cor0
----
9 values hashing to b56f8a4f1fcebc9802481256df61e97c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 32 col1 FROM tab0 cor0 CROSS JOIN tab2, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 6bef041528d0147be26f7de162c66a5f

onlyif mysql # use DIV operator for integer division
query I rowsort label-7560
SELECT ALL + col2 DIV 98 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7560
SELECT ALL + col2 / 98 FROM tab2
----
0
0
0

query I rowsort
SELECT - 87 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 84bcab58a965cc8ae97b39d2d01b3d23

query I rowsort
SELECT col2 * - cor0.col0 * col0 + - col0 AS col0 FROM tab1 AS cor0
----
-233536
-489
-614480

query I rowsort
SELECT + 86 + + col1 FROM tab2 AS cor0
----
103
117
145

onlyif mysql # use DIV operator for integer division
query I rowsort label-7564
SELECT - col0 + - cor0.col2 DIV + col0 FROM tab2 AS cor0
----
-10
-78
-79

skipif mysql # not compatible
query I rowsort label-7564
SELECT - col0 + - cor0.col2 / + col0 FROM tab2 AS cor0
----
-10
-78
-79

query I rowsort
SELECT - col1 * col2 * col1 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT - + cor0.col0 + + cor0.col2 + col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL + - 34 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 5b88331e40da4796cc4826c442aa45f7

onlyif mysql # use DIV operator for integer division
query I rowsort label-7568
SELECT ALL + col2 * - col2 DIV + col2 + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7568
SELECT ALL + col2 * - col2 / + col2 + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 81 * - cor0.col1 AS col0 FROM tab0, tab0 AS cor0
----
-6966
-7371
-7857

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 94 * - col1 col0 FROM tab1 AS cor0
----
-1222
-2444
-940

query I rowsort
SELECT DISTINCT - cor0.col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
-3
-64
-80

query I rowsort
SELECT ALL - 4 * col1 AS col1 FROM tab1
----
-104
-40
-52

query I rowsort
SELECT - - ( - ( col1 ) ) AS col1 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7574
SELECT ALL - CAST( - col1 AS SIGNED ) + col2 * - col0 * + col0 + cor0.col2 FROM tab1 AS cor0
----
-233405
-406
-614291

skipif mysql # not compatible
query I rowsort label-7574
SELECT ALL - CAST ( - col1 AS INTEGER ) + col2 * - col0 * + col0 + cor0.col2 FROM tab1 AS cor0
----
-233405
-406
-614291

query I rowsort
SELECT DISTINCT - 89 * col0 AS col0 FROM tab1 AS cor0
----
-267
-5696
-7120

query I rowsort
SELECT - + 92 AS col2 FROM tab2 AS cor0
----
-92
-92
-92

query I rowsort
SELECT 55 - - col1 FROM tab2
----
114
72
86

onlyif mysql # use DIV operator for integer division
query I rowsort label-7578
SELECT DISTINCT + 53 DIV - col1 + + 12 + col1 * col2 * col2 AS col1 FROM tab0
----
109
611896
93666

skipif mysql # not compatible
query I rowsort label-7578
SELECT DISTINCT + 53 / - col1 + + 12 + col1 * col2 * col2 AS col1 FROM tab0
----
109
611896
93666

query I rowsort
SELECT col0 * tab1.col0 + - 58 AS col1 FROM tab1
----
-49
4038
6342

query I rowsort
SELECT + col0 * col2 * cor0.col1 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT DISTINCT + 17 + col0 + + 28 FROM tab1
----
109
125
48

query I rowsort
SELECT col1 + col0 + - ( + col0 ) AS col1 FROM tab0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7583
SELECT - tab0.col1 + - tab0.col0 * + CAST( 13 AS SIGNED ) AS col1 FROM tab0
----
-1248
-398
-552

skipif mysql # not compatible
query I rowsort label-7583
SELECT - tab0.col1 + - tab0.col0 * + CAST ( 13 AS INTEGER ) AS col1 FROM tab0
----
-1248
-398
-552

query I rowsort
SELECT + - col0 * - col2 - + col0 FROM tab0 AS cor0
----
0
7209
768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col2 col2 FROM tab2 cor0
----
-52
-54
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-7586
SELECT DISTINCT + - col0 DIV 53 AS col2 FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-7586
SELECT DISTINCT + - col0 / 53 AS col2 FROM tab0 AS cor0
----
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7587
SELECT DISTINCT + col0 * CAST( cor0.col0 AS SIGNED ) + - col1 * - col0 * cor0.col0 + + cor0.col2 FROM tab2 AS cor0
----
112376
1595
365066

skipif mysql # not compatible
query I rowsort label-7587
SELECT DISTINCT + col0 * CAST ( cor0.col0 AS INTEGER ) + - col1 * - col0 * cor0.col0 + + cor0.col2 FROM tab2 AS cor0
----
112376
1595
365066

onlyif mysql # use DIV operator for integer division
query I rowsort label-7588
SELECT + col0 + col2 DIV + 32 AS col2 FROM tab0 AS cor0
----
25
35
91

skipif mysql # not compatible
query I rowsort label-7588
SELECT + col0 + col2 / + 32 AS col2 FROM tab0 AS cor0
----
25
35
91

query I rowsort
SELECT - col2 + 25 AS col0 FROM tab2 AS cor0
----
-1
-13
-2

query I rowsort
SELECT ALL - col1 * 42 FROM tab2 AS cor0
----
-1302
-2478
-714

query I rowsort
SELECT - + col2 * 63 AS col1 FROM tab0 AS cor0
----
-2079
-5166
-63

query I rowsort
SELECT DISTINCT - col0 * + cor0.col1 + + col0 + col0 FROM tab2 AS cor0
----
-1185
-203
-4446

onlyif mysql # use DIV operator for integer division
query I rowsort label-7593
SELECT ALL col2 DIV tab2.col1 AS col1 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-7593
SELECT ALL col2 / tab2.col1 AS col1 FROM tab2
----
0
0
2

query I rowsort
SELECT + col1 + + col1 * + col0 + col2 * col1 AS col0 FROM tab0 AS cor0
----
15652
3589
4988

query I rowsort
SELECT DISTINCT col1 * col1 + col0 * + col1 FROM tab0 AS cor0
----
12804
16380
9460

query I rowsort
SELECT DISTINCT + col0 + - col1 - - tab1.col1 FROM tab1
----
3
64
80

query I rowsort
SELECT - col1 + + cor0.col2 + + col1 AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + col2 * col2 + + col1 FROM tab2
----
1461
735
760

onlyif mysql # use DIV operator for integer division
query I rowsort label-7599
SELECT col2 * col0 DIV - col0 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-7599
SELECT col2 * col0 / - col0 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-7600
SELECT - col0 - col1 DIV col0 FROM tab2
----
-11
-78
-79

skipif mysql # not compatible
query I rowsort label-7600
SELECT - col0 - col1 / col0 FROM tab2
----
-11
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - col0 + col2 col0 FROM tab1
----
29
3
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-7602
SELECT DISTINCT + col0 + + col2 + + col0 DIV + tab1.col2 FROM tab1
----
122
176
57

skipif mysql # not compatible
query I rowsort label-7602
SELECT DISTINCT + col0 + + col2 + + col0 / + tab1.col2 FROM tab1
----
122
176
57

query I rowsort
SELECT - col0 * col2 + - col0 + + col2 AS col2 FROM tab2 AS cor0
----
-169
-2080
-3043

query I rowsort
SELECT + col2 * col1 * cor0.col1 + - col2 * col1 + col0 * - col1 AS col0 FROM tab0 AS cor0
----
239166
5917
663481

query I rowsort
SELECT DISTINCT + tab1.col2 * + col2 AS col2 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT - col0 * - col1 + - col0 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT col1 + + tab2.col1 * col1 FROM tab2
----
306
3540
992

query I rowsort
SELECT + col0 + col0 * col1 AS col2 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT col2 * - tab0.col1 * + col1 AS col1 FROM tab0
----
-244068
-679042
-9409

query I rowsort
SELECT ALL - col2 - + col2 FROM tab2 cor0
----
-52
-54
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-7611
SELECT col0 DIV col1 - + col2 FROM tab1 AS cor0
----
-51
-54
-90

skipif mysql # not compatible
query I rowsort label-7611
SELECT col0 / col1 - + col2 FROM tab1 AS cor0
----
-51
-54
-90

query I rowsort
SELECT DISTINCT 70 + - col1 FROM tab2 AS cor0
----
11
39
53

query I rowsort
SELECT DISTINCT + col0 * - col0 + cor0.col0 FROM tab0 cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT - 39 + cor0.col0 AS col2 FROM tab1 AS cor0
----
-36
25
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-7615
SELECT DISTINCT col0 * + col2 * + col1 + col1 DIV col1 AS col2 FROM tab2 AS cor0
----
119653
51035
5860

skipif mysql # not compatible
query I rowsort label-7615
SELECT DISTINCT col0 * + col2 * + col1 + col1 / col1 AS col2 FROM tab2 AS cor0
----
119653
51035
5860

query I rowsort
SELECT ALL - col1 * cor0.col0 + - col1 FROM tab0 cor0
----
-2150
-3492
-8190

query I rowsort
SELECT ALL - - col0 + + col1 * col1 AS col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT DISTINCT col1 * + col0 * - cor0.col2 + col1 AS col1 FROM tab1 AS cor0
----
-36470
-4186
-99827

query I rowsort
SELECT DISTINCT - 31 * + col1 FROM tab0 cor0
----
-2666
-2821
-3007

query I rowsort
SELECT + 7 + - cor0.col0 + + col1 * cor0.col1 * + col2 AS col0 FROM tab2 AS cor0
----
10910
25947
90435

onlyif mysql # use DIV operator for integer division
query I rowsort label-7621
SELECT cor0.col0 * col1 + cor0.col1 DIV - col1 FROM tab1 AS cor0
----
1039
639
77

skipif mysql # not compatible
query I rowsort label-7621
SELECT cor0.col0 * col1 + cor0.col1 / - col1 FROM tab1 AS cor0
----
1039
639
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-7622
SELECT + col0 + col2 DIV cor0.col1 AS col2 FROM tab1 AS cor0
----
5
69
87

skipif mysql # not compatible
query I rowsort label-7622
SELECT + col0 + col2 / cor0.col1 AS col2 FROM tab1 AS cor0
----
5
69
87

query I rowsort
SELECT ALL + col0 * col2 * col0 + col1 AS col0 FROM tab2 AS cor0
----
1354
158243
237175

query I rowsort
SELECT - 9 AS col2 FROM tab0 AS cor0
----
-9
-9
-9

query I rowsort
SELECT + + 64 + col0 * col0 AS col0 FROM tab2 AS cor0
----
113
6148
6305

query I rowsort
SELECT ALL - col0 - col1 * - cor0.col2 FROM tab1 AS cor0
----
1168
1401
506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 85 + + col1 col0 FROM tab1 AS cor0
----
-59
-72
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-7628
SELECT col1 DIV - col1 + + col2 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-7628
SELECT col1 / - col1 + + col2 FROM tab0
----
0
32
81

query I rowsort
SELECT ALL - 94 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to a95bfa539191d3f72f6548147d7efb9e

onlyif mysql # use DIV operator for integer division
query I rowsort label-7630
SELECT col0 DIV - col0 + col0 + col0 AS col0 FROM tab0
----
177
47
69

skipif mysql # not compatible
query I rowsort label-7630
SELECT col0 / - col0 + col0 + col0 AS col0 FROM tab0
----
177
47
69

query I rowsort
SELECT ALL - - cor0.col2 * col2 + col0 AS col0 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT DISTINCT 61 * col0 + + col2 + col1 AS col1 FROM tab1 AS cor0
----
263
3971
4989

query I rowsort
SELECT ALL col2 * - col0 * + 22 AS col1 FROM tab1 cor0
----
-168960
-3564
-80256

query I rowsort
SELECT + - 86 + - col0 FROM tab1 AS cor0
----
-150
-166
-89

query I rowsort
SELECT DISTINCT cor1.col1 FROM tab2 cor0 CROSS JOIN tab1, tab2 AS cor1
----
17
31
59

query I rowsort
SELECT DISTINCT + cor0.col1 * - col2 - col0 FROM tab0 cor0
----
-132
-2862
-7551

query I rowsort
SELECT - - col2 + - 38 FROM tab0 cor0
----
-37
-5
44

query I rowsort
SELECT ALL - - cor0.col0 * col2 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT col1 + + ( col0 ) FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT - col2 + - 0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT 39 FROM tab1, tab1 AS cor0
----
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 70 col1 FROM tab0
----
70
70
70

query I rowsort
SELECT + 79 FROM tab2, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to da0116d31b8af0da9f685c090d378baf

query I rowsort
SELECT col1 + 19 AS col1 FROM tab0 cor0
----
105
110
116

query I rowsort
SELECT col2 * col1 + col2 * col2 AS col2 FROM tab0 AS cor0
----
14186
3927
98

query I rowsort
SELECT ALL - - ( col1 ) + col1 AS col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT + ( col0 ) * + col2 AS col1 FROM tab1 AS cor0
----
162
3648
7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * - col1 - col1 * - col2 col1 FROM tab1 cor0
----
-70
1326
208

query I rowsort
SELECT DISTINCT - col1 - - cor0.col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT 30 AS col2 FROM tab1, tab2 cor0
----
30

query I rowsort
SELECT + - 49 + col2 * - col1 AS col0 FROM tab2 cor0
----
-1583
-695
-886

query I rowsort
SELECT col2 * + cor0.col0 + - col2 * + col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 21 - - tab0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to c327fc3b4ad0ae54e494ca2ffc18b6ae

query I rowsort
SELECT ( - col2 ) * + cor0.col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 75 col2 FROM tab1
----
75

query I rowsort
SELECT + cor1.col1 AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + - col1 * col1 + + col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT DISTINCT cor0.col2 * - 61 FROM tab2 AS cor0
----
-1586
-1647
-2318

query I rowsort
SELECT + + col2 * + col1 + + col2 AS col2 FROM tab2 cor0
----
1560
684
864

query I rowsort
SELECT + col1 * col1 + 22 AS col0 FROM tab2 AS cor0
----
311
3503
983

query I rowsort
SELECT 23 + 59 * col2 FROM tab2 AS cor0
----
1557
1616
2265

query I rowsort
SELECT col1 * + 1 + - col0 AS col0 FROM tab2
----
-19
-62
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7663
SELECT - + 89 + 92 + col1 * CAST( + ( - col0 ) AS SIGNED ) col1 FROM tab1 AS cor0
----
-1037
-637
-75

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7663
SELECT - + 89 + 92 + col1 * CAST ( + ( - col0 ) AS INTEGER ) col1 FROM tab1 AS cor0
----
-1037
-637
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-7664
SELECT + 19 + col2 * col2 DIV - col0 AS col1 FROM tab1 AS cor0
----
-31
-953
-96

skipif mysql # not compatible
query I rowsort label-7664
SELECT + 19 + col2 * col2 / - col0 AS col1 FROM tab1 AS cor0
----
-31
-953
-96

query I rowsort
SELECT - - 9 * - col2 + col1 AS col0 FROM tab0 AS cor0
----
-211
-647
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-7666
SELECT ALL - cor0.col0 DIV 54 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to b2e225572af74ba853e10fb5414ea67f

skipif mysql # not compatible
query I rowsort label-7666
SELECT ALL - cor0.col0 / 54 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to b2e225572af74ba853e10fb5414ea67f

query I rowsort
SELECT ALL - col0 * - cor0.col0 - - 34 FROM tab0 AS cor0
----
1259
610
7955

query I rowsort
SELECT ALL + 95 AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT DISTINCT - col0 - ( 60 ) AS col2 FROM tab1 AS cor0
----
-124
-140
-63

query I rowsort
SELECT DISTINCT + - col0 + 90 * + 16 AS col0 FROM tab0 cor0
----
1351
1405
1416

query I rowsort
SELECT - ( col1 * 97 ) + + col1 AS col1 FROM tab1
----
-1248
-2496
-960

query I rowsort
SELECT + 41 * 61 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 5f5e99bd8eb4acc23e4764c4f44dd5e5

query I rowsort
SELECT ALL + tab2.col1 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT - col2 + ( col1 ) * col1 AS col0 FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT cor0.col0 * ( - col1 ) + - col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT ALL - col0 - + ( + col0 ) FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT + col0 + cor0.col0 + col2 FROM tab1 AS cor0
----
185
256
60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7678
SELECT ALL - CAST( + col1 AS SIGNED ) * col0 AS col1 FROM tab2
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-7678
SELECT ALL - CAST ( + col1 AS INTEGER ) * col0 AS col1 FROM tab2
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7679
SELECT ALL CAST( tab0.col0 AS SIGNED ) FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

skipif mysql # not compatible
query I rowsort label-7679
SELECT ALL CAST ( tab0.col0 AS INTEGER ) FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + col0 * 18 FROM tab1
----
1152
1440
54

query I rowsort
SELECT + 57 + 57 * cor0.col1 FROM tab1 AS cor0
----
1539
627
798

query I rowsort
SELECT - ( col0 ) * col2 + + col1 * col2 * col1 AS col0 FROM tab2 cor0
----
25758
7980
88478

query I rowsort
SELECT 67 + col2 FROM tab1 AS cor0
----
121
124
163

query I rowsort
SELECT + col1 + col0 * + ( + 0 ) AS col2 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - + col1 * col1 - - 57 * col2 * + col1 FROM tab0 AS cor0
----
-3880
154370
417053

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 27 + col0 * col2 col2 FROM tab0 AS cor0
----
7271
765
8

query I rowsort
SELECT ( + col0 ) * + col1 AS col1 FROM tab0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7688
SELECT col1 - col1 * CAST( + col2 AS SIGNED ) FROM tab0 AS cor0
----
-2752
-7371
0

skipif mysql # not compatible
query I rowsort label-7688
SELECT col1 - col1 * CAST ( + col2 AS INTEGER ) FROM tab0 AS cor0
----
-2752
-7371
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7689
SELECT ALL + cor0.col2 + col2 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7689
SELECT ALL + cor0.col2 + col2 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col1 * cor0.col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + + 68 * cor0.col1 + + col0 + + col0 AS col2 FROM tab0 AS cor0
----
5896
6366
6666

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7692
SELECT + + col1 * - col0 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7692
SELECT + + col1 * - col0 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 61 * + col1 + cor0.col0 FROM tab2 AS cor0
----
1116
1898
3677

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + - col0 + col2 col0 FROM tab0
----
63
84
95

query I rowsort
SELECT DISTINCT 93 * col2 + - ( - col2 ) * col2 FROM tab1 AS cor0
----
18144
7938
8550

query I rowsort
SELECT - - col1 + col2 * col1 * col0 - col1 AS col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT 36 + + col1 AS col1 FROM tab0 AS cor0
----
122
127
133

query I rowsort
SELECT DISTINCT + - 76 * col0 AS col0 FROM tab2 AS cor0
----
-532
-5928
-6004

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col2 + + ( 30 ) + + col1 col1 FROM tab0
----
-676
-7177
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-7700
SELECT - tab2.col1 DIV + tab2.col0 FROM tab2
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-7700
SELECT - tab2.col1 / + tab2.col0 FROM tab2
----
-4
0
0

query I rowsort
SELECT - ( + tab2.col2 ) FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT + 68 + col0 + tab0.col1 FROM tab0
----
178
200
248

query I rowsort
SELECT ALL - - cor0.col2 + cor0.col2 AS col0 FROM tab0 cor0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 68 col1 FROM tab0, tab1 cor0, tab0 AS cor1
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

query I rowsort
SELECT ALL + + 13 * col1 FROM tab0 AS cor0
----
1118
1183
1261

onlyif mysql # use DIV operator for integer division
query I rowsort label-7706
SELECT DISTINCT - - cor0.col0 + - cor0.col0 DIV col2 AS col0 FROM tab0 cor0
----
0
24
88

skipif mysql # not compatible
query I rowsort label-7706
SELECT DISTINCT - - cor0.col0 + - cor0.col0 / col2 AS col0 FROM tab0 cor0
----
0
24
88

query I rowsort
SELECT cor0.col1 * + ( + 32 * - col0 + ( + col0 ) ) FROM tab2 AS cor0
----
-142662
-41633
-6727

query I rowsort
SELECT ALL col2 + col2 - col1 FROM tab0 AS cor0
----
-20
-95
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7709
SELECT col0 + 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-7709
SELECT col0 + CAST ( NULL AS REAL ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7710
SELECT ALL + - cor0.col1 + + col0 DIV 21 AS col0 FROM tab1 AS cor0
----
-10
-26
-7

skipif mysql # not compatible
query I rowsort label-7710
SELECT ALL + - cor0.col1 + + col0 / 21 AS col0 FROM tab1 AS cor0
----
-10
-26
-7

query I rowsort
SELECT - col2 * 21 AS col0 FROM tab0 AS cor0
----
-1722
-21
-693

query I rowsort
SELECT DISTINCT + col2 * - ( col0 ) FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT 5 - col0 FROM tab1
----
-59
-75
2

query I rowsort
SELECT ALL - col1 + tab2.col0 - ( col1 ) FROM tab2
----
-40
-55
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-7715
SELECT 71 DIV col0 - col0 AS col0 FROM tab1
----
-63
-80
20

skipif mysql # not compatible
query I rowsort label-7715
SELECT 71 / col0 - col0 AS col0 FROM tab1
----
-63
-80
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-7716
SELECT ALL - 61 * - col0 DIV col0 + 11 AS col1 FROM tab2 AS cor0
----
72
72
72

skipif mysql # not compatible
query I rowsort label-7716
SELECT ALL - 61 * - col0 / col0 + 11 AS col1 FROM tab2 AS cor0
----
72
72
72

query I rowsort
SELECT DISTINCT col2 * + cor0.col1 + + col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT col0 + + 20 AS col2 FROM tab2 AS cor0
----
27
98
99

query I rowsort
SELECT ALL - 77 + 95 + col1 AS col0 FROM tab2 AS cor0
----
35
49
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7720
SELECT ALL CAST( NULL AS DECIMAL ) + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7720
SELECT ALL CAST ( NULL AS REAL ) + col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7721
SELECT ALL CAST( + 76 AS SIGNED ) FROM tab1 cor0
----
76
76
76

skipif mysql # not compatible
query I rowsort label-7721
SELECT ALL CAST ( + 76 AS INTEGER ) FROM tab1 cor0
----
76
76
76

query I rowsort
SELECT ALL tab2.col0 FROM tab2, tab1, tab1 cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + ( 86 ) + col1 * - col2 AS col1 FROM tab0 AS cor0
----
-11
-2752
-7376

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7724
SELECT DISTINCT - CAST( NULL AS SIGNED ) * + col1 AS col1 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7724
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * + col1 AS col1 FROM tab1 cor0
----
NULL

query I rowsort
SELECT - + ( col0 ) * + col2 AS col0 FROM tab0 cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 col2 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

onlyif mysql # use DIV operator for integer division
query I rowsort label-7727
SELECT + + col2 * 80 DIV col0 FROM tab1 AS cor0
----
1440
71
96

skipif mysql # not compatible
query I rowsort label-7727
SELECT + + col2 * 80 / col0 FROM tab1 AS cor0
----
1440
71
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-7729
SELECT DISTINCT 97 DIV col0 AS col2 FROM tab2
----
1
13

skipif mysql # not compatible
query I rowsort label-7729
SELECT DISTINCT 97 / col0 AS col2 FROM tab2
----
1
13

query I rowsort
SELECT ALL cor0.col1 * + col1 AS col1 FROM tab2 cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-7731
SELECT ALL - col2 + col2 DIV + col0 + col0 * col0 AS col2 FROM tab1 AS cor0
----
-27
4039
6305

skipif mysql # not compatible
query I rowsort label-7731
SELECT ALL - col2 + col2 / + col0 + col0 * col0 AS col2 FROM tab1 AS cor0
----
-27
4039
6305

query I rowsort
SELECT col0 * ( cor0.col2 ) FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL - tab1.col1 AS col1 FROM tab1, tab0, tab1 AS cor0, tab2
----
81 values hashing to 96e9ef2950805bca93a295eeea43ef5b

query I rowsort
SELECT DISTINCT tab1.col1 * col0 * col2 AS col2 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT col2 + + 63 FROM tab1 AS cor0
----
117
120
159

query I rowsort
SELECT - + 31 * col2 AS col2 FROM tab1 AS cor0
----
-1674
-1767
-2976

query I rowsort
SELECT ALL + col2 * - col0 * col0 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT - 59 - 66 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 23726b3acc81d0da778ac9662bc92c2b

onlyif mysql # use DIV operator for integer division
query I rowsort label-7739
SELECT + col0 DIV + col1 + - col1 AS col0 FROM tab1 AS cor0
----
-26
-4
-7

skipif mysql # not compatible
query I rowsort label-7739
SELECT + col0 / + col1 + - col1 AS col0 FROM tab1 AS cor0
----
-26
-4
-7

skipif mysql # not compatible
query I rowsort
SELECT + - col1 / cor0.col0 + CAST ( - 9 AS REAL ) * + col2 FROM tab0 AS cor0
----
-11
-300
-739

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col1 col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT - + 90 + col0 * - 85 AS col1 FROM tab1 AS cor0
----
-345
-5530
-6890

onlyif mysql # use DIV operator for integer division
query I rowsort label-7743
SELECT ALL 52 DIV col2 AS col2 FROM tab0 AS cor0
----
0
1
52

skipif mysql # not compatible
query I rowsort label-7743
SELECT ALL 52 / col2 AS col2 FROM tab0 AS cor0
----
0
1
52

query I rowsort
SELECT + 17 + - col2 + 29 AS col1 FROM tab2 AS cor0
----
19
20
8

query I rowsort
SELECT - col0 * col1 + col2 + - tab1.col1 FROM tab1
----
-50
-593
-957

query I rowsort
SELECT ALL + col2 + - col1 * + col2 * col1 + + col2 FROM tab2
----
-10906
-25893
-90454

query I rowsort
SELECT ALL + 55 + - tab0.col0 AS col0 FROM tab0
----
-34
20
31

query I rowsort
SELECT DISTINCT + col1 + 19 FROM tab0
----
105
110
116

onlyif mysql # use DIV operator for integer division
query I rowsort label-7749
SELECT ALL - col1 * col0 + - 2 DIV - col2 AS col1 FROM tab0
----
-2064
-3393
-8099

skipif mysql # not compatible
query I rowsort label-7749
SELECT ALL - col1 * col0 + - 2 / - col2 AS col1 FROM tab0
----
-2064
-3393
-8099

query I rowsort
SELECT DISTINCT + - col2 * col1 + col0 * + cor0.col0 AS col0 FROM tab0 AS cor0
----
-2262
1128
459

query I rowsort
SELECT col2 * col1 + - ( col2 * - col2 ) FROM tab1 cor0
----
10464
3819
4320

query I rowsort
SELECT ALL + - 21 FROM tab0 AS cor0
----
-21
-21
-21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col1 + + col1 col0 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT - col0 * col2 * col0 AS col1 FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT - cor0.col1 + 59 AS col1 FROM tab2 AS cor0
----
0
28
42

query I rowsort
SELECT DISTINCT + - col0 + + col2 + - col1 AS col1 FROM tab0 AS cor0
----
-131
-77
-98

skipif mysql # not compatible
query I rowsort
SELECT ALL - col2 * + CAST ( col0 AS REAL ) FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + col2 * col2 + col0 AS col1 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT 41 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

onlyif mysql # use DIV operator for integer division
query I rowsort label-7760
SELECT - 68 DIV tab1.col1 FROM tab1
----
-2
-5
-6

skipif mysql # not compatible
query I rowsort label-7760
SELECT - 68 / tab1.col1 FROM tab1
----
-2
-5
-6

query I rowsort
SELECT - cor0.col2 * - 44 + + col0 AS col1 FROM tab2 AS cor0
----
1195
1222
1751

query I rowsort
SELECT DISTINCT col1 * + col1 - + col2 FROM tab2 cor0
----
251
3455
934

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * 21 col1 FROM tab0 AS cor0
----
1722
21
693

query I rowsort
SELECT cor0.col2 * col0 + col2 * - col2 AS col0 FROM tab1 AS cor0
----
-1536
-2754
399

query I rowsort
SELECT ALL + - col2 * ( + col2 ) AS col2 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-7766
SELECT DISTINCT 16 DIV + col2 FROM tab0
----
0
16

skipif mysql # not compatible
query I rowsort label-7766
SELECT DISTINCT 16 / + col2 FROM tab0
----
0
16

query I rowsort
SELECT 95 AS col2 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT ALL tab1.col0 * - col0 + col1 FROM tab1
----
-4086
-6387
17

query I rowsort
SELECT - cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab0, tab2 cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7770
SELECT + col1 + - CAST( NULL AS SIGNED ) + - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7770
SELECT + 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-7771
SELECT - 43 * + 97 + col0 DIV col0 FROM tab2
----
-4170
-4170
-4170

skipif mysql # not compatible
query I rowsort label-7771
SELECT - 43 * + 97 + col0 / col0 FROM tab2
----
-4170
-4170
-4170

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7772
SELECT CAST( 70 AS SIGNED ) * - col1 FROM tab1 AS cor0
----
-1820
-700
-910

skipif mysql # not compatible
query I rowsort label-7772
SELECT CAST ( 70 AS INTEGER ) * - col1 FROM tab1 AS cor0
----
-1820
-700
-910

query I rowsort
SELECT ( + col0 ) + - cor0.col2 * + 80 AS col1 FROM tab0 AS cor0
----
-2616
-45
-6471

query I rowsort
SELECT DISTINCT + + 36 * 25 + - col2 * - 82 AS col1 FROM tab0 AS cor0
----
3606
7624
982

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * - cor0.col1 col0 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-7776
SELECT + 72 + col0 DIV col2 + col2 FROM tab1 AS cor0
----
126
130
168

skipif mysql # not compatible
query I rowsort label-7776
SELECT + 72 + col0 / col2 + col2 FROM tab1 AS cor0
----
126
130
168

query I rowsort
SELECT - col1 + col1 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT - - 33 + - col1 FROM tab1 AS cor0
----
20
23
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-7779
SELECT - - col2 DIV col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7779
SELECT - - col2 / col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL + 65 * col0 + col2 * ( + col1 ) AS col1 FROM tab0 AS cor0
----
13247
2372
4398

onlyif mysql # use DIV operator for integer division
query I rowsort label-7781
SELECT ALL - col0 * col0 + cor0.col0 + - ( - col1 + + col1 ) * ( - col2 ) DIV + col0 AS col1 FROM tab0 cor0
----
-1190
-552
-7832

skipif mysql # not compatible
query I rowsort label-7781
SELECT ALL - col0 * col0 + cor0.col0 + - ( - col1 + + col1 ) * ( - col2 ) / + col0 AS col1 FROM tab0 cor0
----
-1190
-552
-7832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7782
SELECT DISTINCT + CAST( NULL AS SIGNED ) * 34 * - col1 + - col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7782
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * 34 * - col1 + - col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col0 + 29 AS col1 FROM tab0 AS cor0
----
118
53
64

query I rowsort
SELECT ALL col2 * - ( + col1 ) FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT - + col1 * 97 * col2 AS col2 FROM tab2 AS cor0
----
-148798
-62662
-81189

query I rowsort
SELECT DISTINCT col2 * - 63 FROM tab1 AS cor0
----
-3402
-3591
-6048

query I rowsort
SELECT ALL - col0 * 20 AS col2 FROM tab2 AS cor0
----
-140
-1560
-1580

query I rowsort
SELECT DISTINCT - - 72 * cor0.col1 FROM tab0 AS cor0
----
6192
6552
6984

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( col1 ) + col2 col0 FROM tab0 AS cor0
----
-53
-9
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col2 ) col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT - col0 * cor0.col0 * - col1 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT ALL - - col0 + + col2 * + col1 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT + 76 - - col1 FROM tab0 AS cor0
----
162
167
173

onlyif mysql # use DIV operator for integer division
query I rowsort label-7794
SELECT DISTINCT - 26 DIV col1 AS col1 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-7794
SELECT DISTINCT - 26 / col1 AS col1 FROM tab2 AS cor0
----
-1
0

query I rowsort
SELECT DISTINCT + ( - cor0.col1 ) * - cor0.col0 AS col2 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT - col2 + - cor0.col1 * - 54 AS col1 FROM tab1 AS cor0
----
1350
483
606

onlyif mysql # use DIV operator for integer division
query I rowsort label-7797
SELECT col2 DIV + col2 - col0 * + tab1.col0 * col0 FROM tab1
----
-26
-262143
-511999

skipif mysql # not compatible
query I rowsort label-7797
SELECT col2 / + col2 - col0 * + tab1.col0 * col0 FROM tab1
----
-26
-262143
-511999

query I rowsort
SELECT ALL - col2 + + ( - 87 ) * cor0.col2 FROM tab2 cor0
----
-2288
-2376
-3344

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + cor0.col1 * col2 col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL + - cor0.col1 + + col2 + + col0 FROM tab1 AS cor0
----
111
163
31

query I rowsort
SELECT DISTINCT - col2 * - 94 AS col2 FROM tab2 AS cor0
----
2444
2538
3572

query I rowsort
SELECT ALL + 97 * + col1 * + tab2.col2 AS col2 FROM tab2
----
148798
62662
81189

query I rowsort
SELECT - col1 * 47 - + col0 * col1 FROM tab0
----
-12376
-6106
-7954

query I rowsort
SELECT DISTINCT cor0.col0 AS col2 FROM tab1, tab0, tab0 AS cor0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7805
SELECT ALL col0 - CAST( NULL AS DECIMAL ) / - col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7805
SELECT ALL col0 - CAST ( NULL AS REAL ) / - col0 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7806
SELECT col2 * 96 DIV + 56 AS col0 FROM tab0 AS cor0
----
1
140
56

skipif mysql # not compatible
query I rowsort label-7806
SELECT col2 * 96 / + 56 AS col0 FROM tab0 AS cor0
----
1
140
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * ( 12 ) col2 FROM tab0
----
1068
288
420

query I rowsort
SELECT + + col2 * 11 FROM tab2 cor0
----
286
297
418

query I rowsort
SELECT - col2 - + col0 * + 81 FROM tab1
----
-297
-5241
-6576

query I rowsort
SELECT + + ( - cor0.col2 ) FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + col1 * - tab1.col0 FROM tab1
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 57 + - col0 col2 FROM tab2
----
-21
-22
50

query I rowsort
SELECT ALL + 84 AS col1 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to e8cd683fe8cea77b4326d9b80f21c74a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 38 col1 FROM tab2, tab1 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT - 60 * - 39 AS col0 FROM tab2
----
2340
2340
2340

onlyif mysql # use DIV operator for integer division
query I rowsort label-7816
SELECT ALL - tab1.col0 + 21 DIV - col0 FROM tab1
----
-10
-64
-80

skipif mysql # not compatible
query I rowsort label-7816
SELECT ALL - tab1.col0 + 21 / - col0 FROM tab1
----
-10
-64
-80

query I rowsort
SELECT DISTINCT + + 41 - col2 * col1 AS col0 FROM tab1 AS cor0
----
-1207
-1363
-529

query I rowsort
SELECT + ( + 30 ) FROM tab2
----
30
30
30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7819
SELECT CAST( NULL AS SIGNED ) * + col2 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7819
SELECT CAST ( NULL AS INTEGER ) * + col2 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - 19 + col0 AS col1 FROM tab0
----
16
5
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7821
SELECT ALL - CAST( NULL AS SIGNED ) + col1 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7821
SELECT ALL - CAST ( NULL AS INTEGER ) + col1 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 51 AS col1 FROM tab0, tab2 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 006d860fc40bbb38cbb649ba917d74a9

query I rowsort
SELECT DISTINCT - cor0.col2 + col1 * col2 FROM tab1 AS cor0
----
1152
1350
513

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( col1 AS REAL ) * col2 AS col0 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 64 col0 FROM tab1 AS cor0
----
-64
-64
-64

query I rowsort
SELECT ALL + + 81 * + 54 AS col2 FROM tab2 AS cor0
----
4374
4374
4374

onlyif mysql # use DIV operator for integer division
query I rowsort label-7827
SELECT col2 DIV - col1 - 11 FROM tab2
----
-11
-11
-13

skipif mysql # not compatible
query I rowsort label-7827
SELECT col2 / - col1 - 11 FROM tab2
----
-11
-11
-13

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7828
SELECT ALL CAST( NULL AS DECIMAL ) + 57 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7828
SELECT ALL CAST ( NULL AS REAL ) + 57 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7829
SELECT ALL + 54 * - col2 + - CAST( NULL AS SIGNED ) * + col2 + + col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7829
SELECT ALL + 54 * - col2 + - CAST ( NULL AS INTEGER ) * + col2 + + col1 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 - - col0 * 1 col2 FROM tab2 cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7831
SELECT + col1 * col0 + - col1 DIV - col2 FROM tab0 AS cor0
----
2066
3492
8100

skipif mysql # not compatible
query I rowsort label-7831
SELECT + col1 * col0 + - col1 / - col2 FROM tab0 AS cor0
----
2066
3492
8100

query I rowsort
SELECT + 40 + + col1 FROM tab0 AS cor0
----
126
131
137

query I rowsort
SELECT ALL - + col2 * col1 - 46 FROM tab1 AS cor0
----
-1294
-1450
-616

query I rowsort
SELECT ALL + 54 + - col1 AS col1 FROM tab0 AS cor0
----
-32
-37
-43

query I rowsort
SELECT DISTINCT + cor0.col1 + cor0.col1 * - ( - col0 ) FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL col0 + - ( ( - col0 ) ) * col0 AS col1 FROM tab1 AS cor0
----
12
4160
6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * ( - col0 ) * col2 + + cor0.col0 col0 FROM tab1 AS cor0
----
-36416
-4209
-99760

query I rowsort
SELECT DISTINCT cor0.col2 + - ( + 11 + - col1 ) * + col1 FROM tab2 AS cor0
----
140
2858
647

query I rowsort
SELECT DISTINCT col0 * - cor0.col1 * 9 + col2 * + col1 AS col1 FROM tab1 AS cor0
----
-5190
-8112
702

query I rowsort
SELECT ALL col0 - + col2 AS col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL 79 * - col0 + - 45 FROM tab2
----
-598
-6207
-6286

query I rowsort
SELECT ALL col2 * - ( col0 + - col2 * - col1 ) FROM tab1 AS cor0
----
-127488
-36138
-75978

query I rowsort
SELECT DISTINCT ( + col1 ) * - col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT 69 * tab1.col0 AS col1 FROM tab1
----
207
4416
5520

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7845
SELECT ALL CAST( - 64 AS SIGNED ) * - tab1.col1 AS col0 FROM tab1
----
1664
640
832

skipif mysql # not compatible
query I rowsort label-7845
SELECT ALL CAST ( - 64 AS INTEGER ) * - tab1.col1 AS col0 FROM tab1
----
1664
640
832

query I rowsort
SELECT + col1 * 33 AS col1 FROM tab2
----
1023
1947
561

query I rowsort
SELECT - 65 - 12 AS col2 FROM tab2, tab1, tab0 cor0
----
27 values hashing to c7e5f48ecd3843d54a76808ed1f43ff6

query I rowsort
SELECT col2 * - 43 FROM tab0
----
-1419
-3526
-43

query I rowsort
SELECT cor0.col0 + + col0 * - col1 * col2 AS col1 FROM tab0 AS cor0
----
-3360
-664029
-68088

query I rowsort
SELECT - + col1 * + col0 + + col0 AS col2 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT - col1 * col0 + + col1 AS col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-7852
SELECT ( + col0 ) DIV - col1 FROM tab1
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-7852
SELECT ( + col0 ) / - col1 FROM tab1
----
-6
-6
0

query I rowsort
SELECT ALL + 54 * col1 + col1 FROM tab0 AS cor0
----
4730
5005
5335

onlyif mysql # use DIV operator for integer division
query I rowsort label-7854
SELECT + cor0.col2 + col2 DIV - 48 AS col2 FROM tab0 AS cor0
----
1
33
81

skipif mysql # not compatible
query I rowsort label-7854
SELECT + cor0.col2 + col2 / - 48 AS col2 FROM tab0 AS cor0
----
1
33
81

query I rowsort
SELECT ALL + - cor0.col1 * col1 AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT + 8 + + col0 * col1 * cor0.col2 AS col2 FROM tab1 AS cor0
----
36488
4220
99848

query I rowsort
SELECT ALL - 8 - col2 AS col0 FROM tab1 AS cor0
----
-104
-62
-65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7858
SELECT ALL - 10 - col2 * - CAST( NULL AS SIGNED ) / - col1 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7858
SELECT ALL - 10 - col2 * - CAST ( NULL AS INTEGER ) / - col1 AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 53 AS col1 FROM tab1 AS cor0
----
-53
-53
-53

query I rowsort
SELECT 0 * + ( tab1.col1 ) AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - 78 + ( - col2 ) AS col2 FROM tab0
----
-111
-160
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-7862
SELECT DISTINCT ( col2 ) DIV col1 + 29 * col0 FROM tab2
----
203
2262
2293

skipif mysql # not compatible
query I rowsort label-7862
SELECT DISTINCT ( col2 ) / col1 + 29 * col0 FROM tab2
----
203
2262
2293

query I rowsort
SELECT - tab1.col1 * - col2 + - col0 AS col0 FROM tab1
----
1168
1401
506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * - col1 col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - - col1 * 40 FROM tab2 AS cor0
----
1240
2360
680

query I rowsort
SELECT DISTINCT - col1 * col1 + + col2 AS col2 FROM tab2 cor0
----
-251
-3455
-934

query I rowsort
SELECT DISTINCT + + col2 * col1 + cor0.col2 AS col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT - - col2 + - 56 * col0 AS col2 FROM tab0 AS cor0
----
-1311
-1959
-4902

query I rowsort
SELECT DISTINCT cor0.col2 + col2 * 70 AS col0 FROM tab2 cor0
----
1846
1917
2698

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + 82 col1 FROM tab0 AS cor0
----
7052
7462
7954

onlyif mysql # use DIV operator for integer division
query I rowsort label-7871
SELECT - col2 DIV + ( - 86 ) AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7871
SELECT - col2 / + ( - 86 ) AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col0 + - col2 * + col0 AS col1 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT - ( col0 ) + + col1 * col1 AS col1 FROM tab0
----
7372
8192
9374

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7874
SELECT DISTINCT - col1 + CAST( NULL AS DECIMAL ) * + 24 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7874
SELECT DISTINCT - col1 + CAST ( NULL AS REAL ) * + 24 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + col1 * + 66 AS col2 FROM tab0 cor0
----
5676
6006
6402

onlyif mysql # use DIV operator for integer division
query I rowsort label-7876
SELECT 69 * col0 + - col1 DIV + cor0.col0 - col0 FROM tab0 AS cor0
----
1629
2378
6051

skipif mysql # not compatible
query I rowsort label-7876
SELECT 69 * col0 + - col1 / + cor0.col0 - col0 FROM tab0 AS cor0
----
1629
2378
6051

query I rowsort
SELECT 24 + col2 FROM tab2 cor0
----
50
51
62

query I rowsort
SELECT ALL + tab0.col2 + - ( ( col1 ) ) AS col2 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT - 87 + ( col0 ) AS col1 FROM tab2 AS cor0
----
-8
-80
-9

query I rowsort
SELECT ( + col1 ) + col0 AS col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT + ( + col1 ) + col0 * + cor0.col0 - 63 * col2 * col1 FROM tab2 cor0
----
-34440
-52651
-90499

query I rowsort
SELECT + 7 + col0 FROM tab0 AS cor0
----
31
42
96

query I rowsort
SELECT - 57 + 84 AS col0 FROM tab2 AS cor0
----
27
27
27

query I rowsort
SELECT - tab2.col1 * 35 * col2 + + col1 AS col1 FROM tab2
----
-22593
-29264
-53631

query I rowsort
SELECT + ( tab2.col2 * col2 ) FROM tab2
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 53 col0 FROM tab0 cor0
----
53
53
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-7887
SELECT - col2 DIV - col0 + ( col0 ) FROM tab2 AS cor0
----
10
78
79

skipif mysql # not compatible
query I rowsort label-7887
SELECT - col2 / - col0 + ( col0 ) FROM tab2 AS cor0
----
10
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-7888
SELECT + 95 + + tab0.col0 DIV + col0 FROM tab0
----
96
96
96

skipif mysql # not compatible
query I rowsort label-7888
SELECT + 95 + + tab0.col0 / + col0 FROM tab0
----
96
96
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7889
SELECT + CAST( NULL AS SIGNED ) * col0 + col1 * + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7889
SELECT + CAST ( NULL AS INTEGER ) * col0 + col1 * + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col0 + - col2 - cor0.col2 FROM tab1 AS cor0
----
-105
-112
-50

query I rowsort
SELECT ALL - 90 FROM tab1, tab1 cor0
----
9 values hashing to f6f26b9a04da14807208b93d507095c5

query I rowsort
SELECT DISTINCT + ( + 88 ) FROM tab0
----
88

query I rowsort
SELECT + 8 AS col1 FROM tab2
----
8
8
8

query I rowsort
SELECT + 7 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 4e72e9e33dacac757f48d0ce46094607

query I rowsort
SELECT + col1 * col2 * cor0.col1 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT - col1 * - 23 AS col0 FROM tab1 AS cor0
----
230
299
598

query I rowsort
SELECT ALL cor0.col2 + - 58 * + tab2.col2 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 7dc9635e4dbb11a497725dad24b5b29e

onlyif mysql # use DIV operator for integer division
query I rowsort label-7898
SELECT - ( + col2 ) DIV + col0 AS col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-7898
SELECT - ( + col2 ) / + col0 AS col0 FROM tab0 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col0 * + cor0.col0 col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT 38 * - col1 AS col1 FROM tab2 AS cor0
----
-1178
-2242
-646

query I rowsort
SELECT 56 * + col1 AS col0 FROM tab0 AS cor0
----
4816
5096
5432

onlyif mysql # use DIV operator for integer division
query I rowsort label-7902
SELECT DISTINCT + - col0 + 37 DIV - 6 AS col1 FROM tab0 AS cor0
----
-30
-41
-95

skipif mysql # not compatible
query I rowsort label-7902
SELECT DISTINCT + - col0 + 37 / - 6 AS col1 FROM tab0 AS cor0
----
-30
-41
-95

query I rowsort
SELECT col0 + + col1 - 92 FROM tab0 AS cor0
----
18
40
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7904
SELECT + col0 + + CAST( NULL AS SIGNED ) + - col2 * - cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7904
SELECT + col0 + + CAST ( NULL AS INTEGER ) + - col2 * - cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7905
SELECT DISTINCT + col1 * + CAST( - col2 AS SIGNED ) + - col0 FROM tab1 AS cor0
----
-1328
-1407
-634

skipif mysql # not compatible
query I rowsort label-7905
SELECT DISTINCT + col1 * + CAST ( - col2 AS INTEGER ) + - col0 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT ALL - cor0.col2 AS col2 FROM tab0, tab1 cor0, tab1 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT DISTINCT - col1 + 64 FROM tab1 AS cor0
----
38
51
54

query I rowsort
SELECT ALL + ( - cor0.col0 ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT - col2 * + 63 AS col0 FROM tab0 AS cor0
----
-2079
-5166
-63

query I rowsort
SELECT col0 + 20 * + col0 + col0 * + col0 FROM tab2 AS cor0
----
196
7722
7900

query I rowsort
SELECT + col2 * ( col2 ) * - col2 FROM tab0 AS cor0
----
-1
-35937
-551368

onlyif mysql # use DIV operator for integer division
query I rowsort label-7912
SELECT ALL + - 90 DIV cor0.col1 AS col2 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-7912
SELECT ALL + - 90 / cor0.col1 AS col2 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT ALL - cor0.col1 AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7914
SELECT + - 99 + - col2 + - col2 * - CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7914
SELECT + - 99 + - col2 + - col2 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 + col1 * col2 AS col0 FROM tab2 AS cor0
----
1475
629
806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7916
SELECT - + col1 * + col1 * CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7916
SELECT - + col1 * + col1 * CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( - col0 ) * 74 AS col1 FROM tab0 AS cor0
----
1776
2590
6586

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 74 col1 FROM tab1 AS cor0
----
-74
-74
-74

query I rowsort
SELECT col1 + col2 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT 21 * + col2 * - 78 FROM tab1 AS cor0
----
-157248
-88452
-93366

query I rowsort
SELECT ALL ( + col2 + col0 ) * col2 FROM tab2
----
2704
4446
918

query I rowsort
SELECT 35 + + 46 * col0 FROM tab2
----
357
3623
3669

query I rowsort
SELECT tab0.col2 + - 77 * + col1 FROM tab0
----
-6589
-6925
-7468

query I rowsort
SELECT 56 + col2 * + col0 AS col2 FROM tab0
----
7354
848
91

query I rowsort
SELECT DISTINCT 9 * col0 + col1 * + col1 FROM tab1 AS cor0
----
676
703
889

query I rowsort
SELECT DISTINCT + col1 + col0 * - col1 AS col2 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT - + col2 + col2 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT + 12 * cor0.col1 + 8 FROM tab0 AS cor0
----
1040
1100
1172

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - col2 * - col1 col1 FROM tab0
----
2814
62
7373

query I rowsort
SELECT ( + col2 ) + - col1 * col2 * col2 FROM tab1
----
-119712
-32433
-75762

query I rowsort
SELECT + tab1.col2 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-7932
SELECT DISTINCT + - col1 DIV - col1 + 66 * - col1 col0 FROM tab0 AS cor0
----
-5675
-6005
-6401

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7932
SELECT DISTINCT + - col1 / - col1 + 66 * - col1 col0 FROM tab0 AS cor0
----
-5675
-6005
-6401

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7933
SELECT - CAST( NULL AS SIGNED ) FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7933
SELECT - CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL + - col2 * col1 + col1 AS col2 FROM tab0 AS cor0
----
-2752
-7371
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - 92 * col2 + + col2 col0 FROM tab2
----
-2288
-2450
-3379

query I rowsort
SELECT ALL col0 + - 51 FROM tab2
----
-44
27
28

query I rowsort
SELECT DISTINCT - col0 * ( 1 ) + col1 FROM tab0
----
2
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-7938
SELECT ALL col1 DIV - ( cor0.col1 ) + + col1 * col0 + cor0.col1 FROM tab1 AS cor0
----
103
1052
649

skipif mysql # not compatible
query I rowsort label-7938
SELECT ALL col1 / - ( cor0.col1 ) + + col1 * col0 + cor0.col1 FROM tab1 AS cor0
----
103
1052
649

query I rowsort
SELECT ALL + col2 - - 99 AS col0 FROM tab2
----
125
126
137

query I rowsort
SELECT col0 + + col2 + col0 FROM tab0
----
260
71
81

query I rowsort
SELECT col2 * + 90 + col1 * - col1 + col1 FROM tab2
----
-1082
1500
3148

query I rowsort
SELECT DISTINCT col2 + ( 90 + + tab2.col0 ) AS col1 FROM tab2
----
124
194
207

query I rowsort
SELECT ALL tab2.col0 + + tab2.col2 AS col1 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL + 41 * - 34 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to abe378b27eb0ce737b696e22331d78b6

query I rowsort
SELECT DISTINCT + 7 * cor0.col0 - + col0 AS col2 FROM tab2 AS cor0
----
42
468
474

onlyif mysql # use DIV operator for integer division
query I rowsort label-7946
SELECT ALL + + 26 DIV 66 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7946
SELECT ALL + + 26 / 66 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT col2 + 36 * cor0.col1 FROM tab1 AS cor0
----
417
564
990

query I rowsort
SELECT ALL + ( + col0 ) + + col0 FROM tab0 AS cor0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-7949
SELECT col1 + + col0 DIV col0 AS col0 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-7949
SELECT col1 + + col0 / col0 AS col0 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT ALL 3 * + col0 + cor0.col1 * col1 AS col0 FROM tab2 AS cor0
----
3715
526
982

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7951
SELECT DISTINCT CAST( - 68 AS SIGNED ) / col2 + CAST( NULL AS SIGNED ) / 36 AS col0 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7951
SELECT DISTINCT CAST ( - 68 AS INTEGER ) / col2 + CAST ( NULL AS INTEGER ) / 36 AS col0 FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL ( - col2 ) * - col2 * col1 + + cor0.col2 + col0 AS col2 FROM tab2 AS cor0
----
22633
24665
39988

query I rowsort
SELECT + col1 + ( + col2 ) AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT ( - col2 ) + - col2 FROM tab0 cor0
----
-164
-2
-66

query I rowsort
SELECT - - ( + ( col2 ) ) FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 40 + + col1 + - col1 col1 FROM tab2 cor0
----
40
40
40

query I rowsort
SELECT ALL + 63 * - col2 * col1 AS col2 FROM tab1 AS cor0
----
-35910
-78624
-88452

query I rowsort
SELECT ALL ( + 3 ) AS col1 FROM tab2 AS cor0
----
3
3
3

query I rowsort
SELECT DISTINCT - + col2 + - col2 * + col1 AS col1 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT - - col2 + 63 AS col1 FROM tab2 cor0
----
101
89
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-7961
SELECT + 38 + - cor0.col1 DIV - col0 FROM tab2 AS cor0
----
38
38
42

skipif mysql # not compatible
query I rowsort label-7961
SELECT + 38 + - cor0.col1 / - col0 FROM tab2 AS cor0
----
38
38
42

query I rowsort
SELECT + col2 * + 16 + + col0 AS col2 FROM tab0 AS cor0
----
1401
51
552

onlyif mysql # use DIV operator for integer division
query I rowsort label-7963
SELECT ALL - col1 DIV + ( - col1 ) AS col2 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7963
SELECT ALL - col1 / + ( - col1 ) AS col2 FROM tab2
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7964
SELECT ALL col0 * ( + col0 + col1 ) DIV 48 AS col1 FROM tab0
----
333
55
96

skipif mysql # not compatible
query I rowsort label-7964
SELECT ALL col0 * ( + col0 + col1 ) / 48 AS col1 FROM tab0
----
333
55
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 71 * - tab2.col2 col0 FROM tab2
----
-1846
-1917
-2698

query I rowsort
SELECT + 63 * + tab1.col2 FROM tab1
----
3402
3591
6048

query I rowsort
SELECT - 91 - - tab2.col0 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to d5282844d0dadeffeb35494fb3e532ff

query I rowsort
SELECT + ( 69 ) FROM tab1
----
69
69
69

query I rowsort
SELECT ALL ( 96 + - tab1.col1 ) FROM tab1
----
70
83
86

query I rowsort
SELECT 68 * - 65 FROM tab1 cor0
----
-4420
-4420
-4420

onlyif mysql # use DIV operator for integer division
query I rowsort label-7971
SELECT + 75 + col2 DIV 95 FROM tab2
----
75
75
75

skipif mysql # not compatible
query I rowsort label-7971
SELECT + 75 + col2 / 95 FROM tab2
----
75
75
75

query I rowsort
SELECT ALL - + col2 * - col1 + col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT + col1 + + col0 * cor0.col0 AS col2 FROM tab1 AS cor0
----
35
4106
6413

onlyif mysql # use DIV operator for integer division
query I rowsort label-7974
SELECT DISTINCT + + col2 + - col0 DIV col1 col2 FROM tab1 AS cor0
----
51
54
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7974
SELECT DISTINCT + + col2 + - col0 / col1 col2 FROM tab1 AS cor0
----
51
54
90

query I rowsort
SELECT ALL + col0 * 47 + col2 - col0 FROM tab0 AS cor0
----
1137
1611
4176

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7976
SELECT - cor0.col0 + + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7976
SELECT - cor0.col0 + + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7977
SELECT - col1 + CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7977
SELECT - col1 + CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col1 - - ( col1 ) AS col1 FROM tab1
----
20
26
52

query I rowsort
SELECT DISTINCT col2 * + 79 * col2 AS col1 FROM tab0
----
531196
79
86031

query I rowsort
SELECT ALL tab2.col1 * + ( 15 ) FROM tab2
----
255
465
885

query I rowsort
SELECT - + cor0.col2 * + col2 + col2 * + col1 AS col1 FROM tab1 AS cor0
----
-1512
-2679
-7968

query I rowsort
SELECT DISTINCT - - ( - 15 ) + cor0.col0 AS col2 FROM tab2 cor0
----
-8
63
64

query I rowsort
SELECT - 54 * col2 FROM tab0 AS cor0
----
-1782
-4428
-54

query I rowsort
SELECT ALL + cor0.col1 * 43 FROM tab0 AS cor0
----
3698
3913
4171

onlyif mysql # use DIV operator for integer division
query I rowsort label-7985
SELECT DISTINCT - ( - cor0.col0 ) * col2 DIV + col1 FROM tab1 AS cor0
----
364
590
6

skipif mysql # not compatible
query I rowsort label-7985
SELECT DISTINCT - ( - cor0.col0 ) * col2 / + col1 FROM tab1 AS cor0
----
364
590
6

query I rowsort
SELECT + col1 * 87 AS col0 FROM tab1 AS cor0
----
1131
2262
870

onlyif mysql # use DIV operator for integer division
query I rowsort label-7987
SELECT DISTINCT + 49 * - col2 + cor0.col1 DIV 88 FROM tab2 AS cor0
----
-1274
-1323
-1862

skipif mysql # not compatible
query I rowsort label-7987
SELECT DISTINCT + 49 * - col2 + cor0.col1 / 88 FROM tab2 AS cor0
----
-1274
-1323
-1862

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + - col2 * - cor0.col2 col2 FROM tab0 cor0
----
1113
36
6813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7989
SELECT DISTINCT CAST( 82 AS SIGNED ) AS col1 FROM tab2, tab2 AS cor0
----
82

skipif mysql # not compatible
query I rowsort label-7989
SELECT DISTINCT CAST ( 82 AS INTEGER ) AS col1 FROM tab2, tab2 AS cor0
----
82

query I rowsort
SELECT + cor0.col2 * - col0 * 25 AS col0 FROM tab1 AS cor0
----
-192000
-4050
-91200

query I rowsort
SELECT cor0.col2 * + cor1.col2 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to a477aa402dcd904394a585dfd5cfe837

query I rowsort
SELECT + 64 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT - + col1 - col2 AS col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT - col1 * - col2 * 89 FROM tab0 AS cor0
----
252582
664118
8633

query I rowsort
SELECT DISTINCT 82 * col2 AS col1 FROM tab1
----
4428
4674
7872

query I rowsort
SELECT ALL - + cor0.col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT DISTINCT 98 * tab1.col0 + col0 * ( 10 ) AS col1 FROM tab1
----
324
6912
8640

query I rowsort
SELECT DISTINCT + col2 * + 65 + col1 * col1 FROM tab2
----
2716
2759
5171

onlyif mysql # use DIV operator for integer division
query I rowsort label-7999
SELECT ALL - ( - col2 ) DIV + cor0.col2 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7999
SELECT ALL - ( - col2 ) / + cor0.col2 AS col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT col1 - 67 AS col0 FROM tab2
----
-36
-50
-8

query I rowsort
SELECT - tab0.col1 - col0 AS col1 FROM tab0
----
-110
-132
-180

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( - col2 * col1 + - CAST ( + 96 AS INTEGER ) AS REAL ) AS col1 FROM tab1
----
-1344
-1500
-666

query I rowsort
SELECT DISTINCT cor0.col0 * col1 + ( cor0.col1 + col0 ) FROM tab2 AS cor0
----
1439
255
4739

query I rowsort
SELECT col0 * - tab0.col2 * col0 + ( - col2 ) AS col2 FROM tab0
----
-1226
-19041
-649604

onlyif mysql # use DIV operator for integer division
query I rowsort label-8005
SELECT DISTINCT - ( + col0 + col2 ) DIV col1 col2 FROM tab0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8005
SELECT DISTINCT - ( + col0 + col2 ) / col1 col2 FROM tab0
----
-1
0

query I rowsort
SELECT DISTINCT + 91 + cor0.col1 AS col0 FROM tab0 AS cor0
----
177
182
188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 73 col2 FROM tab2 cor0
----
73
73
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-8008
SELECT DISTINCT - 80 * cor0.col0 DIV 61 + - col2 + col0 FROM tab0 AS cor0
----
-109
-11
-40

skipif mysql # not compatible
query I rowsort label-8008
SELECT DISTINCT - 80 * cor0.col0 / 61 + - col2 + col0 FROM tab0 AS cor0
----
-109
-11
-40

query I rowsort
SELECT DISTINCT + 17 * col0 + ( 29 ) FROM tab1 cor0
----
1117
1389
80

query I rowsort
SELECT cor0.col2 * col0 + + col1 FROM tab1 cor0
----
188
3658
7693

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8011
SELECT + col2 + - CAST( - 48 AS SIGNED ) FROM tab2 AS cor0
----
74
75
86

skipif mysql # not compatible
query I rowsort label-8011
SELECT + col2 + - CAST ( - 48 AS INTEGER ) FROM tab2 AS cor0
----
74
75
86

query I rowsort
SELECT - col1 + - 50 FROM tab2 AS cor0
----
-109
-67
-81

query I rowsort
SELECT DISTINCT + col0 * + cor0.col1 + - col0 * + col0 FROM tab2 AS cor0
----
-1482
-4898
168

query I rowsort
SELECT ALL - 94 + col2 FROM tab0 AS cor0
----
-12
-61
-93

query I rowsort
SELECT DISTINCT - cor0.col0 * - 52 - - col0 FROM tab0 AS cor0
----
1272
1855
4717

query I rowsort
SELECT ALL + ( col1 * + col2 ) FROM tab0
----
2838
7462
97

query I rowsort
SELECT - 37 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to ed4644af7729c2425ea6cc3d84c6504f

query I rowsort
SELECT DISTINCT - - col1 - col2 * - col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT - col0 + col1 + + col1 * - ( col0 ) AS col0 FROM tab2 cor0
----
-1405
-193
-4621

query I rowsort
SELECT + - cor1.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8021
SELECT - CAST( + col0 AS SIGNED ) FROM tab1 cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-8021
SELECT - CAST ( + col0 AS INTEGER ) FROM tab1 cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col1 ) + col1 * + ( - 31 ) col0 FROM tab2 AS cor0
----
-1888
-544
-992

query I rowsort
SELECT ALL + ( ( - col0 ) ) * - col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + 97 * 35 FROM tab0
----
3395

query I rowsort
SELECT ALL ( col2 ) AS col1 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT - 92 * col2 FROM tab0 AS cor0
----
-3036
-7544
-92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + 29 col1 FROM tab2 AS cor0
----
-203
-2262
-2291

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 54 col1 FROM tab2
----
54
54
54

query I rowsort
SELECT ALL + col1 * - col1 + cor0.col2 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT DISTINCT + + col1 - - col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8031
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-8031
SELECT - CAST ( NULL AS INTEGER ) - - col0 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * + col1 * + col2 + 37 * + 64 FROM tab1 AS cor0
----
18592
38872
8068

query I rowsort
SELECT + + col0 * col0 + + cor0.col1 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT ALL + ( + col1 ) + col2 * - 90 AS col0 FROM tab1 cor0
----
-4834
-5120
-8627

onlyif mysql # use DIV operator for integer division
query I rowsort label-8035
SELECT ALL + col0 * col0 + col0 DIV + 37 FROM tab1 AS cor0
----
4097
6402
9

skipif mysql # not compatible
query I rowsort label-8035
SELECT ALL + col0 * col0 + col0 / + 37 FROM tab1 AS cor0
----
4097
6402
9

query I rowsort
SELECT DISTINCT + 30 + - 15 FROM tab2 cor0
----
15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8037
SELECT - + CAST( NULL AS SIGNED ) / col0 + col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8037
SELECT - + CAST ( NULL AS INTEGER ) / col0 + col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8038
SELECT ALL cor0.col1 DIV - cor0.col1 FROM tab2, tab0 cor0, tab2 cor1
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

skipif mysql # not compatible
query I rowsort label-8038
SELECT ALL cor0.col1 / - cor0.col1 FROM tab2, tab0 cor0, tab2 cor1
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

query I rowsort
SELECT ALL + + cor0.col1 - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT cor0.col2 * + col1 + - col0 * - col2 AS col2 FROM tab0 cor0
----
132
14760
3630

query I rowsort
SELECT DISTINCT col2 * ( 61 ) AS col1 FROM tab1 cor0
----
3294
3477
5856

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8042
SELECT ALL + - CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-8042
SELECT ALL + - CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - 48 AS col2 FROM tab1, tab2 AS cor0
----
-48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col2 + + col0 col1 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT ALL + col0 * col1 + - 12 + + col1 AS col2 FROM tab1
----
1041
638
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8046
SELECT - CAST( NULL AS SIGNED ) * + cor0.col2 + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8046
SELECT - CAST ( NULL AS INTEGER ) * + cor0.col2 + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 74 * col1 + col1 FROM tab1 cor0
----
1950
750
975

query I rowsort
SELECT ALL + col1 + + tab2.col2 * col2 AS col0 FROM tab2
----
1461
735
760

query I rowsort
SELECT DISTINCT + col1 * col0 + 57 AS col1 FROM tab0
----
2121
3452
8156

query I rowsort
SELECT DISTINCT col2 * 8 + col0 AS col0 FROM tab2
----
223
286
383

query I rowsort
SELECT + + 62 + - col1 * + col1 AS col1 FROM tab0 AS cor0
----
-7334
-8219
-9347

query I rowsort
SELECT DISTINCT 87 * tab1.col2 AS col2 FROM tab1
----
4698
4959
8352

query I rowsort
SELECT ( col1 ) + + col2 * col2 AS col2 FROM tab0
----
1175
6815
98

query I rowsort
SELECT ALL - 83 AS col2 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-8055
SELECT DISTINCT - cor0.col1 * CAST( NULL AS SIGNED ) FROM tab0, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8055
SELECT DISTINCT - cor0.col1 * CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8056
SELECT col0 * + 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-8056
SELECT col0 * + col1 * CAST ( NULL AS INTEGER ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col1 * + col1 col1 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT DISTINCT 9 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
9

query I rowsort
SELECT DISTINCT col0 * - col2 * col1 AS col2 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT + - ( 33 ) * cor0.col0 + cor0.col2 * col0 * col1 AS col2 FROM tab0 cor0
----
2240
661181
67320

query I rowsort
SELECT DISTINCT col2 * col0 + - tab1.col1 AS col0 FROM tab1
----
136
3638
7667

query I rowsort
SELECT ALL + cor0.col2 + + tab0.col0 * ( 79 ) FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 350a4c9f0e06b39d45f8b11427477694

query I rowsort
SELECT 53 + - col2 * col2 FROM tab2 AS cor0
----
-1391
-623
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-8064
SELECT DISTINCT - tab2.col2 DIV col0 FROM tab2
----
-3
0

skipif mysql # not compatible
query I rowsort label-8064
SELECT DISTINCT - tab2.col2 / col0 FROM tab2
----
-3
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 0 + col1 * + col1 col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT - - col0 * 45 * col1 FROM tab0 AS cor0
----
152775
364455
92880

onlyif mysql # use DIV operator for integer division
query I rowsort label-8067
SELECT 45 DIV 83 + - col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-8067
SELECT 45 / 83 + - col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - col0 * ( col2 ) + + 71 + 4 FROM tab2 AS cor0
----
-114
-1953
-2927

query I rowsort
SELECT DISTINCT - + ( cor0.col1 ) * col2 + - col2 + + col1 AS col1 FROM tab1 AS cor0
----
-1331
-1432
-617

query I rowsort
SELECT ALL - col2 * 74 AS col0 FROM tab2
----
-1924
-1998
-2812

query I rowsort
SELECT col1 * - 26 AS col1 FROM tab0
----
-2236
-2366
-2522

query I rowsort
SELECT DISTINCT 69 + col1 * + col0 FROM tab2
----
1412
286
4671

onlyif mysql # use DIV operator for integer division
query I rowsort label-8073
SELECT + + col0 DIV + col2 + - col0 AS col1 FROM tab1 AS cor0
----
-3
-63
-80

skipif mysql # not compatible
query I rowsort label-8073
SELECT + + col0 / + col2 + - col0 AS col1 FROM tab1 AS cor0
----
-3
-63
-80

query I rowsort
SELECT + col1 * + 22 + col0 AS col2 FROM tab2 AS cor0
----
1376
453
689

query I rowsort
SELECT + col0 - - col0 * + tab2.col0 AS col0 FROM tab2
----
56
6162
6320

query I rowsort
SELECT tab1.col2 * + col1 - tab1.col1 * col0 AS col0 FROM tab1
----
-70
1326
208

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8077
SELECT CAST( - col1 AS SIGNED ) * - col1 AS col2 FROM tab1
----
100
169
676

skipif mysql # not compatible
query I rowsort label-8077
SELECT CAST ( - col1 AS INTEGER ) * - col1 AS col2 FROM tab1
----
100
169
676

query I rowsort
SELECT DISTINCT col2 * - col0 * col2 + ( - col1 ) FROM tab1
----
-207946
-737293
-8774

query I rowsort
SELECT ALL ( + col1 ) * - 79 + - col2 FROM tab1 AS cor0
----
-1123
-2108
-847

query I rowsort
SELECT - - 38 + + col1 AS col2 FROM tab2 AS cor0
----
55
69
97

query I rowsort
SELECT DISTINCT - - col2 * col2 * ( + 67 ) + - col0 AS col1 FROM tab1 AS cor0
----
195369
217619
617392

onlyif mysql # use DIV operator for integer division
query I rowsort label-8082
SELECT - col1 + col1 * 57 DIV 13 FROM tab2 AS cor0
----
104
199
57

skipif mysql # not compatible
query I rowsort label-8082
SELECT - col1 + col1 * 57 / 13 FROM tab2 AS cor0
----
104
199
57

query I rowsort
SELECT DISTINCT - + 73 * + cor0.col2 FROM tab0 AS cor0
----
-2409
-5986
-73

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 col0 + ( col1 ) - col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - + cor0.col2 + 19 AS col2 FROM tab0 AS cor0
----
-14
-63
18

query I rowsort
SELECT - col0 - ( ( col2 ) ) AS col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + col2 * + cor0.col2 + + cor0.col2 * - col2 * - col2 FROM tab1 AS cor0
----
160380
188442
893952

query I rowsort
SELECT - - col1 + - ( col1 ) + + col1 AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + - cor0.col2 - - ( - 1 ) * + col1 FROM tab1 AS cor0
----
-109
-67
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8091
SELECT + - col0 * CAST( NULL AS SIGNED ) - col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8091
SELECT + - col0 * CAST ( NULL AS INTEGER ) - col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 25 + - cor0.col1 AS col2 FROM tab2 AS cor0
----
-34
-6
8

query I rowsort
SELECT col0 * + col1 * + col0 + col1 * 89 AS col0 FROM tab1 cor0
----
2548
41850
84357

query I rowsort
SELECT - 53 * 44 FROM tab1 AS cor0
----
-2332
-2332
-2332

query I rowsort
SELECT - 4 + - col1 AS col2 FROM tab2 AS cor0
----
-21
-35
-63

query I rowsort
SELECT cor0.col0 - - 3 AS col0 FROM tab0 AS cor0
----
27
38
92

query I rowsort
SELECT DISTINCT - 18 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
-18

onlyif mysql # use DIV operator for integer division
query I rowsort label-8098
SELECT + cor0.col2 DIV ( - col0 ) + + col0 col0 FROM tab2 AS cor0
----
4
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8098
SELECT + cor0.col2 / ( - col0 ) + + col0 col0 FROM tab2 AS cor0
----
4
78
79

query I rowsort
SELECT ALL - - col2 * + 37 FROM tab2 cor0
----
1406
962
999

query I rowsort
SELECT ALL col0 * 10 + - col2 + col1 * + 91 * - 99 FROM tab2 AS cor0
----
-152401
-279236
-530777

query I rowsort
SELECT DISTINCT - + col2 * col0 + col2 + cor0.col0 AS col2 FROM tab0 AS cor0
----
-7127
-735
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + cor0.col0 + - col0 col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT ALL col1 * cor0.col2 AS col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT col0 + col0 * 97 * cor0.col2 + col2 AS col1 FROM tab2 AS cor0
----
18367
196820
291311

query I rowsort
SELECT DISTINCT col1 + cor0.col1 + + cor0.col1 FROM tab0 AS cor0
----
258
273
291

query I rowsort
SELECT DISTINCT col2 + + 88 * ( - cor0.col2 ) FROM tab2 AS cor0
----
-2262
-2349
-3306

query I rowsort
SELECT - - col1 * 30 + - col0 + - col1 FROM tab0 cor0
----
2470
2550
2778

onlyif mysql # use DIV operator for integer division
query I rowsort label-8108
SELECT DISTINCT - col1 DIV col1 AS col0 FROM tab1 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-8108
SELECT DISTINCT - col1 / col1 AS col0 FROM tab1 cor0
----
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8109
SELECT DISTINCT col2 + + CAST( + ( col2 ) AS SIGNED ) AS col1 FROM tab0 AS cor0
----
164
2
66

skipif mysql # not compatible
query I rowsort label-8109
SELECT DISTINCT col2 + + CAST ( + ( col2 ) AS INTEGER ) AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL + col0 + 25 * ( + cor0.col1 ) FROM tab1 AS cor0
----
314
405
653

query I rowsort
SELECT cor0.col0 * - 72 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to a7850e5ba276288fbd70c3d21a222b10

query IIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab1, tab1 cor1, tab0 AS cor2
----
972 values hashing to 909b7ebab62aff8f69dc42ccbb5c2eae

query I rowsort
SELECT + col2 * - 63 FROM tab2 AS cor0
----
-1638
-1701
-2394

query I rowsort
SELECT - + col2 * - 20 FROM tab0 AS cor0
----
1640
20
660

query I rowsort
SELECT ALL - - col1 * col1 AS col2 FROM tab0 cor0
----
7396
8281
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8116
SELECT DISTINCT col0 * + CAST( NULL AS SIGNED ) * + 81 AS col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-8116
SELECT DISTINCT col0 * + CAST ( NULL AS INTEGER ) * + 81 AS col2 FROM tab1
----
NULL

query I rowsort
SELECT - 44 - - col2 FROM tab2 AS cor0
----
-17
-18
-6

query I rowsort
SELECT ALL + - ( col2 ) + - 11 FROM tab2 AS cor0
----
-37
-38
-49

query I rowsort
SELECT DISTINCT - cor0.col1 * col1 + + 5 AS col2 FROM tab2 AS cor0
----
-284
-3476
-956

query I rowsort
SELECT ALL ( - 23 * - col2 ) AS col1 FROM tab2
----
598
621
874

query I rowsort
SELECT DISTINCT - 12 FROM tab2, tab1 AS cor0
----
-12

query I rowsort
SELECT ( col2 ) * col1 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ( - col0 ) + - col2 - tab0.col2 AS col0 FROM tab0
----
-253
-37
-90

query I rowsort
SELECT DISTINCT 79 + col0 * + col1 FROM tab0
----
2143
3474
8178

query I rowsort
SELECT - 42 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 56f86ff01cd96a3511acd46e0e811e27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col0 + - 84 col0 FROM tab2 AS cor0
----
105
1944
2918

skipif mysql # not compatible
query I rowsort
SELECT - ( - col0 ) * - CAST ( + 76 AS REAL ) + + col1 FROM tab0 AS cor0
----
-1738
-2563
-6673

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + tab1.col1 col1 FROM tab1
----
20
26
52

query I rowsort
SELECT ALL - 58 AS col2 FROM tab1 AS cor0
----
-58
-58
-58

query I rowsort
SELECT DISTINCT ( + col1 ) * + col2 AS col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT ALL - cor0.col2 + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8132
SELECT cor0.col0 DIV - col1 + - 64 * cor0.col0 * - col0 + - ( - col2 ) AS col0 FROM tab0 AS cor0
----
36897
507026
78401

skipif mysql # not compatible
query I rowsort label-8132
SELECT cor0.col0 / - col1 + - 64 * cor0.col0 * - col0 + - ( - col2 ) AS col0 FROM tab0 AS cor0
----
36897
507026
78401

onlyif mysql # use DIV operator for integer division
query I rowsort label-8133
SELECT DISTINCT + 45 + - col1 DIV col0 FROM tab2 cor0
----
41
45

skipif mysql # not compatible
query I rowsort label-8133
SELECT DISTINCT + 45 + - col1 / col0 FROM tab2 cor0
----
41
45

query I rowsort
SELECT - 68 + cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 6cb7e7aed19922fa3c36739a0a28832f

onlyif mysql # use DIV operator for integer division
query I rowsort label-8135
SELECT 34 DIV + col1 AS col2 FROM tab1
----
1
2
3

skipif mysql # not compatible
query I rowsort label-8135
SELECT 34 / + col1 AS col2 FROM tab1
----
1
2
3

query I rowsort
SELECT ALL + col2 * + tab1.col2 + + col0 * + col2 AS col2 FROM tab1
----
16896
3078
6897

query I rowsort
SELECT ALL 25 - col1 AS col2 FROM tab2 AS cor0
----
-34
-6
8

query I rowsort
SELECT DISTINCT - + 86 * + cor0.col0 FROM tab0 AS cor0
----
-2064
-3010
-7654

query I rowsort
SELECT DISTINCT + + col0 * + col0 + + col1 AS col2 FROM tab2 cor0
----
6143
6258
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + col1 * col0 col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL - ( tab2.col2 ) * - col2 + - col2 FROM tab2
----
1406
650
702

query I rowsort
SELECT 5 * - col0 - + col2 AS col2 FROM tab1 cor0
----
-377
-496
-69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 + 51 col2 FROM tab2 AS cor0
----
110
68
82

query I rowsort
SELECT + - col0 + + ( + 78 * - cor0.col1 ) FROM tab0 AS cor0
----
-6732
-7187
-7601

onlyif mysql # use DIV operator for integer division
query I rowsort label-8145
SELECT ALL + + col0 * - col1 * + col0 + col2 DIV col1 FROM tab2 cor0
----
-106095
-1519
-358956

skipif mysql # not compatible
query I rowsort label-8145
SELECT ALL + + col0 * - col1 * + col0 + col2 / col1 FROM tab2 cor0
----
-106095
-1519
-358956

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8146
SELECT DISTINCT + col1 + CAST( NULL AS SIGNED ) + - col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8146
SELECT DISTINCT + col1 + CAST ( NULL AS INTEGER ) + - col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL col0 + - col0 * - col1 * col0 + + col1 FROM tab1 AS cor0
----
263
41034
83293

query I rowsort
SELECT DISTINCT col1 * col2 + - col2 * col0 AS col2 FROM tab1
----
-3078
-6432
1242

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * col2 + + col2 col0 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT col2 * - col0 + col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT + col2 + - ( cor0.col0 ) * - col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT ALL - - 50 + cor0.col0 AS col2 FROM tab0 AS cor0
----
139
74
85

query I rowsort
SELECT ALL - 30 * col0 AS col0 FROM tab0 cor0
----
-1050
-2670
-720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8154
SELECT DISTINCT CAST( NULL AS SIGNED ) * - 71 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8154
SELECT DISTINCT CAST ( NULL AS INTEGER ) * - 71 FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8155
SELECT ALL + + ( ( col0 ) ) * + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8155
SELECT ALL + + ( ( col0 ) ) * + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8156
SELECT + 92 DIV 23 AS col2 FROM tab0 AS cor0
----
4
4
4

skipif mysql # not compatible
query I rowsort label-8156
SELECT + 92 / 23 AS col2 FROM tab0 AS cor0
----
4
4
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 13 col1 FROM tab1 AS cor0
----
13

query I rowsort
SELECT 26 * col2 + col1 AS col1 FROM tab2 AS cor0
----
1005
733
735

onlyif mysql # use DIV operator for integer division
query I rowsort label-8159
SELECT DISTINCT ( + col0 ) DIV - col0 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-8159
SELECT DISTINCT ( + col0 ) / - col0 FROM tab0
----
-1

query I rowsort
SELECT DISTINCT 57 + - col1 * col2 AS col2 FROM tab0 AS cor0
----
-2781
-40
-7405

query I rowsort
SELECT ALL - cor0.col2 - col2 AS col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT - ( - ( - cor0.col0 ) ) + + cor0.col0 * + 27 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 350f2cee479f5b8ae58879fa937728c2

query I rowsort
SELECT - ( + 9 ) - - tab2.col0 AS col0 FROM tab2
----
-2
69
70

query I rowsort
SELECT 57 + col1 * + col1 FROM tab2
----
1018
346
3538

query I rowsort
SELECT - 16 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to be22ac76b42c6f7212ecc0ba7c89eb34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8166
SELECT - CAST( 92 AS SIGNED ) col2 FROM tab2 AS cor0
----
-92
-92
-92

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8166
SELECT - CAST ( 92 AS INTEGER ) col2 FROM tab2 AS cor0
----
-92
-92
-92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + col1 col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL - 96 * col0 AS col2 FROM tab2 AS cor0
----
-672
-7488
-7584

query I rowsort
SELECT DISTINCT + 67 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab2 AS cor2
----
67

query I rowsort
SELECT col2 * col1 + - col1 AS col0 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT col2 + tab1.col1 + - col1 AS col1 FROM tab1
----
54
57
96

query I rowsort
SELECT - + col2 + col0 + col0 FROM tab2 AS cor0
----
-13
120
130

onlyif mysql # use DIV operator for integer division
query I rowsort label-8173
SELECT - col2 * col1 + 76 DIV cor0.col0 FROM tab0 AS cor0
----
-2835
-7462
-95

skipif mysql # not compatible
query I rowsort label-8173
SELECT - col2 * col1 + 76 / cor0.col0 FROM tab0 AS cor0
----
-2835
-7462
-95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8174
SELECT + - col0 * + CAST( col0 * col2 + ( col1 ) AS SIGNED ) FROM tab1 AS cor0
----
-234112
-564
-615440

skipif mysql # not compatible
query I rowsort label-8174
SELECT + - col0 * + CAST ( col0 * col2 + ( col1 ) AS INTEGER ) FROM tab1 AS cor0
----
-234112
-564
-615440

query I rowsort
SELECT col2 * - ( - col2 ) AS col1 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT - ( col2 + 17 ) * col1 FROM tab0
----
-1746
-4300
-9009

query I rowsort
SELECT DISTINCT ( col2 ) * + col0 AS col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT DISTINCT + + cor0.col1 * + 56 AS col2 FROM tab1 cor0
----
1456
560
728

query I rowsort
SELECT ALL + col1 * + col2 + col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT - col0 * + 90 + + col2 FROM tab1 AS cor0
----
-216
-5703
-7104

onlyif mysql # use DIV operator for integer division
query I rowsort label-8181
SELECT + col1 - ( col0 ) DIV - col1 col2 FROM tab2 cor0
----
21
31
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8181
SELECT + col1 - ( col0 ) / - col1 col2 FROM tab2 cor0
----
21
31
60

query I rowsort
SELECT ALL col2 + + 59 + col2 AS col1 FROM tab2
----
111
113
135

query I rowsort
SELECT DISTINCT 63 AS col1 FROM tab1, tab0 cor0
----
63

query I rowsort
SELECT DISTINCT + col2 + + col1 * col0 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT col0 * ( col1 ) - col0 * + col2 FROM tab2
----
-1659
2574
28

query I rowsort
SELECT + col2 + 5 FROM tab1
----
101
59
62

query I rowsort
SELECT DISTINCT + tab0.col1 * + col2 * ( + tab0.col2 ) + col2 + 74 AS col1 FROM tab0
----
172
612040
93761

query I rowsort
SELECT + col2 * - col2 + col2 FROM tab0 cor0
----
-1056
-6642
0

query I rowsort
SELECT DISTINCT + col0 * + 6 * + col0 + col2 AS col2 FROM tab0
----
3489
47608
7351

query I rowsort
SELECT DISTINCT - tab0.col0 + - col2 * col1 + + col1 FROM tab0
----
-2776
-35
-7460

query I rowsort
SELECT col1 + + col2 - col2 * - col1 FROM tab1
----
1357
1484
637

query I rowsort
SELECT DISTINCT - tab1.col0 + 24 * cor0.col0 AS col1 FROM tab1, tab2, tab1 AS cor0
----
9 values hashing to d7acb5ec9403de21e85fc3126d2f7397

onlyif mysql # use DIV operator for integer division
query I rowsort label-8193
SELECT + col0 DIV ( + 38 ) + + col1 DIV ( - tab1.col1 ) + - col1 FROM tab1
----
-10
-12
-27

skipif mysql # not compatible
query I rowsort label-8193
SELECT + col0 / ( + 38 ) + + col1 / ( - tab1.col1 ) + - col1 FROM tab1
----
-10
-12
-27

query I rowsort
SELECT - col1 + ( + 98 ) FROM tab1
----
72
85
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8195
SELECT DISTINCT + CAST( + col0 AS SIGNED ) col0 FROM tab2
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8195
SELECT DISTINCT + CAST ( + col0 AS INTEGER ) col0 FROM tab2
----
7
78
79

query I rowsort
SELECT - ( 39 ) AS col1 FROM tab0
----
-39
-39
-39

query I rowsort
SELECT DISTINCT + + col0 * + col0 + col0 AS col2 FROM tab1 AS cor0
----
12
4160
6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 82 col1 FROM tab1 cor0
----
82
82
82

query I rowsort
SELECT cor0.col0 * - cor0.col0 AS col2 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT + col1 + + 50 FROM tab1
----
60
63
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 52 col1 FROM tab2
----
-52
-52
-52

query I rowsort
SELECT + - col2 - - col2 * - col1 AS col0 FROM tab2 cor0
----
-1560
-684
-864

query I rowsort
SELECT + + 74 * - col2 FROM tab2 AS cor0
----
-1924
-1998
-2812

query I rowsort
SELECT ALL 52 * 3 * col2 FROM tab2 AS cor0
----
4056
4212
5928

query I rowsort
SELECT 78 * - col1 + col2 AS col2 FROM tab0
----
-6675
-7016
-7565

query I rowsort
SELECT DISTINCT - col1 + 57 AS col0 FROM tab0
----
-29
-34
-40

query I rowsort
SELECT ALL - 92 + tab0.col0 FROM tab0
----
-3
-57
-68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8208
SELECT DISTINCT CAST( NULL AS SIGNED ) + - ( col1 + 4 * col2 ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-8208
SELECT DISTINCT CAST ( NULL AS INTEGER ) + - ( col1 + 4 * col2 ) FROM tab1
----
NULL

query I rowsort
SELECT + - 0 * - col0 + - col2 AS col0 FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-8210
SELECT DISTINCT - col0 DIV col0 + col1 FROM tab2 cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-8210
SELECT DISTINCT - col0 / col0 + col1 FROM tab2 cor0
----
16
30
58

query I rowsort
SELECT cor0.col1 - - 87 AS col0 FROM tab2, tab1 cor0, tab0 AS cor1
----
27 values hashing to 92ed391e1e0dfe246e05f91b5252c355

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8212
SELECT ALL - - CAST( 76 AS SIGNED ) * + col2 * 58 + + col0 AS col2 FROM tab1 cor0
----
238035
251320
423248

skipif mysql # not compatible
query I rowsort label-8212
SELECT ALL - - CAST ( 76 AS INTEGER ) * + col2 * 58 + + col0 AS col2 FROM tab1 cor0
----
238035
251320
423248

query I rowsort
SELECT ( - cor0.col2 ) AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT + + col0 + 86 * + cor0.col2 FROM tab2 AS cor0
----
2314
2329
3347

query I rowsort
SELECT - + col1 + + 75 AS col2 FROM tab0 AS cor0
----
-11
-16
-22

query I rowsort
SELECT DISTINCT - - ( - 33 ) * - cor0.col1 FROM tab2 AS cor0
----
1023
1947
561

query I rowsort
SELECT - cor0.col2 + col2 * - col0 AS col0 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT DISTINCT + 69 * + 49 FROM tab1 AS cor0
----
3381

onlyif mysql # use DIV operator for integer division
query I rowsort label-8219
SELECT ALL + + 8 + col0 DIV col1 FROM tab1 AS cor0
----
14
14
8

skipif mysql # not compatible
query I rowsort label-8219
SELECT ALL + + 8 + col0 / col1 FROM tab1 AS cor0
----
14
14
8

query I rowsort
SELECT DISTINCT - 41 AS col2 FROM tab2 AS cor0
----
-41

query I rowsort
SELECT + - 18 + + col1 * col0 FROM tab0 AS cor0
----
2046
3377
8081

query I rowsort
SELECT ALL - + 43 * - col1 + - col1 FROM tab0 cor0
----
3612
3822
4074

onlyif mysql # use DIV operator for integer division
query I rowsort label-8223
SELECT DISTINCT - 15 DIV col0 - - 36 DIV - 13 FROM tab0 AS cor0
----
-2

skipif mysql # not compatible
query I rowsort label-8223
SELECT DISTINCT - 15 / col0 - - 36 / - 13 FROM tab0 AS cor0
----
-2

query I rowsort
SELECT DISTINCT - + cor0.col2 * + col2 + col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT ALL - 58 + col2 FROM tab0 AS cor0
----
-25
-57
24

query I rowsort
SELECT ALL - 54 * + col2 + - col2 FROM tab0 AS cor0
----
-1815
-4510
-55

query I rowsort
SELECT ALL + - col2 + cor0.col0 AS col1 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT ALL + + 59 + - col1 AS col2 FROM tab2 AS cor0
----
0
28
42

query I rowsort
SELECT 38 + - cor0.col2 AS col0 FROM tab2 cor0
----
0
11
12

query I rowsort
SELECT DISTINCT - + col1 + - col2 - - cor0.col1 AS col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 7 + + ( + tab2.col0 ) * + 24 col2 FROM tab2
----
161
1865
1889

query I rowsort
SELECT + - col1 + + col2 AS col2 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT ALL 77 + col0 * + col2 * - col2 AS col1 FROM tab0
----
-26059
-598359
42

query I rowsort
SELECT ALL 31 AS col0 FROM tab0, tab1, tab0 cor0
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

query I rowsort
SELECT DISTINCT + col2 * - 95 FROM tab0 cor0
----
-3135
-7790
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-8236
SELECT ALL col2 DIV - 4 FROM tab1 AS cor0
----
-13
-14
-24

skipif mysql # not compatible
query I rowsort label-8236
SELECT ALL col2 / - 4 FROM tab1 AS cor0
----
-13
-14
-24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 + - ( - col2 ) col1 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT DISTINCT + - 62 AS col1 FROM tab1, tab0, tab0 AS cor0
----
-62

query I rowsort
SELECT + 47 AS col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

onlyif mysql # use DIV operator for integer division
query I rowsort label-8240
SELECT DISTINCT col0 + - col0 DIV + col1 AS col2 FROM tab2 AS cor0
----
7
75
77

skipif mysql # not compatible
query I rowsort label-8240
SELECT DISTINCT col0 + - col0 / + col1 AS col2 FROM tab2 AS cor0
----
7
75
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8241
SELECT + col2 + CAST( NULL AS DECIMAL ) / col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8241
SELECT + col2 + CAST ( NULL AS REAL ) / col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8242
SELECT col0 * ( col0 ) DIV + col2 AS col0 FROM tab0 AS cor0
----
1225
17
96

skipif mysql # not compatible
query I rowsort label-8242
SELECT col0 * ( col0 ) / + col2 AS col0 FROM tab0 AS cor0
----
1225
17
96

query I rowsort
SELECT ALL - col0 + 76 AS col2 FROM tab0 cor0
----
-13
41
52

query I rowsort
SELECT ALL - - col1 * 50 + - ( + cor0.col1 ) AS col1 FROM tab2 AS cor0
----
1519
2891
833

onlyif mysql # use DIV operator for integer division
query I rowsort label-8245
SELECT ALL - - 85 + col1 * - col2 - + CAST( col2 AS SIGNED ) DIV col0 FROM tab2 AS cor0
----
-1449
-561
-755

skipif mysql # not compatible
query I rowsort label-8245
SELECT ALL - - 85 + col1 * - col2 - + CAST ( col2 AS INTEGER ) / col0 FROM tab2 AS cor0
----
-1449
-561
-755

query I rowsort
SELECT DISTINCT + ( + 14 ) * col0 FROM tab1 AS cor0
----
1120
42
896

query I rowsort
SELECT - col1 + ( ( col0 ) + 28 ) FROM tab1
----
5
82
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 18 col1 FROM tab2 cor0 CROSS JOIN tab2, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to a13db73ec93475d2821cb4a6d0eff298

query I rowsort
SELECT col2 * + col1 - - tab2.col2 FROM tab2
----
1560
684
864

query I rowsort
SELECT ( - col1 ) + col0 * + col2 AS col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT 74 * col1 AS col2 FROM tab1 AS cor0
----
1924
740
962

query I rowsort
SELECT + ( col1 ) * - col2 * col2 FROM tab2 cor0
----
-22599
-24548
-39884

query I rowsort
SELECT ALL col1 * - ( + col0 ) FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT col1 * + 28 * col0 + col2 AS col2 FROM tab2
----
128882
37642
6103

query I rowsort
SELECT col1 * ( + col0 ) AS col0 FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8256
SELECT DISTINCT + + CAST( + col1 AS SIGNED ) * col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-8256
SELECT DISTINCT + + CAST ( + col1 AS INTEGER ) * col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + + 12 AS col0 FROM tab0 AS cor0
----
12

query I rowsort
SELECT + 68 + ( + col0 ) * ( col0 + col1 ) AS col1 FROM tab1 AS cor0
----
155
4804
7508

query I rowsort
SELECT ALL + 61 AS col0 FROM tab1 AS cor0
----
61
61
61

query I rowsort
SELECT ALL - + 43 AS col0 FROM tab2 AS cor0
----
-43
-43
-43

query I rowsort
SELECT - col0 * col1 * - col1 AS col2 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT ALL - 25 * 9 + - col1 AS col1 FROM tab0 cor0
----
-311
-316
-322

query I rowsort
SELECT DISTINCT col1 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT - + col2 + + cor0.col0 * - col0 FROM tab0 AS cor0
----
-1226
-609
-8003

query I rowsort
SELECT ALL + col2 * - col1 + col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT 22 * col1 + + col2 * + col2 FROM tab0 AS cor0
----
2135
2981
8726

query I rowsort
SELECT ALL - ( + col2 ) * col0 AS col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL col0 + ( + col2 ) FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - cor0.col1 + + 6 AS col0 FROM tab1 cor0
----
-20
-4
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8270
SELECT DISTINCT - col1 + ( col0 ) DIV - cor0.col2 FROM tab0 cor0
----
-132
-86
-92

skipif mysql # not compatible
query I rowsort label-8270
SELECT DISTINCT - col1 + ( col0 ) / - cor0.col2 FROM tab0 cor0
----
-132
-86
-92

query I rowsort
SELECT + - cor0.col1 * 20 * - col1 + - cor0.col1 FROM tab1 AS cor0
----
13494
1990
3367

query I rowsort
SELECT DISTINCT - col1 * col0 + - col0 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT ALL col0 + 17 FROM tab0 cor0
----
106
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col1 col2 FROM tab1 WHERE NOT ( NULL ) <= - col2 + - col2
----

query I rowsort
SELECT ALL + col1 * col0 + - col2 + + col1 FROM tab0 AS cor0
----
2117
3491
8108

query I rowsort
SELECT DISTINCT - + col0 + col2 * col2 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT col0 * col1 * col0 AS col0 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT col0 * + col2 + col1 * col0 FROM tab0 AS cor0
----
15397
2856
3430

query I rowsort
SELECT - col0 * col2 + + col1 AS col2 FROM tab1
----
-136
-3638
-7667

query III rowsort
SELECT * FROM tab1 WHERE NOT ( + col0 ) < col0 + col0
----

query I rowsort
SELECT col1 * - col0 + tab1.col0 * - tab1.col1 * col0 AS col0 FROM tab1
----
-312
-41600
-84240

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT col0 * + col1 / col0 + col0 NOT IN ( + col2 )
----

query I rowsort
SELECT + col0 + - col2 + + col2 * col0 AS col2 FROM tab0 cor0
----
69
7305
783

query I rowsort
SELECT + + col0 - - col1 * + col1 AS col2 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT + + col0 - - col0 * col2 AS col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT - - col2 * col0 - - col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL - col2 * col0 + col0 * col1 + - tab0.col2 * + col1 FROM tab0
----
-1566
-6661
3263

onlyif mysql # use DIV operator for integer division
query I rowsort label-8288
SELECT ALL - col2 + + col1 DIV col1 FROM tab2
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-8288
SELECT ALL - col2 + + col1 / col1 FROM tab2
----
-25
-26
-37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8289
SELECT - cor0.col1 * col2 + - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8289
SELECT - cor0.col1 * col2 + - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8290
SELECT ALL 58 + col1 * - CAST( NULL AS SIGNED ) * - col0 - + col0 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8290
SELECT ALL 58 + col1 * - CAST ( NULL AS INTEGER ) * - col0 - + col0 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col1 * + col1 AS col2 FROM tab0 cor0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-8292
SELECT ALL - cor0.col2 DIV 34 AS col0 FROM tab1 AS cor0
----
-1
-1
-2

skipif mysql # not compatible
query I rowsort label-8292
SELECT ALL - cor0.col2 / 34 AS col0 FROM tab1 AS cor0
----
-1
-1
-2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8293
SELECT ALL - col1 * CAST( NULL AS SIGNED ) + + col1 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8293
SELECT ALL - col1 * CAST ( NULL AS INTEGER ) + + col1 * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8294
SELECT ALL + col1 - - 41 DIV 50 AS col2 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-8294
SELECT ALL + col1 - - 41 / 50 AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT - + col1 + + cor0.col0 * col2 * - col2 - + col2 * ( + col0 ) * - col2 FROM tab2 AS cor0
----
-17
-31
-59

query III rowsort
SELECT ALL * FROM tab2 WHERE NULL > - col1 + col0
----

query III rowsort
SELECT ALL * FROM tab2 WHERE ( col2 / col1 ) NOT IN ( tab2.col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query III rowsort
SELECT * FROM tab1 WHERE NOT ( - col2 ) <> NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - + col1 * col0 col1 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT col0 + - col2 * col2 * col2 FROM tab2
----
-17498
-19676
-54793

query I rowsort
SELECT ALL col1 AS col1 FROM tab0 WHERE col2 * col2 IN ( - col0 + + col1 )
----

query I rowsort
SELECT ALL - col2 * + col1 FROM tab2 WHERE NULL <> - col1 + - col1
----

query I rowsort
SELECT - col0 + col0 + col1 FROM tab2
----
17
31
59

query I rowsort
SELECT ALL col0 FROM tab2 WHERE NOT ( NULL ) <= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8305
SELECT tab1.col2 DIV tab1.col0 col2 FROM tab1
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8305
SELECT tab1.col2 / tab1.col0 col2 FROM tab1
----
0
1
18

query I rowsort
SELECT col1 + - col1 - - tab0.col0 FROM tab0
----
24
35
89

query I rowsort
SELECT col2 + - col2 + tab1.col2 FROM tab1
----
54
57
96

query III rowsort
SELECT ALL * FROM tab1 WHERE ( NULL ) IN ( + col1 )
----

query I rowsort
SELECT + 61 * + tab1.col2 + tab1.col1 AS col0 FROM tab1
----
3320
3487
5869

query I rowsort
SELECT - 37 + cor0.col2 - - cor0.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to aedf1b0354e825f694c8d9d9ca6f2936

query I rowsort
SELECT 39 AS col0 FROM tab0 AS cor0
----
39
39
39

query I rowsort
SELECT - + col0 + - col2 AS col1 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT + col2 + + 91 FROM tab0 AS cor0
----
124
173
92

query I rowsort
SELECT DISTINCT - col0 * - col1 + - 53 FROM tab0 AS cor0
----
2011
3342
8046

query I rowsort
SELECT DISTINCT - cor0.col2 + - ( + cor0.col0 ) * - col1 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT ALL + - col2 + 23 AS col1 FROM tab0 AS cor0
----
-10
-59
22

onlyif mysql # use DIV operator for integer division
query I rowsort label-8317
SELECT ALL + col2 DIV col0 - - col0 FROM tab0 AS cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-8317
SELECT ALL + col2 / col0 - - col0 FROM tab0 AS cor0
----
25
35
89

query I rowsort
SELECT ALL col0 + - tab2.col0 AS col0 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8319
SELECT DISTINCT + + col0 + + col1 DIV - cor0.col2 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-8319
SELECT DISTINCT + + col0 + + col1 / - cor0.col2 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8320
SELECT DISTINCT col2 DIV ( - col2 + col0 ) FROM tab1 AS cor0
----
-1
-6
8

skipif mysql # not compatible
query I rowsort label-8320
SELECT DISTINCT col2 / ( - col2 + col0 ) FROM tab1 AS cor0
----
-1
-6
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-8321
SELECT + col2 + col0 DIV + col0 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-8321
SELECT + col2 + col0 / + col0 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT ALL + col0 * cor0.col1 + - col2 FROM tab2 cor0
----
1305
190
4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-8323
SELECT - col2 * + tab1.col2 + ( 54 ) * col2 DIV col0 FROM tab1
----
-1944
-3201
-9152

skipif mysql # not compatible
query I rowsort label-8323
SELECT - col2 * + tab1.col2 + ( 54 ) * col2 / col0 FROM tab1
----
-1944
-3201
-9152

query I rowsort
SELECT DISTINCT - 31 AS col2 FROM tab2, tab0, tab0 AS cor0
----
-31

query I rowsort
SELECT ALL + col1 + - ( col0 ) * col2 FROM tab0 AS cor0
----
-706
-7207
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col2 - col1 * + col1 col1 FROM tab0 AS cor0
----
-7429
-8363
-9410

query I rowsort
SELECT DISTINCT - - col1 + - cor0.col0 * - col2 AS col2 FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT + - col2 - - col0 * + col1 * - col2 FROM tab2 cor0
----
-119678
-51072
-5886

onlyif mysql # use DIV operator for integer division
query I rowsort label-8329
SELECT - col2 + - col0 DIV + col0 AS col1 FROM tab2 AS cor0
----
-27
-28
-39

skipif mysql # not compatible
query I rowsort label-8329
SELECT - col2 + - col0 / + col0 AS col1 FROM tab2 AS cor0
----
-27
-28
-39

query I rowsort
SELECT ALL + col0 + + col1 * cor0.col2 AS col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT + + ( + 7 ) * cor0.col0 FROM tab1 AS cor0
----
21
448
560

query I rowsort
SELECT DISTINCT col2 - 46 * - col2 FROM tab2 cor0
----
1222
1269
1786

query I rowsort
SELECT DISTINCT col2 + + 75 * col1 FROM tab2 AS cor0
----
1313
2352
4451

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( 16 ) * + col2 + col0 col2 FROM tab1 AS cor0
----
-1456
-848
-861

query I rowsort
SELECT DISTINCT - ( - col2 ) + - col2 AS col2 FROM tab1 cor0
----
0

query I rowsort
SELECT - - 11 * cor0.col2 AS col2 FROM tab2 AS cor0
----
286
297
418

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8337
SELECT ALL + CAST( col1 AS SIGNED ) FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-8337
SELECT ALL + CAST ( col1 AS INTEGER ) FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + col0 * 56 AS col0 FROM tab2 AS cor0
----
392
4368
4424

query I rowsort
SELECT ALL 38 * + cor0.col2 FROM tab2 AS cor0
----
1026
1444
988

onlyif mysql # use DIV operator for integer division
query I rowsort label-8340
SELECT + 24 DIV 34 AS col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8340
SELECT + 24 / 34 AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - - ( - col1 ) * col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + - 17 + - col0 AS col0 FROM tab2 cor0
----
-24
-95
-96

query I rowsort
SELECT DISTINCT - cor0.col0 * + col1 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + cor0.col0 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL 68 * + col0 AS col1 FROM tab0 AS cor0
----
1632
2380
6052

query I rowsort
SELECT ALL + 64 AS col1 FROM tab2
----
64
64
64

query I rowsort
SELECT + col2 * - col0 + - col0 FROM tab2
----
-196
-2106
-3081

query I rowsort
SELECT + - col0 + - col2 + - cor0.col2 * + col0 FROM tab1 AS cor0
----
-219
-3769
-7856

onlyif mysql # use DIV operator for integer division
query I rowsort label-8349
SELECT ALL - col2 DIV - col2 col2 FROM tab1 cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8349
SELECT ALL - col2 / - col2 col2 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT - + ( cor0.col0 ) * + col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL - 3 AS col0 FROM tab2 AS cor0
----
-3
-3
-3

query I rowsort
SELECT DISTINCT - 32 + + col1 * cor0.col0 FROM tab1 AS cor0
----
1008
46
608

query I rowsort
SELECT ALL - 23 AS col0 FROM tab1 cor0
----
-23
-23
-23

onlyif mysql # use DIV operator for integer division
query I rowsort label-8354
SELECT + col0 * col0 + col0 * col0 DIV - col1 FROM tab1
----
3687
5908
9

skipif mysql # not compatible
query I rowsort label-8354
SELECT + col0 * col0 + col0 * col0 / - col1 FROM tab1
----
3687
5908
9

query I rowsort
SELECT ALL - 36 + - col0 AS col0 FROM tab2
----
-114
-115
-43

query I rowsort
SELECT DISTINCT 8 + col2 + + col2 * col2 AS col0 FROM tab2
----
1490
710
764

onlyif mysql # use DIV operator for integer division
query I rowsort label-8357
SELECT DISTINCT + tab0.col0 + col0 * col1 + + col1 DIV - col2 FROM tab0
----
2086
3333
8187

skipif mysql # not compatible
query I rowsort label-8357
SELECT DISTINCT + tab0.col0 + col0 * col1 + + col1 / - col2 FROM tab0
----
2086
3333
8187

query I rowsort
SELECT DISTINCT + col0 + 95 AS col2 FROM tab0
----
119
130
184

query I rowsort
SELECT DISTINCT - 47 * col2 FROM tab0
----
-1551
-3854
-47

query I rowsort
SELECT - col0 + - cor0.col2 * col0 FROM tab1 AS cor0
----
-165
-3712
-7760

query I rowsort
SELECT + ( col1 ) * - cor0.col0 + col2 AS col0 FROM tab0 AS cor0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + 75 col1 FROM tab2
----
37
48
49

query I rowsort
SELECT - ( 93 ) FROM tab1, tab0 AS cor0
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

query I rowsort
SELECT DISTINCT - col2 + + col2 * - col0 FROM tab2 cor0
----
-2054
-216
-3040

query I rowsort
SELECT - col2 + 78 * col1 FROM tab1
----
1974
723
918

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab0.col1 + - 13 * - ( col0 ) * + col1 col2 FROM tab0
----
105196
26746
44038

query I rowsort
SELECT col0 + + col0 - + col1 AS col1 FROM tab1
----
-20
118
147

query I rowsort
SELECT DISTINCT col1 * 24 + col1 * - tab1.col2 * - col1 FROM tab1
----
16536
37128
5940

query I rowsort
SELECT col2 * - col2 * - col1 FROM tab1
----
119808
32490
75816

onlyif mysql # use DIV operator for integer division
query I rowsort label-8370
SELECT col1 + col2 DIV + col2 AS col0 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-8370
SELECT col1 + col2 / + col2 AS col0 FROM tab1
----
11
14
27

query I rowsort
SELECT + col0 * - col2 + col2 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT 20 * col2 * col2 AS col2 FROM tab0
----
134480
20
21780

query I rowsort
SELECT DISTINCT ( + col0 + - col2 ) * col1 FROM tab2
----
-620
3068
697

query I rowsort
SELECT ALL - ( ( col1 ) ) + - col1 * + col2 AS col1 FROM tab0 AS cor0
----
-194
-2924
-7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8375
SELECT + - CAST( NULL AS DECIMAL ) * 0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8375
SELECT + - CAST ( NULL AS REAL ) * 0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8376
SELECT - CAST( col2 AS SIGNED ) * + col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

skipif mysql # not compatible
query I rowsort label-8376
SELECT - CAST ( col2 AS INTEGER ) * + col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL + 96 * - col2 + col1 AS col0 FROM tab2 AS cor0
----
-2437
-2561
-3631

query I rowsort
SELECT - ( - ( col0 ) ) AS col2 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8379
SELECT ( - col0 ) DIV + cor0.col2 + - 71 - - 48 DIV + col0 FROM tab1 AS cor0
----
-55
-71
-72

skipif mysql # not compatible
query I rowsort label-8379
SELECT ( - col0 ) / + cor0.col2 + - 71 - - 48 / + col0 FROM tab1 AS cor0
----
-55
-71
-72

query I rowsort
SELECT + - col0 * col0 + - col1 FROM tab0 AS cor0
----
-1322
-662
-8012

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( col1 ) + col1 col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8382
SELECT + CAST( 36 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
36
36
36

skipif mysql # not compatible
query I rowsort label-8382
SELECT + CAST ( 36 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
36
36
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-8383
SELECT - + col0 * + col1 DIV - col1 - 19 AS col1 FROM tab2 cor0
----
-12
59
60

skipif mysql # not compatible
query I rowsort label-8383
SELECT - + col0 * + col1 / - col1 - 19 AS col1 FROM tab2 cor0
----
-12
59
60

query I rowsort
SELECT DISTINCT - col1 * 28 FROM tab2
----
-1652
-476
-868

onlyif mysql # use DIV operator for integer division
query I rowsort label-8385
SELECT DISTINCT - col1 DIV 10 FROM tab0 AS cor0
----
-8
-9

skipif mysql # not compatible
query I rowsort label-8385
SELECT DISTINCT - col1 / 10 FROM tab0 AS cor0
----
-8
-9

query I rowsort
SELECT + 12 * + col2 AS col2 FROM tab2 cor0
----
312
324
456

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8387
SELECT ALL - CAST( NULL AS DECIMAL ) + col1 * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8387
SELECT ALL - CAST ( NULL AS REAL ) + col1 * col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 56 AS col1 FROM tab2 AS cor0
----
-56

onlyif mysql # use DIV operator for integer division
query I rowsort label-8389
SELECT DISTINCT + cor0.col2 DIV col2 + ( - 59 ) AS col1 FROM tab0 cor0
----
-58

skipif mysql # not compatible
query I rowsort label-8389
SELECT DISTINCT + cor0.col2 / col2 + ( - 59 ) AS col1 FROM tab0 cor0
----
-58

query I rowsort
SELECT + col0 - - col0 AS col0 FROM tab2
----
14
156
158

query I rowsort
SELECT - + col1 + + col0 * col2 AS col1 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT DISTINCT + 14 - tab1.col1 AS col2 FROM tab1
----
-12
1
4

query I rowsort
SELECT ALL 70 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT - 8 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 47f43f23dcd23959d97d8e3b0aab692e

onlyif mysql # use DIV operator for integer division
query I rowsort label-8395
SELECT + col2 * col0 DIV col1 FROM tab1 AS cor0
----
364
590
6

skipif mysql # not compatible
query I rowsort label-8395
SELECT + col2 * col0 / col1 FROM tab1 AS cor0
----
364
590
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-8396
SELECT - col2 + - col0 DIV 67 FROM tab1 AS cor0
----
-54
-57
-97

skipif mysql # not compatible
query I rowsort label-8396
SELECT - col2 + - col0 / 67 FROM tab1 AS cor0
----
-54
-57
-97

query I rowsort
SELECT ALL - 86 * - cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8df2cafda51d55562509bfd0892e3b97

query I rowsort
SELECT - col1 - 16 * col2 * + col2 AS col0 FROM tab2
----
-10875
-11695
-23121

query I rowsort
SELECT col0 * 30 + 49 FROM tab1
----
139
1969
2449

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col2 col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT - col2 * + 0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 4 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8403
SELECT + CAST( - 43 AS SIGNED ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 4f17f941ddb7d7f35d93196515cfe0f2

skipif mysql # not compatible
query I rowsort label-8403
SELECT + CAST ( - 43 AS INTEGER ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 4f17f941ddb7d7f35d93196515cfe0f2

query I rowsort
SELECT DISTINCT ( 43 ) * - cor0.col1 FROM tab1, tab1 AS cor0
----
-1118
-430
-559

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8405
SELECT + cor0.col0 + - CAST( col2 AS SIGNED ) * col1 FROM tab0 AS cor0
----
-2814
-62
-7373

skipif mysql # not compatible
query I rowsort label-8405
SELECT + cor0.col0 + - CAST ( col2 AS INTEGER ) * col1 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT col0 + 18 FROM tab1
----
21
82
98

query I rowsort
SELECT col1 + ( col0 ) AS col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT 85 AS col0 FROM tab2, tab1 AS cor0
----
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8409
SELECT ALL cor0.col2 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-8409
SELECT ALL cor0.col2 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL col0 * + ( - col2 ) FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT 94 + + col1 FROM tab2 cor0
----
111
125
153

query I rowsort
SELECT DISTINCT + col1 * col2 * col1 + + cor0.col2 FROM tab1 AS cor0
----
16320
36558
5757

query I rowsort
SELECT + col2 * + tab2.col0 - + col2 AS col1 FROM tab2
----
162
2002
2964

query I rowsort
SELECT DISTINCT - - col0 * - col0 + - cor0.col1 * 99 AS col2 FROM tab0 AS cor0
----
-10828
-16930
-9090

query I rowsort
SELECT DISTINCT + col0 + col0 * ( 7 ) FROM tab1 AS cor0
----
24
512
640

query I rowsort
SELECT - + col0 + - col0 * col2 * col2 FROM tab0 AS cor0
----
-26160
-598525
-70

query I rowsort
SELECT - col2 + col2 * + cor0.col1 FROM tab1 cor0
----
1152
1350
513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 + - ( - col1 + col0 ) col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL + col2 * cor0.col0 - 74 FROM tab2 AS cor0
----
115
1954
2928

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8420
SELECT ALL + col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8420
SELECT ALL + col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 + - col1 * col2 + + col1 * col2 * col2 AS col1 FROM tab1 AS cor0
----
118573
31930
74438

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8422
SELECT DISTINCT - col2 + - CAST( NULL AS SIGNED ) * col1 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8422
SELECT DISTINCT - col2 + - CAST ( NULL AS INTEGER ) * col1 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort
SELECT ALL col1 + CAST ( - 77 AS REAL ) * - col0 * col1 AS col0 FROM tab0 cor0
----
159014
261512
623714

query I rowsort
SELECT ALL 48 * col1 AS col2 FROM tab0
----
4128
4368
4656

onlyif mysql # use DIV operator for integer division
query I rowsort label-8425
SELECT DISTINCT - + cor0.col2 * - col0 - + 52 DIV col1 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-8425
SELECT DISTINCT - + cor0.col2 * - col0 - + 52 / col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL + col0 + - 63 FROM tab0 AS cor0
----
-28
-39
26

query I rowsort
SELECT ALL + col2 * + col1 * col0 AS col1 FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT DISTINCT - col1 + + col2 * + 44 AS col1 FROM tab2 AS cor0
----
1085
1157
1655

query I rowsort
SELECT DISTINCT 41 * col0 FROM tab1
----
123
2624
3280

query I rowsort
SELECT DISTINCT + 34 + - col1 FROM tab2 cor0
----
-25
17
3

query I rowsort
SELECT + + col2 + col1 * col0 + - 65 AS col0 FROM tab1 AS cor0
----
1071
632
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 22 col1 FROM tab0 AS cor0
----
-22
-22
-22

query I rowsort
SELECT ALL + + cor0.col2 * cor0.col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - col2 * - 81 * col1 + + col1 + - col0 * + col0 AS col2 FROM tab1
----
113741
42084
94701

query I rowsort
SELECT DISTINCT col1 + 35 * - col2 * col1 AS col1 FROM tab2
----
-22593
-29264
-53631

query I rowsort
SELECT + - col0 * + 66 FROM tab0 AS cor0
----
-1584
-2310
-5874

query I rowsort
SELECT tab0.col2 + - ( col2 ) FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8438
SELECT col2 DIV + 87 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-8438
SELECT col2 / + 87 FROM tab1
----
0
0
1

query I rowsort
SELECT - tab1.col1 * + col1 AS col1 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT + - col0 + + cor0.col2 * col0 + + col1 AS col2 FROM tab0 AS cor0
----
7300
854
97

query I rowsort
SELECT - 45 * - col0 * cor0.col2 AS col2 FROM tab1 cor0
----
164160
345600
7290

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8442
SELECT ALL - CAST( NULL AS SIGNED ) * - col2 + col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8442
SELECT ALL - CAST ( NULL AS INTEGER ) * - col2 + col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 15 * col2 AS col0 FROM tab1
----
1440
810
855

onlyif mysql # use DIV operator for integer division
query I rowsort label-8444
SELECT ALL + col1 DIV col0 + + cor0.col2 * col0 FROM tab2 AS cor0
----
193
2028
3002

skipif mysql # not compatible
query I rowsort label-8444
SELECT ALL + col1 / col0 + + cor0.col2 * col0 FROM tab2 AS cor0
----
193
2028
3002

query I rowsort
SELECT DISTINCT col0 + - cor0.col1 + + col0 FROM tab2 AS cor0
----
-17
141
97

query I rowsort
SELECT DISTINCT - col2 * + col0 + col0 + cor0.col0 AS col2 FROM tab1 AS cor0
----
-156
-3520
-7520

query I rowsort
SELECT ALL 21 * + 4 FROM tab1 AS cor0
----
84
84
84

query I rowsort
SELECT 16 * - col2 AS col0 FROM tab2 AS cor0
----
-416
-432
-608

query I rowsort
SELECT ALL + cor0.col2 * + col1 + + cor0.col1 * - ( + cor0.col2 * col1 ) + - col1 FROM tab1 AS cor0
----
-14989
-35126
-5140

query I rowsort
SELECT ALL + cor0.col0 + 25 AS col2 FROM tab1 AS cor0
----
105
28
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8451
SELECT - col0 + 43 * col0 DIV 94 FROM tab1 AS cor0
----
-2
-35
-44

skipif mysql # not compatible
query I rowsort label-8451
SELECT - col0 + 43 * col0 / 94 FROM tab1 AS cor0
----
-2
-35
-44

query I rowsort
SELECT DISTINCT - 33 AS col2 FROM tab2
----
-33

query I rowsort
SELECT ALL - + cor0.col0 AS col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + col1 * + col2 ) col0 FROM tab1
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8455
SELECT - CAST( NULL AS SIGNED ) * + col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8455
SELECT - CAST ( NULL AS INTEGER ) * + col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( + col1 + + col2 * col0 ) AS col2 FROM tab1
----
-188
-3658
-7693

query I rowsort
SELECT ALL + 74 + + 45 AS col2 FROM tab2 AS cor0
----
119
119
119

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col1 col1 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT 85 * + col2 FROM tab2 cor0
----
2210
2295
3230

query I rowsort
SELECT ALL + 67 FROM tab0, tab2 AS cor0
----
9 values hashing to b56f8a4f1fcebc9802481256df61e97c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8461
SELECT - - cor0.col0 - CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-8461
SELECT - - cor0.col0 - CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT 82 + + cor0.col0 AS col2 FROM tab0 cor0
----
106
117
171

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 57 + cor0.col0 col0 FROM tab1 cor0
----
121
137
60

query I rowsort
SELECT col1 * col2 + - col1 * + col0 FROM tab0 AS cor0
----
-3298
-637
774

query I rowsort
SELECT ALL + + col0 * - col2 + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-8466
SELECT DISTINCT + ( col0 ) DIV + col2 col0 FROM tab1 cor0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8466
SELECT DISTINCT + ( col0 ) / + col2 col0 FROM tab1 cor0
----
0
1

query I rowsort
SELECT ALL - cor0.col1 * col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - ( - col1 * col2 ) AS col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT - 50 + - col0 AS col0 FROM tab0
----
-139
-74
-85

query I rowsort
SELECT + col2 - + ( col2 + cor0.col1 ) FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - col1 * col0 - - 82 FROM tab0 AS cor0
----
-1982
-3313
-8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8472
SELECT DISTINCT - col2 + CAST( 57 AS SIGNED ) FROM tab2 AS cor0
----
19
30
31

skipif mysql # not compatible
query I rowsort label-8472
SELECT DISTINCT - col2 + CAST ( 57 AS INTEGER ) FROM tab2 AS cor0
----
19
30
31

query I rowsort
SELECT ALL col2 + - 55 * + col1 FROM tab0 AS cor0
----
-4697
-4923
-5334

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * ( + col1 ) col0 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8475
SELECT ALL + col0 * CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-8475
SELECT ALL + col0 * CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT - cor0.col0 + - 53 FROM tab1 AS cor0
----
-117
-133
-56

query I rowsort
SELECT + col1 + 78 * col2 AS col2 FROM tab2 AS cor0
----
2087
2137
2981

query I rowsort
SELECT - cor0.col2 * ( col2 ) FROM tab0 cor0
----
-1
-1089
-6724

query I rowsort
SELECT - col1 - col0 AS col0 FROM tab1 cor0
----
-29
-74
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8480
SELECT - CAST( NULL AS SIGNED ) * + cor0.col0 + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8480
SELECT - CAST ( NULL AS INTEGER ) * + cor0.col0 + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 - + cor0.col2 * - col2 * - ( col1 ) FROM tab0 AS cor0
----
-611795
-62
-93630

query I rowsort
SELECT DISTINCT 77 FROM tab0, tab2 AS cor0, tab1 AS cor1, tab1 AS cor2
----
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-8483
SELECT DISTINCT tab2.col0 + ( tab2.col1 ) DIV - col0 FROM tab2
----
3
78
79

skipif mysql # not compatible
query I rowsort label-8483
SELECT DISTINCT tab2.col0 + ( tab2.col1 ) / - col0 FROM tab2
----
3
78
79

query I rowsort
SELECT DISTINCT + col0 * - col2 + col0 * col0 * + tab1.col2 FROM tab1
----
229824
324
606720

query I rowsort
SELECT + 56 FROM tab0, tab2 cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT DISTINCT + cor0.col1 - ( + col1 ) * col2 AS col0 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT + col1 * col1 * 87 FROM tab0 AS cor0
----
643452
720447
818583

query I rowsort
SELECT - ( + 46 ) + + col1 + col2 FROM tab1 AS cor0
----
21
34
63

query I rowsort
SELECT - ( + 68 ) FROM tab0 AS cor0
----
-68
-68
-68

query I rowsort
SELECT DISTINCT - 3 FROM tab0, tab1 AS cor0
----
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-8491
SELECT + - col0 DIV 27 + - col0 * col0 + - cor0.col0 FROM tab2 AS cor0
----
-56
-6164
-6322

skipif mysql # not compatible
query I rowsort label-8491
SELECT + - col0 / 27 + - col0 * col0 + - cor0.col0 FROM tab2 AS cor0
----
-56
-6164
-6322

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( - col0 ) + + col2 * + ( - col1 ) * - col2 + + col2 col0 FROM tab1 AS cor0
----
119984
32611
75873

query I rowsort
SELECT + col2 * + col2 * col2 FROM tab1 AS cor0
----
157464
185193
884736

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col1 + - 52 col1 FROM tab2, tab1, tab2 AS cor0
----
-21
-35
7

query I rowsort
SELECT + col0 * - col0 + - col1 AS col2 FROM tab1 AS cor0
----
-35
-4106
-6413

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8496
SELECT DISTINCT - CAST( NULL AS SIGNED ) * - col1 col1 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8496
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * - col1 col1 FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8497
SELECT DISTINCT + cor0.col1 + + col0 DIV - 50 FROM tab0 AS cor0
----
86
90
97

skipif mysql # not compatible
query I rowsort label-8497
SELECT DISTINCT + cor0.col1 + + col0 / - 50 FROM tab0 AS cor0
----
86
90
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8498
SELECT DISTINCT + + ( - col0 ) DIV col2 AS col1 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-8498
SELECT DISTINCT + + ( - col0 ) / col2 AS col1 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT ALL 78 + col2 * - col0 FROM tab1
----
-3570
-7602
-84

query I rowsort
SELECT + ( col2 * col0 ) + - col0 FROM tab1
----
159
3584
7600

query I rowsort
SELECT ALL + col1 * tab1.col1 AS col2 FROM tab1
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-8502
SELECT DISTINCT 24 DIV col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-8502
SELECT DISTINCT 24 / col1 FROM tab0
----
0

query I rowsort
SELECT + tab2.col2 * + col0 + col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT - ( - col1 + 51 ) FROM tab0
----
35
40
46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 84 * col1 * col1 col1 FROM tab2 AS cor0
----
24276
292404
80724

query I rowsort
SELECT ALL 91 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 8a48d0ac75792561e233f0311a8872fd

query I rowsort
SELECT col1 * + ( col1 ) * col2 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT ALL col0 * - col0 - + col2 AS col1 FROM tab0
----
-1226
-609
-8003

query I rowsort
SELECT col0 + col2 * + col0 - col2 FROM tab0
----
69
7305
783

query I rowsort
SELECT - col1 * tab0.col0 * tab0.col1 AS col1 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT + + col2 * 66 + + ( - col2 ) FROM tab1 AS cor0
----
3510
3705
6240

onlyif mysql # use DIV operator for integer division
query I rowsort label-8512
SELECT - + col1 DIV 18 + 97 AS col2 FROM tab0 AS cor0
----
92
92
93

skipif mysql # not compatible
query I rowsort label-8512
SELECT - + col1 / 18 + 97 AS col2 FROM tab0 AS cor0
----
92
92
93

query I rowsort
SELECT ALL col2 - + 91 AS col2 FROM tab2
----
-53
-64
-65

query I rowsort
SELECT ALL col0 * 95 * col1 - - col1 AS col1 FROM tab0
----
196166
322622
769496

query I rowsort
SELECT + col1 * - 3 * - col2 FROM tab2 AS cor0
----
1938
2511
4602

query I rowsort
SELECT + col0 * + ( - col1 ) AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - - col1 * 83 + col2 * col0 FROM tab1 AS cor0
----
2320
4478
8759

onlyif mysql # use DIV operator for integer division
query I rowsort label-8518
SELECT DISTINCT + col0 DIV 96 - col2 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-8518
SELECT DISTINCT + col0 / 96 - col2 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT + col2 * ( col1 ) AS col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT - + ( col1 ) * col2 + + col0 AS col0 FROM tab1 cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL - col2 * + col0 + col1 AS col1 FROM tab0 cor0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-8522
SELECT ALL - + 55 + + 6 DIV + col0 AS col1 FROM tab0 AS cor0
----
-55
-55
-55

skipif mysql # not compatible
query I rowsort label-8522
SELECT ALL - + 55 + + 6 / + col0 AS col1 FROM tab0 AS cor0
----
-55
-55
-55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8523
SELECT - ( + 20 ) * - col1 + - CAST( + col0 AS SIGNED ) + col0 AS col1 FROM tab1 AS cor0
----
200
260
520

skipif mysql # not compatible
query I rowsort label-8523
SELECT - ( + 20 ) * - col1 + - CAST ( + col0 AS INTEGER ) + col0 AS col1 FROM tab1 AS cor0
----
200
260
520

query I rowsort
SELECT DISTINCT - + col0 * 97 + - col1 * + ( + col1 ) FROM tab0 AS cor0
----
-12804
-16914
-9724

onlyif mysql # use DIV operator for integer division
query I rowsort label-8525
SELECT - cor0.col2 DIV col1 + col0 AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-8525
SELECT - cor0.col2 / col1 + col0 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL - col0 * cor0.col0 - - cor0.col2 AS col2 FROM tab0 cor0
----
-1224
-543
-7839

query I rowsort
SELECT DISTINCT + ( col2 ) * + col0 + ( + 42 * - col1 ) + col0 FROM tab1 AS cor0
----
-927
3292
7214

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8528
SELECT ALL CAST( NULL AS SIGNED ) + col1 + - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8528
SELECT ALL CAST ( NULL AS INTEGER ) + col1 + - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - cor0.col2 + col0 * - ( + col2 ) FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT ( + col0 ) * ( + col0 ) AS col1 FROM tab2
----
49
6084
6241

query I rowsort
SELECT col0 + col1 * + col1 + col0 FROM tab2
----
3637
447
975

onlyif mysql # use DIV operator for integer division
query I rowsort label-8532
SELECT - col2 * + ( + 9 ) - + col0 DIV - col0 AS col2 FROM tab2
----
-233
-242
-341

skipif mysql # not compatible
query I rowsort label-8532
SELECT - col2 * + ( + 9 ) - + col0 / - col0 AS col2 FROM tab2
----
-233
-242
-341

query I rowsort
SELECT col2 * - col0 - + col0 AS col1 FROM tab0
----
-70
-7387
-816

query I rowsort
SELECT + ( 55 ) AS col0 FROM tab0 AS cor0
----
55
55
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-8535
SELECT DISTINCT - col2 DIV col2 AS col0 FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-8535
SELECT DISTINCT - col2 / col2 AS col0 FROM tab1
----
-1

query I rowsort
SELECT col2 + - 63 FROM tab2
----
-25
-36
-37

query I rowsort
SELECT col0 + + 66 FROM tab0
----
101
155
90

query I rowsort
SELECT tab0.col1 * - tab0.col1 + - 39 AS col2 FROM tab0
----
-7435
-8320
-9448

query I rowsort
SELECT + tab0.col0 * + col0 AS col1 FROM tab0
----
1225
576
7921

query I rowsort
SELECT - col2 * - col0 + + 21 AS col1 FROM tab1 AS cor0
----
183
3669
7701

query I rowsort
SELECT + col1 * col1 + + 99 AS col0 FROM tab1 AS cor0
----
199
268
775

query I rowsort
SELECT ALL + - col1 * col0 + col0 * 47 FROM tab1 AS cor0
----
2368
2720
63

query I rowsort
SELECT + 40 + col1 - - col0 AS col0 FROM tab0 AS cor0
----
150
172
220

query I rowsort
SELECT ALL - 1 * + col2 AS col2 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-8545
SELECT - col1 DIV col1 + col1 FROM tab2 cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-8545
SELECT - col1 / col1 + col1 FROM tab2 cor0
----
16
30
58

query I rowsort
SELECT ALL - col2 * + col2 * + col2 FROM tab1 AS cor0
----
-157464
-185193
-884736

query I rowsort
SELECT col1 * - col1 - + col1 AS col1 FROM tab2 AS cor0
----
-306
-3540
-992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 * col0 col0 FROM tab2 AS cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 84 * - col1 col2 FROM tab1 cor0
----
-1092
-2184
-840

query I rowsort
SELECT DISTINCT + 49 * 33 * col0 - col0 FROM tab0
----
143824
38784
56560

query I rowsort
SELECT ALL - tab2.col0 * col0 + + tab2.col2 * - 53 FROM tab2
----
-1480
-7462
-8255

onlyif mysql # use DIV operator for integer division
query I rowsort label-8552
SELECT ALL - col1 DIV + cor0.col2 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8552
SELECT ALL - col1 / + cor0.col2 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + - col1 * col0 - - col1 AS col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT + - col1 * cor0.col0 + 91 * + 11 AS col2 FROM tab2 AS cor0
----
-342
-3601
784

query I rowsort
SELECT 76 + + col2 - col2 FROM tab1 AS cor0
----
76
76
76

query I rowsort
SELECT ALL tab0.col2 * col2 + col0 * col1 AS col2 FROM tab0
----
14823
3153
3396

onlyif mysql # use DIV operator for integer division
query I rowsort label-8557
SELECT ALL - col2 * col2 * ( col1 ) + - col1 DIV - col1 FROM tab1
----
-119807
-32489
-75815

skipif mysql # not compatible
query I rowsort label-8557
SELECT ALL - col2 * col2 * ( col1 ) + - col1 / - col1 FROM tab1
----
-119807
-32489
-75815

query I rowsort
SELECT - + col0 + + col2 * - col1 AS col0 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT + col2 * - col2 * + 20 FROM tab1 AS cor0
----
-184320
-58320
-64980

query I rowsort
SELECT + - col2 - col0 FROM tab2 cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-8561
SELECT 16 DIV + tab1.col2 AS col0 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8561
SELECT 16 / + tab1.col2 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT 99 * - col0 FROM tab0
----
-2376
-3465
-8811

query I rowsort
SELECT DISTINCT tab2.col2 + tab2.col0 * col2 AS col0 FROM tab2
----
2054
216
3040

query I rowsort
SELECT - + col2 * 98 * 96 FROM tab0 AS cor0
----
-310464
-771456
-9408

query I rowsort
SELECT - col0 + - col0 * + col2 AS col0 FROM tab1 AS cor0
----
-165
-3712
-7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-8566
SELECT cor0.col2 + - ( col2 ) DIV col2 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-8566
SELECT cor0.col2 + - ( col2 ) / col2 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT - col2 + ( col1 ) + + col1 FROM tab0 AS cor0
----
100
139
193

query I rowsort
SELECT + - col2 * + 10 FROM tab1 AS cor0
----
-540
-570
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-8569
SELECT + col1 - ( - col1 + col0 ) DIV col0 AS col0 FROM tab2 cor0
----
17
34
59

skipif mysql # not compatible
query I rowsort label-8569
SELECT + col1 - ( - col1 + col0 ) / col0 AS col0 FROM tab2 cor0
----
17
34
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-8570
SELECT ALL - col0 * 13 DIV - col2 FROM tab1 AS cor0
----
0
10
14

skipif mysql # not compatible
query I rowsort label-8570
SELECT ALL - col0 * 13 / - col2 FROM tab1 AS cor0
----
0
10
14

query I rowsort
SELECT + col2 + 67 FROM tab2 cor0
----
105
93
94

query I rowsort
SELECT ALL - - cor0.col0 * col0 + cor0.col2 AS col2 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT - col2 * 24 - ( col0 ) FROM tab1 AS cor0
----
-1299
-1432
-2384

query I rowsort
SELECT + + col1 + - col0 * col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT + 73 * 97 AS col1 FROM tab2 AS cor0
----
7081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8576
SELECT + CAST( col0 AS SIGNED ) * col1 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-8576
SELECT + CAST ( col0 AS INTEGER ) * col1 AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT 16 + 42 FROM tab2 AS cor0
----
58

query I rowsort
SELECT DISTINCT - col1 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + ( + col2 ) + - col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - - col1 + cor0.col0 AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT - + 83 + + col1 FROM tab0 AS cor0
----
14
3
8

query I rowsort
SELECT + - ( - ( cor0.col0 ) ) AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + col2 * 97 AS col0 FROM tab0 AS cor0
----
3201
7954
97

query I rowsort
SELECT ALL - + col1 * + col1 * - col1 FROM tab2 AS cor0
----
205379
29791
4913

query I rowsort
SELECT ALL + 66 * - col2 FROM tab1 AS cor0
----
-3564
-3762
-6336

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + + col1 * col0 col2 FROM tab1 cor0
----
1120
704
81

query I rowsort
SELECT ALL + col2 * 44 FROM tab0 AS cor0
----
1452
3608
44

query I rowsort
SELECT col0 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 69 * - col1 col2 FROM tab0 AS cor0
----
-5934
-6279
-6693

query I rowsort
SELECT ALL 30 * - col1 FROM tab0 AS cor0
----
-2580
-2730
-2910

query I rowsort
SELECT ALL - tab2.col0 * col0 AS col2 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT cor0.col2 AS col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-8593
SELECT - cor0.col2 DIV col0 + col2 AS col0 FROM tab2 cor0
----
24
26
38

skipif mysql # not compatible
query I rowsort label-8593
SELECT - cor0.col2 / col0 + col2 AS col0 FROM tab2 cor0
----
24
26
38

query I rowsort
SELECT + col2 * col0 + - col0 FROM tab1
----
159
3584
7600

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + col1 col1 FROM tab1
----
109
67
80

query I rowsort
SELECT - col0 - col0 * - col1 AS col1 FROM tab1
----
576
75
960

query I rowsort
SELECT - tab0.col1 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT ALL - col1 * col1 + - col2 * cor0.col1 AS col2 FROM tab0 AS cor0
----
-10234
-15743
-9506

query I rowsort
SELECT DISTINCT - - col1 * - col0 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - col0 * cor0.col0 AS col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT col1 + - col0 * + col1 AS col2 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT - col0 + col2 - col1 * + col1 FROM tab2 cor0
----
-330
-3533
-941

query I rowsort
SELECT + ( + col2 ) * + col2 - col0 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT - 96 * - col1 FROM tab0 AS cor0
----
8256
8736
9312

query I rowsort
SELECT ( cor0.col1 ) + col1 AS col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - cor0.col1 + col0 * col0 AS col2 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT - col2 + col2 * - col0 AS col1 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT - - col0 + - col0 * col2 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT - col0 * + col2 + col0 + - col0 * col1 AS col2 FROM tab0 AS cor0
----
-15308
-2832
-3395

query I rowsort
SELECT ALL + - col2 - - col0 * + cor0.col0 FROM tab2 cor0
----
22
6058
6203

query I rowsort
SELECT ALL col0 * - col1 - col0 FROM tab1 AS cor0
----
-1120
-704
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-8612
SELECT ALL + col2 - - tab0.col0 DIV col1 AS col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-8612
SELECT ALL + col2 - - tab0.col0 / col1 AS col2 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL col2 * + col2 * - col0 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT col0 * + col2 * col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT ALL - col1 FROM tab1 WHERE NOT NULL >= ( col2 * - col0 )
----

query I rowsort
SELECT ALL tab2.col0 * - col1 * + col1 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT col1 * - col1 * + col1 FROM tab0
----
-636056
-753571
-912673

query I rowsort
SELECT DISTINCT - col2 - - col1 AS col2 FROM tab0
----
53
9
96

query I rowsort
SELECT DISTINCT col0 * + col2 * col2 + + col2 FROM tab2
----
114114
5130
52754

onlyif mysql # use DIV operator for integer division
query I rowsort label-8620
SELECT col0 DIV col2 + - col2 FROM tab1
----
-54
-56
-96

skipif mysql # not compatible
query I rowsort label-8620
SELECT col0 / col2 + - col2 FROM tab1
----
-54
-56
-96

query I rowsort
SELECT + col2 * col0 - - tab2.col0 * col2 FROM tab2
----
378
4056
6004

query I rowsort
SELECT DISTINCT - col1 + cor0.col2 * + ( - cor0.col0 ) - col2 AS col0 FROM tab0 AS cor0
----
-133
-7471
-911

query I rowsort
SELECT DISTINCT col2 + - col0 * + col2 + - col2 AS col1 FROM tab0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-8624
SELECT - tab2.col0 DIV + col0 + - col1 + - col2 * col0 AS col2 FROM tab2
----
-2088
-221
-3020

skipif mysql # not compatible
query I rowsort label-8624
SELECT - tab2.col0 / + col0 + - col1 + - col2 * col0 AS col2 FROM tab2
----
-2088
-221
-3020

query I rowsort
SELECT ALL + cor0.col1 * - col0 + col1 AS col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT - col2 + col2 * + tab2.col0 - + col0 * + col0 FROM tab2
----
-3277
-4082
113

query I rowsort
SELECT DISTINCT + col2 + - col2 - - col2 AS col1 FROM tab2
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - col1 col2 FROM tab2
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-8629
SELECT col0 DIV - col2 col1 FROM tab0
----
-1
-35
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8629
SELECT col0 / - col2 col1 FROM tab0
----
-1
-35
0

query I rowsort
SELECT col0 * - col1 * + col1 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT + col2 * tab0.col1 + + col0 * + col1 * + col1 + - col1 AS col0 FROM tab0
----
180256
329315
744380

query IIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0 WHERE NOT NULL BETWEEN NULL AND ( NULL )
----

query III rowsort
SELECT ALL * FROM tab2 AS cor0 WHERE NOT cor0.col0 + col2 <= + col2 - col1 * - col0 * col0
----

query I rowsort
SELECT col0 + + col2 AS col2 FROM tab1 WHERE NOT col1 - col2 < NULL
----

query I rowsort
SELECT - col0 * col1 * - col0 FROM tab1
----
234
40960
83200

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL >= + col0
----

query I rowsort
SELECT + col2 + tab2.col0 + + col2 AS col2 FROM tab2
----
130
155
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-8638
SELECT col2 * col2 DIV col0 AS col1 FROM tab1
----
115
50
972

skipif mysql # not compatible
query I rowsort label-8638
SELECT col2 * col2 / col0 AS col1 FROM tab1
----
115
50
972

onlyif mysql # use DIV operator for integer division
query I rowsort label-8639
SELECT DISTINCT col1 + tab1.col0 + - col2 DIV - col2 FROM tab1
----
30
75
94

skipif mysql # not compatible
query I rowsort label-8639
SELECT DISTINCT col1 + tab1.col0 + - col2 / - col2 FROM tab1
----
30
75
94

query III rowsort
SELECT * FROM tab1 WHERE NULL NOT IN ( - col2 + + col0 )
----

query I rowsort
SELECT 17 + - 20 AS col0 FROM tab2
----
-3
-3
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 - - col0 col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL 74 + - cor0.col1 FROM tab0 AS cor0
----
-12
-17
-23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8644
SELECT DISTINCT + + CAST( col1 AS SIGNED ) - - col1 * col2 col2 FROM tab1 AS cor0
----
1261
1430
580

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8644
SELECT DISTINCT + + CAST ( col1 AS INTEGER ) - - col1 * col2 col2 FROM tab1 AS cor0
----
1261
1430
580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + 51 ) - col0 col0 FROM tab2 AS cor0
----
-129
-130
-58

query I rowsort
SELECT ALL - + col0 * col1 + + col1 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT ALL + col1 + col2 * col1 AS col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT - + col0 + col2 * 70 FROM tab2 AS cor0
----
1742
1883
2581

query I rowsort
SELECT - col1 + + col2 * + ( + cor0.col1 + col2 ) FROM tab0 AS cor0
----
1
14095
3841

query I rowsort
SELECT ALL + col2 + - col0 AS col1 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT ALL - - cor0.col2 AS col0 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT + col1 + + col0 + - ( 45 ) AS col2 FROM tab2 AS cor0
----
-7
51
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 60 + col1 col1 FROM tab2 AS cor0
----
-1
-29
-43

query I rowsort
SELECT - col1 + + cor0.col0 * cor0.col1 AS col0 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8655
SELECT DISTINCT CAST( NULL AS SIGNED ) + col2 * col0 col0 FROM tab2
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8655
SELECT DISTINCT CAST ( NULL AS INTEGER ) + col2 * col0 col0 FROM tab2
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8656
SELECT - tab2.col0 DIV col0 col1 FROM tab2
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8656
SELECT - tab2.col0 / col0 col1 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT + col2 - col2 * ( 15 ) FROM tab1 AS cor0
----
-1344
-756
-798

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8658
SELECT ALL + col2 - + CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8658
SELECT ALL + col2 - + CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor0.col2 * + ( 18 + col2 ) AS col1 FROM tab0 AS cor0
----
-1683
-19
-8200

query I rowsort
SELECT DISTINCT col2 + ( - ( col2 ) ) * cor0.col1 * + 4 AS col2 FROM tab1 AS cor0
----
-2223
-4896
-5562

query I rowsort
SELECT - + col0 + ( col1 ) FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL - col2 - col0 AS col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT col2 * 12 FROM tab0 cor0
----
12
396
984

query I rowsort
SELECT - col0 * + 13 FROM tab1 AS cor0
----
-1040
-39
-832

onlyif mysql # use DIV operator for integer division
query I rowsort label-8665
SELECT DISTINCT + col0 DIV cor0.col1 AS col2 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-8665
SELECT DISTINCT + col0 / cor0.col1 AS col2 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT 4 - - col0 FROM tab1 cor0
----
68
7
84

query I rowsort
SELECT DISTINCT col0 * col1 + col2 AS col1 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT - - col1 * - col0 + col0 AS col0 FROM tab1 AS cor0
----
-576
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col0 col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - col1 + 1 FROM tab2
----
-16
-30
-58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + 25 * 90 col0 FROM tab0
----
2336
2341
2347

query I rowsort
SELECT col1 * + col0 - + col0 AS col0 FROM tab1
----
576
75
960

onlyif mysql # use DIV operator for integer division
query I rowsort label-8673
SELECT ALL cor0.col0 DIV + cor0.col0 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-8673
SELECT ALL cor0.col0 / + cor0.col0 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT - + 44 * + 29 AS col0 FROM tab0 AS cor0
----
-1276
-1276
-1276

query I rowsort
SELECT col1 * 40 AS col2 FROM tab1 cor0
----
1040
400
520

query I rowsort
SELECT - ( + col1 ) * col2 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
-119808
-32490
-75816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * col2 - col1 col2 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT ALL - - 22 * + col1 + + col2 * col0 FROM tab2 AS cor0
----
3326
3376
871

onlyif mysql # use DIV operator for integer division
query I rowsort label-8679
SELECT ALL ( + 49 ) DIV + col2 + tab1.col2 * - tab1.col1 AS col2 FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-8679
SELECT ALL ( + 49 ) / + col2 + tab1.col2 * - tab1.col1 AS col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT ( - col0 ) * + col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - + col1 * + col0 * + col2 FROM tab0 cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL - ( - tab1.col0 + col0 ) * - col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT + col1 + - CAST ( 10 AS REAL ) + - col0 AS col2 FROM tab2 AS cor0
----
-29
-72
14

query I rowsort
SELECT - col2 * 18 FROM tab2 AS cor0
----
-468
-486
-684

query I rowsort
SELECT DISTINCT tab1.col2 * col2 + col2 + + 23 * col2 AS col1 FROM tab1
----
11520
4212
4617

onlyif mysql # use DIV operator for integer division
query I rowsort label-8686
SELECT - tab2.col0 DIV + col1 + + 98 AS col1 FROM tab2
----
94
97
98

skipif mysql # not compatible
query I rowsort label-8686
SELECT - tab2.col0 / + col1 + + 98 AS col1 FROM tab2
----
94
97
98

query I rowsort
SELECT col0 + - cor0.col1 + col0 FROM tab0 AS cor0
----
-27
-38
87

query I rowsort
SELECT - col2 * col0 + - col1 + + col2 FROM tab0 AS cor0
----
-131
-7307
-845

query I rowsort
SELECT + 25 * + col0 FROM tab2
----
175
1950
1975

query I rowsort
SELECT + ( - col1 * + 36 ) FROM tab0
----
-3096
-3276
-3492

query I rowsort
SELECT DISTINCT col1 * col2 * + col1 AS col0 FROM tab1
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-8692
SELECT col1 + - col1 DIV 70 AS col2 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-8692
SELECT col1 + - col1 / 70 AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + + cor0.col0 * 92 + 64 FROM tab0 cor0
----
2272
3284
8252

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8694
SELECT ALL - col0 * CAST( col0 AS SIGNED ) col2 FROM tab2 AS cor0
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8694
SELECT ALL - col0 * CAST ( col0 AS INTEGER ) col2 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT + - col2 * + col0 + - col1 FROM tab1 AS cor0
----
-188
-3658
-7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * - ( - col1 ) col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + col2 + 54 + 56 FROM tab0 cor0
----
111
143
192

query I rowsort
SELECT DISTINCT col1 * ( 37 ) AS col0 FROM tab0 AS cor0
----
3182
3367
3589

onlyif mysql # use DIV operator for integer division
query I rowsort label-8699
SELECT + - col1 + - ( + ( col0 ) ) + col2 DIV - col1 FROM tab2 AS cor0
----
-137
-38
-98

skipif mysql # not compatible
query I rowsort label-8699
SELECT + - col1 + - ( + ( col0 ) ) + col2 / - col1 FROM tab2 AS cor0
----
-137
-38
-98

query I rowsort
SELECT tab1.col1 * + col0 * 12 AS col2 FROM tab1
----
12480
7680
936

onlyif mysql # use DIV operator for integer division
query I rowsort label-8701
SELECT col1 DIV - col0 + col1 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
2835
7461
95

skipif mysql # not compatible
query I rowsort label-8701
SELECT col1 / - col0 + col1 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
2835
7461
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + col1 + 27 * + cor0.col1 col0 FROM tab2 AS cor0
----
1574
397
861

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8703
SELECT + - col2 + CAST( col0 AS SIGNED ) * col2 FROM tab1 AS cor0
----
108
3591
7584

skipif mysql # not compatible
query I rowsort label-8703
SELECT + - col2 + CAST ( col0 AS INTEGER ) * col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT ALL - cor0.col0 * + 67 FROM tab2 AS cor0
----
-469
-5226
-5293

query I rowsort
SELECT ALL 81 * - col0 FROM tab2
----
-567
-6318
-6399

query I rowsort
SELECT DISTINCT + tab0.col1 * col2 * col0 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab1, tab2, tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL tab2.col1 * tab2.col0 + col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT ALL col1 + - ( 74 ) FROM tab1
----
-48
-61
-64

query I rowsort
SELECT col2 * col0 - col2 * + col1 * - col1 FROM tab2
----
13984
26136
92534

query I rowsort
SELECT ALL 11 + 87 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT + - cor0.col2 * + 75 + col0 AS col2 FROM tab2 AS cor0
----
-1872
-2018
-2771

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8713
SELECT + col0 * CAST( col2 AS SIGNED ) col0 FROM tab2 AS cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8713
SELECT + col0 * CAST ( col2 AS INTEGER ) col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - col0 + + col0 * cor0.col2 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT ALL col0 - - col1 * + col1 FROM tab1
----
164
249
679

onlyif mysql # use DIV operator for integer division
query I rowsort label-8716
SELECT - col0 DIV cor0.col2 + ( col1 + col1 ) col2 FROM tab1 AS cor0
----
19
26
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8716
SELECT - col0 / cor0.col2 + ( col1 + col1 ) col2 FROM tab1 AS cor0
----
19
26
52

query I rowsort
SELECT + - col0 + + col1 * + col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT col1 * - col0 + cor0.col2 AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT cor1.col0 + 48 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
126
127
55

query I rowsort
SELECT + 1 * + col0 + col1 AS col2 FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT + 61 * + col1 FROM tab0 AS cor0
----
5246
5551
5917

query I rowsort
SELECT ALL - - cor0.col0 + + col1 AS col0 FROM tab0 cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8723
SELECT DISTINCT + - ( + col2 ) * - CAST( cor0.col1 + col2 AS SIGNED ) * 3 FROM tab1 AS cor0
----
11457
12960
31392

skipif mysql # not compatible
query I rowsort label-8723
SELECT DISTINCT + - ( + col2 ) * - CAST ( cor0.col1 + col2 AS INTEGER ) * 3 FROM tab1 AS cor0
----
11457
12960
31392

query I rowsort
SELECT DISTINCT - col0 * col0 * 43 FROM tab0 cor0
----
-24768
-340603
-52675

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - col1 + + 48 * col2 col0 FROM tab2 AS cor0
----
-2233
1535
335

query I rowsort
SELECT + col1 * col1 + + col0 * col0 AS col0 FROM tab1 cor0
----
4196
6569
685

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + col2 * - col0 col1 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL col0 + ( col1 ) AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - - col2 * + col1 + ( - col0 * ( col2 ) ) AS col2 FROM tab0 AS cor0
----
164
2046
62

query I rowsort
SELECT DISTINCT - + col2 * - 71 + col2 * - col2 * - ( col2 ) AS col1 FROM tab2 AS cor0
----
19422
21600
57570

query I rowsort
SELECT ALL - - col1 * ( - ( + col2 ) ) AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-8732
SELECT ALL col2 + ( col2 ) DIV - col0 FROM tab0 cor0
----
1
32
82

skipif mysql # not compatible
query I rowsort label-8732
SELECT ALL col2 + ( col2 ) / - col0 FROM tab0 cor0
----
1
32
82

query I rowsort
SELECT ALL + + col1 - col2 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT col1 + - ( + col0 ) * + ( + cor0.col2 ) FROM tab0 AS cor0
----
-706
-7207
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * 31 col2 FROM tab1 AS cor0
----
-1984
-2480
-93

query I rowsort
SELECT + - ( + col0 ) + + col1 * ( + col2 ) AS col0 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT - + col1 + + col2 + col2 FROM tab0 AS cor0
----
-20
-95
73

query I rowsort
SELECT DISTINCT ( 98 ) FROM tab2 AS cor0
----
98

query I rowsort
SELECT ALL - - col1 + + 81 AS col0 FROM tab0 AS cor0
----
167
172
178

onlyif mysql # use DIV operator for integer division
query I rowsort label-8740
SELECT DISTINCT - tab2.col0 DIV cor0.col0 FROM tab2, tab1, tab0 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-8740
SELECT DISTINCT - tab2.col0 / cor0.col0 FROM tab2, tab1, tab0 AS cor0
----
-2
-3
0

query I rowsort
SELECT ALL ( - 59 * col2 ) FROM tab1
----
-3186
-3363
-5664

onlyif mysql # use DIV operator for integer division
query I rowsort label-8742
SELECT DISTINCT + - 87 DIV col2 - - ( + col0 ) AS col1 FROM tab0 cor0
----
-52
22
88

skipif mysql # not compatible
query I rowsort label-8742
SELECT DISTINCT + - 87 / col2 - - ( + col0 ) AS col1 FROM tab0 cor0
----
-52
22
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8743
SELECT DISTINCT + - col1 * - col2 - CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8743
SELECT DISTINCT + - col1 * - col2 - CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + 33 - col2 FROM tab1
----
-21
-24
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-8745
SELECT DISTINCT 48 DIV 6 AS col1 FROM tab0, tab2, tab0 AS cor0
----
8

skipif mysql # not compatible
query I rowsort label-8745
SELECT DISTINCT 48 / 6 AS col1 FROM tab0, tab2, tab0 AS cor0
----
8

query I rowsort
SELECT DISTINCT ( + 69 ) * + col1 AS col1 FROM tab1
----
1794
690
897

query I rowsort
SELECT - - col1 * col2 * + col1 AS col2 FROM tab2 cor0
----
10982
25947
90506

query I rowsort
SELECT + col2 * 92 FROM tab1 cor0
----
4968
5244
8832

query I rowsort
SELECT DISTINCT + ( col1 ) * + col1 + 71 * - col1 FROM tab1
----
-1170
-610
-754

onlyif mysql # use DIV operator for integer division
query I rowsort label-8750
SELECT 1 * 48 DIV col0 FROM tab0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-8750
SELECT 1 * 48 / col0 FROM tab0
----
0
1
2

query I rowsort
SELECT DISTINCT ( - col1 ) + + cor0.col0 + + col0 * - col2 * cor0.col0 FROM tab0 AS cor0
----
-1287
-19070
-649524

query I rowsort
SELECT DISTINCT 87 * + col0 + col1 AS col1 FROM tab0
----
2174
3142
7834

query I rowsort
SELECT - - cor0.col1 AS col0 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT - col1 + col2 + - col2 * ( - tab0.col1 ) AS col2 FROM tab0
----
1
2785
7453

query I rowsort
SELECT DISTINCT - cor1.col1 FROM tab2, tab1 AS cor0, tab1 AS cor1, tab0 AS cor2
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8756
SELECT DISTINCT CAST( col1 AS SIGNED ) col0 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8756
SELECT DISTINCT CAST ( col1 AS INTEGER ) col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT col1 + 47 * + col0 AS col1 FROM tab2 AS cor0
----
360
3725
3730

query I rowsort
SELECT 10 + 69 * + col1 FROM tab2 AS cor0
----
1183
2149
4081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col0 + + col2 col1 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-8760
SELECT - 9 DIV col1 + - col1 AS col1 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-8760
SELECT - 9 / col1 + - col1 AS col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT 96 * cor0.col1 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to b42ff08e59e3946339991f1be89b6cac

query I rowsort
SELECT ALL col0 + + col1 * + 36 FROM tab1 AS cor0
----
424
548
939

query I rowsort
SELECT + 49 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

query I rowsort
SELECT 23 * col0 AS col1 FROM tab2
----
161
1794
1817

query I rowsort
SELECT DISTINCT - + col0 * + col0 - col1 * - col0 FROM tab1 AS cor0
----
-3456
-5360
69

query I rowsort
SELECT - col2 * col0 + 8 FROM tab2 AS cor0
----
-181
-2020
-2994

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 * 87 col2 FROM tab2 cor0
----
1479
2697
5133

onlyif mysql # use DIV operator for integer division
query I rowsort label-8768
SELECT ALL - col0 DIV - col1 AS col2 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-8768
SELECT ALL - col0 / - col1 AS col2 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT DISTINCT - col1 * 18 + + 35 * col0 FROM tab1 AS cor0
----
-363
2060
2566

query I rowsort
SELECT - col0 + - 31 * 26 FROM tab1 cor0
----
-809
-870
-886

onlyif mysql # use DIV operator for integer division
query I rowsort label-8771
SELECT + col1 DIV - 36 AS col0 FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-8771
SELECT + col1 / - 36 AS col0 FROM tab2 AS cor0
----
-1
0
0

query I rowsort
SELECT ALL col1 * + col1 + - cor0.col1 AS col0 FROM tab2 AS cor0
----
272
3422
930

onlyif mysql # use DIV operator for integer division
query I rowsort label-8773
SELECT col0 DIV ( + col1 ) FROM tab1 cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-8773
SELECT col0 / ( + col1 ) FROM tab1 cor0
----
0
6
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-8774
SELECT DISTINCT col1 DIV - 56 AS col1 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-8774
SELECT DISTINCT col1 / - 56 AS col1 FROM tab2 AS cor0
----
-1
0

query I rowsort
SELECT col0 * + ( - 52 ) FROM tab1 AS cor0
----
-156
-3328
-4160

query I rowsort
SELECT ALL + col1 + col2 * col2 AS col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT DISTINCT + + cor0.col2 * + 29 + + col0 AS col2 FROM tab2 AS cor0
----
1181
790
832

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8778
SELECT DISTINCT + + col1 * CAST( NULL AS SIGNED ) - + col2 col2 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8778
SELECT DISTINCT + + col1 * CAST ( NULL AS INTEGER ) - + col2 col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - - col2 + - 30 AS col2 FROM tab2 AS cor0
----
-3
-4
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8780
SELECT - col0 * + CAST( + col1 AS SIGNED ) AS col2 FROM tab2
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-8780
SELECT - col0 * + CAST ( + col1 AS INTEGER ) AS col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT ALL - col1 - + col0 AS col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT + cor1.col1 AS col0 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + - col0 + col1 * col1 AS col0 FROM tab2 AS cor0
----
210
3403
954

query I rowsort
SELECT + col0 + - ( col2 ) AS col1 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT + ( + 12 ) AS col2 FROM tab1 AS cor0
----
12
12
12

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8786
SELECT col2 / CAST( NULL AS DECIMAL ) + + col0 * - tab1.col1 col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8786
SELECT col2 / CAST ( NULL AS REAL ) + + col0 * - tab1.col1 col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 * 27 FROM tab0
----
-2403
-648
-945

query I rowsort
SELECT + ( + col0 ) + cor0.col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + - cor0.col0 * col2 - col2 * + ( col1 ) AS col2 FROM tab2 AS cor0
----
-1026
-3562
-3648

query I rowsort
SELECT DISTINCT - col1 + + cor0.col2 * cor0.col1 FROM tab0 AS cor0
----
0
2752
7371

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8791
SELECT ALL ( + col1 ) * - CAST( + col0 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-8791
SELECT ALL ( + col1 ) * - CAST ( + col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT 31 * col0 * - col0 + 49 AS col1 FROM tab1 AS cor0
----
-126927
-198351
-230

query I rowsort
SELECT - 68 + - 18 FROM tab2
----
-86
-86
-86

query I rowsort
SELECT - 99 FROM tab2, tab1, tab1 AS cor0, tab0
----
81 values hashing to 501094e80bab5e6e81bd79b84ea81e69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 79 + 78 * col0 + - tab2.col2 col0 FROM tab2
----
440
5979
6045

query I rowsort
SELECT ALL 60 + tab2.col1 FROM tab2
----
119
77
91

query I rowsort
SELECT col1 * - col0 + ( col1 ) FROM tab0 cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - 22 * - col2 AS col0 FROM tab1 AS cor0
----
1188
1254
2112

query I rowsort
SELECT + 11 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 69116737f3f57e2e3273f6dbb04d036c

query I rowsort
SELECT - col1 * + ( 73 ) + col1 * 63 * col2 FROM tab2 AS cor0
----
39457
50468
92335

query I rowsort
SELECT ALL cor1.col1 AS col1 FROM tab2, tab1 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

query I rowsort
SELECT ALL - 37 + - col1 AS col0 FROM tab0 AS cor0
----
-123
-128
-134

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col0 + col1 col0 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT + col0 * col2 - col1 AS col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT + 75 * + col2 FROM tab1 AS cor0
----
4050
4275
7200

query I rowsort
SELECT + 14 * - col2 + col2 FROM tab1 AS cor0
----
-1248
-702
-741

query I rowsort
SELECT ALL - col0 * - cor0.col0 AS col2 FROM tab0 cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 73 * col2 col1 FROM tab1
----
3942
4161
7008

query I rowsort
SELECT col1 * + col0 + col0 * col0 FROM tab1 AS cor0
----
4736
7440
87

query I rowsort
SELECT ALL 61 - col1 FROM tab1
----
35
48
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8811
SELECT ALL - CAST( 78 AS SIGNED ) AS col1 FROM tab1 cor0
----
-78
-78
-78

skipif mysql # not compatible
query I rowsort label-8811
SELECT ALL - CAST ( 78 AS INTEGER ) AS col1 FROM tab1 cor0
----
-78
-78
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 28 * - 19 col2 FROM tab1 cor0
----
-532
-532
-532

query I rowsort
SELECT DISTINCT - cor0.col2 FROM tab0, tab0 cor0, tab0 cor1
----
-1
-33
-82

query I rowsort
SELECT - 56 * - 69 AS col1 FROM tab0 AS cor0
----
3864
3864
3864

query I rowsort
SELECT DISTINCT col1 * col2 + cor0.col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + ( col0 ) * - cor0.col0 + 43 FROM tab2 AS cor0
----
-6
-6041
-6198

query I rowsort
SELECT DISTINCT - - col2 * col1 + + 7 FROM tab2 AS cor0
----
1541
653
844

query I rowsort
SELECT - cor0.col0 + + cor0.col1 * 61 FROM tab1 AS cor0
----
1583
546
713

query I rowsort
SELECT DISTINCT 10 * + col1 + cor0.col0 AS col2 FROM tab1 cor0
----
164
210
263

query I rowsort
SELECT ALL - ( col2 ) * + 5 AS col0 FROM tab2 AS cor0
----
-130
-135
-190

query I rowsort
SELECT + + col1 - + cor0.col0 * col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT + col1 - 81 FROM tab0
----
10
16
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-8823
SELECT CAST( 93 AS SIGNED ) DIV - col0 FROM tab2
----
-1
-1
-13

skipif mysql # not compatible
query I rowsort label-8823
SELECT CAST ( 93 AS INTEGER ) / - col0 FROM tab2
----
-1
-1
-13

onlyif mysql # use DIV operator for integer division
query I rowsort label-8824
SELECT ALL + - col1 DIV + col0 AS col2 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-8824
SELECT ALL + - col1 / + col0 AS col2 FROM tab1 AS cor0
----
-8
0
0

query I rowsort
SELECT DISTINCT - col2 * 68 AS col0 FROM tab0 AS cor0
----
-2244
-5576
-68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 * + cor0.col2 col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col2 * 53 AS col1 FROM tab2 AS cor0
----
1378
1431
2014

query I rowsort
SELECT + - col0 + + 96 FROM tab0 AS cor0
----
61
7
72

query I rowsort
SELECT ALL - col1 * + ( + 0 ) AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT col0 * - col0 * - 91 - + col1 FROM tab0
----
111378
52330
720720

query I rowsort
SELECT col0 + 16 AS col2 FROM tab2
----
23
94
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8832
SELECT DISTINCT + CAST( NULL AS SIGNED ) + - 72 * + col2 * ( + 49 * col1 ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8832
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + - 72 * + col2 * ( + 49 * col1 ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col1 * col2 * - cor0.col0 FROM tab2 AS cor0
----
119652
51034
5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8834
SELECT ALL + CAST( col1 AS SIGNED ) + + col2 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-8834
SELECT ALL + CAST ( col1 AS INTEGER ) + + col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - + ( + col1 ) + + col2 * - col1 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT + - col1 * + col0 * cor0.col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - ( - col0 ) ) * col2 + col0 * + col0 col0 FROM tab0 AS cor0
----
-216
1190
623

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - col2 col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * tab0.col0 + + col0 * + col0 * col0 col0 FROM tab0
----
14400
44100
712890

query I rowsort
SELECT ALL tab2.col0 * 43 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to 19dab67aab425d7be61650756bbd8a3c

onlyif mysql # use DIV operator for integer division
query I rowsort label-8841
SELECT tab0.col2 + + tab0.col0 DIV - col1 AS col0 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-8841
SELECT tab0.col2 + + tab0.col0 / - col1 AS col0 FROM tab0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 34 * - ( col1 ) col0 FROM tab2 AS cor0
----
-1054
-2006
-578

query I rowsort
SELECT ALL - + ( + col1 ) AS col0 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8844
SELECT ALL - - CAST( col0 AS SIGNED ) + col1 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-8844
SELECT ALL - - CAST ( col0 AS INTEGER ) + col1 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-8845
SELECT ALL col2 + - cor0.col2 DIV + col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-8845
SELECT ALL col2 + - cor0.col2 / + col1 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8846
SELECT DISTINCT + CAST( 90 AS SIGNED ) + + cor0.col2 AS col1 FROM tab0 AS cor0
----
123
172
91

skipif mysql # not compatible
query I rowsort label-8846
SELECT DISTINCT + CAST ( 90 AS INTEGER ) + + cor0.col2 AS col1 FROM tab0 AS cor0
----
123
172
91

query I rowsort
SELECT cor0.col1 + 55 AS col2 FROM tab2 AS cor0
----
114
72
86

query I rowsort
SELECT ALL + ( + col1 ) + + col2 * col1 AS col0 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL - 53 AS col0 FROM tab1 cor0
----
-53
-53
-53

query I rowsort
SELECT DISTINCT - 88 * + col0 FROM tab0 AS cor0
----
-2112
-3080
-7832

query I rowsort
SELECT ALL - 28 AS col1 FROM tab1 cor0
----
-28
-28
-28

onlyif mysql # use DIV operator for integer division
query I rowsort label-8852
SELECT - - 40 DIV - col0 AS col1 FROM tab0 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-8852
SELECT - - 40 / - col0 AS col1 FROM tab0 AS cor0
----
-1
-1
0

query I rowsort
SELECT DISTINCT ( + cor0.col2 ) * + cor0.col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8854
SELECT DISTINCT col0 + tab0.col2 * CAST( - 67 AS SIGNED ) AS col2 FROM tab0
----
-2187
-32
-5405

skipif mysql # not compatible
query I rowsort label-8854
SELECT DISTINCT col0 + tab0.col2 * CAST ( - 67 AS INTEGER ) AS col2 FROM tab0
----
-2187
-32
-5405

query I rowsort
SELECT col0 + + col2 * ( col2 ) AS col1 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT - - col1 + - cor0.col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 - col1 * ( + col0 ) AS col1 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT 16 * - 22 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 3a0aaea6ea1cb387f1e42efb43cc2297

query I rowsort
SELECT + + 97 + col1 AS col2 FROM tab2 AS cor0
----
114
128
156

query I rowsort
SELECT ALL + - col2 + + col1 * + col2 AS col0 FROM tab2 AS cor0
----
1508
608
810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8861
SELECT - col2 * + CAST( NULL AS SIGNED ) + col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8861
SELECT - col2 * + CAST ( NULL AS INTEGER ) + col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8862
SELECT cor0.col2 * 88 + col0 DIV - col1 + col2 AS col2 FROM tab0 cor0
----
2937
7298
89

skipif mysql # not compatible
query I rowsort label-8862
SELECT cor0.col2 * 88 + col0 / - col1 + col2 AS col2 FROM tab0 cor0
----
2937
7298
89

query I rowsort
SELECT - - col1 * ( col1 ) + + col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT ALL - col2 * + ( cor0.col2 * col2 ) FROM tab1 AS cor0
----
-157464
-185193
-884736

query I rowsort
SELECT - col2 + - ( ( + cor0.col2 ) ) FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT - + 65 AS col2 FROM tab1 AS cor0
----
-65
-65
-65

query I rowsort
SELECT DISTINCT - 92 * col2 FROM tab0 AS cor0
----
-3036
-7544
-92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 + + col0 col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL + + 5 * + col1 + col1 * col0 * col1 FROM tab1 AS cor0
----
13585
2158
6450

query I rowsort
SELECT DISTINCT + 41 * + col1 + col1 FROM tab2 cor0
----
1302
2478
714

query I rowsort
SELECT DISTINCT + 88 + - col0 FROM tab1 AS cor0
----
24
8
85

query I rowsort
SELECT DISTINCT - col0 + col1 * + 20 + + col0 * + col2 FROM tab1 AS cor0
----
3784
679
7860

query I rowsort
SELECT ALL + col2 * + 0 * col2 AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT - 13 + - cor0.col2 * 40 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 5171c222cd3d9c038e68261c348aa285

onlyif mysql # use DIV operator for integer division
query I rowsort label-8875
SELECT + col0 * - col1 + - cor0.col0 * col0 + + col0 DIV 61 col2 FROM tab2 cor0
----
-10685
-266
-7583

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8875
SELECT + col0 * - col1 + - cor0.col0 * col0 + + col0 / 61 col2 FROM tab2 cor0
----
-10685
-266
-7583

query I rowsort
SELECT ( 20 ) FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

query I rowsort
SELECT + cor0.col2 + - 47 * col0 AS col1 FROM tab2 AS cor0
----
-302
-3640
-3675

query I rowsort
SELECT + 51 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to c9771396949659773ab2fa2a1ac228de

query I rowsort
SELECT ALL + cor0.col0 * cor0.col1 * col0 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT DISTINCT - 8 AS col2 FROM tab2, tab1 AS cor0
----
-8

query I rowsort
SELECT DISTINCT tab0.col1 * - col1 + - 85 * + col0 AS col2 FROM tab0
----
-12384
-15846
-9436

query I rowsort
SELECT - tab0.col2 + + 53 * 16 * col1 FROM tab0
----
72895
77086
82255

query I rowsort
SELECT + 98 * tab1.col2 FROM tab1
----
5292
5586
9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-8884
SELECT col0 DIV + col0 + col2 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-8884
SELECT col0 / + col0 + col2 FROM tab1
----
55
58
97

query I rowsort
SELECT - ( col0 ) * - col1 + ( col2 ) AS col1 FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-8886
SELECT DISTINCT 30 DIV col1 AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8886
SELECT DISTINCT 30 / col1 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + - col0 + col2 + col1 FROM tab1 AS cor0
----
29
3
77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8888
SELECT + - ( + col2 ) + col1 * + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8888
SELECT + - ( + col2 ) + col1 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 45 AS col1 FROM tab1
----
-45
-45
-45

query I rowsort
SELECT 17 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT ALL ( + tab0.col2 * - col0 ) FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + - col1 + + cor0.col1 * col2 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT + 14 * 70 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to 6bd3f158e90782ec5a558094cd7a883f

query I rowsort
SELECT col0 + - col2 + col0 FROM tab0 AS cor0
----
15
69
96

query I rowsort
SELECT 89 + cor0.col1 AS col2 FROM tab0 AS cor0
----
175
180
186

query I rowsort
SELECT ALL - 18 + col1 * col2 FROM tab0
----
2820
7444
79

query I rowsort
SELECT - cor0.col1 * - col2 + - cor0.col0 + + col2 * col2 FROM tab1 AS cor0
----
10384
3755
4317

onlyif mysql # use DIV operator for integer division
query I rowsort label-8898
SELECT cor1.col1 DIV - 28 AS col0 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 65b7e16aaa7821ace3a45a9846ffa166

skipif mysql # not compatible
query I rowsort label-8898
SELECT cor1.col1 / - 28 AS col0 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 65b7e16aaa7821ace3a45a9846ffa166

query I rowsort
SELECT ALL - tab0.col0 FROM tab0, tab2, tab1 cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col1 * + col2 + col1 col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL - 47 AS col2 FROM tab2, tab1 cor0, tab0 AS cor1
----
27 values hashing to a4d3a02c376c52ddb0a38a801f7b50d5

onlyif mysql # use DIV operator for integer division
query I rowsort label-8902
SELECT + - col0 DIV + col1 + + col2 DIV + col1 col1 FROM tab0 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8902
SELECT + - col0 / + col1 + + col2 / + col1 col1 FROM tab0 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8903
SELECT - cor0.col1 DIV col1 + + 98 * - col1 + - col1 AS col0 FROM tab2 AS cor0
----
-1684
-3070
-5842

skipif mysql # not compatible
query I rowsort label-8903
SELECT - cor0.col1 / col1 + + 98 * - col1 + - col1 AS col0 FROM tab2 AS cor0
----
-1684
-3070
-5842

query I rowsort
SELECT - - cor0.col1 + - 80 * cor0.col2 FROM tab2 AS cor0
----
-2021
-2129
-3023

query I rowsort
SELECT col2 + - 72 AS col0 FROM tab1 AS cor0
----
-15
-18
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-8906
SELECT DISTINCT - col0 - col2 DIV + col1 AS col0 FROM tab2 AS cor0
----
-7
-78
-81

skipif mysql # not compatible
query I rowsort label-8906
SELECT DISTINCT - col0 - col2 / + col1 AS col0 FROM tab2 AS cor0
----
-7
-78
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - cor0.col0 * + cor0.col1 col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT cor0.col2 + - col1 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT col0 * cor0.col0 + + cor0.col0 AS col1 FROM tab2 cor0
----
56
6162
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-8910
SELECT + col2 + + col0 DIV col0 AS col2 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-8910
SELECT + col2 + + col0 / col0 AS col2 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT + - 79 * - col2 FROM tab2 AS cor0
----
2054
2133
3002

query I rowsort
SELECT - + 49 * - col2 + col0 * - col1 + col2 FROM tab1 AS cor0
----
2210
2622
3760

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col1 AS REAL ) * + col1 + CAST ( col1 AS REAL ) AS col0 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT col0 + col1 + + 38 FROM tab2
----
134
175
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8915
SELECT - col1 + + col0 * CAST( NULL AS DECIMAL ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8915
SELECT - col1 + + col0 * CAST ( NULL AS REAL ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 70 AS col2 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to c76157a7a7ec18de56823b2058b49f32

query I rowsort
SELECT - cor0.col0 * - 76 FROM tab0 cor0
----
1824
2660
6764

query I rowsort
SELECT col1 * + col0 * 5 AS col2 FROM tab1 AS cor0
----
3200
390
5200

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col2 * - CAST ( - col0 AS REAL ) * + col1 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL col2 + - 12 AS col2 FROM tab2 AS cor0
----
14
15
26

query I rowsort
SELECT + col2 * + 51 * col1 AS col2 FROM tab2 AS cor0
----
32946
42687
78234

query I rowsort
SELECT col1 * + col0 * - col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT + col1 + - 34 * col2 AS col1 FROM tab2 AS cor0
----
-1275
-825
-887

onlyif mysql # use DIV operator for integer division
query I rowsort label-8924
SELECT DISTINCT - col2 + + col0 DIV col2 FROM tab1 AS cor0
----
-54
-56
-96

skipif mysql # not compatible
query I rowsort label-8924
SELECT DISTINCT - col2 + + col0 / col2 FROM tab1 AS cor0
----
-54
-56
-96

query I rowsort
SELECT ALL col2 + ( - col2 ) * - col1 AS col1 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-8926
SELECT DISTINCT + + col1 DIV - 31 + 53 * - col2 FROM tab2 cor0
----
-1379
-1432
-2014

skipif mysql # not compatible
query I rowsort label-8926
SELECT DISTINCT + + col1 / - 31 + 53 * - col2 FROM tab2 cor0
----
-1379
-1432
-2014

query I rowsort
SELECT ALL cor0.col2 + + ( 64 ) AS col2 FROM tab1 AS cor0
----
118
121
160

query I rowsort
SELECT DISTINCT - col0 * + 43 + 92 * + col0 + + col1 AS col0 FROM tab1 AS cor0
----
173
3146
3933

query I rowsort
SELECT + 24 * + col0 AS col1 FROM tab0 cor0
----
2136
576
840

query I rowsort
SELECT + + 71 + + 70 FROM tab0 AS cor0
----
141
141
141

onlyif mysql # use DIV operator for integer division
query I rowsort label-8931
SELECT DISTINCT + col1 + col0 DIV - col0 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-8931
SELECT DISTINCT + col1 + col0 / - col0 FROM tab1 AS cor0
----
12
25
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8932
SELECT DISTINCT + col1 * - CAST( + col2 AS SIGNED ) FROM tab0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-8932
SELECT DISTINCT + col1 * - CAST ( + col2 AS INTEGER ) FROM tab0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8933
SELECT - col0 * CAST( col2 AS SIGNED ) AS col2 FROM tab2
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-8933
SELECT - col0 * CAST ( col2 AS INTEGER ) AS col2 FROM tab2
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( + col2 ) + col0 col1 FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8935
SELECT - cor0.col2 * 96 + col2 DIV col0 AS col0 FROM tab0 AS cor0
----
-3167
-7872
-96

skipif mysql # not compatible
query I rowsort label-8935
SELECT - cor0.col2 * 96 + col2 / col0 AS col0 FROM tab0 AS cor0
----
-3167
-7872
-96

query I rowsort
SELECT col0 * + col1 + + col2 * - 7 AS col1 FROM tab1 AS cor0
----
-300
241
368

query I rowsort
SELECT DISTINCT + 85 AS col0 FROM tab1, tab2 AS cor0
----
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 53 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to fede6033dee346dbd272085c05724fda

query I rowsort
SELECT - - col2 + + col0 AS col1 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - ( col1 ) + col2 * + 61 AS col2 FROM tab0 AS cor0
----
-36
1927
4911

query I rowsort
SELECT DISTINCT col0 + col2 * + 68 FROM tab0 AS cor0
----
103
2268
5665

query I rowsort
SELECT - 76 * - col0 * col0 FROM tab0 AS cor0
----
43776
601996
93100

query I rowsort
SELECT - 42 * cor0.col1 * - ( - 10 ) FROM tab2 AS cor0
----
-13020
-24780
-7140

onlyif mysql # use DIV operator for integer division
query I rowsort label-8944
SELECT DISTINCT + cor0.col1 DIV col2 - ( 65 ) * col2 AS col2 FROM tab1 AS cor0
----
-3510
-3705
-6240

skipif mysql # not compatible
query I rowsort label-8944
SELECT DISTINCT + cor0.col1 / col2 - ( 65 ) * col2 AS col2 FROM tab1 AS cor0
----
-3510
-3705
-6240

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 6 * cor0.col1 * col0 col0 FROM tab2 AS cor0
----
1302
27612
8058

query I rowsort
SELECT + 71 + + col2 FROM tab0 AS cor0
----
104
153
72

query I rowsort
SELECT ALL + 57 + + col1 + + col0 FROM tab1 AS cor0
----
131
150
86

query I rowsort
SELECT + col2 + col0 * 85 FROM tab1 cor0
----
309
5497
6896

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( col2 ) * + col2 col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT ALL + col1 + col0 * - col0 * + 77 + ( col0 * - col1 ) AS col1 FROM tab0
----
-46330
-617925
-97623

query I rowsort
SELECT ALL + col2 + - 9 FROM tab1
----
45
48
87

query I rowsort
SELECT ALL 17 * - col0 * cor0.col0 FROM tab1 cor0
----
-108800
-153
-69632

onlyif mysql # use DIV operator for integer division
query I rowsort label-8953
SELECT - 79 DIV 33 + + col2 FROM tab0
----
-1
31
80

skipif mysql # not compatible
query I rowsort label-8953
SELECT - 79 / 33 + + col2 FROM tab0
----
-1
31
80

query I rowsort
SELECT ALL + 42 + col0 FROM tab0
----
131
66
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-8955
SELECT - + 27 DIV + 92 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-8955
SELECT - + 27 / + 92 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL + col2 * col1 * tab1.col0 FROM tab1
----
36480
4212
99840

skipif mysql # not compatible
query I rowsort
SELECT + 77 + - col1 * + CAST ( - col1 AS REAL ) AS col0 FROM tab0 cor0
----
7473
8358
9486

query I rowsort
SELECT - + cor0.col0 * + cor0.col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL ( col0 ) * + tab1.col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT 33 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT DISTINCT 13 + col1 AS col2 FROM tab0 AS cor0
----
104
110
99

query I rowsort
SELECT + ( col0 ) + col1 * 4 * + col2 FROM tab0 cor0
----
11376
29937
423

query I rowsort
SELECT + cor0.col0 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT - ( + col0 ) * col2 * ( + 14 ) + - col2 FROM tab2
----
-2673
-28418
-42066

query I rowsort
SELECT col0 + 55 * col2 + - col2 FROM tab1
----
2919
3142
5264

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8966
SELECT DISTINCT CAST( NULL AS SIGNED ) + + col2 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-8966
SELECT DISTINCT CAST ( NULL AS INTEGER ) + + col2 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 66 * 24 * - col1 col1 FROM tab0
----
-136224
-144144
-153648

query I rowsort
SELECT ALL 28 + - cor0.col1 * - cor0.col0 FROM tab0 AS cor0
----
2092
3423
8127

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8969
SELECT CAST( NULL AS SIGNED ) * + ( col1 ) + - ( - cor0.col2 ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8969
SELECT CAST ( NULL AS INTEGER ) * + ( col1 ) + - ( - cor0.col2 ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col0 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-8971
SELECT + - col0 DIV - col0 + + col1 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-8971
SELECT + - col0 / - col0 + + col1 FROM tab0 AS cor0
----
87
92
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-8972
SELECT + col1 DIV col0 + - col1 FROM tab2 AS cor0
----
-17
-27
-59

skipif mysql # not compatible
query I rowsort label-8972
SELECT + col1 / col0 + - col1 FROM tab2 AS cor0
----
-17
-27
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * + col1 + + col1 * + cor0.col1 col0 FROM tab1 AS cor0
----
-540
-871
598

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8974
SELECT col2 + + CAST( col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-8974
SELECT col2 + + CAST ( col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL col2 * col0 + col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT + col2 * cor0.col2 + - col1 AS col0 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT - - col2 - + 31 FROM tab1 AS cor0
----
23
26
65

query I rowsort
SELECT DISTINCT + + col1 - 48 * - cor0.col0 FROM tab2 AS cor0
----
367
3803
3809

query I rowsort
SELECT ALL col1 + - 12 AS col0 FROM tab0 AS cor0
----
74
79
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8980
SELECT DISTINCT - col1 + + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8980
SELECT DISTINCT - col1 + + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - col1 * - 5 AS col0 FROM tab1 AS cor0
----
130
50
65

query I rowsort
SELECT + + cor0.col2 + ( + col2 ) FROM tab0 cor0
----
164
2
66

query I rowsort
SELECT ALL cor0.col2 * - cor0.col1 - col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT ALL + 41 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT - 55 FROM tab2, tab2 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to 037c686cf473a7e2cc59ce6c19d8dc57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8986
SELECT DISTINCT col1 DIV tab1.col2 + ( - col0 ) AS col2 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-8986
SELECT DISTINCT col1 / tab1.col2 + ( - col0 ) AS col2 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT DISTINCT + 90 * col2 AS col0 FROM tab0 AS cor0
----
2970
7380
90

query I rowsort
SELECT ALL - + col2 * col0 + + ( 60 ) * - col1 * - ( 83 ) + + col0 * ( col1 ) FROM tab0 AS cor0
----
429552
453981
486420

query I rowsort
SELECT - col1 * col0 * col0 + 70 AS col0 FROM tab0 AS cor0
----
-118755
-49466
-720741

query I rowsort
SELECT DISTINCT 98 FROM tab2 cor0
----
98

query I rowsort
SELECT DISTINCT ( + col2 ) + cor0.col0 * + col1 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT + 92 * col2 AS col0 FROM tab0 AS cor0
----
3036
7544
92

query I rowsort
SELECT ALL col0 * + col2 + - col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT - 4 FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
81 values hashing to df0306664dfa9962994889ea8d5edc5a

onlyif mysql # use DIV operator for integer division
query I rowsort label-8995
SELECT DISTINCT 30 DIV + col1 AS col2 FROM tab2
----
0
1

skipif mysql # not compatible
query I rowsort label-8995
SELECT DISTINCT 30 / + col1 AS col2 FROM tab2
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 68 + col2 col2 FROM tab0 cor0
----
101
150
69

query I rowsort
SELECT + 37 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to c023509f63faa044d654943e6df55ca2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 37 * - col2 col0 FROM tab0
----
-1221
-3034
-37

query I rowsort
SELECT tab1.col1 * col2 + 55 AS col0 FROM tab1
----
1303
1459
625

query I rowsort
SELECT + col1 * ( - 83 ) + + col0 AS col2 FROM tab2 AS cor0
----
-1332
-2566
-4819

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9001
SELECT ALL col2 * + col2 + + CAST( col2 AS SIGNED ) FROM tab1
----
2970
3306
9312

skipif mysql # not compatible
query I rowsort label-9001
SELECT ALL col2 * + col2 + + CAST ( col2 AS INTEGER ) FROM tab1
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-9002
SELECT ALL col0 + + tab2.col1 DIV col1 AS col2 FROM tab2
----
79
8
80

skipif mysql # not compatible
query I rowsort label-9002
SELECT ALL col0 + + tab2.col1 / col1 AS col2 FROM tab2
----
79
8
80

query I rowsort
SELECT DISTINCT + 95 + - tab1.col1 FROM tab1
----
69
82
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-9004
SELECT DISTINCT col2 + + col2 DIV + CAST( + col0 * - col2 + 43 AS SIGNED ) AS col0 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-9004
SELECT DISTINCT col2 + + col2 / + CAST ( + col0 * - col2 + 43 AS INTEGER ) AS col0 FROM tab2
----
26
27
38

query I rowsort
SELECT col2 * - 55 + col2 * col0 - - col1 FROM tab1 AS cor0
----
-2782
2413
523

query I rowsort
SELECT - - col1 * - cor0.col2 + + col0 * - col2 FROM tab2 AS cor0
----
-1026
-3562
-3648

query I rowsort
SELECT + + col1 * + cor0.col0 + - 24 AS col1 FROM tab0 AS cor0
----
2040
3371
8075

query I rowsort
SELECT DISTINCT col1 * col1 + col0 * 81 + + col2 * 0 AS col0 FROM tab1
----
5284
6649
919

query I rowsort
SELECT ALL 78 * - 68 * tab2.col0 AS col0 FROM tab2
----
-37128
-413712
-419016

query I rowsort
SELECT ALL ( - col1 ) * - col0 - + 30 AS col2 FROM tab2 AS cor0
----
1313
187
4572

query I rowsort
SELECT DISTINCT - ( tab0.col0 + - col2 ) AS col1 FROM tab0
----
-34
-7
9

query I rowsort
SELECT DISTINCT cor1.col0 AS col0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
7
78
79

query I rowsort
SELECT + 46 FROM tab1, tab0 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9014
SELECT + col0 * col0 + - cor0.col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9014
SELECT + col0 * col0 + - cor0.col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 + 77 FROM tab1 AS cor0
----
-3
13
74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 7 col1 FROM tab1 cor0
----
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9017
SELECT ALL - CAST( col0 AS SIGNED ) * + col0 - - col0 AS col0 FROM tab2 AS cor0
----
-42
-6006
-6162

skipif mysql # not compatible
query I rowsort label-9017
SELECT ALL - CAST ( col0 AS INTEGER ) * + col0 - - col0 AS col0 FROM tab2 AS cor0
----
-42
-6006
-6162

onlyif mysql # use DIV operator for integer division
query I rowsort label-9018
SELECT ALL - + 3 DIV col0 AS col2 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9018
SELECT ALL - + 3 / col0 AS col2 FROM tab2 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9019
SELECT + + col1 * col0 DIV col0 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9019
SELECT + + col1 * col0 / col0 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT - ( cor0.col1 ) * - col1 + cor0.col0 * cor0.col1 AS col0 FROM tab1 AS cor0
----
1209
740
754

query I rowsort
SELECT + 54 * + col2 * + col1 - - 87 AS col1 FROM tab2
----
34971
45285
82923

query I rowsort
SELECT 88 + + 95 FROM tab0
----
183
183
183

query I rowsort
SELECT DISTINCT + 68 AS col2 FROM tab2, tab2 AS cor0
----
68

query I rowsort
SELECT + tab1.col2 * + tab1.col1 - + col2 * 2 FROM tab1
----
1056
1296
456

query I rowsort
SELECT - - 0 AS col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT - cor0.col1 * col2 + 38 + - col1 FROM tab0 AS cor0
----
-156
-2886
-7515

query I rowsort
SELECT ALL - + cor0.col1 * + col1 * + col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - col0 col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + + 73 * col1 FROM tab1 AS cor0
----
1898
730
949

query I rowsort
SELECT DISTINCT + col2 * col0 * col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT - - ( col2 ) * cor0.col1 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9032
SELECT - col1 + CAST( NULL AS SIGNED ) + + col1 * col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9032
SELECT - col1 + CAST ( NULL AS INTEGER ) + + col1 * col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + tab2.col2 + + cor1.col0 AS col0 FROM tab2, tab2 cor0, tab2 cor1
----
27 values hashing to a7182bf415215b07824744b782a00748

query I rowsort
SELECT ALL tab0.col0 * + tab0.col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL + col1 - + ( + col1 ) * + col2 FROM tab0
----
-2752
-7371
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9036
SELECT ALL col1 - - ( - 51 ) * - col0 DIV tab2.col0 AS col2 FROM tab2
----
110
68
82

skipif mysql # not compatible
query I rowsort label-9036
SELECT ALL col1 - - ( - 51 ) * - col0 / tab2.col0 AS col2 FROM tab2
----
110
68
82

query I rowsort
SELECT 18 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9038
SELECT + ( - 47 ) + - col0 + CAST( 46 AS SIGNED ) FROM tab2 cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-9038
SELECT + ( - 47 ) + - col0 + CAST ( 46 AS INTEGER ) FROM tab2 cor0
----
-79
-8
-80

query I rowsort
SELECT - cor0.col0 * 81 * - col0 FROM tab0 cor0
----
46656
641601
99225

query I rowsort
SELECT - ( + col0 ) * col1 * - cor0.col0 FROM tab1 AS cor0
----
234
40960
83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-9041
SELECT + ( - 71 ) + col2 DIV col2 col1 FROM tab1 AS cor0
----
-70
-70
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9041
SELECT + ( - 71 ) + col2 / col2 col1 FROM tab1 AS cor0
----
-70
-70
-70

query I rowsort
SELECT DISTINCT 65 * + col2 + + col1 * col0 AS col2 FROM tab2 AS cor0
----
1972
3813
6292

query I rowsort
SELECT - col1 * col0 - col1 * - 60 AS col1 FROM tab1 AS cor0
----
-260
-40
1482

onlyif mysql # use DIV operator for integer division
query I rowsort label-9044
SELECT DISTINCT + 99 + col0 DIV col0 FROM tab0 AS cor0
----
100

skipif mysql # not compatible
query I rowsort label-9044
SELECT DISTINCT + 99 + col0 / col0 FROM tab0 AS cor0
----
100

query I rowsort
SELECT ALL + - ( ( col2 ) ) AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT col0 * 51 AS col1 FROM tab2
----
357
3978
4029

query I rowsort
SELECT DISTINCT col2 * - cor0.col2 FROM tab1 cor0
----
-2916
-3249
-9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9048
SELECT DISTINCT CAST( NULL AS SIGNED ) + cor0.col2 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9048
SELECT DISTINCT CAST ( NULL AS INTEGER ) + cor0.col2 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - ( + 13 ) + col1 * col0 * + col2 FROM tab1 AS cor0
----
36467
4199
99827

query I rowsort
SELECT ALL col2 + 54 * - col2 AS col0 FROM tab0
----
-1749
-4346
-53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col2 ) + col2 col1 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9052
SELECT ALL + col0 + 48 + + col0 * + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9052
SELECT ALL + col0 + 48 + + col0 * + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9053
SELECT DISTINCT - - CAST( - col2 AS SIGNED ) + col0 + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9053
SELECT DISTINCT - - CAST ( - col2 AS INTEGER ) + col0 + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9054
SELECT ALL - 33 + col2 DIV + col0 FROM tab2 AS cor0
----
-30
-33
-33

skipif mysql # not compatible
query I rowsort label-9054
SELECT ALL - 33 + col2 / + col0 FROM tab2 AS cor0
----
-30
-33
-33

query I rowsort
SELECT DISTINCT + - col1 + + col0 + col2 * - col2 FROM tab0 AS cor0
----
-1151
-63
-6726

query I rowsort
SELECT DISTINCT - col1 + - 84 * + col1 AS col0 FROM tab2 AS cor0
----
-1445
-2635
-5015

query I rowsort
SELECT ALL + col0 + - col1 * col1 + col2 FROM tab2 AS cor0
----
-172
-3377
-927

query I rowsort
SELECT cor0.col2 + + col0 * + col1 + + ( col2 * 94 ) AS col2 FROM tab2 AS cor0
----
2782
4953
7072

query I rowsort
SELECT + 88 + - col2 * col1 FROM tab0 AS cor0
----
-2750
-7374
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 27 * + col1 col1 FROM tab0 AS cor0
----
2322
2457
2619

onlyif mysql # use DIV operator for integer division
query I rowsort label-9061
SELECT DISTINCT - cor0.col0 + - col1 DIV 36 + col2 DIV - col0 FROM tab0 AS cor0
----
-27
-37
-91

skipif mysql # not compatible
query I rowsort label-9061
SELECT DISTINCT - cor0.col0 + - col1 / 36 + col2 / - col0 FROM tab0 AS cor0
----
-27
-37
-91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9062
SELECT ALL + ( col1 ) + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9062
SELECT ALL + ( col1 ) + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 87 * col1 + 69 * + col0 FROM tab1 AS cor0
----
2469
5286
6651

query I rowsort
SELECT + - col1 * cor0.col0 + col0 AS col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT 52 * col0 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
337
4030
4070

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9066
SELECT + 76 * cor0.col1 + - CAST( - 18 AS SIGNED ) + col0 * - CAST( col0 AS SIGNED ) FROM tab0 AS cor0
----
-987
5978
6165

skipif mysql # not compatible
query I rowsort label-9066
SELECT + 76 * cor0.col1 + - CAST ( - 18 AS INTEGER ) + col0 * - CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
-987
5978
6165

query I rowsort
SELECT ALL + tab2.col2 * ( + tab2.col1 ) + - ( - col1 ) FROM tab2
----
1593
663
868

query I rowsort
SELECT DISTINCT - + col2 * cor0.col0 - col2 * + col0 * + col2 FROM tab0 AS cor0
----
-26928
-605734
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-9069
SELECT DISTINCT - cor0.col1 DIV 13 + 2 FROM tab1 cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-9069
SELECT DISTINCT - cor0.col1 / 13 + 2 FROM tab1 cor0
----
0
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 + ( ( col2 ) ) * + col1 col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT + col0 * - col1 * - col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT ALL + - cor0.col1 - + 38 * + 81 FROM tab2 AS cor0
----
-3095
-3109
-3137

query I rowsort
SELECT ALL + col1 * 99 FROM tab1 cor0
----
1287
2574
990

query I rowsort
SELECT ALL - col0 * ( 17 * col0 ) AS col1 FROM tab1 AS cor0
----
-108800
-153
-69632

query I rowsort
SELECT DISTINCT + + col0 * 75 + col1 FROM tab1 cor0
----
251
4810
6013

query I rowsort
SELECT ALL col2 + ( cor0.col2 ) FROM tab2 AS cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 + + col1 * - col1 col1 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT ALL - cor0.col2 + + col2 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + 61 col0 FROM tab0 cor0
----
-1464
-2135
-5429

query I rowsort
SELECT ALL 54 AS col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 81150d59d6c3fc48b4ef5a4a5495bc7a

query I rowsort
SELECT + + 85 - col1 AS col0 FROM tab1 AS cor0
----
59
72
75

query I rowsort
SELECT + col0 - col1 * + col0 * 20 FROM tab2 cor0
----
-26781
-4333
-91962

query I rowsort
SELECT DISTINCT + 38 * - col0 * - col2 FROM tab0 AS cor0
----
1330
277324
30096

query I rowsort
SELECT ALL col0 * col2 + tab1.col0 + 12 * col1 FROM tab1
----
3832
477
7916

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + - col0 col0 FROM tab2 AS cor0
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 43 col0 FROM tab0
----
43
43
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-9087
SELECT DISTINCT col1 DIV col1 col0 FROM tab0 cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9087
SELECT DISTINCT col1 / col1 col0 FROM tab0 cor0
----
1

query I rowsort
SELECT DISTINCT - col1 + + col2 + + col0 FROM tab2
----
100
3
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-9089
SELECT - col1 * tab0.col1 DIV + ( tab0.col1 ) FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-9089
SELECT - col1 * tab0.col1 / + ( tab0.col1 ) FROM tab0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - col0 + 73 AS col0 FROM tab1 AS cor0
----
-7
70
9

query I rowsort
SELECT DISTINCT col0 * + col0 * col0 AS col1 FROM tab1 cor0
----
262144
27
512000

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9092
SELECT - col2 + + CAST( col1 AS SIGNED ) * cor0.col2 FROM tab2 cor0
----
1508
608
810

skipif mysql # not compatible
query I rowsort label-9092
SELECT - col2 + + CAST ( col1 AS INTEGER ) * cor0.col2 FROM tab2 cor0
----
1508
608
810

query I rowsort
SELECT DISTINCT 78 AS col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
78

query I rowsort
SELECT + col2 + + ( col1 + col1 ) FROM tab0 AS cor0
----
195
205
264

query I rowsort
SELECT + cor0.col0 * col0 + col1 * col2 FROM tab1 AS cor0
----
1413
4666
7648

onlyif mysql # use DIV operator for integer division
query I rowsort label-9096
SELECT - col2 DIV - 13 AS col0 FROM tab2 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-9096
SELECT - col2 / - 13 AS col0 FROM tab2 AS cor0
----
2
2
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + ( col0 ) col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9098
SELECT ALL - - cor0.col0 DIV + col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-9098
SELECT ALL - - cor0.col0 / + col2 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT cor0.col0 * - 31 AS col1 FROM tab1 AS cor0
----
-1984
-2480
-93

query I rowsort
SELECT + col0 * col1 + 22 AS col1 FROM tab0 cor0
----
2086
3417
8121

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col0 * col0 - col0 col0 FROM tab0
----
-13848
-42910
-705058

query III rowsort
SELECT * FROM tab0 WHERE NOT ( NULL ) NOT BETWEEN + col1 AND col0 * col0
----

query I rowsort
SELECT DISTINCT col1 - - col1 * col0 * + col1 AS col2 FROM tab1
----
13533
2054
6410

query I rowsort
SELECT - col2 + col1 FROM tab2 WHERE NOT col1 >= + col0 * col1 * - col1
----

query III rowsort
SELECT ALL * FROM tab1 WHERE ( NULL ) < col0
----

query I rowsort
SELECT DISTINCT + col1 FROM tab2 WHERE NOT ( NULL ) >= NULL
----

query I rowsort
SELECT + col0 + + col1 * tab0.col1 FROM tab0
----
7420
8370
9444

query I rowsort
SELECT + - col0 * + col2 + cor0.col2 AS col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT - - 44 * - col2 AS col1 FROM tab0 AS cor0
----
-1452
-3608
-44

query I rowsort
SELECT - - 69 * - col2 FROM tab1 AS cor0
----
-3726
-3933
-6624

query I rowsort
SELECT DISTINCT + - cor0.col1 + col1 * + 71 * col0 FROM tab2 AS cor0
----
15376
326683
95336

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 53 * - col0 col0 FROM tab2 AS cor0
----
-371
-4134
-4187

query I rowsort
SELECT DISTINCT + col0 * - 30 AS col2 FROM tab0 AS cor0
----
-1050
-2670
-720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col1 + col0 * + col2 col1 FROM tab0 AS cor0
----
-164
-2046
-62

query I rowsort
SELECT + col1 + col1 * - 76 AS col2 FROM tab0 AS cor0
----
-6450
-6825
-7275

query I rowsort
SELECT - col0 + 2 FROM tab2 AS cor0
----
-5
-76
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 3 + + ( col1 ) col1 FROM tab2 AS cor0
----
20
34
62

query I rowsort
SELECT + 77 * + col1 AS col0 FROM tab2 AS cor0
----
1309
2387
4543

query I rowsort
SELECT DISTINCT + ( col0 ) + col1 FROM tab2
----
137
38
96

query I rowsort
SELECT + - 54 * 63 AS col0 FROM tab1 AS cor0
----
-3402
-3402
-3402

query I rowsort
SELECT ALL - cor0.col1 - + col1 AS col2 FROM tab1 cor0
----
-20
-26
-52

query I rowsort
SELECT - + col0 * ( - cor0.col1 ) - - col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL col1 * + col1 + + col0 AS col0 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT - cor0.col2 * + 89 + - col0 FROM tab2 AS cor0
----
-2392
-2410
-3461

query I rowsort
SELECT DISTINCT col1 * - ( col0 ) FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT col1 * - 65 * col1 + col2 FROM tab1 AS cor0
----
-10889
-43886
-6443

query I rowsort
SELECT ALL col0 + - 93 * col2 AS col0 FROM tab2
----
-2340
-2504
-3455

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab1.col0 * 43 + + col1 col2 FROM tab1
----
-103
-2742
-3427

query I rowsort
SELECT - cor0.col2 * - 16 FROM tab0 AS cor0
----
1312
16
528

query I rowsort
SELECT col0 + + col1 + + 62 AS col0 FROM tab1
----
136
155
91

query I rowsort
SELECT DISTINCT + col2 + + ( - col1 ) + col2 FROM tab2
----
-7
23
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-9132
SELECT DISTINCT - tab2.col2 * + ( + col2 ) + + col1 DIV ( tab2.col1 ) col0 FROM tab2
----
-1443
-675
-728

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9132
SELECT DISTINCT - tab2.col2 * + ( + col2 ) + + col1 / ( tab2.col1 ) col0 FROM tab2
----
-1443
-675
-728

query I rowsort
SELECT - 51 * 36 FROM tab2, tab1 AS cor0
----
9 values hashing to b3d969d80e4c64f3aa5dd1df1348643a

onlyif mysql # use DIV operator for integer division
query I rowsort label-9134
SELECT cor0.col0 + 74 DIV - 21 AS col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 0f07abde3f2df8420b8e2d179c674a53

skipif mysql # not compatible
query I rowsort label-9134
SELECT cor0.col0 + 74 / - 21 AS col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 0f07abde3f2df8420b8e2d179c674a53

query I rowsort
SELECT - col2 * col1 + col1 AS col1 FROM tab1
----
-1235
-1378
-560

query I rowsort
SELECT tab2.col0 * + col0 + - col0 AS col0 FROM tab2
----
42
6006
6162

query I rowsort
SELECT ALL + col1 * 21 * - col0 FROM tab0
----
-170079
-43344
-71295

onlyif mysql # use DIV operator for integer division
query I rowsort label-9138
SELECT DISTINCT 66 DIV 51 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-9138
SELECT DISTINCT 66 / 51 FROM tab2
----
1

query I rowsort
SELECT DISTINCT 70 AS col1 FROM tab1, tab2 AS cor0
----
70

query I rowsort
SELECT ALL - ( - col1 ) + - 64 * col2 + + cor0.col1 AS col0 FROM tab1 AS cor0
----
-3404
-3628
-6118

query I rowsort
SELECT DISTINCT + col1 * col1 * col0 + ( col2 ) FROM tab0 AS cor0
----
177537
329316
737091

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 19 col2 FROM tab0 cor0
----
19
19
19

query I rowsort
SELECT ALL + - 64 * col0 AS col1 FROM tab0 AS cor0
----
-1536
-2240
-5696

query I rowsort
SELECT ( + col0 * col2 ) AS col1 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT + ( col0 * - 74 ) - col0 AS col1 FROM tab2
----
-525
-5850
-5925

query I rowsort
SELECT ( col0 ) * - ( 19 ) FROM tab0 cor0
----
-1691
-456
-665

query I rowsort
SELECT ALL + col1 * + col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT + + col2 * col1 * col2 + col1 - + col0 AS col2 FROM tab1 AS cor0
----
119741
32436
75839

query I rowsort
SELECT - col2 * col1 + ( 21 ) FROM tab1 AS cor0
----
-1227
-1383
-549

query I rowsort
SELECT - col1 + + col1 * + col0 * col2 - col2 FROM tab1 AS cor0
----
36413
4132
99731

query I rowsort
SELECT 16 + - tab1.col1 AS col2 FROM tab1
----
-10
3
6

query I rowsort
SELECT cor0.col1 * 7 * - tab2.col0 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 952da9755254e4c8af7be00c9a929d1b

query I rowsort
SELECT + col2 * - col0 - 64 FROM tab0
----
-7362
-856
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-9154
SELECT ALL - col0 * + col0 DIV col0 - cor0.col1 * col0 FROM tab2 AS cor0
----
-1422
-224
-4680

skipif mysql # not compatible
query I rowsort label-9154
SELECT ALL - col0 * + col0 / col0 - cor0.col1 * col0 FROM tab2 AS cor0
----
-1422
-224
-4680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9155
SELECT ALL - col0 * + CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9155
SELECT ALL - col0 * + CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * ( 30 ) * + col0 FROM tab0 AS cor0
----
1050
218940
23760

onlyif mysql # use DIV operator for integer division
query I rowsort label-9157
SELECT - col2 * 81 DIV - col0 AS col1 FROM tab0 AS cor0
----
111
2
74

skipif mysql # not compatible
query I rowsort label-9157
SELECT - col2 * 81 / - col0 AS col1 FROM tab0 AS cor0
----
111
2
74

query I rowsort
SELECT DISTINCT + col0 + 43 FROM tab2 AS cor0
----
121
122
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + ( - col1 ) - + col2 col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - col1 + 19 FROM tab2 AS cor0
----
-12
-40
2

skipif mysql # not compatible
query I rowsort
SELECT - col2 - + CAST ( - col0 AS REAL ) AS col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT - col2 + - 98 * - col1 FROM tab0 AS cor0
----
8395
8836
9505

query I rowsort
SELECT ALL - col0 + 5 AS col0 FROM tab0 AS cor0
----
-19
-30
-84

onlyif mysql # use DIV operator for integer division
query I rowsort label-9164
SELECT - col0 DIV + col0 - + 17 AS col1 FROM tab2 AS cor0
----
-18
-18
-18

skipif mysql # not compatible
query I rowsort label-9164
SELECT - col0 / + col0 - + 17 AS col1 FROM tab2 AS cor0
----
-18
-18
-18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9165
SELECT CAST( NULL AS SIGNED ) + + col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9165
SELECT CAST ( NULL AS INTEGER ) + + col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * - 4 + col0 AS col0 FROM tab2 AS cor0
----
-117
-158
11

query I rowsort
SELECT 42 + 29 * + col0 * + 80 AS col2 FROM tab2 cor0
----
16282
181002
183322

query I rowsort
SELECT DISTINCT + + col1 * col0 * col1 - - 49 * col2 AS col0 FROM tab1 AS cor0
----
18224
4674
9193

query I rowsort
SELECT DISTINCT + + cor0.col2 * + col1 + - col0 + 37 * cor0.col0 * col2 AS col1 FROM tab2 AS cor0
----
111641
76492
7823

query I rowsort
SELECT - - col2 + 70 * col1 AS col1 FROM tab0 AS cor0
----
6053
6452
6791

query I rowsort
SELECT ALL + cor0.col0 * - col1 + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT + col1 * col1 + + col1 AS col2 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT DISTINCT - col0 - col1 FROM tab1 cor0
----
-29
-74
-93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9174
SELECT - - ( - col2 ) + col0 * + CAST( NULL AS SIGNED ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9174
SELECT - - ( - col2 ) + col0 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col1 + + 6 * col2 + 61 * - col0 AS col2 FROM tab1 AS cor0
----
-3552
-4291
167

query I rowsort
SELECT ALL + ( + ( col0 ) ) * - ( - col1 ) FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT 2 + col2 AS col1 FROM tab2 AS cor0
----
28
29
40

query I rowsort
SELECT DISTINCT + cor0.col2 * ( col0 ) - 38 FROM tab2 AS cor0
----
151
1990
2964

query I rowsort
SELECT ALL col2 * ( col0 ) FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + + 82 FROM tab2 cor0
----
82

query I rowsort
SELECT DISTINCT - - col1 + + col2 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL col2 * col1 + 41 + col0 AS col2 FROM tab1 AS cor0
----
1369
1448
675

query I rowsort
SELECT + - 17 * col2 FROM tab1 AS cor0
----
-1632
-918
-969

query I rowsort
SELECT col2 * - 3 * - cor0.col0 AS col1 FROM tab0 cor0
----
105
21894
2376

onlyif mysql # use DIV operator for integer division
query I rowsort label-9185
SELECT + ( col1 ) + col0 DIV CAST( + 23 AS SIGNED ) FROM tab2 AS cor0
----
20
31
62

skipif mysql # not compatible
query I rowsort label-9185
SELECT + ( col1 ) + col0 / CAST ( + 23 AS INTEGER ) FROM tab2 AS cor0
----
20
31
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-9186
SELECT ALL col1 DIV ( + col0 ) FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-9186
SELECT ALL col1 / ( + col0 ) FROM tab0
----
1
2
3

query I rowsort
SELECT DISTINCT - tab0.col0 * - 28 AS col0 FROM tab0
----
2492
672
980

query I rowsort
SELECT ALL + ( - col2 ) * + col2 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT + 85 + col2 + col2 AS col1 FROM tab2
----
137
139
161

onlyif mysql # use DIV operator for integer division
query I rowsort label-9190
SELECT + tab0.col1 DIV + col2 AS col0 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-9190
SELECT + tab0.col1 / + col2 AS col0 FROM tab0
----
1
2
97

query I rowsort
SELECT ALL - 96 * + cor0.col1 FROM tab0 AS cor0
----
-8256
-8736
-9312

query I rowsort
SELECT ALL col1 + col0 * - col1 FROM tab2 AS cor0
----
-1326
-186
-4543

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9193
SELECT + CAST( NULL AS SIGNED ) * - 85 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9193
SELECT + CAST ( NULL AS INTEGER ) * - 85 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 65 * col1 AS col0 FROM tab0
----
5590
5915
6305

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9195
SELECT col0 + + col0 * CAST( NULL AS DECIMAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9195
SELECT col0 + + col0 * CAST ( NULL AS REAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + 42 * + col0 AS col0 FROM tab2 AS cor0
----
294
3276
3318

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 32 + cor1.col0 col0 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
112
35
96

query I rowsort
SELECT DISTINCT 91 * + col0 AS col0 FROM tab1
----
273
5824
7280

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 col1 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT - - col1 + cor0.col1 * 32 FROM tab0 AS cor0
----
2838
3003
3201

onlyif mysql # use DIV operator for integer division
query I rowsort label-9201
SELECT col0 * col2 DIV 75 FROM tab1 AS cor0
----
102
2
48

skipif mysql # not compatible
query I rowsort label-9201
SELECT col0 * col2 / 75 FROM tab1 AS cor0
----
102
2
48

query I rowsort
SELECT ALL - - col0 * + 51 AS col2 FROM tab0 AS cor0
----
1224
1785
4539

query I rowsort
SELECT DISTINCT - - col2 * ( + col0 * col0 + col2 ) FROM tab0 AS cor0
----
1226
20097
656246

onlyif mysql # use DIV operator for integer division
query I rowsort label-9204
SELECT col1 * col2 DIV - 62 col1 FROM tab1 AS cor0
----
-20
-22
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9204
SELECT col1 * col2 / - 62 col1 FROM tab1 AS cor0
----
-20
-22
-9

query I rowsort
SELECT DISTINCT - 92 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
-92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - ( ( - col2 ) ) col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT 51 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT - + col0 * + col0 + + col2 * cor0.col1 FROM tab2 cor0
----
-4550
-5595
788

query I rowsort
SELECT - col0 * + ( - col1 ) FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT + col2 * + col2 * col1 + cor0.col2 * - 1 FROM tab2 AS cor0
----
22572
24510
39858

query I rowsort
SELECT - + col0 + 11 * + col0 AS col1 FROM tab1 AS cor0
----
30
640
800

query I rowsort
SELECT ( col0 ) * col2 * col0 AS col0 FROM tab0 cor0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT - - 11 + - ( col2 ) AS col0 FROM tab0 cor0
----
-22
-71
10

query I rowsort
SELECT 51 + - col2 * 17 FROM tab0 AS cor0
----
-1343
-510
34

query I rowsort
SELECT ALL + - 61 + col2 FROM tab1 AS cor0
----
-4
-7
35

query I rowsort
SELECT + + 83 * col1 - - cor0.col1 FROM tab1 AS cor0
----
1092
2184
840

query I rowsort
SELECT ALL + 2 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT - col1 + + ( - col1 ) FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT + 45 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

query I rowsort
SELECT - cor0.col2 + ( - col0 ) AS col1 FROM tab0 AS cor0
----
-171
-36
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 44 col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

query I rowsort
SELECT DISTINCT - 35 * + cor0.col2 AS col1 FROM tab2, tab2 AS cor0
----
-1330
-910
-945

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 + + col1 col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT - - 29 * + col0 + col1 * + col1 AS col2 FROM tab1 AS cor0
----
1956
2489
763

onlyif mysql # use DIV operator for integer division
query I rowsort label-9225
SELECT - + ( + 47 ) DIV col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9225
SELECT - + ( + 47 ) / col2 AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9226
SELECT ALL - + col2 * + ( col0 ) * - CAST( NULL AS SIGNED ) + - 66 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9226
SELECT ALL - + col2 * + ( col0 ) * - CAST ( NULL AS INTEGER ) + - 66 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + cor0.col0 + + col0 FROM tab0 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9228
SELECT + - col1 * + col0 + cor0.col2 DIV 40 FROM tab0 cor0
----
-2064
-3395
-8097

skipif mysql # not compatible
query I rowsort label-9228
SELECT + - col1 * + col0 + cor0.col2 / 40 FROM tab0 cor0
----
-2064
-3395
-8097

query I rowsort
SELECT + 36 + + col1 * col1 * + col0 + cor0.col2 FROM tab1 AS cor0
----
13652
2118
6493

query I rowsort
SELECT + + ( col1 ) * + 11 AS col2 FROM tab0 AS cor0
----
1001
1067
946

query I rowsort
SELECT DISTINCT - + 0 * col2 FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9232
SELECT ALL col1 + col1 DIV - col0 AS col1 FROM tab1 AS cor0
----
10
13
18

skipif mysql # not compatible
query I rowsort label-9232
SELECT ALL col1 + col1 / - col0 AS col1 FROM tab1 AS cor0
----
10
13
18

query I rowsort
SELECT ALL + tab1.col0 - + col2 FROM tab1
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9234
SELECT ALL col1 DIV + 21 AS col2 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9234
SELECT ALL col1 / + 21 AS col2 FROM tab1
----
0
0
1

query I rowsort
SELECT cor0.col0 * - ( col2 ) FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + ( 84 ) col0 FROM tab0 AS cor0
----
170
175
181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 + + 28 * 60 col2 FROM tab0 cor0
----
1591
1645
1656

query I rowsort
SELECT DISTINCT - cor0.col2 * ( col2 ) FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-9239
SELECT DISTINCT - + col0 DIV 10 - - col2 * col1 col1 FROM tab2 AS cor0
----
1527
639
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9239
SELECT DISTINCT - + col0 / 10 - - col2 * col1 col1 FROM tab2 AS cor0
----
1527
639
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9240
SELECT ALL cor0.col1 * + CAST( + col2 AS SIGNED ) FROM tab2 AS cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-9240
SELECT ALL cor0.col1 * + CAST ( + col2 AS INTEGER ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + col1 * + col0 + col2 FROM tab0 cor0
----
2097
3396
8181

query I rowsort
SELECT ALL ( + col1 ) * cor0.col2 + col2 - + 96 FROM tab1 AS cor0
----
1248
1362
531

query I rowsort
SELECT DISTINCT - 31 - - col0 FROM tab0 AS cor0
----
-7
4
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9244
SELECT CAST( col0 AS SIGNED ) * + cor0.col1 FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-9244
SELECT CAST ( col0 AS INTEGER ) * + cor0.col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL cor0.col2 * col0 + + col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT + col2 - + col1 * tab0.col1 FROM tab0
----
-7363
-8199
-9408

query I rowsort
SELECT col0 + 13 AS col1 FROM tab0
----
102
37
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9248
SELECT + col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9248
SELECT + col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * ( + 39 ) + + col1 AS col0 FROM tab1
----
-380
-494
-988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col1 * - col2 col2 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT ALL - 55 * col0 AS col0 FROM tab2 AS cor0
----
-385
-4290
-4345

query I rowsort
SELECT + - col1 * col0 AS col0 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9253
SELECT DISTINCT + CAST( - cor0.col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-9253
SELECT DISTINCT + CAST ( - cor0.col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-9254
SELECT - - 50 DIV - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-9254
SELECT - - 50 / - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 48 col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT DISTINCT - 2 + 4 FROM tab2 AS cor0
----
2

query I rowsort
SELECT - col2 * 23 + + col2 * + col1 AS col1 FROM tab0
----
2079
5576
74

query I rowsort
SELECT ALL + col2 * - col2 * - col1 AS col1 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT 67 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

query I rowsort
SELECT ( ( col0 ) ) + + ( - col2 ) FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL 73 * - 1 AS col1 FROM tab0 AS cor0
----
-73
-73
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-9262
SELECT ALL + col2 DIV - 40 + cor0.col2 * + col1 AS col2 FROM tab0 AS cor0
----
2838
7460
97

skipif mysql # not compatible
query I rowsort label-9262
SELECT ALL + col2 / - 40 + cor0.col2 * + col1 AS col2 FROM tab0 AS cor0
----
2838
7460
97

query I rowsort
SELECT - col2 * - col0 * 86 FROM tab0 AS cor0
----
3010
627628
68112

query I rowsort
SELECT ( - tab2.col1 ) - - col2 AS col2 FROM tab2
----
-33
-4
21

query I rowsort
SELECT col0 - col1 * tab2.col2 AS col0 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT + col1 * tab0.col2 + + col0 FROM tab0
----
132
2862
7551

query I rowsort
SELECT - cor0.col2 + col1 * cor0.col1 AS col1 FROM tab1 AS cor0
----
43
622
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-9268
SELECT col2 DIV - col0 AS col2 FROM tab1 cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-9268
SELECT col2 / - col0 AS col2 FROM tab1 cor0
----
-1
-18
0

query I rowsort
SELECT ALL 19 + col1 * + col0 FROM tab1
----
1059
659
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9270
SELECT + col2 DIV + col2 + + 24 AS col1 FROM tab1
----
25
25
25

skipif mysql # not compatible
query I rowsort label-9270
SELECT + col2 / + col2 + + 24 AS col1 FROM tab1
----
25
25
25

query I rowsort
SELECT DISTINCT - col2 * - col0 * col2 + col1 * col0 AS col0 FROM tab0
----
28200
3430
606535

query I rowsort
SELECT DISTINCT + ( tab0.col0 ) AS col0 FROM tab0, tab2 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-9273
SELECT DISTINCT - cor0.col2 * col0 DIV + ( col2 ) + - col0 FROM tab1 AS cor0
----
-128
-160
-6

skipif mysql # not compatible
query I rowsort label-9273
SELECT DISTINCT - cor0.col2 * col0 / + ( col2 ) + - col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT ALL + col0 * + col2 - + 44 AS col2 FROM tab1 AS cor0
----
118
3604
7636

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * ( + col2 ) col0 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + col1 * - 73 col2 FROM tab2 AS cor0
----
-1258
-2294
-4366

query I rowsort
SELECT DISTINCT cor0.col1 * cor0.col0 AS col1 FROM tab2, tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT col1 + cor0.col0 + 46 AS col2 FROM tab0 AS cor0
----
156
178
226

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9279
SELECT - - col2 + + CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
108
114
192

skipif mysql # not compatible
query I rowsort label-9279
SELECT - - col2 + + CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT - + col1 * + col1 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT + cor0.col0 + 41 + col1 * col1 AS col0 FROM tab2 AS cor0
----
1009
3600
409

query I rowsort
SELECT DISTINCT - cor0.col1 * ( col2 * cor0.col0 ) AS col0 FROM tab2 cor0
----
-119652
-51034
-5859

query I rowsort
SELECT + - col0 * 54 AS col0 FROM tab1 AS cor0
----
-162
-3456
-4320

query I rowsort
SELECT DISTINCT + - col1 * 41 AS col1 FROM tab2 AS cor0
----
-1271
-2419
-697

query I rowsort
SELECT DISTINCT - col0 + - col2 * - col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT - col1 + - col2 * 95 FROM tab0 AS cor0
----
-192
-3221
-7881

query I rowsort
SELECT ALL + cor0.col1 + cor0.col2 * 88 AS col0 FROM tab1 AS cor0
----
4778
5026
8461

query I rowsort
SELECT 9 * + col0 * col1 + 94 * - col1 FROM tab2 AS cor0
----
-961
10489
35872

query I rowsort
SELECT - + col2 * 36 AS col1 FROM tab1 AS cor0
----
-1944
-2052
-3456

onlyif mysql # use DIV operator for integer division
query I rowsort label-9290
SELECT cor0.col2 DIV col2 col2 FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9290
SELECT cor0.col2 / col2 col2 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT col2 + 28 * + col1 AS col2 FROM tab0 AS cor0
----
2441
2630
2717

query I rowsort
SELECT - 69 * - col0 + col1 AS col2 FROM tab0
----
1742
2512
6232

query I rowsort
SELECT - 38 AS col1 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to e8c064543bf0f2e57329db1bb0a411e3

query I rowsort
SELECT - + ( - 95 ) FROM tab0 AS cor0
----
95
95
95

query I rowsort
SELECT - + 10 AS col2 FROM tab0 AS cor0
----
-10
-10
-10

query I rowsort
SELECT - + 10 + col1 FROM tab2 AS cor0
----
21
49
7

query I rowsort
SELECT + ( - col1 ) + cor0.col0 * col0 AS col2 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT ALL 54 + col0 * col0 AS col2 FROM tab2 cor0
----
103
6138
6295

query I rowsort
SELECT - 39 + cor0.col0 AS col0 FROM tab1 AS cor0
----
-36
25
41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9300
SELECT + + ( col2 ) + col0 * + CAST( NULL AS SIGNED ) * 59 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9300
SELECT + + ( col2 ) + col0 * + CAST ( NULL AS INTEGER ) * 59 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 4 * 89 AS col0 FROM tab0 cor0
----
356
356
356

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9302
SELECT - ( cor0.col1 ) * col0 + - CAST( NULL AS DECIMAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9302
SELECT - ( cor0.col1 ) * col0 + - CAST ( NULL AS REAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9303
SELECT + + col1 + col1 DIV cor0.col1 AS col2 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-9303
SELECT + + col1 + col1 / cor0.col1 AS col2 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT ALL + col0 + - 25 FROM tab2
----
-18
53
54

query I rowsort
SELECT col0 + col1 + - col2 * col0 AS col2 FROM tab2
----
-151
-1891
-2906

query I rowsort
SELECT - col0 + - 29 FROM tab0 AS cor0
----
-118
-53
-64

query I rowsort
SELECT col1 + col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-9308
SELECT DISTINCT + cor0.col0 - + col2 DIV col2 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-9308
SELECT DISTINCT + cor0.col0 - + col2 / col2 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT + 9 + ( col0 ) AS col1 FROM tab1 AS cor0
----
12
73
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9310
SELECT ALL - CAST( col2 AS SIGNED ) + col0 AS col1 FROM tab0 cor0
----
-9
34
7

skipif mysql # not compatible
query I rowsort label-9310
SELECT ALL - CAST ( col2 AS INTEGER ) + col0 AS col1 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT + col2 * cor0.col2 * + col1 AS col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT cor0.col1 * - col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT - - col2 + - col0 * - 48 + - col0 FROM tab2 AS cor0
----
356
3692
3751

onlyif mysql # use DIV operator for integer division
query I rowsort label-9314
SELECT DISTINCT - 43 DIV col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-9314
SELECT DISTINCT - 43 / col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT 32 * - col0 AS col2 FROM tab0
----
-1120
-2848
-768

query I rowsort
SELECT ALL - col1 - + col2 * ( + col1 ) * col1 FROM tab1 AS cor0
----
-16237
-36530
-5710

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9317
SELECT CAST( + col1 AS SIGNED ) * + col2 FROM tab2
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-9317
SELECT CAST ( + col1 AS INTEGER ) * + col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT ( col1 ) * col1 + + col2 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT + cor0.col0 * + col2 * 12 AS col1 FROM tab2 AS cor0
----
2268
24336
36024

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9320
SELECT CAST( - col0 AS SIGNED ) AS col1 FROM tab2
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-9320
SELECT CAST ( - col0 AS INTEGER ) AS col1 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT + + tab2.col2 FROM tab2, tab1, tab2 AS cor0, tab0
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT col1 * 73 AS col1 FROM tab2
----
1241
2263
4307

query I rowsort
SELECT DISTINCT - 71 AS col0 FROM tab0
----
-71

query I rowsort
SELECT 49 - + col0 FROM tab0
----
-40
14
25

query I rowsort
SELECT DISTINCT - 84 + - col1 FROM tab1
----
-110
-94
-97

query I rowsort
SELECT 27 + col2 FROM tab2 AS cor0
----
53
54
65

query I rowsort
SELECT - + col1 * col1 + col1 AS col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT 15 + + 71 * + cor0.col0 FROM tab0, tab1 AS cor0
----
228
4559
5695

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col2 col1 FROM tab1 cor0 CROSS JOIN tab2, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 7 + - cor1.col2 col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 9b63b6d4aa2da176e38cb64c330a2d93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * - col2 * col2 col2 FROM tab0 AS cor0
----
-611884
-93654
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9332
SELECT DISTINCT + tab1.col2 DIV tab1.col1 - + col0 FROM tab1
----
-1
-59
-73

skipif mysql # not compatible
query I rowsort label-9332
SELECT DISTINCT + tab1.col2 / tab1.col1 - + col0 FROM tab1
----
-1
-59
-73

query I rowsort
SELECT ALL col1 + - col2 - col2 * 73 FROM tab2
----
-1865
-1967
-2795

query I rowsort
SELECT - + 4 + + 69 - col0 FROM tab1 AS cor0
----
-15
1
62

query I rowsort
SELECT DISTINCT col0 * 21 FROM tab1 AS cor0
----
1344
1680
63

query I rowsort
SELECT - - cor0.col0 * col1 * col1 + 46 * + col0 AS col2 FROM tab2 AS cor0
----
26465
275106
7049

query I rowsort
SELECT ALL - tab0.col2 * + col1 AS col0 FROM tab0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9338
SELECT ALL - + col0 DIV col1 AS col0 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-9338
SELECT ALL - + col0 / col1 AS col0 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT - col1 * cor0.col0 * + col2 AS col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9340
SELECT + CAST( NULL AS SIGNED ) - + 30 * - col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9340
SELECT + CAST ( NULL AS INTEGER ) - + 30 * - col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 67 AS col1 FROM tab0, tab2 AS cor0
----
67

query I rowsort
SELECT ALL + ( + col1 ) + col2 * col1 * - col2 FROM tab0
----
-611793
-93568
0

query I rowsort
SELECT ALL - 93 + - col0 * col2 AS col0 FROM tab1
----
-255
-3741
-7773

query I rowsort
SELECT ALL + + col1 + + 37 AS col2 FROM tab2 AS cor0
----
54
68
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9345
SELECT DISTINCT + - col0 - - cor0.col0 * col0 DIV - col1 AS col0 FROM tab1 AS cor0
----
-3
-473
-572

skipif mysql # not compatible
query I rowsort label-9345
SELECT DISTINCT + - col0 - - cor0.col0 * col0 / - col1 AS col0 FROM tab1 AS cor0
----
-3
-473
-572

onlyif mysql # use DIV operator for integer division
query I rowsort label-9346
SELECT 54 DIV col1 + col1 FROM tab1 cor0
----
15
17
28

skipif mysql # not compatible
query I rowsort label-9346
SELECT 54 / col1 + col1 FROM tab1 cor0
----
15
17
28

query I rowsort
SELECT + col0 * + ( col2 * cor0.col2 ) + col2 FROM tab1 cor0
----
207993
737376
8802

query I rowsort
SELECT DISTINCT - - col2 + - col1 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT ALL - cor0.col0 + - col2 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT - col2 + - col0 * col0 AS col1 FROM tab0 cor0
----
-1226
-609
-8003

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 11 + col1 col1 FROM tab2 AS cor0
----
28
42
70

query I rowsort
SELECT - - 7 * + cor0.col1 + + col1 AS col1 FROM tab0 AS cor0
----
688
728
776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col1 * col0 + col2 col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT col1 + col1 * + col2 FROM tab0 AS cor0
----
194
2924
7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 16 * col2 * - col2 col2 FROM tab2 AS cor0
----
-10816
-11664
-23104

query I rowsort
SELECT DISTINCT + - 56 + col2 * col1 AS col2 FROM tab1 AS cor0
----
1192
1348
514

query I rowsort
SELECT ALL + ( + 77 ) AS col2 FROM tab2
----
77
77
77

query I rowsort
SELECT - 86 * col1 AS col0 FROM tab0
----
-7396
-7826
-8342

query I rowsort
SELECT ALL - + col2 + col1 * col1 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT ALL + - ( col0 ) + col1 * col0 AS col1 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT + + 85 FROM tab0 cor0
----
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-9362
SELECT DISTINCT - col1 DIV + col1 + - col1 AS col1 FROM tab0 cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-9362
SELECT DISTINCT - col1 / + col1 + - col1 AS col1 FROM tab0 cor0
----
-87
-92
-98

query I rowsort
SELECT + col1 * + col2 + tab0.col1 AS col2 FROM tab0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-9364
SELECT + col1 + + col2 DIV col2 FROM tab0 AS cor0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-9364
SELECT + col1 + + col2 / col2 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT DISTINCT cor0.col0 + cor0.col0 AS col1 FROM tab1, tab0 AS cor0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-9366
SELECT - col0 + - col1 DIV col1 + + col2 * + col0 * col0 col2 FROM tab0
----
1189
18983
649432

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9366
SELECT - col0 + - col1 / col1 + + col2 * + col0 * col0 col2 FROM tab0
----
1189
18983
649432

query I rowsort
SELECT DISTINCT - cor0.col2 + cor0.col0 AS col1 FROM tab2, tab0 AS cor0
----
-9
34
7

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( NULL ) IN ( - col0 + + col2 )
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE ( NULL ) > tab1.col2 * + col0 * col0 + + col2 + col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9370
SELECT col1 + tab1.col1 DIV col2 + + tab1.col1 * col0 FROM tab1
----
104
1053
650

skipif mysql # not compatible
query I rowsort label-9370
SELECT col1 + tab1.col1 / col2 + + tab1.col1 * col0 FROM tab1
----
104
1053
650

query I rowsort
SELECT col1 * col0 + col0 - col0 AS col1 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-9372
SELECT ALL + col2 DIV - col2 - - col0 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-9372
SELECT ALL + col2 / - col2 - - col0 FROM tab1
----
2
63
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col2 * - col1 col0 FROM tab0 WHERE NOT NULL IN ( col1 + + col2 )
----

query I rowsort
SELECT DISTINCT col0 * - col2 + + col2 FROM tab2
----
-162
-2002
-2964

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT ( - col2 ) NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL col2 / + col0 FROM tab1 WHERE NOT + col0 BETWEEN NULL AND NULL
----

query III rowsort
SELECT ALL * FROM tab2 WHERE col1 NOT BETWEEN NULL AND + col0 + - col2 * col2
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-9378
SELECT ALL - col2 DIV + col1 + + col2 AS col0 FROM tab1 AS cor0
----
52
52
89

skipif mysql # not compatible
query I rowsort label-9378
SELECT ALL - col2 / + col1 + + col2 AS col0 FROM tab1 AS cor0
----
52
52
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-9379
SELECT - col0 * cor0.col2 - + cor0.col1 DIV cor0.col1 col2 FROM tab1 AS cor0
----
-163
-3649
-7681

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9379
SELECT - col0 * cor0.col2 - + cor0.col1 / cor0.col1 col2 FROM tab1 AS cor0
----
-163
-3649
-7681

query I rowsort
SELECT DISTINCT - col0 * col2 + + col1 - - col0 FROM tab2 AS cor0
----
-151
-1891
-2906

query I rowsort
SELECT ALL + col2 + + cor0.col0 * - col2 FROM tab1 cor0
----
-108
-3591
-7584

query I rowsort
SELECT + col2 - tab1.col0 * + col2 FROM tab1
----
-108
-3591
-7584

query I rowsort
SELECT + col0 + - col2 * + col0 * col1 - - col1 FROM tab2
----
-119515
-50938
-5821

query I rowsort
SELECT + cor0.col0 + col1 * col1 - - col1 AS col2 FROM tab1 AS cor0
----
174
262
705

query I rowsort
SELECT DISTINCT + + col0 * col1 AS col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT ALL - + col0 * + cor0.col0 - col2 * col0 FROM tab1 cor0
----
-14080
-171
-7744

query I rowsort
SELECT + col1 + col0 + + col1 FROM tab1
----
106
55
84

query I rowsort
SELECT ALL + tab0.col1 * col1 * + col2 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT - col0 + col1 * tab2.col2 AS col2 FROM tab2
----
1456
567
830

query I rowsort
SELECT DISTINCT col0 - col0 * + col2 AS col0 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT - col0 * col2 - col2 * col0 AS col2 FROM tab0
----
-14596
-1584
-70

query I rowsort
SELECT DISTINCT + col0 - col0 * + col1 AS col0 FROM tab1
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-9393
SELECT DISTINCT - col0 + col2 DIV - col2 FROM tab0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-9393
SELECT DISTINCT - col0 + col2 / - col2 FROM tab0
----
-25
-36
-90

query I rowsort
SELECT DISTINCT - col0 * col0 + + col1 AS col2 FROM tab1
----
-4086
-6387
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-9395
SELECT DISTINCT + col2 * - col2 * col1 + col1 DIV col1 AS col0 FROM tab0
----
-611883
-93653
-96

skipif mysql # not compatible
query I rowsort label-9395
SELECT DISTINCT + col2 * - col2 * col1 + col1 / col1 AS col0 FROM tab0
----
-611883
-93653
-96

query I rowsort
SELECT col2 FROM tab1 WHERE NULL NOT BETWEEN + col2 / + col0 AND NULL
----

query I rowsort
SELECT - - col0 * + cor0.col0 + col0 * + col0 FROM tab1 AS cor0
----
12800
18
8192

query I rowsort
SELECT DISTINCT - col0 * ( tab2.col1 ) FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT col1 * ( + ( col2 ) ) + + col0 AS col0 FROM tab1
----
1328
1407
634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 + + cor0.col1 + - col1 col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - col0 * col1 + - col1 AS col0 FROM tab2 cor0
----
-1360
-248
-4661

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9402
SELECT + + CAST( 55 AS SIGNED ) * + cor0.col1 + col1 + 63 FROM tab0 AS cor0
----
4879
5159
5495

skipif mysql # not compatible
query I rowsort label-9402
SELECT + + CAST ( 55 AS INTEGER ) * + cor0.col1 + col1 + 63 FROM tab0 AS cor0
----
4879
5159
5495

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9403
SELECT - + CAST( NULL AS SIGNED ) * - col1 * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9403
SELECT - + CAST ( NULL AS INTEGER ) * - col1 * col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 94 * ( col0 * 80 ) FROM tab1 AS cor0
----
22560
481280
601600

onlyif mysql # use DIV operator for integer division
query I rowsort label-9405
SELECT + - 92 DIV - col2 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-9405
SELECT + - 92 / - col2 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT col2 + - 54 * - col2 AS col1 FROM tab2
----
1430
1485
2090

query I rowsort
SELECT - col0 * col2 * - 50 FROM tab0
----
1750
364900
39600

query I rowsort
SELECT - tab1.col0 * + tab1.col2 FROM tab1
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( + col1 ) col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL ( - col0 ) * 57 + col1 FROM tab0 AS cor0
----
-1282
-1898
-4982

query I rowsort
SELECT 57 + - col2 FROM tab1 AS cor0
----
-39
0
3

query I rowsort
SELECT ALL - col1 * cor0.col2 * + ( col1 ) FROM tab0 AS cor0
----
-244068
-679042
-9409

query I rowsort
SELECT + - col1 * col2 + - ( cor0.col1 ) FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT ALL - - 19 * col2 AS col0 FROM tab1 AS cor0
----
1026
1083
1824

query I rowsort
SELECT DISTINCT ( col0 ) * col2 + - col0 * col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - col1 * + col0 - col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT DISTINCT - - col2 + - cor0.col0 AS col1 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL - + cor0.col0 + + col0 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 42 * col1 col0 FROM tab1 AS cor0
----
1092
420
546

query I rowsort
SELECT + 93 + 71 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 73dfaab5bffad64399ffa17616b9603e

query I rowsort
SELECT - col1 * col1 + col0 AS col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT - - cor0.col0 + col2 * - 68 AS col0 FROM tab2 AS cor0
----
-1690
-1829
-2505

query I rowsort
SELECT col1 * - col2 - col0 FROM tab0 AS cor0
----
-132
-2862
-7551

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 - col1 col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT col1 + col1 * col2 - + col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + cor0.col0 - + cor0.col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT - col1 + - 86 + + col1 FROM tab2 AS cor0
----
-86
-86
-86

query I rowsort
SELECT + col2 * col1 + + col2 * cor0.col0 FROM tab1 AS cor0
----
1566
4218
8928

query I rowsort
SELECT col0 + + 42 AS col0 FROM tab0 AS cor0
----
131
66
77

query I rowsort
SELECT ALL + col0 * - col1 - - col0 FROM tab1 cor0
----
-576
-75
-960

query I rowsort
SELECT + col0 * - col1 + cor0.col2 * + col1 AS col0 FROM tab2 AS cor0
----
-3068
-697
620

query I rowsort
SELECT DISTINCT 80 AS col0 FROM tab2, tab1 AS cor0
----
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9433
SELECT DISTINCT col0 DIV - col2 - - col1 AS col2 FROM tab0 cor0
----
62
86
90

skipif mysql # not compatible
query I rowsort label-9433
SELECT DISTINCT col0 / - col2 - - col1 AS col2 FROM tab0 cor0
----
62
86
90

query I rowsort
SELECT cor0.col1 * col1 + - col2 AS col0 FROM tab2 AS cor0
----
251
3455
934

query I rowsort
SELECT DISTINCT - col0 * col1 * + col2 + - col1 - col0 AS col1 FROM tab1 AS cor0
----
-36554
-4241
-99933

query I rowsort
SELECT - col1 * 32 AS col1 FROM tab2 AS cor0
----
-1888
-544
-992

query I rowsort
SELECT - 90 + col0 * col2 FROM tab0 AS cor0
----
-55
702
7208

onlyif mysql # use DIV operator for integer division
query I rowsort label-9438
SELECT - col1 + + col0 DIV col2 col0 FROM tab1 AS cor0
----
-13
-26
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9438
SELECT - col1 + + col0 / col2 col0 FROM tab1 AS cor0
----
-13
-26
-9

query I rowsort
SELECT ALL + col2 * - 8 FROM tab1
----
-432
-456
-768

query I rowsort
SELECT + tab1.col1 - + col0 * col2 AS col0 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT ( + col1 * col2 ) - - col1 FROM tab2
----
1593
663
868

query I rowsort
SELECT tab0.col0 * + ( 6 ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to db0e4131803545a8cb9d5124a84d835a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 * - col1 col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT + col1 * cor0.col2 * - col1 AS col1 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT ALL + - col2 * + col1 + + 9 FROM tab2 AS cor0
----
-1525
-637
-828

query I rowsort
SELECT ALL - + col1 + - col0 AS col2 FROM tab2 cor0
----
-137
-38
-96

query I rowsort
SELECT - col1 + col2 * ( + 43 ) AS col2 FROM tab2 AS cor0
----
1059
1130
1617

query I rowsort
SELECT ALL 32 FROM tab2 cor0
----
32
32
32

query I rowsort
SELECT - - ( - cor0.col0 ) AS col2 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL + 83 + 50 * + col1 * 10 AS col2 FROM tab0
----
43083
45583
48583

query I rowsort
SELECT DISTINCT + col2 * col2 * col2 FROM tab0 cor0
----
1
35937
551368

query I rowsort
SELECT 1 * + col2 + 19 FROM tab1 AS cor0
----
115
73
76

query I rowsort
SELECT ALL + col0 + col0 + cor0.col2 AS col1 FROM tab0 AS cor0
----
260
71
81

query I rowsort
SELECT 5 * col1 + 25 AS col2 FROM tab0 AS cor0
----
455
480
510

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + col2 * + col1 col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL + 59 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT DISTINCT - col1 * col0 + col0 + - col1 AS col0 FROM tab2 AS cor0
----
-1281
-241
-4583

query I rowsort
SELECT ALL + + 97 - + col2 AS col0 FROM tab1 AS cor0
----
1
40
43

query I rowsort
SELECT col0 + + col2 * - cor0.col0 * - cor0.col0 FROM tab0 AS cor0
----
1260
19032
649611

onlyif mysql # use DIV operator for integer division
query I rowsort label-9460
SELECT ALL + col2 DIV - col2 AS col1 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9460
SELECT ALL + col2 / - col2 AS col1 FROM tab0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 73 col2 FROM tab2, tab2 AS cor0
----
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-9462
SELECT col0 - + col0 DIV - col0 col2 FROM tab1
----
4
65
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9462
SELECT col0 - + col0 / - col0 col2 FROM tab1
----
4
65
81

query I rowsort
SELECT - col2 + col1 - col0 AS col2 FROM tab0 cor0
----
-80
29
61

query I rowsort
SELECT + 59 AS col1 FROM tab1 cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 cor2
----
81 values hashing to 05f41d0d3fd0b5c29af79ab9209cab27

query I rowsort
SELECT DISTINCT 24 - 90 FROM tab2, tab0 AS cor0
----
-66

query I rowsort
SELECT ALL - col0 + - col1 * + col1 * tab1.col1 AS col2 FROM tab1
----
-1064
-17579
-2277

query I rowsort
SELECT ALL + col2 + + col0 * + col2 + + col2 * col1 AS col1 FROM tab0
----
133
14842
3663

query I rowsort
SELECT DISTINCT - 88 AS col0 FROM tab2 cor0
----
-88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9469
SELECT CAST( - 95 AS SIGNED ) * cor0.col2 * - ( - col1 ) + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-118573
-133406
-54160

skipif mysql # not compatible
query I rowsort label-9469
SELECT CAST ( - 95 AS INTEGER ) * cor0.col2 * - ( - col1 ) + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-118573
-133406
-54160

onlyif mysql # use DIV operator for integer division
query I rowsort label-9470
SELECT 49 * - cor0.col2 * + cor0.col1 + - col0 DIV - 1 FROM tab0 AS cor0
----
-139038
-365549
-4718

skipif mysql # not compatible
query I rowsort label-9470
SELECT 49 * - cor0.col2 * + cor0.col1 + - col0 / - 1 FROM tab0 AS cor0
----
-139038
-365549
-4718

query I rowsort
SELECT ALL - 78 AS col0 FROM tab2 AS cor0
----
-78
-78
-78

query I rowsort
SELECT DISTINCT - - col2 + - col1 AS col2 FROM tab2 AS cor0
----
-33
-4
21

query IIIIIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0, tab1 AS cor2
----
13122 values hashing to b173008d27e9b0938c4b0dd206da5d1b

query I rowsort
SELECT 40 * - col2 + tab0.col2 AS col1 FROM tab0
----
-1287
-3198
-39

query I rowsort
SELECT DISTINCT 4 * col2 + + col2 FROM tab0
----
165
410
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-9476
SELECT ALL - col1 * col0 DIV col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-9476
SELECT ALL - col1 * col0 / col0 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9477
SELECT ALL + - CAST( NULL AS SIGNED ) * - col2 + cor0.col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9477
SELECT ALL + - CAST ( NULL AS INTEGER ) * - col2 + cor0.col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 70 * + cor0.col0 + - col1 FROM tab1 cor0
----
184
4470
5587

query I rowsort
SELECT DISTINCT + col0 + + 77 AS col2 FROM tab1 AS cor0
----
141
157
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9480
SELECT + CAST( NULL AS SIGNED ) * cor0.col0 + - col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9480
SELECT + CAST ( NULL AS INTEGER ) * cor0.col0 + - col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 64 + col2 * + col2 FROM tab2 AS cor0
----
1508
740
793

query I rowsort
SELECT ALL + col0 + - col0 * 82 FROM tab2 cor0
----
-567
-6318
-6399

query I rowsort
SELECT + cor0.col1 * + col0 + + 50 * - 90 AS col1 FROM tab1 AS cor0
----
-3460
-3860
-4422

query I rowsort
SELECT ALL col2 + - col2 * - 90 AS col0 FROM tab0 AS cor0
----
3003
7462
91

query I rowsort
SELECT ALL col1 * col0 * 6 AS col0 FROM tab2
----
1302
27612
8058

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9486
SELECT ( col0 ) * CAST( 54 AS SIGNED ) AS col1 FROM tab0
----
1296
1890
4806

skipif mysql # not compatible
query I rowsort label-9486
SELECT ( col0 ) * CAST ( 54 AS INTEGER ) AS col1 FROM tab0
----
1296
1890
4806

query I rowsort
SELECT + + 86 * col1 + col2 FROM tab2 AS cor0
----
1500
2693
5100

onlyif mysql # use DIV operator for integer division
query I rowsort label-9488
SELECT cor0.col0 DIV + col0 + - 43 AS col0 FROM tab2 AS cor0
----
-42
-42
-42

skipif mysql # not compatible
query I rowsort label-9488
SELECT cor0.col0 / + col0 + - 43 AS col0 FROM tab2 AS cor0
----
-42
-42
-42

query I rowsort
SELECT + col0 * col0 + 38 FROM tab1 AS cor0
----
4134
47
6438

onlyif mysql # use DIV operator for integer division
query I rowsort label-9490
SELECT col2 DIV + col2 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-9490
SELECT col2 / + col2 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT ALL col2 * + col0 + + col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT 39 * - col2 + col0 FROM tab2 AS cor0
----
-1046
-1403
-936

onlyif mysql # use DIV operator for integer division
query I rowsort label-9493
SELECT - 30 DIV col0 AS col1 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-9493
SELECT - 30 / col0 AS col1 FROM tab0 AS cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9494
SELECT DISTINCT col1 * 0 DIV col1 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-9494
SELECT DISTINCT col1 * 0 / col1 FROM tab0 cor0
----
0

query I rowsort
SELECT + - ( + col2 ) - col1 * ( + col0 ) FROM tab1 cor0
----
-1136
-132
-697

onlyif mysql # use DIV operator for integer division
query I rowsort label-9496
SELECT col2 + 17 DIV col0 FROM tab1
----
57
59
96

skipif mysql # not compatible
query I rowsort label-9496
SELECT col2 + 17 / col0 FROM tab1
----
57
59
96

query I rowsort
SELECT - - col2 + 37 + - 21 AS col1 FROM tab0 AS cor0
----
17
49
98

query I rowsort
SELECT + - col0 * ( - col0 ) * col0 - col2 FROM tab0 AS cor0
----
13791
42874
704887

query I rowsort
SELECT - col2 + - ( + 66 ) FROM tab2 AS cor0
----
-104
-92
-93

query I rowsort
SELECT - + cor0.col1 * + col2 + - col0 AS col2 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT DISTINCT tab2.col2 + + col0 AS col2 FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-9502
SELECT DISTINCT + col0 DIV col1 + + 82 AS col2 FROM tab2
----
82
83
86

skipif mysql # not compatible
query I rowsort label-9502
SELECT DISTINCT + col0 / col1 + + 82 AS col2 FROM tab2
----
82
83
86

query I rowsort
SELECT ALL 92 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

query I rowsort
SELECT ALL - 92 + - tab0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 10497697aad25d6ff737fb5798e775d1

query I rowsort
SELECT - col2 + + col2 + - 53 FROM tab1
----
-53
-53
-53

query I rowsort
SELECT ALL col2 - - 43 * - 62 FROM tab0
----
-2584
-2633
-2665

query I rowsort
SELECT ALL 44 * - 68 FROM tab0
----
-2992
-2992
-2992

query I rowsort
SELECT DISTINCT + col2 * - col2 * + col1 FROM tab1
----
-119808
-32490
-75816

query I rowsort
SELECT ALL + ( + col1 ) * - col1 AS col0 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT ALL - - cor0.col0 + col0 AS col0 FROM tab1 AS cor0
----
128
160
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9511
SELECT cor0.col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab1, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9511
SELECT cor0.col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab1, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + + ( + col2 ) * + col0 * col1 AS col1 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT 53 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 866ae1b4ab9e5b4043ac1bcfd413aaa6

query I rowsort
SELECT col0 * - col1 - col2 * col2 FROM tab2
----
-2787
-5278
-946

query I rowsort
SELECT - + 58 + + cor0.col0 AS col1 FROM tab2 AS cor0
----
-51
20
21

query I rowsort
SELECT DISTINCT 37 + col2 FROM tab2 AS cor0
----
63
64
75

query I rowsort
SELECT DISTINCT - col0 + - ( col2 ) * + col2 FROM tab2 AS cor0
----
-1523
-736
-754

query I rowsort
SELECT DISTINCT + - col1 + col2 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT - - col2 * - 60 FROM tab2 AS cor0
----
-1560
-1620
-2280

query I rowsort
SELECT - col0 * + ( - cor0.col0 ) * col1 AS col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT ALL + col0 * 30 FROM tab2 AS cor0
----
210
2340
2370

onlyif mysql # use DIV operator for integer division
query I rowsort label-9522
SELECT col1 * 92 DIV col2 AS col0 FROM tab1 AS cor0
----
12
16
44

skipif mysql # not compatible
query I rowsort label-9522
SELECT col1 * 92 / col2 AS col0 FROM tab1 AS cor0
----
12
16
44

query I rowsort
SELECT - - col2 * + 23 + + ( - cor0.col0 ) * - col0 - cor0.col2 AS col2 FROM tab2 AS cor0
----
643
6656
7077

query I rowsort
SELECT - col2 + - 47 FROM tab2 AS cor0
----
-73
-74
-85

query I rowsort
SELECT DISTINCT + col1 + - col0 * - cor0.col1 AS col2 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL + col0 * - 46 AS col0 FROM tab2 cor0
----
-322
-3588
-3634

query I rowsort
SELECT - col2 + 72 FROM tab1 AS cor0
----
-24
15
18

query I rowsort
SELECT - - 12 + col2 AS col0 FROM tab1 cor0
----
108
66
69

query I rowsort
SELECT + col0 * 86 AS col1 FROM tab1
----
258
5504
6880

query I rowsort
SELECT - col0 * 31 + cor0.col2 FROM tab0 AS cor0
----
-1084
-2677
-711

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 1 * - 15 + + col0 col2 FROM tab2 AS cor0
----
22
93
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 91 col2 FROM tab1 AS cor0
----
91
91
91

query I rowsort
SELECT DISTINCT + + 84 AS col1 FROM tab1 cor0
----
84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9534
SELECT - CAST( NULL AS SIGNED ) + + col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9534
SELECT - CAST ( NULL AS INTEGER ) + + col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * - 60 FROM tab0 cor0
----
-1980
-4920
-60

skipif mysql # not compatible
query I rowsort
SELECT ALL - - col2 + - col1 * CAST ( col2 AS REAL ) AS col2 FROM tab1 AS cor0
----
-1152
-1350
-513

onlyif mysql # use DIV operator for integer division
query I rowsort label-9537
SELECT DISTINCT - col2 + cor0.col2 DIV col2 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-9537
SELECT DISTINCT - col2 + cor0.col2 / col2 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT DISTINCT + cor0.col0 + + cor0.col1 + 90 AS col2 FROM tab1 AS cor0
----
119
164
183

query I rowsort
SELECT ALL + col0 * 82 + col0 FROM tab2 AS cor0
----
581
6474
6557

query I rowsort
SELECT col0 - - col1 * col1 * - cor0.col0 FROM tab0 AS cor0
----
-177480
-329280
-736920

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9541
SELECT ALL + col1 + CAST( + cor0.col2 AS SIGNED ) * col0 AS col2 FROM tab1 AS cor0
----
188
3658
7693

skipif mysql # not compatible
query I rowsort label-9541
SELECT ALL + col1 + CAST ( + cor0.col2 AS INTEGER ) * col0 AS col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ALL + col1 * - 62 AS col0 FROM tab0 AS cor0
----
-5332
-5642
-6014

query I rowsort
SELECT + col2 + 32 FROM tab2 cor0
----
58
59
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-9544
SELECT - col2 DIV 30 + col1 FROM tab1 AS cor0
----
10
25
9

skipif mysql # not compatible
query I rowsort label-9544
SELECT - col2 / 30 + col1 FROM tab1 AS cor0
----
10
25
9

query I rowsort
SELECT - + col2 + - ( + col0 ) * - cor0.col0 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT - - cor0.col1 * col2 + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL - - col0 + 28 AS col0 FROM tab0 AS cor0
----
117
52
63

query I rowsort
SELECT ALL - cor0.col0 * - 98 + - col2 FROM tab1 AS cor0
----
240
6215
7744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 - col2 col0 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9550
SELECT - - col2 + + col2 DIV + col2 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-9550
SELECT - - col2 + + col2 / + col2 FROM tab0 AS cor0
----
2
34
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9551
SELECT DISTINCT + col0 * + CAST( 54 AS SIGNED ) * + col0 + - col2 * col1 * - col2 AS col1 FROM tab0 cor0
----
1039618
124758
66247

skipif mysql # not compatible
query I rowsort label-9551
SELECT DISTINCT + col0 * + CAST ( 54 AS INTEGER ) * + col0 + - col2 * col1 * - col2 AS col1 FROM tab0 cor0
----
1039618
124758
66247

query I rowsort
SELECT ALL - col2 + + 90 AS col2 FROM tab0 AS cor0
----
57
8
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-9553
SELECT ALL + + col2 + ( + 13 * - col2 ) + ( col0 ) DIV col1 AS col0 FROM tab1 AS cor0
----
-1146
-648
-678

skipif mysql # not compatible
query I rowsort label-9553
SELECT ALL + + col2 + ( + 13 * - col2 ) + ( col0 ) / col1 AS col0 FROM tab1 AS cor0
----
-1146
-648
-678

query I rowsort
SELECT ALL - 34 * col1 AS col1 FROM tab1 AS cor0
----
-340
-442
-884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 83 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

query I rowsort
SELECT DISTINCT - col2 + 75 FROM tab0
----
-7
42
74

query I rowsort
SELECT col1 + - 94 * + col2 AS col1 FROM tab1
----
-5050
-5348
-9011

query I rowsort
SELECT - + col1 + + col2 * + col0 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT DISTINCT + col1 + col0 * - col0 * ( + col1 + + col2 ) FROM tab0 AS cor0
----
-119953
-1370242
-68458

query I rowsort
SELECT DISTINCT 77 * ( - col0 ) AS col2 FROM tab2 AS cor0
----
-539
-6006
-6083

query I rowsort
SELECT DISTINCT - 8 * col1 + - col2 * + col1 * col0 FROM tab1 AS cor0
----
-36560
-4420
-99944

query I rowsort
SELECT ALL ( col2 ) + col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT - 92 * + 83 AS col2 FROM tab0, tab1 cor0
----
9 values hashing to 2660facff474fee412eeab4b3d7a9b58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + col2 * col2 * + col1 col0 FROM tab2
----
22592
24469
39806

query I rowsort
SELECT DISTINCT - 91 * col1 AS col2 FROM tab0 AS cor0
----
-7826
-8281
-8827

query I rowsort
SELECT DISTINCT + 9 * col0 + 47 AS col0 FROM tab2 AS cor0
----
110
749
758

query I rowsort
SELECT 8 + + col2 FROM tab0 AS cor0
----
41
9
90

query I rowsort
SELECT - col0 + col0 * + ( col1 ) * - col2 AS col0 FROM tab0 AS cor0
----
-3430
-664207
-68136

onlyif mysql # use DIV operator for integer division
query I rowsort label-9569
SELECT DISTINCT - + 22 + col2 DIV 69 AS col2 FROM tab2 AS cor0
----
-22

skipif mysql # not compatible
query I rowsort label-9569
SELECT DISTINCT - + 22 + col2 / 69 AS col2 FROM tab2 AS cor0
----
-22

query I rowsort
SELECT ALL 16 * col1 FROM tab1
----
160
208
416

query I rowsort
SELECT DISTINCT 15 * col1 - col0 AS col1 FROM tab1
----
115
387
86

query I rowsort
SELECT - 67 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 95c9eba643f6489e03be4d5e83f1ef99

query I rowsort
SELECT - col0 - + tab1.col0 FROM tab1
----
-128
-160
-6

query I rowsort
SELECT DISTINCT 40 - - col2 AS col2 FROM tab2
----
66
67
78

query I rowsort
SELECT - 81 - - col0 AS col2 FROM tab0
----
-46
-57
8

query I rowsort
SELECT ALL col0 + col0 * - col1 AS col1 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT ALL + ( 92 ) * cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d9f91b4f2fe0b891f0f8ae75454401ec

query I rowsort
SELECT ALL col0 + 53 AS col0 FROM tab1 AS cor0
----
117
133
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + 35 col0 FROM tab2 AS cor0
----
113
114
42

query I rowsort
SELECT DISTINCT - col2 * + cor0.col2 * - col0 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT DISTINCT - + col0 + + 61 * + col2 AS col0 FROM tab1 AS cor0
----
3291
3413
5776

query I rowsort
SELECT + - col0 + - col1 * - ( col2 ) * col1 AS col0 FROM tab2 AS cor0
----
10903
25940
90428

query I rowsort
SELECT DISTINCT - + 24 + + col1 AS col2 FROM tab1 AS cor0
----
-11
-14
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-9584
SELECT - + col1 DIV col2 + col0 AS col1 FROM tab0 AS cor0
----
-62
22
88

skipif mysql # not compatible
query I rowsort label-9584
SELECT - + col1 / col2 + col0 AS col1 FROM tab0 AS cor0
----
-62
22
88

query I rowsort
SELECT ALL + - ( col0 ) * col0 + col1 AS col0 FROM tab1 AS cor0
----
-4086
-6387
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + tab2.col2 col1 FROM tab2
----
-41
-52
20

query I rowsort
SELECT ALL + - 10 * - col0 + col1 * - col1 FROM tab2 cor0
----
-2701
-891
501

query I rowsort
SELECT ALL - + col1 + + col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + + 13 + - cor0.col1 FROM tab1 AS cor0
----
-13
0
3

query I rowsort
SELECT DISTINCT - col1 + col1 * cor0.col0 * cor0.col2 AS col0 FROM tab2 cor0
----
119593
51017
5828

query I rowsort
SELECT DISTINCT - + 88 + - col1 * col1 AS col0 FROM tab2 cor0
----
-1049
-3569
-377

query I rowsort
SELECT ALL - col2 * cor0.col0 * - col1 AS col2 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ALL + + col1 * col2 + + ( + cor0.col2 ) * + cor0.col1 FROM tab1 AS cor0
----
1140
2496
2808

onlyif mysql # use DIV operator for integer division
query I rowsort label-9594
SELECT ALL + 60 DIV col1 AS col1 FROM tab1 AS cor0
----
2
4
6

skipif mysql # not compatible
query I rowsort label-9594
SELECT ALL + 60 / col1 AS col1 FROM tab1 AS cor0
----
2
4
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-9595
SELECT 60 DIV col1 col0 FROM tab2 AS cor0
----
1
1
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9595
SELECT 60 / col1 col0 FROM tab2 AS cor0
----
1
1
3

query I rowsort
SELECT ALL ( + 3 + + col1 ) AS col2 FROM tab2
----
20
34
62

query I rowsort
SELECT DISTINCT col0 * col0 * + col2 FROM tab2 cor0
----
1323
158184
237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-9598
SELECT - col2 DIV - cor0.col2 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9598
SELECT - col2 / - cor0.col2 AS col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT 19 + + col0 AS col0 FROM tab1 AS cor0
----
22
83
99

query I rowsort
SELECT ALL + 5 FROM tab1, tab0 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

query I rowsort
SELECT col0 + col1 * cor0.col0 AS col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT - col1 + col2 * 25 FROM tab0 AS cor0
----
-72
1959
739

query I rowsort
SELECT ALL + col0 * col2 + + col2 * col0 AS col0 FROM tab2 AS cor0
----
378
4056
6004

query I rowsort
SELECT + ( - 5 ) AS col2 FROM tab0
----
-5
-5
-5

query I rowsort
SELECT + - col0 * + 30 AS col0 FROM tab2 AS cor0
----
-210
-2340
-2370

query I rowsort
SELECT - col0 * col1 + - col1 * + col0 FROM tab1
----
-1280
-156
-2080

query I rowsort
SELECT ALL 33 * - col0 AS col1 FROM tab0
----
-1155
-2937
-792

query I rowsort
SELECT ALL - 5 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 74665fbb47d5b17da011bca567195b21

query I rowsort
SELECT - col1 + + cor0.col0 * col2 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT DISTINCT + 25 FROM tab0, tab1 AS cor0, tab1, tab0 cor1
----
25

query IIIIIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0, tab0 AS cor2, tab0 AS cor3
----
13122 values hashing to 418cea23186d151f6761321f4bd1b716

query I rowsort
SELECT ALL col1 * 47 + col2 FROM tab2 AS cor0
----
1484
2799
837

query I rowsort
SELECT DISTINCT + col2 * + col1 + - 40 * + col2 - col1 AS col2 FROM tab2 AS cor0
----
-274
-891
435

query I rowsort
SELECT 59 * col1 AS col2 FROM tab2 AS cor0
----
1003
1829
3481

query I rowsort
SELECT DISTINCT - ( col0 ) + col1 * + ( col1 * - col1 ) AS col2 FROM tab1 AS cor0
----
-1064
-17579
-2277

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9616
SELECT ALL + col1 * CAST( col2 AS SIGNED ) FROM tab1
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-9616
SELECT ALL + col1 * CAST ( col2 AS INTEGER ) FROM tab1
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9617
SELECT col0 * - CAST( NULL AS SIGNED ) * + 42 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9617
SELECT col0 * - CAST ( NULL AS INTEGER ) * + 42 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + + col2 * - 63 + - col1 * col2 + + col2 * - col1 AS col2 FROM tab1 AS cor0
----
-4731
-6210
-8544

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9619
SELECT ALL col0 + + CAST( + 39 AS SIGNED ) * + col1 * col0 AS col2 FROM tab2
----
179556
52456
8470

skipif mysql # not compatible
query I rowsort label-9619
SELECT ALL col0 + + CAST ( + 39 AS INTEGER ) * + col1 * col0 AS col2 FROM tab2
----
179556
52456
8470

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + + col1 col0 FROM tab1
----
-28
-47
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9621
SELECT DISTINCT - col0 * + CAST( 51 AS SIGNED ) + + col2 + ( ( col2 ) + - ( col1 ) ) FROM tab0
----
-1244
-1880
-4466

skipif mysql # not compatible
query I rowsort label-9621
SELECT DISTINCT - col0 * + CAST ( 51 AS INTEGER ) + + col2 + ( ( col2 ) + - ( col1 ) ) FROM tab0
----
-1244
-1880
-4466

query I rowsort
SELECT DISTINCT - 41 - tab1.col1 AS col0 FROM tab1, tab1 cor0
----
-51
-54
-67

query I rowsort
SELECT 92 + - col0 * col1 FROM tab0 AS cor0
----
-1972
-3303
-8007

onlyif mysql # use DIV operator for integer division
query I rowsort label-9624
SELECT DISTINCT - col2 + - col1 DIV + col1 AS col0 FROM tab2 AS cor0
----
-27
-28
-39

skipif mysql # not compatible
query I rowsort label-9624
SELECT DISTINCT - col2 + - col1 / + col1 AS col0 FROM tab2 AS cor0
----
-27
-28
-39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 48 * + col0 col2 FROM tab1 AS cor0
----
-144
-3072
-3840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col1 * + cor0.col0 col1 FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT DISTINCT - ( + 56 ) FROM tab2 cor0
----
-56

query I rowsort
SELECT ALL + col1 + ( - col0 ) FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT + + 14 * - cor0.col1 * col1 AS col0 FROM tab2 AS cor0
----
-13454
-4046
-48734

query I rowsort
SELECT - - ( + cor0.col1 ) * - col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ( - col0 ) * col2 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT + 41 * - col1 + + ( + 19 ) + - col2 AS col1 FROM tab1 cor0
----
-1101
-448
-610

query I rowsort
SELECT 45 - - col1 * - col2 FROM tab0 AS cor0
----
-2793
-52
-7417

query I rowsort
SELECT - - col1 * ( col2 ) + + col2 * 27 AS col0 FROM tab2 AS cor0
----
1566
1672
2236

query I rowsort
SELECT + col0 + + cor0.col1 * + 15 * + col0 + col2 AS col0 FROM tab2 AS cor0
----
20262
3289
69134

query I rowsort
SELECT - - col2 * - col0 * + col1 + cor0.col1 * - cor0.col1 FROM tab1 AS cor0
----
-100009
-36580
-4888

query I rowsort
SELECT ALL + col2 * 21 FROM tab1 AS cor0
----
1134
1197
2016

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - col2 col2 FROM tab0
----
-9
34
7

query I rowsort
SELECT ( 83 ) + col2 * col2 FROM tab0
----
1172
6807
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-9640
SELECT col0 + tab0.col0 DIV col2 FROM tab0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-9640
SELECT col0 + tab0.col0 / col2 FROM tab0
----
24
70
90

query I rowsort
SELECT ALL col2 + col2 * col0 - col0 FROM tab2
----
1976
209
2961

query I rowsort
SELECT DISTINCT + 19 - col2 FROM tab2
----
-19
-7
-8

query I rowsort
SELECT + ( 52 * col2 ) + - col0 * col2 + - col1 * - col0 FROM tab2
----
1432
317
3926

query I rowsort
SELECT ALL - - col0 + + cor0.col2 * col2 * col1 AS col1 FROM tab0 AS cor0
----
132
611973
93678

query I rowsort
SELECT + 48 + col2 AS col1 FROM tab2 cor0
----
74
75
86

query I rowsort
SELECT ALL + + cor0.col0 + - col2 AS col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT + 38 * col1 AS col0 FROM tab0 AS cor0
----
3268
3458
3686

query I rowsort
SELECT col0 * - col0 * col1 + + col1 FROM tab0 AS cor0
----
-118728
-49450
-720720

query I rowsort
SELECT ALL - ( cor0.col0 ) AS col2 FROM tab1 cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9650
SELECT ALL + + cor0.col1 DIV - col2 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-9650
SELECT ALL + + cor0.col1 / - col2 FROM tab0 AS cor0
----
-1
-2
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + + col0 col2 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT 60 + - col2 * col2 AS col1 FROM tab2 AS cor0
----
-1384
-616
-669

query I rowsort
SELECT + + 85 * + col0 - + cor0.col1 AS col1 FROM tab2 AS cor0
----
564
6571
6698

query I rowsort
SELECT - col1 * col2 + col1 * + col0 AS col1 FROM tab0 AS cor0
----
-774
3298
637

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 19 * cor0.col0 - - col0 * col1 * col1 col1 FROM tab0 cor0
----
177960
329980
738700

query I rowsort
SELECT DISTINCT - - col0 * cor0.col2 AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - col1 * - col2 * - col0 AS col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-9658
SELECT ALL + - col1 DIV - col1 + col2 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-9658
SELECT ALL + - col1 / - col1 + col2 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT DISTINCT - col2 + + col1 * 28 * - col1 FROM tab1 AS cor0
----
-18982
-2857
-4828

query I rowsort
SELECT ALL cor0.col2 + + ( + col0 ) * + col2 * + col2 AS col1 FROM tab0 AS cor0
----
26169
36
598518

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL col0 + CAST ( - 17 + - col0 AS REAL ) col2 FROM tab2 AS cor0
----
-17
-17
-17

query I rowsort
SELECT DISTINCT - - cor0.col2 + 94 AS col1 FROM tab1 AS cor0
----
148
151
190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9663
SELECT ALL + + col1 * CAST( - col1 * + col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-16224
-36504
-5700

skipif mysql # not compatible
query I rowsort label-9663
SELECT ALL + + col1 * CAST ( - col1 * + col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT ALL col0 * - col1 * + 35 FROM tab2 cor0
----
-161070
-47005
-7595

onlyif mysql # use DIV operator for integer division
query I rowsort label-9665
SELECT DISTINCT - col2 * 18 DIV - cor0.col0 FROM tab2 AS cor0
----
6
69
8

skipif mysql # not compatible
query I rowsort label-9665
SELECT DISTINCT - col2 * 18 / - cor0.col0 FROM tab2 AS cor0
----
6
69
8

query I rowsort
SELECT DISTINCT - - col0 + 45 * cor0.col0 FROM tab0 cor0
----
1104
1610
4094

query I rowsort
SELECT - 94 + col1 * - col1 FROM tab2 AS cor0
----
-1055
-3575
-383

query I rowsort
SELECT ALL + 52 AS col1 FROM tab0 AS cor0
----
52
52
52

query I rowsort
SELECT DISTINCT - ( cor0.col1 ) * + col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT 28 + + tab0.col0 FROM tab0, tab0 cor0
----
9 values hashing to 27a91d9d2c7980948fd903ad56d735e5

query I rowsort
SELECT DISTINCT ( col1 ) + + col1 * col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT + cor0.col2 * - col1 + col1 + col1 AS col2 FROM tab0 AS cor0
----
-2666
-7280
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9673
SELECT ALL - col0 DIV col1 + col1 FROM tab1 AS cor0
----
26
4
7

skipif mysql # not compatible
query I rowsort label-9673
SELECT ALL - col0 / col1 + col1 FROM tab1 AS cor0
----
26
4
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9674
SELECT ALL - cor0.col1 DIV + col1 + col0 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-9674
SELECT ALL - cor0.col1 / + col1 + col0 FROM tab0 AS cor0
----
23
34
88

query I rowsort
SELECT ALL + + cor0.col1 * col0 + col2 AS col1 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-9676
SELECT - tab0.col0 DIV col2 + col1 AS col2 FROM tab0
----
62
86
90

skipif mysql # not compatible
query I rowsort label-9676
SELECT - tab0.col0 / col2 + col1 AS col2 FROM tab0
----
62
86
90

query I rowsort
SELECT + col2 * + col1 + col1 * col1 AS col2 FROM tab2
----
1798
5015
935

query I rowsort
SELECT DISTINCT col0 - cor0.col2 AS col1 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-9679
SELECT - col2 + - col2 DIV col1 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-9679
SELECT - col2 + - col2 / col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT col2 * - col1 + tab2.col0 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT - col0 + + cor0.col0 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + cor0.col2 * + col1 + col1 AS col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL + col1 - col2 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT - col0 + col1 * + cor0.col0 AS col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT + + col0 + col2 * - col0 FROM tab1 AS cor0
----
-159
-3584
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-9686
SELECT DISTINCT col2 * col0 + col1 DIV - col1 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
35
7379
824

skipif mysql # not compatible
query I rowsort label-9686
SELECT DISTINCT col2 * col0 + col1 / - col1 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
35
7379
824

query I rowsort
SELECT DISTINCT col0 + col1 * - col0 * + col1 AS col0 FROM tab1 AS cor0
----
-13440
-2025
-6336

query I rowsort
SELECT cor0.col0 - - tab0.col2 * 71 FROM tab0, tab0 AS cor0
----
9 values hashing to 0cdd031ef55b4f476f4456a54e2c909d

query I rowsort
SELECT DISTINCT - - 21 + - 50 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
-29

query I rowsort
SELECT + 34 * - col1 AS col2 FROM tab2
----
-1054
-2006
-578

onlyif mysql # use DIV operator for integer division
query I rowsort label-9691
SELECT + - cor0.col1 * col1 DIV 50 FROM tab2 AS cor0
----
-19
-5
-69

skipif mysql # not compatible
query I rowsort label-9691
SELECT + - cor0.col1 * col1 / 50 FROM tab2 AS cor0
----
-19
-5
-69

query I rowsort
SELECT + cor0.col0 * ( + col2 + col2 ) * + 2 FROM tab2 cor0
----
12008
756
8112

onlyif mysql # use DIV operator for integer division
query I rowsort label-9693
SELECT + col1 DIV - col0 AS col2 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-9693
SELECT + col1 / - col0 AS col2 FROM tab1 AS cor0
----
-8
0
0

query I rowsort
SELECT - 48 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 31c94943c073954e4ca20b170ab61f8c

query I rowsort
SELECT DISTINCT + 99 AS col2 FROM tab2, tab0 AS cor0
----
99

query I rowsort
SELECT DISTINCT 49 AS col1 FROM tab2, tab0 AS cor0
----
49

query I rowsort
SELECT DISTINCT - + cor0.col2 * 62 FROM tab0 AS cor0
----
-2046
-5084
-62

query I rowsort
SELECT col1 * - 47 FROM tab1 AS cor0
----
-1222
-470
-611

query I rowsort
SELECT - col2 * col2 - col2 AS col1 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT col2 * - col0 + col1 + ( 41 ) FROM tab1 AS cor0
----
-3597
-7626
-95

query I rowsort
SELECT + col1 * col0 + cor0.col1 FROM tab1 AS cor0
----
104
1053
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 75 + col1 col0 FROM tab2 AS cor0
----
-16
-44
-58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9703
SELECT DISTINCT + + cor0.col2 * - col0 * CAST( - col2 AS SIGNED ) - + col2 FROM tab1 AS cor0
----
207879
737184
8694

skipif mysql # not compatible
query I rowsort label-9703
SELECT DISTINCT + + cor0.col2 * - col0 * CAST ( - col2 AS INTEGER ) - + col2 FROM tab1 AS cor0
----
207879
737184
8694

query I rowsort
SELECT 14 * col2 * col2 AS col1 FROM tab2
----
10206
20216
9464

onlyif mysql # use DIV operator for integer division
query I rowsort label-9705
SELECT + col2 DIV cor0.col1 + + 18 + col2 FROM tab2 AS cor0
----
44
45
58

skipif mysql # not compatible
query I rowsort label-9705
SELECT + col2 / cor0.col1 + + 18 + col2 FROM tab2 AS cor0
----
44
45
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-9706
SELECT ( col0 ) DIV 30 + 34 * - col0 col0 FROM tab2 AS cor0
----
-238
-2650
-2684

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9706
SELECT ( col0 ) / 30 + 34 * - col0 col0 FROM tab2 AS cor0
----
-238
-2650
-2684

onlyif mysql # use DIV operator for integer division
query I rowsort label-9707
SELECT + 41 * col2 DIV + ( - col2 * + col0 ) + col2 col0 FROM tab1 AS cor0
----
41
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9707
SELECT + 41 * col2 / + ( - col2 * + col0 ) + col2 col0 FROM tab1 AS cor0
----
41
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 77 col2 FROM tab1, tab2 cor0
----
9 values hashing to 3a24155cb91ceff1e67bb51c07b72107

query I rowsort
SELECT - ( - tab0.col0 ) * + col2 AS col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT - 64 AS col2 FROM tab2, tab1, tab2 AS cor0
----
-64

query I rowsort
SELECT ALL 39 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT - 6 * col1 AS col0 FROM tab0
----
-516
-546
-582

query I rowsort
SELECT + col2 * col0 * + col2 AS col2 FROM tab2
----
114076
5103
52728

query I rowsort
SELECT DISTINCT - 6 AS col0 FROM tab2, tab0 AS cor0
----
-6

query I rowsort
SELECT ALL - 82 - col1 * col0 FROM tab1 AS cor0
----
-1122
-160
-722

query I rowsort
SELECT DISTINCT - col0 * - col1 + + ( cor0.col2 ) FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-9717
SELECT + - col2 + + cor0.col1 DIV - ( col2 ) AS col1 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-9717
SELECT + - col2 + + cor0.col1 / - ( col2 ) AS col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - + 13 * + col0 FROM tab1 AS cor0
----
-1040
-39
-832

query I rowsort
SELECT DISTINCT 72 * - col2 * + ( col2 ) + - col0 * - col2 * - col1 + col2 AS col0 FROM tab0 cor0
----
-1148164
-146487
-3466

query I rowsort
SELECT - col1 + - col1 * ( col2 + - col2 ) FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - + col2 * - col2 + + col1 * col1 AS col0 FROM tab2 AS cor0
----
1690
1733
4157

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 13 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9723
SELECT col2 - - col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9723
SELECT col2 - - col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * cor0.col0 + + col2 AS col0 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT + + col2 + - 11 FROM tab1 AS cor0
----
43
46
85

query I rowsort
SELECT ALL + 83 + - col0 * + ( col0 ) AS col1 FROM tab2
----
-6001
-6158
34

query I rowsort
SELECT + 43 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

query I rowsort
SELECT ALL - col2 + col0 * ( - col0 ) AS col1 FROM tab2
----
-6110
-6279
-76

query I rowsort
SELECT ( - 46 ) * col2 * - col1 - col2 * col2 AS col0 FROM tab0 cor0
----
129459
336528
4461

query I rowsort
SELECT DISTINCT - ( + 45 ) * col1 FROM tab2 AS cor0
----
-1395
-2655
-765

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * - col2 col2 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( + col0 ) col1 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT - ( col0 ) * cor0.col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + + 84 + col0 FROM tab1 AS cor0
----
148
164
87

query I rowsort
SELECT - col2 + 25 * + 85 * + col2 AS col2 FROM tab1
----
114696
121068
203904

query I rowsort
SELECT ALL - col2 * ( tab0.col0 + col0 * 96 ) FROM tab0
----
-3395
-707906
-76824

query I rowsort
SELECT ALL 20 - + col2 * - col1 AS col0 FROM tab1
----
1268
1424
590

query I rowsort
SELECT - cor0.col0 - 4 AS col0 FROM tab0 AS cor0
----
-28
-39
-93

query I rowsort
SELECT ALL col0 + col1 + cor0.col0 FROM tab1 AS cor0
----
138
173
32

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9740
SELECT ALL + CAST( NULL AS SIGNED ) * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9740
SELECT ALL + CAST ( NULL AS INTEGER ) * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9741
SELECT + 1 * + 90 DIV - col0 - + col2 * 7 FROM tab0 AS cor0
----
-234
-575
-9

skipif mysql # not compatible
query I rowsort label-9741
SELECT + 1 * + 90 / - col0 - + col2 * 7 FROM tab0 AS cor0
----
-234
-575
-9

query I rowsort
SELECT - cor0.col0 * 47 FROM tab1 AS cor0
----
-141
-3008
-3760

query I rowsort
SELECT 94 + + col0 FROM tab1 AS cor0
----
158
174
97

query I rowsort
SELECT - col2 * - 13 + col1 FROM tab0
----
110
1157
515

query I rowsort
SELECT ( 4 ) * - cor0.col2 FROM tab2 AS cor0
----
-104
-108
-152

query I rowsort
SELECT ALL - + 80 + + col2 AS col1 FROM tab2 cor0
----
-42
-53
-54

query I rowsort
SELECT DISTINCT col1 * 28 FROM tab1
----
280
364
728

query I rowsort
SELECT col2 + col2 * 67 FROM tab0
----
2244
5576
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9749
SELECT col2 - - CAST( NULL AS SIGNED ) * + col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9749
SELECT col2 - - CAST ( NULL AS INTEGER ) * + col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * 48 AS col0 FROM tab0
----
1152
1680
4272

query I rowsort
SELECT ALL - + col2 + col0 * - col0 * 31 + + col0 FROM tab0 AS cor0
----
-17865
-245544
-37941

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col1 + cor0.col1 col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT col0 * 60 AS col2 FROM tab0 cor0
----
1440
2100
5340

query I rowsort
SELECT ALL 57 * + col1 * col0 + + col1 FROM tab1 AS cor0
----
36490
4472
59293

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9755
SELECT - + CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9755
SELECT - + CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 67 + col1 * col2 AS col0 FROM tab2 AS cor0
----
1601
713
904

query I rowsort
SELECT DISTINCT 85 + 15 * col2 * col0 AS col1 FROM tab0 AS cor0
----
109555
11965
610

query I rowsort
SELECT ALL - + 11 - 31 FROM tab0 AS cor0
----
-42
-42
-42

query I rowsort
SELECT col2 * 96 FROM tab1 AS cor0
----
5184
5472
9216

query I rowsort
SELECT - + ( - col1 ) * col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT - ( - 78 ) - + col2 FROM tab1 AS cor0
----
-18
21
24

query I rowsort
SELECT - 0 + - col1 * - 52 AS col0 FROM tab2
----
1612
3068
884

query I rowsort
SELECT + cor0.col1 * - col2 + - col2 * - 71 AS col2 FROM tab2 AS cor0
----
1080
2052
312

query I rowsort
SELECT + 2 + cor0.col1 + ( + col1 ) FROM tab0 AS cor0
----
174
184
196

query I rowsort
SELECT ALL + cor0.col1 * - col2 * 75 AS col1 FROM tab2 cor0
----
-115050
-48450
-62775

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col2 + cor0.col0 col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT col0 * col2 + + 8 * 89 AS col1 FROM tab2
----
2740
3714
901

onlyif mysql # use DIV operator for integer division
query I rowsort label-9768
SELECT col0 * col1 DIV cor0.col1 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-9768
SELECT col0 * col1 / cor0.col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ALL - + col0 * - ( + col0 ) FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + + cor0.col0 * 34 AS col1 FROM tab0 AS cor0
----
1190
3026
816

query I rowsort
SELECT DISTINCT - col1 + col0 + cor0.col1 * - col1 AS col2 FROM tab2 AS cor0
----
-227
-3462
-985

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9772
SELECT ALL - + col0 * - CAST( NULL AS SIGNED ) + + ( - col2 ) 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-9772
SELECT ALL - + col0 * - CAST ( NULL AS INTEGER ) + + ( - col2 ) col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 * 35 FROM tab1 cor0
----
105
2240
2800

query I rowsort
SELECT DISTINCT 84 AS col0 FROM tab0, tab1 AS cor0
----
84

query I rowsort
SELECT cor0.col0 * 68 + - cor0.col2 * cor0.col1 + col0 AS col2 FROM tab2 AS cor0
----
-354
3848
4805

query I rowsort
SELECT + - col2 + 33 * + 28 + col0 FROM tab1 AS cor0
----
873
908
931

query I rowsort
SELECT ALL 3 FROM tab0, tab1 cor0, tab2, tab1 AS cor1
----
81 values hashing to c7bd37716aa9c76e684a54f53d1ee343

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9778
SELECT ALL - col2 + + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9778
SELECT ALL - col2 + + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + + 11 * + col0 FROM tab2 AS cor0
----
104
884
907

query I rowsort
SELECT col1 + col1 * 37 * + col0 FROM tab1 cor0
----
23690
2912
38493

query I rowsort
SELECT ALL cor0.col2 + 16 * + col1 FROM tab1 AS cor0
----
217
304
470

query I rowsort
SELECT - + col0 * + cor0.col0 + + col1 AS col0 FROM tab2 AS cor0
----
-18
-6025
-6224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + + col0 + - col1 * cor0.col2 col0 FROM tab2 AS cor0
----
-1397
-550
-799

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9784
SELECT DISTINCT + + cor0.col0 * + CAST( - col0 AS SIGNED ) col2 FROM tab2 AS cor0
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9784
SELECT DISTINCT + + cor0.col0 * + CAST ( - col0 AS INTEGER ) col2 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL col1 + cor0.col2 * + col2 * col0 FROM tab1 AS cor0
----
207946
737293
8774

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9786
SELECT - cor0.col1 * CAST( NULL AS SIGNED ) * col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9786
SELECT - cor0.col1 * 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 + ( col2 ) + cor0.col2 * ( + col0 ) * col1 + cor0.col2 col1 FROM tab2 AS cor0
----
119704
51110
5913

query IIIIIIIIIIII rowsort
SELECT * FROM tab1 cor0 CROSS JOIN tab2, tab2 AS cor1, tab1 cor2
----
972 values hashing to 980274175fafec015a83080672486a9a

query I rowsort
SELECT DISTINCT + + 37 + - col0 + 79 * col2 * cor0.col1 FROM tab0 AS cor0
----
224215
589446
7665

query I rowsort
SELECT + ( col0 ) + col1 AS col1 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-9791
SELECT ALL + ( col0 ) DIV + 81 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9791
SELECT ALL + ( col0 ) / + 81 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + - cor0.col1 + col0 * + col2 FROM tab0 AS cor0
----
-62
706
7207

onlyif mysql # use DIV operator for integer division
query I rowsort label-9793
SELECT DISTINCT + col1 * + col0 * 80 + + ( + col0 ) DIV cor0.col0 AS col0 FROM tab1 cor0
----
51201
6241
83201

skipif mysql # not compatible
query I rowsort label-9793
SELECT DISTINCT + col1 * + col0 * 80 + + ( + col0 ) / cor0.col0 AS col0 FROM tab1 cor0
----
51201
6241
83201

query I rowsort
SELECT - 11 + + col1 FROM tab0 AS cor0
----
75
80
86

query I rowsort
SELECT + col1 * col2 + + col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT ALL + ( + col2 ) + - tab1.col1 FROM tab1
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 col0 FROM tab2, tab1, tab2 AS cor0
----
-26
-27
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9798
SELECT ALL col1 * - col0 + CAST( NULL AS SIGNED ) + col0 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9798
SELECT ALL col1 * - col0 + CAST ( NULL AS INTEGER ) + col0 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - ( + 94 * cor0.col2 ) col1 FROM tab2 AS cor0
----
-2385
-2507
-3555

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 27 + - 89 col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d2579f9395350eda865ff3a2d38a74f6

query I rowsort
SELECT DISTINCT + + col2 * col0 + col0 * 25 AS col0 FROM tab1 cor0
----
237
5248
9680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9802
SELECT ALL col2 + - col1 * CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9802
SELECT ALL col2 + - col1 * CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT col0 + + col0 * - col1 * col0 AS col1 FROM tab1
----
-231
-40896
-83120

query I rowsort
SELECT + tab2.col0 + col2 * + col1 * + col1 FROM tab2
----
11061
25954
90584

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE col2 = ( NULL )
----

query I rowsort
SELECT DISTINCT - 45 + col2 * 63 FROM tab2 cor0
----
1593
1656
2349

query I rowsort
SELECT + col2 * col1 - + col1 AS col1 FROM tab1
----
1235
1378
560

query I rowsort
SELECT - + 36 * col0 * 73 AS col1 FROM tab2 AS cor0
----
-18396
-204984
-207612

query I rowsort
SELECT DISTINCT + col1 - - col1 AS col2 FROM tab2
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-9810
SELECT col1 * col1 DIV - tab2.col0 AS col0 FROM tab2
----
-137
-3
-44

skipif mysql # not compatible
query I rowsort label-9810
SELECT col1 * col1 / - tab2.col0 AS col0 FROM tab2
----
-137
-3
-44

query I rowsort
SELECT col1 * - col0 + + col2 FROM tab2
----
-1305
-190
-4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + tab0.col0 + 60 col1 FROM tab0
----
117
231
96

query I rowsort
SELECT + col1 * cor0.col2 + + col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT - tab1.col0 - col1 AS col1 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT - col2 + col0 * tab0.col2 FROM tab0
----
34
7216
759

query I rowsort
SELECT ALL col0 * cor0.col1 AS col2 FROM tab1 AS cor0 WHERE col2 IN ( - col1 + col0 * cor0.col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + col1 - col1 col0 FROM tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col1 * col1 col2 FROM tab0
----
7482
8372
9506

query I rowsort
SELECT ALL col1 + col0 - col0 AS col0 FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-9820
SELECT DISTINCT col1 * tab2.col2 DIV col0 FROM tab2
----
119
19
8

skipif mysql # not compatible
query I rowsort label-9820
SELECT DISTINCT col1 * tab2.col2 / col0 FROM tab2
----
119
19
8

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) IN ( col1 * tab1.col2 )
----

query I rowsort
SELECT DISTINCT col0 * + col2 FROM tab1 WHERE col2 + + col2 + col0 NOT IN ( + col0 )
----
162
3648
7680

query I rowsort
SELECT DISTINCT + col2 * - tab0.col1 AS col0 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT tab1.col1 + col0 * col2 AS col1 FROM tab1
----
188
3658
7693

query I rowsort
SELECT ALL col0 * col2 + col0 * col1 + - col2 FROM tab0
----
15315
2823
3429

query III rowsort
SELECT ALL * FROM tab0 WHERE + col0 * col1 + - col1 / col2 BETWEEN ( - col0 ) AND + col2 - + col1
----

query I rowsort
SELECT + col2 * - col0 * + col1 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT ALL - col2 * col2 * - col0 AS col0 FROM tab1
----
207936
737280
8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-9829
SELECT tab1.col1 * + col0 + - col0 DIV col2 FROM tab1
----
1040
639
78

skipif mysql # not compatible
query I rowsort label-9829
SELECT tab1.col1 * + col0 + - col0 / col2 FROM tab1
----
1040
639
78

query I rowsort
SELECT DISTINCT - + col2 * - col2 + col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT DISTINCT col1 + ( - col1 ) FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9832
SELECT DISTINCT col1 DIV col0 + + col2 FROM tab1 AS cor0
----
57
62
96

skipif mysql # not compatible
query I rowsort label-9832
SELECT DISTINCT col1 / col0 + + col2 FROM tab1 AS cor0
----
57
62
96

query I rowsort
SELECT ALL + + col0 + + 38 AS col2 FROM tab2 AS cor0
----
116
117
45

query I rowsort
SELECT ALL cor0.col2 + + 74 AS col2 FROM tab2 cor0
----
100
101
112

onlyif mysql # use DIV operator for integer division
query I rowsort label-9835
SELECT ALL col0 + + col1 * 74 DIV - 13 + col0 FROM tab1 AS cor0
----
-142
72
86

skipif mysql # not compatible
query I rowsort label-9835
SELECT ALL col0 + + col1 * 74 / - 13 + col0 FROM tab1 AS cor0
----
-142
72
86

query I rowsort
SELECT - - ( cor0.col0 ) * - col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL 30 + cor0.col2 AS col1 FROM tab2 AS cor0
----
56
57
68

query I rowsort
SELECT ALL + 28 FROM tab2 cor0
----
28
28
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-9839
SELECT + col0 + col1 + + 3 DIV - 81 FROM tab1 AS cor0
----
29
74
93

skipif mysql # not compatible
query I rowsort label-9839
SELECT + col0 + col1 + + 3 / - 81 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - 16 + cor0.col2 AS col0 FROM tab1 AS cor0
----
38
41
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - col0 + col2 * 18 col2 FROM tab2 AS cor0
----
2027
5070
703

onlyif mysql # use DIV operator for integer division
query I rowsort label-9842
SELECT + cor0.col0 DIV col1 + - CAST( 53 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-53
-53
-53

skipif mysql # not compatible
query I rowsort label-9842
SELECT + cor0.col0 / col1 + - CAST ( 53 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-53
-53
-53

onlyif mysql # use DIV operator for integer division
query I rowsort label-9843
SELECT ALL + col1 DIV col0 + + col1 DIV - 99 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-9843
SELECT ALL + col1 / col0 + + col1 / - 99 FROM tab0 AS cor0
----
1
2
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9844
SELECT ALL CAST( + col0 AS SIGNED ) - - col2 FROM tab0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-9844
SELECT ALL CAST ( + col0 AS INTEGER ) - - col2 FROM tab0
----
171
36
57

query I rowsort
SELECT - ( col0 * + tab2.col1 ) FROM tab2
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9846
SELECT DISTINCT + CAST( NULL AS SIGNED ) * 71 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-9846
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * 71 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - col1 ) - tab0.col1 col0 FROM tab0
----
-172
-182
-194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9848
SELECT + - col0 * + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9848
SELECT + - col0 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + col2 * - ( cor0.col0 ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - - cor0.col1 + 92 * col0 * + cor0.col1 - - ( + col0 ) * - col0 * - ( + col2 ) AS col1 FROM tab0 cor0
----
1394721
208982
313662

query I rowsort
SELECT ALL - col1 * ( col2 * + col0 ) + - 6 * - 32 AS col1 FROM tab0 AS cor0
----
-3203
-663926
-67920

query I rowsort
SELECT - col1 * 16 AS col0 FROM tab0 AS cor0
----
-1376
-1456
-1552

query I rowsort
SELECT + col1 * ( - ( col1 ) ) FROM tab1 AS cor0
----
-100
-169
-676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9854
SELECT DISTINCT - col0 * CAST( NULL AS SIGNED ) col2 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9854
SELECT DISTINCT - col0 * CAST ( NULL AS INTEGER ) col2 FROM tab0
----
NULL

query I rowsort
SELECT + 43 * - 28 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 6378b28fed223abf4cd768b3d5681fb1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + + col1 col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT + - ( + col1 ) AS col1 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT ALL - 30 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to a96370a8187089b6b83ce9bfbade5142

onlyif mysql # use DIV operator for integer division
query I rowsort label-9859
SELECT ALL - 91 + cor0.col1 DIV - col2 FROM tab0 AS cor0
----
-188
-92
-93

skipif mysql # not compatible
query I rowsort label-9859
SELECT ALL - 91 + cor0.col1 / - col2 FROM tab0 AS cor0
----
-188
-92
-93

query I rowsort
SELECT DISTINCT + col1 + col0 * + col2 * - col0 FROM tab0 AS cor0
----
-1128
-18922
-649431

query I rowsort
SELECT DISTINCT cor0.col1 * col2 + 90 FROM tab1 cor0
----
1338
1494
660

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col1 col0 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT ALL - 26 * + col1 - 51 AS col1 FROM tab2 AS cor0
----
-1585
-493
-857

query I rowsort
SELECT ALL + col2 + - col1 + ( - col0 ) AS col2 FROM tab2 AS cor0
----
-11
-111
-58

query I rowsort
SELECT + + cor0.col1 * cor0.col2 * 80 AS col0 FROM tab2 cor0
----
122720
51680
66960

query I rowsort
SELECT col1 * + ( col2 ) AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT 66 AS col2 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 897b6122ac98340b78905f39d81897fc

query I rowsort
SELECT DISTINCT 99 * col1 FROM tab2
----
1683
3069
5841

query I rowsort
SELECT ALL + ( - cor0.col2 ) * cor0.col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - 85 * 78 + col0 * - 8 * 99 AS col2 FROM tab2 AS cor0
----
-12174
-68406
-69198

query I rowsort
SELECT 54 * - 58 FROM tab1 cor0
----
-3132
-3132
-3132

query I rowsort
SELECT + cor0.col2 * col1 + col2 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9873
SELECT ALL CAST( ( col1 ) AS SIGNED ) FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-9873
SELECT ALL CAST ( ( col1 ) AS INTEGER ) FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT DISTINCT ( 8 ) * - col0 AS col1 FROM tab1 AS cor0
----
-24
-512
-640

query I rowsort
SELECT DISTINCT cor0.col0 + - cor0.col1 * + col1 - - col1 FROM tab1 AS cor0
----
-26
-647
-76

query I rowsort
SELECT + 80 * col2 - col1 FROM tab2 AS cor0
----
2021
2129
3023

query I rowsort
SELECT DISTINCT + 68 * col0 - col1 AS col1 FROM tab2 AS cor0
----
445
5245
5355

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9878
SELECT - - CAST( NULL AS SIGNED ) + - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9878
SELECT - - CAST ( NULL AS INTEGER ) + - col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col0 + + cor0.col0 * + col1 + col0 * 63 * col2 FROM tab2 AS cor0
----
12131
132444
190548

onlyif mysql # use DIV operator for integer division
query I rowsort label-9880
SELECT DISTINCT + 63 DIV - col0 - - col0 AS col1 FROM tab1 AS cor0
----
-18
64
80

skipif mysql # not compatible
query I rowsort label-9880
SELECT DISTINCT + 63 / - col0 - - col0 AS col1 FROM tab1 AS cor0
----
-18
64
80

query I rowsort
SELECT col0 + col1 + + 54 AS col0 FROM tab2
----
150
191
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9882
SELECT DISTINCT + col1 - CAST( NULL AS SIGNED ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-9882
SELECT DISTINCT + col1 - CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

query I rowsort
SELECT col0 + 28 - - col0 AS col2 FROM tab2
----
184
186
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 75 col2 FROM tab0
----
75
75
75

query I rowsort
SELECT DISTINCT - 38 + 84 AS col1 FROM tab2 AS cor0
----
46

query I rowsort
SELECT ALL - 38 + - 54 * col1 AS col1 FROM tab2 AS cor0
----
-1712
-3224
-956

query I rowsort
SELECT - - cor0.col1 * - cor0.col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT 5 FROM tab0, tab0 cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

onlyif mysql # use DIV operator for integer division
query I rowsort label-9889
SELECT + cor0.col0 DIV - cor0.col0 + - col0 FROM tab2 AS cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-9889
SELECT + cor0.col0 / - cor0.col0 + - col0 FROM tab2 AS cor0
----
-79
-8
-80

query I rowsort
SELECT ALL - ( ( + col0 ) ) + + col2 * - col1 * col1 FROM tab1
----
-16304
-36507
-5764

query I rowsort
SELECT ALL + col2 + + col2 + - col1 FROM tab1
----
104
179
82

query I rowsort
SELECT + 49 + col0 * - col0 AS col1 FROM tab1 AS cor0
----
-4047
-6351
40

query I rowsort
SELECT + col1 + cor0.col0 * + 41 * 27 FROM tab1 AS cor0
----
3347
70858
88573

query I rowsort
SELECT 60 - col2 * col1 FROM tab2 cor0
----
-1474
-586
-777

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 3 * col0 col2 FROM tab1
----
192
240
9

query I rowsort
SELECT 36 * - tab1.col1 AS col1 FROM tab1
----
-360
-468
-936

query I rowsort
SELECT - col1 * + col2 - col2 * col1 FROM tab2 cor0
----
-1292
-1674
-3068

query I rowsort
SELECT - 38 + + col1 FROM tab0 AS cor0
----
48
53
59

query I rowsort
SELECT 63 + - col2 AS col1 FROM tab1 AS cor0
----
-33
6
9

query I rowsort
SELECT col2 + + col2 * 39 FROM tab0 cor0
----
1320
3280
40

query I rowsort
SELECT + 61 * + col2 + - col1 AS col1 FROM tab1 AS cor0
----
3268
3467
5843

query I rowsort
SELECT ALL + 55 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9903
SELECT DISTINCT tab0.col0 DIV col0 col2 FROM tab0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9903
SELECT DISTINCT tab0.col0 / col0 col2 FROM tab0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9904
SELECT + + col2 DIV col0 AS col1 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-9904
SELECT + + col2 / col0 AS col1 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT col0 * ( col1 ) * - col1 AS col1 FROM tab0 cor0
----
-177504
-329315
-737009

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9906
SELECT + col1 * CAST( NULL AS DECIMAL ) * + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9906
SELECT + col1 * CAST ( NULL AS REAL ) * + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 * 63 AS col1 FROM tab0 AS cor0
----
-1512
-2205
-5607

query I rowsort
SELECT ALL + + col0 * - 8 FROM tab0 AS cor0
----
-192
-280
-712

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9909
SELECT DISTINCT - col0 + CAST( + col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-9909
SELECT DISTINCT - col0 + CAST ( + col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT col1 + - col0 * + col1 AS col0 FROM tab2 cor0
----
-1326
-186
-4543

query I rowsort
SELECT + 8 * + col1 AS col1 FROM tab2 AS cor0
----
136
248
472

query I rowsort
SELECT - 59 * + col0 FROM tab0 AS cor0
----
-1416
-2065
-5251

query I rowsort
SELECT col2 * + 73 * col0 AS col2 FROM tab1 AS cor0
----
11826
266304
560640

query I rowsort
SELECT + col2 - 42 FROM tab2 AS cor0
----
-15
-16
-4

query I rowsort
SELECT - col1 * - 77 FROM tab2 AS cor0
----
1309
2387
4543

query I rowsort
SELECT + col0 + col2 * - 44 AS col2 FROM tab2 AS cor0
----
-1066
-1181
-1593

onlyif mysql # use DIV operator for integer division
query I rowsort label-9917
SELECT + - col2 DIV + CAST( - col0 AS SIGNED ) + + col2 col1 FROM tab0 AS cor0
----
1
34
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9917
SELECT + - col2 / + CAST ( - col0 AS INTEGER ) + + col2 col1 FROM tab0 AS cor0
----
1
34
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-9918
SELECT - 0 DIV + col0 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9918
SELECT - 0 / + col0 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9919
SELECT - col2 + - CAST( col1 + - col2 AS SIGNED ) AS col2 FROM tab1 cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-9919
SELECT - col2 + - CAST ( col1 + - col2 AS INTEGER ) AS col2 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT ALL + - col1 * col2 + cor0.col0 * cor0.col2 AS col0 FROM tab2 AS cor0
----
-648
2356
494

query I rowsort
SELECT DISTINCT - + col0 * + col0 - + col1 * col0 * - col1 FROM tab0 AS cor0
----
176928
328090
729088

query I rowsort
SELECT DISTINCT - col1 * - col2 * col1 FROM tab0 AS cor0
----
244068
679042
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9923
SELECT ALL - col2 * - CAST( NULL AS SIGNED ) / - cor0.col2 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9923
SELECT ALL - col2 * - CAST ( NULL AS INTEGER ) / - cor0.col2 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 76 + + 16 * + col1 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
-21564
-3548
-73708

query I rowsort
SELECT ALL - col1 * - 43 FROM tab0 AS cor0
----
3698
3913
4171

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9926
SELECT DISTINCT CAST( NULL AS SIGNED ) + - col1 + col2 * 89 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9926
SELECT DISTINCT CAST ( NULL AS INTEGER ) + - col1 + col2 * 89 AS col1 FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9927
SELECT col2 * - CAST( NULL AS SIGNED ) - col2 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9927
SELECT col2 * - CAST ( NULL AS INTEGER ) - col2 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * ( 82 ) + + col2 * - 52 AS col0 FROM tab0 AS cor0
----
252
2818
3034

query I rowsort
SELECT ALL col2 - ( col2 * col1 + - 73 ) AS col1 FROM tab0
----
-23
-2732
-7307

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9930
SELECT - CAST( NULL AS SIGNED ) col2 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9930
SELECT - CAST ( NULL AS INTEGER ) col2 FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) + - 83 col1 FROM tab0 AS cor0
----
-1
-50
-82

query I rowsort
SELECT - ( - col2 * + col2 ) AS col2 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT - 13 AS col0 FROM tab2, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 1c6aaa07ba8d3dc01ee616e16bef60f2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + col2 col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - + 74 AS col0 FROM tab1, tab2, tab1 AS cor0
----
-74

onlyif mysql # use DIV operator for integer division
query I rowsort label-9936
SELECT + col2 - + col2 DIV + ( - 64 * col0 ) FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-9936
SELECT + col2 - + col2 / + ( - 64 * col0 ) FROM tab2
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 81 col1 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
81

query I rowsort
SELECT + 57 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to 220a93709e207779b34ef74b544764a5

query I rowsort
SELECT col1 + col2 * 61 AS col2 FROM tab2 AS cor0
----
1645
1678
2335

onlyif mysql # use DIV operator for integer division
query I rowsort label-9940
SELECT ALL col2 DIV col2 col0 FROM tab1
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9940
SELECT ALL col2 / col2 col0 FROM tab1
----
1
1
1

query I rowsort
SELECT + cor0.col2 * + cor0.col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT col2 * - ( + 43 ) AS col0 FROM tab0 AS cor0
----
-1419
-3526
-43

onlyif mysql # use DIV operator for integer division
query I rowsort label-9943
SELECT DISTINCT col2 + 15 DIV cor0.col0 FROM tab1 AS cor0
----
57
59
96

skipif mysql # not compatible
query I rowsort label-9943
SELECT DISTINCT col2 + 15 / cor0.col0 FROM tab1 AS cor0
----
57
59
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9944
SELECT ALL - tab0.col1 + + CAST( col1 AS SIGNED ) AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9944
SELECT ALL - tab0.col1 + + CAST ( col1 AS INTEGER ) AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL 83 * - tab0.col0 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 8a9e6de455cd4a1e9d5248cc1ec144f5

query I rowsort
SELECT DISTINCT - 63 FROM tab0, tab1 AS cor0
----
-63

query I rowsort
SELECT ALL + + col2 - ( col1 ) * + col0 * + ( cor0.col1 ) AS col2 FROM tab2 AS cor0
----
-22793
-271492
-6700

query I rowsort
SELECT ALL - - col2 * - ( - col0 ) * col0 AS col1 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT DISTINCT - + cor0.col1 * + 56 * col0 FROM tab1 AS cor0
----
-35840
-4368
-58240

query I rowsort
SELECT DISTINCT + col2 * + 49 + col1 + - col0 FROM tab2 AS cor0
----
1255
1347
1800

query I rowsort
SELECT col0 + - 4 * + 65 AS col1 FROM tab1 AS cor0
----
-180
-196
-257

query I rowsort
SELECT ALL - 19 + 95 FROM tab0
----
76
76
76

query I rowsort
SELECT 70 * + tab1.col0 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 45057eabdfc9c276a006bcd1599c917f

query I rowsort
SELECT ALL 28 + col0 + col2 FROM tab1
----
149
204
85

query I rowsort
SELECT 25 * cor0.col2 AS col2 FROM tab2 cor0
----
650
675
950

onlyif mysql # use DIV operator for integer division
query I rowsort label-9956
SELECT ALL 68 DIV - col0 AS col1 FROM tab1 AS cor0
----
-1
-22
0

skipif mysql # not compatible
query I rowsort label-9956
SELECT ALL 68 / - col0 AS col1 FROM tab1 AS cor0
----
-1
-22
0

query I rowsort
SELECT DISTINCT - ( col0 ) * cor0.col1 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
-2150
-3492
-8190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9958
SELECT - 88 * - col2 + col2 + - CAST( NULL AS SIGNED ) / col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9958
SELECT - 88 * - col2 + col2 + - CAST ( NULL AS INTEGER ) / col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9959
SELECT + - 66 DIV col2 AS col1 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-9959
SELECT + - 66 / col2 AS col1 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT ALL - - col0 + col0 * col1 AS col2 FROM tab0 AS cor0
----
2088
3430
8188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9961
SELECT DISTINCT - - col1 + cor0.col0 * CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9961
SELECT DISTINCT - - col1 + cor0.col0 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + - col0 + col0 * + 89 AS col2 FROM tab2 AS cor0
----
616
6864
6952

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col0 * + col1 col1 FROM tab0 AS cor0
----
2150
3492
8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * cor0.col0 col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL 12 * col1 FROM tab0 cor0
----
1032
1092
1164

onlyif mysql # use DIV operator for integer division
query I rowsort label-9966
SELECT ALL + - col1 DIV col0 col2 FROM tab0 AS cor0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9966
SELECT ALL + - col1 / col0 col2 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT ( + 10 ) AS col1 FROM tab1
----
10
10
10

query I rowsort
SELECT ALL + 53 * col1 FROM tab0
----
4558
4823
5141

query I rowsort
SELECT DISTINCT col1 * col2 + + col2 AS col0 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT 43 + - col1 AS col2 FROM tab0 cor0
----
-43
-48
-54

query I rowsort
SELECT ALL + 23 + col0 AS col0 FROM tab0 AS cor0
----
112
47
58

query I rowsort
SELECT ALL - 75 * cor0.col0 AS col2 FROM tab0 AS cor0
----
-1800
-2625
-6675

onlyif mysql # use DIV operator for integer division
query I rowsort label-9973
SELECT ALL - cor0.col0 DIV col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9973
SELECT ALL - cor0.col0 / col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 74 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 63 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to c3eea92c46f2c49716f386a58b575025

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0, tab0 AS cor1, tab2 AS cor2
----
972 values hashing to d41be7437523f0dba2158c7f0439f329

query I rowsort
SELECT DISTINCT - 61 FROM tab1, tab0 cor0, tab1 AS cor1
----
-61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 - - col2 col1 FROM tab2 AS cor0
----
52
54
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9979
SELECT ALL - + col0 / CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9979
SELECT ALL - + col0 / CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col0 + col0 * cor0.col1 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT DISTINCT - cor0.col0 * + col1 * 42 + - col1 AS col0 FROM tab0 cor0
----
-142687
-340249
-86774

onlyif mysql # use DIV operator for integer division
query I rowsort label-9982
SELECT col2 DIV ( + col0 ) + col1 FROM tab2 AS cor0
----
17
34
59

skipif mysql # not compatible
query I rowsort label-9982
SELECT col2 / ( + col0 ) + col1 FROM tab2 AS cor0
----
17
34
59

query I rowsort
SELECT DISTINCT + cor0.col1 * + 75 FROM tab2 AS cor0
----
1275
2325
4425

query I rowsort
SELECT - - 80 FROM tab1, tab0 AS cor0
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT ALL + col1 + col2 * + col0 * - col1 FROM tab2 AS cor0
----
-119593
-51017
-5828

query I rowsort
SELECT DISTINCT - 27 + + ( + col1 ) FROM tab1 AS cor0
----
-1
-14
-17

query I rowsort
SELECT DISTINCT - - col0 * + ( + col0 ) + col2 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT - - col2 + - col0 * - col2 * ( - col1 + col2 ) FROM tab0 AS cor0
----
-3359
-41943
-65600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9989
SELECT DISTINCT - CAST( cor0.col2 AS SIGNED ) FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-9989
SELECT DISTINCT - CAST ( cor0.col2 AS INTEGER ) FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col0 * col2 col1 FROM tab0 cor0
----
1225
19008
649522

query I rowsort
SELECT + + 72 * col2 FROM tab0 AS cor0
----
2376
5904
72

query I rowsort
SELECT DISTINCT + col0 * 3 FROM tab2 AS cor0
----
21
234
237

query I rowsort
SELECT + col2 * col1 * - col1 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT ALL tab0.col2 + tab0.col2 + col0 FROM tab0
----
253
37
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9995
SELECT - - CAST( NULL AS SIGNED ) * cor0.col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9995
SELECT - - CAST ( NULL AS INTEGER ) * cor0.col1 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 * col0 + + col1 * col0 * col0 AS col1 FROM tab1 AS cor0
----
396
44608
90880

onlyif mysql # use DIV operator for integer division
query I rowsort label-9997
SELECT DISTINCT + + ( + col1 ) * col2 + + col0 - + col2 DIV cor0.col2 FROM tab1 cor0
----
1327
1406
633

skipif mysql # not compatible
query I rowsort label-9997
SELECT DISTINCT + + ( + col1 ) * col2 + + col0 - + col2 / cor0.col2 FROM tab1 cor0
----
1327
1406
633

onlyif mysql # use DIV operator for integer division
query I rowsort label-9998
SELECT DISTINCT + 83 DIV - col1 AS col0 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-9998
SELECT DISTINCT + 83 / - col1 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - 87 * col1 AS col0 FROM tab2 AS cor0
----
-1479
-2697
-5133