sqllogictest
Artifact Content
Not logged in

Artifact 1a905e742a3bd27bb80f6ecd245f4a46b1b8a087:


hash-threshold 8

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

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

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

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

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

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

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

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

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

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

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

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

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

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1, tab0 AS cor0, tab1 cor1
----
972 values hashing to 7942394eb7766dfb9ea95b7805ff595d

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

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

query I rowsort
SELECT ALL 64 AS col2 FROM tab2
----
64
64
64

query I rowsort
SELECT - + col1 + - 81 AS col1 FROM tab1 AS cor0
----
-107
-91
-94

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

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

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

query I rowsort
SELECT DISTINCT - col2 * + 40 FROM tab1 AS cor0
----
-2160
-2280
-3840

query I rowsort
SELECT DISTINCT + col0 + + col2 * - 52 FROM tab2 AS cor0
----
-1274
-1397
-1897

query I rowsort
SELECT ALL col0 + - ( + 6 ) * col2 * 94 FROM tab0 AS cor0
----
-18588
-46159
-529

query I rowsort
SELECT + col0 + 93 FROM tab0 AS cor0
----
117
128
182

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

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

query I rowsort
SELECT + - col2 * col2 * 82 FROM tab0 AS cor0
----
-551368
-82
-89298

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

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

query I rowsort
SELECT ALL + col1 * 53 AS col0 FROM tab1 cor0
----
1378
530
689

query I rowsort
SELECT DISTINCT col1 + + ( 21 ) * cor0.col2 FROM tab2 AS cor0
----
598
605
815

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

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

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

query I rowsort
SELECT DISTINCT - tab1.col2 + + 49 AS col0 FROM tab1, tab2, tab1 AS cor0
----
-47
-5
-8

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

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

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

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

query I rowsort
SELECT + ( 93 ) * - col0 FROM tab1 AS cor0
----
-279
-5952
-7440

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 52 col1 FROM tab2
----
111
69
83

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

query I rowsort
SELECT DISTINCT - - col0 * + col2 + 33 + + 35 AS col2 FROM tab0 AS cor0
----
103
7366
860

query I rowsort
SELECT DISTINCT - 33 * + col1 + col0 AS col0 FROM tab2 AS cor0
----
-1016
-1869
-482

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

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

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

query I rowsort
SELECT ALL + 85 + col0 FROM tab0 cor0
----
109
120
174

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

query I rowsort
SELECT + ( + col1 ) * + col0 + col0 * col0 + - cor0.col2 FROM tab1 AS cor0
----
33
4679
7344

query I rowsort
SELECT col2 - - 12 FROM tab2
----
38
39
50

query I rowsort
SELECT tab2.col1 + - 69 AS col1 FROM tab2
----
-10
-38
-52

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

skipif mysql # not compatible
query I rowsort label-37
SELECT + col0 + - col0 / col2 FROM tab1 AS cor0
----
3
63
80

query I rowsort
SELECT ALL tab1.col1 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT + col1 * col2 * 21 AS col2 FROM tab2
----
13566
17577
32214

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

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

query I rowsort
SELECT + 30 * cor1.col1 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 014c83c26abd20da9de5ac8894c81835

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

query I rowsort
SELECT ( + 1 + col0 ) FROM tab2
----
79
8
80

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

query I rowsort
SELECT DISTINCT - ( cor0.col1 ) + 12 AS col2 FROM tab2 AS cor0
----
-19
-47
-5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-47
SELECT - + ( col1 ) * + ( col2 * - cor0.col1 + - CAST( - ( col2 ) AS SIGNED ) ) AS col0 FROM tab1 AS cor0
----
14976
35100
5130

skipif mysql # not compatible
query I rowsort label-47
SELECT - + ( col1 ) * + ( col2 * - cor0.col1 + - CAST ( - ( col2 ) AS INTEGER ) ) AS col0 FROM tab1 AS cor0
----
14976
35100
5130

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

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

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

query I rowsort
SELECT DISTINCT - 84 * + col2 * + col1 AS col1 FROM tab2
----
-128856
-54264
-70308

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

query I rowsort
SELECT ALL - 56 * tab1.col1 AS col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 6de72235afe6c19713aecc1c706b4ca6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-54
SELECT ( ( - col2 ) * CAST( 95 AS SIGNED ) ) AS col1 FROM tab1
----
-5130
-5415
-9120

skipif mysql # not compatible
query I rowsort label-54
SELECT ( ( - col2 ) * CAST ( 95 AS INTEGER ) ) AS col1 FROM tab1
----
-5130
-5415
-9120

query I rowsort
SELECT col1 - - col2 * ( - col2 ) FROM tab1
----
-2890
-3239
-9203

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

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

query I rowsort
SELECT - + cor0.col0 + cor0.col1 * + 81 FROM tab1 AS cor0
----
2103
746
973

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

query I rowsort
SELECT col0 * - ( 26 ) FROM tab2
----
-182
-2028
-2054

onlyif mysql # use DIV operator for integer division
query I rowsort label-61
SELECT - col1 - + col0 DIV 58 FROM tab2 cor0
----
-18
-31
-60

skipif mysql # not compatible
query I rowsort label-61
SELECT - col1 - + col0 / 58 FROM tab2 cor0
----
-18
-31
-60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + 6 + - col1 col0 FROM tab0 AS cor0
----
-602
-637
-679

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 cor0, tab0 AS cor1, tab0 AS cor2
----
972 values hashing to 3406497351e4789c89a295ee9b64b201

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

query I rowsort
SELECT - col1 * + col1 * - col2 + - 47 FROM tab1 AS cor0
----
16177
36457
5653

onlyif mysql # use DIV operator for integer division
query I rowsort label-66
SELECT col2 + 82 DIV - cor0.col2 FROM tab1 AS cor0
----
53
56
96

skipif mysql # not compatible
query I rowsort label-66
SELECT col2 + 82 / - cor0.col2 FROM tab1 AS cor0
----
53
56
96

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 3 * - col2 col2 FROM tab2 AS cor0
----
114
78
81

query I rowsort
SELECT - + 35 * col1 + col2 AS col0 FROM tab1 AS cor0
----
-293
-359
-856

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

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

query I rowsort
SELECT ALL col0 + ( + col0 * col2 + + col0 ) AS col1 FROM tab0
----
105
7476
840

query I rowsort
SELECT - 19 + col0 AS col0 FROM tab1 AS cor0
----
-16
45
61

query I rowsort
SELECT ALL - + 91 + 29 + - cor0.col1 FROM tab0 AS cor0
----
-148
-153
-159

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

query I rowsort
SELECT DISTINCT + cor0.col1 - + 96 FROM tab1 AS cor0
----
-70
-83
-86

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

query I rowsort
SELECT ALL - 21 * - col2 * + col1 AS col0 FROM tab1 AS cor0
----
11970
26208
29484

query I rowsort
SELECT ALL + 43 * + 46 - - col1 FROM tab0 AS cor0
----
2064
2069
2075

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

query I rowsort
SELECT DISTINCT + - 15 AS col2 FROM tab0 cor0
----
-15

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

query I rowsort
SELECT DISTINCT + col0 * - 65 AS col0 FROM tab0 AS cor0
----
-1560
-2275
-5785

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-85
SELECT ALL + - CAST( 18 AS SIGNED ) * col1 + - col2 + + col2 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-1746
-492
5004

skipif mysql # not compatible
query I rowsort label-85
SELECT ALL + - CAST ( 18 AS INTEGER ) * col1 + - col2 + + col2 * cor0.col2 AS col1 FROM tab0 AS cor0
----
-1746
-492
5004

query I rowsort
SELECT + + 18 + - col1 * col1 AS col2 FROM tab0 cor0
----
-7378
-8263
-9391

query I rowsort
SELECT - col2 * + 26 - + col1 AS col2 FROM tab0 AS cor0
----
-123
-2223
-944

query I rowsort
SELECT DISTINCT - 77 * + 22 + col1 FROM tab2 AS cor0
----
-1635
-1663
-1677

query I rowsort
SELECT DISTINCT 74 - 22 FROM tab1 AS cor0
----
52

query I rowsort
SELECT ALL ( - 90 ) * col1 FROM tab0 AS cor0
----
-7740
-8190
-8730

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

query I rowsort
SELECT DISTINCT + 69 + col1 FROM tab0 AS cor0
----
155
160
166

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

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

query I rowsort
SELECT - + 21 * + col0 FROM tab2 cor0
----
-147
-1638
-1659

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

query I rowsort
SELECT + + col2 + + col1 * + 93 AS col0 FROM tab2 AS cor0
----
1619
2910
5513

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

query I rowsort
SELECT DISTINCT + 16 * col0 FROM tab0 AS cor0
----
1424
384
560

query I rowsort
SELECT + - cor0.col0 * + 48 AS col0 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to dd629622b93bd94cc2fe909691e695e1

onlyif mysql # use DIV operator for integer division
query I rowsort label-101
SELECT ALL - 74 + 86 DIV + col2 FROM tab1
----
-73
-73
-74

skipif mysql # not compatible
query I rowsort label-101
SELECT ALL - 74 + 86 / + col2 FROM tab1
----
-73
-73
-74

query I rowsort
SELECT DISTINCT col1 + - 74 AS col2 FROM tab0 AS cor0
----
12
17
23

query I rowsort
SELECT ALL - col2 + 25 AS col2 FROM tab2 AS cor0
----
-1
-13
-2

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * ( + 45 ) - + col2 col0 FROM tab2 cor0
----
288
3484
3517

query I rowsort
SELECT - + 62 + 69 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

query I rowsort
SELECT DISTINCT + + col1 * 33 FROM tab2 AS cor0
----
1023
1947
561

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

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

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

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

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

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

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

query I rowsort
SELECT + col0 * col1 - - 69 FROM tab2
----
1412
286
4671

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

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

query I rowsort
SELECT col2 + col1 * + 97 * + col2 + 6 * - 90 FROM tab0
----
274779
723356
8870

query I rowsort
SELECT ALL + - 2 + - col2 AS col2 FROM tab1 AS cor0
----
-56
-59
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 80 * + col0 col2 FROM tab2 AS cor0
----
-560
-6240
-6320

query I rowsort
SELECT ALL 59 + - col0 FROM tab1 AS cor0
----
-21
-5
56

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

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

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

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

query I rowsort
SELECT - col1 + 70 * col2 AS col0 FROM tab2 AS cor0
----
1761
1859
2643

query I rowsort
SELECT DISTINCT col0 * - col1 * 64 FROM tab0
----
-132096
-217280
-518336

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

query I rowsort
SELECT DISTINCT col1 * + 94 AS col0 FROM tab1 AS cor0
----
1222
2444
940

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

skipif mysql # not compatible
query I rowsort label-127
SELECT col2 - col2 / col2 FROM tab0
----
0
32
81

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

query I rowsort
SELECT DISTINCT + 54 + col0 AS col0 FROM tab2 AS cor0
----
132
133
61

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

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

query I rowsort
SELECT - 56 + + col0 AS col2 FROM tab1 AS cor0
----
-53
24
8

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

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

query I rowsort
SELECT ALL + ( + 19 ) AS col2 FROM tab0 AS cor0
----
19
19
19

query I rowsort
SELECT DISTINCT - 58 + 17 AS col0 FROM tab1 AS cor0
----
-41

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + 26 + + col1 * - col0 col0 FROM tab0
----
-2062
-3404
-8162

query I rowsort
SELECT col2 + + 33 AS col2 FROM tab0
----
115
34
66

query I rowsort
SELECT ALL - col1 * - tab1.col1 + col0 AS col2 FROM tab1
----
164
249
679

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

query I rowsort
SELECT DISTINCT + col1 + + col2 * 9 * tab1.col2 AS col1 FROM tab1
----
26270
29251
82957

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

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

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

query I rowsort
SELECT 97 + 27 * col2 FROM tab1
----
1555
1636
2689

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

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

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

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

query I rowsort
SELECT DISTINCT + 12 + + 53 * - col2 AS col1 FROM tab1 AS cor0
----
-2850
-3009
-5076

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

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

query I rowsort
SELECT - + ( 90 ) + - col1 * 70 AS col1 FROM tab0 AS cor0
----
-6110
-6460
-6880

query I rowsort
SELECT ALL + 34 * col0 + + col1 AS col2 FROM tab2 AS cor0
----
269
2703
2711

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-152
SELECT + CAST( ( + col1 ) AS SIGNED ) + - ( 46 ) * + col1 AS col2 FROM tab2
----
-1395
-2655
-765

skipif mysql # not compatible
query I rowsort label-152
SELECT + CAST ( ( + col1 ) AS INTEGER ) + - ( 46 ) * + col1 AS col2 FROM tab2
----
-1395
-2655
-765

query I rowsort
SELECT ALL 69 * col0 AS col1 FROM tab2 AS cor0
----
483
5382
5451

query I rowsort
SELECT - - 86 + + ( col2 + - 53 ) * + col2 AS col2 FROM tab1 AS cor0
----
140
314
4214

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * cor0.col0 col0 FROM tab0 AS cor0
----
-1225
-576
-7921

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

query I rowsort
SELECT DISTINCT 82 * 28 AS col2 FROM tab0, tab1, tab0 AS cor0
----
2296

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

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

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

query I rowsort
SELECT + 61 + - 94 AS col1 FROM tab1
----
-33
-33
-33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 3 * + col2 + - col1 col2 FROM tab0 AS cor0
----
-94
13
155

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

query I rowsort
SELECT ALL - 20 + col2 FROM tab2 AS cor0
----
18
6
7

query I rowsort
SELECT ALL + 92 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT DISTINCT + - cor0.col0 * + cor0.col2 + + 50 AS col2 FROM tab0 AS cor0
----
-7248
-742
15

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

query I rowsort
SELECT 73 * cor0.col1 + ( col0 ) * col0 FROM tab2 AS cor0
----
10391
2312
7482

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

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

query I rowsort
SELECT col0 - + 94 FROM tab2 AS cor0
----
-15
-16
-87

query I rowsort
SELECT ALL col1 + - 92 AS col0 FROM tab2
----
-33
-61
-75

query I rowsort
SELECT DISTINCT col0 + - 75 FROM tab2
----
-68
3
4

query I rowsort
SELECT 97 FROM tab1, tab1 AS cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

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

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

query I rowsort
SELECT ALL + + col1 + col1 - 41 AS col0 FROM tab0 AS cor0
----
131
141
153

query I rowsort
SELECT - col2 + ( 45 * col2 ) AS col2 FROM tab2 cor0
----
1144
1188
1672

query I rowsort
SELECT - col2 * - ( - 64 ) FROM tab2 AS cor0
----
-1664
-1728
-2432

query I rowsort
SELECT DISTINCT + col1 + + col1 - col1 * - col2 AS col1 FROM tab2 cor0
----
1652
680
899

query I rowsort
SELECT - + col1 + + 93 AS col1 FROM tab0 AS cor0
----
-4
2
7

query I rowsort
SELECT ALL - col0 * 85 + + 25 AS col0 FROM tab1 AS cor0
----
-230
-5415
-6775

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

query I rowsort
SELECT - + cor0.col1 * 69 + + 70 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
-1649
1389
4357

query I rowsort
SELECT ALL + col1 + + col2 * 12 FROM tab2 AS cor0
----
355
371
473

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-187
SELECT CAST ( NULL AS INTEGER ) / - 90 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col1 + 75 AS col1 FROM tab0 AS cor0
----
161
166
172

query I rowsort
SELECT ( 46 ) * col0 * 52 + 27 AS col2 FROM tab1 AS cor0
----
153115
191387
7203

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

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

query I rowsort
SELECT ALL - col2 + - ( + col0 ) AS col1 FROM tab0
----
-171
-36
-57

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

query I rowsort
SELECT col2 * - 37 FROM tab1 AS cor0
----
-1998
-2109
-3552

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - ( 48 ) * col0 * + ( - 51 ) col0 FROM tab2 AS cor0
----
17167
191003
193409

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

query I rowsort
SELECT col0 * - ( col0 ) + + col0 + col1 FROM tab2 AS cor0
----
-11
-5947
-6145

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-200
SELECT ALL + col1 DIV 57 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-200
SELECT ALL + col1 / 57 FROM tab1 AS cor0
----
0
0
0

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-203
SELECT col2 + - ( - col1 ) DIV - col0 + - 10 AS col2 FROM tab2 AS cor0
----
13
16
28

skipif mysql # not compatible
query I rowsort label-203
SELECT col2 + - ( - col1 ) / - col0 + - 10 AS col2 FROM tab2 AS cor0
----
13
16
28

query I rowsort
SELECT DISTINCT - cor0.col1 AS col2 FROM tab0, tab2 AS cor0 CROSS JOIN tab1
----
-17
-31
-59

query I rowsort
SELECT ALL - tab0.col2 + - 91 AS col2 FROM tab0
----
-124
-173
-92

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

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

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

query I rowsort
SELECT DISTINCT ( 20 ) + - col0 AS col0 FROM tab1 AS cor0
----
-44
-60
17

query I rowsort
SELECT ALL - 65 - col2 AS col0 FROM tab0
----
-147
-66
-98

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

query I rowsort
SELECT + 2 * col0 - + 14 FROM tab0 cor0
----
164
34
56

query I rowsort
SELECT DISTINCT - ( 20 ) AS col2 FROM tab2, tab1 AS cor0
----
-20

query I rowsort
SELECT - col1 + + col0 * ( col0 ) * - cor0.col1 + - cor0.col0 AS col1 FROM tab1 AS cor0
----
-263
-41034
-83293

query I rowsort
SELECT 97 + col2 FROM tab0 AS cor0
----
130
179
98

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

skipif mysql # not compatible
query I rowsort label-216
SELECT ALL + col0 * col0 + - col0 * col0 - - col0 / - 34 AS col2 FROM tab2
----
-2
-2
0

query I rowsort
SELECT - 9 * + col1 AS col0 FROM tab0
----
-774
-819
-873

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

query I rowsort
SELECT ALL + 65 * + col2 + - col0 AS col2 FROM tab0
----
2121
30
5241

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-221
SELECT - cor0.col2 + ( + 44 ) DIV col1 FROM tab1 AS cor0
----
-53
-53
-93

skipif mysql # not compatible
query I rowsort label-221
SELECT - cor0.col2 + ( + 44 ) / col1 FROM tab1 AS cor0
----
-53
-53
-93

query I rowsort
SELECT + col2 + - 56 + - 42 AS col2 FROM tab1 AS cor0
----
-2
-41
-44

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

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

query I rowsort
SELECT + + cor0.col2 + ( - 65 + + cor0.col0 ) AS col2 FROM tab2 AS cor0
----
-31
39
52

query I rowsort
SELECT ALL - col2 + + col0 + 68 FROM tab0 AS cor0
----
102
59
75

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

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

skipif mysql # not compatible
query I rowsort label-228
SELECT ALL + - col2 / ( - cor0.col2 ) + col2 AS col1 FROM tab0 AS cor0
----
2
34
83

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

query I rowsort
SELECT ALL - 71 - - col2 FROM tab0 AS cor0
----
-38
-70
11

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

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

query I rowsort
SELECT DISTINCT - + 43 + + 57 FROM tab2 AS cor0
----
14

query I rowsort
SELECT DISTINCT - + 23 + cor0.col1 AS col2 FROM tab0 AS cor0
----
63
68
74

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

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

query I rowsort
SELECT ALL - 53 * + cor0.col1 + - col2 AS col2 FROM tab0 AS cor0
----
-4591
-4905
-5142

onlyif mysql # use DIV operator for integer division
query I rowsort label-238
SELECT DISTINCT 33 * col1 DIV 32 FROM tab0 AS cor0
----
100
88
93

skipif mysql # not compatible
query I rowsort label-238
SELECT DISTINCT 33 * col1 / 32 FROM tab0 AS cor0
----
100
88
93

query I rowsort
SELECT DISTINCT + col2 * - cor0.col0 * col0 + - cor0.col0 FROM tab0 AS cor0
----
-1260
-19032
-649611

query I rowsort
SELECT ALL 28 + + cor0.col1 * + col2 * - col1 AS col1 FROM tab0 AS cor0
----
-244040
-679014
-9381

query I rowsort
SELECT DISTINCT + col2 + + col2 * + ( - col2 ) + col1 FROM tab0 AS cor0
----
-6551
-970
97

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 12 - cor0.col1 * col1 col2 FROM tab2 AS cor0
----
-277
-3469
-949

query I rowsort
SELECT + + 89 + col2 * - ( - 3 ) FROM tab1 AS cor0
----
251
260
377

query I rowsort
SELECT DISTINCT - 15 * + col2 FROM tab0 cor0
----
-1230
-15
-495

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col2 * ( + col2 * col2 ) col1 FROM tab2
----
17576
19683
54872

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

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

query I rowsort
SELECT col1 + - col0 * + 69 FROM tab1
----
-181
-4406
-5507

onlyif mysql # use DIV operator for integer division
query I rowsort label-250
SELECT ALL - col2 DIV col1 + + col1 AS col2 FROM tab1 AS cor0
----
24
5
6

skipif mysql # not compatible
query I rowsort label-250
SELECT ALL - col2 / col1 + + col1 AS col2 FROM tab1 AS cor0
----
24
5
6

query I rowsort
SELECT ALL - - col2 + - ( col0 ) FROM tab1 AS cor0
----
-7
16
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * 14 + + col1 col0 FROM tab1 AS cor0
----
1357
782
808

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

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

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

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

query I rowsort
SELECT col0 + - 74 AS col0 FROM tab2 AS cor0
----
-67
4
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-257
SELECT - col1 + CAST( 95 AS SIGNED ) * + col2 * - 94 FROM tab1 AS cor0
----
-482246
-509020
-857293

skipif mysql # not compatible
query I rowsort label-257
SELECT - col1 + CAST ( 95 AS INTEGER ) * + col2 * - 94 FROM tab1 AS cor0
----
-482246
-509020
-857293

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

skipif mysql # not compatible
query I rowsort label-258
SELECT DISTINCT col2 / ( 33 + + col1 ) AS col1 FROM tab2 AS cor0
----
0

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-260
SELECT - ( + cor0.col1 ) DIV - cor0.col1 FROM tab2, tab2 cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-260
SELECT - ( + cor0.col1 ) / - cor0.col1 FROM tab2, tab2 cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT DISTINCT - + 31 FROM tab1 AS cor0
----
-31

query I rowsort
SELECT ALL + + cor0.col1 * 13 FROM tab2 AS cor0
----
221
403
767

query I rowsort
SELECT ALL 52 FROM tab0, tab0 AS cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT + - col1 * cor0.col2 + - 81 AS col1 FROM tab0 AS cor0
----
-178
-2919
-7543

query I rowsort
SELECT + col2 * col0 * ( + col2 * col0 ) - 37 AS col0 FROM tab0 AS cor0
----
1188
53260767
627227

query I rowsort
SELECT + + 86 - col0 AS col0 FROM tab1 AS cor0
----
22
6
83

query I rowsort
SELECT col2 * + col2 + + col1 AS col2 FROM tab2
----
1461
735
760

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

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

query I rowsort
SELECT ALL - cor0.col1 * - tab2.col0 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 9337cab14248fdf0584f0cfce23b6e23

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

skipif mysql # not compatible
query I rowsort label-271
SELECT - 68 - - col1 / ( - ( col1 ) * CAST ( NULL AS INTEGER ) ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 40 - + col2 AS col2 FROM tab1 AS cor0
----
-136
-94
-97

query I rowsort
SELECT ALL 44 * col1 FROM tab0 AS cor0
----
3784
4004
4268

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

query I rowsort
SELECT - col2 + col0 * 16 - 2 FROM tab1
----
-8
1182
965

query I rowsort
SELECT DISTINCT - col1 + col2 + - cor0.col0 FROM tab1 AS cor0
----
-17
25
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col2 col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT col0 * col1 + - ( - 26 ) * tab0.col1 AS col2 FROM tab0
----
10465
4300
5917

query I rowsort
SELECT DISTINCT 49 + - col1 AS col2 FROM tab2
----
-10
18
32

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

query I rowsort
SELECT DISTINCT 55 * + col0 + - tab2.col2 AS col1 FROM tab2
----
358
4264
4307

query I rowsort
SELECT DISTINCT 8 + col0 FROM tab0
----
32
43
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col1 + - ( col2 + - col1 ) col0 FROM tab0
----
7449
8290
9505

query I rowsort
SELECT DISTINCT cor1.col0 AS col0 FROM tab0, tab1 AS cor0, tab1 cor1
----
3
64
80

query I rowsort
SELECT DISTINCT + + ( + 55 ) FROM tab0 cor0
----
55

query I rowsort
SELECT DISTINCT - - ( 34 ) * col1 AS col2 FROM tab0 AS cor0
----
2924
3094
3298

query I rowsort
SELECT - col0 * + ( col2 ) + - col0 * + col2 + 35 FROM tab0 AS cor0
----
-14561
-1549
-35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * + tab1.col0 col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT ALL col2 * ( tab0.col0 ) * tab0.col1 AS col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT + + 77 + col2 * 70 FROM tab0 AS cor0
----
147
2387
5817

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

skipif mysql # not compatible
query I rowsort label-291
SELECT 1 / col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - ( - 50 + col2 ) FROM tab0
----
-32
17
49

query I rowsort
SELECT ( 19 ) FROM tab1
----
19
19
19

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-294
SELECT ALL CAST( + 23 AS SIGNED ) * - col2 FROM tab2
----
-598
-621
-874

skipif mysql # not compatible
query I rowsort label-294
SELECT ALL CAST ( + 23 AS INTEGER ) * - col2 FROM tab2
----
-598
-621
-874

query I rowsort
SELECT 59 * - col0 FROM tab2
----
-413
-4602
-4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-296
SELECT + 87 DIV + col2 + - col1 * col1 * - col1 AS col2 FROM tab0 AS cor0
----
636058
753572
912760

skipif mysql # not compatible
query I rowsort label-296
SELECT + 87 / + col2 + - col1 * col1 * - col1 AS col2 FROM tab0 AS cor0
----
636058
753572
912760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col1 ) + 18 * + col0 col2 FROM tab1 AS cor0
----
1162
1453
80

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

query I rowsort
SELECT - 75 * - col0 FROM tab2 cor0
----
525
5850
5925

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

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

query I rowsort
SELECT ALL + 40 - - 40 FROM tab2
----
80
80
80

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-305
SELECT DISTINCT CAST( + 63 AS SIGNED ) * cor0.col1 - - ( - 88 ) FROM tab1 AS cor0
----
1550
542
731

skipif mysql # not compatible
query I rowsort label-305
SELECT DISTINCT CAST ( + 63 AS INTEGER ) * cor0.col1 - - ( - 88 ) FROM tab1 AS cor0
----
1550
542
731

query I rowsort
SELECT + - col1 * col1 + col2 * - col2 FROM tab1 AS cor0
----
-3349
-3592
-9385

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col2 + col2 col0 FROM tab2 cor0
----
1482
702
756

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-309
SELECT + col0 DIV - cor0.col0 + cor0.col2 AS col2 FROM tab1 AS cor0
----
53
56
95

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-312
SELECT 62 DIV col0 FROM tab1 AS cor0
----
0
0
20

skipif mysql # not compatible
query I rowsort label-312
SELECT 62 / col0 FROM tab1 AS cor0
----
0
0
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-313
SELECT + + cor0.col1 + col2 + CAST( - 3 AS SIGNED ) DIV + col1 AS col1 FROM tab2 cor0
----
55
58
85

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

query I rowsort
SELECT - - 53 + + col0 * + ( 99 ) * col0 FROM tab1 AS cor0
----
405557
633653
944

query I rowsort
SELECT - - col0 * col0 + - 92 * + col2 * col2 FROM tab2 AS cor0
----
-126607
-56108
-67019

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

query I rowsort
SELECT DISTINCT + - col0 + cor0.col2 * + col1 * col2 + col1 FROM tab1 AS cor0
----
119741
32436
75839

query I rowsort
SELECT ALL + 67 AS col2 FROM tab1
----
67
67
67

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

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

skipif mysql # not compatible
query I rowsort label-320
SELECT - + col2 + + col2 / ( col0 ) AS col2 FROM tab1 AS cor0
----
-36
-57
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 69 * - col0 col2 FROM tab2 AS cor0
----
483
5382
5451

skipif mysql # not compatible
query I rowsort
SELECT ALL col0 + + col1 * CAST ( col2 AS REAL ) FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT col0 * + col1 + - 24 FROM tab2 AS cor0
----
1319
193
4578

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-328
SELECT ALL col2 - CAST ( NULL AS REAL ) / 9 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 * 39 - col2 AS col1 FROM tab2 AS cor0
----
-1040
-1080
-1520

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-331
SELECT DISTINCT - - col0 * col1 * - col0 + col2 DIV col2 AS col1 FROM tab1 AS cor0
----
-233
-40959
-83199

skipif mysql # not compatible
query I rowsort label-331
SELECT DISTINCT - - col0 * col1 * - col0 + col2 / col2 AS col1 FROM tab1 AS cor0
----
-233
-40959
-83199

query I rowsort
SELECT 54 * cor0.col1 * + cor0.col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c81343da6af352bfe6a413a44ab6f083

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 1 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT DISTINCT + 74 - col2 FROM tab1 AS cor0
----
-22
17
20

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

query I rowsort
SELECT DISTINCT - 72 * 54 - col2 AS col0 FROM tab2 cor0
----
-3914
-3915
-3926

query I rowsort
SELECT DISTINCT + 68 * col2 * col1 AS col2 FROM tab2 cor0
----
104312
43928
56916

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

query I rowsort
SELECT ALL 35 * - 30 FROM tab0 AS cor0
----
-1050
-1050
-1050

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

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

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

skipif mysql # not compatible
query I rowsort label-341
SELECT DISTINCT + CAST ( - 81 AS INTEGER ) * cor0.col2 FROM tab0 AS cor0
----
-2673
-6642
-81

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

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

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

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

query I rowsort
SELECT DISTINCT - cor0.col0 + - 60 - - col0 * - col1 * + col0 AS col0 FROM tab1 AS cor0
----
-297
-41084
-83340

query I rowsort
SELECT DISTINCT - + ( 66 ) AS col0 FROM tab1 AS cor0
----
-66

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 54 * cor0.col0 col1 FROM tab2 AS cor0
----
378
4212
4266

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-352
SELECT DISTINCT - - CAST ( - col0 AS INTEGER ) col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT - tab2.col2 * - col2 * - col0 + - col1 FROM tab2
----
-114093
-5134
-52787

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

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

query I rowsort
SELECT DISTINCT - + ( - 67 ) FROM tab2 AS cor0
----
67

query I rowsort
SELECT DISTINCT + - 2 + 17 * + col2 FROM tab1 AS cor0
----
1630
916
967

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

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

query I rowsort
SELECT DISTINCT + col1 + + col1 * - 84 FROM tab2
----
-1411
-2573
-4897

query I rowsort
SELECT 17 * + col0 * - ( col2 ) + col1 AS col0 FROM tab1 AS cor0
----
-130547
-2728
-62006

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL - - col2 + + col1 + - col0 * - col0 AS col1 FROM tab1 AS cor0
----
4163
6509
89

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

query I rowsort
SELECT DISTINCT + tab0.col1 * + col1 + + col2 + col0 FROM tab0
----
7453
8452
9445

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * col0 * col0 col0 FROM tab1 AS cor0
----
-262144
-27
-512000

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

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

query I rowsort
SELECT tab1.col2 + + col1 FROM tab1
----
109
67
80

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

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

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

skipif mysql # not compatible
query I rowsort label-378
SELECT col1 * col0 / col1 FROM tab1 AS cor0
----
3
64
80

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - col2 + + col0 * col1 + col1 * cor0.col1 col0 FROM tab1 AS cor0
----
4388
8889
916

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

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

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 + + col0 col1 FROM tab0 cor0
----
24
35
89

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

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

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

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

skipif mysql # not compatible
query I rowsort label-388
SELECT DISTINCT - col0 + col1 / - col1 AS col2 FROM tab1 AS cor0
----
-4
-65
-81

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

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

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

query I rowsort
SELECT - col1 * - col2 + col1 + + col0 AS col1 FROM tab1 AS cor0
----
1341
1433
644

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

query I rowsort
SELECT DISTINCT col2 * col0 + cor0.col2 * - col2 + + col1 AS col2 FROM tab1 AS cor0
----
-1523
-2728
409

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

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

query I rowsort
SELECT DISTINCT + col1 + + col0 + - col2 FROM tab2 AS cor0
----
11
111
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 - tab2.col1 * col2 col0 FROM tab2
----
-1508
-608
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-399
SELECT + col2 * cor0.col0 + - col1 DIV col2 - + col0 * - col2 AS col2 FROM tab0 cor0
----
-27
14595
1582

skipif mysql # not compatible
query I rowsort label-399
SELECT + col2 * cor0.col0 + - col1 / col2 - + col0 * - col2 AS col2 FROM tab0 cor0
----
-27
14595
1582

query I rowsort
SELECT col0 + + cor0.col2 * col0 * - col2 FROM tab2 AS cor0
----
-113997
-5096
-52650

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

query I rowsort
SELECT DISTINCT cor0.col2 + + col0 * 51 FROM tab0 AS cor0
----
1257
1786
4621

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

query I rowsort
SELECT - col1 * + col2 - 14 * cor0.col2 FROM tab2 AS cor0
----
-1178
-1215
-1898

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

query I rowsort
SELECT + cor0.col2 + col2 * + col2 * - col2 AS col0 FROM tab0 AS cor0
----
-35904
-551286
0

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

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

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

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

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

query I rowsort
SELECT + tab0.col1 AS col1 FROM tab0 WHERE ( NULL ) NOT IN ( - col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-413
SELECT DISTINCT tab2.col0 DIV col0 + + col0 AS col0 FROM tab2
----
79
8
80

skipif mysql # not compatible
query I rowsort label-413
SELECT DISTINCT tab2.col0 / col0 + + col0 AS col0 FROM tab2
----
79
8
80

query I rowsort
SELECT col2 + - col2 * - col1 * + col2 FROM tab1
----
119904
32547
75870

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

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

query I rowsort
SELECT col1 + - col0 * col2 + col2 * col0 AS col2 FROM tab0
----
86
91
97

query I rowsort
SELECT col2 + + col0 - - col0 * col1 * + col1 AS col1 FROM tab2
----
22948
271622
6761

query I rowsort
SELECT ALL - col0 - - col0 AS col1 FROM tab2
----
0
0
0

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

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

query I rowsort
SELECT ALL + col2 FROM tab2 WHERE NOT NULL = - col1
----

query I rowsort
SELECT + 20 AS col2 FROM tab2
----
20
20
20

query I rowsort
SELECT 93 + col1 FROM tab1 AS cor0
----
103
106
119

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

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

query I rowsort
SELECT col0 * - 98 + - col0 * col0 + cor0.col0 FROM tab2 AS cor0
----
-13650
-13904
-728

query I rowsort
SELECT - col0 * - ( 67 ) FROM tab1 AS cor0
----
201
4288
5360

query I rowsort
SELECT ALL - col0 + + col0 * col0 * + col2 - - col1 AS col0 FROM tab0
----
1287
19070
649524

onlyif mysql # use DIV operator for integer division
query I rowsort label-429
SELECT + col1 * - 94 + tab0.col1 + col2 DIV + tab0.col1 FROM tab0
----
-7998
-8463
-9021

skipif mysql # not compatible
query I rowsort label-429
SELECT + col1 * - 94 + tab0.col1 + col2 / + tab0.col1 FROM tab0
----
-7998
-8463
-9021

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

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

query I rowsort
SELECT + col1 + 36 * ( col1 ) AS col0 FROM tab2 cor0
----
1147
2183
629

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * cor0.col0 col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT col2 + - col0 * col2 * col1 AS col2 FROM tab1 AS cor0
----
-36423
-4158
-99744

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

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

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

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

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

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

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

query I rowsort
SELECT - + 30 FROM tab1 cor0
----
-30
-30
-30

query I rowsort
SELECT - 19 + 55 FROM tab1 AS cor0
----
36
36
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-442
SELECT ALL + col1 + - col2 DIV - 53 AS col1 FROM tab0 AS cor0
----
86
92
97

skipif mysql # not compatible
query I rowsort label-442
SELECT ALL + col1 + - col2 / - 53 AS col1 FROM tab0 AS cor0
----
86
92
97

query I rowsort
SELECT DISTINCT - + 15 + col2 FROM tab2 AS cor0
----
11
12
23

query I rowsort
SELECT DISTINCT - 96 + - col1 * col1 FROM tab2 AS cor0
----
-1057
-3577
-385

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

query I rowsort
SELECT ALL col1 + - col1 * 58 AS col1 FROM tab1 AS cor0
----
-1482
-570
-741

query I rowsort
SELECT DISTINCT col2 * col2 * + col1 + - cor0.col2 FROM tab0 cor0
----
611802
93621
96

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 36 + col1 * - col0 col1 FROM tab0 AS cor0
----
-2100
-3431
-8135

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

query I rowsort
SELECT DISTINCT - - 63 * cor0.col1 + col2 AS col1 FROM tab2 AS cor0
----
1109
1980
3743

query I rowsort
SELECT - - 88 * col0 FROM tab0 AS cor0
----
2112
3080
7832

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

query I rowsort
SELECT ALL - - col2 + - col1 - - col0 AS col1 FROM tab0 cor0
----
-29
-61
80

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

query I rowsort
SELECT DISTINCT - + col0 - col2 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT + cor0.col2 * - cor0.col2 + col2 + - col1 AS col2 FROM tab0 AS cor0
----
-1142
-6733
-97

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

skipif mysql # not compatible
query I rowsort label-458
SELECT 37 / tab0.col1 + col1 AS col0 FROM tab0
----
86
91
97

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

query I rowsort
SELECT col2 * + col2 - tab1.col0 AS col1 FROM tab1
----
2913
3185
9136

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

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

query I rowsort
SELECT ALL - col1 * + 63 * - 40 - col2 FROM tab1
----
25143
32664
65466

query I rowsort
SELECT col2 + 42 * + col2 + col0 * col2 FROM tab0
----
10824
2211
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-465
SELECT DISTINCT - col2 * tab1.col1 DIV col1 + col0 * col1 * col0 AS col1 FROM tab1
----
180
40903
83104

skipif mysql # not compatible
query I rowsort label-465
SELECT DISTINCT - col2 * tab1.col1 / col1 + col0 * col1 * col0 AS col1 FROM tab1
----
180
40903
83104

query I rowsort
SELECT DISTINCT - col0 + - 84 FROM tab2
----
-162
-163
-91

query I rowsort
SELECT - tab0.col2 + 32 AS col2 FROM tab0
----
-1
-50
31

query I rowsort
SELECT - 89 AS col2 FROM tab0
----
-89
-89
-89

query I rowsort
SELECT col1 * - col0 + col1 + + col2 FROM tab2
----
-1288
-159
-4517

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

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

query I rowsort
SELECT + 21 + col0 AS col0 FROM tab2
----
100
28
99

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

query I rowsort
SELECT DISTINCT - 11 + - tab1.col2 * col1 FROM tab1
----
-1259
-1415
-581

query I rowsort
SELECT - ( col0 ) - tab0.col0 * + col0 AS col2 FROM tab0
----
-1260
-600
-8010

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

query I rowsort
SELECT col2 * col2 + - col2 + col0 * col0 FROM tab2 AS cor0
----
6734
751
7647

query I rowsort
SELECT DISTINCT - 97 + 25 * tab1.col2 FROM tab1
----
1253
1328
2303

query I rowsort
SELECT + + col1 + - 34 FROM tab1 AS cor0
----
-21
-24
-8

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

query I rowsort
SELECT ALL 71 * col2 - col1 AS col0 FROM tab1 AS cor0
----
3808
4037
6803

query I rowsort
SELECT + + 98 - 72 * + col0 AS col2 FROM tab1 AS cor0
----
-118
-4510
-5662

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

query I rowsort
SELECT - col2 * cor0.col2 * col2 AS col2 FROM tab1 AS cor0
----
-157464
-185193
-884736

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

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

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

skipif mysql # not compatible
query I rowsort label-485
SELECT ALL + tab0.col2 + + col2 / col0 AS col1 FROM tab0
----
1
34
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-486
SELECT ALL + 90 + 49 - + col0 DIV + cor0.col1 col2 FROM tab0 AS cor0
----
139
139
139

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-486
SELECT ALL + 90 + 49 - + col0 / + cor0.col1 col2 FROM tab0 AS cor0
----
139
139
139

onlyif mysql # use DIV operator for integer division
query I rowsort label-487
SELECT ALL - ( - cor0.col2 ) * col1 DIV ( col1 ) + col0 AS col1 FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-487
SELECT ALL - ( - cor0.col2 ) * col1 / ( col1 ) + col0 AS col1 FROM tab2 AS cor0
----
104
117
34

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

query I rowsort
SELECT - 57 FROM tab1, tab0 AS cor0
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

query I rowsort
SELECT DISTINCT + + col1 * + cor0.col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - col1 * 48 FROM tab1 AS cor0
----
-1248
-480
-624

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

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

query I rowsort
SELECT DISTINCT + col0 * - ( 63 ) AS col0 FROM tab0 AS cor0
----
-1512
-2205
-5607

query I rowsort
SELECT 99 * - ( cor0.col0 ) AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 1800530561d04b5280d564c678aa70c5

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

skipif mysql # not compatible
query I rowsort label-495
SELECT - col0 + CAST ( col0 AS INTEGER ) * cor0.col0 AS col0 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT 80 FROM tab1, tab1 AS cor0
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT + - 37 + + cor0.col2 * - cor0.col0 AS col2 FROM tab0 cor0
----
-72
-7335
-829

query I rowsort
SELECT ALL 31 FROM tab0, tab0 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query I rowsort
SELECT ALL + 12 * 47 FROM tab1
----
564
564
564

query I rowsort
SELECT ALL + - col1 + 58 * cor0.col2 * col0 AS col2 FROM tab2 cor0
----
10931
117565
174099

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

query I rowsort
SELECT DISTINCT - 48 * + col0 - 52 AS col1 FROM tab2 AS cor0
----
-3796
-3844
-388

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

query I rowsort
SELECT + 20 + + col2 * col0 AS col1 FROM tab0 AS cor0
----
55
7318
812

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-506
SELECT ALL - + 52 DIV cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to ccd77e2770d5a834e59c1674defa88fa

skipif mysql # not compatible
query I rowsort label-506
SELECT ALL - + 52 / cor0.col0 FROM tab1, tab0 AS cor0
----
9 values hashing to ccd77e2770d5a834e59c1674defa88fa

query I rowsort
SELECT + - cor0.col0 * + col2 * - col1 + col1 FROM tab2 AS cor0
----
119711
51051
5890

query I rowsort
SELECT col1 * col1 + + col0 * col1 * col2 FROM tab0 AS cor0
----
12804
672399
75508

query I rowsort
SELECT - col1 * col1 * - col0 + - cor0.col1 AS col2 FROM tab2 AS cor0
----
22814
271459
6696

onlyif mysql # use DIV operator for integer division
query I rowsort label-510
SELECT - cor0.col0 DIV col1 + + col2 * + col0 * ( - col2 ) AS col0 FROM tab0 AS cor0
----
-26136
-35
-598436

skipif mysql # not compatible
query I rowsort label-510
SELECT - cor0.col0 / col1 + + col2 * + col0 * ( - col2 ) AS col0 FROM tab0 AS cor0
----
-26136
-35
-598436

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

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

query I rowsort
SELECT - col1 * - 67 FROM tab0 AS cor0
----
5762
6097
6499

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col2 + col0 * + col0 col1 FROM tab2 AS cor0
----
238
8112
9243

onlyif mysql # use DIV operator for integer division
query I rowsort label-514
SELECT DISTINCT + 73 DIV + col0 FROM tab0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-514
SELECT DISTINCT + 73 / + col0 FROM tab0
----
0
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-515
SELECT DISTINCT - col0 * col1 DIV 91 col0 FROM tab1 AS cor0
----
-11
-7
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-515
SELECT DISTINCT - col0 * col1 / 91 col0 FROM tab1 AS cor0
----
-11
-7
0

query I rowsort
SELECT DISTINCT + + 76 FROM tab1 cor0
----
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col2 col0 FROM tab2 AS cor0
----
-189
-2028
-3002

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

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

query I rowsort
SELECT DISTINCT + tab2.col0 + + 68 + - col0 * col2 AS col0 FROM tab2
----
-114
-1882
-2855

query I rowsort
SELECT DISTINCT - 11 * col0 + col1 FROM tab2 AS cor0
----
-46
-799
-852

query I rowsort
SELECT 78 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

query I rowsort
SELECT DISTINCT - ( col1 ) * ( + col2 * tab0.col1 ) FROM tab0
----
-244068
-679042
-9409

query I rowsort
SELECT - 61 - col1 FROM tab1
----
-71
-74
-87

query I rowsort
SELECT ALL + 73 FROM tab0
----
73
73
73

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

query I rowsort
SELECT ALL 66 * - cor0.col1 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to e8ed9bc195fc77a7c9e3c4fd7c2b570e

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-531
SELECT ALL + 91 DIV cor0.col2 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to 56389a442bcba9c72653c4f5f0199e5b

skipif mysql # not compatible
query I rowsort label-531
SELECT ALL + 91 / cor0.col2 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to 56389a442bcba9c72653c4f5f0199e5b

query I rowsort
SELECT + col2 * - col2 + col0 * col0 + col0 AS col0 FROM tab2 AS cor0
----
-673
4876
5486

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

query I rowsort
SELECT col0 + 54 * col0 FROM tab0
----
1320
1925
4895

query I rowsort
SELECT ALL - col1 * col0 - - col1 AS col1 FROM tab0
----
-1978
-3298
-8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-536
SELECT tab2.col1 + + CAST( ( col1 ) * 10 AS SIGNED ) FROM tab2
----
187
341
649

skipif mysql # not compatible
query I rowsort label-536
SELECT tab2.col1 + + CAST ( ( col1 ) * 10 AS INTEGER ) FROM tab2
----
187
341
649

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

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

skipif mysql # not compatible
query I rowsort label-538
SELECT 70 / + cor0.col0 FROM tab1 AS cor0
----
0
1
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 26 + - col2 + col1 col2 FROM tab0 AS cor0
----
2289
2375
2618

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

query I rowsort
SELECT ALL - 93 + - 90 AS col1 FROM tab1 AS cor0
----
-183
-183
-183

query I rowsort
SELECT DISTINCT 32 * - col0 FROM tab0 AS cor0
----
-1120
-2848
-768

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

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

query I rowsort
SELECT - - col0 + + 65 + + col1 * - 95 AS col1 FROM tab1 AS cor0
----
-1090
-2402
-821

query I rowsort
SELECT DISTINCT + + col2 + 47 * cor0.col0 FROM tab1 AS cor0
----
195
3065
3856

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

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

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

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

query I rowsort
SELECT ( col0 ) * tab0.col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT + col2 + 6 * col0 FROM tab2
----
494
512
69

query I rowsort
SELECT DISTINCT + ( 46 * col1 ) + ( col1 ) AS col0 FROM tab1
----
1222
470
611

query I rowsort
SELECT - 62 * + 45 AS col0 FROM tab2
----
-2790
-2790
-2790

query I rowsort
SELECT DISTINCT + 73 + - 51 AS col0 FROM tab0
----
22

query I rowsort
SELECT + 38 + + col2 + tab2.col2 FROM tab2
----
114
90
92

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

skipif mysql # not compatible
query I rowsort
SELECT ALL - + CAST ( 45 AS REAL ) * - col0 + - col0 * col0 FROM tab1 AS cor0
----
-1216
-2800
126

query I rowsort
SELECT ALL + - 65 + - 31 AS col0 FROM tab2 AS cor0
----
-96
-96
-96

query I rowsort
SELECT DISTINCT 31 + col1 + col1 AS col1 FROM tab0 AS cor0
----
203
213
225

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - col2 col0 FROM tab0 cor0
----
-119
-173
-98

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

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

query I rowsort
SELECT DISTINCT + - col2 + + col2 * + 0 FROM tab1 cor0
----
-54
-57
-96

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

query I rowsort
SELECT DISTINCT + 8 + - col0 * col2 FROM tab0 AS cor0
----
-27
-7290
-784

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

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

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

query I rowsort
SELECT + 45 AS col0 FROM tab1 AS cor0
----
45
45
45

query I rowsort
SELECT ALL - + 38 * col2 AS col2 FROM tab0 AS cor0
----
-1254
-3116
-38

query I rowsort
SELECT cor0.col2 * col2 * + 86 + cor0.col1 AS col0 FROM tab2 AS cor0
----
124201
58195
62725

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

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-576
SELECT ALL + col2 * CAST( + 64 * col1 AS SIGNED ) - - 71 AS col0 FROM tab2 cor0
----
41415
53639
98247

skipif mysql # not compatible
query I rowsort label-576
SELECT ALL + col2 * CAST ( + 64 * col1 AS INTEGER ) - - 71 AS col0 FROM tab2 cor0
----
41415
53639
98247

query I rowsort
SELECT + col0 + - 15 AS col2 FROM tab2 AS cor0
----
-8
63
64

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

query I rowsort
SELECT ALL + - col2 + - ( col0 ) + col0 AS col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + col1 * + 29 - col1 FROM tab1 AS cor0
----
280
364
728

query I rowsort
SELECT DISTINCT - col2 - + 5 AS col2 FROM tab0 AS cor0
----
-38
-6
-87

query I rowsort
SELECT ALL + col2 + - 92 AS col2 FROM tab2 AS cor0
----
-54
-65
-66

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

query I rowsort
SELECT DISTINCT + col1 + - col0 + - col0 * + col1 FROM tab2 cor0
----
-1405
-193
-4621

query I rowsort
SELECT ALL - col1 + 69 AS col2 FROM tab1 AS cor0
----
43
56
59

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

skipif mysql # not compatible
query I rowsort label-586
SELECT - cor0.col0 + + CAST ( col1 AS INTEGER ) * col1 AS col1 FROM tab2 AS cor0
----
210
3403
954

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 * 91 + ( - col0 ) col1 FROM tab1 AS cor0
----
270
5760
7200

query I rowsort
SELECT DISTINCT - ( + ( col2 ) ) + 53 FROM tab0 AS cor0
----
-29
20
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-589
SELECT ( + 18 ) DIV + col1 - col2 * - col1 AS col1 FROM tab2 AS cor0
----
1534
647
837

skipif mysql # not compatible
query I rowsort label-589
SELECT ( + 18 ) / + col1 - col2 * - col1 AS col1 FROM tab2 AS cor0
----
1534
647
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-590
SELECT DISTINCT + ( 31 ) + + col2 DIV - col1 - 83 AS col2 FROM tab2 AS cor0
----
-52
-54

skipif mysql # not compatible
query I rowsort label-590
SELECT DISTINCT + ( 31 ) + + col2 / - col1 - 83 AS col2 FROM tab2 AS cor0
----
-52
-54

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

query I rowsort
SELECT + col2 - - 6 AS col2 FROM tab2
----
32
33
44

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

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

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

query I rowsort
SELECT ALL - - col1 * - col1 + + ( cor0.col1 ) FROM tab2 AS cor0
----
-272
-3422
-930

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-598
SELECT ALL + + 19 + col0 DIV 17 AS col0 FROM tab1 AS cor0
----
19
22
23

skipif mysql # not compatible
query I rowsort label-598
SELECT ALL + + 19 + col0 / 17 AS col0 FROM tab1 AS cor0
----
19
22
23

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

query I rowsort
SELECT DISTINCT 56 AS col0 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
56

query I rowsort
SELECT tab2.col0 + col2 * - col2 AS col1 FROM tab2
----
-1365
-598
-722

query I rowsort
SELECT + 8 * 24 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 2694be6e3557cfde97d42d0dbe9df366

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

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

query I rowsort
SELECT + col0 + col1 + + col2 * + 9 AS col2 FROM tab2 AS cor0
----
281
371
438

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

skipif mysql # not compatible
query I rowsort label-606
SELECT + CAST ( col1 AS INTEGER ) FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - cor1.col0 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
-24
-35
-89

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

query I rowsort
SELECT DISTINCT ( cor0.col2 ) AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1, tab2 AS cor2
----
54
57
96

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

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

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

query I rowsort
SELECT ALL - 24 + 82 * - cor0.col0 - 32 * + 47 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 0ceb4b7a5708d04dd58697c03f87470d

query I rowsort
SELECT ALL + col0 + 37 AS col1 FROM tab1
----
101
117
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col1 * + tab2.col0 col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT ALL - 29 * ( + col1 ) FROM tab0
----
-2494
-2639
-2813

query I rowsort
SELECT ( 37 ) FROM tab1
----
37
37
37

query I rowsort
SELECT 65 * - col1 * tab0.col0 AS col0 FROM tab0
----
-134160
-220675
-526435

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

skipif mysql # not compatible
query I rowsort label-619
SELECT + + CAST ( NULL AS REAL ) / + 66 + - col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

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

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

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

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

query I rowsort
SELECT 25 * col0 AS col1 FROM tab0
----
2225
600
875

query I rowsort
SELECT + 26 * 78 FROM tab2
----
2028
2028
2028

query I rowsort
SELECT - 85 * ( col2 ) AS col1 FROM tab0
----
-2805
-6970
-85

query I rowsort
SELECT ALL - ( + 89 ) FROM tab1, tab2 cor0 CROSS JOIN tab2
----
27 values hashing to c36e597b7bc5727536f5bb580e6cebbc

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

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

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

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

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

query I rowsort
SELECT DISTINCT 15 + - 19 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 10 * + 65 col2 FROM tab2
----
-16900
-17550
-24700

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

query I rowsort
SELECT DISTINCT col0 + + 65 FROM tab1
----
129
145
68

query I rowsort
SELECT DISTINCT col1 * + 26 + - col0 FROM tab2
----
1456
363
799

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

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

query I rowsort
SELECT DISTINCT - col2 * ( + col1 * col0 ) + - col0 * 50 + + col0 FROM tab2 AS cor0
----
-123474
-54905
-6202

onlyif mysql # use DIV operator for integer division
query I rowsort label-639
SELECT ALL + col2 * col2 DIV + col0 FROM tab2 AS cor0
----
104
18
8

skipif mysql # not compatible
query I rowsort label-639
SELECT ALL + col2 * col2 / + col0 FROM tab2 AS cor0
----
104
18
8

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-641
SELECT col0 * col0 + col0 DIV - col1 FROM tab0 AS cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-641
SELECT col0 * col0 + col0 / - col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ( - col0 ) + + cor0.col2 * - col0 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT ( 65 ) * col0 * ( + col2 + + col1 ) FROM tab2
----
26390
282425
430950

query I rowsort
SELECT col1 + - 58 + - cor0.col0 * - col2 FROM tab0 AS cor0
----
7331
74
820

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

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

query I rowsort
SELECT col0 + + col1 * - col2 + cor0.col2 FROM tab2 AS cor0
----
-1430
-529
-803

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

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

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

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

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

query I rowsort
SELECT + 36 AS col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 4d1892e880125dc90345721151acb22c

query I rowsort
SELECT DISTINCT col2 * + 33 FROM tab0 AS cor0
----
1089
2706
33

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 99 + - col1 + col0 * 99 col2 FROM tab1 AS cor0
----
370
6425
8006

query I rowsort
SELECT ALL - col2 * 60 * - col0 + - col2 + - 68 AS col2 FROM tab2 cor0
----
11245
121586
180014

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

query I rowsort
SELECT DISTINCT 58 + col1 FROM tab1 AS cor0
----
68
71
84

query I rowsort
SELECT - ( - col0 ) AS col1 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-660
SELECT DISTINCT ( - 79 ) + + cor0.col0 - CAST( - col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-41
17
58

skipif mysql # not compatible
query I rowsort label-660
SELECT DISTINCT ( - 79 ) + + cor0.col0 - CAST ( - col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-41
17
58

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

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

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

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

query I rowsort
SELECT + ( 44 ) FROM tab0, tab2 AS cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT col2 - col1 * - 66 AS col0 FROM tab2 AS cor0
----
1160
2073
3920

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

query I rowsort
SELECT col2 + - col1 - - 53 AS col1 FROM tab1 AS cor0
----
100
136
81

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

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

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

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

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

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

query I rowsort
SELECT 89 * + col0 AS col1 FROM tab1 AS cor0
----
267
5696
7120

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

query I rowsort
SELECT 65 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-679
SELECT tab0.col1 / + tab0.col2 col2 FROM tab0
----
1
2
97

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

query I rowsort
SELECT DISTINCT + ( + 55 ) FROM tab2, tab0, tab0 cor0
----
55

query I rowsort
SELECT ALL + col0 - col2 * + 10 AS col2 FROM tab1
----
-506
-537
-880

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-685
SELECT DISTINCT + col1 DIV col2 - + 14 AS col1 FROM tab1
----
-14

skipif mysql # not compatible
query I rowsort label-685
SELECT DISTINCT + col1 / col2 - + 14 AS col1 FROM tab1
----
-14

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

query I rowsort
SELECT + tab1.col1 * tab1.col1 + tab1.col2 - col0 FROM tab1
----
185
727
93

query I rowsort
SELECT ALL col0 * col0 + col2 FROM tab0 AS cor0
----
1226
609
8003

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

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

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

query I rowsort
SELECT + cor0.col1 * - ( + col0 + + col0 ) * ( - col0 ) FROM tab2 AS cor0
----
212194
3038
717912

query I rowsort
SELECT - - col1 + + 74 + col2 AS col2 FROM tab0 AS cor0
----
172
193
247

skipif mysql # not compatible
query I rowsort
SELECT ALL col1 + - col2 + CAST ( - 95 AS REAL ) * col1 FROM tab0
----
-8117
-8636
-9119

query I rowsort
SELECT 86 + col2 AS col2 FROM tab2
----
112
113
124

query I rowsort
SELECT col0 + col2 + + col2 FROM tab1
----
111
178
272

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

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

query I rowsort
SELECT DISTINCT - col0 + 24 FROM tab1 AS cor0
----
-40
-56
21

query I rowsort
SELECT DISTINCT - - col2 + col2 * - 4 FROM tab2 AS cor0
----
-114
-78
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + 2 + col0 col1 FROM tab1 AS cor0
----
192
240
9

query I rowsort
SELECT + col1 - ( - 83 ) * - col0 FROM tab0 AS cor0
----
-1906
-2808
-7296

query I rowsort
SELECT - + col1 * + col1 + + 52 + - col0 AS col1 FROM tab0 AS cor0
----
-7368
-8318
-9392

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

query I rowsort
SELECT col1 + + ( - col1 ) * col1 FROM tab2 AS cor0
----
-272
-3422
-930

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

query I rowsort
SELECT ALL - col2 * 79 AS col0 FROM tab1 AS cor0
----
-4266
-4503
-7584

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

query I rowsort
SELECT - col0 - - 91 FROM tab1 cor0
----
11
27
88

query I rowsort
SELECT + 17 + + col2 AS col0 FROM tab1
----
113
71
74

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

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

query I rowsort
SELECT DISTINCT + + col1 * 97 + - cor0.col0 + ( 32 * col1 ) FROM tab1 AS cor0
----
1226
1597
3351

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-713
SELECT DISTINCT + CAST( - 58 AS SIGNED ) + col2 AS col1 FROM tab2 cor0
----
-20
-31
-32

skipif mysql # not compatible
query I rowsort label-713
SELECT DISTINCT + CAST ( - 58 AS INTEGER ) + col2 AS col1 FROM tab2 cor0
----
-20
-31
-32

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

query I rowsort
SELECT + 39 AS col0 FROM tab0
----
39
39
39

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

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

query I rowsort
SELECT ALL + ( - cor0.col0 ) * col1 * 2 + + col1 AS col2 FROM tab0 AS cor0
----
-16107
-4042
-6693

query I rowsort
SELECT ALL - 80 + - col1 * 30 FROM tab0 AS cor0
----
-2660
-2810
-2990

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

skipif mysql # not compatible
query I rowsort label-720
SELECT + col2 + - col1 / + col0 FROM tab2 AS cor0
----
23
26
38

query I rowsort
SELECT ALL - - 90 * col0 * col1 + 21 AS col0 FROM tab0 AS cor0
----
185781
305571
728931

onlyif mysql # use DIV operator for integer division
query I rowsort label-722
SELECT ALL - col1 DIV 33 FROM tab2
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-722
SELECT ALL - col1 / 33 FROM tab2
----
-1
0
0

query I rowsort
SELECT + tab0.col0 AS col2 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0, tab0 cor1, tab0 cor2
----
972 values hashing to 8b4fcda7f1ca76bad7c7d728f54a51e0

query I rowsort
SELECT DISTINCT + + 16 + - col0 FROM tab2 AS cor0
----
-62
-63
9

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

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

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

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

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-734
SELECT - ( col2 ) * col0 / + col2 AS col1 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT col1 + - col0 * - col0 * col0 FROM tab2 AS cor0
----
374
474611
493056

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

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

query I rowsort
SELECT + 86 + - col0 + col2 AS col2 FROM tab0 AS cor0
----
52
79
95

query I rowsort
SELECT ALL - - 90 + col0 * col1 FROM tab0 AS cor0
----
2154
3485
8189

onlyif mysql # use DIV operator for integer division
query I rowsort label-740
SELECT + 22 + - col2 * col2 DIV - col0 FROM tab2 AS cor0
----
126
30
40

skipif mysql # not compatible
query I rowsort label-740
SELECT + 22 + - col2 * col2 / - col0 FROM tab2 AS cor0
----
126
30
40

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

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

query I rowsort
SELECT + col2 * col0 + + col1 + + col0 FROM tab1 AS cor0
----
191
3722
7773

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

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

query I rowsort
SELECT col0 * + col2 + col2 * + col2 + col1 * col2 FROM tab1
----
18144
4482
7467

query I rowsort
SELECT DISTINCT col2 + + col1 + + col0 AS col0 FROM tab0
----
133
143
262

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

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL NOT IN ( - col1 / tab1.col2 )
----

query I rowsort
SELECT col1 * col1 AS col2 FROM tab2 WHERE NULL > ( - col0 )
----

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

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

query I rowsort
SELECT + col0 FROM tab0 WHERE NOT NULL = ( NULL )
----

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

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

query I rowsort
SELECT col0 * col2 + + col0 + - col2 AS col1 FROM tab1
----
111
3655
7664

query III rowsort
SELECT * FROM tab2 WHERE NOT ( + col1 + + col0 * col0 ) IN ( + col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

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

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

query I rowsort
SELECT ALL col0 + - col1 + - col2 * + col0 * + tab0.col1 AS col0 FROM tab0
----
-3457
-664120
-68174

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

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

query I rowsort
SELECT ALL 62 + - col1 * + 55 FROM tab2 cor0
----
-1643
-3183
-873

query I rowsort
SELECT + col1 FROM tab1 WHERE NOT ( - col0 ) BETWEEN col1 AND NULL
----
10
13
26

query I rowsort
SELECT DISTINCT - col1 * - col1 + col2 FROM tab0
----
7429
8363
9410

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

query I rowsort
SELECT col1 + col0 AS col0 FROM tab1 WHERE NOT ( NULL ) = NULL
----

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

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

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

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL <> + col0
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * tab0.col0 - - col0 * tab0.col1 * - col1 col2 FROM tab0
----
-178296
-329350
-744307

query I rowsort
SELECT ALL + col0 + col1 * - col0 FROM tab1
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-774
SELECT col2 - col0 DIV + col1 AS col0 FROM tab1
----
51
54
90

skipif mysql # not compatible
query I rowsort label-774
SELECT col2 - col0 / + col1 AS col0 FROM tab1
----
51
54
90

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

query I rowsort
SELECT col1 + - col2 FROM tab2 WHERE NOT + tab2.col1 <> ( - col1 * col0 - col1 )
----

query I rowsort
SELECT DISTINCT col1 * - col0 * + col0 AS col2 FROM tab0 WHERE NOT NULL BETWEEN - col1 * col2 AND NULL
----

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

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

query I rowsort
SELECT DISTINCT col1 * col0 - tab2.col0 FROM tab2
----
1264
210
4524

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

query I rowsort
SELECT - 58 - col2 FROM tab1
----
-112
-115
-154

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-784
SELECT col2 DIV col0 + + col1 + + 36 AS col2 FROM tab0 AS cor0
----
123
127
133

skipif mysql # not compatible
query I rowsort label-784
SELECT col2 / col0 + + col1 + + 36 AS col2 FROM tab0 AS cor0
----
123
127
133

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

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

query I rowsort
SELECT DISTINCT - tab0.col1 * tab0.col1 + col2 FROM tab0
----
-7363
-8199
-9408

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + cor0.col0 + col1 * - 4 col2 FROM tab1 AS cor0
----
-104
-40
-52

query I rowsort
SELECT DISTINCT col0 * + col0 + 18 + - col1 AS col0 FROM tab0 AS cor0
----
1146
508
7848

query I rowsort
SELECT DISTINCT 63 + col1 * - 20 FROM tab0
----
-1657
-1757
-1877

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col0 + + col2 + - 50 * + cor0.col1 col0 FROM tab0 cor0
----
-12389
-4843
-6074

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

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

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

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

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

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

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

query I rowsort
SELECT ALL - 72 * col2 + - col2 FROM tab0 AS cor0
----
-2409
-5986
-73

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

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

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

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

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

query I rowsort
SELECT DISTINCT - + 76 * 31 - col0 AS col1 FROM tab1 AS cor0
----
-2359
-2420
-2436

query I rowsort
SELECT + col1 + - 29 + - col0 FROM tab1 AS cor0
----
-6
-83
-96

query I rowsort
SELECT - 86 + + col0 FROM tab1 AS cor0
----
-22
-6
-83

query I rowsort
SELECT ALL + - 16 + 91 FROM tab0 AS cor0
----
75
75
75

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

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

query I rowsort
SELECT DISTINCT + 95 + + col1 + + col1 AS col1 FROM tab2 AS cor0
----
129
157
213

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-813
SELECT ALL + 41 * col0 + + col1 DIV col0 AS col1 FROM tab1 AS cor0
----
131
2624
3280

skipif mysql # not compatible
query I rowsort label-813
SELECT ALL + 41 * col0 + + col1 / col0 AS col1 FROM tab1 AS cor0
----
131
2624
3280

query I rowsort
SELECT + + cor0.col0 * 11 FROM tab2 AS cor0
----
77
858
869

query I rowsort
SELECT ALL + 20 AS col0 FROM tab2 cor0
----
20
20
20

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

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

query I rowsort
SELECT ALL col0 - - col2 * col1 FROM tab0
----
132
2862
7551

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-821
SELECT - col2 * col2 - col1 DIV + col2 FROM tab0 AS cor0
----
-1091
-6725
-98

skipif mysql # not compatible
query I rowsort label-821
SELECT - col2 * col2 - col1 / + col2 FROM tab0 AS cor0
----
-1091
-6725
-98

query I rowsort
SELECT + - 4 + + col1 FROM tab1 AS cor0
----
22
6
9

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

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

query I rowsort
SELECT - 65 + - 1 AS col1 FROM tab1
----
-66
-66
-66

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

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

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

query I rowsort
SELECT DISTINCT - col1 + - col0 + + col2 AS col0 FROM tab2
----
-11
-111
-58

query I rowsort
SELECT DISTINCT - + col2 * + 74 FROM tab2 AS cor0
----
-1924
-1998
-2812

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

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

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

query I rowsort
SELECT - col1 + - col1 * - col1 AS col1 FROM tab2
----
272
3422
930

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

skipif mysql # not compatible
query I rowsort label-834
SELECT + tab2.col1 + - col2 * + CAST ( - col0 AS INTEGER ) FROM tab2
----
2087
220
3019

query I rowsort
SELECT DISTINCT - tab2.col0 * cor0.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to a3b44b1349b97a64e1970dbe00e8d983

query I rowsort
SELECT ALL 89 * + col2 + col2 * col0 + + col0 FROM tab1
----
16304
4971
8785

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-837
SELECT DISTINCT col0 + col2 * - CAST( + 15 + col0 AS SIGNED ) AS col2 FROM tab2
----
-2340
-3493
-587

skipif mysql # not compatible
query I rowsort label-837
SELECT DISTINCT col0 + col2 * - CAST ( + 15 + col0 AS INTEGER ) AS col2 FROM tab2
----
-2340
-3493
-587

onlyif mysql # use DIV operator for integer division
query I rowsort label-838
SELECT tab1.col0 DIV col2 - + col0 FROM tab1
----
-3
-63
-80

skipif mysql # not compatible
query I rowsort label-838
SELECT tab1.col0 / col2 - + col0 FROM tab1
----
-3
-63
-80

query I rowsort
SELECT col0 * col1 * 39 + col1 AS col1 FROM tab1
----
24970
3068
40573

query I rowsort
SELECT ALL + + cor0.col0 * + col2 + cor0.col0 FROM tab0 AS cor0
----
70
7387
816

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

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

query I rowsort
SELECT DISTINCT - cor0.col2 * 42 - col0 AS col1 FROM tab1 AS cor0
----
-2271
-2458
-4112

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

query I rowsort
SELECT ALL tab2.col0 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

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

skipif mysql # not compatible
query I rowsort label-846
SELECT DISTINCT cor0.col2 + CAST ( col0 AS INTEGER ) * col0 AS col0 FROM tab1 AS cor0
----
4153
63
6496

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

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

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

query I rowsort
SELECT ALL + - col2 - col0 * + 50 FROM tab1 AS cor0
----
-204
-3257
-4096

query I rowsort
SELECT + col1 * 36 + - col1 * col2 FROM tab1 AS cor0
----
-210
-468
-780

query I rowsort
SELECT + + col0 + - col1 * - 74 FROM tab1 AS cor0
----
1042
1927
804

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-853
SELECT + cor0.col2 * - CAST( - 32 AS SIGNED ) FROM tab1 AS cor0
----
1728
1824
3072

skipif mysql # not compatible
query I rowsort label-853
SELECT + cor0.col2 * - CAST ( - 32 AS INTEGER ) FROM tab1 AS cor0
----
1728
1824
3072

onlyif mysql # use DIV operator for integer division
query I rowsort label-854
SELECT DISTINCT + 37 DIV tab0.col2 + + 16 + - col0 FROM tab0
----
-7
-73
18

skipif mysql # not compatible
query I rowsort label-854
SELECT DISTINCT + 37 / tab0.col2 + + 16 + - col0 FROM tab0
----
-7
-73
18

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

query I rowsort
SELECT ALL col2 * + tab2.col0 * 11 FROM tab2
----
2079
22308
33022

query I rowsort
SELECT col1 + col2 + ( col1 * + col1 ) AS col2 FROM tab0
----
7515
8454
9507

onlyif mysql # use DIV operator for integer division
query I rowsort label-858
SELECT DISTINCT col2 + - col2 DIV + 14 FROM tab2
----
25
26
36

skipif mysql # not compatible
query I rowsort label-858
SELECT DISTINCT col2 + - col2 / + 14 FROM tab2
----
25
26
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-859
SELECT 59 DIV + col0 AS col2 FROM tab2
----
0
0
8

skipif mysql # not compatible
query I rowsort label-859
SELECT 59 / + col0 AS col2 FROM tab2
----
0
0
8

query I rowsort
SELECT + col1 * 94 * col0 FROM tab0
----
194016
319130
761306

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

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

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

query I rowsort
SELECT DISTINCT tab0.col2 * - ( + col0 * - tab0.col0 ) FROM tab0
----
1225
19008
649522

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

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

query I rowsort
SELECT + col0 * + col2 + + 47 AS col2 FROM tab2 AS cor0
----
2075
236
3049

query I rowsort
SELECT DISTINCT + col1 * ( + 77 ) AS col0 FROM tab2 AS cor0
----
1309
2387
4543

query I rowsort
SELECT - col1 * col0 + col0 * cor0.col2 FROM tab1 AS cor0
----
3008
6640
84

query I rowsort
SELECT ALL col2 + - cor0.col1 * + 57 FROM tab0 AS cor0
----
-4869
-5105
-5528

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

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

skipif mysql # not compatible
query I rowsort label-871
SELECT CAST ( NULL AS INTEGER ) AS col2 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT col2 * - col0 + col0 * col0 FROM tab1
----
-1280
-153
448

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * - 34 col1 FROM tab2 AS cor0
----
1292
884
918

query I rowsort
SELECT + col2 * - 62 AS col2 FROM tab0 AS cor0
----
-2046
-5084
-62

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

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

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

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

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

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

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

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

query I rowsort
SELECT + - 93 * - col0 + col0 * cor0.col2 FROM tab0 AS cor0
----
15575
3024
3290

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

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

query I rowsort
SELECT DISTINCT - 44 * - tab2.col0 AS col2 FROM tab2
----
308
3432
3476

query I rowsort
SELECT 15 AS col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

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

query I rowsort
SELECT ALL - 40 + - 91 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to e9fc6b8f48d9b7b1ab7d24aa342273b9

query I rowsort
SELECT DISTINCT tab2.col0 * - 90 + 90 AS col1 FROM tab2, tab0 AS cor0
----
-540
-6930
-7020

onlyif mysql # use DIV operator for integer division
query I rowsort label-889
SELECT - - 96 DIV + col0 FROM tab0 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-889
SELECT - - 96 / + col0 FROM tab0 AS cor0
----
1
2
4

query I rowsort
SELECT 47 + - col1 FROM tab2 AS cor0
----
-12
16
30

query I rowsort
SELECT - col2 * + col1 - 61 FROM tab1 AS cor0
----
-1309
-1465
-631

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

query I rowsort
SELECT col1 + - cor0.col0 + 35 * - col1 * col2 AS col1 FROM tab0 AS cor0
----
-261168
-3333
-99268

query I rowsort
SELECT ALL 70 FROM tab0, tab2 cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

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

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

query I rowsort
SELECT DISTINCT + 69 + - cor0.col0 FROM tab1 cor0
----
-11
5
66

query I rowsort
SELECT ALL ( - col2 ) AS col0 FROM tab1
----
-54
-57
-96

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

query I rowsort
SELECT + col2 * - col1 + 68 * col0 FROM tab1 AS cor0
----
-1200
3782
4192

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

query I rowsort
SELECT ALL cor0.col1 * - col2 + + col1 * 63 FROM tab0 AS cor0
----
-1729
2580
6014

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

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

query I rowsort
SELECT ALL 74 * cor0.col0 FROM tab1 AS cor0
----
222
4736
5920

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

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

query I rowsort
SELECT DISTINCT ( col1 ) * - col2 * - ( col1 ) + - tab0.col2 + + 57 FROM tab0
----
244092
679017
9465

onlyif mysql # use DIV operator for integer division
query I rowsort label-909
SELECT 7 DIV col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-909
SELECT 7 / col1 FROM tab1
----
0
0
0

query I rowsort
SELECT cor1.col1 AS col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

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

skipif mysql # not compatible
query I rowsort label-911
SELECT DISTINCT CAST ( - ( + col1 ) AS INTEGER ) * col0 + col2 * + col1 FROM tab1 AS cor0
----
-70
1326
208

query I rowsort
SELECT DISTINCT + cor0.col2 + + 75 FROM tab1 AS cor0
----
129
132
171

query I rowsort
SELECT ALL + col0 + ( col2 ) * - col2 AS col0 FROM tab2 AS cor0
----
-1365
-598
-722

onlyif mysql # use DIV operator for integer division
query I rowsort label-914
SELECT 41 * cor0.col1 - col1 DIV col1 FROM tab1 cor0
----
1065
409
532

skipif mysql # not compatible
query I rowsort label-914
SELECT 41 * cor0.col1 - col1 / col1 FROM tab1 cor0
----
1065
409
532

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

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

query I rowsort
SELECT + 7 FROM tab2, tab0 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to bd991c690468eea3ef45a96817ca3617

query I rowsort
SELECT - 15 * col1 AS col2 FROM tab0
----
-1290
-1365
-1455

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

skipif mysql # not compatible
query I rowsort label-919
SELECT + col0 + - col2 * + CAST ( + col2 AS INTEGER ) AS col2 FROM tab0
----
-1065
-6635
34

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

query I rowsort
SELECT ALL - col2 * + col1 + col2 + col1 AS col2 FROM tab2
----
-1449
-591
-779

query I rowsort
SELECT DISTINCT + col0 + col2 + - 50 FROM tab0 AS cor0
----
-14
121
7

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

query I rowsort
SELECT col1 * - 73 AS col1 FROM tab0 AS cor0
----
-6278
-6643
-7081

query I rowsort
SELECT - col0 * 91 + 98 AS col1 FROM tab1 AS cor0
----
-175
-5726
-7182

onlyif mysql # use DIV operator for integer division
query I rowsort label-926
SELECT ALL 33 DIV tab0.col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-926
SELECT ALL 33 / tab0.col1 FROM tab0
----
0
0
0

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

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

skipif mysql # not compatible
query I rowsort label-928
SELECT CAST ( tab1.col0 AS INTEGER ) AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * - 78 col1 FROM tab2 AS cor0
----
546
6084
6162

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

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

query I rowsort
SELECT ALL + - col2 + 21 AS col1 FROM tab1 AS cor0
----
-33
-36
-75

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

query I rowsort
SELECT + 86 + - col1 AS col1 FROM tab2 AS cor0
----
27
55
69

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-937
SELECT DISTINCT col1 + col1 DIV - col1 FROM tab2 cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-937
SELECT DISTINCT col1 + col1 / - col1 FROM tab2 cor0
----
16
30
58

query I rowsort
SELECT + col2 + - 43 * + col0 AS col2 FROM tab2
----
-274
-3328
-3359

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

query I rowsort
SELECT - 92 + col0 FROM tab1 AS cor0
----
-12
-28
-89

query I rowsort
SELECT DISTINCT - + 7 * - col2 FROM tab1 AS cor0
----
378
399
672

onlyif mysql # use DIV operator for integer division
query I rowsort label-942
SELECT + 57 * col1 DIV col1 - col2 AS col2 FROM tab0 AS cor0
----
-25
24
56

skipif mysql # not compatible
query I rowsort label-942
SELECT + 57 * col1 / col1 - col2 AS col2 FROM tab0 AS cor0
----
-25
24
56

query I rowsort
SELECT DISTINCT col0 * - col2 + 1 + col0 * col1 FROM tab1 AS cor0
----
-3007
-6639
-83

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-946
SELECT CAST( - ( + col1 ) AS SIGNED ) * col1 + - 74 AS col2 FROM tab1
----
-174
-243
-750

skipif mysql # not compatible
query I rowsort label-946
SELECT CAST ( - ( + col1 ) AS INTEGER ) * col1 + - 74 AS col2 FROM tab1
----
-174
-243
-750

query I rowsort
SELECT ALL - 63 - col0 AS col2 FROM tab1
----
-127
-143
-66

query I rowsort
SELECT DISTINCT col1 * col0 + 73 FROM tab0 AS cor0
----
2137
3468
8172

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + col0 * cor0.col1 col1 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-953
SELECT ALL - col1 DIV col0 + col0 FROM tab1
----
-5
64
80

skipif mysql # not compatible
query I rowsort label-953
SELECT ALL - col1 / col0 + col0 FROM tab1
----
-5
64
80

query I rowsort
SELECT - 34 * - col1 + col1 * col1 FROM tab2 AS cor0
----
2015
5487
867

query I rowsort
SELECT ALL - ( cor1.col0 ) FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT 20 + + 1 * - col0 AS col0 FROM tab0 AS cor0
----
-15
-4
-69

query I rowsort
SELECT + 25 * + 51 AS col2 FROM tab0 AS cor0
----
1275
1275
1275

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

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

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

query I rowsort
SELECT 12 * - col2 + 82 * 44 FROM tab1 AS cor0
----
2456
2924
2960

query I rowsort
SELECT + col2 + col1 * 20 - col1 FROM tab1 AS cor0
----
247
343
548

query I rowsort
SELECT 7 * col2 + - 12 * cor0.col2 FROM tab1 AS cor0
----
-270
-285
-480

query I rowsort
SELECT DISTINCT + 55 * - col2 FROM tab2
----
-1430
-1485
-2090

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

skipif mysql # not compatible
query I rowsort
SELECT col2 + CAST ( + col2 AS REAL ) FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ALL + 49 AS col0 FROM tab0
----
49
49
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-968
SELECT tab2.col1 DIV col1 + - 23 FROM tab2
----
-22
-22
-22

skipif mysql # not compatible
query I rowsort label-968
SELECT tab2.col1 / col1 + - 23 FROM tab2
----
-22
-22
-22

onlyif mysql # use DIV operator for integer division
query I rowsort label-969
SELECT + col1 * - col0 + 76 DIV + col2 AS col1 FROM tab0
----
-2062
-3319
-8099

skipif mysql # not compatible
query I rowsort label-969
SELECT + col1 * - col0 + 76 / + col2 AS col1 FROM tab0
----
-2062
-3319
-8099

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

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

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

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

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

query I rowsort
SELECT + 71 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

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

skipif mysql # not compatible
query I rowsort label-976
SELECT ALL col0 / + 31 AS col1 FROM tab2
----
0
2
2

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

query I rowsort
SELECT DISTINCT - 85 * cor0.col2 + cor0.col0 FROM tab2 AS cor0
----
-2132
-2288
-3151

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

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

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

query I rowsort
SELECT + cor0.col1 * + 19 FROM tab2, tab0 AS cor0
----
9 values hashing to 5bb85ac8dc21877ff66a0789ba6bef8e

query I rowsort
SELECT col0 - 53 AS col1 FROM tab2
----
-46
25
26

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

query I rowsort
SELECT ALL col0 * 28 FROM tab1
----
1792
2240
84

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

query I rowsort
SELECT ALL + + ( col0 ) * + cor0.col0 - 91 * col2 AS col0 FROM tab2 AS cor0
----
-2408
2783
3718

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

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

query I rowsort
SELECT col1 * - col2 * + 74 FROM tab2
----
-113516
-47804
-61938

onlyif mysql # use DIV operator for integer division
query I rowsort label-991
SELECT DISTINCT + ( + col1 ) DIV 76 AS col0 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-991
SELECT DISTINCT + ( + col1 ) / 76 AS col0 FROM tab0
----
1

query I rowsort
SELECT 70 * col2 FROM tab2
----
1820
1890
2660

query I rowsort
SELECT 88 + + 27 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 8ea29c11e2d920a09e8656cafe5a9642

query I rowsort
SELECT ALL + 87 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

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

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

query I rowsort
SELECT 5 + + 8 * - cor0.col2 AS col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 4f5b3b46b3a77f96ff335a3d1bcf6433

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

query I rowsort
SELECT 95 * 87 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 0875c3a775714f3aea485031f1400713

query I rowsort
SELECT DISTINCT + col0 * + 90 FROM tab2 AS cor0
----
630
7020
7110

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

skipif mysql # not compatible
query I rowsort label-1000
SELECT - col0 / 84 FROM tab1 AS cor0
----
0
0
0

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

skipif mysql # not compatible
query I rowsort label-1001
SELECT ALL + col0 / - ( + col2 ) AS col0 FROM tab0 AS cor0
----
-1
-35
0

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

query I rowsort
SELECT ALL + - 86 * - col1 - 35 AS col2 FROM tab0 cor0
----
7361
7791
8307

query I rowsort
SELECT - + 93 * - cor0.col0 + cor0.col2 FROM tab0 AS cor0
----
2265
3256
8359

query I rowsort
SELECT DISTINCT - - 63 * + col2 + col2 - cor0.col2 * + cor0.col0 FROM tab0 cor0
----
-2050
1320
29

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

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

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

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

query I rowsort
SELECT ALL - - cor0.col2 + - col0 + col2 * 76 * col2 FROM tab2 AS cor0
----
109703
51324
55424

onlyif mysql # use DIV operator for integer division
query I rowsort label-1009
SELECT DISTINCT - - 82 + + cor0.col1 * ( col0 ) + + col2 * - col1 DIV + col1 AS col2 FROM tab1 AS cor0
----
1026
106
665

skipif mysql # not compatible
query I rowsort label-1009
SELECT DISTINCT - - 82 + + cor0.col1 * ( col0 ) + + col2 * - col1 / + col1 AS col2 FROM tab1 AS cor0
----
1026
106
665

query I rowsort
SELECT ALL 53 + tab1.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to d448f8a080de06f3f17a0e6820fa1d18

query I rowsort
SELECT + 73 * - col1 + - col2 * 84 AS col0 FROM tab0 AS cor0
----
-13531
-7165
-9050

query I rowsort
SELECT ALL + 10 + col0 AS col2 FROM tab0
----
34
45
99

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

query I rowsort
SELECT DISTINCT col2 * col1 * - col1 + 7 * - col2 FROM tab1 AS cor0
----
-16896
-36882
-6099

query I rowsort
SELECT DISTINCT col1 + - col2 * cor0.col1 * + col1 FROM tab0 AS cor0
----
-243982
-678951
-9312

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

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

query I rowsort
SELECT ALL - cor0.col1 * col2 * col1 + 75 FROM tab0 AS cor0
----
-243993
-678967
-9334

query I rowsort
SELECT + col1 * ( 21 ) FROM tab0 AS cor0
----
1806
1911
2037

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

query I rowsort
SELECT DISTINCT col0 + + 25 FROM tab0 cor0
----
114
49
60

query I rowsort
SELECT DISTINCT - 5 * + 97 AS col2 FROM tab2 AS cor0
----
-485

query I rowsort
SELECT ALL col2 - + 33 AS col0 FROM tab0 cor0
----
-32
0
49

query I rowsort
SELECT ALL + - cor0.col1 + - ( + 87 ) FROM tab1, tab0 AS cor0
----
9 values hashing to 4f310bad2aadaff2179e45cbdc05f935

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

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

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

query I rowsort
SELECT DISTINCT - 52 + + col2 FROM tab1
----
2
44
5

query I rowsort
SELECT - ( + 88 ) FROM tab1
----
-88
-88
-88

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

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

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

query I rowsort
SELECT ALL ( - 88 ) * - col1 + ( + cor0.col0 ) FROM tab2 AS cor0
----
1575
2735
5270

onlyif mysql # use DIV operator for integer division
query I rowsort label-1034
SELECT col1 + + col2 DIV + col1 AS col1 FROM tab1 AS cor0
----
15
20
28

skipif mysql # not compatible
query I rowsort label-1034
SELECT col1 + + col2 / + col1 AS col1 FROM tab1 AS cor0
----
15
20
28

query I rowsort
SELECT 59 + + col0 FROM tab2
----
137
138
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-1036
SELECT ALL col2 + - col2 DIV + tab1.col2 FROM tab1
----
53
56
95

skipif mysql # not compatible
query I rowsort label-1036
SELECT ALL col2 + - col2 / + tab1.col2 FROM tab1
----
53
56
95

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

query I rowsort
SELECT DISTINCT + col2 * - 82 FROM tab1 AS cor0
----
-4428
-4674
-7872

query I rowsort
SELECT ALL + ( + 67 ) * col1 FROM tab1 cor0
----
1742
670
871

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col1 + + col0 col1 FROM tab2 AS cor0
----
11
111
58

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
17
31
59

query I rowsort
SELECT + - 75 * col0 + col0 + col2 * col0 FROM tab2 AS cor0
----
-2844
-329
-3744

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

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

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

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

query I rowsort
SELECT - - 20 * col2 FROM tab1 AS cor0
----
1080
1140
1920

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

query I rowsort
SELECT ALL + col2 + - 82 * + col1 * + tab0.col1 FROM tab0
----
-606439
-678960
-771537

query I rowsort
SELECT DISTINCT - col2 + 62 FROM tab1 cor0
----
-34
5
8

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + 36 col0 FROM tab0 AS cor0
----
-46
3
35

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

query I rowsort
SELECT + - col1 + + ( + 58 ) AS col1 FROM tab0 AS cor0
----
-28
-33
-39

query I rowsort
SELECT DISTINCT cor0.col1 + 85 * + col1 FROM tab1 AS cor0
----
1118
2236
860

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

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

query I rowsort
SELECT DISTINCT - col0 * + 55 AS col1 FROM tab1 AS cor0
----
-165
-3520
-4400

query I rowsort
SELECT + col0 + cor0.col0 * + col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT col0 * + ( + cor0.col2 ) - ( 25 ) * col0 AS col0 FROM tab1 AS cor0
----
2048
5680
87

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

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

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

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

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

query I rowsort
SELECT + + col1 - 12 FROM tab1 AS cor0
----
-2
1
14

query I rowsort
SELECT DISTINCT + 67 * cor0.col0 FROM tab2 AS cor0
----
469
5226
5293

query I rowsort
SELECT - + 21 * col2 FROM tab0 AS cor0
----
-1722
-21
-693

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

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

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

query I rowsort
SELECT + + col2 * - 52 FROM tab0 AS cor0
----
-1716
-4264
-52

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1073
SELECT - col2 - col1 DIV col1 FROM tab1 AS cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-1073
SELECT - col2 - col1 / col1 FROM tab1 AS cor0
----
-55
-58
-97

query I rowsort
SELECT - 91 * 58 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-5285
-5356
-5357

query I rowsort
SELECT - col0 * - 88 - col2 FROM tab0 AS cor0
----
2079
3079
7750

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

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

skipif mysql # not compatible
query I rowsort label-1077
SELECT ALL cor0.col2 / col2 FROM tab0 cor0
----
1
1
1

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1079
SELECT col0 + col1 DIV col0 AS col2 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-1079
SELECT col0 + col1 / col0 AS col2 FROM tab1 AS cor0
----
11
64
80

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

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

query I rowsort
SELECT col1 * 9 FROM tab2 AS cor0
----
153
279
531

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

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

query I rowsort
SELECT - 69 * 96 + cor0.col0 FROM tab0 AS cor0
----
-6535
-6589
-6600

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

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

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

query I rowsort
SELECT DISTINCT + col2 * 28 FROM tab0 cor0
----
2296
28
924

query I rowsort
SELECT DISTINCT + 20 * col1 - col1 * col0 AS col1 FROM tab1 AS cor0
----
-440
-780
442

query I rowsort
SELECT + + ( col2 ) + col0 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - - 32 + col0 * col2 FROM tab0 AS cor0
----
67
7330
824

query I rowsort
SELECT ALL col0 * - ( - col0 * - col0 ) + col1 + col0 AS col1 FROM tab0 AS cor0
----
-13714
-42743
-704789

query I rowsort
SELECT - 51 FROM tab2 cor0
----
-51
-51
-51

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

query I rowsort
SELECT DISTINCT 29 - + ( + col1 ) * col0 FROM tab1 cor0
----
-1011
-49
-611

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1095
SELECT + - ( 85 ) * - col1 + CAST( + col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
1118
2236
860

skipif mysql # not compatible
query I rowsort label-1095
SELECT + - ( 85 ) * - col1 + CAST ( + col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
1118
2236
860

query I rowsort
SELECT + 52 * - 23 + col1 * - 3 FROM tab2 AS cor0
----
-1247
-1289
-1373

query I rowsort
SELECT ALL - col2 + - col2 * col0 * + col2 AS col0 FROM tab2
----
-114114
-5130
-52754

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1099
SELECT + col2 + ( + col1 ) DIV col1 AS col2 FROM tab2
----
27
28
39

skipif mysql # not compatible
query I rowsort label-1099
SELECT + col2 + ( + col1 ) / col1 AS col2 FROM tab2
----
27
28
39

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

query I rowsort
SELECT + + 6 * + 81 FROM tab0 AS cor0
----
486
486
486

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

query I rowsort
SELECT - cor0.col2 + - 68 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ec61defe18e6426dd2c5c0c3e28c7618

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

query I rowsort
SELECT - - 81 * col1 + col0 * + 20 + - col1 FROM tab0 AS cor0
----
7360
8460
9060

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

query I rowsort
SELECT + - 72 + + col2 FROM tab1 AS cor0
----
-15
-18
24

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

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

query I rowsort
SELECT + col1 * cor0.col1 + 35 + ( + col0 ) FROM tab0 AS cor0
----
7455
8405
9479

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

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

query I rowsort
SELECT ALL 66 + - col1 FROM tab2
----
35
49
7

query I rowsort
SELECT + - 26 * col1 + 51 AS col0 FROM tab0 cor0
----
-2185
-2315
-2471

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

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

query I rowsort
SELECT tab0.col0 * + 36 * - col0 FROM tab0
----
-20736
-285156
-44100

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

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

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

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

query I rowsort
SELECT - ( + col2 ) + col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - 21 * col1 + + col2 AS col2 FROM tab0 cor0
----
-1773
-1829
-2036

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 36 col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 AS cor2, tab0 AS cor3
----
36

query I rowsort
SELECT ALL + col2 + 28 + 3 AS col2 FROM tab2
----
57
58
69

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1127
SELECT - col0 * col2 DIV col1 AS col1 FROM tab0 AS cor0
----
-80
-9
0

skipif mysql # not compatible
query I rowsort label-1127
SELECT - col0 * col2 / col1 AS col1 FROM tab0 AS cor0
----
-80
-9
0

query I rowsort
SELECT ALL - + col0 + ( + 61 ) * col0 FROM tab1 cor0
----
180
3840
4800

onlyif mysql # use DIV operator for integer division
query I rowsort label-1129
SELECT DISTINCT - col1 * - ( ( + col0 ) * ( - col0 ) ) + - col0 DIV - CAST( - col2 + col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-118824
-49538
-720799

skipif mysql # not compatible
query I rowsort label-1129
SELECT DISTINCT - col1 * - ( ( + col0 ) * ( - col0 ) ) + - col0 / - CAST ( - col2 + col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-118824
-49538
-720799

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

skipif mysql # not compatible
query I rowsort label-1130
SELECT ALL - col1 / + ( + 83 ) + col2 AS col0 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT - col1 + + ( 96 ) AS col1 FROM tab2 AS cor0
----
37
65
79

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

query I rowsort
SELECT ALL - col2 * 82 * - col2 + + col2 * 97 FROM tab1 AS cor0
----
244350
271947
765024

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1134
SELECT col2 + - CAST( NULL AS SIGNED ) / + 94 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-1134
SELECT col2 + - CAST ( NULL AS INTEGER ) / + 94 col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

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

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

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

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

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

query I rowsort
SELECT ALL 33 * + col0 AS col0 FROM tab1 AS cor0
----
2112
2640
99

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1140
SELECT DISTINCT col2 + - 27 DIV - col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1140
SELECT DISTINCT col2 + - 27 / - col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + ( + col0 ) + - col2 * col0 FROM tab1 AS cor0
----
-159
-3584
-7600

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

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

query I rowsort
SELECT DISTINCT + 66 + - 70 FROM tab0 AS cor0
----
-4

query I rowsort
SELECT ALL 62 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-186
-3968
-4960

query I rowsort
SELECT - - 19 * col2 AS col1 FROM tab0 AS cor0
----
1558
19
627

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1147
SELECT ALL - + ( - col1 ) DIV + col0 + col1 FROM tab0 cor0
----
89
92
99

skipif mysql # not compatible
query I rowsort label-1147
SELECT ALL - + ( - col1 ) / + col0 + col1 FROM tab0 cor0
----
89
92
99

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

query I rowsort
SELECT - col2 * col0 - col2 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
-2704
-4446
-918

query I rowsort
SELECT DISTINCT - col1 + - col1 * 60 AS col0 FROM tab1 AS cor0
----
-1586
-610
-793

onlyif mysql # use DIV operator for integer division
query I rowsort label-1151
SELECT DISTINCT + col2 + col2 DIV - 15 col1 FROM tab1 AS cor0
----
51
54
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1151
SELECT DISTINCT + col2 + col2 / - 15 col1 FROM tab1 AS cor0
----
51
54
90

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1154
SELECT cor0.col2 DIV - col2 + ( ( col1 ) ) FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-1154
SELECT cor0.col2 / - col2 + ( ( col1 ) ) FROM tab0 AS cor0
----
85
90
96

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

query I rowsort
SELECT - + cor0.col1 * - col0 - ( - col1 ) * - col1 FROM tab0 AS cor0
----
-182
-5332
-6014

query I rowsort
SELECT - + col2 - col0 * - 68 FROM tab0 AS cor0
----
1599
2379
5970

query I rowsort
SELECT 84 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT DISTINCT ( + col2 ) + 94 * 47 * col2 AS col0 FROM tab0 AS cor0
----
145827
362358
4419

query I rowsort
SELECT ALL - 97 + + col0 * ( + col1 ) * + col0 FROM tab0 AS cor0
----
118728
49439
720714

query I rowsort
SELECT ALL col0 * col0 + + col2 * + col0 AS col2 FROM tab1 AS cor0
----
14080
171
7744

query I rowsort
SELECT col2 + 4 * col1 AS col1 FROM tab0 AS cor0
----
377
389
446

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

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

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

query I rowsort
SELECT col1 * col1 + - 56 * - col1 * col1 FROM tab0
----
421572
472017
536313

query I rowsort
SELECT col0 * - tab0.col0 + ( + col1 ) * col1 + + ( + 28 ) FROM tab0
----
388
6848
8212

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1169
SELECT ALL + col0 + col0 / col1 col0 FROM tab2 AS cor0
----
7
79
83

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

query I rowsort
SELECT DISTINCT + 59 FROM tab0 cor0 CROSS JOIN tab1 AS cor1
----
59

query I rowsort
SELECT - + 26 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 47d0574274146de273829785364ada39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1173
SELECT DISTINCT col2 - - tab1.col0 * + CAST( ( + col0 ) + - col2 AS SIGNED ) AS col1 FROM tab1
----
-1184
-99
505

skipif mysql # not compatible
query I rowsort label-1173
SELECT DISTINCT col2 - - tab1.col0 * + CAST ( ( + col0 ) + - col2 AS INTEGER ) AS col1 FROM tab1
----
-1184
-99
505

query I rowsort
SELECT DISTINCT - col1 * - col0 + - col1 * - col1 AS col2 FROM tab1
----
1209
740
754

query I rowsort
SELECT DISTINCT - col2 + - 61 FROM tab2
----
-87
-88
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-1176
SELECT col2 DIV ( col2 * col0 ) AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1176
SELECT col2 / ( col2 * col0 ) AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - tab1.col0 + + col0 * col0 AS col1 FROM tab1
----
4032
6
6320

query I rowsort
SELECT + col0 * + 93 AS col1 FROM tab0
----
2232
3255
8277

query I rowsort
SELECT - col1 * - 32 + - 10 FROM tab0 AS cor0
----
2742
2902
3094

query I rowsort
SELECT ALL col1 - 65 AS col2 FROM tab1 cor0
----
-39
-52
-55

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

query I rowsort
SELECT DISTINCT - col2 + + 36 * + cor0.col1 FROM tab0 AS cor0
----
3063
3194
3491

query I rowsort
SELECT + + col0 + 21 * - 97 FROM tab2 AS cor0
----
-1958
-1959
-2030

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

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

query I rowsort
SELECT 64 + + tab2.col0 * tab2.col2 FROM tab2
----
2092
253
3066

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 84 * + col0 col1 FROM tab0 AS cor0
----
2016
2940
7476

onlyif mysql # use DIV operator for integer division
query I rowsort label-1188
SELECT + col1 + - col1 DIV - col2 col0 FROM tab1
----
10
13
26

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

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

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

query I rowsort
SELECT ALL + ( col2 ) * 11 FROM tab2 AS cor0
----
286
297
418

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

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

query I rowsort
SELECT ALL - + 74 + cor0.col1 FROM tab1 AS cor0
----
-48
-61
-64

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

query I rowsort
SELECT DISTINCT - col1 * 60 FROM tab2
----
-1020
-1860
-3540

query I rowsort
SELECT - 17 * tab0.col2 * col2 AS col0 FROM tab0
----
-114308
-17
-18513

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

query I rowsort
SELECT - 72 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to b7689a8218ac9df1cca20d2ba5c53888

query I rowsort
SELECT + col2 + col2 * 42 AS col2 FROM tab0
----
1419
3526
43

query I rowsort
SELECT DISTINCT + col2 * col2 + + 55 AS col2 FROM tab0
----
1144
56
6779

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

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

query I rowsort
SELECT - ( 87 ) + - tab1.col0 FROM tab1, tab1 cor0
----
9 values hashing to ca7a9ef18ec0475b9e04bf32d6ecc2a2

query I rowsort
SELECT DISTINCT - col2 * col1 * + 83 FROM tab0
----
-235554
-619346
-8051

query I rowsort
SELECT col1 * - ( - 75 + col2 ) FROM tab2
----
1488
2891
629

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1211
SELECT DISTINCT col2 DIV + 69 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-1211
SELECT DISTINCT col2 / + 69 FROM tab1
----
0
1

query I rowsort
SELECT ALL col0 + col2 * - col1 AS col2 FROM tab2 AS cor0
----
-1456
-567
-830

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

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

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

query I rowsort
SELECT ( - 78 ) FROM tab0 AS cor0
----
-78
-78
-78

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

query I rowsort
SELECT DISTINCT ( + 69 ) AS col0 FROM tab1, tab1 AS cor0
----
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-1218
SELECT DISTINCT col1 + - CAST( col0 + + col0 AS SIGNED ) DIV col0 FROM tab0
----
84
89
95

skipif mysql # not compatible
query I rowsort label-1218
SELECT DISTINCT col1 + - CAST ( col0 + + col0 AS INTEGER ) / col0 FROM tab0
----
84
89
95

query I rowsort
SELECT + + col1 + + col1 + - col0 FROM tab0 cor0
----
148
159
93

query I rowsort
SELECT - col2 + - col1 + col0 AS col1 FROM tab2 AS cor0
----
-51
-7
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1221
SELECT ( - 73 ) + col2 * CAST( col1 AS SIGNED ) FROM tab0 AS cor0
----
24
2765
7389

skipif mysql # not compatible
query I rowsort label-1221
SELECT ( - 73 ) + col2 * CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
24
2765
7389

query I rowsort
SELECT ALL 10 * + col0 * - tab0.col1 + col1 + 30 FROM tab0
----
-20524
-33823
-80869

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

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

query I rowsort
SELECT ALL + 14 - - col2 * - col1 FROM tab2
----
-1520
-632
-823

query I rowsort
SELECT + + 66 * - 15 AS col2 FROM tab1 AS cor0
----
-990
-990
-990

query I rowsort
SELECT col2 - col2 * cor0.col0 * + col1 FROM tab1 AS cor0
----
-36423
-4158
-99744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * + 26 - + col2 * + cor0.col1 col1 FROM tab2 AS cor0
----
-655
1408
494

query I rowsort
SELECT - - col1 * col2 + col1 * + col2 FROM tab1 AS cor0
----
1140
2496
2808

query I rowsort
SELECT col0 - - col0 * - cor0.col2 FROM tab1 cor0
----
-159
-3584
-7600

query I rowsort
SELECT - col1 * col1 + col1 AS col2 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT + - 13 + col0 FROM tab2 AS cor0
----
-6
65
66

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 12 * col0 + - 81 col2 FROM tab2 AS cor0
----
3
855
867

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 64 + col2 * + cor0.col0 col1 FROM tab2 cor0
----
2092
253
3066

query I rowsort
SELECT DISTINCT + 86 * col0 + col1 AS col2 FROM tab1 AS cor0
----
284
5514
6893

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

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

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

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

query I rowsort
SELECT + + col0 + + col0 * col2 AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL + 62 * + col2 FROM tab0 AS cor0
----
2046
5084
62

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1245
SELECT - - col1 + + cor0.col0 + + col0 DIV - 47 AS col1 FROM tab1 AS cor0
----
29
73
92

skipif mysql # not compatible
query I rowsort label-1245
SELECT - - col1 + + cor0.col0 + + col0 / - 47 AS col1 FROM tab1 AS cor0
----
29
73
92

query I rowsort
SELECT ALL - + col2 * + col1 + + cor0.col2 * - col0 FROM tab1 AS cor0
----
-1566
-4218
-8928

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

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

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

query I rowsort
SELECT - col2 * 1 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col1 * + ( + col2 ) + + col1 col0 FROM tab1 AS cor0
----
-1235
-1378
-560

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

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

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

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

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

query I rowsort
SELECT DISTINCT - col2 + + 53 FROM tab2 AS cor0
----
15
26
27

query I rowsort
SELECT ALL - ( - col2 ) + col2 AS col0 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL - cor0.col1 * cor0.col0 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 75a608bf2ba236d24f146ac4aff9ec52

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

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

query I rowsort
SELECT ALL col1 * col1 + col1 - + col2 AS col0 FROM tab2
----
268
3514
965

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + 91 * col1 * col1 col2 FROM tab2 AS cor0
----
26316
316830
87482

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

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

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

query I rowsort
SELECT - col1 + - cor0.col1 * 97 FROM tab0 AS cor0
----
-8428
-8918
-9506

query I rowsort
SELECT col1 * cor0.col0 + - 24 FROM tab2 AS cor0
----
1319
193
4578

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

query I rowsort
SELECT DISTINCT - tab1.col0 * col0 + col0 AS col1 FROM tab1
----
-4032
-6
-6320

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

query I rowsort
SELECT DISTINCT - 44 * col2 + col2 * + 32 AS col2 FROM tab1
----
-1152
-648
-684

query I rowsort
SELECT + 25 + col1 FROM tab2
----
42
56
84

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

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1275
SELECT + cor1.col1 * CAST( cor1.col1 + + cor1.col2 AS SIGNED ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 3fc6919b1b8fe81f5274c047cc37ee1c

skipif mysql # not compatible
query I rowsort label-1275
SELECT + cor1.col1 * CAST ( cor1.col1 + + cor1.col2 AS INTEGER ) AS col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
27 values hashing to 3fc6919b1b8fe81f5274c047cc37ee1c

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1277
SELECT DISTINCT - + col2 DIV + 2 FROM tab2 AS cor0
----
-13
-19

skipif mysql # not compatible
query I rowsort label-1277
SELECT DISTINCT - + col2 / + 2 FROM tab2 AS cor0
----
-13
-19

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 + 61 col2 FROM tab1 AS cor0
----
115
118
157

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

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

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

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

query I rowsort
SELECT - col2 * cor0.col2 + col0 * col2 AS col2 FROM tab2 AS cor0
----
-540
1352
1558

query I rowsort
SELECT + col2 + - 94 + col2 * col2 FROM tab0 cor0
----
-92
1028
6712

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1285
SELECT + col2 + col1 DIV + col0 + + tab2.col1 AS col2 FROM tab2
----
55
62
85

skipif mysql # not compatible
query I rowsort label-1285
SELECT + col2 + col1 / + col0 + + tab2.col1 AS col2 FROM tab2
----
55
62
85

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

query I rowsort
SELECT DISTINCT col0 AS col0 FROM tab0 WHERE NOT NULL NOT BETWEEN col0 AND NULL
----

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

query III rowsort
SELECT * FROM tab2 WHERE NOT tab2.col2 IN ( - tab2.col2 * - col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT ALL - col2 * tab0.col1 * col2 + + col2 * tab0.col2 AS col0 FROM tab0
----
-605160
-92565
-96

query I rowsort
SELECT col0 + - col1 - + col2 AS col2 FROM tab1
----
-29
-3
-77

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

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

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

query I rowsort
SELECT ALL 17 + - col1 * - col2 FROM tab0 AS cor0
----
114
2855
7479

query I rowsort
SELECT ALL tab1.col1 FROM tab1 WHERE NOT NULL NOT BETWEEN NULL AND NULL
----

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

query I rowsort
SELECT + 49 AS col0 FROM tab2
----
49
49
49

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

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

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

query I rowsort
SELECT 57 * col0 * col0 AS col1 FROM tab1 AS cor0
----
233472
364800
513

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1303
SELECT DISTINCT + + col0 * col2 DIV - col1 + - col1 AS col0 FROM tab1 AS cor0
----
-32
-374
-603

skipif mysql # not compatible
query I rowsort label-1303
SELECT DISTINCT + + col0 * col2 / - col1 + - col1 AS col0 FROM tab1 AS cor0
----
-32
-374
-603

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

query I rowsort
SELECT + col1 * - 35 FROM tab2 AS cor0
----
-1085
-2065
-595

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

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

query I rowsort
SELECT DISTINCT ( - cor0.col0 ) * cor0.col0 * 71 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-290816
-454400
-639

query I rowsort
SELECT + 19 AS col2 FROM tab2
----
19
19
19

query I rowsort
SELECT DISTINCT - 7 * col1 AS col1 FROM tab2 AS cor0
----
-119
-217
-413

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

query I rowsort
SELECT ( 56 ) * col1 FROM tab1 cor0
----
1456
560
728

query I rowsort
SELECT - 26 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 92c9dcf04a06d25c174ffa715aa22fcf

query I rowsort
SELECT DISTINCT col1 * - 91 FROM tab0 cor0
----
-7826
-8281
-8827

query I rowsort
SELECT ALL + 91 AS col2 FROM tab0, tab2 cor0, tab2 cor1
----
27 values hashing to deebbcfb9c7803a34dca6bd860849afe

onlyif mysql # use DIV operator for integer division
query I rowsort label-1316
SELECT ALL col1 DIV - tab1.col0 + col0 col1 FROM tab1
----
-5
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1316
SELECT ALL col1 / - tab1.col0 + col0 col1 FROM tab1
----
-5
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1317
SELECT - col2 DIV tab0.col0 + 83 FROM tab0
----
82
83
83

skipif mysql # not compatible
query I rowsort label-1317
SELECT - col2 / tab0.col0 + 83 FROM tab0
----
82
83
83

skipif mysql # not compatible
query I rowsort
SELECT - + CAST ( col2 AS REAL ) + col2 FROM tab0 AS cor0
----
0
0
0

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

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

query I rowsort
SELECT + 50 FROM tab2, tab1 AS cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT DISTINCT ( + col1 ) + + cor0.col1 + - ( 19 + cor0.col2 ) AS col0 FROM tab1 AS cor0
----
-21
-56
-89

query I rowsort
SELECT cor0.col0 * cor0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to bc669a3cc969c7619ebcffb5400ba0ba

onlyif mysql # use DIV operator for integer division
query I rowsort label-1324
SELECT - - col1 + + CAST( + ( + col0 ) AS SIGNED ) DIV col0 col0 FROM tab0 AS cor0
----
87
92
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1324
SELECT - - col1 + + CAST ( + ( + col0 ) AS INTEGER ) / col0 col0 FROM tab0 AS cor0
----
87
92
98

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + 3 * col2 col0 FROM tab0 AS cor0
----
123
335
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-1328
SELECT ALL - - col0 DIV + cor0.col1 + - col0 DIV - 33 FROM tab2 AS cor0
----
0
3
6

skipif mysql # not compatible
query I rowsort label-1328
SELECT ALL - - col0 / + cor0.col1 + - col0 / - 33 FROM tab2 AS cor0
----
0
3
6

query I rowsort
SELECT - col1 * 5 AS col1 FROM tab2 cor0
----
-155
-295
-85

query I rowsort
SELECT DISTINCT - - cor0.col1 * 59 FROM tab1 AS cor0
----
1534
590
767

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

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

query I rowsort
SELECT ALL col2 * - col2 + cor0.col2 FROM tab0 cor0
----
-1056
-6642
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * ( col2 * - tab0.col2 ) col1 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT - col0 + ( - col1 + - cor0.col0 ) AS col2 FROM tab2 cor0
----
-175
-215
-45

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

query I rowsort
SELECT DISTINCT ( - tab0.col0 ) AS col2 FROM tab0, tab1 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL - col2 * - 47 FROM tab1
----
2538
2679
4512

query I rowsort
SELECT + col1 + col2 * + 54 AS col0 FROM tab0 AS cor0
----
151
1868
4519

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

query I rowsort
SELECT DISTINCT + ( 28 ) FROM tab0
----
28

query I rowsort
SELECT - 71 * col2 AS col2 FROM tab0
----
-2343
-5822
-71

query I rowsort
SELECT 92 * - col1 * ( - ( - col2 ) ) + col1 * col0 FROM tab1 AS cor0
----
-113776
-129090
-51800

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

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

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

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

query I rowsort
SELECT ALL 29 * col2 AS col1 FROM tab2
----
1102
754
783

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1349
SELECT + tab1.col1 + + col2 DIV + 85 FROM tab1
----
10
14
26

skipif mysql # not compatible
query I rowsort label-1349
SELECT + tab1.col1 + + col2 / + 85 FROM tab1
----
10
14
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 - 93 * col1 col0 FROM tab1 AS cor0
----
-1129
-2415
-866

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

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

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

query I rowsort
SELECT ALL col0 * ( + 61 ) FROM tab2 AS cor0
----
427
4758
4819

query I rowsort
SELECT - col0 - 55 FROM tab2 AS cor0
----
-133
-134
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-1356
SELECT ALL + col0 + 63 DIV col2 FROM tab1 AS cor0
----
4
65
80

skipif mysql # not compatible
query I rowsort label-1356
SELECT ALL + col0 + 63 / col2 FROM tab1 AS cor0
----
4
65
80

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

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

skipif mysql # not compatible
query I rowsort label-1358
SELECT DISTINCT col2 * CAST ( + col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT col0 + - col1 + cor0.col2 * + col1 FROM tab1 AS cor0
----
1315
1381
624

query I rowsort
SELECT - col2 * 28 - col1 FROM tab1 cor0
----
-1538
-1606
-2701

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

query I rowsort
SELECT - 56 AS col1 FROM tab0, tab0 AS cor0 CROSS JOIN tab2
----
27 values hashing to a228dfb9ede9780b082a5a3dfb2fca80

query I rowsort
SELECT 64 * - col2 + col1 * + col0 AS col0 FROM tab1 AS cor0
----
-3008
-3378
-5104

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

query I rowsort
SELECT + + cor0.col0 * - 21 + cor0.col1 + - 63 * ( - col0 + ( 44 ) ) * - col2 AS col1 FROM tab2 AS cor0
----
-57271
-85432
62821

query I rowsort
SELECT 85 + - col2 FROM tab1 cor0
----
-11
28
31

query I rowsort
SELECT ALL + cor0.col1 + col0 * col0 FROM tab1 AS cor0
----
35
4106
6413

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

query I rowsort
SELECT DISTINCT 35 + col2 + - ( col0 ) * col0 * - ( col2 ) FROM tab1 AS cor0
----
233564
575
614531

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

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

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

query I rowsort
SELECT - 81 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 205b3ff2d7b1817c98d7980b8c17e6c1

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 97 * + col0 + - col0 + + col0 col0 FROM tab2 AS cor0
----
679
7566
7663

query I rowsort
SELECT ALL + - 16 * - col2 - col0 AS col2 FROM tab0 AS cor0
----
-19
1223
504

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * + col1 * - col2 col1 FROM tab1 AS cor0
----
16224
36504
5700

query I rowsort
SELECT ALL + col1 * col1 - col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT ALL - col1 + + col0 + + cor0.col1 * + col0 FROM tab0 cor0
----
2002
3333
8097

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + CAST ( + col0 AS REAL ) - - col0 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - ( - 44 ) + - col2 AS col1 FROM tab1 AS cor0
----
-10
-13
-52

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1382
SELECT DISTINCT - - cor0.col2 DIV col0 + + col0 - - col1 AS col1 FROM tab0 AS cor0
----
111
132
180

skipif mysql # not compatible
query I rowsort label-1382
SELECT DISTINCT - - cor0.col2 / col0 + + col0 - - col1 AS col1 FROM tab0 AS cor0
----
111
132
180

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

query I rowsort
SELECT tab1.col0 * 77 + ( - col2 * - ( - col2 ) ) FROM tab1
----
-2685
-3056
1679

query I rowsort
SELECT col0 + 90 FROM tab0
----
114
125
179

query I rowsort
SELECT DISTINCT col1 * - 49 * + col1 FROM tab1
----
-33124
-4900
-8281

query I rowsort
SELECT DISTINCT + 62 + 29 * col1 AS col2 FROM tab2
----
1773
555
961

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

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

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

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

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

query I rowsort
SELECT cor0.col1 * tab0.col2 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 1d94ea086ff4b04d01d3c46ff83c5c3d

query I rowsort
SELECT col1 * + 60 AS col0 FROM tab1
----
1560
600
780

query I rowsort
SELECT DISTINCT - col0 + col2 + - 99 AS col1 FROM tab0
----
-106
-133
-90

query I rowsort
SELECT DISTINCT cor0.col0 + 71 FROM tab1, tab1 AS cor0
----
135
151
74

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

query I rowsort
SELECT DISTINCT + + cor0.col0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
3
64
80

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

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

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

query I rowsort
SELECT ALL ( + ( cor0.col0 ) + 69 ) FROM tab1, tab0 AS cor0
----
9 values hashing to d9b60e632cb8d73d19971ee816f20c2f

query I rowsort
SELECT ALL + + col0 * - 94 + 25 FROM tab2 AS cor0
----
-633
-7307
-7401

query I rowsort
SELECT col0 * - 42 AS col2 FROM tab0 AS cor0
----
-1008
-1470
-3738

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

query I rowsort
SELECT DISTINCT cor0.col1 + cor2.col0 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1, tab1 AS cor2
----
9 values hashing to af3a539c18b07c0d2d3147e1b73e81ac

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

query I rowsort
SELECT ALL col2 + 30 * cor0.col0 FROM tab0 AS cor0
----
1051
2752
753

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

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

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

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

query I rowsort
SELECT ALL - col0 + 71 FROM tab0 AS cor0
----
-18
36
47

query I rowsort
SELECT + + col0 + 41 * col0 FROM tab1 AS cor0
----
126
2688
3360

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

skipif mysql # not compatible
query I rowsort label-1413
SELECT CAST ( NULL AS INTEGER ) * - 15 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

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

query I rowsort
SELECT ALL - col1 + - cor0.col1 * 57 AS col0 FROM tab2 AS cor0
----
-1798
-3422
-986

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 + col0 * - 60 col1 FROM tab2 cor0
----
-427
-4758
-4819

query I rowsort
SELECT ALL + 77 * 12 FROM tab0 cor0
----
924
924
924

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

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

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

query I rowsort
SELECT ALL + 26 AS col0 FROM tab2 AS cor0
----
26
26
26

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

query I rowsort
SELECT col0 * + col2 + + 90 FROM tab1 AS cor0
----
252
3738
7770

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

query I rowsort
SELECT + 72 * + col2 AS col1 FROM tab2
----
1872
1944
2736

onlyif mysql # use DIV operator for integer division
query I rowsort label-1426
SELECT ALL 1 DIV 85 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-1426
SELECT ALL 1 / 85 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT ALL + col2 - + cor0.col1 * - 79 AS col2 FROM tab1 AS cor0
----
1123
2108
847

query I rowsort
SELECT DISTINCT col2 + col2 * + col2 - - 57 AS col0 FROM tab0 AS cor0
----
1179
59
6863

query I rowsort
SELECT col0 * - 30 + - col2 AS col1 FROM tab1 cor0
----
-144
-1977
-2496

query I rowsort
SELECT ( col2 ) + + ( 90 ) + + col0 AS col2 FROM tab0
----
126
147
261

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1432
SELECT - - col1 DIV + 10 + col0 FROM tab0 AS cor0
----
32
44
98

skipif mysql # not compatible
query I rowsort label-1432
SELECT - - col1 / + 10 + col0 FROM tab0 AS cor0
----
32
44
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col2 + 38 col0 FROM tab0 AS cor0
----
135
2876
7500

query I rowsort
SELECT ( col0 ) + + ( 50 ) * + col2 AS col2 FROM tab0
----
1674
4189
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-1435
SELECT - tab1.col0 * - tab1.col0 + col2 * 83 * col2 + col0 DIV - col1 FROM tab1
----
242037
273757
771322

skipif mysql # not compatible
query I rowsort label-1435
SELECT - tab1.col0 * - tab1.col0 + col2 * 83 * col2 + col0 / - col1 FROM tab1
----
242037
273757
771322

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

query I rowsort
SELECT ALL + 73 * col2 + - col0 FROM tab2
----
1820
1964
2695

query I rowsort
SELECT DISTINCT + col1 + col1 * 61 AS col0 FROM tab0
----
5332
5642
6014

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

query I rowsort
SELECT + 98 FROM tab2, tab2 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

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

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

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

query I rowsort
SELECT col1 * cor0.col1 - + col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT + + col0 * + col1 + 43 * col0 AS col0 FROM tab2 AS cor0
----
4740
518
7956

query I rowsort
SELECT - 25 AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 2e7a33467ee3a4d9570560d60302b35a

query I rowsort
SELECT ( - tab1.col1 + col1 * col0 ) AS col2 FROM tab1
----
1027
52
630

query I rowsort
SELECT ALL - ( col1 ) * 88 FROM tab0 AS cor0
----
-7568
-8008
-8536

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

query I rowsort
SELECT - 76 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

query I rowsort
SELECT 53 * - 78 FROM tab2, tab2 AS cor0
----
9 values hashing to 3f304b84e872ed38018efb1c32eaaf81

query I rowsort
SELECT cor0.col1 + + 30 FROM tab0, tab1 AS cor0
----
9 values hashing to 76432e94f1a83d1f7a61210a286babca

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1456
SELECT col0 * + col0 DIV col0 col0 FROM tab0 cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1456
SELECT col0 * + col0 / col0 col0 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT + - 66 * col2 FROM tab1 AS cor0
----
-3564
-3762
-6336

query I rowsort
SELECT + 87 + - 62 AS col1 FROM tab2 AS cor0
----
25
25
25

query I rowsort
SELECT DISTINCT + 21 + - 46 AS col2 FROM tab2 AS cor0
----
-25

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

skipif mysql # not compatible
query I rowsort label-1460
SELECT col2 / ( + cor0.col0 ) FROM tab0 cor0
----
0
0
1

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

query I rowsort
SELECT DISTINCT col2 * + 45 FROM tab0
----
1485
3690
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 + col1 * col2 * + ( 74 ) col2 FROM tab0 AS cor0
----
210098
552279
7275

query I rowsort
SELECT ALL + - col2 + 16 FROM tab1 AS cor0
----
-38
-41
-80

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

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

query I rowsort
SELECT DISTINCT tab0.col1 * 26 AS col1 FROM tab0
----
2236
2366
2522

query I rowsort
SELECT ALL ( - col0 ) + col2 * - 31 FROM tab0 AS cor0
----
-1047
-2631
-66

query I rowsort
SELECT ALL + - 91 * cor0.col0 + col1 * col0 FROM tab1 cor0
----
-195
-5184
-6240

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

query I rowsort
SELECT - + col0 * + 22 AS col1 FROM tab0 cor0
----
-1958
-528
-770

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 93 col0 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

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

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

query I rowsort
SELECT DISTINCT + + 0 FROM tab0 cor0
----
0

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

query I rowsort
SELECT + ( 52 ) FROM tab2
----
52
52
52

query I rowsort
SELECT 21 * col1 * tab2.col0 + col0 FROM tab2
----
28282
4564
96720

query I rowsort
SELECT ALL 62 AS col0 FROM tab1
----
62
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-1480
SELECT - col1 + col1 DIV - col1 FROM tab1
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-1480
SELECT - col1 + col1 / - col1 FROM tab1
----
-11
-14
-27

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - 13 + col1 - cor0.col0 col1 FROM tab0 AS cor0
----
1180
1185
1323

query I rowsort
SELECT DISTINCT - col0 + 66 FROM tab1 AS cor0
----
-14
2
63

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

skipif mysql # not compatible
query I rowsort label-1484
SELECT DISTINCT + - cor0.col0 * CAST ( col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-4096
-6400
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + tab0.col0 + col0 col1 FROM tab0
----
105
267
72

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1487
SELECT ALL - col1 DIV + col0 + + ( - col0 * col0 ) FROM tab0
----
-1227
-579
-7922

skipif mysql # not compatible
query I rowsort label-1487
SELECT ALL - col1 / + col0 + + ( - col0 * col0 ) FROM tab0
----
-1227
-579
-7922

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1489
SELECT DISTINCT + + col2 DIV + col2 + - col2 * col1 AS col2 FROM tab0 AS cor0
----
-2837
-7461
-96

skipif mysql # not compatible
query I rowsort label-1489
SELECT DISTINCT + + col2 / + col2 + - col2 * col1 AS col2 FROM tab0 AS cor0
----
-2837
-7461
-96

query I rowsort
SELECT ALL + - col0 + - 71 FROM tab1 AS cor0
----
-135
-151
-74

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

query I rowsort
SELECT + col2 + - 29 * col1 AS col1 FROM tab0 AS cor0
----
-2461
-2557
-2812

onlyif mysql # use DIV operator for integer division
query I rowsort label-1493
SELECT + col0 DIV cor0.col0 + col0 * col2 FROM tab0 AS cor0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-1493
SELECT + col0 / cor0.col0 + col0 * col2 FROM tab0 AS cor0
----
36
7299
793

query I rowsort
SELECT col1 * 93 + + col2 + - col2 FROM tab0 AS cor0
----
7998
8463
9021

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

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

query I rowsort
SELECT DISTINCT - 68 * col1 * - ( col2 ) AS col0 FROM tab2
----
104312
43928
56916

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

query I rowsort
SELECT DISTINCT - 44 * col2 FROM tab0 AS cor0
----
-1452
-3608
-44

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

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

query I rowsort
SELECT 91 * - col0 + 49 AS col1 FROM tab1 AS cor0
----
-224
-5775
-7231

query I rowsort
SELECT cor0.col0 + - col1 * - 63 FROM tab2 AS cor0
----
1150
1960
3795

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

query I rowsort
SELECT ALL - - col2 * 35 AS col2 FROM tab2 AS cor0
----
1330
910
945

query I rowsort
SELECT - + col0 + col2 * + col1 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT col2 + - col0 * ( - col2 * col0 ) FROM tab1
----
233529
540
614496

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

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

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

query I rowsort
SELECT DISTINCT - 97 * col0 AS col2 FROM tab0
----
-2328
-3395
-8633

query I rowsort
SELECT DISTINCT - ( + col1 ) * col0 * col1 + col0 * col2 AS col0 FROM tab2 AS cor0
----
-19829
-269490
-6538

query I rowsort
SELECT DISTINCT + cor0.col2 + + 38 AS col1 FROM tab2 AS cor0
----
64
65
76

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

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

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

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

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

query I rowsort
SELECT ALL ( cor0.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-1519
SELECT + 92 * ( - col2 ) + CAST( - col1 AS SIGNED ) AS col1 FROM tab1 cor0
----
-4994
-5254
-8845

skipif mysql # not compatible
query I rowsort label-1519
SELECT + 92 * ( - col2 ) + CAST ( - col1 AS INTEGER ) AS col1 FROM tab1 cor0
----
-4994
-5254
-8845

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

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

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

query I rowsort
SELECT ALL + cor0.col1 + col0 * - col1 * col2 FROM tab2 AS cor0
----
-119593
-51017
-5828

query I rowsort
SELECT DISTINCT - 91 * col1 FROM tab2 cor0
----
-1547
-2821
-5369

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

query I rowsort
SELECT + 16 * + col0 + - col2 FROM tab0 AS cor0
----
1342
351
559

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

query I rowsort
SELECT + col1 + + 68 + - col1 AS col2 FROM tab1
----
68
68
68

query I rowsort
SELECT DISTINCT 2 * 2 FROM tab1 AS cor0
----
4

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

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

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

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

query I rowsort
SELECT DISTINCT + 9 * - col1 FROM tab2 cor0
----
-153
-279
-531

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 25 * col0 col0 FROM tab1 AS cor0
----
1600
2000
75

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

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

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

query I rowsort
SELECT DISTINCT - 86 AS col1 FROM tab2
----
-86

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

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

skipif mysql # not compatible
query I rowsort label-1539
SELECT CAST ( NULL AS REAL ) + 51 / col0 FROM tab0
----
NULL
NULL
NULL

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

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

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

query I rowsort
SELECT ALL 76 * col0 FROM tab0
----
1824
2660
6764

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

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

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

query I rowsort
SELECT ALL - col2 - + col2 * - 34 FROM tab1 AS cor0
----
1782
1881
3168

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

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

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

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

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

query I rowsort
SELECT DISTINCT + 33 * col2 - - col0 * 79 FROM tab1 AS cor0
----
2019
6937
9488

query I rowsort
SELECT + 23 + cor0.col0 FROM tab1 AS cor0
----
103
26
87

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

query I rowsort
SELECT DISTINCT + 31 FROM tab0 AS cor0
----
31

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

query I rowsort
SELECT ALL - + 29 + 27 * + col0 + + 38 FROM tab0 AS cor0
----
2412
657
954

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

query I rowsort
SELECT + + cor0.col0 FROM tab2, tab1 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

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

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

query I rowsort
SELECT + - col2 + - 6 FROM tab0 cor0
----
-39
-7
-88

query I rowsort
SELECT + - cor0.col0 * cor0.col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT - + 38 FROM tab2 cor0
----
-38
-38
-38

query I rowsort
SELECT ALL col1 * - tab0.col2 * - col0 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT ALL col1 * col2 + col1 AS col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT ALL col2 * col0 - col2 * col2 * col2 AS col0 FROM tab1 AS cor0
----
-157302
-181545
-877056

query I rowsort
SELECT + col0 * - col2 * col1 AS col1 FROM tab0 cor0
----
-3395
-664118
-68112

query I rowsort
SELECT + 8 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1569
SELECT - CAST( ( + col1 ) AS SIGNED ) + col1 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1569
SELECT - CAST ( ( + col1 ) AS INTEGER ) + col1 AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1570
SELECT - CAST( ( col0 ) AS SIGNED ) * cor0.col1 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-1570
SELECT - CAST ( ( col0 ) AS INTEGER ) * cor0.col1 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-1571
SELECT - - ( col2 ) DIV col0 AS col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-1571
SELECT - - ( col2 ) / col0 AS col0 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT DISTINCT + 11 FROM tab0, tab0 AS cor0
----
11

query I rowsort
SELECT + col0 * col0 + + col1 FROM tab2 AS cor0
----
6143
6258
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1574
SELECT - 39 DIV col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1574
SELECT - 39 / col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - 90 * col2 FROM tab2 cor0
----
-2340
-2430
-3420

query I rowsort
SELECT + ( + cor0.col1 ) AS col0 FROM tab2 AS cor0
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-1577
SELECT - + col2 DIV + col0 AS col2 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1577
SELECT - + col2 / + col0 AS col2 FROM tab0 cor0
----
-1
0
0

query I rowsort
SELECT - + 22 * - col2 + - col2 FROM tab2 AS cor0
----
546
567
798

query I rowsort
SELECT - 98 * - col0 AS col1 FROM tab1 AS cor0
----
294
6272
7840

query I rowsort
SELECT - - ( + col1 ) FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT ALL ( col0 ) * + col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT 20 * + col0 FROM tab0
----
1780
480
700

query I rowsort
SELECT col1 + + cor0.col2 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT col2 * col2 * + col1 AS col1 FROM tab2 AS cor0 WHERE NOT NULL IN ( + col0 * - col0 * col0 + col2 )
----

query I rowsort
SELECT DISTINCT - col0 * col0 * col0 FROM tab1
----
-262144
-27
-512000

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( NULL ) NOT IN ( - col2 )
----

query I rowsort
SELECT + col0 * tab1.col1 AS col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL + col1 * - tab2.col2 * tab2.col1 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT + col2 AS col0 FROM tab0 AS cor0 WHERE NULL NOT IN ( col2 * - col2 / col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1590
SELECT cor0.col0 DIV - col0 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1590
SELECT cor0.col0 / - col0 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT tab1.col0 AS col2 FROM tab1 WHERE NOT NULL BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL col0 * col1 + col1 AS col2 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT ALL + col1 + col2 * col1 AS col0 FROM tab1
----
1261
1430
580

query I rowsort
SELECT + col0 + - col2 * + tab1.col2 + - col2 / col2 AS col1 FROM tab1 WHERE ( - col2 + - col1 * - col2 ) <= NULL
----

query I rowsort
SELECT ALL col0 + - col0 * col0 AS col1 FROM tab1
----
-4032
-6
-6320

query I rowsort
SELECT - col2 FROM tab0 WHERE ( NULL ) IN ( col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1597
SELECT DISTINCT - col0 + + tab1.col1 DIV - tab1.col2 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-1597
SELECT DISTINCT - col0 + + tab1.col1 / - tab1.col2 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT ALL col2 * - col2 + + col1 * tab1.col0 FROM tab1
----
-2609
-2838
-8176

query I rowsort
SELECT DISTINCT + tab0.col2 AS col1 FROM tab0 WHERE NOT ( NULL ) <> ( NULL )
----

query I rowsort
SELECT - col1 AS col2 FROM tab2 WHERE NOT ( NULL ) IN ( col2 )
----

query I rowsort
SELECT DISTINCT tab0.col0 * + col0 + col2 FROM tab0
----
1226
609
8003

query I rowsort
SELECT - col0 * + col2 - - col2 AS col1 FROM tab1
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-1603
SELECT - + col0 - + col0 DIV + col2 AS col1 FROM tab0 AS cor0
----
-24
-70
-90

skipif mysql # not compatible
query I rowsort label-1603
SELECT - + col0 - + col0 / + col2 AS col1 FROM tab0 AS cor0
----
-24
-70
-90

query I rowsort
SELECT DISTINCT + cor0.col2 * + col1 * - col0 - col1 * + col0 AS col1 FROM tab0 AS cor0
----
-672217
-6790
-70176

query I rowsort
SELECT DISTINCT - + col0 * col2 + col1 * - col2 AS col0 FROM tab1 AS cor0
----
-1566
-4218
-8928

query I rowsort
SELECT ALL - - col2 - col2 * + col2 AS col1 FROM tab1 AS cor0
----
-2862
-3192
-9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-1607
SELECT cor0.col1 + col0 DIV + col2 FROM tab0 AS cor0
----
132
86
92

skipif mysql # not compatible
query I rowsort label-1607
SELECT cor0.col1 + col0 / + col2 FROM tab0 AS cor0
----
132
86
92

query I rowsort
SELECT DISTINCT + + col2 - + col2 AS col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + - col1 * col1 - + col2 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT ALL - - col1 + col0 FROM tab0 cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-1611
SELECT + col2 DIV - col1 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-1611
SELECT + col2 / - col1 FROM tab1
----
-2
-5
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-1612
SELECT col2 DIV - col0 + col2 * col0 - col1 * - col0 AS col1 FROM tab0
----
15397
2855
3430

skipif mysql # not compatible
query I rowsort label-1612
SELECT col2 / - col0 + col2 * col0 - col1 * - col0 AS col1 FROM tab0
----
15397
2855
3430

query I rowsort
SELECT - col2 - + col1 AS col1 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT - col2 + - col1 * col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT col0 + col0 - + col1 FROM tab2
----
-17
141
97

query I rowsort
SELECT + col1 * col0 * col1 AS col0 FROM tab1 AS cor0
----
13520
2028
6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col0 col0 FROM tab2
----
14
156
158

query I rowsort
SELECT DISTINCT + col2 + col1 * col0 FROM tab0
----
2097
3396
8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - 55 col1 FROM tab0
----
1320
1925
4895

query I rowsort
SELECT ALL - + col2 + 31 AS col0 FROM tab2 AS cor0
----
-7
4
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-1621
SELECT + col2 + 6 - col1 DIV col1 AS col1 FROM tab1 AS cor0
----
101
59
62

skipif mysql # not compatible
query I rowsort label-1621
SELECT + col2 + 6 - col1 / col1 AS col1 FROM tab1 AS cor0
----
101
59
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-1622
SELECT DISTINCT - col1 * cor0.col1 DIV + 39 FROM tab2 AS cor0
----
-24
-7
-89

skipif mysql # not compatible
query I rowsort label-1622
SELECT DISTINCT - col1 * cor0.col1 / + 39 FROM tab2 AS cor0
----
-24
-7
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-1623
SELECT DISTINCT tab2.col2 * tab2.col1 DIV col0 col2 FROM tab2
----
119
19
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1623
SELECT DISTINCT tab2.col2 * tab2.col1 / col0 col2 FROM tab2
----
119
19
8

query I rowsort
SELECT DISTINCT - col2 + ( - col2 ) + - col0 AS col1 FROM tab0 AS cor0
----
-253
-37
-90

query I rowsort
SELECT ALL - - 11 * - ( col1 ) FROM tab0 AS cor0
----
-1001
-1067
-946

query I rowsort
SELECT col1 * col0 + col0 * col2 AS col2 FROM tab2 AS cor0
----
406
4345
6630

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT - - CAST ( - col1 AS REAL ) col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - - 76 AS col0 FROM tab1 AS cor0
----
76

query I rowsort
SELECT ALL + ( cor0.col2 ) + col0 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL 87 + col0 * col2 AS col0 FROM tab0 AS cor0
----
122
7385
879

query I rowsort
SELECT ALL + col0 - + 94 FROM tab2 AS cor0
----
-15
-16
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-1632
SELECT col1 DIV - col2 + + cor0.col2 col1 FROM tab0 AS cor0
----
-96
31
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1632
SELECT col1 / - col2 + + cor0.col2 col1 FROM tab0 AS cor0
----
-96
31
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-1633
SELECT DISTINCT 84 * col1 + - col1 DIV col1 FROM tab1 AS cor0
----
1091
2183
839

skipif mysql # not compatible
query I rowsort label-1633
SELECT DISTINCT 84 * col1 + - col1 / col1 FROM tab1 AS cor0
----
1091
2183
839

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1634
SELECT DISTINCT - CAST( col1 AS SIGNED ) * col2 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-1634
SELECT DISTINCT - CAST ( col1 AS INTEGER ) * col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL col0 + 29 * tab0.col0 AS col2 FROM tab0
----
1050
2670
720

query I rowsort
SELECT - ( + 10 ) * - col2 FROM tab0 cor0
----
10
330
820

query I rowsort
SELECT 24 * col0 AS col0 FROM tab0 AS cor0
----
2136
576
840

query I rowsort
SELECT DISTINCT + 94 * col2 * - col0 AS col1 FROM tab2 cor0
----
-17766
-190632
-282188

query I rowsort
SELECT - - 27 * col0 FROM tab2 AS cor0
----
189
2106
2133

query I rowsort
SELECT - - col1 * col0 + col2 AS col0 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT + col0 * col0 + cor0.col2 FROM tab0 cor0
----
1226
609
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-1642
SELECT ALL - col2 + + cor0.col0 DIV - col2 AS col2 FROM tab0 AS cor0
----
-33
-36
-83

skipif mysql # not compatible
query I rowsort label-1642
SELECT ALL - col2 + + cor0.col0 / - col2 AS col2 FROM tab0 AS cor0
----
-33
-36
-83

query I rowsort
SELECT + - col1 * cor0.col0 + - ( col1 ) * col1 * col1 + - ( - col2 ) * + col0 AS col1 FROM tab2 AS cor0
----
-207953
-29819
-3254

query I rowsort
SELECT ALL col1 * col2 + cor0.col0 + - cor0.col2 FROM tab2 cor0
----
1586
687
817

query I rowsort
SELECT ALL - ( + col1 ) + + ( 26 ) FROM tab0 AS cor0
----
-60
-65
-71

query I rowsort
SELECT DISTINCT + 41 + col0 AS col1 FROM tab0 AS cor0
----
130
65
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 85 + col0 + - ( col2 + col0 ) col0 FROM tab0 AS cor0
----
-118
-167
-86

query I rowsort
SELECT + 3 AS col2 FROM tab2 AS cor0
----
3
3
3

query I rowsort
SELECT ALL - cor0.col0 + col0 * - 34 FROM tab1 AS cor0
----
-105
-2240
-2800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 84 col2 FROM tab0 cor0
----
84
84
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 37 - col2 col2 FROM tab1 AS cor0
----
-17
-20
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1652
SELECT DISTINCT + - 11 * + col2 + - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1652
SELECT DISTINCT + - 11 * + col2 + - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + + col2 * 18 + 54 * col0 + - col1 AS col2 FROM tab1 cor0
----
1108
4472
6035

onlyif mysql # use DIV operator for integer division
query I rowsort label-1654
SELECT ALL col1 + col2 * col0 DIV - col0 AS col1 FROM tab0 AS cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-1654
SELECT ALL col1 + col2 * col0 / - col0 AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL col0 * + 40 FROM tab1 AS cor0
----
120
2560
3200

query I rowsort
SELECT col2 + - col0 * + col2 FROM tab1
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-1657
SELECT col0 + - col0 DIV + col0 AS col1 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-1657
SELECT col0 + - col0 / + col0 AS col1 FROM tab1
----
2
63
79

query I rowsort
SELECT + col0 * ( 54 ) + col0 * col0 AS col0 FROM tab2 AS cor0
----
10296
10507
427

query I rowsort
SELECT col1 + - 98 * + col0 FROM tab2 AS cor0
----
-655
-7585
-7725

onlyif mysql # use DIV operator for integer division
query I rowsort label-1660
SELECT + col0 DIV cor0.col0 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1660
SELECT + col0 / cor0.col0 AS col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - + col1 * + col1 + col0 * + col0 * col1 FROM tab2 AS cor0
----
105808
355475
558

query I rowsort
SELECT - col0 * col0 - - col2 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT ALL - + col0 * 48 FROM tab2 cor0
----
-336
-3744
-3792

query I rowsort
SELECT col1 - col1 * col2 AS col1 FROM tab1 cor0
----
-1235
-1378
-560

query I rowsort
SELECT col2 + col1 * col2 AS col0 FROM tab1
----
1344
1458
627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 72 col1 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT + col1 * + ( + col1 ) AS col0 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-1668
SELECT + ( - 3 ) * + col0 DIV - col0 FROM tab2 AS cor0
----
3
3
3

skipif mysql # not compatible
query I rowsort label-1668
SELECT + ( - 3 ) * + col0 / - col0 FROM tab2 AS cor0
----
3
3
3

query I rowsort
SELECT - ( col1 ) * col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT col1 + + cor0.col0 FROM tab0 cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 + + 58 * - 34 col2 FROM tab1, tab0 cor0
----
-1890
-1939
-1971

query I rowsort
SELECT ALL + cor0.col2 * col0 + 17 * - col0 FROM tab1 cor0
----
111
2560
6320

query I rowsort
SELECT ALL - col2 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-1674
SELECT ALL - col1 * + col2 DIV cor0.col2 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-1674
SELECT ALL - col1 * + col2 / cor0.col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + 67 * col2 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
10854
244416
514560

onlyif mysql # use DIV operator for integer division
query I rowsort label-1676
SELECT DISTINCT + col0 + + col0 DIV - 63 FROM tab0 AS cor0
----
24
35
88

skipif mysql # not compatible
query I rowsort label-1676
SELECT DISTINCT + col0 + + col0 / - 63 FROM tab0 AS cor0
----
24
35
88

query I rowsort
SELECT DISTINCT cor0.col1 + col2 * col1 * - 49 FROM tab2 AS cor0
----
-31637
-40982
-75107

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 * + col2 col2 FROM tab2 AS cor0
----
189
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + cor0.col2 + + 88 * + ( col0 ) col2 FROM tab2 AS cor0
----
650
6968
7069

query I rowsort
SELECT + 25 * col1 AS col2 FROM tab1 AS cor0
----
250
325
650

query I rowsort
SELECT + ( - col0 ) * + col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT - ( - col1 ) * + ( cor0.col0 ) * col1 + + 85 FROM tab2 cor0
----
22916
271603
6812

query I rowsort
SELECT ALL 22 + - col0 * - col0 FROM tab2 AS cor0
----
6106
6263
71

query I rowsort
SELECT ALL + 43 AS col1 FROM tab2 AS cor0
----
43
43
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1685
SELECT DISTINCT - + ( col0 ) * CAST( NULL AS SIGNED ) + col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1685
SELECT DISTINCT - + ( col0 ) * CAST ( NULL AS INTEGER ) + col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - 43 FROM tab0
----
-43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1687
SELECT - CAST( NULL AS SIGNED ) + - cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1687
SELECT - CAST ( NULL AS INTEGER ) + - cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 cor0, tab0 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to 61a671f1b5048e339ad9838f68ebbba4

query I rowsort
SELECT + - ( - 35 ) * - cor0.col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 688b43ac920e8da3bf3c9d161ede23f6

query I rowsort
SELECT + - 38 AS col1 FROM tab2 AS cor0
----
-38
-38
-38

query I rowsort
SELECT + col2 * + col2 + - 61 AS col1 FROM tab0
----
-60
1028
6663

query I rowsort
SELECT ALL - col0 + 14 * + col2 AS col0 FROM tab1 AS cor0
----
1264
734
753

onlyif mysql # use DIV operator for integer division
query I rowsort label-1693
SELECT DISTINCT - - 32 + ( col0 ) DIV col1 AS col2 FROM tab0 AS cor0
----
32

skipif mysql # not compatible
query I rowsort label-1693
SELECT DISTINCT - - 32 + ( col0 ) / col1 AS col2 FROM tab0 AS cor0
----
32

query I rowsort
SELECT DISTINCT - + 26 * col1 FROM tab2 AS cor0
----
-1534
-442
-806

query I rowsort
SELECT col2 * - col2 * col2 - + col1 FROM tab1 AS cor0
----
-157490
-185203
-884749

query I rowsort
SELECT - col0 + col0 * - col1 AS col1 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT + col1 * + 90 AS col2 FROM tab1
----
1170
2340
900

query I rowsort
SELECT DISTINCT - - cor0.col1 + 78 FROM tab0, tab2, tab0 AS cor0
----
164
169
175

query I rowsort
SELECT - 76 + + col1 FROM tab1 AS cor0
----
-50
-63
-66

query I rowsort
SELECT - - cor0.col0 * + cor0.col0 - col0 * + col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL + cor1.col0 - - 68 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to 63fbabe1670494a36e9fde411027b780

query I rowsort
SELECT ( + ( col1 ) ) * - col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT + col0 + + col1 + - tab0.col1 * 39 FROM tab0
----
-3244
-3369
-3651

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1704
SELECT CAST( col0 AS SIGNED ) * - col0 AS col1 FROM tab2
----
-49
-6084
-6241

skipif mysql # not compatible
query I rowsort label-1704
SELECT CAST ( col0 AS INTEGER ) * - col0 AS col1 FROM tab2
----
-49
-6084
-6241

query IIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
243 values hashing to 2ba47a833971d4c4b0287e849fb0cfb8

onlyif mysql # use DIV operator for integer division
query I rowsort label-1706
SELECT 28 DIV - 73 + col2 AS col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1706
SELECT 28 / - 73 + col2 AS col2 FROM tab0
----
1
33
82

query I rowsort
SELECT col0 * + tab0.col2 - + col2 FROM tab0
----
34
7216
759

query I rowsort
SELECT - - col1 + col2 + col2 FROM tab0 AS cor0
----
152
255
99

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 DISTINCT col0 * col1 + col0 AS col2 FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 46 + col2 + col2 col1 FROM tab2
----
100
122
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-1712
SELECT ALL - 69 DIV + col2 + - 73 AS col0 FROM tab1 AS cor0
----
-73
-74
-74

skipif mysql # not compatible
query I rowsort label-1712
SELECT ALL - 69 / + col2 + - 73 AS col0 FROM tab1 AS cor0
----
-73
-74
-74

query I rowsort
SELECT + - 8 + + col1 FROM tab1 AS cor0
----
18
2
5

query I rowsort
SELECT DISTINCT - col1 + - col2 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT ALL + + 93 - col0 AS col2 FROM tab0 cor0
----
4
58
69

query I rowsort
SELECT DISTINCT col1 * col0 * ( - 68 ) AS col0 FROM tab1 cor0
----
-43520
-5304
-70720

query I rowsort
SELECT col0 + cor0.col1 * col0 AS col0 FROM tab1 cor0
----
1120
704
81

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) AS col0 FROM tab2, tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-1719
SELECT cor0.col2 DIV col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1719
SELECT cor0.col2 / col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL - col1 * + tab1.col1 AS col0 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT - tab2.col2 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT ALL col0 + + 95 * col2 * col0 AS col1 FROM tab0 AS cor0
----
3360
693399
75264

query I rowsort
SELECT DISTINCT + col2 + 56 AS col2 FROM tab1 cor0
----
110
113
152

query I rowsort
SELECT ALL col2 * + 46 + + col1 + col2 AS col0 FROM tab2 AS cor0
----
1281
1300
1803

query I rowsort
SELECT + 30 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 6c98840ed134c765d56389f4150075f0

query I rowsort
SELECT ALL + 61 AS col2 FROM tab2, tab1 AS cor0, tab0 cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

query I rowsort
SELECT + 35 + 64 + col0 FROM tab1 AS cor0
----
102
163
179

query I rowsort
SELECT ALL - col0 * col1 * - col0 AS col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT col0 * - 55 AS col1 FROM tab2 AS cor0
----
-385
-4290
-4345

query I rowsort
SELECT - 28 + col2 * + col0 FROM tab2 AS cor0
----
161
2000
2974

query I rowsort
SELECT 86 - col2 * cor0.col0 FROM tab0 cor0
----
-706
-7212
51

query I rowsort
SELECT DISTINCT - - ( 36 ) * + col0 - col1 FROM tab1 AS cor0
----
2294
2867
82

query I rowsort
SELECT - 99 * 51 + col2 AS col2 FROM tab0 AS cor0
----
-4967
-5016
-5048

query I rowsort
SELECT ALL col0 + 79 AS col1 FROM tab1 cor0
----
143
159
82

query I rowsort
SELECT ALL ( col1 ) * - col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ( + 18 ) * + cor0.col1 + ( + col0 * + col1 ) + + ( + col0 ) * - col0 FROM tab1 AS cor0
----
-3276
-5126
537

query I rowsort
SELECT ALL + col1 + - col0 * col0 AS col2 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT - 62 AS col2 FROM tab2 AS cor0
----
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-1739
SELECT ALL col0 * col1 DIV 46 AS col1 FROM tab0
----
176
44
73

skipif mysql # not compatible
query I rowsort label-1739
SELECT ALL col0 * col1 / 46 AS col1 FROM tab0
----
176
44
73

query I rowsort
SELECT DISTINCT cor0.col2 * - col1 + col1 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-1741
SELECT col1 * 70 DIV + 96 AS col2 FROM tab1 AS cor0
----
18
7
9

skipif mysql # not compatible
query I rowsort label-1741
SELECT col1 * 70 / + 96 AS col2 FROM tab1 AS cor0
----
18
7
9

query I rowsort
SELECT col0 * cor0.col2 - - col1 AS col0 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT + 16 + + col0 AS col0 FROM tab2
----
23
94
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1744
SELECT - col2 + - col2 * + CAST( 47 AS SIGNED ) AS col0 FROM tab2
----
-1248
-1296
-1824

skipif mysql # not compatible
query I rowsort label-1744
SELECT - col2 + - col2 * + CAST ( 47 AS INTEGER ) AS col0 FROM tab2
----
-1248
-1296
-1824

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 col0 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT - col2 * + ( col0 ) + col2 FROM tab2
----
-162
-2002
-2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab0.col1 + - 40 + ( - col0 ) * + ( col2 ) col0 FROM tab0
----
-7247
-746
22

query I rowsort
SELECT - col2 + col2 + col2 * + col0 FROM tab2
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1749
SELECT + cor0.col1 * CAST( NULL AS SIGNED ) + + 38 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1749
SELECT + cor0.col1 * CAST ( NULL AS INTEGER ) + + 38 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 47 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

query I rowsort
SELECT col1 * col2 - 87 AS col1 FROM tab2 AS cor0
----
1447
559
750

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * + 61 - - 42 * cor0.col2 col1 FROM tab0 AS cor0
----
-1985
-2093
-78

query I rowsort
SELECT DISTINCT col0 - col2 AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT cor1.col0 * cor0.col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
9 values hashing to 54522441dbf7fb56e19a888572d1f6e3

query I rowsort
SELECT col0 + + tab1.col1 * tab1.col1 AS col0 FROM tab1
----
164
249
679

onlyif mysql # use DIV operator for integer division
query I rowsort label-1756
SELECT col1 DIV - col1 + - col1 AS col0 FROM tab0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-1756
SELECT col1 / - col1 + - col1 AS col0 FROM tab0
----
-87
-92
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 57 col2 FROM tab2
----
57

query I rowsort
SELECT ALL col2 * + 24 FROM tab0
----
1968
24
792

query I rowsort
SELECT ALL 68 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

query I rowsort
SELECT - 32 AS col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 7106326ae056e78044adc0aef747ef08

query I rowsort
SELECT DISTINCT + 60 AS col2 FROM tab1
----
60

query I rowsort
SELECT DISTINCT + - 8 + - col0 * 18 FROM tab1 cor0
----
-1160
-1448
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 91 - + col1 col1 FROM tab2 AS cor0
----
32
60
74

query I rowsort
SELECT ALL 57 * + col2 - + ( col2 ) AS col1 FROM tab1 AS cor0
----
3024
3192
5376

query I rowsort
SELECT DISTINCT - - ( col2 ) * + ( col1 ) + col1 * + 37 + - 33 FROM tab1 cor0
----
1696
2333
907

query I rowsort
SELECT DISTINCT 0 + - 55 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
-55

query I rowsort
SELECT DISTINCT - - 61 AS col2 FROM tab1 cor0
----
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col1 col0 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 26 col0 FROM tab1 AS cor0
----
26
26
26

query I rowsort
SELECT - - 99 AS col1 FROM tab0 cor0
----
99
99
99

query I rowsort
SELECT DISTINCT cor0.col1 + col0 AS col2 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1772
SELECT ALL - col1 DIV cor0.col1 - col1 FROM tab0 AS cor0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-1772
SELECT ALL - col1 / cor0.col1 - col1 FROM tab0 AS cor0
----
-87
-92
-98

query I rowsort
SELECT DISTINCT - + cor0.col2 + col1 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-1774
SELECT ALL + - col2 DIV - col0 AS col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1774
SELECT ALL + - col2 / - col0 AS col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT DISTINCT + + ( + col1 ) AS col2 FROM tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * - 26 col0 FROM tab1 AS cor0
----
260
338
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1777
SELECT - col2 * + CAST( NULL AS DECIMAL ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1777
SELECT - col2 * + CAST ( NULL AS REAL ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 50 + - cor0.col1 col2 FROM tab0 AS cor0
----
-136
-141
-147

onlyif mysql # use DIV operator for integer division
query I rowsort label-1779
SELECT + col1 DIV 26 AS col0 FROM tab2 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-1779
SELECT + col1 / 26 AS col0 FROM tab2 AS cor0
----
0
1
2

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 col2 * + col2 + col2 col1 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL 83 * - 66 AS col1 FROM tab0 AS cor0
----
-5478
-5478
-5478

query I rowsort
SELECT - tab2.col0 * - 72 AS col2 FROM tab2
----
504
5616
5688

query I rowsort
SELECT ( + cor0.col2 ) + + col1 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT col2 * 67 AS col0 FROM tab1
----
3618
3819
6432

query I rowsort
SELECT - + col0 * 45 + cor0.col2 FROM tab1 AS cor0
----
-2823
-3504
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + 21 + - 16 * col1 col1 FROM tab2 AS cor0
----
-349
1387
694

query I rowsort
SELECT col0 + 10 + col1 AS col1 FROM tab2 AS cor0
----
106
147
48

query I rowsort
SELECT DISTINCT col2 * + col2 + col2 * + col2 AS col0 FROM tab1 AS cor0
----
18432
5832
6498

query I rowsort
SELECT DISTINCT col2 - col1 * 3 * col2 FROM tab0 AS cor0
----
-22304
-290
-8481

onlyif mysql # use DIV operator for integer division
query I rowsort label-1791
SELECT - col1 DIV - 35 + ( - col1 + - col0 ) * - 58 AS col1 FROM tab2 AS cor0
----
2204
5568
7947

skipif mysql # not compatible
query I rowsort label-1791
SELECT - col1 / - 35 + ( - col1 + - col0 ) * - 58 AS col1 FROM tab2 AS cor0
----
2204
5568
7947

query I rowsort
SELECT DISTINCT - col2 + col1 * col1 * col0 AS col0 FROM tab2 AS cor0
----
22793
271492
6700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 + + ( + cor0.col2 ) * col1 + col2 col2 FROM tab2 AS cor0
----
1638
763
871

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col1 * + col2 col0 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - col1 * - 36 FROM tab2 cor0
----
1116
2124
612

query I rowsort
SELECT ALL - - col1 + col0 * + col1 FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1797
SELECT + CAST( NULL AS SIGNED ) * + cor0.col1 / col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1797
SELECT + CAST ( NULL AS INTEGER ) * + cor0.col1 / col0 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( - 4 ) FROM tab2 AS cor0
----
-4

query I rowsort
SELECT + - col2 * 72 AS col1 FROM tab0 cor0
----
-2376
-5904
-72

query I rowsort
SELECT DISTINCT - col2 + - cor0.col2 FROM tab2 cor0
----
-52
-54
-76

query I rowsort
SELECT ALL - - col0 + col0 * cor0.col2 AS col1 FROM tab1 AS cor0
----
165
3712
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - 0 * cor0.col1 col0 FROM tab0 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1803
SELECT + CAST( NULL AS SIGNED ) + - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1803
SELECT + 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 ALL col1 * col1 - + 44 * - col1 col0 FROM tab2
----
1037
2325
6077

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 11 col0 FROM tab0 cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 69116737f3f57e2e3273f6dbb04d036c

query I rowsort
SELECT + tab2.col0 * 92 FROM tab2, tab0 AS cor0
----
9 values hashing to 9596028634f7ef5bc08792444e59b3e7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 61 col0 FROM tab2 AS cor0
----
61
61
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * cor0.col0 + 17 + - 40 col2 FROM tab1 cor0
----
-14
4073
6377

query I rowsort
SELECT - 33 + col2 * ( - col1 ) AS col2 FROM tab2 cor0
----
-1567
-679
-870

query I rowsort
SELECT 4 + col2 FROM tab0
----
37
5
86

query I rowsort
SELECT DISTINCT col0 + - ( - 20 ) - + col0 FROM tab2 AS cor0
----
20

query I rowsort
SELECT ALL + + col2 + + ( - 88 * + col0 ) + col1 * + col0 * + col1 FROM tab0 AS cor0
----
175425
326236
729259

query I rowsort
SELECT - + col0 * ( - 83 ) FROM tab0 AS cor0
----
1992
2905
7387

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1814
SELECT DISTINCT + CAST( + 82 AS SIGNED ) FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
82

skipif mysql # not compatible
query I rowsort label-1814
SELECT DISTINCT + CAST ( + 82 AS INTEGER ) FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
82

query I rowsort
SELECT - tab1.col1 * 39 FROM tab1, tab0 AS cor0
----
9 values hashing to 8f9f14ef6fc1705922ed31c1c226478a

query I rowsort
SELECT col1 * + 42 AS col2 FROM tab0
----
3612
3822
4074

query I rowsort
SELECT DISTINCT + tab0.col1 + - col0 AS col1 FROM tab0
----
2
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 4 + + ( + col1 ) col0 FROM tab1
----
24
30
56

query I rowsort
SELECT ALL col2 * + col2 - col1 AS col0 FROM tab2
----
1427
617
698

query I rowsort
SELECT + + col0 - - ( col2 ) * col0 AS col1 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT - + col0 * ( col2 ) AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL col0 + - 53 AS col2 FROM tab0 cor0
----
-18
-29
36

query I rowsort
SELECT ALL + cor0.col2 + col0 AS col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - col2 + col0 * cor0.col0 AS col1 FROM tab2 AS cor0
----
22
6058
6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-1825
SELECT ALL - col2 DIV + col0 - - col0 col2 FROM tab2 AS cor0
----
4
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1825
SELECT ALL - col2 / + col0 - - col0 col2 FROM tab2 AS cor0
----
4
78
79

query I rowsort
SELECT + col0 + - ( cor0.col1 ) FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT - 74 FROM tab1, tab0, tab2 AS cor0, tab0 AS cor1
----
81 values hashing to 83dc6c0e38784f5f5c6b91de33ab4ff1

query I rowsort
SELECT + ( + 89 * tab2.col1 ) - col1 * 9 FROM tab2
----
1360
2480
4720

query I rowsort
SELECT ALL 50 * col2 + + col2 * + 38 FROM tab0
----
2904
7216
88

query I rowsort
SELECT - + col0 + ( + col0 ) * col0 AS col1 FROM tab2 AS cor0
----
42
6006
6162

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to 2270901c73a658a63f841c68db8155ba

query I rowsort
SELECT DISTINCT 39 * - ( tab2.col0 ) + + col1 * - 58 FROM tab2
----
-2071
-4067
-6464

query I rowsort
SELECT + 86 FROM tab2, tab1 AS cor0
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

query I rowsort
SELECT - - 4 * + col1 FROM tab0 AS cor0
----
344
364
388

query I rowsort
SELECT ALL 37 * - cor0.col0 FROM tab1 cor0
----
-111
-2368
-2960

query I rowsort
SELECT DISTINCT + 24 AS col2 FROM tab1 cor0
----
24

query I rowsort
SELECT 11 * col2 FROM tab1 AS cor0
----
1056
594
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-1838
SELECT ALL + 72 DIV + cor0.col2 AS col0 FROM tab1 cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-1838
SELECT ALL + 72 / + cor0.col2 AS col0 FROM tab1 cor0
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 73 * - col2 col2 FROM tab2 AS cor0
----
-1898
-1971
-2774

query I rowsort
SELECT ALL + ( + 26 ) AS col1 FROM tab1
----
26
26
26

query I rowsort
SELECT ALL + ( tab1.col1 ) FROM tab1, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT - - col1 * col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL 18 * + col2 FROM tab0 AS cor0
----
1476
18
594

query I rowsort
SELECT ALL 68 + cor0.col2 * col2 FROM tab1 cor0
----
2984
3317
9284

query I rowsort
SELECT DISTINCT + 66 * - col2 AS col1 FROM tab1 AS cor0
----
-3564
-3762
-6336

query I rowsort
SELECT ALL - - col2 + + cor0.col0 * col1 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-1847
SELECT ALL + - col2 DIV + cor0.col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1847
SELECT ALL + - col2 / + cor0.col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL + col1 * - 42 FROM tab2 AS cor0
----
-1302
-2478
-714

query I rowsort
SELECT DISTINCT - 54 AS col2 FROM tab0 AS cor0
----
-54

onlyif mysql # use DIV operator for integer division
query I rowsort label-1850
SELECT DISTINCT - + 8 DIV + col0 AS col2 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-1850
SELECT DISTINCT - + 8 / + col0 AS col2 FROM tab2 AS cor0
----
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1851
SELECT + - cor0.col1 + ( - col2 ) DIV + col2 FROM tab1 AS cor0
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-1851
SELECT + - cor0.col1 + ( - col2 ) / + col2 FROM tab1 AS cor0
----
-11
-14
-27

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1852
SELECT - CAST( NULL AS SIGNED ) * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1852
SELECT - CAST ( NULL AS INTEGER ) * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 53 + + ( col0 ) * col2 FROM tab0 AS cor0
----
7351
845
88

query I rowsort
SELECT ALL col0 - + 53 AS col1 FROM tab2
----
-46
25
26

query I rowsort
SELECT ALL tab1.col0 * + col1 + - col0 FROM tab1
----
576
75
960

onlyif mysql # use DIV operator for integer division
query I rowsort label-1856
SELECT ALL + 50 + + 53 * tab2.col1 + col2 DIV + 58 FROM tab2
----
1693
3177
951

skipif mysql # not compatible
query I rowsort label-1856
SELECT ALL + 50 + + 53 * tab2.col1 + col2 / + 58 FROM tab2
----
1693
3177
951

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1857
SELECT - 61 + + col2 + CAST( col0 * col2 AS SIGNED ) FROM tab1 AS cor0
----
155
3644
7715

skipif mysql # not compatible
query I rowsort label-1857
SELECT - 61 + + col2 + CAST ( col0 * col2 AS INTEGER ) FROM tab1 AS cor0
----
155
3644
7715

query I rowsort
SELECT + col1 * cor0.col1 + 1 + - col2 AS col0 FROM tab0 AS cor0
----
7364
8200
9409

query I rowsort
SELECT - - col2 * + col1 + col2 + + cor0.col2 FROM tab1 AS cor0
----
1440
1512
684

query I rowsort
SELECT 37 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

query I rowsort
SELECT DISTINCT 44 FROM tab0, tab2 AS cor0
----
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-1862
SELECT DISTINCT ( col1 ) DIV col0 AS col0 FROM tab1
----
0
8

skipif mysql # not compatible
query I rowsort label-1862
SELECT DISTINCT ( col1 ) / col0 AS col0 FROM tab1
----
0
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-1863
SELECT ALL tab0.col0 DIV col0 AS col1 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1863
SELECT ALL tab0.col0 / col0 AS col1 FROM tab0
----
1
1
1

query I rowsort
SELECT ALL + ( - col2 * col0 ) AS col2 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL - 56 AS col0 FROM tab0
----
-56
-56
-56

query I rowsort
SELECT ALL col0 + col2 * 15 AS col2 FROM tab2
----
412
468
649

query I rowsort
SELECT DISTINCT - col0 + col0 * col0 + + col2 FROM tab2 AS cor0
----
6032
6200
69

query I rowsort
SELECT ALL + col2 * 39 FROM tab1 AS cor0
----
2106
2223
3744

query I rowsort
SELECT ALL - col0 * cor0.col0 + col1 AS col0 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT - + col1 * 48 * + col1 + - cor0.col0 AS col1 FROM tab2 AS cor0
----
-13951
-167166
-46135

query I rowsort
SELECT ALL + + col0 + col2 + col0 AS col2 FROM tab2 AS cor0
----
182
196
41

query I rowsort
SELECT DISTINCT + ( - col2 ) + tab2.col2 FROM tab2
----
0

query I rowsort
SELECT - tab2.col2 + col1 FROM tab2
----
-21
33
4

query I rowsort
SELECT + ( - col0 + - col1 ) * - col0 AS col0 FROM tab1
----
4736
7440
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col0 col2 FROM tab0
----
178
48
70

query I rowsort
SELECT DISTINCT + cor3.col2 FROM tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 AS cor2, tab2 AS cor3
----
26
27
38

query I rowsort
SELECT - ( cor1.col1 ) + 0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1878
SELECT DISTINCT + CAST( NULL AS SIGNED ) FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 AS cor2
----
NULL

skipif mysql # not compatible
query I rowsort label-1878
SELECT DISTINCT + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 AS cor2
----
NULL

query I rowsort
SELECT DISTINCT + col1 + + ( 26 ) FROM tab2 AS cor0
----
43
57
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1880
SELECT ALL cor0.col2 * + ( - col2 ) * col2 - + CAST( NULL AS SIGNED ) * col1 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1880
SELECT ALL cor0.col2 * + ( - col2 ) * col2 - + CAST ( NULL AS INTEGER ) * col1 col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col2 + + 34 AS col2 FROM tab2 AS cor0
----
60
61
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-1882
SELECT ALL - col2 DIV col0 AS col0 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-1882
SELECT ALL - col2 / col0 AS col0 FROM tab1 AS cor0
----
-1
-18
0

query I rowsort
SELECT col1 * 37 FROM tab2 AS cor0
----
1147
2183
629

query I rowsort
SELECT ALL - col1 + - 91 * col2 * + col2 FROM tab1 AS cor0
----
-265382
-295669
-838669

onlyif mysql # use DIV operator for integer division
query I rowsort label-1885
SELECT DISTINCT + cor0.col0 DIV - cor0.col0 + col0 + col2 AS col0 FROM tab1 AS cor0
----
120
175
56

skipif mysql # not compatible
query I rowsort label-1885
SELECT DISTINCT + cor0.col0 / - cor0.col0 + col0 + col2 AS col0 FROM tab1 AS cor0
----
120
175
56

query I rowsort
SELECT ALL - + col2 + ( col0 ) FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-1887
SELECT ALL + cor0.col2 DIV + ( + col0 ) col1 FROM tab2 AS cor0
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1887
SELECT ALL + cor0.col2 / + ( + col0 ) col1 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT ALL + col2 + - ( + col1 ) FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT col0 + + 14 - + col2 FROM tab2 AS cor0
----
-6
55
66

query I rowsort
SELECT + + col1 + - cor0.col1 * + 29 FROM tab2 AS cor0
----
-1652
-476
-868

query I rowsort
SELECT DISTINCT col0 * + 11 + 98 FROM tab1 AS cor0
----
131
802
978

query I rowsort
SELECT + col1 * + 87 AS col1 FROM tab0
----
7482
7917
8439

query I rowsort
SELECT ALL + col2 * 63 FROM tab0
----
2079
5166
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 82 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

onlyif mysql # use DIV operator for integer division
query I rowsort label-1895
SELECT ALL + col2 DIV + 60 AS col1 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-1895
SELECT ALL + col2 / + 60 AS col1 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT - cor0.col2 + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 - col0 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT 75 AS col0 FROM tab2, tab0 cor0
----
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1899
SELECT ALL CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1899
SELECT ALL CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab1 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + col2 + 5 AS col0 FROM tab0 AS cor0
----
38
6
87

query I rowsort
SELECT - + col0 * + 12 * + col1 FROM tab1 AS cor0
----
-12480
-7680
-936

query I rowsort
SELECT ALL + 95 * col1 AS col0 FROM tab1
----
1235
2470
950

query I rowsort
SELECT ( col2 ) - + col1 FROM tab2 AS cor0
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-1904
SELECT DISTINCT + col2 + + col2 * col1 DIV - cor0.col2 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

skipif mysql # not compatible
query I rowsort label-1904
SELECT DISTINCT + col2 + + col2 * col1 / - cor0.col2 AS col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - 43 * col0 FROM tab2 AS cor0
----
-301
-3354
-3397

query I rowsort
SELECT + + 93 FROM tab0 AS cor0
----
93
93
93

query I rowsort
SELECT + - col1 * col1 - col0 * - col2 AS col0 FROM tab0 AS cor0
----
-6604
-9374
-983

query I rowsort
SELECT - cor0.col0 - - col0 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1909
SELECT DISTINCT col0 DIV col1 + 25 * col1 FROM tab1 AS cor0
----
256
331
650

skipif mysql # not compatible
query I rowsort label-1909
SELECT DISTINCT col0 / col1 + 25 * col1 FROM tab1 AS cor0
----
256
331
650

query I rowsort
SELECT + 91 + col1 * - cor0.col2 AS col2 FROM tab0 cor0
----
-2747
-6
-7371

query I rowsort
SELECT ALL - 42 * - col0 AS col0 FROM tab2 AS cor0
----
294
3276
3318

query I rowsort
SELECT + col0 - col0 * col2 AS col0 FROM tab0 AS cor0
----
-7209
-768
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 33 col0 FROM tab1 AS cor0
----
-2112
-2640
-99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1914
SELECT col2 + - CAST( NULL AS SIGNED ) / - 26 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1914
SELECT col2 + - CAST ( NULL AS INTEGER ) / - 26 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 36 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to afecaf209e79e23b6674a73fffa3e837

onlyif mysql # use DIV operator for integer division
query I rowsort label-1916
SELECT DISTINCT - - col0 + col2 DIV 28 - - col0 * col0 FROM tab1 AS cor0
----
13
4162
6483

skipif mysql # not compatible
query I rowsort label-1916
SELECT DISTINCT - - col0 + col2 / 28 - - col0 * col0 FROM tab1 AS cor0
----
13
4162
6483

query I rowsort
SELECT - col2 * col0 + + col1 * - col0 AS col1 FROM tab0 cor0
----
-15397
-2856
-3430

query I rowsort
SELECT DISTINCT 32 + - col0 FROM tab2
----
-46
-47
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-1919
SELECT + col2 * col1 DIV - tab1.col1 + tab1.col0 AS col1 FROM tab1
----
-16
-51
7

skipif mysql # not compatible
query I rowsort label-1919
SELECT + col2 * col1 / - tab1.col1 + tab1.col0 AS col1 FROM tab1
----
-16
-51
7

query I rowsort
SELECT 58 + - col2 AS col0 FROM tab2
----
20
31
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 68 * col0 col1 FROM tab1
----
204
4352
5440

query I rowsort
SELECT ALL + ( 2 ) AS col0 FROM tab2
----
2
2
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-1923
SELECT col1 DIV + tab0.col0 AS col1 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-1923
SELECT col1 / + tab0.col0 AS col1 FROM tab0
----
1
2
3

query I rowsort
SELECT DISTINCT - cor0.col1 * tab2.col2 FROM tab2, tab1, tab2 AS cor0
----
9 values hashing to 3f5ea019223361c8c7a5502ecc1aeefb

query I rowsort
SELECT 75 * + col2 + tab0.col2 AS col1 FROM tab0
----
2508
6232
76

query I rowsort
SELECT tab0.col2 + - 14 * + col0 AS col0 FROM tab0
----
-1164
-303
-489

onlyif mysql # use DIV operator for integer division
query I rowsort label-1927
SELECT + 37 DIV - cor0.col1 + col1 AS col2 FROM tab1 AS cor0
----
11
25
7

skipif mysql # not compatible
query I rowsort label-1927
SELECT + 37 / - cor0.col1 + col1 AS col2 FROM tab1 AS cor0
----
11
25
7

query I rowsort
SELECT DISTINCT + col2 * + col2 + - col2 AS col0 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT ALL - col2 - - col0 AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT 9 * col1 AS col0 FROM tab0
----
774
819
873

query I rowsort
SELECT col2 * - col0 - + col2 AS col2 FROM tab2 AS cor0
----
-2054
-216
-3040

query I rowsort
SELECT DISTINCT - cor0.col0 * col0 AS col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT 64 * col0 * - col2 FROM tab0 cor0
----
-2240
-467072
-50688

query I rowsort
SELECT DISTINCT - - col2 + - col0 AS col2 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT + + col1 * cor0.col0 + col0 AS col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT DISTINCT - + 83 + col1 AS col2 FROM tab1 AS cor0
----
-57
-70
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col1 + + cor0.col2 col1 FROM tab2 cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT col2 * - col2 + cor0.col1 * cor0.col2 FROM tab2 AS cor0
----
-798
108
858

onlyif mysql # use DIV operator for integer division
query I rowsort label-1939
SELECT DISTINCT 61 DIV + col2 FROM tab0 cor0
----
0
1
61

skipif mysql # not compatible
query I rowsort label-1939
SELECT DISTINCT 61 / + col2 FROM tab0 cor0
----
0
1
61

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab1, tab1 cor2
----
3645 values hashing to 44545a6297aa29bb730ffb907c13bc58

query I rowsort
SELECT col1 * ( - col1 ) FROM tab1 AS cor0
----
-100
-169
-676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 85 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

query I rowsort
SELECT DISTINCT cor0.col1 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
10
13
26

query I rowsort
SELECT - - col0 * 30 * col0 + cor0.col0 * col2 AS col0 FROM tab2 AS cor0
----
1659
184548
190232

onlyif mysql # use DIV operator for integer division
query I rowsort label-1945
SELECT DISTINCT col0 DIV cor0.col0 + + 68 FROM tab1 AS cor0
----
69

skipif mysql # not compatible
query I rowsort label-1945
SELECT DISTINCT col0 / cor0.col0 + + 68 FROM tab1 AS cor0
----
69

query I rowsort
SELECT + col2 * 27 + 53 * col0 FROM tab2 AS cor0
----
1100
4836
5213

query I rowsort
SELECT - cor0.col2 * + 18 FROM tab0 AS cor0
----
-1476
-18
-594

query I rowsort
SELECT + ( col0 ) * + cor0.col1 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL + ( - col2 ) * cor0.col0 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - 86 * col2 AS col0 FROM tab2 AS cor0
----
-2236
-2322
-3268

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1951
SELECT CAST( NULL AS SIGNED ) * 73 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1951
SELECT CAST ( NULL AS INTEGER ) * 73 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 + ( col2 ) * + cor0.col2 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT ALL + + col0 * cor0.col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-1954
SELECT col1 + - col2 DIV - col2 AS col0 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-1954
SELECT col1 + - col2 / - col2 AS col0 FROM tab1 AS cor0
----
11
14
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-1955
SELECT - col1 DIV - col1 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1955
SELECT - col1 / - col1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT col2 * - col2 * col0 AS col1 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT + col0 + + tab1.col2 * col0 FROM tab1
----
165
3712
7760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + - col1 col0 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ALL - - cor0.col2 * col0 + col0 AS col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT + - col0 + + col0 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 * - cor0.col1 col1 FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col2 + + col2 * col2 col0 FROM tab0 cor0
----
1146
37
6895

query I rowsort
SELECT ALL + cor0.col0 + - col0 + cor0.col1 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-1964
SELECT ALL - - col2 DIV col0 + col0 FROM tab0 AS cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-1964
SELECT ALL - - col2 / col0 + col0 FROM tab0 AS cor0
----
25
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-1965
SELECT ALL + col2 DIV + col1 col0 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1965
SELECT ALL + col2 / + col1 col0 FROM tab0
----
0
0
0

query I rowsort
SELECT col0 + + col0 * + col1 AS col0 FROM tab0
----
2088
3430
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-1967
SELECT col1 + + tab0.col2 DIV col2 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-1967
SELECT col1 + + tab0.col2 / col2 FROM tab0
----
87
92
98

query I rowsort
SELECT col0 + - col2 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT ALL + col1 + - col1 * col2 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL - + col1 * - col1 + + col0 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT + - cor0.col0 * col0 * col0 FROM tab2 AS cor0
----
-343
-474552
-493039

query I rowsort
SELECT DISTINCT - + col2 + - col1 * col1 FROM tab2 AS cor0
----
-327
-3507
-988

onlyif mysql # use DIV operator for integer division
query I rowsort label-1973
SELECT + ( col2 ) * - col1 DIV + tab0.col1 + col0 * tab0.col1 AS col2 FROM tab0
----
2031
3394
8017

skipif mysql # not compatible
query I rowsort label-1973
SELECT + ( col2 ) * - col1 / + tab0.col1 + col0 * tab0.col1 AS col2 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT 62 * col2 - col1 FROM tab2
----
1553
1643
2339

query I rowsort
SELECT - 43 * - col2 FROM tab1
----
2322
2451
4128

query I rowsort
SELECT col1 * col1 * tab0.col1 - col1 AS col1 FROM tab0
----
635970
753480
912576

query I rowsort
SELECT DISTINCT col1 * - col0 + + col2 * - col2 FROM tab0
----
-14823
-3153
-3396

query I rowsort
SELECT - col1 * col1 * + col0 + - col2 * col2 FROM tab0
----
-178593
-329316
-743733

onlyif mysql # use DIV operator for integer division
query I rowsort label-1979
SELECT ALL + col1 DIV + col1 + col1 FROM tab2
----
18
32
60

skipif mysql # not compatible
query I rowsort label-1979
SELECT ALL + col1 / + col1 + col1 FROM tab2
----
18
32
60

query I rowsort
SELECT DISTINCT col2 * col2 * col0 + - col1 AS col1 FROM tab1
----
207926
737267
8722

query I rowsort
SELECT + col2 + + tab2.col2 * col0 FROM tab2
----
2054
216
3040

query I rowsort
SELECT DISTINCT - cor0.col1 - col1 * col1 AS col1 FROM tab0 AS cor0
----
-7482
-8372
-9506

query I rowsort
SELECT DISTINCT col1 + cor0.col0 AS col1 FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col1 + + col1 * - col1 col1 FROM tab2
----
-744
1054
1121

query I rowsort
SELECT col0 + - col0 AS col1 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1986
SELECT tab0.col0 DIV + 62 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

skipif mysql # not compatible
query I rowsort label-1986
SELECT tab0.col0 / + 62 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 14fcfa6c11198893073049d94262832c

query I rowsort
SELECT ( col0 ) * + 64 FROM tab2
----
448
4992
5056

query I rowsort
SELECT + + cor0.col1 + + col2 * ( - cor0.col1 ) * col1 FROM tab1 AS cor0
----
-16211
-36478
-5690

query I rowsort
SELECT DISTINCT - ( + col2 ) * 71 FROM tab2 AS cor0
----
-1846
-1917
-2698

query I rowsort
SELECT 87 * + col0 FROM tab1 AS cor0
----
261
5568
6960

query I rowsort
SELECT - 61 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 51f53697966a79d306a4570537cd91a1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1992
SELECT ALL - - col1 + col1 DIV col2 AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-1992
SELECT ALL - - col1 + col1 / col2 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + 53 * + col2 FROM tab2 cor0
----
1378
1431
2014

query I rowsort
SELECT DISTINCT col0 * + col2 + 63 * cor0.col0 + col2 FROM tab2 AS cor0
----
657
6968
8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1995
SELECT + col1 * CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1995
SELECT + col1 * CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 * col1 * col2 FROM tab0 cor0
----
244068
679042
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-1997
SELECT ALL 96 DIV col2 AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1997
SELECT ALL 96 / col2 AS col2 FROM tab1
----
1
1
1

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1999
SELECT DISTINCT - + CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1999
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) * col1 AS col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2000
SELECT ALL + cor0.col0 DIV - 59 AS col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2000
SELECT ALL + cor0.col0 / - 59 AS col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT ALL + ( + col1 ) * + col2 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + 50 AS col1 FROM tab2 cor0
----
50
50
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( cor0.col0 ) * + col1 col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + col1 * 68 - - col1 * + col1 FROM tab1
----
1053
2444
780

onlyif mysql # use DIV operator for integer division
query I rowsort label-2005
SELECT - col1 + - 93 DIV col1 - + 71 FROM tab2 cor0
----
-105
-131
-93

skipif mysql # not compatible
query I rowsort label-2005
SELECT - col1 + - 93 / col1 - + 71 FROM tab2 cor0
----
-105
-131
-93

query I rowsort
SELECT DISTINCT col2 * + cor0.col0 + cor0.col0 + + 1 * ( + col2 * + col2 ) AS col2 FROM tab1 AS cor0
----
16976
3081
6961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * col1 + - cor0.col0 - col1 col2 FROM tab2 AS cor0
----
-1439
-255
-4739

query I rowsort
SELECT tab1.col0 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT - - 95 AS col2 FROM tab1 cor0
----
95
95
95

query I rowsort
SELECT DISTINCT 69 * + 75 FROM tab1
----
5175

query I rowsort
SELECT ( 52 ) AS col2 FROM tab1
----
52
52
52

query I rowsort
SELECT + 85 + col0 FROM tab2
----
163
164
92

query I rowsort
SELECT col1 + ( col1 ) AS col1 FROM tab1
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-2014
SELECT ALL col1 DIV 38 + col0 + col1 AS col1 FROM tab2
----
138
38
96

skipif mysql # not compatible
query I rowsort label-2014
SELECT ALL col1 / 38 + col0 + col1 AS col1 FROM tab2
----
138
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + 31 col0 FROM tab2
----
57
58
69

query I rowsort
SELECT ALL 18 * cor0.col2 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to f3762691e4a423c4281dd8ce8a25a896

query I rowsort
SELECT - 21 * - tab1.col2 AS col1 FROM tab1
----
1134
1197
2016

query I rowsort
SELECT DISTINCT tab1.col1 + + 60 AS col1 FROM tab1
----
70
73
86

query I rowsort
SELECT + col1 + col1 AS col1 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT + col0 + - cor0.col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT + col1 + col1 - col2 FROM tab0 AS cor0
----
100
139
193

query I rowsort
SELECT cor0.col2 + - col2 AS col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT + - 39 * cor0.col1 AS col1 FROM tab0 AS cor0
----
-3354
-3549
-3783

query I rowsort
SELECT ALL + - col0 + col1 * col1 AS col0 FROM tab2 cor0
----
210
3403
954

query I rowsort
SELECT ALL + col1 * + ( 5 + - col2 ) * col0 AS col0 FROM tab2 AS cor0
----
-44319
-4774
-96642

query I rowsort
SELECT + cor0.col2 * cor0.col1 AS col1 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * ( col1 ) col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + col2 * + ( - 48 ) AS col0 FROM tab0 AS cor0
----
-1584
-3936
-48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 77 * + col2 col1 FROM tab2
----
-2002
-2079
-2926

query I rowsort
SELECT - col2 + + cor0.col2 * 99 FROM tab0 AS cor0
----
3234
8036
98

query I rowsort
SELECT DISTINCT + 7 FROM tab1, tab2, tab1 cor0
----
7

query I rowsort
SELECT 99 + 86 AS col2 FROM tab0 AS cor0
----
185
185
185

query I rowsort
SELECT ( ( + col2 ) ) * col0 * + col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT - 54 * - col2 AS col1 FROM tab0 AS cor0
----
1782
4428
54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2035
SELECT - CAST( + col2 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-2035
SELECT - CAST ( + col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL 68 + 78 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 708ab89da52f5539ae8cc2b28295d0f9

query I rowsort
SELECT ALL + 76 FROM tab1, tab0 AS cor0
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2038
SELECT + col2 DIV col0 - cor0.col2 * + col0 * col0 FROM tab2 cor0
----
-1320
-158184
-237158

skipif mysql # not compatible
query I rowsort label-2038
SELECT + col2 / col0 - cor0.col2 * + col0 * col0 FROM tab2 cor0
----
-1320
-158184
-237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-2039
SELECT + - col0 - col0 DIV col2 AS col0 FROM tab0 AS cor0
----
-24
-70
-90

skipif mysql # not compatible
query I rowsort label-2039
SELECT + - col0 - col0 / col2 AS col0 FROM tab0 AS cor0
----
-24
-70
-90

query I rowsort
SELECT - + 23 * - col1 + col2 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
1037
1550
2891

query I rowsort
SELECT - 77 * 92 AS col0 FROM tab0 AS cor0
----
-7084
-7084
-7084

query I rowsort
SELECT ALL 80 * col1 + + cor0.col1 FROM tab0 AS cor0
----
6966
7371
7857

query I rowsort
SELECT ALL + ( col2 ) * - col2 AS col1 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - 70 + - 32 * col0 * col2 FROM tab2 AS cor0
----
-6118
-64966
-96134

onlyif mysql # use DIV operator for integer division
query I rowsort label-2045
SELECT DISTINCT col0 + + col1 DIV - col2 AS col2 FROM tab1 cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-2045
SELECT DISTINCT col0 + + col1 / - col2 AS col2 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT DISTINCT col0 + ( col2 ) FROM tab0 AS cor0
----
171
36
57

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( ( - col2 ) AS REAL ) + + ( - col1 ) AS col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT - col0 * + col1 * col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT ALL col1 + + 23 AS col2 FROM tab2
----
40
54
82

query I rowsort
SELECT DISTINCT - 4 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
-4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2051
SELECT col2 + CAST( NULL AS SIGNED ) * - col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2051
SELECT col2 + CAST ( NULL AS INTEGER ) * - col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - 8 AS col0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 852581644118629bf652b1aa4b8f4363

query I rowsort
SELECT DISTINCT 95 AS col1 FROM tab0, tab0 AS cor0
----
95

query I rowsort
SELECT 0 AS col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + ( cor0.col1 ) - - cor0.col0 * col0 AS col2 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT DISTINCT + col2 * col0 + - col0 * col0 + + col2 AS col1 FROM tab2 AS cor0
----
-3201
-4030
167

query I rowsort
SELECT - col2 * col0 * col0 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT - + 97 * - col0 FROM tab1 AS cor0
----
291
6208
7760

query I rowsort
SELECT - col1 + - col1 + + ( col0 ) FROM tab1 AS cor0
----
-49
44
54

query I rowsort
SELECT 41 AS col0 FROM tab1 AS cor0
----
41
41
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col2 + - col1 - 75 col1 FROM tab2
----
-108
-54
-79

query I rowsort
SELECT + - cor0.col0 + col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT - + cor0.col2 + cor0.col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + cor0.col1 * 78 AS col1 FROM tab0 AS cor0
----
6708
7098
7566

query I rowsort
SELECT DISTINCT + + col2 * ( - 97 ) FROM tab2 AS cor0
----
-2522
-2619
-3686

query I rowsort
SELECT - col1 + 31 + 68 AS col1 FROM tab1 AS cor0
----
73
86
89

query I rowsort
SELECT ALL - + cor0.col0 * + col1 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2068
SELECT ALL col1 DIV - CAST( + 45 AS SIGNED ) + + col0 FROM tab0 AS cor0
----
23
33
87

skipif mysql # not compatible
query I rowsort label-2068
SELECT ALL col1 / - CAST ( + 45 AS INTEGER ) + + col0 FROM tab0 AS cor0
----
23
33
87

query I rowsort
SELECT + col1 * 42 + col0 * - col2 FROM tab1 cor0
----
-3228
-7134
930

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2070
SELECT DISTINCT col2 * + CAST( - col0 AS SIGNED ) + col2 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

skipif mysql # not compatible
query I rowsort label-2070
SELECT DISTINCT col2 * + CAST ( - col0 AS INTEGER ) + col2 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 + - ( col0 ) col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT + cor0.col0 + + col0 * col2 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT ALL - + col2 * cor0.col0 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-2074
SELECT - cor0.col1 DIV - 70 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2074
SELECT - cor0.col1 / - 70 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - + cor0.col1 * col1 + col0 + col2 AS col1 FROM tab1 AS cor0
----
-619
21
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2076
SELECT + col1 / + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2076
SELECT + col1 / + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT + col1 * - 43 FROM tab1 AS cor0
----
-1118
-430
-559

query I rowsort
SELECT DISTINCT ( + col0 ) + col0 AS col0 FROM tab2 AS cor0
----
14
156
158

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2080
SELECT DISTINCT CAST( + col1 AS SIGNED ) * col2 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-2080
SELECT DISTINCT CAST ( + col1 AS INTEGER ) * col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - ( 14 ) + col0 AS col0 FROM tab0 AS cor0
----
10
21
75

query I rowsort
SELECT ALL + 0 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT col1 + - 52 FROM tab2
----
-21
-35
7

query I rowsort
SELECT DISTINCT - col2 * 76 FROM tab1 AS cor0
----
-4104
-4332
-7296

query I rowsort
SELECT + 82 + cor0.col1 * - col1 AS col1 FROM tab0 AS cor0
----
-7314
-8199
-9327

query I rowsort
SELECT DISTINCT + 77 * col2 + + ( 52 * col0 ) FROM tab2 AS cor0
----
2443
6058
7034

query I rowsort
SELECT ALL - + col1 * - col0 + + col2 * col1 * col2 FROM tab0 AS cor0
----
3492
619983
95718

query I rowsort
SELECT + col2 * col1 * 88 + ( - col0 ) * 6 + + 23 FROM tab2 cor0
----
134547
56397
73637

query I rowsort
SELECT ALL col0 + + col2 * + col1 + - col1 FROM tab2 AS cor0
----
1553
708
813

query I rowsort
SELECT col2 * cor0.col2 + + col1 + 95 FROM tab0 AS cor0
----
1270
193
6910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col1 + + 23 col0 FROM tab2 AS cor0
----
119
160
61

query I rowsort
SELECT ALL - 11 AS col0 FROM tab0
----
-11
-11
-11

query I rowsort
SELECT ALL + col2 * col0 * col1 + cor0.col2 AS col0 FROM tab0 AS cor0
----
3396
664200
68145

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0, tab0 cor1, tab2 cor2
----
972 values hashing to d41be7437523f0dba2158c7f0439f329

query I rowsort
SELECT + 5 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 - + col2 col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT + col2 - col0 AS col1 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT tab0.col1 + + col0 + + 86 AS col1 FROM tab0
----
196
218
266

onlyif mysql # use DIV operator for integer division
query I rowsort label-2099
SELECT col2 DIV - 54 + - 92 FROM tab2 AS cor0
----
-92
-92
-92

skipif mysql # not compatible
query I rowsort label-2099
SELECT col2 / - 54 + - 92 FROM tab2 AS cor0
----
-92
-92
-92

query I rowsort
SELECT DISTINCT + cor0.col1 * ( + 74 ) FROM tab0 AS cor0
----
6364
6734
7178

query I rowsort
SELECT DISTINCT - col1 * + 41 AS col1 FROM tab1 AS cor0
----
-1066
-410
-533

query I rowsort
SELECT - - col1 + 18 + + col2 * - col2 FROM tab1 AS cor0
----
-2872
-3221
-9185

query I rowsort
SELECT DISTINCT col1 * + 16 AS col1 FROM tab0 AS cor0
----
1376
1456
1552

onlyif mysql # use DIV operator for integer division
query I rowsort label-2104
SELECT - 99 * col0 DIV + col0 col1 FROM tab2
----
-99
-99
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2104
SELECT - 99 * col0 / + col0 col1 FROM tab2
----
-99
-99
-99

query I rowsort
SELECT ALL - col0 - + col1 AS col1 FROM tab2
----
-137
-38
-96

query I rowsort
SELECT ALL tab1.col0 + col0 * - col1 * col0 AS col1 FROM tab1
----
-231
-40896
-83120

query I rowsort
SELECT + col2 * col0 FROM tab2 WHERE NULL NOT IN ( + col2 )
----

query I rowsort
SELECT DISTINCT col1 * + col2 * + col2 AS col0 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT - 53 + + col2 AS col1 FROM tab1 AS cor0
----
1
4
43

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL NOT BETWEEN NULL AND ( + col2 + col1 )
----

query I rowsort
SELECT col2 - + col1 AS col0 FROM tab0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2112
SELECT col2 DIV col1 + col0 AS col2 FROM tab1
----
5
69
87

skipif mysql # not compatible
query I rowsort label-2112
SELECT col2 / col1 + col0 AS col2 FROM tab1
----
5
69
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-2113
SELECT col1 DIV - col0 + tab0.col1 - - col1 DIV col0 AS col2 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2113
SELECT col1 / - col0 + tab0.col1 - - col1 / col0 AS col2 FROM tab0
----
86
91
97

query I rowsort
SELECT col1 * col2 AS col0 FROM tab2 WHERE NOT - col0 = ( NULL )
----

query I rowsort
SELECT col0 * + col2 + col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT - ( 42 ) AS col1 FROM tab2, tab1 AS cor0
----
-42

query I rowsort
SELECT + tab2.col0 + + 48 AS col0 FROM tab2, tab0, tab1 AS cor0, tab1
----
81 values hashing to 2ebe57157244396d734c1118630e24d7

query I rowsort
SELECT - - 33 * col1 AS col1 FROM tab2 AS cor0
----
1023
1947
561

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 3 col1 FROM tab2 AS cor0
----
-3
-3
-3

query I rowsort
SELECT - col2 * + col0 + col2 AS col2 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT tab0.col2 FROM tab0 WHERE NOT NULL > ( col0 )
----

query I rowsort
SELECT col1 * + col0 + col1 FROM tab1
----
104
1053
650

query I rowsort
SELECT DISTINCT - col0 * tab0.col0 * - col1 AS col2 FROM tab0
----
118825
49536
720811

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT - col1 NOT IN ( tab1.col1 / col2 + col0 + + col0 )
----

query I rowsort
SELECT + col0 * - col1 AS col1 FROM tab2
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * tab2.col0 * + col2 col1 FROM tab2
----
114076
5103
52728

query I rowsort
SELECT ALL tab1.col0 * - col2 + - col1 * - tab1.col2 + + col2 AS col0 FROM tab1
----
-3021
-6336
1296

query I rowsort
SELECT ALL col1 + tab2.col2 * + tab2.col0 * col2 + - col1 FROM tab2
----
114076
5103
52728

query I rowsort
SELECT - tab2.col1 * col1 * + tab2.col1 FROM tab2
----
-205379
-29791
-4913

query I rowsort
SELECT tab1.col0 AS col0 FROM tab1 WHERE NOT NULL IN ( col2 * col2 - - col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2131
SELECT DISTINCT tab2.col2 * col2 + col0 DIV col0 + - col0 FROM tab2
----
1366
599
723

skipif mysql # not compatible
query I rowsort label-2131
SELECT DISTINCT tab2.col2 * col2 + col0 / col0 + - col0 FROM tab2
----
1366
599
723

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 * - col1 col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + col2 AS col1 FROM tab2 AS cor0 WHERE NOT + col0 - - cor0.col1 * + col0 * - col0 IN ( - col2 + + col1 * col0 + + cor0.col2 )
----
26
27
38

query I rowsort
SELECT + col1 * - col0 + col0 AS col0 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT tab2.col2 + - col1 * tab2.col2 AS col0 FROM tab2
----
-1508
-608
-810

query I rowsort
SELECT ALL - col0 + col0 + - tab2.col0 * + col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT col2 * - col2 * col1 AS col2 FROM tab1
----
-119808
-32490
-75816

query I rowsort
SELECT col1 * col2 + - col0 AS col1 FROM tab1
----
1168
1401
506

query I rowsort
SELECT DISTINCT + tab2.col0 + col2 * col0 AS col2 FROM tab2 WHERE NOT ( NULL ) BETWEEN col1 AND col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2140
SELECT tab0.col0 DIV + col1 + + col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-2140
SELECT tab0.col0 / + col1 + + col1 FROM tab0
----
86
91
97

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL NOT IN ( - col2 )
----

query I rowsort
SELECT - col2 + col1 + col2 AS col2 FROM tab2
----
17
31
59

query I rowsort
SELECT DISTINCT + col2 + - col0 * col1 + col1 AS col2 FROM tab1
----
-573
-931
2

query I rowsort
SELECT + tab1.col2 + - tab1.col2 FROM tab1
----
0
0
0

query I rowsort
SELECT col0 * col0 * - col0 FROM tab0
----
-13824
-42875
-704969

onlyif mysql # use DIV operator for integer division
query I rowsort label-2146
SELECT DISTINCT col0 + + col0 + col0 DIV col1 FROM tab2
----
14
157
162

skipif mysql # not compatible
query I rowsort label-2146
SELECT DISTINCT col0 + + col0 + col0 / col1 FROM tab2
----
14
157
162

onlyif mysql # use DIV operator for integer division
query I rowsort label-2147
SELECT DISTINCT + tab1.col2 DIV + col1 AS col2 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-2147
SELECT DISTINCT + tab1.col2 / + col1 AS col2 FROM tab1
----
2
5
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2148
SELECT ALL col2 DIV - col1 AS col0 FROM tab2
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-2148
SELECT ALL col2 / - col1 AS col0 FROM tab2
----
-2
0
0

query III rowsort
SELECT * FROM tab2 WHERE NOT col1 * col2 / + col1 - col1 / col1 NOT BETWEEN NULL AND ( col1 )
----

query I rowsort
SELECT - ( cor0.col1 ) + col0 * col1 + col1 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - 83 col1 FROM tab0
----
-2739
-6806
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2152
SELECT + CAST( 94 AS SIGNED ) * col0 AS col1 FROM tab0 AS cor0
----
2256
3290
8366

skipif mysql # not compatible
query I rowsort label-2152
SELECT + CAST ( 94 AS INTEGER ) * col0 AS col1 FROM tab0 AS cor0
----
2256
3290
8366

query I rowsort
SELECT - + 73 * - col1 FROM tab2 AS cor0
----
1241
2263
4307

query I rowsort
SELECT 36 - 61 AS col0 FROM tab1 AS cor0
----
-25
-25
-25

query I rowsort
SELECT 10 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query I rowsort
SELECT + 20 + cor0.col0 * - col0 AS col0 FROM tab0 AS cor0
----
-1205
-556
-7901

query I rowsort
SELECT - - cor0.col0 + col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT - col2 + + col1 * col2 AS col0 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT - ( col1 ) + col1 AS col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT - 63 AS col1 FROM tab2
----
-63
-63
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-2161
SELECT ALL + col2 * + 82 + col0 + - ( col2 ) DIV + col0 AS col1 FROM tab0
----
117
2729
6813

skipif mysql # not compatible
query I rowsort label-2161
SELECT ALL + col2 * + 82 + col0 + - ( col2 ) / + col0 AS col1 FROM tab0
----
117
2729
6813

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2162
SELECT CAST( - 64 + tab1.col2 AS SIGNED ) * 77 AS col2 FROM tab1
----
-539
-770
2464

skipif mysql # not compatible
query I rowsort label-2162
SELECT CAST ( - 64 + tab1.col2 AS INTEGER ) * 77 AS col2 FROM tab1
----
-539
-770
2464

query I rowsort
SELECT + 48 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT DISTINCT col0 * + col0 * + col0 AS col0 FROM tab0
----
13824
42875
704969

query I rowsort
SELECT tab2.col0 * + 17 FROM tab2
----
119
1326
1343

query I rowsort
SELECT col0 + col0 * col2 AS col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT col1 * col0 + + 20 AS col2 FROM tab2 AS cor0
----
1363
237
4622

query I rowsort
SELECT DISTINCT + ( - col1 ) AS col1 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + col0 * - col0 + ( + col2 ) FROM tab0 AS cor0
----
-1224
-543
-7839

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * ( 77 ) - col2 col0 FROM tab1 AS cor0
----
-1097
-2056
-827

query I rowsort
SELECT 73 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 3933a906d17a820ccf95467e2206df8f

query I rowsort
SELECT ALL - 16 * col0 + 7 FROM tab2 AS cor0
----
-105
-1241
-1257

query I rowsort
SELECT ALL + + col2 * + col2 + + col2 FROM tab0 cor0
----
1122
2
6806

onlyif mysql # use DIV operator for integer division
query I rowsort label-2174
SELECT + + col0 DIV cor0.col0 AS col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2174
SELECT + + col0 / cor0.col0 AS col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - ( - col2 ) * 72 AS col0 FROM tab2 AS cor0
----
1872
1944
2736

query I rowsort
SELECT - 71 AS col2 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 3907e0aa4f29c002120742c4abb3e23a

query I rowsort
SELECT ALL + - col0 * + 99 FROM tab2 AS cor0
----
-693
-7722
-7821

query I rowsort
SELECT DISTINCT + col1 + + col1 AS col1 FROM tab2 cor0
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2179
SELECT DISTINCT + cor0.col0 + CAST( 1 AS SIGNED ) * + col0 FROM tab0 AS cor0
----
178
48
70

skipif mysql # not compatible
query I rowsort label-2179
SELECT DISTINCT + cor0.col0 + CAST ( 1 AS INTEGER ) * + col0 FROM tab0 AS cor0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-2180
SELECT + col1 DIV - 71 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2180
SELECT + col1 / - 71 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 * col2 + - col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT + col2 * + ( + 8 ) - + col0 FROM tab0 AS cor0
----
-27
240
567

onlyif mysql # use DIV operator for integer division
query I rowsort label-2183
SELECT ALL + col0 + - col0 DIV - 57 FROM tab1
----
3
65
81

skipif mysql # not compatible
query I rowsort label-2183
SELECT ALL + col0 + - col0 / - 57 FROM tab1
----
3
65
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col2 + col0 col2 FROM tab2
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-2185
SELECT - tab2.col0 DIV col0 + col0 FROM tab2
----
6
77
78

skipif mysql # not compatible
query I rowsort label-2185
SELECT - tab2.col0 / col0 + col0 FROM tab2
----
6
77
78

query I rowsort
SELECT col2 + + col1 * + col2 AS col0 FROM tab0
----
2871
7544
98

query I rowsort
SELECT DISTINCT - tab2.col1 + + col2 + 75 * + 74 AS col1 FROM tab2
----
5517
5546
5571

query I rowsort
SELECT 99 * + col0 + + col0 FROM tab0 AS cor0
----
2400
3500
8900

onlyif mysql # use DIV operator for integer division
query I rowsort label-2189
SELECT ( + col1 ) * + cor0.col2 + - ( - cor0.col1 ) DIV col0 - col0 AS col1 FROM tab0 AS cor0
----
2817
64
7374

skipif mysql # not compatible
query I rowsort label-2189
SELECT ( + col1 ) * + cor0.col2 + - ( - cor0.col1 ) / col0 - col0 AS col1 FROM tab0 AS cor0
----
2817
64
7374

onlyif mysql # use DIV operator for integer division
query I rowsort label-2190
SELECT ALL - col1 DIV col1 + col1 + col0 FROM tab0 AS cor0
----
109
131
179

skipif mysql # not compatible
query I rowsort label-2190
SELECT ALL - col1 / col1 + col1 + col0 FROM tab0 AS cor0
----
109
131
179

query I rowsort
SELECT ALL + col2 + 65 + - col0 FROM tab1 AS cor0
----
116
58
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2192
SELECT + CAST( col1 AS SIGNED ) + - cor0.col0 AS col0 FROM tab0 AS cor0
----
2
62
62

skipif mysql # not compatible
query I rowsort label-2192
SELECT + CAST ( col1 AS INTEGER ) + - cor0.col0 AS col0 FROM tab0 AS cor0
----
2
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + 61 * col0 col1 FROM tab1 AS cor0
----
180
3840
4800

query I rowsort
SELECT DISTINCT + 45 * + col0 FROM tab0 cor0
----
1080
1575
4005

query I rowsort
SELECT col0 * col0 + - col2 + col2 FROM tab1
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 14 col2 FROM tab1
----
24
27
40

query I rowsort
SELECT ALL - - cor0.col2 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL ( col1 ) * tab1.col1 AS col2 FROM tab1
----
100
169
676

query I rowsort
SELECT 14 * - col1 * col1 + col2 FROM tab0 AS cor0
----
-103511
-115852
-131725

query I rowsort
SELECT - 30 * 86 - + cor0.col2 AS col0 FROM tab0 AS cor0
----
-2581
-2613
-2662

query I rowsort
SELECT col1 * + col1 + + col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT + col0 + col0 * - col2 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT ALL + col2 - 65 FROM tab0
----
-32
-64
17

query I rowsort
SELECT + col2 + col2 - col2 AS col2 FROM tab0
----
1
33
82

query I rowsort
SELECT + 56 + + ( col0 ) * ( 98 * col1 ) FROM tab2
----
131670
21322
451052

query I rowsort
SELECT DISTINCT - + 40 * col2 - col2 FROM tab2 AS cor0
----
-1066
-1107
-1558

query I rowsort
SELECT col0 * col1 + + 61 FROM tab0 AS cor0
----
2125
3456
8160

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) * - ( + 54 ) + + col0 col2 FROM tab2 AS cor0
----
-371
-4134
-4187

query I rowsort
SELECT - + 81 * cor0.col2 AS col2 FROM tab0, tab1, tab1 cor0, tab2
----
81 values hashing to 360401e8497600bf0d109e779ff7acc8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 70 col0 FROM tab2, tab1 cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT ALL - 62 + + col1 FROM tab0
----
24
29
35

query I rowsort
SELECT ALL col0 * + col2 + col1 * col1 AS col2 FROM tab2 AS cor0
----
1150
3291
5509

query I rowsort
SELECT col2 * col2 + - 48 AS col0 FROM tab0 AS cor0
----
-47
1041
6676

query I rowsort
SELECT DISTINCT 12 + + col2 FROM tab1 AS cor0
----
108
66
69

query I rowsort
SELECT ALL tab0.col1 + + col0 AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT ALL - 65 * col2 AS col0 FROM tab2
----
-1690
-1755
-2470

query I rowsort
SELECT ALL + + col1 + col1 * - 90 AS col1 FROM tab1 AS cor0
----
-1157
-2314
-890

query I rowsort
SELECT + ( col0 ) + 29 * col2 FROM tab0 AS cor0
----
2467
64
981

query I rowsort
SELECT DISTINCT + - 23 - - cor0.col1 FROM tab0 AS cor0
----
63
68
74

query I rowsort
SELECT ALL 54 + col2 * - col2 AS col2 FROM tab0 cor0
----
-1035
-6670
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-2221
SELECT - cor0.col1 DIV col0 - - CAST( + ( - col1 ) AS SIGNED ) * col2 AS col1 FROM tab0 AS cor0
----
-2841
-7463
-99

skipif mysql # not compatible
query I rowsort label-2221
SELECT - cor0.col1 / col0 - - CAST ( + ( - col1 ) AS INTEGER ) * col2 AS col1 FROM tab0 AS cor0
----
-2841
-7463
-99

query I rowsort
SELECT DISTINCT - + cor0.col0 + - col0 * cor0.col0 AS col0 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT ALL - ( + col0 ) + col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 10 + + col0 FROM tab2 AS cor0
----
17
88
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2225
SELECT ALL - 60 + - col2 DIV + col1 FROM tab2 AS cor0
----
-60
-60
-62

skipif mysql # not compatible
query I rowsort label-2225
SELECT ALL - 60 + - col2 / + col1 FROM tab2 AS cor0
----
-60
-60
-62

query I rowsort
SELECT ALL col0 * col1 + + col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT + 28 * col1 - col0 FROM tab0 AS cor0
----
2384
2459
2681

query I rowsort
SELECT DISTINCT + + 29 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
29

query I rowsort
SELECT ALL - + col2 * + 37 AS col0 FROM tab2 AS cor0
----
-1406
-962
-999

query I rowsort
SELECT DISTINCT - - cor0.col0 + - ( + col0 ) FROM tab2 cor0
----
0

query I rowsort
SELECT ALL + - col0 * ( 64 ) AS col0 FROM tab2 AS cor0
----
-448
-4992
-5056

onlyif mysql # use DIV operator for integer division
query I rowsort label-2232
SELECT ALL + col2 DIV + col0 AS col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-2232
SELECT ALL + col2 / + col0 AS col0 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT ALL - cor0.col2 FROM tab2, tab1 AS cor0, tab0 cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2234
SELECT - CAST( NULL AS SIGNED ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2234
SELECT - CAST ( NULL AS INTEGER ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2235
SELECT DISTINCT - col2 * col2 - cor0.col2 DIV + 73 FROM tab2 AS cor0
----
-1444
-676
-729

skipif mysql # not compatible
query I rowsort label-2235
SELECT DISTINCT - col2 * col2 - cor0.col2 / + 73 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL + col1 + + 50 - cor0.col2 AS col0 FROM tab0 AS cor0
----
103
146
59

query I rowsort
SELECT DISTINCT + - col1 + 41 FROM tab0 cor0
----
-45
-50
-56

query I rowsort
SELECT DISTINCT + col0 * - 93 AS col2 FROM tab0 AS cor0
----
-2232
-3255
-8277

query I rowsort
SELECT + ( - col0 ) + col0 * ( col0 * + cor0.col2 ) FROM tab2 AS cor0
----
1316
158106
237079

query I rowsort
SELECT + + col0 - - cor0.col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT DISTINCT + 63 * - col1 FROM tab2 AS cor0
----
-1071
-1953
-3717

query I rowsort
SELECT 14 * col2 + - col1 AS col0 FROM tab1 AS cor0
----
1331
730
788

query I rowsort
SELECT ALL col1 * 10 + col1 FROM tab2 AS cor0
----
187
341
649

query I rowsort
SELECT ALL - ( col2 ) * col0 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - - col1 - + col1 * + col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + ( col0 ) col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + + col1 * ( col0 ) FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT - col2 * col2 + + 72 + + col0 AS col2 FROM tab1 cor0
----
-2841
-3113
-9064

query I rowsort
SELECT col0 * - ( col1 * + col1 ) AS col2 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT ALL - col0 * col0 + + 45 FROM tab1 AS cor0
----
-4051
-6355
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - 76 col1 FROM tab2 AS cor0
----
-107
-135
-93

query I rowsort
SELECT ALL + - col1 + 11 FROM tab2 cor0
----
-20
-48
-6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2253
SELECT - col1 * - CAST( NULL AS SIGNED ) + - col2 + cor0.col1 * + ( col2 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2253
SELECT - col1 * - CAST ( NULL AS INTEGER ) + - col2 + cor0.col1 * + ( col2 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 + col0 * col0 FROM tab1 AS cor0
----
-17
4086
6387

query I rowsort
SELECT col2 * col0 - + col1 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT - + tab1.col1 AS col2 FROM tab1, tab0, tab0 AS cor0, tab2
----
81 values hashing to 96e9ef2950805bca93a295eeea43ef5b

onlyif mysql # use DIV operator for integer division
query I rowsort label-2257
SELECT col2 DIV - col0 - col2 AS col1 FROM tab0 AS cor0
----
-1
-34
-82

skipif mysql # not compatible
query I rowsort label-2257
SELECT col2 / - col0 - col2 AS col1 FROM tab0 AS cor0
----
-1
-34
-82

query I rowsort
SELECT col1 * col1 * - col1 - - col0 FROM tab0 AS cor0
----
-636032
-753482
-912638

query I rowsort
SELECT + tab1.col1 * - ( col0 ) AS col2 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT ALL + cor1.col1 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ALL - col1 * col2 * - 5 AS col0 FROM tab1
----
2850
6240
7020

onlyif mysql # use DIV operator for integer division
query I rowsort label-2262
SELECT DISTINCT - col2 DIV - col1 AS col2 FROM tab2
----
0
2

skipif mysql # not compatible
query I rowsort label-2262
SELECT DISTINCT - col2 / - col1 AS col2 FROM tab2
----
0
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-2263
SELECT DISTINCT + 67 + col2 DIV - col0 FROM tab1 AS cor0
----
49
66
67

skipif mysql # not compatible
query I rowsort label-2263
SELECT DISTINCT + 67 + col2 / - col0 FROM tab1 AS cor0
----
49
66
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-2264
SELECT DISTINCT col0 + + col1 DIV col0 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-2264
SELECT DISTINCT col0 + + col1 / col0 FROM tab1 AS cor0
----
11
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2265
SELECT DISTINCT + col1 DIV + col2 AS col2 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-2265
SELECT DISTINCT + col1 / + col2 AS col2 FROM tab0
----
1
2
97

query I rowsort
SELECT ALL 54 * - col1 FROM tab0 AS cor0
----
-4644
-4914
-5238

query I rowsort
SELECT ALL - col0 * + 28 FROM tab0 AS cor0
----
-2492
-672
-980

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 75 * cor0.col2 col1 FROM tab1 cor0
----
4050
4275
7200

query I rowsort
SELECT cor0.col2 * + col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + 96 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

query I rowsort
SELECT 62 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

query I rowsort
SELECT DISTINCT + col1 - 35 FROM tab1
----
-22
-25
-9

query I rowsort
SELECT DISTINCT col1 * 24 - + tab1.col0 AS col0 FROM tab1
----
176
232
621

query I rowsort
SELECT DISTINCT col2 * - col2 * col2 FROM tab2
----
-17576
-19683
-54872

query I rowsort
SELECT - tab0.col0 * col0 + col0 AS col1 FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT - + col1 * 43 AS col0 FROM tab1 AS cor0
----
-1118
-430
-559

query I rowsort
SELECT DISTINCT + col0 + ( - col1 ) + col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL - col1 - 22 * col0 FROM tab0 AS cor0
----
-2049
-614
-867

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 93 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

onlyif mysql # use DIV operator for integer division
query I rowsort label-2280
SELECT DISTINCT + col0 + + 49 - - col1 DIV col1 FROM tab2 cor0
----
128
129
57

skipif mysql # not compatible
query I rowsort label-2280
SELECT DISTINCT + col0 + + 49 - - col1 / col1 FROM tab2 cor0
----
128
129
57

query I rowsort
SELECT DISTINCT - cor1.col2 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
-1
-33
-82

query I rowsort
SELECT DISTINCT 47 FROM tab0, tab1 AS cor0
----
47

query I rowsort
SELECT ALL + ( + col1 ) * + col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT + ( col1 ) * col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - + ( - col0 ) + col1 * + col1 * - col2 FROM tab1 AS cor0
----
-16144
-36501
-5636

query I rowsort
SELECT + + 55 + - col1 AS col0 FROM tab1 AS cor0
----
29
42
45

query I rowsort
SELECT + + 61 * - col0 FROM tab2 AS cor0
----
-427
-4758
-4819

query I rowsort
SELECT - cor0.col1 * cor0.col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT - col1 * - ( + col0 ) FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2290
SELECT DISTINCT col2 DIV - 55 AS col1 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-2290
SELECT DISTINCT col2 / - 55 AS col1 FROM tab1
----
-1
0

query I rowsort
SELECT col2 * ( - col1 ) AS col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT + + col2 + + col2 * 30 FROM tab2 AS cor0
----
1178
806
837

query I rowsort
SELECT + 68 + col2 * col0 AS col0 FROM tab2 AS cor0
----
2096
257
3070

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + 23 + - 42 * col2 col2 FROM tab2
----
-973
221
702

query I rowsort
SELECT DISTINCT col0 * col2 * 51 + col1 AS col2 FROM tab0
----
1882
372289
40478

query I rowsort
SELECT col1 * + col2 + - col0 AS col0 FROM tab1
----
1168
1401
506

query I rowsort
SELECT + col0 + col2 * + col0 * - col2 FROM tab1
----
-207872
-737200
-8745

query I rowsort
SELECT ALL + col1 + 79 AS col1 FROM tab1
----
105
89
92

query I rowsort
SELECT ALL + - col0 * - 7 + + col0 AS col1 FROM tab0 AS cor0
----
192
280
712

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 + + 81 + - 69 * col2 col0 FROM tab1 AS cor0
----
-3648
-3916
-6623

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2301
SELECT - CAST( + 80 AS SIGNED ) * + col2 AS col0 FROM tab2 cor0
----
-2080
-2160
-3040

skipif mysql # not compatible
query I rowsort label-2301
SELECT - CAST ( + 80 AS INTEGER ) * + col2 AS col0 FROM tab2 cor0
----
-2080
-2160
-3040

query I rowsort
SELECT ALL + col0 + 32 * col0 AS col2 FROM tab1 AS cor0
----
2112
2640
99

query I rowsort
SELECT ALL col0 - + col1 * - col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT + col1 * cor0.col0 + col0 AS col1 FROM tab2 AS cor0
----
1422
224
4680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2305
SELECT ALL - CAST( NULL AS SIGNED ) * - col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2305
SELECT ALL - CAST ( NULL AS INTEGER ) * - col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 13 - - col0 * col0 AS col1 FROM tab1 AS cor0
----
-4
4083
6387

query I rowsort
SELECT DISTINCT + + col2 * col0 * - col0 + + col1 * - cor0.col1 * cor0.col0 AS col2 FROM tab2 AS cor0
----
-259989
-429702
-8050

query I rowsort
SELECT - 42 * - col2 FROM tab1 AS cor0
----
2268
2394
4032

query I rowsort
SELECT ALL - + 75 * + col0 + col2 - + col2 FROM tab2 AS cor0
----
-525
-5850
-5925

query I rowsort
SELECT - ( - 5 ) * col1 + - ( 71 ) FROM tab0 AS cor0
----
359
384
414

query I rowsort
SELECT + col0 * + 40 * col0 AS col2 FROM tab1
----
163840
256000
360

query I rowsort
SELECT - 56 FROM tab2, tab0 cor0
----
9 values hashing to 3d3dab400eef93c098acbbba3fc9bdc6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2313
SELECT ALL - col0 - + CAST( NULL AS DECIMAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2313
SELECT ALL - col0 - + CAST ( NULL AS REAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + 9 FROM tab2 AS cor0
----
9

query I rowsort
SELECT cor0.col0 + - col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - ( col1 ) * col0 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2317
SELECT + CAST( - col0 AS SIGNED ) * col2 * col2 + - col0 FROM tab2 AS cor0
----
-114155
-5110
-52806

skipif mysql # not compatible
query I rowsort label-2317
SELECT + CAST ( - col0 AS INTEGER ) * col2 * col2 + - col0 FROM tab2 AS cor0
----
-114155
-5110
-52806

query I rowsort
SELECT ALL - - 44 + + 7 AS col1 FROM tab0 AS cor0
----
51
51
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col0 * cor0.col1 col0 FROM tab1 AS cor0
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 46 + col0 col1 FROM tab1 AS cor0
----
110
126
49

query I rowsort
SELECT DISTINCT - col0 + + cor0.col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL - col1 + + col1 * ( - col1 ) FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT DISTINCT + col2 * - col2 + 15 AS col1 FROM tab0 cor0
----
-1074
-6709
14

query I rowsort
SELECT ALL + ( - col2 ) * + col1 + 96 FROM tab1 AS cor0
----
-1152
-1308
-474

query I rowsort
SELECT + 82 AS col1 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

query I rowsort
SELECT col1 * cor0.col0 * + 48 FROM tab2 AS cor0
----
10416
220896
64464

query I rowsort
SELECT ALL 12 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT - ( - 28 ) AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

query I rowsort
SELECT DISTINCT - col2 + + col2 * - ( - col2 ) FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT ALL col0 + col1 * - col1 FROM tab2 AS cor0
----
-210
-3403
-954

onlyif mysql # use DIV operator for integer division
query I rowsort label-2331
SELECT ALL + col2 * 58 DIV col1 + - col1 FROM tab0 cor0
----
-39
-64
-97

skipif mysql # not compatible
query I rowsort label-2331
SELECT ALL + col2 * 58 / col1 + - col1 FROM tab0 cor0
----
-39
-64
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col0 col2 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT - col1 * - ( 8 ) FROM tab0 AS cor0
----
688
728
776

query I rowsort
SELECT col0 * + ( col0 + - col2 ) FROM tab0 AS cor0
----
-216
1190
623

query I rowsort
SELECT ALL + col0 * 73 + cor0.col1 FROM tab0 AS cor0
----
1838
2652
6588

query I rowsort
SELECT - tab2.col1 + - tab2.col0 FROM tab2
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 - col0 * - 59 col1 FROM tab1
----
231
3833
4816

onlyif mysql # use DIV operator for integer division
query I rowsort label-2338
SELECT DISTINCT - col2 + 97 + + 61 DIV tab1.col1 FROM tab1
----
45
46
5

skipif mysql # not compatible
query I rowsort label-2338
SELECT DISTINCT - col2 + 97 + + 61 / tab1.col1 FROM tab1
----
45
46
5

query I rowsort
SELECT - col1 * - col1 AS col0 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT + col1 - ( 93 + - col0 ) FROM tab0
----
17
39
87

query I rowsort
SELECT DISTINCT col2 + 22 FROM tab0
----
104
23
55

query I rowsort
SELECT DISTINCT col1 + + col1 * - ( + col2 ) + - 23 AS col2 FROM tab0 AS cor0
----
-23
-2775
-7394

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2343
SELECT col1 - - CAST( NULL AS DECIMAL ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2343
SELECT col1 - - CAST ( NULL AS REAL ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * 94 FROM tab1 AS cor0
----
1222
2444
940

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2345
SELECT ALL col1 * CAST( NULL AS SIGNED ) + 75 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2345
SELECT ALL col1 * CAST ( NULL AS INTEGER ) + 75 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 * ( + 60 ) + col1 AS col2 FROM tab0 AS cor0
----
-1894
-4829
37

query I rowsort
SELECT col1 * 38 FROM tab1 AS cor0
----
380
494
988

query I rowsort
SELECT + col0 + 87 AS col0 FROM tab0
----
111
122
176

query I rowsort
SELECT + col2 + + cor0.col1 AS col1 FROM tab0 AS cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * cor0.col0 * + 80 + 55 col2 FROM tab0 cor0
----
165175
271655
647975

query I rowsort
SELECT DISTINCT - + col2 + + col1 * + col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT DISTINCT - 63 + + col1 * + col1 FROM tab1 AS cor0
----
106
37
613

onlyif mysql # use DIV operator for integer division
query I rowsort label-2353
SELECT DISTINCT - 94 DIV col1 + col1 * col1 DIV col0 AS col0 FROM tab2 AS cor0
----
-2
134
43

skipif mysql # not compatible
query I rowsort label-2353
SELECT DISTINCT - 94 / col1 + col1 * col1 / col0 AS col0 FROM tab2 AS cor0
----
-2
134
43

query I rowsort
SELECT DISTINCT + 19 AS col1 FROM tab1 AS cor0
----
19

query I rowsort
SELECT ALL - col1 * + col2 - + 53 * - col2 * - col1 AS col0 FROM tab0 cor0
----
-153252
-402948
-5238

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) FROM tab1, tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 25 * col1 + cor0.col0 * 45 col1 FROM tab2 AS cor0
----
1090
3980
4985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - col2 ) col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL cor0.col1 * + 45 AS col1 FROM tab1 AS cor0
----
1170
450
585

query I rowsort
SELECT - - col1 * col0 AS col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT 71 FROM tab2, tab0 cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2362
SELECT + + col0 DIV 9 FROM tab1 AS cor0
----
0
7
8

skipif mysql # not compatible
query I rowsort label-2362
SELECT + + col0 / 9 FROM tab1 AS cor0
----
0
7
8

query I rowsort
SELECT ALL 96 * + col1 FROM tab0 cor0
----
8256
8736
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-2364
SELECT ALL + ( - 8 ) DIV col0 AS col2 FROM tab1 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-2364
SELECT ALL + ( - 8 ) / col0 AS col2 FROM tab1 AS cor0
----
-2
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2365
SELECT + CAST( ( + col2 ) AS SIGNED ) * CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2365
SELECT + CAST ( ( + col2 ) AS INTEGER ) * CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 56 * cor0.col2 FROM tab2 AS cor0
----
1456
1512
2128

query I rowsort
SELECT + 72 - col0 FROM tab1 AS cor0
----
-8
69
8

query I rowsort
SELECT - col2 + - col1 * cor0.col0 AS col0 FROM tab1 AS cor0
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT - tab2.col2 * + tab2.col0 FROM tab2, tab0 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT col2 + + col2 * + 53 FROM tab1 AS cor0
----
2916
3078
5184

query I rowsort
SELECT + 72 + col0 FROM tab2
----
150
151
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-2372
SELECT col0 * ( - 84 ) DIV - col1 AS col2 FROM tab0 AS cor0
----
23
30
82

skipif mysql # not compatible
query I rowsort label-2372
SELECT col0 * ( - 84 ) / - col1 AS col2 FROM tab0 AS cor0
----
23
30
82

query I rowsort
SELECT ALL + col0 * - col2 + col0 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT + col0 * - tab2.col2 * col0 FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT ALL col2 * - 80 FROM tab0
----
-2640
-6560
-80

query I rowsort
SELECT + col2 + 83 AS col0 FROM tab1 cor0
----
137
140
179

query I rowsort
SELECT DISTINCT - col1 * col2 + col1 AS col0 FROM tab2 cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT col2 * ( - 10 ) FROM tab2
----
-260
-270
-380

onlyif mysql # use DIV operator for integer division
query I rowsort label-2379
SELECT ALL - tab0.col1 DIV col0 AS col0 FROM tab0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-2379
SELECT ALL - tab0.col1 / col0 AS col0 FROM tab0
----
-1
-2
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-2380
SELECT ALL + col1 DIV + col0 + cor0.col0 AS col0 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-2380
SELECT ALL + col1 / + col0 + cor0.col0 AS col0 FROM tab1 AS cor0
----
11
64
80

query I rowsort
SELECT - 36 + col0 * - col0 AS col0 FROM tab1 AS cor0
----
-4132
-45
-6436

query I rowsort
SELECT ALL 15 * 34 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to d014015036bba0acfe641e14c6ddece9

query I rowsort
SELECT - col1 * + ( col0 ) FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + 31 * + col0 FROM tab1
----
1984
2480
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-2385
SELECT DISTINCT col0 DIV ( col0 ) AS col2 FROM tab2
----
1

skipif mysql # not compatible
query I rowsort label-2385
SELECT DISTINCT col0 / ( col0 ) AS col2 FROM tab2
----
1

query I rowsort
SELECT DISTINCT 11 * - 55 FROM tab1
----
-605

onlyif mysql # use DIV operator for integer division
query I rowsort label-2387
SELECT DISTINCT + 58 DIV col1 FROM tab1
----
2
4
5

skipif mysql # not compatible
query I rowsort label-2387
SELECT DISTINCT + 58 / col1 FROM tab1
----
2
4
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 74 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 2ccf8ef3f477e1a1a3e30c8b8154ff31

query I rowsort
SELECT ( - cor0.col2 ) AS col1 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT col0 * + 1 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - 6 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to e92b2679faac7be63701967e3f0c0934

query I rowsort
SELECT 8 + 3 AS col1 FROM tab1
----
11
11
11

query I rowsort
SELECT + col0 * + col2 * + col0 + 4 FROM tab0
----
1229
19012
649526

query I rowsort
SELECT - col2 - + 14 AS col0 FROM tab0
----
-15
-47
-96

query I rowsort
SELECT + 9 * col1 FROM tab0 AS cor0
----
774
819
873

query I rowsort
SELECT DISTINCT + 73 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 41 col2 FROM tab0
----
41

query I rowsort
SELECT ALL 96 AS col0 FROM tab2 AS cor0
----
96
96
96

query I rowsort
SELECT ALL - 91 FROM tab0 AS cor0
----
-91
-91
-91

query I rowsort
SELECT 36 * - col1 FROM tab1
----
-360
-468
-936

query I rowsort
SELECT col2 + 25 AS col0 FROM tab2 AS cor0
----
51
52
63

query I rowsort
SELECT - + col2 * - col2 + col0 AS col1 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT - col0 - - 17 * tab0.col1 AS col1 FROM tab0
----
1438
1458
1614

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2404
SELECT DISTINCT + tab1.col2 + CAST( + col2 AS SIGNED ) FROM tab1
----
108
114
192

skipif mysql # not compatible
query I rowsort label-2404
SELECT DISTINCT + tab1.col2 + CAST ( + col2 AS INTEGER ) FROM tab1
----
108
114
192

query I rowsort
SELECT + + col0 - col2 AS col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT + col2 * - ( col2 ) * - col2 + 31 FROM tab2 AS cor0
----
17607
19714
54903

query I rowsort
SELECT + col0 + col2 * - col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT + col0 * + ( col0 ) AS col2 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL - col1 - col2 AS col0 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL col2 * col1 - col1 AS col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT + col0 + + tab1.col2 AS col2 FROM tab1
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 40 col1 FROM tab1
----
40

query I rowsort
SELECT ALL - col0 + 60 AS col2 FROM tab2
----
-18
-19
53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2414
SELECT ALL + col2 * - CAST( col1 AS SIGNED ) * cor0.col2 + cor0.col1 FROM tab1 AS cor0
----
-119795
-32480
-75790

skipif mysql # not compatible
query I rowsort label-2414
SELECT ALL + col2 * - CAST ( col1 AS INTEGER ) * cor0.col2 + cor0.col1 FROM tab1 AS cor0
----
-119795
-32480
-75790

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2415
SELECT DISTINCT + + col2 + CAST( col2 AS SIGNED ) + col2 * + col0 AS col2 FROM tab1 AS cor0
----
270
3762
7872

skipif mysql # not compatible
query I rowsort label-2415
SELECT DISTINCT + + col2 + CAST ( col2 AS INTEGER ) + col2 * + col0 AS col2 FROM tab1 AS cor0
----
270
3762
7872

query I rowsort
SELECT DISTINCT - col2 + ( col1 * col1 ) + col2 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col0 * + 71 col1 FROM tab0 AS cor0
----
-1704
-2485
-6319

query I rowsort
SELECT - - col1 * - col1 - col0 * - col2 FROM tab2 AS cor0
----
-1453
-772
2713

query I rowsort
SELECT DISTINCT + col0 + - 4 * - col1 FROM tab1 AS cor0
----
104
107
132

query I rowsort
SELECT ALL - - col0 * 61 + 61 + - col2 AS col2 FROM tab1 AS cor0
----
190
3908
4845

query I rowsort
SELECT col0 * 62 - - col2 * col1 FROM tab1 AS cor0
----
1590
4538
6208

query I rowsort
SELECT DISTINCT + col2 + 32 * 54 * + col0 AS col0 FROM tab0 AS cor0
----
153874
41505
60481

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2423
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2423
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab2 AS cor0
----
NULL

query I rowsort
SELECT col2 + - col0 * - col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT ALL 36 * cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to e6db7d11c94ea823449267ee4a0e54d7

query I rowsort
SELECT ALL - ( + tab0.col0 ) AS col0 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT - + 40 AS col2 FROM tab0 AS cor0
----
-40
-40
-40

query I rowsort
SELECT + cor0.col0 * col0 + + col2 * - 33 AS col1 FROM tab0 cor0
----
-513
1192
5215

query I rowsort
SELECT 55 * col0 + - col0 AS col2 FROM tab1
----
162
3456
4320

query I rowsort
SELECT + - 52 FROM tab0 AS cor0
----
-52
-52
-52

query I rowsort
SELECT ALL + col0 * col1 + 67 AS col1 FROM tab1 AS cor0
----
1107
145
707

query I rowsort
SELECT 80 + col2 AS col0 FROM tab0 AS cor0
----
113
162
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-2433
SELECT DISTINCT col2 DIV col2 + + 67 * col1 AS col1 FROM tab0 AS cor0
----
5763
6098
6500

skipif mysql # not compatible
query I rowsort label-2433
SELECT DISTINCT col2 / col2 + + 67 * col1 AS col1 FROM tab0 AS cor0
----
5763
6098
6500

onlyif mysql # use DIV operator for integer division
query I rowsort label-2434
SELECT DISTINCT col2 DIV - col1 - - col1 DIV - col0 AS col2 FROM tab1 AS cor0
----
-10
-5
-7

skipif mysql # not compatible
query I rowsort label-2434
SELECT DISTINCT col2 / - col1 - - col1 / - col0 AS col2 FROM tab1 AS cor0
----
-10
-5
-7

query I rowsort
SELECT ALL 90 * col1 * - cor0.col2 + 63 AS col2 FROM tab0 AS cor0
----
-255357
-671517
-8667

query I rowsort
SELECT ALL + + 61 * col2 + + col2 + col2 AS col1 FROM tab1 AS cor0
----
3402
3591
6048

query I rowsort
SELECT DISTINCT - + col0 + col2 * + ( col0 ) FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT ALL + - col0 * col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - col0 * - col2 AS col1 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT ALL - ( - col2 ) + + col2 AS col2 FROM tab2 AS cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + col1 * ( col2 ) col0 FROM tab2 AS cor0
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 * col2 col1 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * cor0.col1 col2 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT col2 * - ( col1 ) FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - cor0.col0 * 2 FROM tab0 AS cor0
----
-178
-48
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + + col0 col0 FROM tab1
----
-16
-51
7

query I rowsort
SELECT - col0 * - 77 FROM tab1 AS cor0
----
231
4928
6160

query I rowsort
SELECT - 85 AS col2 FROM tab1
----
-85
-85
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 59 * col2 * - col2 col1 FROM tab1 AS cor0
----
172044
191691
543744

query I rowsort
SELECT DISTINCT + 53 * 32 AS col1 FROM tab2 cor0
----
1696

query I rowsort
SELECT DISTINCT - - ( col2 ) * - col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + col0 * col1 + cor0.col1 FROM tab1 cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-2453
SELECT ALL - 54 DIV cor0.col0 FROM tab2 AS cor0
----
-7
0
0

skipif mysql # not compatible
query I rowsort label-2453
SELECT ALL - 54 / cor0.col0 FROM tab2 AS cor0
----
-7
0
0

query I rowsort
SELECT - 90 + - col0 AS col1 FROM tab1 AS cor0
----
-154
-170
-93

query I rowsort
SELECT DISTINCT 96 AS col2 FROM tab1 AS cor0
----
96

query I rowsort
SELECT + + 10 AS col2 FROM tab2 AS cor0
----
10
10
10

query I rowsort
SELECT ALL + + col1 * - 24 + col0 AS col2 FROM tab2 AS cor0
----
-1338
-329
-737

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2458
SELECT ALL col2 * ( col0 ) + - CAST( - ( - col0 ) AS SIGNED ) AS col2 FROM tab2 AS cor0
----
182
1950
2923

skipif mysql # not compatible
query I rowsort label-2458
SELECT ALL col2 * ( col0 ) + - CAST ( - ( - col0 ) AS INTEGER ) AS col2 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT - 94 * col0 AS col1 FROM tab2 AS cor0
----
-658
-7332
-7426

query I rowsort
SELECT ALL - col0 - col0 * col1 FROM tab2
----
-1422
-224
-4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2461
SELECT col2 DIV ( - col2 ) AS col0 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2461
SELECT col2 / ( - col2 ) AS col0 FROM tab1
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2462
SELECT 3 DIV - col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2462
SELECT 3 / - col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 60 * col0 FROM tab2 cor0
----
-420
-4680
-4740

query I rowsort
SELECT DISTINCT - cor0.col2 * - cor0.col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT col2 * - cor0.col2 + + col2 - 62 * cor0.col0 AS col2 FROM tab2 AS cor0
----
-1136
-5486
-6304

query I rowsort
SELECT col1 * col2 + - col1 * col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2467
SELECT DISTINCT + col1 DIV + col1 + col2 + + 33 * + 93 FROM tab1 AS cor0
----
3124
3127
3166

skipif mysql # not compatible
query I rowsort label-2467
SELECT DISTINCT + col1 / + col1 + col2 + + 33 * + 93 FROM tab1 AS cor0
----
3124
3127
3166

query I rowsort
SELECT DISTINCT - col1 + col1 * 52 - - col0 FROM tab1
----
1329
574
743

query I rowsort
SELECT 98 + - col0 AS col1 FROM tab0
----
63
74
9

query I rowsort
SELECT ALL 47 + col0 * + col2 + col0 AS col2 FROM tab0 AS cor0
----
117
7434
863

query I rowsort
SELECT DISTINCT - - ( - col0 ) + + col2 * - 41 FROM tab2 AS cor0
----
-1114
-1144
-1637

query I rowsort
SELECT DISTINCT + ( + col2 ) + - col0 * tab0.col2 * - col0 FROM tab0
----
1226
19041
649604

query I rowsort
SELECT - col0 + 25 AS col2 FROM tab0
----
-10
-64
1

query I rowsort
SELECT ALL - col0 FROM tab1 WHERE + col0 NOT IN ( - col0 * - col1 )
----
-3
-64
-80

query I rowsort
SELECT ALL col2 * - col1 + - col0 * + col0 AS col1 FROM tab1
----
-1413
-4666
-7648

onlyif mysql # use DIV operator for integer division
query I rowsort label-2476
SELECT + col0 + - col2 DIV col1 FROM tab1
----
1
59
73

skipif mysql # not compatible
query I rowsort label-2476
SELECT + col0 + - col2 / col1 FROM tab1
----
1
59
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-2477
SELECT + tab0.col2 DIV col0 + - col2 - - col0 AS col0 FROM tab0
----
-8
34
7

skipif mysql # not compatible
query I rowsort label-2477
SELECT + tab0.col2 / col0 + - col2 - - col0 AS col0 FROM tab0
----
-8
34
7

query III rowsort
SELECT * FROM tab2 WHERE NOT ( NULL ) NOT IN ( - col0 * tab2.col2 )
----

query I rowsort
SELECT ALL - tab1.col0 + - col2 AS col1 FROM tab1 WHERE NULL NOT IN ( - tab1.col1 )
----

query I rowsort
SELECT DISTINCT tab2.col0 + + tab2.col2 AS col0 FROM tab2
----
104
117
34

query I rowsort
SELECT - col0 FROM tab2 WHERE NOT ( NULL ) > NULL
----

query I rowsort
SELECT - col1 + - tab1.col0 AS col0 FROM tab1
----
-29
-74
-93

query I rowsort
SELECT DISTINCT col0 * + col2 + col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT DISTINCT + tab2.col1 + col0 * col1 FROM tab2
----
1360
248
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + col2 col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT col1 * - col2 * - col2 + + col2 FROM tab2
----
22626
24586
39910

query I rowsort
SELECT - tab2.col2 - col1 * + tab2.col2 AS col0 FROM tab2
----
-1560
-684
-864

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE + col0 > NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2489
SELECT - col0 DIV - col0 AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2489
SELECT - col0 / - col0 AS col2 FROM tab1
----
1
1
1

query I rowsort
SELECT ALL col1 * col2 * col1 AS col0 FROM tab0 WHERE NOT NULL IN ( + tab0.col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2491
SELECT DISTINCT col1 + - col1 DIV + col1 FROM tab1
----
12
25
9

skipif mysql # not compatible
query I rowsort label-2491
SELECT DISTINCT col1 + - col1 / + col1 FROM tab1
----
12
25
9

query I rowsort
SELECT + col1 - col2 FROM tab0
----
53
9
96

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( col1 ) NOT BETWEEN col2 * col2 + col2 AND NULL
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT ALL col0 * + col1 + + col1 * col1 AS col2 FROM tab0
----
12804
16380
9460

query I rowsort
SELECT DISTINCT col2 * col1 * + col0 + - col2 * col0 AS col1 FROM tab0
----
3360
656820
67320

query I rowsort
SELECT + col2 * - col0 * tab1.col2 FROM tab1
----
-207936
-737280
-8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-2497
SELECT - cor0.col0 DIV - col0 + - cor0.col2 + col2 * col2 AS col2 FROM tab0 AS cor0
----
1
1057
6643

skipif mysql # not compatible
query I rowsort label-2497
SELECT - cor0.col0 / - col0 + - cor0.col2 + col2 * col2 AS col2 FROM tab0 AS cor0
----
1
1057
6643

query I rowsort
SELECT + + col1 * + col0 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * cor0.col0 col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT col2 * - col1 - col2 AS col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT + - col1 + - col0 * - col0 FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT DISTINCT - col2 * - col1 - col1 AS col0 FROM tab1 AS cor0
----
1235
1378
560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 * - col2 col2 FROM tab2 cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-2504
SELECT + - cor0.col2 * - col2 + + col2 DIV - col1 AS col1 FROM tab0 AS cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-2504
SELECT + - cor0.col2 * - col2 + + col2 / - col1 AS col1 FROM tab0 AS cor0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 * cor0.col0 col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - cor0.col2 + + col0 AS col2 FROM tab2 AS cor0
----
-20
41
52

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE NOT ( col2 ) BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2508
SELECT + col2 * - col0 + col0 DIV col2 + + col0 AS col1 FROM tab1 AS cor0
----
-159
-3583
-7600

skipif mysql # not compatible
query I rowsort label-2508
SELECT + col2 * - col0 + col0 / col2 + + col0 AS col1 FROM tab1 AS cor0
----
-159
-3583
-7600

query I rowsort
SELECT col0 AS col0 FROM tab0 AS cor0 WHERE ( NULL ) BETWEEN col1 AND NULL
----

query III rowsort
SELECT DISTINCT * FROM tab2 cor0 WHERE NOT ( col0 / col2 ) <= ( NULL )
----

query I rowsort
SELECT ALL + col2 * + col1 + - col1 * + col0 AS col0 FROM tab0
----
-3298
-637
774

query I rowsort
SELECT cor0.col0 * col1 + cor0.col2 FROM tab0 AS cor0
----
2097
3396
8181

query IIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0 WHERE NULL <= ( NULL )
----

query I rowsort
SELECT tab0.col1 * col2 + + tab0.col0 AS col0 FROM tab0
----
132
2862
7551

query I rowsort
SELECT DISTINCT col1 + + col1 + col0 * col2 AS col1 FROM tab1
----
214
3668
7706

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col0 + - col2 + 17 col0 FROM tab1
----
-34
1
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2517
SELECT DISTINCT + - cor0.col1 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2517
SELECT DISTINCT + - cor0.col1 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2518
SELECT DISTINCT col2 * CAST( NULL AS SIGNED ) / col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2518
SELECT DISTINCT col2 * CAST ( NULL AS INTEGER ) / col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL col2 + ( col1 ) AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + cor0.col0 + 33 * - col2 AS col0 FROM tab2 AS cor0
----
-1175
-780
-884

query I rowsort
SELECT + + col1 + col2 + - 41 FROM tab0 cor0
----
132
57
78

query I rowsort
SELECT col2 + + ( col1 ) - - col0 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT DISTINCT - cor0.col2 * + ( + col0 ) FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-2524
SELECT col1 * col0 + col1 DIV + col0 + col0 AS col0 FROM tab0 AS cor0
----
2091
3432
8189

skipif mysql # not compatible
query I rowsort label-2524
SELECT col1 * col0 + col1 / + col0 + col0 AS col0 FROM tab0 AS cor0
----
2091
3432
8189

query I rowsort
SELECT cor0.col0 + - cor0.col0 * + col1 AS col1 FROM tab1 AS cor0
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-2526
SELECT - ( col0 ) DIV + col2 AS col2 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-2526
SELECT - ( col0 ) / + col2 AS col2 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT DISTINCT - 40 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-40

query I rowsort
SELECT + col1 * 11 AS col1 FROM tab2
----
187
341
649

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT 95 * col1 * 82 FROM tab1 AS cor0
----
101270
202540
77900

query I rowsort
SELECT ALL cor0.col2 + + cor0.col1 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 5484e660e65aa37f29a1eca3fc30f5cc

query I rowsort
SELECT DISTINCT col1 * col1 + col1 * - col0 FROM tab0
----
182
5332
6014

query I rowsort
SELECT 49 AS col1 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

query I rowsort
SELECT DISTINCT 3 * + col2 FROM tab0
----
246
3
99

query I rowsort
SELECT + + col0 + + col0 + + 2 FROM tab1 AS cor0
----
130
162
8

query I rowsort
SELECT + 39 + + tab0.col2 * + col0 - col0 AS col1 FROM tab0
----
39
7248
807

query I rowsort
SELECT DISTINCT - 34 + col2 - ( col0 ) * col0 FROM tab1
----
-4073
-6338
11

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * - col2 - col1 col1 FROM tab2
----
1427
617
698

query I rowsort
SELECT ALL + 50 * cor0.col1 * + col0 FROM tab0 AS cor0
----
103200
169750
404950

query I rowsort
SELECT + - col0 + - 7 * - col1 FROM tab0 AS cor0
----
548
578
644

query I rowsort
SELECT ALL + - 87 AS col2 FROM tab2 AS cor0
----
-87
-87
-87

query I rowsort
SELECT DISTINCT - 69 FROM tab1, tab2 AS cor0
----
-69

query I rowsort
SELECT ALL col1 + - col0 * + 64 FROM tab1
----
-166
-4086
-5107

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2544
SELECT DISTINCT CAST( cor0.col0 AS SIGNED ) + col2 AS col2 FROM tab2 AS cor0
----
104
117
34

skipif mysql # not compatible
query I rowsort label-2544
SELECT DISTINCT CAST ( cor0.col0 AS INTEGER ) + col2 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT col1 * - 89 FROM tab2
----
-1513
-2759
-5251

query I rowsort
SELECT 74 - + ( + col0 ) AS col1 FROM tab1
----
-6
10
71

query I rowsort
SELECT - + 22 AS col2 FROM tab2 AS cor0
----
-22
-22
-22

query I rowsort
SELECT ( col1 * + col1 ) AS col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL col0 * + 41 FROM tab2
----
287
3198
3239

query I rowsort
SELECT 9 * col2 AS col1 FROM tab1
----
486
513
864

query I rowsort
SELECT + col0 * + tab0.col2 AS col1 FROM tab0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - 35 + col2 col1 FROM tab2 AS cor0
----
-1058
-2039
-557

query I rowsort
SELECT DISTINCT + - col1 - + col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT + col1 + col1 * col1 + - col2 AS col2 FROM tab1 cor0
----
53
648
86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2555
SELECT DISTINCT - cor0.col1 - - CAST( NULL AS SIGNED ) * - col1 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2555
SELECT DISTINCT - cor0.col1 - - CAST ( NULL AS INTEGER ) * - col1 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col0 + ( + 85 ) * col0 AS col1 FROM tab0 AS cor0
----
2016
2940
7476

query I rowsort
SELECT ALL col2 * + col2 * col0 FROM tab2
----
114076
5103
52728

query I rowsort
SELECT DISTINCT - 88 + + col1 * 85 * col1 AS col0 FROM tab0
----
628572
703797
799677

query I rowsort
SELECT 38 + - col1 * + ( + col0 ) FROM tab0
----
-2026
-3357
-8061

query I rowsort
SELECT ALL col1 + tab0.col1 * 80 FROM tab0
----
6966
7371
7857

query I rowsort
SELECT 73 - tab0.col2 FROM tab0, tab2 cor0, tab1 AS cor1
----
27 values hashing to 210b0616bc1fd7cd9cf34f13ee409dbc

query I rowsort
SELECT + tab0.col0 + col0 + tab0.col0 AS col2 FROM tab0
----
105
267
72

query I rowsort
SELECT ALL - col2 + 40 * + col0 AS col2 FROM tab2 cor0
----
253
3094
3122

query I rowsort
SELECT ALL - + col1 + 40 AS col0 FROM tab1 AS cor0
----
14
27
30

query I rowsort
SELECT DISTINCT - col2 - - cor0.col2 * col0 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT DISTINCT - + col1 * 90 FROM tab0 AS cor0
----
-7740
-8190
-8730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 + - col0 + 2 col0 FROM tab2 cor0
----
-17
-60
26

query I rowsort
SELECT ALL col1 * 23 + col1 * - col1 FROM tab1 AS cor0
----
-78
130
130

query I rowsort
SELECT - col1 * + 8 FROM tab2 AS cor0
----
-136
-248
-472

query I rowsort
SELECT ALL + col2 * 55 + + col1 FROM tab2 cor0
----
1489
1516
2107

query I rowsort
SELECT + + col2 * - ( - col1 ) + - col1 AS col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT DISTINCT + col0 + - col1 * + col2 FROM tab0
----
-2814
-62
-7373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2573
SELECT CAST( NULL AS SIGNED ) col2 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2573
SELECT CAST ( NULL AS INTEGER ) col2 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) AS col1 FROM tab1, tab1 AS cor0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2575
SELECT ALL - - col2 DIV - 86 + col2 DIV cor0.col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2575
SELECT ALL - - col2 / - 86 + col2 / cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col2 * ( - col0 ) + col1 * cor0.col1 AS col2 FROM tab2 AS cor0
----
1150
3291
5509

query I rowsort
SELECT - 47 AS col1 FROM tab0 AS cor0
----
-47
-47
-47

query I rowsort
SELECT DISTINCT cor0.col0 * - 34 + col1 * 65 FROM tab2 AS cor0
----
-1581
1183
1777

query I rowsort
SELECT + + col1 + - 78 * + cor0.col0 AS col1 FROM tab2 AS cor0
----
-515
-6025
-6145

query I rowsort
SELECT ALL + col0 + col2 * - col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL + 89 AS col2 FROM tab0 cor0
----
89
89
89

query I rowsort
SELECT cor0.col0 * + tab2.col0 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 12930ec3ed2e24e506ebb47d036ed597

query I rowsort
SELECT + col2 * 49 + + col1 FROM tab0 cor0
----
146
1703
4109

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2584
SELECT + - CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2584
SELECT + - CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + 4 * 33 AS col2 FROM tab0 AS cor0
----
132

query I rowsort
SELECT ALL - col1 * + 83 + - col2 FROM tab2 AS cor0
----
-1449
-2600
-4923

query I rowsort
SELECT - ( + ( col1 ) ) * - ( col1 ) AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT col2 * - col1 + cor0.col2 FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2589
SELECT ALL CAST( col0 AS SIGNED ) + col2 FROM tab1 AS cor0
----
121
176
57

skipif mysql # not compatible
query I rowsort label-2589
SELECT ALL CAST ( col0 AS INTEGER ) + col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - cor0.col0 * + 6 + col1 FROM tab2 AS cor0
----
-11
-409
-457

onlyif mysql # use DIV operator for integer division
query I rowsort label-2591
SELECT 65 + - col0 DIV + col0 FROM tab1 AS cor0
----
64
64
64

skipif mysql # not compatible
query I rowsort label-2591
SELECT 65 + - col0 / + col0 FROM tab1 AS cor0
----
64
64
64

query I rowsort
SELECT DISTINCT + 78 * col0 AS col2 FROM tab2 cor0
----
546
6084
6162

query I rowsort
SELECT ALL col1 + + col0 AS col2 FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 42 col1 FROM tab0 AS cor0
----
42
42
42

query I rowsort
SELECT ALL 46 + + col2 * - 22 FROM tab1 AS cor0
----
-1142
-1208
-2066

query I rowsort
SELECT DISTINCT cor0.col2 * col2 AS col0 FROM tab2 AS cor0
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 49 - cor0.col2 col0 FROM tab1 cor0
----
-47
-5
-8

query I rowsort
SELECT DISTINCT - cor1.col2 FROM tab0, tab2 cor0, tab2 cor1
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - 78 + + col0 + - col0 FROM tab0
----
-78

query I rowsort
SELECT cor0.col0 * 3 * - 82 FROM tab2, tab1 AS cor0
----
9 values hashing to 0186edf2729151c91bba10b808cf6bf7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2601
SELECT DISTINCT + - col1 DIV col1 AS col2 FROM tab2 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-2601
SELECT DISTINCT + - col1 / col1 AS col2 FROM tab2 cor0
----
-1

query I rowsort
SELECT DISTINCT - + ( col1 ) * + ( + cor0.col2 + - col1 ) AS col0 FROM tab0 AS cor0
----
4558
819
9312

query I rowsort
SELECT ALL - ( - col1 ) * cor0.col2 + col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT - - col1 + col1 * col0 FROM tab2 AS cor0
----
1360
248
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col2 * col0 col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT + col1 * - col0 - + col0 FROM tab0 cor0
----
-2088
-3430
-8188

query I rowsort
SELECT - + 52 * - cor0.col2 + 71 AS col1 FROM tab1 cor0
----
2879
3035
5063

query I rowsort
SELECT - cor0.col1 + cor0.col0 + - col1 AS col2 FROM tab2 AS cor0
----
-40
-55
45

query I rowsort
SELECT - col1 + - ( col0 ) FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT - col2 + - cor0.col0 * + 4 AS col2 FROM tab2 AS cor0
----
-338
-354
-55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col0 col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col1 + 1 AS col1 FROM tab2 AS cor0
----
-16
-30
-58

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 cor0, tab1 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to 78077727601c056ad0d4f4c11c8daffb

query I rowsort
SELECT DISTINCT + - col0 * + col2 + col0 AS col2 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT col2 - - tab1.col0 FROM tab1
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-2616
SELECT DISTINCT + col0 DIV col0 + + ( tab2.col0 ) AS col0 FROM tab2
----
79
8
80

skipif mysql # not compatible
query I rowsort label-2616
SELECT DISTINCT + col0 / col0 + + ( tab2.col0 ) AS col0 FROM tab2
----
79
8
80

query I rowsort
SELECT + + col1 * col2 + + col0 AS col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT - col0 * + col1 * + ( + col0 ) + col1 AS col0 FROM tab0 AS cor0
----
-118728
-49450
-720720

onlyif mysql # use DIV operator for integer division
query I rowsort label-2619
SELECT + col0 DIV + col0 + col2 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-2619
SELECT + col0 / + col0 + col2 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT DISTINCT ( 99 ) AS col2 FROM tab1
----
99

query I rowsort
SELECT ALL - cor0.col1 AS col2 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT DISTINCT + 48 AS col2 FROM tab2, tab1 AS cor0
----
48

query I rowsort
SELECT ( - tab1.col2 ) * + tab1.col0 + - 58 AS col1 FROM tab1
----
-220
-3706
-7738

query I rowsort
SELECT ( + col1 ) * + tab1.col1 FROM tab1
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col2 * - col1 * col2 + ( + col0 ) col1 FROM tab0
----
-611795
-62
-93630

query I rowsort
SELECT 40 * - ( + col2 ) AS col1 FROM tab1
----
-2160
-2280
-3840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 + 29 * tab1.col0 col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 6289c3183642fe73c215d2835ff8d843

query I rowsort
SELECT 52 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

query I rowsort
SELECT - col0 * cor0.col1 + col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT - col0 * - col1 + cor0.col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT DISTINCT col2 * col0 * 5 FROM tab2 cor0
----
10140
15010
945

query I rowsort
SELECT - 90 * col1 AS col0 FROM tab1 AS cor0
----
-1170
-2340
-900

query I rowsort
SELECT ALL 28 * col1 + + col0 AS col2 FROM tab2 AS cor0
----
1730
555
875

onlyif mysql # use DIV operator for integer division
query I rowsort label-2634
SELECT ALL tab0.col1 DIV - col2 + 24 * col0 FROM tab0
----
2135
574
743

skipif mysql # not compatible
query I rowsort label-2634
SELECT ALL tab0.col1 / - col2 + 24 * col0 FROM tab0
----
2135
574
743

onlyif mysql # use DIV operator for integer division
query I rowsort label-2635
SELECT - col2 + 99 DIV col0 FROM tab0
----
-29
-81
1

skipif mysql # not compatible
query I rowsort label-2635
SELECT - col2 + 99 / col0 FROM tab0
----
-29
-81
1

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 AS cor2, tab1 AS cor3
----
3645 values hashing to 8bda8b9cf32f196464e0ee0b41a5162d

query I rowsort
SELECT ALL - - cor0.col1 + + cor0.col2 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT - - col2 + ( col1 ) * - col0 * ( - 16 * col2 ) FROM tab2 AS cor0
----
1914458
816582
93771

query I rowsort
SELECT - 68 + - tab1.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 24b6b2d30f2d343811b860205c6df2bc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 8 col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 47f43f23dcd23959d97d8e3b0aab692e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - 64 * col0 - 76 * + 54 col0 FROM tab1 AS cor0
----
-266248
-413704
-4680

query I rowsort
SELECT DISTINCT + 21 + col2 AS col1 FROM tab2 AS cor0
----
47
48
59

query I rowsort
SELECT ALL + 25 + - col1 FROM tab1 AS cor0
----
-1
12
15

query I rowsort
SELECT DISTINCT ( ( + col1 ) ) + 7 FROM tab2 AS cor0
----
24
38
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2645
SELECT + CAST( col0 AS SIGNED ) * + col0 + + col0 * - col2 FROM tab1 AS cor0
----
-1280
-153
448

skipif mysql # not compatible
query I rowsort label-2645
SELECT + CAST ( col0 AS INTEGER ) * + col0 + + col0 * - col2 FROM tab1 AS cor0
----
-1280
-153
448

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2646
SELECT DISTINCT + - ( - 48 ) * col1 + CAST( 62 AS SIGNED ) FROM tab2 AS cor0
----
1550
2894
878

skipif mysql # not compatible
query I rowsort label-2646
SELECT DISTINCT + - ( - 48 ) * col1 + CAST ( 62 AS INTEGER ) FROM tab2 AS cor0
----
1550
2894
878

query I rowsort
SELECT ALL 11 AS col1 FROM tab0
----
11
11
11

query I rowsort
SELECT - - 95 - col1 AS col0 FROM tab0 AS cor0
----
-2
4
9

query I rowsort
SELECT 96 * col0 - cor0.col1 AS col0 FROM tab1 AS cor0
----
262
6134
7667

query I rowsort
SELECT DISTINCT col0 - 15 * + col1 FROM tab1
----
-115
-387
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col0 ) * + col0 col0 FROM tab2
----
49
6084
6241

query I rowsort
SELECT - + 50 AS col0 FROM tab2 AS cor0
----
-50
-50
-50

query I rowsort
SELECT + - col0 + + col0 * col1 FROM tab0 cor0
----
2040
3360
8010

query I rowsort
SELECT + col0 * - 40 AS col1 FROM tab2 AS cor0
----
-280
-3120
-3160

onlyif mysql # use DIV operator for integer division
query I rowsort label-2655
SELECT - ( 1 ) DIV col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2655
SELECT - ( 1 ) / col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - - col1 * + 20 AS col2 FROM tab2 AS cor0
----
1180
340
620

query I rowsort
SELECT 45 * + col0 FROM tab1 cor0
----
135
2880
3600

query I rowsort
SELECT - + col0 - col1 AS col1 FROM tab1 cor0
----
-29
-74
-93

query I rowsort
SELECT 79 + - cor0.col0 * + col0 * + col0 AS col2 FROM tab1 AS cor0
----
-262065
-511921
52

query I rowsort
SELECT - 44 * 8 FROM tab2, tab1 AS cor0
----
9 values hashing to 3a0aaea6ea1cb387f1e42efb43cc2297

query I rowsort
SELECT DISTINCT - - 14 * col2 + + 61 * + ( col0 ) * - col2 AS col2 FROM tab0 AS cor0
----
-2121
-444030
-47850

query I rowsort
SELECT 90 - + col2 FROM tab2 AS cor0
----
52
63
64

query I rowsort
SELECT col0 * + col0 + ( col1 ) AS col0 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT ALL + col0 - - cor0.col0 AS col0 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT ALL + cor0.col0 + - col1 * 85 FROM tab1 AS cor0
----
-1025
-2207
-786

query I rowsort
SELECT - - 34 * - col1 - - col0 * col0 FROM tab0 AS cor0
----
-2073
-2348
4827

query I rowsort
SELECT DISTINCT + 55 AS col0 FROM tab0 cor0
----
55

query I rowsort
SELECT - - 5 + + col2 * col0 AS col0 FROM tab2 AS cor0
----
194
2033
3007

query I rowsort
SELECT DISTINCT cor1.col2 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
1
33
82

query I rowsort
SELECT + col0 * - col2 + - col1 FROM tab1
----
-188
-3658
-7693

query I rowsort
SELECT DISTINCT 65 FROM tab0, tab0 cor0, tab2 AS cor1
----
65

query I rowsort
SELECT - ( 94 ) FROM tab2, tab1 AS cor0
----
9 values hashing to a95bfa539191d3f72f6548147d7efb9e

query I rowsort
SELECT + - col0 * ( col1 * col2 ) AS col0 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT + + ( col1 ) + + col0 AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL + col0 + ( + col0 * + col1 ) FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT - 1 + - ( col0 ) AS col0 FROM tab0 AS cor0
----
-25
-36
-90

query I rowsort
SELECT col2 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + 6 * + col2 AS col1 FROM tab2 AS cor0
----
156
162
228

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + ( + col2 ) * col2 col1 FROM tab2 AS cor0
----
1461
735
760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2680
SELECT - + CAST( cor0.col0 AS SIGNED ) * col2 AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-2680
SELECT - + CAST ( cor0.col0 AS INTEGER ) * col2 AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-2681
SELECT ALL col1 DIV ( - col1 ) col2 FROM tab2
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2681
SELECT ALL col1 / ( - col1 ) col2 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT ALL - col0 * + 38 AS col0 FROM tab2
----
-266
-2964
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2683
SELECT ALL + col2 + col1 / - CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2683
SELECT ALL + col2 + col1 / - CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col0 - + col0 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 59 col0 FROM tab0 AS cor0
----
59
59
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + col1 col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT + + col1 * + col1 * col1 AS col0 FROM tab2 cor0
----
205379
29791
4913

query I rowsort
SELECT ALL - cor0.col2 * + cor0.col0 FROM tab1 cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2689
SELECT ALL + - col2 DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2689
SELECT ALL + - col2 / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 85 * col2 + col2 AS col0 FROM tab0 AS cor0
----
2838
7052
86

query I rowsort
SELECT col0 * col0 + + 72 * - col0 * - col0 FROM tab1 AS cor0
----
299008
467200
657

onlyif mysql # use DIV operator for integer division
query I rowsort label-2692
SELECT ALL - 84 DIV col0 AS col1 FROM tab1 cor0
----
-1
-1
-28

skipif mysql # not compatible
query I rowsort label-2692
SELECT ALL - 84 / col0 AS col1 FROM tab1 cor0
----
-1
-1
-28

query I rowsort
SELECT + ( col1 ) + 11 * + 1 FROM tab0 AS cor0
----
102
108
97

query I rowsort
SELECT ALL + col1 + col0 * + col2 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT - col2 + + ( 16 + + col1 ) * col2 FROM tab1 AS cor0
----
1425
2214
2688

query I rowsort
SELECT DISTINCT col1 + - ( col1 ) AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT col2 * + 10 FROM tab2 AS cor0
----
260
270
380

query I rowsort
SELECT 97 * + col1 FROM tab1
----
1261
2522
970

onlyif mysql # use DIV operator for integer division
query I rowsort label-2699
SELECT DISTINCT - cor0.col1 DIV + ( col0 + - col1 ) AS col2 FROM tab0 AS cor0
----
1
45

skipif mysql # not compatible
query I rowsort label-2699
SELECT DISTINCT - cor0.col1 / + ( col0 + - col1 ) AS col2 FROM tab0 AS cor0
----
1
45

query I rowsort
SELECT col0 * - tab2.col1 - col1 FROM tab2
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT - col1 + col0 AS col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT DISTINCT + 90 + col1 FROM tab0 AS cor0
----
176
181
187

query I rowsort
SELECT - - 41 - - col0 AS col2 FROM tab2 AS cor0
----
119
120
48

query I rowsort
SELECT ALL + 85 * + 35 AS col2 FROM tab0 AS cor0
----
2975
2975
2975

query I rowsort
SELECT 38 + cor0.col1 - cor0.col2 AS col1 FROM tab0 AS cor0
----
134
47
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2706
SELECT DISTINCT + CAST( col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2706
SELECT DISTINCT + CAST ( col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + + 26 + + col2 FROM tab2 AS cor0
----
52
53
64

query I rowsort
SELECT + col1 * + col1 - - col1 AS col2 FROM tab0 AS cor0
----
7482
8372
9506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2709
SELECT ALL col2 * + col2 + col1 * - CAST( NULL AS SIGNED ) - col0 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2709
SELECT ALL col2 * + col2 + col1 * - CAST ( NULL AS INTEGER ) - col0 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + ( + col2 ) + + col2 FROM tab2
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col0 col0 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-2712
SELECT col1 * + col1 + 80 * cor0.col0 + + col1 DIV 54 FROM tab2 AS cor0
----
1521
6609
9722

skipif mysql # not compatible
query I rowsort label-2712
SELECT col1 * + col1 + 80 * cor0.col0 + + col1 / 54 FROM tab2 AS cor0
----
1521
6609
9722

query I rowsort
SELECT 10 * - cor0.col1 AS col1 FROM tab1 AS cor0
----
-100
-130
-260

query I rowsort
SELECT ALL + ( col1 ) * + ( 52 ) AS col2 FROM tab0 cor0
----
4472
4732
5044

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2715
SELECT ALL - CAST( NULL AS SIGNED ) + col1 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2715
SELECT ALL - CAST ( NULL AS INTEGER ) + col1 AS col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2716
SELECT DISTINCT + 76 DIV + col2 + col1 * ( - tab1.col2 ) AS col0 FROM tab1
----
-1248
-1403
-569

skipif mysql # not compatible
query I rowsort label-2716
SELECT DISTINCT + 76 / + col2 + col1 * ( - tab1.col2 ) AS col0 FROM tab1
----
-1248
-1403
-569

query I rowsort
SELECT col2 + + 66 * col1 AS col0 FROM tab1
----
1770
717
954

query I rowsort
SELECT ALL - - cor0.col1 AS col2 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT 80 FROM tab1, tab2, tab1 cor0
----
27 values hashing to 6dd5038be71dffa82f5ceba787caab91

query I rowsort
SELECT - 88 FROM tab0, tab2 cor0, tab0 cor1
----
27 values hashing to eb8cbefa7d831e1a0183e919e2caef32

query I rowsort
SELECT + - col0 - col0 * - 74 FROM tab2 AS cor0
----
511
5694
5767

onlyif mysql # use DIV operator for integer division
query I rowsort label-2722
SELECT ALL 8 DIV + col1 col1 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2722
SELECT ALL 8 / + col1 col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2723
SELECT + 97 DIV cor0.col0 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 36d00a2b29852f88ac26d257535464fb

skipif mysql # not compatible
query I rowsort label-2723
SELECT + 97 / cor0.col0 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 36d00a2b29852f88ac26d257535464fb

query I rowsort
SELECT 78 + + col1 FROM tab1
----
104
88
91

query I rowsort
SELECT ALL - ( 25 ) + - col1 * - col1 AS col0 FROM tab2
----
264
3456
936

query I rowsort
SELECT ALL col1 * + col0 * 66 FROM tab1
----
42240
5148
68640

query I rowsort
SELECT ALL 77 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to d7b027bca5d37c67e29013904def8125

query I rowsort
SELECT ALL col0 + col1 + tab0.col1 FROM tab0
----
196
229
271

query I rowsort
SELECT ALL + col2 + - col1 * - col2 + - col0 AS col0 FROM tab2
----
1482
605
857

query I rowsort
SELECT 40 * - col1 FROM tab2
----
-1240
-2360
-680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2731
SELECT + col0 + col1 DIV - ( + tab1.col2 ) FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-2731
SELECT + col0 + col1 / - ( + tab1.col2 ) FROM tab1
----
3
64
80

query I rowsort
SELECT + col2 + + col2 + - 84 FROM tab2 AS cor0
----
-30
-32
-8

query I rowsort
SELECT - + col1 + - col0 + col2 AS col0 FROM tab0 AS cor0
----
-131
-77
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 + + col0 col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + col1 + - col1 - col2 * + col1 * col1 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT cor0.col2 * - cor0.col1 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 86c8e75d83d283b29460c020ab5988af

query I rowsort
SELECT 30 * - tab1.col1 AS col2 FROM tab1
----
-300
-390
-780

query I rowsort
SELECT DISTINCT + 56 * + col0 FROM tab0 AS cor0
----
1344
1960
4984

query I rowsort
SELECT - + 77 AS col1 FROM tab2 cor0
----
-77
-77
-77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2740
SELECT ALL + CAST( NULL AS SIGNED ) - cor0.col0 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2740
SELECT ALL + CAST ( NULL AS INTEGER ) - cor0.col0 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + col1 + col1 * ( + col1 ) FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT col0 * ( ( + cor0.col1 ) ) * ( col2 + + cor0.col1 ) FROM tab2 AS cor0
----
12586
391170
73865

query I rowsort
SELECT col2 + col0 * 16 FROM tab2
----
1274
1302
139

query I rowsort
SELECT + + 6 AS col2 FROM tab0 AS cor0
----
6
6
6

query I rowsort
SELECT DISTINCT - col2 - 19 FROM tab2 AS cor0
----
-45
-46
-57

skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( - ( - col0 ) AS REAL ) * + col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - col1 + + col1 * col2 * - 79 FROM tab2 AS cor0
----
-121245
-51051
-66154

query I rowsort
SELECT 82 * + col1 FROM tab2 AS cor0
----
1394
2542
4838

query I rowsort
SELECT ALL - col1 * - col0 + col2 AS col1 FROM tab2
----
1381
244
4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2750
SELECT DISTINCT CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2750
SELECT DISTINCT CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + col1 * ( cor0.col1 ) + - col2 AS col0 FROM tab2 cor0
----
251
3455
934

query I rowsort
SELECT DISTINCT + 25 + col0 * + col2 FROM tab1 cor0
----
187
3673
7705

onlyif mysql # use DIV operator for integer division
query I rowsort label-2753
SELECT ALL - 24 DIV col2 FROM tab0 AS cor0
----
-24
0
0

skipif mysql # not compatible
query I rowsort label-2753
SELECT ALL - 24 / col2 FROM tab0 AS cor0
----
-24
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2754
SELECT DISTINCT CAST( NULL AS SIGNED ) + col0 / col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2754
SELECT DISTINCT CAST ( NULL AS INTEGER ) + col0 / col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + + 75 * - col2 FROM tab0 cor0
----
-2475
-6150
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-2756
SELECT col0 + 20 + cor0.col2 DIV col2 AS col2 FROM tab1 AS cor0
----
101
24
85

skipif mysql # not compatible
query I rowsort label-2756
SELECT col0 + 20 + cor0.col2 / col2 AS col2 FROM tab1 AS cor0
----
101
24
85

query I rowsort
SELECT col0 - cor0.col1 AS col0 FROM tab1 AS cor0
----
-23
54
67

onlyif mysql # use DIV operator for integer division
query I rowsort label-2758
SELECT + col2 DIV 12 col0 FROM tab1
----
4
4
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2758
SELECT + col2 / 12 col0 FROM tab1
----
4
4
8

query I rowsort
SELECT + cor0.col1 * - col0 * 67 AS col2 FROM tab0 AS cor0
----
-138288
-227465
-542633

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + cor0.col2 * col2 col2 FROM tab2 cor0
----
1461
735
760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - col2 col0 FROM tab0 cor0
----
-171
-36
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2762
SELECT + - col1 - - CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-2762
SELECT + - col1 - - CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col0 + + col1 + col2 * - cor0.col2 FROM tab0 AS cor0
----
-1027
-6722
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-2764
SELECT DISTINCT col2 DIV + cor0.col2 FROM tab0 cor0
----
1

skipif mysql # not compatible
query I rowsort label-2764
SELECT DISTINCT col2 / + cor0.col2 FROM tab0 cor0
----
1

query I rowsort
SELECT + cor0.col2 + col1 AS col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT ALL - - 81 + cor0.col1 FROM tab0 AS cor0
----
167
172
178

query I rowsort
SELECT DISTINCT + col1 + + 57 * - cor0.col1 FROM tab2 AS cor0
----
-1736
-3304
-952

query I rowsort
SELECT + col1 + col2 * + col1 * + ( - 31 ) AS col0 FROM tab1 AS cor0
----
-17660
-38675
-43498

skipif mysql # not compatible
query I rowsort
SELECT + - CAST ( - col1 AS REAL ) * col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT col2 * 20 FROM tab1
----
1080
1140
1920

query I rowsort
SELECT + col0 * ( + tab1.col2 ) * col1 AS col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT col1 + - col2 * + 74 AS col1 FROM tab2 AS cor0
----
-1865
-1967
-2795

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 88 col0 FROM tab0 AS cor0
----
88
88
88

query I rowsort
SELECT ALL + 87 FROM tab1, tab2 AS cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2775
SELECT DISTINCT - CAST( NULL AS SIGNED ) * + 96 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2775
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * + 96 FROM tab1
----
NULL

query I rowsort
SELECT tab0.col0 * - col2 + - col2 FROM tab0
----
-36
-7380
-825

query I rowsort
SELECT - 14 * col2 * col1 FROM tab1 AS cor0
----
-17472
-19656
-7980

query I rowsort
SELECT - - cor0.col2 * col2 AS col0 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2779
SELECT ALL - CAST( ( - col2 ) AS SIGNED ) * CAST( + 7 AS SIGNED ) AS col2 FROM tab1
----
378
399
672

skipif mysql # not compatible
query I rowsort label-2779
SELECT ALL - CAST ( ( - col2 ) AS INTEGER ) * CAST ( + 7 AS INTEGER ) AS col2 FROM tab1
----
378
399
672

onlyif mysql # use DIV operator for integer division
query I rowsort label-2780
SELECT DISTINCT ( col0 ) * col0 DIV + ( col2 ) FROM tab0
----
1225
17
96

skipif mysql # not compatible
query I rowsort label-2780
SELECT DISTINCT ( col0 ) * col0 / + ( col2 ) FROM tab0
----
1225
17
96

query I rowsort
SELECT col0 * 77 FROM tab0 AS cor0
----
1848
2695
6853

query I rowsort
SELECT DISTINCT - + ( + col2 ) AS col0 FROM tab0 AS cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 97 col2 FROM tab2
----
97
97
97

query I rowsort
SELECT ALL + + cor1.col1 FROM tab1, tab0 AS cor0, tab0, tab0 AS cor1
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col1 * col0 col0 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT ALL - tab1.col1 + - 13 AS col2 FROM tab2, tab0, tab1 AS cor0, tab1
----
81 values hashing to 51e347fb72d7115c44a83ac1b5ea41b6

query I rowsort
SELECT DISTINCT - col1 + - col1 * cor0.col2 FROM tab0 cor0
----
-194
-2924
-7553

query I rowsort
SELECT ALL + col2 * 39 + + col0 AS col1 FROM tab1 AS cor0
----
2109
2287
3824

query I rowsort
SELECT col0 + 18 FROM tab2 AS cor0
----
25
96
97

query I rowsort
SELECT DISTINCT - + col2 * + col1 + cor0.col1 AS col1 FROM tab1 cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL + + col1 * + 89 + + col2 AS col0 FROM tab1 AS cor0
----
1253
2368
947

query I rowsort
SELECT DISTINCT - col1 * col2 + + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL 62 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

skipif mysql # not compatible
query I rowsort
SELECT col2 + + CAST ( - col2 AS REAL ) * - col0 AS col0 FROM tab1
----
216
3705
7776

query I rowsort
SELECT cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

onlyif mysql # use DIV operator for integer division
query I rowsort label-2796
SELECT ALL + cor0.col2 DIV 92 + - 11 * col1 * ( + col2 ) FROM tab1 AS cor0
----
-13727
-15444
-6270

skipif mysql # not compatible
query I rowsort label-2796
SELECT ALL + cor0.col2 / 92 + - 11 * col1 * ( + col2 ) FROM tab1 AS cor0
----
-13727
-15444
-6270

query I rowsort
SELECT ALL - col1 * ( cor0.col0 ) * + col0 + + ( + col2 ) FROM tab2 AS cor0
----
-106059
-1492
-358930

query I rowsort
SELECT DISTINCT - 28 FROM tab2
----
-28

query I rowsort
SELECT - ( col0 ) + cor0.col2 AS col2 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-2800
SELECT + ( - col2 ) * - col2 + CAST( - col2 AS SIGNED ) DIV col2 AS col0 FROM tab0 cor0
----
0
1088
6723

skipif mysql # not compatible
query I rowsort label-2800
SELECT + ( - col2 ) * - col2 + CAST ( - col2 AS INTEGER ) / col2 AS col0 FROM tab0 cor0
----
0
1088
6723

query I rowsort
SELECT + col1 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT 42 AS col1 FROM tab0, tab0 cor0 CROSS JOIN tab1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

query I rowsort
SELECT ( - 4 ) AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 39ed23475412c3cbba02ecdd2d7018e6

query I rowsort
SELECT 29 + + tab2.col1 FROM tab2
----
46
60
88

query I rowsort
SELECT ALL + 85 AS col1 FROM tab0
----
85
85
85

query I rowsort
SELECT DISTINCT - + cor0.col0 + - col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT ALL + col2 * - col1 + col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT - col1 + col2 * cor0.col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT - tab1.col0 * 70 AS col0 FROM tab1
----
-210
-4480
-5600

query I rowsort
SELECT - col1 + col2 + tab1.col2 FROM tab1
----
104
179
82

query I rowsort
SELECT DISTINCT - col1 + - 72 AS col0 FROM tab0
----
-158
-163
-169

query I rowsort
SELECT cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col1 col1 FROM tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT - col2 - - 34 * - 5 AS col0 FROM tab1
----
-224
-227
-266

query I rowsort
SELECT + col1 * - cor0.col2 + col1 AS col2 FROM tab0 AS cor0
----
-2752
-7371
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2816
SELECT ALL col1 * CAST( NULL AS DECIMAL ) - 40 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2816
SELECT ALL col1 * CAST ( NULL AS REAL ) - 40 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 - - 66 FROM tab0 AS cor0
----
148
67
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-2818
SELECT DISTINCT - col1 + + 14 DIV 15 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-2818
SELECT DISTINCT - col1 + + 14 / 15 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - col1 - ( col2 ) FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT DISTINCT col0 + ( - col2 ) FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT + col1 + + 9 FROM tab0 AS cor0
----
100
106
95

query I rowsort
SELECT col1 * - 56 * cor0.col1 FROM tab0 AS cor0
----
-414176
-463736
-526904

query I rowsort
SELECT 76 * + 20 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 9f98ddb3b8cf9fd1bb47ad9701328137

query I rowsort
SELECT ALL + cor1.col0 FROM tab2 cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT + col1 + - 94 * - 59 FROM tab0
----
5632
5637
5643

query I rowsort
SELECT ALL + 78 * - col2 - + col2 FROM tab2 AS cor0
----
-2054
-2133
-3002

query I rowsort
SELECT DISTINCT + col1 + + 92 FROM tab1 AS cor0
----
102
105
118

onlyif mysql # use DIV operator for integer division
query I rowsort label-2828
SELECT - CAST( ( col2 ) AS SIGNED ) + col0 * cor0.col2 DIV col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2828
SELECT - CAST ( ( col2 ) AS INTEGER ) + col0 * cor0.col2 / col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + ( - col0 ) + col2 AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL cor0.col1 * col2 * col2 AS col1 FROM tab2 cor0
----
22599
24548
39884

query I rowsort
SELECT ALL - + 2 FROM tab1 AS cor0
----
-2
-2
-2

query I rowsort
SELECT + 27 + ( - col2 ) FROM tab2
----
-11
0
1

query I rowsort
SELECT DISTINCT + 63 AS col2 FROM tab0
----
63

query I rowsort
SELECT ALL + col0 * 2 + col1 + col0 AS col2 FROM tab0 AS cor0
----
158
202
358

query I rowsort
SELECT ALL - ( col2 ) + + col0 AS col1 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT ALL cor0.col1 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL 93 + + 99 * col2 * col2 FROM tab1 AS cor0
----
288777
321744
912477

query I rowsort
SELECT + 52 - col0 FROM tab0
----
-37
17
28

query I rowsort
SELECT DISTINCT + + col2 + col2 * col1 FROM tab2 cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT - + col2 * + 60 FROM tab0 AS cor0
----
-1980
-4920
-60

query I rowsort
SELECT + col1 - col1 * + ( - col2 ) FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT + - cor0.col1 + - col1 * col1 FROM tab0 AS cor0
----
-7482
-8372
-9506

query I rowsort
SELECT col1 - col2 AS col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT - cor0.col1 + + ( col2 ) * col1 * - col0 AS col2 FROM tab1 AS cor0
----
-36490
-4238
-99853

onlyif mysql # use DIV operator for integer division
query I rowsort label-2845
SELECT - cor0.col2 * - 80 + ( col1 ) DIV + col2 FROM tab0 AS cor0
----
177
2642
6561

skipif mysql # not compatible
query I rowsort label-2845
SELECT - cor0.col2 * - 80 + ( col1 ) / + col2 FROM tab0 AS cor0
----
177
2642
6561

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 + + col1 * - col1 col2 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT ALL + col0 * ( - col1 * col0 ) FROM tab0 AS cor0
----
-118825
-49536
-720811

query I rowsort
SELECT + col0 - cor0.col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2849
SELECT ALL col1 DIV - 76 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2849
SELECT ALL col1 / - 76 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - + col2 * 20 + - 28 AS col1 FROM tab0 AS cor0
----
-1668
-48
-688

query I rowsort
SELECT + 11 + - tab1.col2 AS col2 FROM tab1
----
-43
-46
-85

query I rowsort
SELECT col1 + + col1 * ( ( + col1 ) ) FROM tab1
----
110
182
702

query I rowsort
SELECT DISTINCT - col0 * col2 * 36 + col0 AS col2 FROM tab0 AS cor0
----
-1225
-262639
-28488

query I rowsort
SELECT ALL cor0.col2 + col2 * - col2 - col1 AS col2 FROM tab0 AS cor0
----
-1142
-6733
-97

query I rowsort
SELECT ALL + 45 AS col0 FROM tab0
----
45
45
45

query I rowsort
SELECT ALL + cor0.col2 + col1 AS col2 FROM tab0 AS cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2857
SELECT ALL 13 DIV + col0 FROM tab1
----
0
0
4

skipif mysql # not compatible
query I rowsort label-2857
SELECT ALL 13 / + col0 FROM tab1
----
0
0
4

query I rowsort
SELECT DISTINCT + tab2.col2 + col1 AS col0 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL - col0 + - col2 * col0 * + col2 FROM tab0
----
-26160
-598525
-70

query I rowsort
SELECT - col0 + + col0 * col1 * + tab2.col1 + + col0 * col2 AS col1 FROM tab2
----
25754
273468
6909

query I rowsort
SELECT ALL + tab2.col1 * tab2.col0 + + col0 AS col2 FROM tab2
----
1422
224
4680

query I rowsort
SELECT tab0.col1 + col1 + - col1 * col0 FROM tab0
----
-1892
-3201
-7917

query I rowsort
SELECT - col1 * col0 - col1 FROM tab1 AS cor0
----
-104
-1053
-650

onlyif mysql # use DIV operator for integer division
query I rowsort label-2864
SELECT col2 * + col0 - col0 DIV - col0 AS col1 FROM tab0 AS cor0
----
36
7299
793

skipif mysql # not compatible
query I rowsort label-2864
SELECT col2 * + col0 - col0 / - col0 AS col1 FROM tab0 AS cor0
----
36
7299
793

query I rowsort
SELECT - - col0 + - col1 AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL - col2 + + tab2.col1 FROM tab2
----
-21
33
4

query I rowsort
SELECT - 73 FROM tab2 cor0
----
-73
-73
-73

query I rowsort
SELECT ALL - col0 + + 75 + col2 FROM tab1
----
126
68
91

query I rowsort
SELECT ALL - col1 + - ( + col1 + col0 ) * col0 FROM tab1
----
-113
-4746
-7453

query I rowsort
SELECT 27 + + col1 FROM tab1 AS cor0
----
37
40
53

query I rowsort
SELECT DISTINCT cor0.col1 + - col2 + col2 AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - + col1 + col1 + + col1 AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT + 70 + + col1 AS col0 FROM tab2 AS cor0
----
101
129
87

query I rowsort
SELECT 21 * cor0.col1 + col1 * + cor0.col1 FROM tab1 AS cor0
----
1222
310
442

query I rowsort
SELECT col1 * - col1 * col2 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT 74 * col1 FROM tab1
----
1924
740
962

query I rowsort
SELECT col2 * + col1 * tab1.col0 + col1 AS col2 FROM tab1
----
36490
4238
99853

query I rowsort
SELECT ALL - ( + tab2.col1 ) + + col2 AS col0 FROM tab2
----
-33
-4
21

query I rowsort
SELECT ALL 49 + col1 * - col2 AS col0 FROM tab1 AS cor0
----
-1199
-1355
-521

query I rowsort
SELECT DISTINCT - col2 * + col2 + - col2 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT + 11 + col1 FROM tab1 AS cor0
----
21
24
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-2882
SELECT ALL - col1 * - col1 + - col2 DIV col1 + + col2 AS col0 FROM tab2 AS cor0
----
325
3507
988

skipif mysql # not compatible
query I rowsort label-2882
SELECT ALL - col1 * - col1 + - col2 / col1 + + col2 AS col0 FROM tab2 AS cor0
----
325
3507
988

query I rowsort
SELECT ALL 98 * col1 + col0 * - col0 AS col2 FROM tab0 AS cor0
----
7852
8281
997

query I rowsort
SELECT DISTINCT 96 * + col1 FROM tab1 cor0
----
1248
2496
960

query I rowsort
SELECT - 75 AS col2 FROM tab2
----
-75
-75
-75

query I rowsort
SELECT ALL + 41 AS col1 FROM tab2 AS cor0
----
41
41
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + col1 col2 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + cor0.col2 col0 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT ALL - cor0.col1 * - col2 + - col1 + col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - 76 * + 97 * + cor0.col0 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 772428b5cec64eb1ea2a06e2bfc3e004

query I rowsort
SELECT ALL + 38 AS col2 FROM tab0
----
38
38
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2892
SELECT + + CAST( NULL AS SIGNED ) FROM tab2, tab0, tab1 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2892
SELECT + + CAST ( NULL AS INTEGER ) FROM tab2, tab0, tab1 cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - ( - ( - col1 ) ) * ( - col0 ) AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + 22 * col2 - 25 AS col2 FROM tab1 AS cor0
----
1163
1229
2087

query I rowsort
SELECT DISTINCT 18 * col2 * 8 - - col0 AS col2 FROM tab1 AS cor0
----
13904
7779
8272

query I rowsort
SELECT DISTINCT + 47 AS col0 FROM tab1 cor0
----
47

query I rowsort
SELECT - + 81 AS col1 FROM tab0 cor0
----
-81
-81
-81

query I rowsort
SELECT ALL ( + col1 ) * + col1 AS col2 FROM tab1
----
100
169
676

query I rowsort
SELECT + col1 * + col2 + - col2 + col0 FROM tab0 AS cor0
----
131
2829
7469

query I rowsort
SELECT - + col1 * 35 FROM tab2 AS cor0
----
-1085
-2065
-595

query I rowsort
SELECT DISTINCT + col1 * col0 * col1 AS col2 FROM tab0 cor0
----
177504
329315
737009

query I rowsort
SELECT - - col0 * col0 * + 66 FROM tab2 AS cor0
----
3234
401544
411906

query I rowsort
SELECT ALL col0 * + 48 + col2 FROM tab0 AS cor0
----
1185
1681
4354

onlyif mysql # use DIV operator for integer division
query I rowsort label-2904
SELECT col1 DIV 25 FROM tab2 cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-2904
SELECT col1 / 25 FROM tab2 cor0
----
0
1
2

query I rowsort
SELECT - col0 * - col1 * 66 + col0 AS col0 FROM tab0 AS cor0
----
136248
224105
534623

query I rowsort
SELECT - col0 * - ( col2 ) AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col0 * - 68 FROM tab2 AS cor0
----
-476
-5304
-5372

onlyif mysql # use DIV operator for integer division
query I rowsort label-2908
SELECT - - col2 DIV + ( col1 ) + - col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-2908
SELECT - - col2 / + ( col1 ) + - col0 FROM tab0 AS cor0
----
-24
-35
-89

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 cor0, tab0 AS cor1, tab0, tab0 cor2
----
3645 values hashing to e7ea8a30caeb35409d15d2ce0abbd5a6

query I rowsort
SELECT + - 27 AS col1 FROM tab0 AS cor0
----
-27
-27
-27

query I rowsort
SELECT col1 * - 4 AS col1 FROM tab0 cor0
----
-344
-364
-388

query I rowsort
SELECT + - 65 * 33 FROM tab1 AS cor0
----
-2145
-2145
-2145

query I rowsort
SELECT ALL col1 * - 94 FROM tab0
----
-8084
-8554
-9118

query I rowsort
SELECT + ( - col2 ) AS col2 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - + col2 * - ( - col2 ) + + col1 AS col2 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT - - 29 AS col0 FROM tab2 AS cor0
----
29
29
29

query I rowsort
SELECT + 40 * - 27 FROM tab2 AS cor0
----
-1080
-1080
-1080

query I rowsort
SELECT + + col2 * col0 * col2 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT + 76 * col2 + col2 FROM tab1 AS cor0
----
4158
4389
7392

query I rowsort
SELECT col0 + col1 * col0 AS col0 FROM tab0 AS cor0
----
2088
3430
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-2921
SELECT - ( + col0 ) DIV - col2 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2921
SELECT - ( + col0 ) / - col2 FROM tab1 AS cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2922
SELECT ALL tab1.col0 DIV + col2 col0 FROM tab1
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2922
SELECT ALL tab1.col0 / + col2 col0 FROM tab1
----
0
0
1

query I rowsort
SELECT DISTINCT 85 * col1 AS col1 FROM tab2 AS cor0
----
1445
2635
5015

query I rowsort
SELECT DISTINCT - + 72 * col0 FROM tab1 AS cor0
----
-216
-4608
-5760

onlyif mysql # use DIV operator for integer division
query I rowsort label-2925
SELECT + - ( col0 ) DIV + col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2925
SELECT + - ( col0 ) / + col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL + - col1 * 92 FROM tab1 AS cor0
----
-1196
-2392
-920

query I rowsort
SELECT ALL - ( col2 ) * cor0.col1 FROM tab2 cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-2928
SELECT DISTINCT - ( col2 ) DIV cor0.col1 FROM tab2 AS cor0
----
-2
0

skipif mysql # not compatible
query I rowsort label-2928
SELECT DISTINCT - ( col2 ) / cor0.col1 FROM tab2 AS cor0
----
-2
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - + col0 col1 FROM tab2
----
-41
-52
20

query I rowsort
SELECT DISTINCT + + col0 * - col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-2931
SELECT - + ( - col0 ) DIV col2 FROM tab0 cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-2931
SELECT - + ( - col0 ) / col2 FROM tab0 cor0
----
0
1
35

query I rowsort
SELECT + 67 AS col1 FROM tab2
----
67
67
67

query I rowsort
SELECT DISTINCT + + cor1.col0 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
24
35
89

query I rowsort
SELECT ALL - 88 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 467301f887614eb7beda22c561b0fad2

query I rowsort
SELECT - 6 FROM tab2 cor0
----
-6
-6
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor1.col1 col1 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT DISTINCT + 45 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
45

query I rowsort
SELECT - 11 * - tab1.col1 FROM tab1
----
110
143
286

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col0 * 0 * ( col1 ) col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL - + col1 * - 54 + + cor0.col2 * cor0.col2 AS col1 FROM tab1 AS cor0
----
3789
4320
9918

query I rowsort
SELECT ALL + 34 * cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 162f363b10ac4da0f1af554f398dcfca

query I rowsort
SELECT ALL col1 + - ( col0 ) * - col2 + - col0 * - ( col2 ) FROM tab2
----
409
4115
6021

query I rowsort
SELECT DISTINCT - col0 * + col2 + col2 AS col2 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT ALL - col1 * + col2 + col1 AS col1 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT ALL + 54 FROM tab2, tab2 AS cor0
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT + col2 * + cor0.col0 * - col0 AS col1 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT ALL - col2 * col0 + col2 * col2 AS col1 FROM tab2 AS cor0
----
-1352
-1558
540

query I rowsort
SELECT - col2 + + 72 AS col2 FROM tab2 AS cor0
----
34
45
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2949
SELECT + cor0.col0 * CAST( col2 AS SIGNED ) * col1 - + col1 AS col1 FROM tab1 AS cor0
----
36470
4186
99827

skipif mysql # not compatible
query I rowsort label-2949
SELECT + cor0.col0 * CAST ( col2 AS INTEGER ) * col1 - + col1 AS col1 FROM tab1 AS cor0
----
36470
4186
99827

query I rowsort
SELECT DISTINCT - - col0 + - col1 * col0 AS col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT - col2 * - 49 AS col2 FROM tab0 AS cor0
----
1617
4018
49

query I rowsort
SELECT ALL col2 * 76 * - col2 AS col2 FROM tab0 AS cor0
----
-511024
-76
-82764

onlyif mysql # use DIV operator for integer division
query I rowsort label-2953
SELECT ALL - + col0 DIV - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2953
SELECT ALL - + col0 / - col1 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 86 * - col2 AS col1 FROM tab1
----
4644
4902
8256

query I rowsort
SELECT + col2 * col1 + ( tab0.col2 * col2 ) FROM tab0
----
14186
3927
98

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab2 AS cor2, tab2 AS cor3
----
3645 values hashing to c9ee6ec1bc8c6eb5f95042f98a50bd57

query I rowsort
SELECT + 6 + + col2 AS col1 FROM tab0 AS cor0
----
39
7
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + 14 * col2 col0 FROM tab1
----
1424
759
862

query I rowsort
SELECT DISTINCT col2 * cor0.col0 * col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ALL col2 * 59 AS col1 FROM tab0 cor0
----
1947
4838
59

query I rowsort
SELECT - col0 + 70 + - cor0.col0 FROM tab2 AS cor0
----
-86
-88
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-2962
SELECT DISTINCT + - col2 DIV + col0 AS col0 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-2962
SELECT DISTINCT + - col2 / + col0 AS col0 FROM tab1 AS cor0
----
-1
-18
0

query I rowsort
SELECT col2 + 6 * 72 AS col1 FROM tab0 AS cor0
----
433
465
514

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + col0 + - 15 col2 FROM tab2 AS cor0
----
-1358
-232
-4617

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2965
SELECT - CAST( NULL AS SIGNED ) + + col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2965
SELECT - CAST ( NULL AS INTEGER ) + + col2 FROM tab2
----
NULL
NULL
NULL

query IIIIIIIII rowsort
SELECT * FROM tab1, tab1 AS cor0 CROSS JOIN tab1 cor1
----
243 values hashing to 2464a6f4cfabe66aeca50fcb4cd85bf5

query I rowsort
SELECT DISTINCT + col1 + + cor0.col2 + 7 FROM tab0 AS cor0
----
105
126
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 45 col1 FROM tab0, tab2 AS cor0 CROSS JOIN tab2
----
45

query I rowsort
SELECT ( - 47 ) * col0 AS col1 FROM tab0 AS cor0
----
-1128
-1645
-4183

query I rowsort
SELECT + - cor0.col1 FROM tab2, tab1, tab2 AS cor0, tab0
----
81 values hashing to b7a1b38fe8e4f34388e3be1f52601ae5

query I rowsort
SELECT 79 + cor0.col0 * col0 FROM tab2 cor0
----
128
6163
6320

query I rowsort
SELECT ALL + col0 * + col2 + - col2 AS col0 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT DISTINCT tab2.col1 * 61 FROM tab2, tab1 AS cor0
----
1037
1891
3599

query I rowsort
SELECT DISTINCT - 91 * col0 + + cor0.col0 FROM tab2 AS cor0
----
-630
-7020
-7110

query I rowsort
SELECT ALL - ( - col2 ) + ( - ( col0 ) ) * ( col2 + col2 ) * 46 FROM tab1 AS cor0
----
-14850
-335559
-706464

query I rowsort
SELECT col0 + col1 * - ( - col2 ) FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT + - 46 + - col0 AS col1 FROM tab1 AS cor0
----
-110
-126
-49

query I rowsort
SELECT DISTINCT - - 0 + cor0.col2 FROM tab1 cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( - col0 ) + - col1 * col2 col0 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT + 99 * + col1 * - cor0.col1 + - col0 * col0 AS col2 FROM tab2 AS cor0
----
-34852
-350703
-95188

query I rowsort
SELECT DISTINCT + col1 + + 13 * + 33 AS col2 FROM tab1 AS cor0
----
439
442
455

query I rowsort
SELECT ALL col1 * + col1 + - 32 FROM tab0 cor0
----
7364
8249
9377

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0, tab0 cor1, tab2 cor2
----
972 values hashing to 9600bdf5bac0caec3229e87170cc40b3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * ( + col0 ) + + col1 col2 FROM tab2 cor0
----
-158
-1969
-2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col1 * - col1 col2 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT + ( cor1.col1 ) * cor1.col0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to f2938bee011b8d49dd931b1f9235e7f5

query I rowsort
SELECT - 60 * 13 - - col0 AS col2 FROM tab1 AS cor0
----
-700
-716
-777

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col1 ) col2 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT ALL 73 * - col2 FROM tab1 AS cor0
----
-3942
-4161
-7008

query I rowsort
SELECT + 50 * col1 + cor0.col0 + ( col0 ) * col0 * 13 FROM tab0 AS cor0
----
107612
11812
20810

query I rowsort
SELECT DISTINCT - 97 + - col2 AS col0 FROM tab1 AS cor0
----
-151
-154
-193

query I rowsort
SELECT DISTINCT - 46 FROM tab0, tab1, tab0 AS cor0
----
-46

onlyif mysql # use DIV operator for integer division
query I rowsort label-2993
SELECT ALL 89 DIV tab0.col0 FROM tab0, tab2 cor0
----
9 values hashing to 245313dc4e9fc19df7ee93651efe9bf2

skipif mysql # not compatible
query I rowsort label-2993
SELECT ALL 89 / tab0.col0 FROM tab0, tab2 cor0
----
9 values hashing to 245313dc4e9fc19df7ee93651efe9bf2

query I rowsort
SELECT DISTINCT ( + 48 ) FROM tab2
----
48

skipif mysql # not compatible
query I rowsort
SELECT - ( - 57 * col1 + CAST ( + 17 AS REAL ) ) AS col2 FROM tab1
----
1465
553
724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - cor0.col1 col1 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT + + col1 - col0 AS col0 FROM tab1 AS cor0
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col1 ) * - col1 - + col0 col0 FROM tab0 AS cor0
----
7372
8192
9374

query I rowsort
SELECT 38 * col2 AS col0 FROM tab0 AS cor0
----
1254
3116
38

query I rowsort
SELECT - + col0 * - col0 + - col1 FROM tab1 cor0
----
-17
4086
6387

query I rowsort
SELECT - col1 * - col1 AS col1 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT col0 * + col1 + - col2 AS col1 FROM tab0
----
2031
3394
8017

query I rowsort
SELECT DISTINCT cor0.col0 + cor0.col1 FROM tab0, tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL ( 15 ) + col2 AS col2 FROM tab0
----
16
48
97

query I rowsort
SELECT ALL 43 * + col1 + col0 AS col1 FROM tab1
----
1121
494
639

query I rowsort
SELECT ( ( + cor0.col0 ) ) * 77 + col1 * - col2 FROM tab0 cor0
----
-609
-990
2598

query I rowsort
SELECT ALL - col1 + col0 + - col1 AS col0 FROM tab2 AS cor0
----
-40
-55
45

query I rowsort
SELECT + cor0.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT 63 * + 40 FROM tab0 AS cor0
----
2520
2520
2520

query I rowsort
SELECT + 96 + col2 FROM tab0
----
129
178
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 96 ) col1 FROM tab0 AS cor0
----
-96
-96
-96

query I rowsort
SELECT + cor0.col1 FROM tab1, tab0, tab2 cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - col2 ) * col2 + + 42 * col0 * + col2 col1 FROM tab2 AS cor0
----
127528
85852
8667

query I rowsort
SELECT + 50 * - col1 + + 55 AS col0 FROM tab2 AS cor0
----
-1495
-2895
-795

query I rowsort
SELECT + col2 * - tab0.col0 AS col1 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ( - col2 ) * + 43 AS col2 FROM tab0
----
-1419
-3526
-43

query I rowsort
SELECT - 28 * col1 FROM tab2
----
-1652
-476
-868

query I rowsort
SELECT - col1 * col0 + cor0.col0 * col1 * - col1 FROM tab1 AS cor0
----
-14560
-2106
-7040

query I rowsort
SELECT cor0.col2 * - 71 + - col2 AS col2 FROM tab2 AS cor0
----
-1872
-1944
-2736

query I rowsort
SELECT - - col0 * - col2 + 86 * - col2 AS col1 FROM tab2 AS cor0
----
-2511
-4264
-6270

query I rowsort
SELECT col1 + col0 + - col0 AS col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL + col0 + + ( col0 ) FROM tab2
----
14
156
158

query I rowsort
SELECT DISTINCT col0 + - ( col0 * - col2 ) FROM tab1
----
165
3712
7760

query I rowsort
SELECT ALL - col0 + - 90 FROM tab2
----
-168
-169
-97

query I rowsort
SELECT ALL - - col1 + col0 AS col1 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL + col0 - + ( col2 ) AS col0 FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3027
SELECT DISTINCT col0 DIV + col0 - cor0.col2 DIV col1 AS col2 FROM tab2 AS cor0
----
-1
1

skipif mysql # not compatible
query I rowsort label-3027
SELECT DISTINCT col0 / + col0 - cor0.col2 / col1 AS col2 FROM tab2 AS cor0
----
-1
1

query I rowsort
SELECT + col1 * + ( + col0 ) - - col2 * + col2 FROM tab1 AS cor0
----
10256
2994
3889

query I rowsort
SELECT ALL - ( col1 ) + col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT - cor0.col1 + + col2 + + col2 FROM tab0 AS cor0
----
-20
-95
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3031
SELECT DISTINCT - - CAST( + col0 AS SIGNED ) + col2 + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3031
SELECT DISTINCT - - CAST ( + col0 AS INTEGER ) + col2 + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT ( + 44 ) - col2 * - col0 * + col2 FROM tab2 cor0
----
114120
5147
52772

query I rowsort
SELECT - - 30 AS col2 FROM tab1 cor0
----
30
30
30

query I rowsort
SELECT ALL + - 57 FROM tab2 AS cor0
----
-57
-57
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 42 + ( cor0.col1 ) col0 FROM tab2 AS cor0
----
-11
-25
17

query I rowsort
SELECT 78 * col1 * + col1 AS col2 FROM tab2 AS cor0
----
22542
271518
74958

query I rowsort
SELECT + cor0.col1 * cor0.col1 + col0 FROM tab2 AS cor0
----
3559
368
968

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 * col2 - + col0 * 58 col0 FROM tab2 AS cor0
----
-1580
-217
-2496

query I rowsort
SELECT DISTINCT tab1.col0 AS col2 FROM tab1, tab2 AS cor0
----
3
64
80

query I rowsort
SELECT ALL + col2 + + 78 FROM tab0
----
111
160
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3041
SELECT + - 31 + + cor0.col1 * col0 DIV col1 FROM tab2 AS cor0
----
-24
47
48

skipif mysql # not compatible
query I rowsort label-3041
SELECT + - 31 + + cor0.col1 * col0 / col1 FROM tab2 AS cor0
----
-24
47
48

query I rowsort
SELECT - col2 * 19 * - col0 + ( + col1 * col0 ) FROM tab2 AS cor0
----
3808
43134
58381

query I rowsort
SELECT DISTINCT + col0 * col2 * cor0.col0 + + col1 AS col1 FROM tab1 AS cor0
----
233482
512
614413

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3044
SELECT DISTINCT + - CAST( col1 AS SIGNED ) + + cor0.col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3044
SELECT DISTINCT + - CAST ( col1 AS INTEGER ) + + cor0.col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT tab2.col2 * + ( col1 ) AS col2 FROM tab2
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-3046
SELECT ALL + - 33 + col2 DIV + col0 AS col0 FROM tab0 AS cor0
----
-32
-33
-33

skipif mysql # not compatible
query I rowsort label-3046
SELECT ALL + - 33 + col2 / + col0 AS col0 FROM tab0 AS cor0
----
-32
-33
-33

query I rowsort
SELECT ALL + cor0.col0 + - col0 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col0 * cor0.col1 AS col2 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL 4 + col0 * 70 * - col0 AS col2 FROM tab1 AS cor0
----
-286716
-447996
-626

onlyif mysql # use DIV operator for integer division
query I rowsort label-3050
SELECT DISTINCT col2 + cor0.col2 DIV + 95 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-3050
SELECT DISTINCT col2 + cor0.col2 / + 95 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT col1 * + col0 * + 80 - col0 AS col0 FROM tab0 AS cor0
----
165096
271565
647831

query I rowsort
SELECT DISTINCT + 41 * col1 AS col1 FROM tab1 cor0
----
1066
410
533

query I rowsort
SELECT ALL col0 + col2 * - col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT - + col1 * - col1 AS col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL - + col1 * + 90 FROM tab1 AS cor0
----
-1170
-2340
-900

query I rowsort
SELECT + - col2 - col1 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL + col2 + - col0 AS col1 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT DISTINCT - 94 * + col1 AS col0 FROM tab1 AS cor0
----
-1222
-2444
-940

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3059
SELECT ALL + - CAST( NULL AS SIGNED ) / + 61 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3059
SELECT ALL + - CAST ( NULL AS INTEGER ) / + 61 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 92 AS col2 FROM tab1 AS cor0
----
92
92
92

query I rowsort
SELECT DISTINCT + col0 + col1 * - col0 * col2 FROM tab2 AS cor0
----
-119574
-50955
-5852

query I rowsort
SELECT DISTINCT 21 + + col0 - cor0.col1 FROM tab1 cor0
----
-2
75
88

query I rowsort
SELECT - ( 2 ) FROM tab0
----
-2
-2
-2

query I rowsort
SELECT - col1 * - 4 AS col2 FROM tab1 cor0
----
104
40
52

query I rowsort
SELECT ALL 91 + col0 * col1 FROM tab0 cor0
----
2155
3486
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-3066
SELECT ( + ( + col2 ) ) + ( col1 ) DIV - col1 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-3066
SELECT ( + ( + col2 ) ) + ( col1 ) / - col1 FROM tab2 AS cor0
----
25
26
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + cor0.col2 * - col2 col1 FROM tab0 AS cor0
----
-1175
-6815
-98

query I rowsort
SELECT ALL 18 AS col2 FROM tab1 AS cor0
----
18
18
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3069
SELECT CAST( - 33 AS SIGNED ) AS col1 FROM tab0 cor0
----
-33
-33
-33

skipif mysql # not compatible
query I rowsort label-3069
SELECT CAST ( - 33 AS INTEGER ) AS col1 FROM tab0 cor0
----
-33
-33
-33

query I rowsort
SELECT ALL col2 * cor0.col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT ( - col1 ) * - col2 * + col2 AS col0 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT ALL - col0 + ( + tab2.col0 ) + col1 FROM tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 95 + + col1 col0 FROM tab1 AS cor0
----
105
108
121

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 + col1 + 68 * + col2 FROM tab1 AS cor0
----
3698
3886
6541

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3076
SELECT DISTINCT - CAST( col1 AS SIGNED ) * + cor0.col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

skipif mysql # not compatible
query I rowsort label-3076
SELECT DISTINCT - CAST ( col1 AS INTEGER ) * + cor0.col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT + cor0.col1 AS col0 FROM tab1, tab0 cor0, tab2 AS cor1
----
86
91
97

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 AS cor0 CROSS JOIN tab2, tab0 cor1
----
972 values hashing to deaaa983f771be544ffdc26f04a18657

query I rowsort
SELECT ALL - cor0.col2 * ( cor0.col0 ) + + cor0.col0 * - col1 FROM tab1 AS cor0
----
-240
-4288
-8720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 * 59 col0 FROM tab2 AS cor0
----
1003
1829
3481

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3081
SELECT DISTINCT CAST( NULL AS SIGNED ) + cor0.col1 FROM tab0, tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3081
SELECT DISTINCT CAST ( NULL AS INTEGER ) + cor0.col1 FROM tab0, tab1 cor0
----
NULL

query I rowsort
SELECT ALL col0 * + 96 + + 65 * col0 AS col0 FROM tab0 AS cor0
----
14329
3864
5635

query I rowsort
SELECT col2 + ( col1 ) FROM tab2
----
55
58
85

query I rowsort
SELECT ALL + 63 AS col1 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

query I rowsort
SELECT + col2 + - col1 * - col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT cor0.col1 * + 47 * - 90 FROM tab1 cor0
----
-109980
-42300
-54990

query I rowsort
SELECT 65 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT col2 * ( col2 ) AS col0 FROM tab0
----
1
1089
6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3089
SELECT + tab0.col2 + - CAST( NULL AS SIGNED ) * - col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3089
SELECT + tab0.col2 + - CAST ( NULL AS INTEGER ) * - col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - + ( cor0.col1 ) AS col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - + 71 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

query I rowsort
SELECT ALL ( tab2.col2 ) FROM tab2, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT col2 * col0 + col1 * - col1 FROM tab2 AS cor0
----
-1453
-772
2713

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + col2 col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL + + col1 + ( col2 ) FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT ( + 47 ) * - col1 * - col1 FROM tab2 AS cor0
----
13583
163607
45167

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( col1 AS REAL ) + col2 * + col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT 74 FROM tab0, tab2 AS cor0, tab1 cor1
----
74

query I rowsort
SELECT ALL + 85 * + cor0.col2 + - cor0.col1 AS col2 FROM tab2 AS cor0
----
2151
2264
3213

query I rowsort
SELECT DISTINCT col0 * cor0.col1 - col2 AS col2 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT + - 41 * + col2 FROM tab2 AS cor0
----
-1066
-1107
-1558

query I rowsort
SELECT ALL + + 22 + + col2 AS col0 FROM tab1 cor0
----
118
76
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3103
SELECT + col0 DIV - col2 + col2 AS col0 FROM tab0 AS cor0
----
-34
33
81

skipif mysql # not compatible
query I rowsort label-3103
SELECT + col0 / - col2 + col2 AS col0 FROM tab0 AS cor0
----
-34
33
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3104
SELECT ALL + 42 * col1 / - CAST( NULL AS SIGNED ) - + col2 * col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3104
SELECT ALL + 42 * col1 / - CAST ( NULL AS INTEGER ) - + col2 * col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + 70 FROM tab2 cor0
----
108
96
97

query I rowsort
SELECT ALL col0 - ( + cor0.col2 ) * col2 FROM tab0 cor0
----
-1065
-6635
34

query I rowsort
SELECT - col2 + - col1 * - 55 FROM tab1 AS cor0
----
1376
493
619

query I rowsort
SELECT ALL + - col0 + col2 * + col1 * col1 AS col0 FROM tab1 AS cor0
----
16144
36501
5636

query I rowsort
SELECT DISTINCT col2 * + col0 + col2 * col2 FROM tab1 AS cor0
----
16896
3078
6897

query I rowsort
SELECT col1 + ( col1 ) * - col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT - - col1 + - ( 63 ) FROM tab0 cor0
----
23
28
34

query I rowsort
SELECT ALL - - col1 * 58 AS col2 FROM tab2 AS cor0
----
1798
3422
986

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3113
SELECT DISTINCT - col2 - + CAST( NULL AS SIGNED ) / 32 col0 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3113
SELECT DISTINCT - col2 - + CAST ( NULL AS INTEGER ) / 32 col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - + col1 + - col2 AS col1 FROM tab1 cor0
----
-109
-67
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 + col1 * ( - col0 * col0 ) + col2 * col2 col1 FROM tab2 AS cor0
----
-104636
-358221
-759

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - - col1 * + 51 col0 FROM tab2 cor0
----
1612
3068
884

query I rowsort
SELECT 7 * col2 + + col2 * - col2 * col2 + 59 * + tab1.col0 AS col2 FROM tab1
----
-156909
-181018
-879344

query I rowsort
SELECT + + col0 + col1 * col1 AS col1 FROM tab2 AS cor0
----
3559
368
968

onlyif mysql # use DIV operator for integer division
query I rowsort label-3119
SELECT + + col1 DIV - col1 AS col2 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3119
SELECT + + col1 / - col1 AS col2 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT cor0.col1 AS col1 FROM tab0, tab2 cor0
----
17
31
59

query I rowsort
SELECT + 29 AS col1 FROM tab0 AS cor0
----
29
29
29

query I rowsort
SELECT ALL cor0.col2 * cor0.col2 FROM tab0, tab1 cor0
----
9 values hashing to aeb56f097f17f262600266df7fcf8652

query I rowsort
SELECT + - 87 * + col1 FROM tab2 AS cor0
----
-1479
-2697
-5133

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3124
SELECT ( - col0 ) * - CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-3124
SELECT ( - col0 ) * - CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - - col1 + + col2 AS col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL - - 28 FROM tab0 AS cor0
----
28
28
28

query I rowsort
SELECT col2 * - tab1.col2 AS col0 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT - col0 * 18 AS col2 FROM tab0 AS cor0
----
-1602
-432
-630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * 81 * cor0.col2 col2 FROM tab0 AS cor0
----
2835
591138
64152

onlyif mysql # use DIV operator for integer division
query I rowsort label-3130
SELECT - col2 DIV + col2 AS col2 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3130
SELECT - col2 / + col2 AS col2 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col0 * ( - 90 ) FROM tab0 AS cor0
----
-2160
-3150
-8010

query I rowsort
SELECT DISTINCT - 20 AS col2 FROM tab2
----
-20

query I rowsort
SELECT - 3 - + col2 * + col2 AS col2 FROM tab0 AS cor0
----
-1092
-4
-6727

query I rowsort
SELECT - + cor0.col0 + 53 AS col0 FROM tab2 AS cor0
----
-25
-26
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3135
SELECT - CAST( NULL AS DECIMAL ) + - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3135
SELECT - CAST ( NULL AS REAL ) + - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3136
SELECT ALL tab1.col2 DIV col1 AS col2 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-3136
SELECT ALL tab1.col2 / col1 AS col2 FROM tab1
----
2
5
7

query I rowsort
SELECT 22 * + 53 FROM tab2
----
1166
1166
1166

query I rowsort
SELECT - col1 * cor0.col1 * + col1 + + 9 - 11 * - col2 AS col0 FROM tab0 AS cor0
----
-635684
-752660
-912653

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3139
SELECT - CAST( NULL AS DECIMAL ) - + 67 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3139
SELECT - CAST ( NULL AS REAL ) - + 67 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - cor0.col2 * - cor0.col2 + col0 * 73 * - col2 + col1 FROM tab2 AS cor0
----
-14495
-148661
-220573

onlyif mysql # use DIV operator for integer division
query I rowsort label-3141
SELECT 87 + col1 * cor0.col2 + 51 DIV - 45 col0 FROM tab0 AS cor0
----
183
2924
7548

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3141
SELECT 87 + col1 * cor0.col2 + 51 / - 45 col0 FROM tab0 AS cor0
----
183
2924
7548

query I rowsort
SELECT - col0 + - cor0.col1 - - col0 AS col2 FROM tab0 AS cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - 17 ) col2 FROM tab2 AS cor0
----
17
17
17

query I rowsort
SELECT DISTINCT - tab1.col1 * 57 * col1 AS col0 FROM tab1
----
-38532
-5700
-9633

query I rowsort
SELECT col0 * - col0 * - col1 + tab2.col0 + col1 FROM tab2
----
106193
1557
359093

query I rowsort
SELECT col2 * 77 * col0 FROM tab1
----
12474
280896
591360

onlyif mysql # use DIV operator for integer division
query I rowsort label-3147
SELECT 69 + 52 DIV + col2 + col2 * + col1 FROM tab1
----
1317
1473
639

skipif mysql # not compatible
query I rowsort label-3147
SELECT 69 + 52 / + col2 + col2 * + col1 FROM tab1
----
1317
1473
639

onlyif mysql # use DIV operator for integer division
query I rowsort label-3148
SELECT col2 - + col1 * col0 DIV col2 AS col2 FROM tab0
----
-16
-29
-3394

skipif mysql # not compatible
query I rowsort label-3148
SELECT col2 - + col1 * col0 / col2 AS col2 FROM tab0
----
-16
-29
-3394

onlyif mysql # use DIV operator for integer division
query I rowsort label-3149
SELECT - col2 DIV - col1 + + col1 - 48 FROM tab2
----
-17
-29
11

skipif mysql # not compatible
query I rowsort label-3149
SELECT - col2 / - col1 + + col1 - 48 FROM tab2
----
-17
-29
11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3150
SELECT - CAST( ( + col2 ) AS SIGNED ) FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-3150
SELECT - CAST ( ( + col2 ) AS INTEGER ) FROM tab1
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 61 col1 FROM tab0
----
61

query I rowsort
SELECT ALL cor0.col0 + - cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to c22e7a33a1d8d55a5f7224b3cf03e3bc

query I rowsort
SELECT + 32 + col1 AS col0 FROM tab1
----
42
45
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 99 * + col2 col1 FROM tab1 AS cor0
----
5346
5643
9504

query I rowsort
SELECT 88 + cor0.col0 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to af798f5ce37f7c19e18927772657aa97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 68 - + col2 * col2 col2 FROM tab2 AS cor0
----
-1376
-608
-661

onlyif mysql # use DIV operator for integer division
query I rowsort label-3157
SELECT ALL - - col0 DIV + col1 + + cor0.col0 AS col2 FROM tab1 cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-3157
SELECT ALL - - col0 / + col1 + + cor0.col0 AS col2 FROM tab1 cor0
----
3
70
86

query I rowsort
SELECT + - cor0.col1 + - col2 FROM tab0 AS cor0
----
-119
-173
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3159
SELECT DISTINCT col0 DIV col0 + col0 + cor0.col1 FROM tab2 AS cor0
----
138
39
97

skipif mysql # not compatible
query I rowsort label-3159
SELECT DISTINCT col0 / col0 + col0 + cor0.col1 FROM tab2 AS cor0
----
138
39
97

query I rowsort
SELECT DISTINCT col1 * + col1 + + col2 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT DISTINCT + col1 + + cor0.col1 * col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT ALL - - col1 * - col1 + + col0 AS col1 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT + - 60 * col1 + col1 * - 36 AS col0 FROM tab0 AS cor0
----
-8256
-8736
-9312

query I rowsort
SELECT DISTINCT 48 AS col2 FROM tab0 AS cor0
----
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-3165
SELECT - 2 + - col2 DIV col0 FROM tab2 cor0
----
-2
-2
-5

skipif mysql # not compatible
query I rowsort label-3165
SELECT - 2 + - col2 / col0 FROM tab2 cor0
----
-2
-2
-5

query I rowsort
SELECT ALL - 15 * - col1 + + ( + 32 ) + col0 FROM tab1 cor0
----
246
307
425

query I rowsort
SELECT - - col0 * + 30 FROM tab1 AS cor0
----
1920
2400
90

query I rowsort
SELECT + col0 * 14 + col2 FROM tab1 AS cor0
----
1216
953
96

query I rowsort
SELECT ALL - 21 * col1 AS col0 FROM tab1 AS cor0
----
-210
-273
-546

onlyif mysql # use DIV operator for integer division
query I rowsort label-3170
SELECT DISTINCT 55 DIV ( + col0 ) FROM tab0 cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-3170
SELECT DISTINCT 55 / ( + col0 ) FROM tab0 cor0
----
0
1
2

query I rowsort
SELECT ALL + + 69 + col0 AS col2 FROM tab2 AS cor0
----
147
148
76

query I rowsort
SELECT 35 * col0 FROM tab1 AS cor0
----
105
2240
2800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3173
SELECT CAST( NULL AS SIGNED ) * col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3173
SELECT CAST ( NULL AS INTEGER ) * col1 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3174
SELECT CAST( + col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-3174
SELECT CAST ( + col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + + col0 + + ( + col0 ) * - col0 AS col0 FROM tab1 AS cor0
----
-4032
-6
-6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 - 86 col0 FROM tab1 AS cor0
----
-140
-143
-182

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col2 * col1 + - col0 col2 FROM tab1
----
36416
4209
99760

query I rowsort
SELECT col2 * + tab2.col2 AS col0 FROM tab2
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col0 * + tab1.col0 col0 FROM tab1
----
-4086
-6387
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-3180
SELECT ALL col1 + + col2 DIV - ( col2 * + col0 ) FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3180
SELECT ALL col1 + + col2 / - ( col2 * + col0 ) FROM tab0
----
86
91
97

query I rowsort
SELECT ALL - - ( col2 ) + col2 AS col2 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT + + col1 * - col2 - 58 FROM tab2 AS cor0
----
-1592
-704
-895

query I rowsort
SELECT + col1 + col2 * - 90 FROM tab0 AS cor0
----
-2884
-7289
7

query I rowsort
SELECT ALL + 2 FROM tab2
----
2
2
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-3185
SELECT DISTINCT - - col1 * col1 + - 34 DIV col1 + - col0 * col1 FROM tab0 AS cor0
----
182
5332
6014

skipif mysql # not compatible
query I rowsort label-3185
SELECT DISTINCT - - col1 * col1 + - 34 / col1 + - col0 * col1 FROM tab0 AS cor0
----
182
5332
6014

query I rowsort
SELECT - + cor0.col0 + - col0 AS col1 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT ALL + cor0.col1 * - 25 + col2 FROM tab1 AS cor0
----
-193
-229
-596

query I rowsort
SELECT DISTINCT col2 + + 74 FROM tab1 AS cor0
----
128
131
170

query I rowsort
SELECT DISTINCT - col2 + 36 * col2 * col2 FROM tab0 AS cor0
----
241982
35
39171

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - col0 col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL + col2 + - col2 - col0 AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT - col2 + ( + col1 ) * col1 AS col2 FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT - cor0.col1 + - 9 FROM tab0 AS cor0
----
-100
-106
-95

query I rowsort
SELECT col1 + ( + col1 ) AS col0 FROM tab1 cor0
----
20
26
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3195
SELECT ALL col2 + CAST( col0 AS SIGNED ) + + col0 FROM tab1 cor0
----
185
256
60

skipif mysql # not compatible
query I rowsort label-3195
SELECT ALL col2 + CAST ( col0 AS INTEGER ) + + col0 FROM tab1 cor0
----
185
256
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col2 col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - cor0.col0 + - col1 * + cor0.col1 + + col1 FROM tab0 AS cor0
----
-7334
-8279
-9347

query I rowsort
SELECT + - col1 * 88 * 73 FROM tab1 cor0
----
-167024
-64240
-83512

query I rowsort
SELECT col0 * - col0 + col0 * - 81 AS col2 FROM tab2 AS cor0
----
-12402
-12640
-616

query I rowsort
SELECT - 20 * cor0.col2 FROM tab0 cor0
----
-1640
-20
-660

query I rowsort
SELECT + + col2 + - col0 * - col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT + + col2 + 72 * - col2 FROM tab1 AS cor0
----
-3834
-4047
-6816

query I rowsort
SELECT tab0.col2 * + 59 FROM tab0
----
1947
4838
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-3204
SELECT ( 19 ) DIV tab1.col0 FROM tab1
----
0
0
6

skipif mysql # not compatible
query I rowsort label-3204
SELECT ( 19 ) / tab1.col0 FROM tab1
----
0
0
6

query I rowsort
SELECT DISTINCT - 84 * - col2 + - col2 FROM tab1 AS cor0
----
4482
4731
7968

query I rowsort
SELECT ALL + col2 * + col1 - col1 FROM tab1 AS cor0
----
1235
1378
560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 - - col0 col2 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT ALL col2 + - ( + col0 ) AS col1 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT col1 * 92 AS col0 FROM tab0 cor0
----
7912
8372
8924

query I rowsort
SELECT DISTINCT col2 * - col2 * col2 AS col0 FROM tab2 AS cor0
----
-17576
-19683
-54872

onlyif mysql # use DIV operator for integer division
query I rowsort label-3211
SELECT DISTINCT - + ( + 52 ) DIV col1 FROM tab2 AS cor0
----
-1
-3
0

skipif mysql # not compatible
query I rowsort label-3211
SELECT DISTINCT - + ( + 52 ) / col1 FROM tab2 AS cor0
----
-1
-3
0

query I rowsort
SELECT DISTINCT 61 + + 25 AS col0 FROM tab2 AS cor0
----
86

query I rowsort
SELECT ALL col0 * - cor0.col0 AS col1 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT - + 92 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 1af709a79a3e56281ffdce4d931d5965

query I rowsort
SELECT ALL - - cor0.col1 * + col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT ALL 71 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

query I rowsort
SELECT DISTINCT - 92 - col0 FROM tab0 AS cor0
----
-116
-127
-181

query I rowsort
SELECT ALL - 49 FROM tab0 AS cor0
----
-49
-49
-49

onlyif mysql # use DIV operator for integer division
query I rowsort label-3219
SELECT ALL 13 DIV col1 + - col2 AS col0 FROM tab2
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-3219
SELECT ALL 13 / col1 + - col2 AS col0 FROM tab2
----
-26
-27
-38

query I rowsort
SELECT - 18 - + col0 FROM tab1 cor0
----
-21
-82
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col1 + col0 * cor0.col2 col2 FROM tab1 AS cor0
----
214
3668
7706

query I rowsort
SELECT DISTINCT + col1 + + cor0.col0 AS col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL 72 * - col0 AS col2 FROM tab1 AS cor0
----
-216
-4608
-5760

query I rowsort
SELECT + col1 + + col1 + col1 FROM tab1 AS cor0
----
30
39
78

query I rowsort
SELECT col0 - + col0 AS col1 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL ( + 8 ) + - col1 FROM tab1
----
-18
-2
-5

query I rowsort
SELECT - col1 * + col0 - col1 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT + + 20 + col1 + + col0 FROM tab0 AS cor0
----
130
152
200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col0 + tab1.col1 col0 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT - tab1.col2 * col2 * col2 FROM tab1
----
-157464
-185193
-884736

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col1 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3232
SELECT CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-3232
SELECT CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + - ( + ( col1 ) ) * + col0 * col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3234
SELECT ALL + CAST( NULL AS SIGNED ) / + 8 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3234
SELECT ALL + CAST ( NULL AS INTEGER ) / + 8 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3235
SELECT ALL tab0.col2 + - 75 DIV - col0 AS col2 FROM tab0
----
3
36
82

skipif mysql # not compatible
query I rowsort label-3235
SELECT ALL tab0.col2 + - 75 / - col0 AS col2 FROM tab0
----
3
36
82

query I rowsort
SELECT ALL + ( ( tab1.col0 ) ) + - col1 * col0 AS col0 FROM tab1
----
-576
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - 34 ) col2 FROM tab1 AS cor0
----
-34
-34
-34

query I rowsort
SELECT + + 64 + col2 FROM tab1 cor0
----
118
121
160

query I rowsort
SELECT ALL + col0 + - col1 * col0 AS col1 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT col0 + col2 * - 67 AS col1 FROM tab2 AS cor0
----
-1664
-1802
-2467

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3241
SELECT - col2 * CAST( 1 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-3241
SELECT - col2 * CAST ( 1 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT col0 * 12 AS col1 FROM tab2 AS cor0
----
84
936
948

query I rowsort
SELECT + + col2 + - ( - col2 ) * + col0 AS col0 FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3244
SELECT - col2 * - CAST( NULL AS DECIMAL ) - - col2 * + col1 / col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3244
SELECT - col2 * - CAST ( NULL AS REAL ) - - col2 * + col1 / col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( col1 ) + - col0 * - col1 FROM tab0 cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT - col0 * 55 - col1 AS col2 FROM tab2 AS cor0
----
-416
-4349
-4362

query I rowsort
SELECT - - 62 * col2 + col2 FROM tab2 AS cor0
----
1638
1701
2394

query I rowsort
SELECT + col1 * - 28 + col0 AS col1 FROM tab0 AS cor0
----
-2384
-2459
-2681

query I rowsort
SELECT - - col0 * 18 - col0 AS col1 FROM tab1 AS cor0
----
1088
1360
51

query I rowsort
SELECT DISTINCT col1 * col2 + - col1 * - 42 * col2 - col0 FROM tab0 AS cor0
----
122010
320777
4136

query I rowsort
SELECT DISTINCT - ( col0 ) * - col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - + ( + 21 ) AS col2 FROM tab2 AS cor0
----
-21

query I rowsort
SELECT - cor0.col0 * col0 * + 45 FROM tab2 AS cor0
----
-2205
-273780
-280845

query I rowsort
SELECT - 30 + col1 * ( col1 ) FROM tab1
----
139
646
70

query I rowsort
SELECT - - 15 + - cor0.col2 FROM tab0 AS cor0
----
-18
-67
14

onlyif mysql # use DIV operator for integer division
query I rowsort label-3256
SELECT + - col0 + + cor0.col0 DIV + col0 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-3256
SELECT + - col0 + + cor0.col0 / + col0 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab1, tab2 cor0
----
26
27
38

query I rowsort
SELECT ALL - cor0.col2 * 46 FROM tab0 AS cor0
----
-1518
-3772
-46

query I rowsort
SELECT ALL - 40 * col2 FROM tab1
----
-2160
-2280
-3840

query I rowsort
SELECT DISTINCT + col1 * ( + 47 * cor0.col2 ) + col2 AS col2 FROM tab1 AS cor0
----
26847
58752
66042

onlyif mysql # use DIV operator for integer division
query I rowsort label-3261
SELECT ALL col0 - + ( + col0 ) DIV col1 FROM tab2 cor0
----
7
75
77

skipif mysql # not compatible
query I rowsort label-3261
SELECT ALL col0 - + ( + col0 ) / col1 FROM tab2 cor0
----
7
75
77

query I rowsort
SELECT ALL - - 82 FROM tab1, tab2, tab0 cor0
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

query I rowsort
SELECT ALL - col2 + 87 * col2 FROM tab1 AS cor0
----
4644
4902
8256

query I rowsort
SELECT ALL + + col1 * 29 FROM tab1 AS cor0
----
290
377
754

query I rowsort
SELECT + 83 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

query I rowsort
SELECT DISTINCT + 10 FROM tab0, tab0 AS cor0
----
10

query I rowsort
SELECT + col0 * tab2.col1 + - tab2.col1 FROM tab2
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-3268
SELECT DISTINCT - ( - col2 + - col0 ) DIV - col0 FROM tab2
----
-1
-4

skipif mysql # not compatible
query I rowsort label-3268
SELECT DISTINCT - ( - col2 + - col0 ) / - col0 FROM tab2
----
-1
-4

query I rowsort
SELECT cor1.col2 AS col0 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL - col0 + + col1 * + 63 FROM tab0 AS cor0
----
5394
5644
6076

query I rowsort
SELECT + tab2.col2 * col0 + col2 AS col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT DISTINCT - col0 * - col1 AS col0 FROM tab1
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col0 + ( + tab1.col2 ) col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT + col1 * + col0 + - col2 AS col2 FROM tab2
----
1305
190
4576

onlyif mysql # use DIV operator for integer division
query I rowsort label-3275
SELECT DISTINCT + cor0.col1 * cor0.col1 DIV col1 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-3275
SELECT DISTINCT + cor0.col1 * cor0.col1 / col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ( ( col2 ) ) * 65 AS col2 FROM tab1 AS cor0
----
3510
3705
6240

query I rowsort
SELECT DISTINCT + col2 * col1 * tab0.col1 FROM tab0
----
244068
679042
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - ( - 46 ) col2 FROM tab1
----
100
103
142

query I rowsort
SELECT col1 + - ( 66 ) FROM tab2
----
-35
-49
-7

query I rowsort
SELECT + col1 + col2 * col0 FROM tab2
----
2087
220
3019

query I rowsort
SELECT - col1 + - 66 FROM tab2
----
-125
-83
-97

query I rowsort
SELECT - 65 * - col0 FROM tab0
----
1560
2275
5785

query I rowsort
SELECT - - col2 + - cor0.col2 AS col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3284
SELECT 43 DIV col1 AS col2 FROM tab2 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-3284
SELECT 43 / col1 AS col2 FROM tab2 AS cor0
----
0
1
2

query I rowsort
SELECT ALL + col0 * col1 * 5 AS col1 FROM tab0 AS cor0
----
10320
16975
40495

query I rowsort
SELECT cor0.col2 * - col0 + - 99 AS col0 FROM tab1 cor0
----
-261
-3747
-7779

onlyif mysql # use DIV operator for integer division
query I rowsort label-3287
SELECT DISTINCT - col0 DIV + cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-3287
SELECT DISTINCT - col0 / + cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT - - ( col0 ) * - cor0.col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL - + col2 * col0 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3290
SELECT cor0.col0 * col1 + + col1 DIV col1 FROM tab0 cor0
----
2065
3396
8100

skipif mysql # not compatible
query I rowsort label-3290
SELECT cor0.col0 * col1 + + col1 / col1 FROM tab0 cor0
----
2065
3396
8100

query I rowsort
SELECT ALL ( tab0.col2 ) * col0 + - 45 + tab0.col1 FROM tab0
----
7344
833
87

query I rowsort
SELECT DISTINCT + col1 * tab0.col0 + - tab0.col1 FROM tab0
----
1978
3298
8008

query I rowsort
SELECT ( + col1 + - tab0.col2 ) * + col2 AS col2 FROM tab0
----
1749
738
96

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( + col1 AS REAL ) + col0 FROM tab0
----
110
132
180

query I rowsort
SELECT cor0.col2 AS col1 FROM tab0, tab2, tab0 cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT - + cor0.col2 * - cor0.col0 AS col1 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3297
SELECT ALL - 8 DIV - col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3297
SELECT ALL - 8 / - col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col2 + - col2 * ( + 18 ) FROM tab0 AS cor0
----
-1558
-19
-627

onlyif mysql # use DIV operator for integer division
query I rowsort label-3299
SELECT + col0 DIV col0 + + col2 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-3299
SELECT + col0 / col0 + + col2 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT + - col2 * col1 * 77 + col1 AS col0 FROM tab0 AS cor0
----
-218440
-574483
-7372

query I rowsort
SELECT - ( col2 ) * - ( cor0.col1 ) AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + col2 * + col0 * col0 AS col2 FROM tab2 cor0
----
1323
158184
237158

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 - col2 * col0 + - col2 * + col1 FROM tab1
----
-1566
-4218
-8928

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3305
SELECT ALL CAST( + col0 AS SIGNED ) * col0 + + col2 FROM tab2
----
6110
6279
76

skipif mysql # not compatible
query I rowsort label-3305
SELECT ALL CAST ( + col0 AS INTEGER ) * col0 + + col2 FROM tab2
----
6110
6279
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - col2 col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - + cor0.col2 * - col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - - 97 * col2 + + 78 AS col2 FROM tab0 AS cor0
----
175
3279
8032

query I rowsort
SELECT ALL 13 + col1 * - col2 AS col0 FROM tab0
----
-2825
-7449
-84

query I rowsort
SELECT DISTINCT + 17 + col0 + - col1 AS col2 FROM tab1
----
-6
71
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-3311
SELECT + col0 + - 62 DIV tab1.col1 FROM tab1
----
1
58
76

skipif mysql # not compatible
query I rowsort label-3311
SELECT + col0 + - 62 / tab1.col1 FROM tab1
----
1
58
76

query I rowsort
SELECT - 62 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to f0e93f6ff5fc3cf50a14e276206dad5c

query I rowsort
SELECT ALL + cor0.col0 + col2 * ( col2 ) FROM tab0 AS cor0
----
1113
36
6813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 15 * - col2 + 88 col2 FROM tab0 AS cor0
----
-1142
-407
73

query I rowsort
SELECT DISTINCT ( - col2 ) + 7 FROM tab2 AS cor0
----
-19
-20
-31

query I rowsort
SELECT ALL - cor0.col0 * col1 + - col1 FROM tab0 cor0
----
-2150
-3492
-8190

query I rowsort
SELECT ALL - 25 * - col1 FROM tab0 AS cor0
----
2150
2275
2425

query I rowsort
SELECT + + col2 * col2 + - ( + col0 * col0 ) + cor0.col1 FROM tab1 cor0
----
-837
2829
2933

query I rowsort
SELECT ALL col2 + col2 * 74 FROM tab2 AS cor0
----
1950
2025
2850

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col2 + + ( - col2 ) * col0 col0 FROM tab2 AS cor0
----
-2356
-494
648

query I rowsort
SELECT DISTINCT + + col1 + cor0.col1 FROM tab0 cor0
----
172
182
194

query I rowsort
SELECT DISTINCT - cor0.col1 + + 21 FROM tab2 AS cor0
----
-10
-38
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3323
SELECT DISTINCT - col0 * col0 - - col0 DIV - cor0.col1 FROM tab1 AS cor0
----
-4102
-6406
-9

skipif mysql # not compatible
query I rowsort label-3323
SELECT DISTINCT - col0 * col0 - - col0 / - cor0.col1 FROM tab1 AS cor0
----
-4102
-6406
-9

query I rowsort
SELECT ALL - col1 * 39 + - col2 + col0 AS col1 FROM tab0 cor0
----
-3363
-3542
-3749

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3325
SELECT DISTINCT + cor0.col1 + + CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3325
SELECT DISTINCT + cor0.col1 + + CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort
SELECT ALL - + col1 * CAST ( + col1 AS REAL ) - col0 AS col2 FROM tab2 AS cor0
----
-3559
-368
-968

onlyif mysql # use DIV operator for integer division
query I rowsort label-3327
SELECT col1 + + col2 DIV tab1.col0 AS col1 FROM tab1
----
10
14
44

skipif mysql # not compatible
query I rowsort label-3327
SELECT col1 + + col2 / tab1.col0 AS col1 FROM tab1
----
10
14
44

query I rowsort
SELECT + col0 + + 34 FROM tab2 AS cor0
----
112
113
41

query I rowsort
SELECT ALL col1 * 50 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
1246
443
554

onlyif mysql # use DIV operator for integer division
query I rowsort label-3330
SELECT ALL cor0.col0 + cor0.col2 + cor0.col2 DIV col1 FROM tab1 AS cor0
----
126
183
59

skipif mysql # not compatible
query I rowsort label-3330
SELECT ALL cor0.col0 + cor0.col2 + cor0.col2 / col1 FROM tab1 AS cor0
----
126
183
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3331
SELECT cor1.col0 - - CAST( 19 AS SIGNED ) FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 498e5ef265639e7ff8dbb333a4772786

skipif mysql # not compatible
query I rowsort label-3331
SELECT cor1.col0 - - CAST ( 19 AS INTEGER ) FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 498e5ef265639e7ff8dbb333a4772786

query I rowsort
SELECT - 93 - ( col2 ) FROM tab0 AS cor0
----
-126
-175
-94

query I rowsort
SELECT DISTINCT + - 15 - + col0 FROM tab0 AS cor0
----
-104
-39
-50

query I rowsort
SELECT DISTINCT + - 32 - - col2 AS col0 FROM tab2 AS cor0
----
-5
-6
6

query I rowsort
SELECT - ( - 48 ) * + col1 - col1 AS col0 FROM tab2 AS cor0
----
1457
2773
799

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - cor0.col2 + - col2 col0 FROM tab0 AS cor0
----
34
7216
759

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0, tab0 AS cor1, tab0 cor2
----
972 values hashing to d522b52b67b20888d3544d25cb98f232

onlyif mysql # use DIV operator for integer division
query I rowsort label-3338
SELECT + col2 DIV - 96 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3338
SELECT + col2 / - 96 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT + - col2 + cor0.col0 FROM tab0 cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3340
SELECT ALL - + col0 + cor0.col1 DIV + col2 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3340
SELECT ALL - + col0 + cor0.col1 / + col2 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL col0 * cor0.col2 + col0 FROM tab2 cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT - 83 + cor0.col1 FROM tab0 cor0
----
14
3
8

query I rowsort
SELECT + 23 - col2 FROM tab0 AS cor0
----
-10
-59
22

query I rowsort
SELECT + 32 AS col1 FROM tab0 AS cor0
----
32
32
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * cor0.col2 + col2 + - ( col1 + col1 ) col2 FROM tab2 AS cor0
----
1448
584
694

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 47 * + col0 col2 FROM tab2 AS cor0
----
-329
-3666
-3713

query I rowsort
SELECT DISTINCT + 98 + + 85 AS col0 FROM tab1 AS cor0
----
183

query I rowsort
SELECT DISTINCT ( 92 ) AS col0 FROM tab0
----
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3349
SELECT ALL - CAST( + ( - col0 ) + - 11 AS SIGNED ) * 37 * + col1 FROM tab2
----
194287
20646
56610

skipif mysql # not compatible
query I rowsort label-3349
SELECT ALL - CAST ( + ( - col0 ) + - 11 AS INTEGER ) * 37 * + col1 FROM tab2
----
194287
20646
56610

query I rowsort
SELECT 3 * cor0.col2 AS col0 FROM tab1 cor0
----
162
171
288

query I rowsort
SELECT ALL + - 24 - + col2 AS col2 FROM tab2 AS cor0
----
-50
-51
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3352
SELECT col1 - + col0 * col2 DIV + 81 FROM tab2 cor0
----
-20
29
34

skipif mysql # not compatible
query I rowsort label-3352
SELECT col1 - + col0 * col2 / + 81 FROM tab2 cor0
----
-20
29
34

query I rowsort
SELECT + 87 * - col0 + col1 AS col1 FROM tab1 cor0
----
-235
-5558
-6947

query I rowsort
SELECT + tab1.col0 * cor0.col1 * 77 FROM tab1, tab2 AS cor0
----
9 values hashing to 3bbcea0e01718659d645b9b906bb22ab

query I rowsort
SELECT - 42 AS col0 FROM tab2
----
-42
-42
-42

query I rowsort
SELECT + 30 + - tab1.col2 FROM tab1
----
-24
-27
-66

query I rowsort
SELECT DISTINCT 66 FROM tab2, tab2 AS cor0
----
66

query I rowsort
SELECT ALL cor0.col1 + + col1 AS col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT + col0 * + col1 * - 99 AS col0 FROM tab1 AS cor0
----
-102960
-63360
-7722

onlyif mysql # use DIV operator for integer division
query I rowsort label-3360
SELECT + col1 DIV - CAST( col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3360
SELECT + col1 / - CAST ( col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 * - 30 col1 FROM tab0 cor0
----
-1050
-2670
-720

query I rowsort
SELECT DISTINCT col1 * + col0 + + col1 + col2 FROM tab0
----
2183
3493
8272

query I rowsort
SELECT col0 * 41 FROM tab1 cor0
----
123
2624
3280

query I rowsort
SELECT - col1 + tab1.col1 * 48 FROM tab1
----
1222
470
611

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT - col2 * + col0 = + col1
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT ALL col1 + - col0 * col2 AS col0 FROM tab0 cor0
----
-706
-7207
62

query I rowsort
SELECT + col0 FROM tab1 WHERE + col0 * col0 >= - col1 / tab1.col0
----
3
64
80

query I rowsort
SELECT DISTINCT tab2.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3369
SELECT ALL + col0 DIV col0 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3369
SELECT ALL + col0 / col0 AS col1 FROM tab1
----
1
1
1

query I rowsort
SELECT DISTINCT - col0 + col1 + col1 * + col1 AS col1 FROM tab0
----
7458
8283
9471

query I rowsort
SELECT ALL - col1 + col2 * col2 + col0 * col2 AS col0 FROM tab2
----
2645
4429
887

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NULL NOT BETWEEN ( NULL ) AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3373
SELECT ALL + tab0.col0 DIV col2 AS col0 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-3373
SELECT ALL + tab0.col0 / col2 AS col0 FROM tab0
----
0
1
35

query I rowsort
SELECT ALL col0 AS col2 FROM tab0 WHERE ( col0 * - tab0.col0 - col0 ) >= ( NULL )
----

query I rowsort
SELECT + tab2.col1 + + col2 + - col0 FROM tab2
----
-24
51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3376
SELECT DISTINCT col1 DIV + tab0.col2 AS col1 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-3376
SELECT DISTINCT col1 / + tab0.col2 AS col1 FROM tab0
----
1
2
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 col2 FROM tab0, tab0 cor0
----
24
35
89

query I rowsort
SELECT ALL col2 + col0 * - col0 AS col1 FROM tab0 AS cor0
----
-1224
-543
-7839

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col1 col2 FROM tab1 cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * col1 col1 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-3381
SELECT DISTINCT col1 DIV col2 + col0 * col2 col1 FROM tab0 AS cor0
----
132
7299
794

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3381
SELECT DISTINCT col1 / col2 + col0 * col2 col1 FROM tab0 AS cor0
----
132
7299
794

query I rowsort
SELECT ALL + col0 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - col1 + tab2.col0 AS col0 FROM tab2
----
-24
19
62

query I rowsort
SELECT - col2 + col2 + 1 * - col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT 90 + col2 FROM tab1
----
144
147
186

query I rowsort
SELECT - col1 + + col2 * - col1 AS col1 FROM tab0
----
-194
-2924
-7553

query I rowsort
SELECT ALL + 93 AS col2 FROM tab0 cor0
----
93
93
93

query I rowsort
SELECT 64 + + col2 FROM tab0 AS cor0
----
146
65
97

query I rowsort
SELECT ALL ( + cor0.col0 ) + + 4 * + 59 FROM tab1 AS cor0
----
239
300
316

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col2 ) col2 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT DISTINCT - - col1 * - 15 FROM tab2 AS cor0
----
-255
-465
-885

query I rowsort
SELECT ALL - col2 + col0 * col0 FROM tab1 AS cor0
----
-45
4039
6304

query I rowsort
SELECT + + col2 * - ( col2 ) AS col0 FROM tab2 AS cor0
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col1 * - col0 col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT col1 + col2 * - 39 AS col2 FROM tab1 AS cor0
----
-2080
-2213
-3731

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 + + col1 * + cor0.col0 + - ( - col0 ) AS col1 FROM tab2 AS cor0
----
-613
3146
776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 - + col0 col2 FROM tab2 AS cor0
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col0 col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - col1 + 85 * col0 FROM tab2 AS cor0
----
564
6571
6698

query I rowsort
SELECT ALL col2 + col0 * + col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT 63 * + col0 + + tab1.col0 AS col1 FROM tab1
----
192
4096
5120

query I rowsort
SELECT 21 + - tab1.col2 FROM tab1
----
-33
-36
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-3403
SELECT col1 DIV - tab2.col0 - col1 * col2 AS col0 FROM tab2
----
-1534
-646
-841

skipif mysql # not compatible
query I rowsort label-3403
SELECT col1 / - tab2.col0 - col1 * col2 AS col0 FROM tab2
----
-1534
-646
-841

query I rowsort
SELECT - col0 * - col0 + + tab1.col2 AS col2 FROM tab1
----
4153
63
6496

query I rowsort
SELECT ALL - col0 * col2 FROM tab0 WHERE NULL <= - col2
----

query I rowsort
SELECT ALL col0 + col1 * + col1 AS col0 FROM tab2
----
3559
368
968

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT + col1 / + col1 + col0 + + col1 <= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3408
SELECT ALL col1 + + col0 DIV tab1.col0 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-3408
SELECT ALL col1 + + col0 / tab1.col0 FROM tab1
----
11
14
27

query I rowsort
SELECT DISTINCT - col0 + - col1 * tab0.col1 FROM tab0
----
-7420
-8370
-9444

query I rowsort
SELECT col2 / + col1 AS col2 FROM tab0 WHERE NOT ( NULL ) <> col0
----

query III rowsort
SELECT * FROM tab2 WHERE NOT ( col1 ) NOT IN ( + col1 * col0 + + col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + + col0 col0 FROM tab2
----
104
117
34

query I rowsort
SELECT DISTINCT tab0.col0 + col2 + - col0 * + col0 FROM tab0
----
-1189
-519
-7750

onlyif mysql # use DIV operator for integer division
query I rowsort label-3414
SELECT + tab2.col1 * tab2.col0 DIV - col0 FROM tab2
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-3414
SELECT + tab2.col1 * tab2.col0 / - col0 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT + col0 * col0 + tab2.col2 AS col2 FROM tab2
----
6110
6279
76

query III rowsort
SELECT * FROM tab1 WHERE ( col0 ) IN ( - col1 )
----

query I rowsort
SELECT ALL - col0 + - col2 * col1 AS col1 FROM tab2
----
-1612
-725
-844

query I rowsort
SELECT DISTINCT + col1 + col0 + + tab0.col2 FROM tab0
----
133
143
262

onlyif mysql # use DIV operator for integer division
query I rowsort label-3419
SELECT col2 * col2 DIV - col1 AS col1 FROM tab0
----
-12
-73
0

skipif mysql # not compatible
query I rowsort label-3419
SELECT col2 * col2 / - col1 AS col1 FROM tab0
----
-12
-73
0

query I rowsort
SELECT ALL + col1 AS col2 FROM tab1 WHERE NOT NULL IN ( + col2 / col0 - col1 )
----

query I rowsort
SELECT ALL - col1 + + col0 + + col0 FROM tab0
----
-27
-38
87

query III rowsort
SELECT * FROM tab2 WHERE NOT ( NULL ) = ( - col2 * col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3423
SELECT + col0 * col1 DIV - col2 FROM tab0
----
-3395
-62
-98

skipif mysql # not compatible
query I rowsort label-3423
SELECT + col0 * col1 / - col2 FROM tab0
----
-3395
-62
-98

query I rowsort
SELECT col0 + col2 * col2 + - col2 AS col0 FROM tab2
----
1485
709
728

query III rowsort
SELECT * FROM tab2 WHERE NOT ( NULL ) BETWEEN ( tab2.col1 ) AND ( + col0 - - col1 * col1 * col1 )
----

query III rowsort
SELECT * FROM tab1 WHERE col0 + col2 / col0 + - col0 <= NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col2 col1 FROM tab2
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col1 + col1 * + col0 col1 FROM tab2
----
1054
1989
6136

query I rowsort
SELECT DISTINCT col2 * + col2 * - col0 AS col2 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT col2 * - tab1.col2 * - col2 FROM tab1
----
157464
185193
884736

query I rowsort
SELECT DISTINCT col0 * + tab0.col1 * col1 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT ALL col1 * tab2.col0 AS col2 FROM tab2
----
1343
217
4602

query I rowsort
SELECT cor0.col0 * 55 FROM tab0, tab0 AS cor0
----
9 values hashing to a9ac1870cd1d3b91eef55464077bbaad

query I rowsort
SELECT - col0 + - 83 * 60 AS col1 FROM tab2 AS cor0
----
-4987
-5058
-5059

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + col1 * col0 col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL - col2 + cor0.col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col1 * ( col2 ) AS col0 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3438
SELECT DISTINCT col1 * col0 * - CAST( tab2.col0 + col1 AS SIGNED ) FROM tab2
----
-128928
-630474
-8246

skipif mysql # not compatible
query I rowsort label-3438
SELECT DISTINCT col1 * col0 * - CAST ( tab2.col0 + col1 AS INTEGER ) FROM tab2
----
-128928
-630474
-8246

query I rowsort
SELECT col0 * - 28 AS col2 FROM tab0 AS cor0
----
-2492
-672
-980

query I rowsort
SELECT DISTINCT - col2 * col2 * + col1 + col1 AS col1 FROM tab2
----
-22568
-24531
-39825

onlyif mysql # use DIV operator for integer division
query I rowsort label-3441
SELECT - col0 DIV + 66 col0 FROM tab0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3441
SELECT - col0 / + 66 col0 FROM tab0
----
-1
0
0

query I rowsort
SELECT DISTINCT col2 + 24 FROM tab1
----
120
78
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3443
SELECT + CAST( NULL AS SIGNED ) + + cor0.col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3443
SELECT + CAST ( NULL AS INTEGER ) + + cor0.col2 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3444
SELECT col0 * ( col0 ) - col0 DIV + col0 AS col2 FROM tab2 AS cor0
----
48
6083
6240

skipif mysql # not compatible
query I rowsort label-3444
SELECT col0 * ( col0 ) - col0 / + col0 AS col2 FROM tab2 AS cor0
----
48
6083
6240

query I rowsort
SELECT - + col1 + - ( + col0 ) * 90 AS col1 FROM tab0 AS cor0
----
-2246
-3247
-8101

query I rowsort
SELECT ALL col0 + - col2 + + col2 AS col2 FROM tab2
----
7
78
79

query I rowsort
SELECT col1 * col2 * col0 AS col0 FROM tab2 cor0
----
119652
51034
5859

query I rowsort
SELECT ALL col1 + col0 * col0 * col0 + col0 * - col2 FROM tab1
----
-109
258506
504333

query I rowsort
SELECT col2 * - col0 + 32 FROM tab0 AS cor0
----
-3
-7266
-760

query I rowsort
SELECT 68 * col1 AS col1 FROM tab2 AS cor0
----
1156
2108
4012

query I rowsort
SELECT DISTINCT col2 * - cor0.col2 * + col0 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT col2 * 37 AS col1 FROM tab0
----
1221
3034
37

query I rowsort
SELECT DISTINCT ( + col2 ) * - tab2.col1 FROM tab2
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 31 col0 FROM tab0, tab0 AS cor0
----
9 values hashing to f4b05206ee2fc0cf8007d9c3514885fa

query I rowsort
SELECT ALL cor0.col0 - + 53 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 02ca9d58e76e2012f203be77e57a8697

query I rowsort
SELECT ALL + 11 + - col0 FROM tab0 AS cor0
----
-13
-24
-78

query I rowsort
SELECT DISTINCT ( - cor0.col0 ) * - 10 AS col2 FROM tab2 AS cor0
----
70
780
790

query I rowsort
SELECT DISTINCT + + 80 FROM tab2 AS cor0
----
80

query I rowsort
SELECT ALL col0 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 27 col2 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
-27

query I rowsort
SELECT + col1 * - ( - col0 ) AS col0 FROM tab1 cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3462
SELECT col1 + ( - col2 ) * col0 DIV - 29 AS col2 FROM tab0 cor0
----
113
342
98

skipif mysql # not compatible
query I rowsort label-3462
SELECT col1 + ( - col2 ) * col0 / - 29 AS col2 FROM tab0 cor0
----
113
342
98

query I rowsort
SELECT DISTINCT 97 AS col1 FROM tab2, tab0, tab1 AS cor0
----
97

query I rowsort
SELECT + col1 * 27 AS col1 FROM tab2 AS cor0
----
1593
459
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-3465
SELECT + col1 * col0 DIV col1 AS col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3465
SELECT + col1 * col0 / col1 AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT ( + col0 * + col2 ) FROM tab1
----
162
3648
7680

query I rowsort
SELECT + col0 * + 14 + col0 AS col1 FROM tab2 AS cor0
----
105
1170
1185

onlyif mysql # use DIV operator for integer division
query I rowsort label-3468
SELECT col0 - - ( col1 ) DIV 21 AS col1 FROM tab0 AS cor0
----
28
39
93

skipif mysql # not compatible
query I rowsort label-3468
SELECT col0 - - ( col1 ) / 21 AS col1 FROM tab0 AS cor0
----
28
39
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - 12 ) * col0 col0 FROM tab0 AS cor0
----
-1068
-288
-420

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 cor0, tab0, tab0 AS cor1
----
972 values hashing to 3406497351e4789c89a295ee9b64b201

query I rowsort
SELECT ALL - + ( + 3 ) FROM tab2 AS cor0
----
-3
-3
-3

query I rowsort
SELECT - ( + 66 ) * col0 + + cor0.col2 FROM tab2 AS cor0
----
-435
-5122
-5176

query I rowsort
SELECT ALL - + col2 * col1 * col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT ALL - 85 FROM tab0, tab0 AS cor0
----
9 values hashing to 8ebc8ffafb1517ea04e3a6fc4059d88a

query I rowsort
SELECT col2 * + cor0.col2 + - 76 FROM tab0 AS cor0
----
-75
1013
6648

query I rowsort
SELECT ALL ( ( col2 ) ) AS col2 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( col1 AS REAL ) * col2 + col1 * - col0 AS col1 FROM tab2 AS cor0
----
-3068
-697
620

query I rowsort
SELECT ALL 86 AS col2 FROM tab1 AS cor0
----
86
86
86

query I rowsort
SELECT DISTINCT - col1 * 10 * col1 AS col2 FROM tab2 AS cor0
----
-2890
-34810
-9610

onlyif mysql # use DIV operator for integer division
query I rowsort label-3480
SELECT ALL col2 DIV 15 FROM tab2 AS cor0
----
1
1
2

skipif mysql # not compatible
query I rowsort label-3480
SELECT ALL col2 / 15 FROM tab2 AS cor0
----
1
1
2

query I rowsort
SELECT 70 * col1 AS col2 FROM tab1 AS cor0
----
1820
700
910

query I rowsort
SELECT DISTINCT col1 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 27 * + 55 col0 FROM tab2 AS cor0
----
1485
1485
1485

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3484
SELECT + + CAST( NULL AS DECIMAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3484
SELECT + + CAST ( NULL AS REAL ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( + ( + col2 ) ) * 91 FROM tab2 AS cor0
----
-2366
-2457
-3458

query I rowsort
SELECT ALL + cor1.col0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT col0 * + ( + col1 ) + + col1 FROM tab2 cor0
----
1360
248
4661

query I rowsort
SELECT ALL - ( - col0 ) AS col2 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 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + + col2 + col0 * + col1 AS col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL 75 * col2 + - col0 * col2 AS col0 FROM tab0 AS cor0
----
-1148
1683
40

query I rowsort
SELECT DISTINCT - 49 - + col1 AS col1 FROM tab0 AS cor0
----
-135
-140
-146

query I rowsort
SELECT ALL 40 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT + ( col2 ) * col1 AS col0 FROM tab1
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-3495
SELECT ALL + col1 DIV 28 FROM tab0 AS cor0
----
3
3
3

skipif mysql # not compatible
query I rowsort label-3495
SELECT ALL + col1 / 28 FROM tab0 AS cor0
----
3
3
3

query I rowsort
SELECT DISTINCT - col1 + - col1 FROM tab2 cor0
----
-118
-34
-62

query I rowsort
SELECT col1 * - 81 AS col1 FROM tab1 AS cor0
----
-1053
-2106
-810

query I rowsort
SELECT ALL col2 + col1 - - 74 AS col2 FROM tab0
----
172
193
247

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3499
SELECT DISTINCT CAST( NULL AS DECIMAL ) FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-3499
SELECT DISTINCT CAST ( NULL AS REAL ) FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
NULL

query I rowsort
SELECT cor0.col0 * + 29 FROM tab1, tab2 AS cor0
----
9 values hashing to af4733015d9e577cc3ec6bccfb989962

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 cor0, tab2, tab2 cor1
----
972 values hashing to a47a9db07c7de4927c7c28efb4cd13f2

query I rowsort
SELECT ALL - 87 * + tab2.col0 FROM tab2
----
-609
-6786
-6873

query I rowsort
SELECT ALL col1 * - 80 + + 1 FROM tab1
----
-1039
-2079
-799

query I rowsort
SELECT ALL col0 * col1 + col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT col1 + ( - 35 ) * + col2 * col2 FROM tab0 cor0
----
-235249
-38029
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3506
SELECT ALL + 0 DIV cor0.col2 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-3506
SELECT ALL + 0 / cor0.col2 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL - 10 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to bb7f754a7a056e665155ed52a63f5bc0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3508
SELECT DISTINCT col1 + + CAST( 37 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
123
128
134

skipif mysql # not compatible
query I rowsort label-3508
SELECT DISTINCT col1 + + CAST ( 37 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
123
128
134

query I rowsort
SELECT DISTINCT - + col1 + col0 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL + - col2 + - 17 FROM tab1 AS cor0
----
-113
-71
-74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - 85 - + 21 * - cor0.col0 col0 FROM tab0 AS cor0
----
-5866
-6806
-7510

onlyif mysql # use DIV operator for integer division
query I rowsort label-3512
SELECT - col2 DIV + col2 + col2 * col1 FROM tab1 AS cor0
----
1247
1403
569

skipif mysql # not compatible
query I rowsort label-3512
SELECT - col2 / + col2 + col2 * col1 FROM tab1 AS cor0
----
1247
1403
569

query I rowsort
SELECT col2 + col1 + col0 * - tab0.col0 * - ( + col2 ) AS col2 FROM tab0
----
1323
19127
649695

onlyif mysql # use DIV operator for integer division
query I rowsort label-3514
SELECT ALL col1 * col2 + col1 DIV - 52 FROM tab2 AS cor0
----
1533
646
837

skipif mysql # not compatible
query I rowsort label-3514
SELECT ALL col1 * col2 + col1 / - 52 FROM tab2 AS cor0
----
1533
646
837

query I rowsort
SELECT DISTINCT cor0.col1 + - 17 * + col0 AS col1 FROM tab0 AS cor0
----
-1422
-322
-498

query I rowsort
SELECT DISTINCT + col0 + 85 * - col1 FROM tab1 AS cor0
----
-1025
-2207
-786

query I rowsort
SELECT - ( + 95 ) * - col2 FROM tab1
----
5130
5415
9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-3518
SELECT DISTINCT col2 DIV - 64 col2 FROM tab2
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3518
SELECT DISTINCT col2 / - 64 col2 FROM tab2
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 51 col1 FROM tab0, tab2, tab1 cor0
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

query I rowsort
SELECT - cor1.col0 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

onlyif mysql # use DIV operator for integer division
query I rowsort label-3521
SELECT ALL 77 DIV - col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3521
SELECT ALL 77 / - col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 63 * col1 + - col0 AS col0 FROM tab0
----
5394
5644
6076

query I rowsort
SELECT ALL - col0 * - cor0.col1 + + col0 AS col2 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + col1 * + cor0.col0 - + 73 FROM tab0 AS cor0
----
1991
3322
8026

query I rowsort
SELECT DISTINCT col2 * - col2 + - col1 + - ( - col2 ) AS col0 FROM tab2 AS cor0
----
-1423
-709
-733

query I rowsort
SELECT ALL col1 * col2 - col2 * + col0 AS col2 FROM tab2 AS cor0
----
-2356
-494
648

query I rowsort
SELECT ALL col1 * cor0.col2 * 58 AS col0 FROM tab2 AS cor0
----
37468
48546
88972

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * col1 col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + 9 AS col2 FROM tab1 cor0
----
9

query I rowsort
SELECT + col2 * col0 + - 72 AS col1 FROM tab1 AS cor0
----
3576
7608
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3531
SELECT DISTINCT + - col2 DIV + ( col1 ) FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3531
SELECT DISTINCT + - col2 / + ( col1 ) FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + + col2 * - col2 + 84 * col0 FROM tab2 AS cor0
----
-141
5192
5876

onlyif mysql # use DIV operator for integer division
query I rowsort label-3533
SELECT ALL - col0 DIV cor0.col2 - + ( col1 * - col2 ) FROM tab1 AS cor0
----
1248
1404
569

skipif mysql # not compatible
query I rowsort label-3533
SELECT ALL - col0 / cor0.col2 - + ( col1 * - col2 ) FROM tab1 AS cor0
----
1248
1404
569

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - - col2 col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + col2 * - col1 AS col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT - - col0 + ( col2 ) * cor0.col1 * ( 53 * + col0 ) FROM tab0 cor0
----
179970
35198343
3609960

query I rowsort
SELECT col1 * + col2 + + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL + + col2 * col1 - - col1 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
1140
2496
2808

query I rowsort
SELECT ALL - 50 * - col2 - + 32 FROM tab0
----
1618
18
4068

query I rowsort
SELECT ALL + - 61 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to c91d7b51e91f33d302e697913fb438b6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 18 + + col1 col1 FROM tab0
----
104
109
115

onlyif mysql # use DIV operator for integer division
query I rowsort label-3542
SELECT DISTINCT - + col2 DIV - col2 FROM tab1 cor0
----
1

skipif mysql # not compatible
query I rowsort label-3542
SELECT DISTINCT - + col2 / - col2 FROM tab1 cor0
----
1

query I rowsort
SELECT DISTINCT 55 - + col1 AS col1 FROM tab2
----
-4
24
38

query I rowsort
SELECT DISTINCT - 23 * + col0 AS col0 FROM tab1
----
-1472
-1840
-69

query I rowsort
SELECT ( + 25 + - col1 ) AS col0 FROM tab0
----
-61
-66
-72

query I rowsort
SELECT DISTINCT - 58 AS col0 FROM tab2
----
-58

query I rowsort
SELECT DISTINCT - ( col0 * + col0 + + tab2.col0 ) AS col1 FROM tab2
----
-56
-6162
-6320

query I rowsort
SELECT ALL 65 * - 18 + col2 * - 50 AS col0 FROM tab1 AS cor0
----
-3870
-4020
-5970

query I rowsort
SELECT DISTINCT + - 31 + 14 FROM tab2 cor0
----
-17

query I rowsort
SELECT - col1 * + 9 AS col0 FROM tab2 cor0
----
-153
-279
-531

query I rowsort
SELECT ALL - ( + col2 ) * col1 * ( + col1 * col0 ) AS col0 FROM tab1 AS cor0
----
-109512
-1297920
-364800

query I rowsort
SELECT - cor0.col0 * col2 + + ( + cor0.col0 ) AS col0 FROM tab0 AS cor0
----
-7209
-768
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3553
SELECT ALL ( - col2 ) * + col1 + col1 * col0 DIV CAST( 44 AS SIGNED ) FROM tab0 AS cor0
----
-20
-2792
-7278

skipif mysql # not compatible
query I rowsort label-3553
SELECT ALL ( - col2 ) * + col1 + col1 * col0 / CAST ( 44 AS INTEGER ) FROM tab0 AS cor0
----
-20
-2792
-7278

query I rowsort
SELECT - col0 + + col2 * - 46 AS col1 FROM tab2 AS cor0
----
-1249
-1274
-1827

query I rowsort
SELECT ALL cor0.col2 + - col0 * + ( col0 ) AS col0 FROM tab2 cor0
----
-22
-6058
-6203

query I rowsort
SELECT DISTINCT + ( - col0 ) + - 5 * - col0 * col1 + - col2 FROM tab1 AS cor0
----
3079
333
5024

query I rowsort
SELECT - 91 + col0 FROM tab0 AS cor0
----
-2
-56
-67

query I rowsort
SELECT + tab0.col2 + col1 AS col2 FROM tab0
----
119
173
98

query I rowsort
SELECT DISTINCT - ( 49 ) FROM tab1
----
-49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 45 * + col2 col1 FROM tab2 AS cor0
----
1170
1215
1710

query I rowsort
SELECT - - col0 + 64 + col0 AS col1 FROM tab2 AS cor0
----
220
222
78

query I rowsort
SELECT ALL cor0.col2 + 6 * + col2 AS col0 FROM tab1 AS cor0
----
378
399
672

query I rowsort
SELECT + col2 + - ( - ( + cor0.col1 ) ) * - col0 * - col2 + + col2 AS col1 FROM tab1 AS cor0
----
100032
36594
4320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3564
SELECT ALL + + col1 / - CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3564
SELECT ALL + + col1 / - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * - ( col0 ) + col2 + col0 * + cor0.col1 FROM tab2 cor0
----
433
4383
6656

query I rowsort
SELECT DISTINCT - + col1 * col1 AS col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL + + col0 * ( 63 ) FROM tab2 AS cor0
----
441
4914
4977

query I rowsort
SELECT DISTINCT - 15 + col0 FROM tab2
----
-8
63
64

query I rowsort
SELECT + col1 + tab2.col0 - - 49 FROM tab2
----
145
186
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-3570
SELECT 47 DIV col1 AS col2 FROM tab2
----
0
1
2

skipif mysql # not compatible
query I rowsort label-3570
SELECT 47 / col1 AS col2 FROM tab2
----
0
1
2

query I rowsort
SELECT + col1 * + 56 + col0 AS col2 FROM tab1 AS cor0
----
1459
624
808

query I rowsort
SELECT col0 + + ( col1 ) + + col0 * 14 * - col1 AS col1 FROM tab1 AS cor0
----
-1063
-14467
-8886

query I rowsort
SELECT - col1 + - col1 + col1 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - - col1 * + 19 AS col1 FROM tab0 AS cor0
----
1634
1729
1843

onlyif mysql # use DIV operator for integer division
query I rowsort label-3575
SELECT ALL cor0.col2 * - cor0.col0 + - col2 DIV - col1 FROM tab1 AS cor0
----
-160
-3643
-7673

skipif mysql # not compatible
query I rowsort label-3575
SELECT ALL cor0.col2 * - cor0.col0 + - col2 / - col1 FROM tab1 AS cor0
----
-160
-3643
-7673

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3576
SELECT + col1 * CAST( NULL AS SIGNED ) + col2 * - col0 / col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3576
SELECT + col1 * CAST ( NULL AS INTEGER ) + col2 * - col0 / col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col2 * ( col2 ) col2 FROM tab2
----
1461
735
760

onlyif mysql # use DIV operator for integer division
query I rowsort label-3578
SELECT DISTINCT tab2.col2 DIV - col1 AS col1 FROM tab2
----
-2
0

skipif mysql # not compatible
query I rowsort label-3578
SELECT DISTINCT tab2.col2 / - col1 AS col1 FROM tab2
----
-2
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3579
SELECT - - CAST( NULL AS SIGNED ) + + col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3579
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-3580
SELECT ALL + CAST( NULL AS SIGNED ) - 9 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3580
SELECT ALL + CAST ( NULL AS INTEGER ) - 9 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + col1 + - col2 * + col1 AS col0 FROM tab2 AS cor0
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col2 + tab0.col1 col0 FROM tab0
----
194
2924
7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3583
SELECT - CAST( NULL AS SIGNED ) + col0 * cor0.col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3583
SELECT - CAST ( NULL AS INTEGER ) + col0 * cor0.col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 82 + + ( col1 * - cor0.col0 ) AS col1 FROM tab1 AS cor0
----
-558
-958
4

query I rowsort
SELECT - col0 + + col1 * col2 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT - - ( col0 ) * - col1 * + 35 AS col0 FROM tab1 AS cor0
----
-22400
-2730
-36400

onlyif mysql # use DIV operator for integer division
query I rowsort label-3587
SELECT col2 DIV ( - col0 ) AS col1 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3587
SELECT col2 / ( - col0 ) AS col1 FROM tab0 cor0
----
-1
0
0

query I rowsort
SELECT + col1 * - 48 FROM tab0
----
-4128
-4368
-4656

query I rowsort
SELECT 72 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT cor0.col0 + tab1.col2 AS col2 FROM tab2, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to 8bd72de8d7a75bcbd2619bca60945947

query I rowsort
SELECT ALL ( - col2 + col2 ) * col1 FROM tab2
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3592
SELECT - - CAST( col0 AS SIGNED ) * + col1 + + 38 * col0 * - cor0.col2 FROM tab1 cor0
----
-137984
-290800
-6078

skipif mysql # not compatible
query I rowsort label-3592
SELECT - - CAST ( col0 AS INTEGER ) * + col1 + + 38 * col0 * - cor0.col2 FROM tab1 cor0
----
-137984
-290800
-6078

query I rowsort
SELECT - col1 * + 85 FROM tab1 AS cor0
----
-1105
-2210
-850

query I rowsort
SELECT 82 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
108
109
120

query I rowsort
SELECT - ( - col0 ) * - col0 + - ( col0 ) AS col0 FROM tab1 cor0
----
-12
-4160
-6480

query I rowsort
SELECT DISTINCT tab1.col1 * tab1.col1 AS col2 FROM tab1
----
100
169
676

query I rowsort
SELECT 18 * col2 AS col1 FROM tab2
----
468
486
684

query I rowsort
SELECT DISTINCT 90 + - col1 FROM tab1
----
64
77
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3599
SELECT DISTINCT - CAST( NULL AS SIGNED ) FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-3599
SELECT DISTINCT - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
NULL

query I rowsort
SELECT DISTINCT - - ( col2 ) + 98 AS col1 FROM tab1 AS cor0
----
152
155
194

query I rowsort
SELECT DISTINCT 46 * - col0 FROM tab0 AS cor0
----
-1104
-1610
-4094

query I rowsort
SELECT ALL + col1 + 23 AS col0 FROM tab1 AS cor0
----
33
36
49

query I rowsort
SELECT - cor0.col1 * + col2 - + col0 AS col0 FROM tab0 cor0
----
-132
-2862
-7551

query I rowsort
SELECT DISTINCT col2 + + 78 + col1 * col1 FROM tab2 AS cor0
----
1066
3585
405

query I rowsort
SELECT DISTINCT col0 * ( col1 + - col1 ) FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3606
SELECT DISTINCT + col0 DIV 4 AS col1 FROM tab2
----
1
19

skipif mysql # not compatible
query I rowsort label-3606
SELECT DISTINCT + col0 / 4 AS col1 FROM tab2
----
1
19

query I rowsort
SELECT + col2 * 23 FROM tab1
----
1242
1311
2208

onlyif mysql # use DIV operator for integer division
query I rowsort label-3608
SELECT + col2 + - ( + col1 ) - col1 DIV - ( col2 ) FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-3608
SELECT + col2 + - ( + col1 ) - col1 / - ( col2 ) FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + + col1 * col0 + 46 FROM tab0 cor0
----
2110
3441
8145

query I rowsort
SELECT col2 * col2 - col0 AS col2 FROM tab1 AS cor0
----
2913
3185
9136

onlyif mysql # use DIV operator for integer division
query I rowsort label-3611
SELECT cor0.col2 + col2 DIV + 75 AS col1 FROM tab1 AS cor0
----
54
57
97

skipif mysql # not compatible
query I rowsort label-3611
SELECT cor0.col2 + col2 / + 75 AS col1 FROM tab1 AS cor0
----
54
57
97

query I rowsort
SELECT - + col0 * + col1 + + 5 FROM tab0 AS cor0
----
-2059
-3390
-8094

query I rowsort
SELECT DISTINCT + 38 + col0 AS col1 FROM tab2 AS cor0
----
116
117
45

query I rowsort
SELECT ALL col0 - col1 AS col1 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ALL - 45 - col0 FROM tab2 AS cor0
----
-123
-124
-52

query I rowsort
SELECT DISTINCT + - col2 + col0 * 84 FROM tab2 AS cor0
----
561
6526
6598

onlyif mysql # use DIV operator for integer division
query I rowsort label-3617
SELECT + + 95 - col0 * 84 DIV 57 AS col2 FROM tab1 AS cor0
----
-22
1
91

skipif mysql # not compatible
query I rowsort label-3617
SELECT + + 95 - col0 * 84 / 57 AS col2 FROM tab1 AS cor0
----
-22
1
91

query I rowsort
SELECT ALL col0 * + col1 + ( - col2 ) + col1 FROM tab2 cor0
----
1322
221
4635

query I rowsort
SELECT ALL - - col1 + col0 * 29 AS col2 FROM tab1 AS cor0
----
113
1866
2333

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3620
SELECT DISTINCT - col2 + col0 + - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3620
SELECT DISTINCT - col2 + col0 + - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ( col1 ) + col0 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - col2 * ( col0 ) * col1 + + ( + 0 + col0 ) FROM tab0 AS cor0
----
-3360
-664029
-68088

query I rowsort
SELECT + col0 + + 59 * - col1 FROM tab2 AS cor0
----
-1822
-3403
-924

onlyif mysql # use DIV operator for integer division
query I rowsort label-3624
SELECT ALL - + col2 DIV col1 + + col1 * col1 FROM tab2 AS cor0
----
287
3481
961

skipif mysql # not compatible
query I rowsort label-3624
SELECT ALL - + col2 / col1 + + col1 * col1 FROM tab2 AS cor0
----
287
3481
961

query I rowsort
SELECT DISTINCT 0 * col0 + - col2 AS col0 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT - col1 - - col2 * - 59 FROM tab2
----
-1593
-1624
-2259

query I rowsort
SELECT DISTINCT 53 * + 85 FROM tab1 AS cor0
----
4505

query I rowsort
SELECT + col1 * col2 * - col1 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT tab1.col0 * + 70 + col0 - - col2 FROM tab1
----
267
4601
5776

query I rowsort
SELECT + - 76 + - col0 FROM tab2 AS cor0
----
-154
-155
-83

query I rowsort
SELECT DISTINCT + col2 * tab2.col0 - col2 FROM tab2
----
162
2002
2964

query I rowsort
SELECT ( - ( - col1 ) ) AS col1 FROM tab2
----
17
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3633
SELECT col1 + col2 * - col1 + + CAST( NULL AS SIGNED ) col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3633
SELECT col1 + col2 * - col1 + + CAST ( NULL AS INTEGER ) col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3634
SELECT DISTINCT - col2 * ( + col2 ) * ( tab0.col0 ) - col1 DIV 77 FROM tab0
----
-26137
-36
-598437

skipif mysql # not compatible
query I rowsort label-3634
SELECT DISTINCT - col2 * ( + col2 ) * ( tab0.col0 ) - col1 / 77 FROM tab0
----
-26137
-36
-598437

query I rowsort
SELECT DISTINCT + 27 * col1 - col2 * ( - col0 ) FROM tab0
----
2654
3114
9755

query I rowsort
SELECT DISTINCT - tab0.col2 * + col0 - - col0 AS col2 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT - col0 + + 88 * tab1.col2 FROM tab1
----
4749
4952
8368

query I rowsort
SELECT ALL + - col0 * col1 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ( col2 ) * cor0.col1 * - col0 - col0 FROM tab1 AS cor0
----
-36544
-4215
-99920

query I rowsort
SELECT + col0 * + cor0.col2 * ( 86 ) FROM tab0 AS cor0
----
3010
627628
68112

query I rowsort
SELECT DISTINCT 10 + + col1 FROM tab2 AS cor0
----
27
41
69

query I rowsort
SELECT + 42 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

query I rowsort
SELECT ALL + tab0.col1 + + tab0.col0 * - col1 + col2 AS col0 FROM tab0
----
-1945
-3297
-7926

query I rowsort
SELECT DISTINCT - - col0 + + cor0.col0 * 50 FROM tab1 AS cor0
----
153
3264
4080

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3645
SELECT ALL + 69 * col0 + + CAST( NULL AS SIGNED ) + + ( + col1 * 50 ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3645
SELECT ALL + 69 * col0 + + CAST ( NULL AS INTEGER ) + + ( + col1 * 50 ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - cor0.col2 * col1 * col0 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT - col2 * ( 55 ) + tab0.col0 AS col2 FROM tab0
----
-1791
-20
-4421

query I rowsort
SELECT col0 + ( col1 ) * - col1 FROM tab0
----
-7372
-8192
-9374

query I rowsort
SELECT + 61 * 39 FROM tab0, tab0 AS cor0
----
9 values hashing to 564694fbb8dacc1a26224c771d5c08b2

query I rowsort
SELECT DISTINCT + 13 * - col1 FROM tab1 AS cor0
----
-130
-169
-338

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( 94 ) * col0 col2 FROM tab0 AS cor0
----
2256
3290
8366

query I rowsort
SELECT DISTINCT - col0 * + col1 + col1 AS col2 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT 99 + 8 FROM tab0 AS cor0
----
107

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3654
SELECT + CAST( ( + col2 ) AS SIGNED ) FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3654
SELECT + CAST ( ( + col2 ) AS INTEGER ) FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - 23 AS col0 FROM tab0 AS cor0
----
-23

query I rowsort
SELECT DISTINCT + - cor0.col0 + col0 AS col0 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3657
SELECT ALL + col1 DIV - cor0.col0 + + col0 AS col1 FROM tab1 cor0
----
-5
64
80

skipif mysql # not compatible
query I rowsort label-3657
SELECT ALL + col1 / - cor0.col0 + + col0 AS col1 FROM tab1 cor0
----
-5
64
80

query I rowsort
SELECT ALL - + col1 + - col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT 33 * - 89 + col1 FROM tab2 AS cor0
----
-2878
-2906
-2920

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3660
SELECT DISTINCT + CAST( + col1 AS SIGNED ) FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3660
SELECT DISTINCT + CAST ( + col1 AS INTEGER ) FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + 31 + cor0.col0 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 24fa8f685160021bf96af2f39a41800b

query I rowsort
SELECT ALL + col1 * + 70 - + col1 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
13832
6887
8858

query I rowsort
SELECT ALL col1 + - 63 AS col1 FROM tab0 AS cor0
----
23
28
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-3664
SELECT ALL col2 DIV + col0 AS col2 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3664
SELECT ALL col2 / + col0 AS col2 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT + - ( col1 ) + col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col0 * cor0.col0 * col0 AS col0 FROM tab0 AS cor0
----
13824
42875
704969

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-3668
SELECT + 55 + + col1 * col0 DIV - col1 AS col2 FROM tab0 AS cor0
----
-34
20
31

skipif mysql # not compatible
query I rowsort label-3668
SELECT + 55 + + col1 * col0 / - col1 AS col2 FROM tab0 AS cor0
----
-34
20
31

query I rowsort
SELECT + ( - 88 ) FROM tab2, tab0 AS cor0
----
9 values hashing to 467301f887614eb7beda22c561b0fad2

query I rowsort
SELECT + col0 + - 32 FROM tab0 cor0
----
-8
3
57

query I rowsort
SELECT - 68 * + col2 FROM tab0 AS cor0
----
-2244
-5576
-68

query I rowsort
SELECT ALL col1 * col2 * - col1 + - col0 FROM tab2
----
-11061
-25954
-90584

query I rowsort
SELECT ALL - col2 + col1 AS col1 FROM tab0
----
53
9
96

query I rowsort
SELECT - 30 * tab1.col0 FROM tab1
----
-1920
-2400
-90

query I rowsort
SELECT DISTINCT - col0 + cor0.col2 * col1 * + col1 AS col0 FROM tab0 AS cor0
----
244044
678953
9374

query I rowsort
SELECT ALL ( - col2 ) * - 82 - + cor0.col1 FROM tab2 AS cor0
----
2073
2183
3099

query I rowsort
SELECT + col0 * - cor0.col1 + + 92 AS col2 FROM tab1 cor0
----
-548
-948
14

query I rowsort
SELECT + cor0.col0 - col0 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + col0 * ( - col0 ) col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT cor0.col1 * col2 + col1 * + cor0.col0 + cor0.col0 FROM tab0 AS cor0
----
15650
3527
4926

query I rowsort
SELECT - col2 + cor0.col0 * 58 FROM tab1 AS cor0
----
120
3655
4544

onlyif mysql # use DIV operator for integer division
query I rowsort label-3682
SELECT + col0 DIV - col0 + col1 col1 FROM tab1 AS cor0
----
12
25
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3682
SELECT + col0 / - col0 + col1 col1 FROM tab1 AS cor0
----
12
25
9

query I rowsort
SELECT DISTINCT - cor0.col1 + - col2 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL - cor0.col2 + + ( ( col1 ) ) AS col0 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT + col0 + - ( col1 ) * - cor0.col1 AS col2 FROM tab1 AS cor0
----
164
249
679

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3687
SELECT - - col1 + - CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3687
SELECT - - col1 + - CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 * - 50 + col1 FROM tab2 AS cor0
----
-1241
-1319
-1883

query I rowsort
SELECT + col2 * 31 + col1 AS col2 FROM tab1 AS cor0
----
1700
1777
2989

query I rowsort
SELECT ALL + + col0 * 40 + 52 * col2 FROM tab1 AS cor0
----
2928
5524
8192

query I rowsort
SELECT DISTINCT col2 + - col0 + ( col1 ) * col2 AS col2 FROM tab0
----
2847
63
7455

onlyif mysql # use DIV operator for integer division
query I rowsort label-3692
SELECT - col2 * col0 DIV 95 FROM tab2
----
-1
-21
-31

skipif mysql # not compatible
query I rowsort label-3692
SELECT - col2 * col0 / 95 FROM tab2
----
-1
-21
-31

query I rowsort
SELECT + col0 * + ( - col2 ) + col2 * col2 FROM tab2 AS cor0
----
-1352
-1558
540

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3694
SELECT + col0 + ( + col2 + col2 * CAST( + 94 AS SIGNED ) ) FROM tab1 AS cor0
----
5133
5479
9200

skipif mysql # not compatible
query I rowsort label-3694
SELECT + col0 + ( + col2 + col2 * CAST ( + 94 AS INTEGER ) ) FROM tab1 AS cor0
----
5133
5479
9200

onlyif mysql # use DIV operator for integer division
query I rowsort label-3695
SELECT - col0 DIV + cor0.col1 - + col0 FROM tab1 AS cor0
----
-3
-70
-86

skipif mysql # not compatible
query I rowsort label-3695
SELECT - col0 / + cor0.col1 - + col0 FROM tab1 AS cor0
----
-3
-70
-86

query I rowsort
SELECT ALL - 23 AS col0 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to 9bd721f99d79dce21b1de2860fd51ed5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3697
SELECT col0 DIV 35 AS col1 FROM tab1
----
0
1
2

skipif mysql # not compatible
query I rowsort label-3697
SELECT col0 / 35 AS col1 FROM tab1
----
0
1
2

query I rowsort
SELECT + col1 + col0 - tab1.col0 AS col0 FROM tab1
----
10
13
26

query I rowsort
SELECT col2 - - cor0.col0 * + cor0.col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT cor0.col0 - col1 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT + col1 * - ( col2 ) - - col2 * - col0 FROM tab1 cor0
----
-1566
-4218
-8928

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3702
SELECT - - CAST( NULL AS DECIMAL ) + + 66 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3702
SELECT - - CAST ( NULL AS REAL ) + + 66 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + ( + col1 ) + + col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT 8 * col1 * col2 AS col2 FROM tab1 cor0
----
11232
4560
9984

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3705
SELECT DISTINCT + - CAST( NULL AS SIGNED ) + ( - col2 ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3705
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) + ( - col2 ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT col2 + + 85 AS col0 FROM tab0 AS cor0
----
118
167
86

query I rowsort
SELECT - col0 * + col1 + + col1 FROM tab2 cor0
----
-1326
-186
-4543

query I rowsort
SELECT ALL - 10 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

query I rowsort
SELECT col0 * - col1 + + ( + tab1.col1 ) * tab1.col1 + 32 FROM tab1
----
-508
-839
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-3710
SELECT + + 88 DIV - col2 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-3710
SELECT + + 88 / - col2 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT DISTINCT - 19 * - 25 AS col2 FROM tab0
----
475

query I rowsort
SELECT DISTINCT - 85 * col0 AS col2 FROM tab0
----
-2040
-2975
-7565

onlyif mysql # use DIV operator for integer division
query I rowsort label-3713
SELECT + + cor0.col1 DIV col0 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-3713
SELECT + + cor0.col1 / col0 FROM tab1 AS cor0
----
0
0
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-3714
SELECT ALL - 5 DIV - 21 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3714
SELECT ALL - 5 / - 21 FROM tab0
----
0
0
0

query I rowsort
SELECT + - col0 - + ( + 1 ) FROM tab2 AS cor0
----
-79
-8
-80

query I rowsort
SELECT + 77 * - col2 AS col2 FROM tab0 AS cor0
----
-2541
-6314
-77

query I rowsort
SELECT + col1 * + col0 + + col0 - + tab1.col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT + col2 + col2 * col2 + col1 * - col2 FROM tab2
----
-81
-832
836

query I rowsort
SELECT ALL - col0 - tab0.col0 FROM tab0
----
-178
-48
-70

query I rowsort
SELECT - tab2.col2 + - col0 - - col1 * + col2 AS col0 FROM tab2
----
1430
529
803

query I rowsort
SELECT cor0.col0 AS col1 FROM tab1, tab0, tab2 cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT DISTINCT col1 * + col1 * col1 AS col0 FROM tab0
----
636056
753571
912673

query I rowsort
SELECT + col0 * - col1 * + col2 AS col1 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-3724
SELECT DISTINCT col0 - - col2 * col0 DIV - col1 AS col0 FROM tab2
----
-97
1
44

skipif mysql # not compatible
query I rowsort label-3724
SELECT DISTINCT col0 - - col2 * col0 / - col1 AS col0 FROM tab2
----
-97
1
44

query I rowsort
SELECT DISTINCT + col1 - col1 AS col0 FROM tab0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3726
SELECT + col2 * + col1 + + col1 DIV col0 + + col0 * tab2.col1 FROM tab2
----
1058
1989
6136

skipif mysql # not compatible
query I rowsort label-3726
SELECT + col2 * + col1 + + col1 / col0 + + col0 * tab2.col1 FROM tab2
----
1058
1989
6136

query I rowsort
SELECT col1 * col1 + + col0 AS col2 FROM tab1
----
164
249
679

onlyif mysql # use DIV operator for integer division
query I rowsort label-3728
SELECT - + col2 DIV + col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3728
SELECT - + col2 / + col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT + col2 + + tab2.col2 + col0 * - col2 FROM tab2
----
-135
-1976
-2926

query I rowsort
SELECT + + col0 + col0 + - col1 AS col0 FROM tab1 AS cor0
----
-20
118
147

onlyif mysql # use DIV operator for integer division
query I rowsort label-3731
SELECT DISTINCT - - col2 + col2 * + col2 + - col2 DIV col1 FROM tab0 AS cor0
----
1122
2
6806

skipif mysql # not compatible
query I rowsort label-3731
SELECT DISTINCT - - col2 + col2 * + col2 + - col2 / col1 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT ALL - col0 * - col1 + + col1 AS col2 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT + + col2 + - col1 * - cor0.col2 - col1 AS col0 FROM tab0 AS cor0
----
1
2785
7453

query I rowsort
SELECT DISTINCT + col2 * col0 * col1 + col1 FROM tab1
----
36490
4238
99853

query I rowsort
SELECT tab2.col0 + - col2 + col1 * tab2.col0 FROM tab2
----
1384
197
4654

query I rowsort
SELECT - tab2.col0 * tab2.col2 AS col2 FROM tab2
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-3737
SELECT DISTINCT - col1 DIV - cor0.col2 + - col0 FROM tab0 AS cor0
----
-22
-88
62

skipif mysql # not compatible
query I rowsort label-3737
SELECT DISTINCT - col1 / - cor0.col2 + - col0 FROM tab0 AS cor0
----
-22
-88
62

query I rowsort
SELECT - col2 * - col0 * col0 + + col0 FROM tab2 AS cor0
----
1330
158262
237237

onlyif mysql # use DIV operator for integer division
query I rowsort label-3739
SELECT + cor0.col1 DIV col2 + + cor0.col1 * cor0.col0 AS col0 FROM tab0 AS cor0
----
2066
3492
8100

skipif mysql # not compatible
query I rowsort label-3739
SELECT + cor0.col1 / col2 + + cor0.col1 * cor0.col0 AS col0 FROM tab0 AS cor0
----
2066
3492
8100

query I rowsort
SELECT col2 * - col2 + - col1 - col2 FROM tab1 AS cor0
----
-2996
-3316
-9325

query I rowsort
SELECT ALL - col0 * + col1 AS col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT col2 * cor0.col1 + cor0.col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL cor0.col1 * col0 + - cor0.col1 + col2 * + col2 AS col1 FROM tab2 AS cor0
----
2770
5219
915

query I rowsort
SELECT + + cor0.col2 * col0 + - col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT - tab2.col1 + tab2.col1 FROM tab2
----
0
0
0

query I rowsort
SELECT + 38 * tab2.col2 - col0 FROM tab2
----
1019
1365
910

query I rowsort
SELECT ALL 93 * col0 + - col2 + cor0.col2 FROM tab1 AS cor0
----
279
5952
7440

query I rowsort
SELECT + - 23 * col0 AS col1 FROM tab2 AS cor0
----
-161
-1794
-1817

query I rowsort
SELECT - 54 * col0 FROM tab1 AS cor0
----
-162
-3456
-4320

query I rowsort
SELECT ALL + + col0 + + col2 * + col0 + - col1 AS col1 FROM tab0 AS cor0
----
-27
7296
730

query I rowsort
SELECT ALL - cor0.col0 + col1 AS col2 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL - col0 * col0 + cor0.col2 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT DISTINCT + col2 * col0 + - col2 AS col2 FROM tab2 AS cor0
----
162
2002
2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-3754
SELECT DISTINCT + - col0 + col0 DIV col2 AS col1 FROM tab1 cor0
----
-3
-63
-80

skipif mysql # not compatible
query I rowsort label-3754
SELECT DISTINCT + - col0 + col0 / col2 AS col1 FROM tab1 cor0
----
-3
-63
-80

query I rowsort
SELECT ALL - col2 * col0 AS col0 FROM tab0 WHERE NOT ( col1 * + col2 ) NOT BETWEEN - col2 AND NULL
----

query I rowsort
SELECT ALL col2 FROM tab1 WHERE NOT col1 >= col1 * + col0 * - col2
----

query I rowsort
SELECT + col1 + col1 * tab0.col2 AS col2 FROM tab0
----
194
2924
7553

query I rowsort
SELECT ALL col0 * col1 + tab1.col1 * - tab1.col0 * col0 AS col1 FROM tab1
----
-156
-40320
-82160

query I rowsort
SELECT - col0 - col0 * col1 FROM tab0
----
-2088
-3430
-8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-3760
SELECT ALL - col2 * col0 + - col0 DIV tab0.col2 AS col0 FROM tab0
----
-70
-7299
-792

skipif mysql # not compatible
query I rowsort label-3760
SELECT ALL - col2 * col0 + - col0 / tab0.col2 AS col0 FROM tab0
----
-70
-7299
-792

query I rowsort
SELECT ALL + col2 + - tab0.col0 * + col1 AS col0 FROM tab0 WHERE NOT NULL BETWEEN col2 AND NULL
----

query I rowsort
SELECT DISTINCT col2 + col2 * - col2 AS col1 FROM tab1
----
-2862
-3192
-9120

query I rowsort
SELECT DISTINCT col2 * tab2.col2 + - col0 * col1 * col0 FROM tab2
----
-104653
-358280
-790

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT - col1 < - col0
----
64
10
57
80
13
96

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT BETWEEN col1 AND NULL
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT ALL + col2 * + col0 + + tab0.col0 AS col1 FROM tab0
----
70
7387
816

query I rowsort
SELECT ALL col0 + + col1 * col1 AS col2 FROM tab1
----
164
249
679

query I rowsort
SELECT - col2 * - col0 AS col1 FROM tab2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-3770
SELECT ALL - 10 * + col1 + - ( - 91 ) DIV col0 + col0 FROM tab0 AS cor0
----
-820
-833
-933

skipif mysql # not compatible
query I rowsort label-3770
SELECT ALL - 10 * + col1 + - ( - 91 ) / col0 + col0 FROM tab0 AS cor0
----
-820
-833
-933

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0, tab0 cor1, tab0 AS cor2
----
972 values hashing to 09b120a8ff13ebafea7af10c2152241b

query I rowsort
SELECT ALL col0 * col0 + col0 AS col2 FROM tab1
----
12
4160
6480

query I rowsort
SELECT + col2 * - tab0.col0 AS col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + col2 + + col1 FROM tab1 WHERE NOT + col0 NOT IN ( col0 * col1 / + col1 )
----
109
67
80

query I rowsort
SELECT ALL - tab1.col0 * tab1.col0 FROM tab1 WHERE NULL BETWEEN - col1 * col0 AND ( col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 col2 FROM tab2 WHERE col0 NOT IN ( - tab2.col1 )
----
26
27
38

query I rowsort
SELECT - col1 + - col1 AS col1 FROM tab2 WHERE NOT NULL NOT BETWEEN NULL AND ( NULL )
----

query I rowsort
SELECT - col2 + tab2.col1 * tab2.col0 FROM tab2
----
1305
190
4576

query I rowsort
SELECT ALL + col1 - tab1.col1 FROM tab1
----
0
0
0

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL NOT IN ( tab1.col2 )
----

query I rowsort
SELECT col0 - col2 AS col2 FROM tab2
----
-20
41
52

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NULL <> NULL
----

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT NULL NOT BETWEEN NULL AND - col1 + + cor0.col2
----

query III rowsort
SELECT ALL * FROM tab1 cor0 WHERE col0 * col0 + - col1 < NULL
----

query I rowsort
SELECT ALL - col1 + - col0 * col1 AS col2 FROM tab1
----
-104
-1053
-650

onlyif mysql # use DIV operator for integer division
query I rowsort label-3786
SELECT DISTINCT - col1 + - col1 DIV col2 + + col2 * col2 AS col2 FROM tab0
----
-193
1001
6632

skipif mysql # not compatible
query I rowsort label-3786
SELECT DISTINCT - col1 + - col1 / col2 + + col2 * col2 AS col2 FROM tab0
----
-193
1001
6632

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE + col0 = ( NULL )
----

query I rowsort
SELECT col2 + col2 * tab2.col0 FROM tab2
----
2054
216
3040

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL NOT IN ( - col0 + col0 * col1 )
----

query I rowsort
SELECT - col1 * col2 + + col0 + + col2 AS col1 FROM tab0
----
-2781
-61
-7291

query I rowsort
SELECT DISTINCT col0 * col0 + col0 * + col1 FROM tab2
----
10686
266
7584

query I rowsort
SELECT col0 - + col1 AS col2 FROM tab1
----
-23
54
67

query III rowsort
SELECT * FROM tab1 WHERE NULL IN ( col2 * + col1 + + col0 )
----

query I rowsort
SELECT DISTINCT col1 * - col0 * - col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT DISTINCT col0 + 60 * + col1 AS col2 FROM tab2
----
1099
1867
3618

query I rowsort
SELECT ALL ( tab2.col2 ) * + col2 FROM tab2
----
1444
676
729

query IIIIIIIII rowsort
SELECT * FROM tab0, tab1, tab0 AS cor0 WHERE ( NULL ) NOT IN ( + cor0.col1 )
----

query I rowsort
SELECT + col1 + col2 * - ( col1 ) FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL + 19 * - col1 AS col1 FROM tab1 AS cor0
----
-190
-247
-494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col2 col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT 76 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

query I rowsort
SELECT ALL 95 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

onlyif mysql # use DIV operator for integer division
query I rowsort label-3803
SELECT - 54 DIV col1 AS col2 FROM tab2 AS cor0
----
-1
-3
0

skipif mysql # not compatible
query I rowsort label-3803
SELECT - 54 / col1 AS col2 FROM tab2 AS cor0
----
-1
-3
0

query I rowsort
SELECT - col2 + 68 FROM tab2
----
30
41
42

query I rowsort
SELECT ALL tab0.col0 * + col1 AS col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT tab2.col0 * 15 + - col1 AS col0 FROM tab2
----
1111
1168
74

query I rowsort
SELECT - col0 + - ( - col0 ) + ( col1 ) FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL 71 * col0 AS col0 FROM tab2 AS cor0
----
497
5538
5609

query I rowsort
SELECT - - 68 - col2 FROM tab1 AS cor0
----
-28
11
14

query I rowsort
SELECT DISTINCT - cor0.col2 * - cor0.col0 + col0 AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT + + col0 + - 74 AS col2 FROM tab2 cor0
----
-67
4
5

query I rowsort
SELECT DISTINCT 32 * col1 AS col1 FROM tab2 AS cor0
----
1888
544
992

query I rowsort
SELECT ALL - - ( + col2 ) * cor0.col0 + + ( 85 ) AS col0 FROM tab0 AS cor0
----
120
7383
877

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3814
SELECT DISTINCT + CAST( NULL AS SIGNED ) * 40 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3814
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * 40 FROM tab1 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3815
SELECT - + ( col1 ) + cor0.col2 * + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3815
SELECT - + ( col1 ) + cor0.col2 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 * - col0 + col1 AS col2 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT 42 * cor0.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 24522a847b44e4ab85b1227024816378

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 90 + - col1 col0 FROM tab0 AS cor0
----
-1
-7
4

query I rowsort
SELECT DISTINCT - ( col1 + - col2 ) AS col1 FROM tab1
----
28
47
83

query I rowsort
SELECT + - col0 * - col2 * + ( 7 ) - - col2 * 70 AS col2 FROM tab1 AS cor0
----
29526
4914
60480

query I rowsort
SELECT + 45 - col1 AS col0 FROM tab0 cor0
----
-41
-46
-52

query I rowsort
SELECT + ( col1 ) AS col1 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT 33 + + col0 * 15 FROM tab1 AS cor0
----
1233
78
993

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3824
SELECT + 80 / cor0.col1 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3824
SELECT + 80 / cor0.col1 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 26 * + col2 AS col1 FROM tab1 AS cor0
----
-1404
-1482
-2496

query I rowsort
SELECT ALL - + ( + 17 ) AS col2 FROM tab2, tab0 AS cor0, tab0, tab2 cor1
----
81 values hashing to c2265365b5649c888846aefc3ede9a69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3827
SELECT DISTINCT + col2 * - 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-3827
SELECT DISTINCT + col2 * - CAST ( NULL AS INTEGER ) col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT col0 + ( 64 ) * col2 FROM tab2 AS cor0
----
1735
1742
2511

query I rowsort
SELECT DISTINCT col1 * + ( col0 ) - col1 AS col0 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT - cor0.col1 * + 3 + + col0 AS col1 FROM tab0 cor0
----
-184
-234
-256

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 col0 FROM tab2, tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + + col1 * 13 FROM tab2 AS cor0
----
221
403
767

onlyif mysql # use DIV operator for integer division
query I rowsort label-3834
SELECT ALL + col1 + - ( - col2 ) DIV + cor0.col0 AS col1 FROM tab0 cor0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-3834
SELECT ALL + col1 + - ( - col2 ) / + cor0.col0 AS col1 FROM tab0 cor0
----
87
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3835
SELECT DISTINCT col0 + - ( + 67 ) * col1 DIV - 81 FROM tab2 AS cor0
----
126
32
93

skipif mysql # not compatible
query I rowsort label-3835
SELECT DISTINCT col0 + - ( + 67 ) * col1 / - 81 FROM tab2 AS cor0
----
126
32
93

query I rowsort
SELECT ALL - - col0 * - 62 AS col2 FROM tab2 AS cor0
----
-434
-4836
-4898

query I rowsort
SELECT ALL col2 * - tab0.col0 * - 71 FROM tab0
----
2485
518158
56232

query I rowsort
SELECT ALL + col1 * + tab0.col1 AS col2 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL + col1 * 19 AS col0 FROM tab2
----
1121
323
589

query I rowsort
SELECT DISTINCT - col2 + col1 * col2 AS col0 FROM tab0 AS cor0
----
2805
7380
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3841
SELECT - - col2 + + CAST( cor0.col0 AS SIGNED ) * - cor0.col0 AS col1 FROM tab2 AS cor0
----
-22
-6058
-6203

skipif mysql # not compatible
query I rowsort label-3841
SELECT - - col2 + + CAST ( cor0.col0 AS INTEGER ) * - cor0.col0 AS col1 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT ALL - col2 * 38 FROM tab1 AS cor0
----
-2052
-2166
-3648

query I rowsort
SELECT col2 * + 18 AS col2 FROM tab2 cor0
----
468
486
684

query I rowsort
SELECT DISTINCT 84 FROM tab1, tab2 AS cor0
----
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-3845
SELECT ALL - 81 DIV col0 FROM tab1
----
-1
-1
-27

skipif mysql # not compatible
query I rowsort label-3845
SELECT ALL - 81 / col0 FROM tab1
----
-1
-1
-27

query I rowsort
SELECT DISTINCT - cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-24
-35
-89

query I rowsort
SELECT - 91 * col0 AS col2 FROM tab2 AS cor0
----
-637
-7098
-7189

onlyif mysql # use DIV operator for integer division
query I rowsort label-3848
SELECT col2 + col2 DIV col1 AS col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-3848
SELECT col2 + col2 / col1 AS col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - + col0 * col2 * + col0 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT ( - ( cor0.col1 ) ) + - ( 70 ) FROM tab2, tab1 cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 AS cor2
----
243 values hashing to dda969c8e7f6404a6c8237e95fe4540c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 + col1 col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL 44 * + col2 * cor0.col1 FROM tab1 AS cor0
----
25080
54912
61776

query I rowsort
SELECT ALL 8 * - col2 AS col0 FROM tab2 AS cor0
----
-208
-216
-304

query I rowsort
SELECT ALL 41 + col1 FROM tab1 AS cor0
----
51
54
67

query I rowsort
SELECT + 29 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT DISTINCT - cor1.col2 FROM tab1, tab0 AS cor0, tab0, tab1 AS cor1
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 23 col0 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

query I rowsort
SELECT DISTINCT ( - col2 ) + 72 FROM tab2 cor0
----
34
45
46

query I rowsort
SELECT ALL - - col1 * - cor0.col1 + + ( cor0.col0 * col1 ) + + ( - col1 * + col1 ) FROM tab0 AS cor0
----
-12728
-15423
-8463

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * - col0 col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - + 23 + col2 FROM tab1 AS cor0
----
31
34
73

query I rowsort
SELECT DISTINCT + 81 + col1 FROM tab1 AS cor0
----
107
91
94

query I rowsort
SELECT DISTINCT + cor0.col2 * 23 + 14 AS col1 FROM tab1 AS cor0
----
1256
1325
2222

query I rowsort
SELECT ALL + + col1 * 35 + + 11 FROM tab1 AS cor0
----
361
466
921

query I rowsort
SELECT ALL col0 * - 69 * 6 FROM tab0 AS cor0
----
-14490
-36846
-9936

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3866
SELECT col2 * CAST( NULL AS SIGNED ) + col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3866
SELECT col2 * CAST ( NULL AS INTEGER ) + col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor0.col2 + - col0 * + 65 * + col2 FROM tab1 AS cor0
----
-10476
-237063
-499104

query I rowsort
SELECT 4 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT cor0.col0 + ( col2 ) AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - col0 * + col0 + + col2 AS col2 FROM tab0
----
-1224
-543
-7839

query I rowsort
SELECT DISTINCT + cor1.col0 AS col2 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col0 * col1 col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT - - 54 * + ( + col2 ) - 72 AS col1 FROM tab0 AS cor0
----
-18
1710
4356

query I rowsort
SELECT ALL - 97 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to e4a6bd848a69226cbb7ad3d154be321b

query I rowsort
SELECT + ( - ( col2 ) ) * + col0 + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT - + col2 * - 15 FROM tab1 AS cor0
----
1440
810
855

query I rowsort
SELECT ALL - 53 * + col2 FROM tab0 AS cor0
----
-1749
-4346
-53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - 21 * + col2 col1 FROM tab0 AS cor0
----
-1631
-607
76

query I rowsort
SELECT ALL ( - col0 ) + col1 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + + col0 * - col0 * col1 AS col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT - ( - col2 ) - + col1 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT - col1 - - col1 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 + col1 * + col0 FROM tab1
----
1136
132
697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 81 col2 FROM tab1 AS cor0
----
-81
-81
-81

query I rowsort
SELECT ALL + + col2 * + col2 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT DISTINCT + 16 * col1 - col2 FROM tab1 cor0
----
103
112
362

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col2 col2 FROM tab0 cor0
----
-164
-2
-66

query I rowsort
SELECT DISTINCT - - 60 - col0 FROM tab0 AS cor0
----
-29
25
36

query I rowsort
SELECT ALL ( col1 ) + col0 * col1 AS col1 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT - 98 * col1 + + col2 AS col2 FROM tab1
----
-1178
-2494
-923

query I rowsort
SELECT DISTINCT + col1 + col2 * - col2 * 56 FROM tab2
----
-37797
-40793
-80847

query I rowsort
SELECT DISTINCT col2 + col1 + col1 FROM tab0
----
195
205
264

query I rowsort
SELECT DISTINCT + + col0 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL col2 * col1 * col1 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT col0 * + ( + col2 ) AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - cor0.col2 * - col2 * - cor0.col0 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT + col0 + ( col2 ) AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT col0 * ( + 1 ) + col1 AS col2 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT + ( col0 ) * + cor0.col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT 25 * - cor0.col0 FROM tab0, tab1 AS cor0
----
9 values hashing to e355f1314e550ddd0c7740ff16769d7e

query I rowsort
SELECT ALL col1 + col0 * - 89 AS col2 FROM tab2
----
-592
-6883
-7014

query I rowsort
SELECT DISTINCT + col1 * - col0 * + col0 FROM tab1 AS cor0
----
-234
-40960
-83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col2 + 50 * 92 col0 FROM tab1 AS cor0
----
12280
4762
8248

query I rowsort
SELECT - + col0 * 87 FROM tab0 AS cor0
----
-2088
-3045
-7743

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * cor0.col1 col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT col2 * - tab2.col0 AS col0 FROM tab2
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-3907
SELECT ALL - cor1.col1 DIV + cor0.col1 FROM tab1, tab2, tab0 AS cor0, tab0 AS cor1
----
81 values hashing to 5126313d4765c5364287d9d255e52040

skipif mysql # not compatible
query I rowsort label-3907
SELECT ALL - cor1.col1 / + cor0.col1 FROM tab1, tab2, tab0 AS cor0, tab0 AS cor1
----
81 values hashing to 5126313d4765c5364287d9d255e52040

query I rowsort
SELECT ALL - + cor0.col0 * cor0.col2 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * + 80 col0 FROM tab0 AS cor0
----
6880
7280
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-3910
SELECT + - col0 + col0 DIV + 82 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-3910
SELECT + - col0 + col0 / + 82 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL col1 + - col1 AS col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - + col0 * + 41 FROM tab1 AS cor0
----
-123
-2624
-3280

query I rowsort
SELECT col1 * ( - 57 * - col1 ) FROM tab0 AS cor0
----
421572
472017
536313

query I rowsort
SELECT DISTINCT + col2 * - 93 FROM tab0 AS cor0
----
-3069
-7626
-93

query I rowsort
SELECT - 69 AS col0 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 3bd7460efa48c66c072ad5f3c2def7e9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3916
SELECT DISTINCT - col2 DIV tab1.col2 col2 FROM tab1
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3916
SELECT DISTINCT - col2 / tab1.col2 col2 FROM tab1
----
-1

query I rowsort
SELECT ALL col1 * ( - col1 ) FROM tab2
----
-289
-3481
-961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3918
SELECT col2 * CAST( + col1 AS SIGNED ) FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-3918
SELECT col2 * CAST ( + col1 AS INTEGER ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - 97 * + col1 * col2 AS col2 FROM tab0
----
-275286
-723814
-9409

query I rowsort
SELECT - col0 + cor0.col1 + col0 AS col0 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT cor0.col0 * cor0.col1 AS col0 FROM tab2, tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col0 * 86 FROM tab2
----
-602
-6708
-6794

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT 10 + col0 AS col2 FROM tab2 AS cor0
----
17
88
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3925
SELECT - + col2 DIV col2 + + col0 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-3925
SELECT - + col2 / col2 + + col0 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT + 69 + - col1 * col1 AS col1 FROM tab2 AS cor0
----
-220
-3412
-892

query I rowsort
SELECT DISTINCT + ( col0 ) FROM tab0 cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3928
SELECT + col0 DIV + col1 + - col0 * - cor0.col2 * + col1 FROM tab2 AS cor0
----
119653
51038
5859

skipif mysql # not compatible
query I rowsort label-3928
SELECT + col0 / + col1 + - col0 * - cor0.col2 * + col1 FROM tab2 AS cor0
----
119653
51038
5859

query I rowsort
SELECT + col0 * col2 + col0 AS col2 FROM tab2 AS cor0
----
196
2106
3081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col1 col1 FROM tab0 AS cor0
----
172
182
194

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3931
SELECT - CAST( NULL AS SIGNED ) col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3931
SELECT - CAST ( NULL AS INTEGER ) col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 * ( cor0.col0 ) AS col1 FROM tab2 cor0
----
-189
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3933
SELECT DISTINCT CAST( NULL AS SIGNED ) + 26 col1 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3933
SELECT DISTINCT CAST ( NULL AS INTEGER ) + 26 col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT tab0.col2 AS col2 FROM tab0, tab1, tab1 cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

onlyif mysql # use DIV operator for integer division
query I rowsort label-3935
SELECT ALL 89 * col2 DIV col1 FROM tab1 AS cor0
----
184
507
657

skipif mysql # not compatible
query I rowsort label-3935
SELECT ALL 89 * col2 / col1 FROM tab1 AS cor0
----
184
507
657

query I rowsort
SELECT DISTINCT + - 30 * + ( col2 ) + col2 FROM tab1 AS cor0
----
-1566
-1653
-2784

query I rowsort
SELECT + - 82 AS col0 FROM tab1 cor0
----
-82
-82
-82

query I rowsort
SELECT ALL - + 16 + - ( - cor0.col0 ) * - 35 * - col0 AS col0 FROM tab0 cor0
----
20144
277219
42859

query I rowsort
SELECT ALL + col0 * + col2 + - col1 * + col0 AS col0 FROM tab1 AS cor0
----
3008
6640
84

query I rowsort
SELECT DISTINCT - col2 * - col1 + - 20 FROM tab2 AS cor0
----
1514
626
817

query I rowsort
SELECT DISTINCT - col1 * - cor0.col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - col2 + col2 * col0 AS col0 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT - col1 * 57 + + tab2.col2 FROM tab2
----
-1740
-3337
-931

query I rowsort
SELECT DISTINCT - col1 + col1 * 90 FROM tab0 AS cor0
----
7654
8099
8633

query I rowsort
SELECT ALL + + cor0.col1 * col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - 42 * + col2 AS col1 FROM tab2 AS cor0
----
-1092
-1134
-1596

query I rowsort
SELECT ALL - 88 * - col1 + col1 AS col0 FROM tab1 AS cor0
----
1157
2314
890

query I rowsort
SELECT - cor0.col1 + col2 * - col0 AS col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT ALL ( col2 * col2 ) FROM tab1
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-3950
SELECT col1 + - col0 DIV col0 AS col2 FROM tab2 AS cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-3950
SELECT col1 + - col0 / col0 AS col2 FROM tab2 AS cor0
----
16
30
58

query I rowsort
SELECT - - col2 + 54 * - col2 * + col2 + col0 AS col1 FROM tab2 AS cor0
----
-36400
-39332
-77859

query I rowsort
SELECT DISTINCT - + col2 * - col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT + col2 + - 8 * + col0 AS col0 FROM tab0 AS cor0
----
-159
-279
-630

query I rowsort
SELECT DISTINCT - col0 * - 78 FROM tab1 AS cor0
----
234
4992
6240

query I rowsort
SELECT ALL cor0.col1 - + cor0.col0 * col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL - cor0.col1 + 7 FROM tab2 AS cor0
----
-10
-24
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-3957
SELECT ALL - cor0.col2 + col0 DIV col1 + col2 AS col0 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-3957
SELECT ALL - cor0.col2 + col0 / col1 + col2 AS col0 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT + - col0 + ( 43 ) * col1 FROM tab2 cor0
----
1326
2459
652

query I rowsort
SELECT ALL - + col1 + - 63 AS col1 FROM tab2 AS cor0
----
-122
-80
-94

onlyif mysql # use DIV operator for integer division
query I rowsort label-3960
SELECT DISTINCT + - col2 - + ( + col0 ) DIV - col1 FROM tab0 cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-3960
SELECT DISTINCT + - col2 - + ( + col0 ) / - col1 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT ALL tab0.col1 * - col0 AS col2 FROM tab0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3962
SELECT - tab0.col1 DIV CAST( 46 * - col1 AS SIGNED ) + col0 * + col0 + col1 AS col2 FROM tab0
----
1322
662
8012

skipif mysql # not compatible
query I rowsort label-3962
SELECT - tab0.col1 / CAST ( 46 * - col1 AS INTEGER ) + col0 * + col0 + col1 AS col2 FROM tab0
----
1322
662
8012

query I rowsort
SELECT + + cor0.col2 + - col0 FROM tab1 cor0
----
-7
16
51

query I rowsort
SELECT - col0 + col0 * + col2 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT DISTINCT col0 + - col0 * col0 + + col1 FROM tab0
----
-1093
-466
-7741

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * col0 + + col2 + col0 * - tab2.col2 * + tab2.col0 col0 FROM tab2
----
-1107
-156130
-234118

query I rowsort
SELECT tab1.col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

onlyif mysql # use DIV operator for integer division
query I rowsort label-3968
SELECT + col2 + col2 DIV - cor0.col0 FROM tab1 cor0
----
36
57
95

skipif mysql # not compatible
query I rowsort label-3968
SELECT + col2 + col2 / - cor0.col0 FROM tab1 cor0
----
36
57
95

query I rowsort
SELECT + + 48 * ( + col2 ) * col2 FROM tab0 AS cor0
----
322752
48
52272

query I rowsort
SELECT + 36 + + col1 FROM tab0 AS cor0
----
122
127
133

onlyif mysql # use DIV operator for integer division
query I rowsort label-3971
SELECT ALL + col1 + + col1 DIV + col1 AS col1 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-3971
SELECT ALL + col1 + + col1 / + col1 AS col1 FROM tab0
----
87
92
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3972
SELECT - col0 DIV 15 FROM tab1
----
-4
-5
0

skipif mysql # not compatible
query I rowsort label-3972
SELECT - col0 / 15 FROM tab1
----
-4
-5
0

query I rowsort
SELECT ALL tab2.col1 * - col0 + 22 + col0 * - col0 AS col1 FROM tab2
----
-10664
-244
-7562

query I rowsort
SELECT col0 + col2 + + col0 * col2 * col1 FROM tab1
----
100016
36601
4269

onlyif mysql # use DIV operator for integer division
query I rowsort label-3975
SELECT ALL col2 + col1 DIV cor0.col2 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-3975
SELECT ALL col2 + col1 / cor0.col2 FROM tab0 AS cor0
----
35
83
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3976
SELECT DISTINCT + - 8 * + col0 DIV col0 FROM tab2 AS cor0
----
-8

skipif mysql # not compatible
query I rowsort label-3976
SELECT DISTINCT + - 8 * + col0 / col0 FROM tab2 AS cor0
----
-8

query I rowsort
SELECT DISTINCT + cor0.col2 * - col0 + + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-3978
SELECT 26 DIV + col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-3978
SELECT 26 / + col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT ALL ( + col1 ) * + col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - ( - col2 ) col1 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3981
SELECT DISTINCT - CAST( NULL AS SIGNED ) * col2 + col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3981
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * col2 + col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - - col0 + 69 AS col2 FROM tab2 AS cor0
----
147
148
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-3983
SELECT ALL 75 DIV col0 AS col0 FROM tab0 AS cor0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-3983
SELECT ALL 75 / col0 AS col0 FROM tab0 AS cor0
----
0
2
3

query I rowsort
SELECT - 54 * - 74 + col1 AS col2 FROM tab2 cor0
----
4013
4027
4055

query I rowsort
SELECT DISTINCT + - ( - col0 ) * + col2 + 22 FROM tab2 AS cor0
----
2050
211
3024

query I rowsort
SELECT DISTINCT + 38 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3987
SELECT ALL cor0.col1 + - col0 DIV col0 AS col2 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-3987
SELECT ALL cor0.col1 + - col0 / col0 AS col2 FROM tab1 AS cor0
----
12
25
9

query I rowsort
SELECT + + 86 * col0 FROM tab2 AS cor0
----
602
6708
6794

query I rowsort
SELECT DISTINCT + + cor0.col2 * - col2 - - 5 * col0 FROM tab2 cor0
----
-1049
-286
-694

query I rowsort
SELECT DISTINCT + - 59 * col2 AS col2 FROM tab2 AS cor0
----
-1534
-1593
-2242

query I rowsort
SELECT ALL - col0 * col0 + - col0 AS col0 FROM tab2 AS cor0
----
-56
-6162
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-3992
SELECT + - col0 DIV + col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3992
SELECT + - col0 / + col2 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT 1 * - col2 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL - cor0.col0 * col0 + - ( - col1 ) AS col0 FROM tab1 AS cor0
----
-4086
-6387
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-3995
SELECT - col1 + 91 * ( cor0.col2 ) DIV ( col1 ) - + col2 FROM tab2 cor0
----
-45
148
21

skipif mysql # not compatible
query I rowsort label-3995
SELECT - col1 + 91 * ( cor0.col2 ) / ( col1 ) - + col2 FROM tab2 cor0
----
-45
148
21

query I rowsort
SELECT DISTINCT ( 70 ) AS col2 FROM tab1, tab0 AS cor0
----
70

query I rowsort
SELECT - col1 * + col0 - - col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT cor0.col1 + - ( + col2 * col0 + col2 ) AS col2 FROM tab2 AS cor0
----
-185
-1995
-3023

query I rowsort
SELECT ALL - col1 * - cor0.col0 + col0 * - col2 * + cor0.col0 FROM tab0 AS cor0
----
-16944
-641423
2170

query I rowsort
SELECT col0 * col0 + col1 + - col0 AS col2 FROM tab2 AS cor0
----
6065
6179
73

query I rowsort
SELECT ALL - cor0.col1 * ( ( - col0 ) + + cor0.col0 ) AS col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 + ( 82 ) col1 FROM tab2 AS cor0
----
160
161
89

query I rowsort
SELECT ALL + - col1 + + 88 FROM tab2 AS cor0
----
29
57
71

query I rowsort
SELECT + + col2 * col0 - col1 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT ALL - + col0 * - col1 + - cor0.col2 FROM tab0 AS cor0
----
2031
3394
8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-4006
SELECT DISTINCT - tab0.col1 * col1 DIV - col0 FROM tab0
----
268
308
93

skipif mysql # not compatible
query I rowsort label-4006
SELECT DISTINCT - tab0.col1 * col1 / - col0 FROM tab0
----
268
308
93

query I rowsort
SELECT - - col0 + col1 AS col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - - ( + col2 ) - col2 AS col1 FROM tab2 cor0
----
0

query I rowsort
SELECT ALL 36 + 58 * col0 AS col2 FROM tab2 AS cor0
----
442
4560
4618

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4010
SELECT ALL - CAST( NULL AS DECIMAL ) + + 50 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4010
SELECT ALL - CAST ( NULL AS REAL ) + + 50 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( + col1 ) * cor0.col0 col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ( col0 * - col2 ) FROM tab2
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + 30 col1 FROM tab1 AS cor0
----
-300
-390
-780

query I rowsort
SELECT col1 + cor0.col2 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL col0 + col1 * + col0 FROM tab2 AS cor0
----
1422
224
4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 76 col1 FROM tab0, tab0 AS cor0, tab1 cor1
----
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 * + 53 + cor0.col2 col2 FROM tab0 AS cor0
----
-1716
-4264
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-4018
SELECT ALL + col1 - ( + cor0.col1 ) DIV cor0.col1 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-4018
SELECT ALL + col1 - ( + cor0.col1 ) / cor0.col1 FROM tab1 AS cor0
----
12
25
9

query I rowsort
SELECT DISTINCT + tab0.col0 FROM tab0, tab1 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 7 col0 FROM tab0, tab0 AS cor0, tab2 cor1
----
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4021
SELECT DISTINCT CAST( NULL AS DECIMAL ) FROM tab1, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4021
SELECT DISTINCT CAST ( NULL AS REAL ) FROM tab1, tab0 AS cor0
----
NULL

query I rowsort
SELECT + tab1.col0 * ( 94 * col1 + + col2 ) AS col1 FROM tab1
----
105440
63808
7494

query I rowsort
SELECT + col1 * - 66 AS col2 FROM tab0 cor0
----
-5676
-6006
-6402

query I rowsort
SELECT ALL + 49 FROM tab0, tab0 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT ALL + cor0.col2 - + cor0.col2 AS col0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT + - 12 + - col1 FROM tab0 AS cor0
----
-103
-109
-98

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( + ( col1 ) AS REAL ) FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ( 53 ) * col2 + - col2 AS col0 FROM tab0 AS cor0
----
1716
4264
52

query I rowsort
SELECT + 93 + + col0 AS col1 FROM tab1 AS cor0
----
157
173
96

query I rowsort
SELECT + cor0.col2 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4031
SELECT - CAST( NULL AS SIGNED ) * col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4031
SELECT - CAST ( NULL AS INTEGER ) * col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * + 1 + col2 AS col0 FROM tab1
----
108
114
192

query I rowsort
SELECT DISTINCT 46 * 36 FROM tab0 AS cor0
----
1656

query I rowsort
SELECT + + ( 67 ) AS col2 FROM tab2 AS cor0
----
67
67
67

query I rowsort
SELECT DISTINCT - - ( + col2 ) + col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL + 71 FROM tab0, tab0 AS cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT ALL 83 * col2 + col0 FROM tab0 AS cor0
----
118
2763
6895

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 * + col2 col1 FROM tab1 cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-4039
SELECT ALL - col2 + col1 * col2 DIV cor0.col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4039
SELECT ALL - col2 + col1 * col2 / cor0.col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4040
SELECT DISTINCT - col1 DIV - col1 + col1 - + col1 AS col1 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-4040
SELECT DISTINCT - col1 / - col1 + col1 - + col1 AS col1 FROM tab0 AS cor0
----
1

query I rowsort
SELECT ALL + 71 + col1 AS col0 FROM tab0
----
157
162
168

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4042
SELECT CAST( NULL AS SIGNED ) * + 66 AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4042
SELECT CAST ( NULL AS INTEGER ) * + 66 AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - ( col0 ) AS col2 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT ALL ( col1 ) * col1 AS col2 FROM tab1
----
100
169
676

query I rowsort
SELECT - col1 * + col2 - cor0.col2 * col1 AS col2 FROM tab0 AS cor0
----
-14924
-194
-5676

query I rowsort
SELECT - + col0 * - cor0.col0 * - 14 + + col0 * col2 AS col2 FROM tab2 AS cor0
----
-497
-83148
-84372

onlyif mysql # use DIV operator for integer division
query I rowsort label-4047
SELECT + 17 DIV tab2.col0 AS col1 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-4047
SELECT + 17 / tab2.col0 AS col1 FROM tab2
----
0
0
2

query I rowsort
SELECT DISTINCT col0 + col1 + - col0 AS col1 FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-4049
SELECT col2 * + col1 DIV - col1 - col0 * - col0 FROM tab0 AS cor0
----
1224
543
7839

skipif mysql # not compatible
query I rowsort label-4049
SELECT col2 * + col1 / - col1 - col0 * - col0 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT tab2.col0 + ( - tab2.col2 ) AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 363494b33b4d1826f58e179e26d91c4a

query I rowsort
SELECT ALL - ( - tab2.col1 + - col0 ) AS col1 FROM tab2
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 22 + + col1 col0 FROM tab0
----
108
113
119

query I rowsort
SELECT DISTINCT - tab1.col1 * col2 + 35 + col2 * + col1 AS col2 FROM tab1
----
35

query I rowsort
SELECT DISTINCT - + 22 AS col2 FROM tab2, tab1, tab2 AS cor0
----
-22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT + col2 * ( 16 * - col1 ) FROM tab0 cor0
----
-119392
-1552
-45408

onlyif mysql # use DIV operator for integer division
query I rowsort label-4057
SELECT ALL - col2 * - ( col0 ) + + col2 DIV col1 - col0 FROM tab0
----
0
7209
768

skipif mysql # not compatible
query I rowsort label-4057
SELECT ALL - col2 * - ( col0 ) + + col2 / col1 - col0 FROM tab0
----
0
7209
768

query I rowsort
SELECT - col1 + col0 + 3 FROM tab1 AS cor0
----
-20
57
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-4059
SELECT + col2 + col1 DIV - col0 + col0 AS col1 FROM tab1 AS cor0
----
121
176
49

skipif mysql # not compatible
query I rowsort label-4059
SELECT + col2 + col1 / - col0 + col0 AS col1 FROM tab1 AS cor0
----
121
176
49

query I rowsort
SELECT ALL 79 * col1 * - col1 + - col2 AS col2 FROM tab2
----
-22869
-275025
-75946

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + col1 * - col1 col2 FROM tab0
----
-7420
-8370
-9444

query I rowsort
SELECT DISTINCT - 73 * + 99 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
-7227

query I rowsort
SELECT ALL - 58 * + col1 + + col1 * col0 FROM tab2
----
-1581
1180
357

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col2 + + col0 + + 62 col1 FROM tab2
----
166
179
96

query I rowsort
SELECT col2 * + col2 + - cor0.col2 * cor0.col1 AS col0 FROM tab2 AS cor0
----
-108
-858
798

onlyif mysql # use DIV operator for integer division
query I rowsort label-4066
SELECT DISTINCT + col1 - col2 DIV col1 FROM tab1 AS cor0
----
24
5
6

skipif mysql # not compatible
query I rowsort label-4066
SELECT DISTINCT + col1 - col2 / col1 FROM tab1 AS cor0
----
24
5
6

query I rowsort
SELECT DISTINCT + 35 + + col1 AS col0 FROM tab1 AS cor0
----
45
48
61

query I rowsort
SELECT - col2 - + col0 AS col1 FROM tab0 cor0
----
-171
-36
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-4069
SELECT - col2 DIV + col1 FROM tab2 cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-4069
SELECT - col2 / + col1 FROM tab2 cor0
----
-2
0
0

query I rowsort
SELECT DISTINCT col2 * - col2 + col0 AS col1 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT DISTINCT + col1 + + col2 AS col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT - - 13 FROM tab0, tab1, tab0 AS cor0
----
13

query I rowsort
SELECT DISTINCT + tab2.col2 AS col1 FROM tab2, tab1, tab0 AS cor0
----
26
27
38

query I rowsort
SELECT - 5 - + col2 FROM tab2 AS cor0
----
-31
-32
-43

query I rowsort
SELECT ALL - 79 * col0 AS col2 FROM tab0 AS cor0
----
-1896
-2765
-7031

query I rowsort
SELECT ALL col1 * col0 + col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT + col1 + - ( + col1 ) * - col1 + cor0.col1 FROM tab1 AS cor0
----
120
195
728

query I rowsort
SELECT ALL - - cor0.col2 + - col0 AS col0 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4079
SELECT ALL + + col1 * - CAST( NULL AS SIGNED ) + - cor0.col2 / col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4079
SELECT ALL + + col1 * - CAST ( NULL AS INTEGER ) + - cor0.col2 / col0 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + 4 AS col0 FROM tab2 AS cor0
----
21
35
63

query I rowsort
SELECT - col0 * + col2 + + col2 AS col2 FROM tab2 AS cor0
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-4082
SELECT DISTINCT + col0 DIV 84 FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4082
SELECT DISTINCT + col0 / 84 FROM tab2 AS cor0
----
0

query I rowsort
SELECT - + col1 + + col1 * - col1 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT tab1.col2 * - col2 AS col2 FROM tab1
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-4085
SELECT DISTINCT + tab1.col0 + - col1 * 42 DIV - col0 AS col1 FROM tab1
----
367
70
86

skipif mysql # not compatible
query I rowsort label-4085
SELECT DISTINCT + tab1.col0 + - col1 * 42 / - col0 AS col1 FROM tab1
----
367
70
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - col0 * - cor0.col2 + col0 col1 FROM tab1 cor0
----
191
3722
7773

query I rowsort
SELECT DISTINCT + col0 * - 45 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
-132
-2816
-3520

query I rowsort
SELECT ALL + - col1 + col1 * 57 AS col1 FROM tab2 cor0
----
1736
3304
952

query I rowsort
SELECT col1 + 1 AS col0 FROM tab2 AS cor0
----
18
32
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-4090
SELECT ALL col1 DIV col2 + col0 AS col2 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-4090
SELECT ALL col1 / col2 + col0 AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT col1 * 57 + - 12 * col1 FROM tab1 AS cor0
----
1170
450
585

query I rowsort
SELECT + col0 * - ( col2 * 7 ) AS col2 FROM tab0 AS cor0
----
-245
-51086
-5544

query I rowsort
SELECT DISTINCT - 43 * 57 * - col0 AS col2 FROM tab0 cor0
----
218139
58824
85785

query I rowsort
SELECT - ( - col1 ) * col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT 59 * col1 + + col0 - ( col1 ) AS col1 FROM tab1
----
1511
644
834

query I rowsort
SELECT ( - col0 ) * - cor0.col0 + col1 AS col2 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT DISTINCT + 53 * + col1 FROM tab2 AS cor0
----
1643
3127
901

query I rowsort
SELECT 44 * - col1 FROM tab0 AS cor0
----
-3784
-4004
-4268

query I rowsort
SELECT DISTINCT - - ( cor0.col0 ) * + col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL + 86 * 11 FROM tab2, tab0 AS cor0
----
9 values hashing to e69b857ff5cb70222d63ee6513f106bf

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 1 * - col2 col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT - + ( ( col2 ) ) AS col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + 28 col0 FROM tab0 AS cor0
----
2296
28
924

query I rowsort
SELECT DISTINCT - col0 * cor0.col1 AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + - ( - cor0.col0 ) + - col0 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4106
SELECT ALL col0 - col1 DIV - ( col0 ) FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-4106
SELECT ALL col0 - col1 / - ( col0 ) FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col0 * + col2 * - CAST ( + col0 AS REAL ) AS col0 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT ALL col0 + cor0.col0 * ( - col2 ) FROM tab0 AS cor0
----
-7209
-768
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4109
SELECT ALL CAST( NULL AS SIGNED ) - col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4109
SELECT ALL CAST ( NULL AS INTEGER ) - col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - 8 AS col0 FROM tab1
----
-8
-8
-8

query I rowsort
SELECT - 84 * col2 FROM tab2
----
-2184
-2268
-3192

query I rowsort
SELECT + cor0.col1 + - col0 AS col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT + ( - col1 ) - col2 * col0 AS col2 FROM tab0 cor0
----
-132
-7389
-878

query I rowsort
SELECT ALL - - col2 * + cor0.col0 + ( - col2 * + col1 ) FROM tab2 AS cor0
----
-648
2356
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-4115
SELECT DISTINCT col2 * col1 DIV col1 - + col2 AS col2 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4115
SELECT DISTINCT col2 * col1 / col1 - + col2 AS col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT ( - col0 ) * - col0 AS col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL col2 * - col2 + cor0.col0 + - col0 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
-14734
-3129
-3361

onlyif mysql # use DIV operator for integer division
query I rowsort label-4118
SELECT ALL - ( col0 ) DIV + col0 col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4118
SELECT ALL - ( col0 ) / + col0 col1 FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4119
SELECT DISTINCT - CAST( col2 AS SIGNED ) * col0 DIV col2 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-4119
SELECT DISTINCT - CAST ( col2 AS INTEGER ) * col0 / col2 FROM tab0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4120
SELECT - col2 DIV - tab0.col1 - - col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-4120
SELECT - col2 / - tab0.col1 - - col0 FROM tab0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4121
SELECT + CAST( NULL AS DECIMAL ) + - col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4121
SELECT + CAST ( NULL AS REAL ) + - col2 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4122
SELECT + 49 + col1 DIV - cor0.col0 FROM tab0 AS cor0
----
46
47
48

skipif mysql # not compatible
query I rowsort label-4122
SELECT + 49 + col1 / - cor0.col0 FROM tab0 AS cor0
----
46
47
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-4123
SELECT 50 DIV + col1 AS col2 FROM tab1 cor0
----
1
3
5

skipif mysql # not compatible
query I rowsort label-4123
SELECT 50 / + col1 AS col2 FROM tab1 cor0
----
1
3
5

query I rowsort
SELECT DISTINCT + cor1.col2 + + tab1.col2 AS col1 FROM tab1, tab0 AS cor0, tab2, tab2 AS cor1
----
9 values hashing to 08980ba33c72425c650f4b0533f5a9d7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 62 col0 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col0 col1 FROM tab1
----
162
3648
7680

query I rowsort
SELECT ALL - 53 * cor0.col0 AS col1 FROM tab0 AS cor0
----
-1272
-1855
-4717

query I rowsort
SELECT ALL - col0 * col2 - 41 AS col0 FROM tab0 AS cor0
----
-7339
-76
-833

onlyif mysql # use DIV operator for integer division
query I rowsort label-4129
SELECT DISTINCT col1 DIV tab0.col2 + 31 * tab0.col0 * tab0.col1 FROM tab0
----
105342
251070
63986

skipif mysql # not compatible
query I rowsort label-4129
SELECT DISTINCT col1 / tab0.col2 + 31 * tab0.col0 * tab0.col1 FROM tab0
----
105342
251070
63986

query I rowsort
SELECT DISTINCT cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
10
13
26

query I rowsort
SELECT + 94 * tab1.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to f921c393277435555824b774774f1983

query I rowsort
SELECT - 55 * cor0.col2 AS col1 FROM tab2 AS cor0
----
-1430
-1485
-2090

query I rowsort
SELECT ALL - col1 * + 24 FROM tab0 cor0
----
-2064
-2184
-2328

onlyif mysql # use DIV operator for integer division
query I rowsort label-4134
SELECT DISTINCT - col2 DIV 18 FROM tab0 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-4134
SELECT DISTINCT - col2 / 18 FROM tab0 AS cor0
----
-1
-4
0

query I rowsort
SELECT DISTINCT - col1 * - 10 + - col1 AS col1 FROM tab2 AS cor0
----
153
279
531

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( tab1.col0 ) col2 FROM tab1
----
3
64
80

query I rowsort
SELECT DISTINCT + col2 + - col1 * - col1 AS col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT - - ( col0 ) AS col0 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4139
SELECT + col0 + + tab0.col0 DIV + col0 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-4139
SELECT + col0 + + tab0.col0 / + col0 FROM tab0
----
25
36
90

query I rowsort
SELECT ALL + - ( + 59 ) * col1 FROM tab2 AS cor0
----
-1003
-1829
-3481

query I rowsort
SELECT ALL 37 AS col2 FROM tab2 AS cor0
----
37
37
37

query I rowsort
SELECT ALL col1 + + col2 * - col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT + ( ( - col0 ) ) * cor0.col0 + 92 FROM tab0 AS cor0
----
-1133
-484
-7829

query I rowsort
SELECT DISTINCT col2 * - 1 * col2 AS col1 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT 6 * tab2.col1 FROM tab2, tab1 cor0
----
9 values hashing to 7b6f7b44d971ceaede5dfcdeaa8a82a3

query I rowsort
SELECT ALL 64 AS col2 FROM tab1
----
64
64
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-4147
SELECT + col2 * col2 DIV + col0 FROM tab1 AS cor0
----
115
50
972

skipif mysql # not compatible
query I rowsort label-4147
SELECT + col2 * col2 / + col0 FROM tab1 AS cor0
----
115
50
972

query I rowsort
SELECT - 53 * + 79 FROM tab2 AS cor0
----
-4187
-4187
-4187

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT cor0.col0 + + col1 * cor0.col0 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT DISTINCT col0 + col2 * 2 FROM tab2
----
130
155
61

query I rowsort
SELECT 41 * - col2 AS col2 FROM tab1
----
-2214
-2337
-3936

query I rowsort
SELECT DISTINCT + + 67 * + col0 + + 71 AS col1 FROM tab0 AS cor0
----
1679
2416
6034

query I rowsort
SELECT + - col1 + - col0 + + col1 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4155
SELECT cor0.col0 - - CAST( - cor0.col0 + + col0 AS SIGNED ) * 85 AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-4155
SELECT cor0.col0 - - CAST ( - cor0.col0 + + col0 AS INTEGER ) * 85 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - col0 * + col1 + col1 * - col0 * cor0.col2 + - col2 * col0 FROM tab1 AS cor0
----
-108560
-40768
-4452

query I rowsort
SELECT ALL - 24 + - 68 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 1af709a79a3e56281ffdce4d931d5965

query I rowsort
SELECT - col2 * ( + tab1.col0 ) * col2 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT DISTINCT tab0.col2 * + ( - 27 ) AS col2 FROM tab0
----
-2214
-27
-891

query I rowsort
SELECT col1 * ( + col2 * + col2 ) FROM tab1
----
119808
32490
75816

query I rowsort
SELECT + col2 * col0 - col2 AS col1 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT col1 * - col0 + col1 AS col2 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT - col1 + 12 FROM tab1 AS cor0
----
-1
-14
2

query I rowsort
SELECT cor1.col2 AS col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4165
SELECT DISTINCT CAST( col2 AS SIGNED ) * col1 AS col2 FROM tab2 AS cor0
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-4165
SELECT DISTINCT CAST ( col2 AS INTEGER ) * col1 AS col2 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4166
SELECT + CAST( NULL AS SIGNED ) / + 78 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4166
SELECT + CAST ( NULL AS INTEGER ) / + 78 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + 81 AS REAL ) + - col2 * + CAST ( col0 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-711
-7217
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-4168
SELECT - 26 DIV col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4168
SELECT - 26 / col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4169
SELECT DISTINCT + - CAST( col0 AS SIGNED ) + col2 FROM tab2 AS cor0
----
-41
-52
20

skipif mysql # not compatible
query I rowsort label-4169
SELECT DISTINCT + - CAST ( col0 AS INTEGER ) + col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + 94 + + col1 * + col0 - + 45 AS col0 FROM tab0 AS cor0
----
2113
3444
8148

query I rowsort
SELECT - col0 * col0 * - col1 + - ( - col1 ) * col1 AS col0 FROM tab0 AS cor0
----
128234
56932
729092

onlyif mysql # use DIV operator for integer division
query I rowsort label-4172
SELECT ALL + - ( col1 ) DIV col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4172
SELECT ALL + - ( col1 ) / col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 96 col0 FROM tab2 cor0
----
-96

query I rowsort
SELECT + tab2.col1 * - tab2.col1 + - 77 AS col0 FROM tab2
----
-1038
-3558
-366

query I rowsort
SELECT + 43 * + col0 FROM tab1 AS cor0
----
129
2752
3440

query I rowsort
SELECT DISTINCT cor0.col0 * - col0 + - ( - col2 ) AS col2 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT ALL + - col0 + - 15 + + col1 AS col2 FROM tab0 AS cor0
----
-13
47
47

query I rowsort
SELECT ALL + 36 AS col0 FROM tab1
----
36
36
36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4179
SELECT + cor0.col1 / CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4179
SELECT + cor0.col1 / CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4180
SELECT ALL + - col1 + cor0.col1 DIV + 20 AS col2 FROM tab2 AS cor0
----
-17
-30
-57

skipif mysql # not compatible
query I rowsort label-4180
SELECT ALL + - col1 + cor0.col1 / + 20 AS col2 FROM tab2 AS cor0
----
-17
-30
-57

query I rowsort
SELECT + - col1 * ( - col1 ) FROM tab0 AS cor0
----
7396
8281
9409

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4182
SELECT ALL col2 + + CAST( + 78 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
111
160
79

skipif mysql # not compatible
query I rowsort label-4182
SELECT ALL col2 + + CAST ( + 78 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
111
160
79

query I rowsort
SELECT ALL 94 AS col0 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to a4d239626cf0546ac1b2f57bb8407089

query I rowsort
SELECT - 55 AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to b90e74bece5521b514096c5b6e105fde

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 25 + col0 col1 FROM tab2 cor0
----
-18
53
54

query I rowsort
SELECT + + col0 - col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 * col0 - col1 * 32 FROM tab0 AS cor0
----
-11011
-4816
-6499

onlyif mysql # use DIV operator for integer division
query I rowsort label-4188
SELECT DISTINCT - 29 * col1 - col2 DIV 87 col1 FROM tab1 AS cor0
----
-290
-378
-754

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4188
SELECT DISTINCT - 29 * col1 - col2 / 87 col1 FROM tab1 AS cor0
----
-290
-378
-754

query I rowsort
SELECT DISTINCT + 23 FROM tab2 cor0
----
23

query I rowsort
SELECT 17 FROM tab1 cor0
----
17
17
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 85 col0 FROM tab0, tab2 AS cor0
----
85

query I rowsort
SELECT ALL - ( + col2 ) * tab0.col2 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT ALL - ( - col0 ) * col2 + + 30 FROM tab2
----
2058
219
3032

query I rowsort
SELECT ALL col1 + tab1.col1 + 67 FROM tab1
----
119
87
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4195
SELECT DISTINCT ( col1 ) + + CAST( 10 AS SIGNED ) AS col1 FROM tab1
----
20
23
36

skipif mysql # not compatible
query I rowsort label-4195
SELECT DISTINCT ( col1 ) + + CAST ( 10 AS INTEGER ) AS col1 FROM tab1
----
20
23
36

query I rowsort
SELECT DISTINCT + 49 AS col2 FROM tab0, tab0 AS cor0, tab1 cor1
----
49

query I rowsort
SELECT ALL col1 + col2 * + tab2.col1 FROM tab2
----
1593
663
868

query I rowsort
SELECT DISTINCT - - 17 FROM tab1 AS cor0
----
17

query I rowsort
SELECT + - col0 - + col1 AS col2 FROM tab2 AS cor0
----
-137
-38
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4200
SELECT ALL + col2 DIV col2 col0 FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4200
SELECT ALL + col2 / col2 col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + 70 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
70

query I rowsort
SELECT DISTINCT - col0 * cor0.col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - + col1 + + col2 AS col0 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT 50 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
50

query I rowsort
SELECT tab0.col0 + col1 * 18 FROM tab0
----
1572
1727
1781

query I rowsort
SELECT col0 + + col0 * - tab2.col0 FROM tab2
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT - cor0.col2 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
-119
-173
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 + - col1 col2 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT - + col1 + - cor0.col2 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT ALL + ( col1 ) * col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + col0 * 25 AS col0 FROM tab0 AS cor0
----
2225
600
875

query I rowsort
SELECT DISTINCT ( 10 ) * + col2 + + 84 * + cor0.col0 FROM tab0 AS cor0
----
2346
2950
8296

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( + col1 ) col2 FROM tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - col2 * + col0 col0 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL + col2 * - col2 AS col1 FROM tab1 cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-4216
SELECT + - 25 DIV - 11 AS col2 FROM tab0 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-4216
SELECT + - 25 / - 11 AS col2 FROM tab0 AS cor0
----
2
2
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4217
SELECT DISTINCT - CAST( 54 AS SIGNED ) + col2 * + col0 FROM tab0 AS cor0
----
-19
7244
738

skipif mysql # not compatible
query I rowsort label-4217
SELECT DISTINCT - CAST ( 54 AS INTEGER ) + col2 * + col0 FROM tab0 AS cor0
----
-19
7244
738

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4218
SELECT - CAST( NULL AS SIGNED ) / 46 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4218
SELECT - CAST ( NULL AS INTEGER ) / 46 col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + 64 AS col2 FROM tab0 AS cor0
----
-64
-64
-64

onlyif mysql # use DIV operator for integer division
query I rowsort label-4220
SELECT DISTINCT + col0 DIV + col1 FROM tab1 cor0
----
0
6

skipif mysql # not compatible
query I rowsort label-4220
SELECT DISTINCT + col0 / + col1 FROM tab1 cor0
----
0
6

query I rowsort
SELECT - 63 AS col1 FROM tab0
----
-63
-63
-63

query I rowsort
SELECT ALL + 33 + cor0.col2 AS col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to d3e17115d0cdb55624dd53be23abcdc2

query I rowsort
SELECT ALL - 12 + - col2 * col2 FROM tab1 AS cor0
----
-2928
-3261
-9228

query I rowsort
SELECT + cor0.col2 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

onlyif mysql # use DIV operator for integer division
query I rowsort label-4225
SELECT DISTINCT - ( + col0 ) DIV col1 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-4225
SELECT DISTINCT - ( + col0 ) / col1 FROM tab2
----
-1
-4
0

query I rowsort
SELECT ALL - col1 * col2 + - col1 * + cor0.col2 * ( col2 * col1 ) FROM tab2 AS cor0
----
-2354690
-417962
-701406

query I rowsort
SELECT col1 * - 84 * cor0.col0 FROM tab1 AS cor0
----
-53760
-6552
-87360

query I rowsort
SELECT DISTINCT - + cor0.col1 + + col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT col1 + - 69 FROM tab0 AS cor0
----
17
22
28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + - cor0.col1 col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT col0 + - col1 * - col1 * col1 FROM tab2 AS cor0
----
205457
29798
4992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 ) * 58 col2 FROM tab2 cor0
----
406
4524
4582

query I rowsort
SELECT + - ( + cor0.col0 ) * - col2 + col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT + tab1.col0 * - col2 + - col0 FROM tab1
----
-165
-3712
-7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-4235
SELECT DISTINCT + cor0.col0 DIV - ( - 25 ) + - col1 FROM tab0 AS cor0
----
-86
-88
-96

skipif mysql # not compatible
query I rowsort label-4235
SELECT DISTINCT + cor0.col0 / - ( - 25 ) + - col1 FROM tab0 AS cor0
----
-86
-88
-96

query I rowsort
SELECT DISTINCT - col1 * col0 + + cor0.col2 * cor0.col1 * col1 FROM tab2 AS cor0
----
25730
85904
9639

query I rowsort
SELECT DISTINCT - col1 + + cor0.col0 * col2 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT DISTINCT - col0 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + + col2 + + 11 FROM tab1 AS cor0
----
107
65
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4240
SELECT col2 * + CAST( col0 AS SIGNED ) + - col2 FROM tab2 AS cor0
----
162
2002
2964

skipif mysql # not compatible
query I rowsort label-4240
SELECT col2 * + CAST ( col0 AS INTEGER ) + - col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT ALL + col1 + - col1 * + 57 FROM tab2 AS cor0
----
-1736
-3304
-952

query I rowsort
SELECT DISTINCT + col2 + - col1 * col1 AS col2 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT - 57 + col2 FROM tab1
----
-3
0
39

query I rowsort
SELECT ALL + col2 + 40 * col0 - + col0 * - ( col1 ) AS col0 FROM tab2 cor0
----
4541
524
7748

query I rowsort
SELECT - - cor0.col0 + col0 * - col0 AS col1 FROM tab1 AS cor0
----
-4032
-6
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-4246
SELECT + 1 + + col1 DIV col0 FROM tab2 AS cor0
----
1
1
5

skipif mysql # not compatible
query I rowsort label-4246
SELECT + 1 + + col1 / col0 FROM tab2 AS cor0
----
1
1
5

query I rowsort
SELECT DISTINCT col0 * - col1 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT 78 * col0 FROM tab1 AS cor0
----
234
4992
6240

query I rowsort
SELECT - 22 * - col0 - ( col2 ) AS col0 FROM tab2 AS cor0
----
127
1690
1700

query I rowsort
SELECT - cor0.col1 - - col1 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT 24 * - col1 FROM tab2
----
-1416
-408
-744

onlyif mysql # use DIV operator for integer division
query I rowsort label-4252
SELECT CAST( col1 AS SIGNED ) DIV - col0 AS col1 FROM tab2
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-4252
SELECT CAST ( col1 AS INTEGER ) / - col0 AS col1 FROM tab2
----
-4
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4253
SELECT DISTINCT col2 + 33 DIV col2 FROM tab0
----
34
82

skipif mysql # not compatible
query I rowsort label-4253
SELECT DISTINCT col2 + 33 / col2 FROM tab0
----
34
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 79 * + col2 col1 FROM tab1
----
4266
4503
7584

query I rowsort
SELECT 40 AS col2 FROM tab1 AS cor0
----
40
40
40

query I rowsort
SELECT + ( - col0 ) * col0 - col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT ALL tab1.col1 * - 35 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 6080e370f86ce7edde8c44797e4affff

query I rowsort
SELECT ALL tab0.col2 * cor0.col2 FROM tab0, tab2 AS cor0
----
9 values hashing to a477aa402dcd904394a585dfd5cfe837

query I rowsort
SELECT + + 34 * + col0 FROM tab2 AS cor0
----
238
2652
2686

query I rowsort
SELECT 56 FROM tab0, tab2 AS cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT DISTINCT - cor1.col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
-24
-35
-89

query I rowsort
SELECT ALL ( col1 + + col0 ) AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT ALL + 83 * + col1 * + col0 AS col2 FROM tab1
----
53120
6474
86320

query I rowsort
SELECT ALL + ( 10 ) AS col2 FROM tab1
----
10
10
10

onlyif mysql # use DIV operator for integer division
query I rowsort label-4265
SELECT ALL 42 DIV 34 + - tab0.col1 * - 95 FROM tab0
----
8171
8646
9216

skipif mysql # not compatible
query I rowsort label-4265
SELECT ALL 42 / 34 + - tab0.col1 * - 95 FROM tab0
----
8171
8646
9216

query I rowsort
SELECT - - 41 AS col1 FROM tab1 AS cor0
----
41
41
41

query I rowsort
SELECT ALL 25 FROM tab0, tab0 cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT ALL - ( col1 ) + - col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT + col0 + col1 * col2 AS col0 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-4270
SELECT DISTINCT - + col1 DIV - col0 AS col1 FROM tab2 AS cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-4270
SELECT DISTINCT - + col1 / - col0 AS col1 FROM tab2 AS cor0
----
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col2 * + 41 + tab0.col0 * col1 * 62 col2 FROM tab0
----
214467
244326
808080

query I rowsort
SELECT - col0 * col0 + col0 + col2 * + col0 FROM tab0 AS cor0
----
-1155
-534
240

query I rowsort
SELECT DISTINCT ( + col1 ) - 1 * - col1 AS col2 FROM tab2
----
118
34
62

query I rowsort
SELECT DISTINCT - col1 - col0 * tab0.col2 FROM tab0
----
-132
-7389
-878

onlyif mysql # use DIV operator for integer division
query I rowsort label-4275
SELECT + 36 DIV col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4275
SELECT + 36 / col2 FROM tab1
----
0
0
0

query I rowsort
SELECT + 42 * col1 + + ( + col0 ) * col1 AS col0 FROM tab1
----
1060
1170
1586

query I rowsort
SELECT DISTINCT 58 * col1 - + col2 AS col0 FROM tab1
----
1454
523
658

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab0 cor1, tab2 AS cor2
----
972 values hashing to 9600bdf5bac0caec3229e87170cc40b3

query I rowsort
SELECT DISTINCT - ( col0 ) + + 73 FROM tab2 cor0
----
-5
-6
66

query I rowsort
SELECT DISTINCT + 43 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
43

query I rowsort
SELECT ALL 53 AS col1 FROM tab2, tab2 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 63949b5362442f48bd29195397a57dad

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 89 col1 FROM tab2, tab1 AS cor0, tab0 cor1
----
27 values hashing to 860d55eb6785972467218a9c3badb5ad

query I rowsort
SELECT - - col0 + col1 * ( col2 ) AS col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT 50 * - col0 AS col2 FROM tab0 AS cor0
----
-1200
-1750
-4450

query I rowsort
SELECT - 39 + col0 * ( col2 ) FROM tab2 AS cor0
----
150
1989
2963

query I rowsort
SELECT 4 FROM tab0, tab0 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT + tab2.col0 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + - col0 * - col2 + - 67 FROM tab2 AS cor0
----
122
1961
2935

query I rowsort
SELECT + + col1 * + col1 * + 93 FROM tab1 AS cor0
----
15717
62868
9300

query I rowsort
SELECT + 33 FROM tab1, tab2 cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT + + col1 * 21 FROM tab2 AS cor0
----
1239
357
651

onlyif mysql # use DIV operator for integer division
query I rowsort label-4292
SELECT + col0 DIV ( + col1 ) AS col0 FROM tab2 cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-4292
SELECT + col0 / ( + col1 ) AS col0 FROM tab2 cor0
----
0
1
4

query I rowsort
SELECT + - ( - 17 ) * col0 AS col0 FROM tab2 AS cor0
----
119
1326
1343

query I rowsort
SELECT + col2 * 4 AS col0 FROM tab0 AS cor0
----
132
328
4

query I rowsort
SELECT ALL + ( col0 ) * col0 * 22 + 13 * - col0 + 67 FROM tab2 AS cor0
----
1054
132901
136342

onlyif mysql # use DIV operator for integer division
query I rowsort label-4296
SELECT DISTINCT - 20 * + col0 + col0 DIV + ( col0 ) FROM tab0 AS cor0
----
-1779
-479
-699

skipif mysql # not compatible
query I rowsort label-4296
SELECT DISTINCT - 20 * + col0 + col0 / + ( col0 ) FROM tab0 AS cor0
----
-1779
-479
-699

query I rowsort
SELECT DISTINCT 31 * - 87 AS col0 FROM tab1 AS cor0
----
-2697

query I rowsort
SELECT ALL col0 + ( + 43 ) * col1 FROM tab1 AS cor0
----
1121
494
639

query I rowsort
SELECT ALL col0 + - 68 + col1 FROM tab0 AS cor0
----
112
42
64

query I rowsort
SELECT cor0.col2 + 5 AS col1 FROM tab2 AS cor0
----
31
32
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4301
SELECT DISTINCT col2 * + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4301
SELECT DISTINCT col2 * + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + col1 - - col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT - 71 - - col2 FROM tab1
----
-14
-17
25

query I rowsort
SELECT ALL - 41 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 4ba0c102091f9cbc9fe9439b04584e70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4305
SELECT col1 - + col1 * CAST( NULL AS DECIMAL ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4305
SELECT col1 - + col1 * CAST ( NULL AS REAL ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * cor0.col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort
SELECT + col2 + CAST ( col2 * - col0 AS REAL ) FROM tab1
----
-108
-3591
-7584

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4308
SELECT col2 - - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4308
SELECT col2 - - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - ( - cor0.col1 ) * col0 + + col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT - col1 * - col2 + - col1 * 36 * col1 AS col2 FROM tab1 AS cor0
----
-22932
-3030
-4836

query I rowsort
SELECT + 21 - col0 FROM tab1 AS cor0
----
-43
-59
18

query I rowsort
SELECT ALL - col0 * - tab1.col2 * 62 FROM tab1
----
10044
226176
476160

query I rowsort
SELECT + col0 * ( col2 * - col0 ) AS col2 FROM tab1 AS cor0
----
-233472
-486
-614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-4314
SELECT + col0 DIV - 89 + - 3 FROM tab1
----
-3
-3
-3

skipif mysql # not compatible
query I rowsort label-4314
SELECT + col0 / - 89 + - 3 FROM tab1
----
-3
-3
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-4315
SELECT col0 DIV 48 + - col1 AS col0 FROM tab2
----
-16
-31
-58

skipif mysql # not compatible
query I rowsort label-4315
SELECT col0 / 48 + - col1 AS col0 FROM tab2
----
-16
-31
-58

query I rowsort
SELECT 26 + - cor0.col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 77d862048d2bf4e93075bb3e95a614e0

query I rowsort
SELECT DISTINCT - 47 - tab0.col2 AS col1 FROM tab0, tab0 AS cor0
----
-129
-48
-80

query I rowsort
SELECT - cor0.col2 * + col2 * - col0 FROM tab1 cor0
----
207936
737280
8748

query I rowsort
SELECT 84 * col1 FROM tab0 AS cor0
----
7224
7644
8148

onlyif mysql # use DIV operator for integer division
query I rowsort label-4320
SELECT DISTINCT col2 DIV cor0.col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-4320
SELECT DISTINCT col2 / cor0.col0 FROM tab1 AS cor0
----
0
1
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-4321
SELECT ALL - 73 * + col2 + col1 DIV ( col1 ) FROM tab2
----
-1897
-1970
-2773

skipif mysql # not compatible
query I rowsort label-4321
SELECT ALL - 73 * + col2 + col1 / ( col1 ) FROM tab2
----
-1897
-1970
-2773

query I rowsort
SELECT ALL + 0 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + tab2.col2 + col2 AS col1 FROM tab2
----
52
54
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4324
SELECT DISTINCT + ( col1 ) * CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4324
SELECT DISTINCT + ( col1 ) * CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4325
SELECT + + ( col1 ) DIV - col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-4325
SELECT + + ( col1 ) / - col0 FROM tab1 AS cor0
----
-8
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4326
SELECT DISTINCT + col0 * col1 DIV cor0.col0 AS col0 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-4326
SELECT DISTINCT + col0 * col1 / cor0.col0 AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL 86 + - col1 AS col1 FROM tab1 AS cor0
----
60
73
76

query I rowsort
SELECT col1 + col2 * + 55 FROM tab1 cor0
----
2996
3145
5293

onlyif mysql # use DIV operator for integer division
query I rowsort label-4329
SELECT - - cor0.col0 DIV + cor0.col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-4329
SELECT - - cor0.col0 / + cor0.col1 FROM tab1 AS cor0
----
0
6
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-4330
SELECT DISTINCT + col2 DIV col0 AS col0 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-4330
SELECT DISTINCT + col2 / col0 AS col0 FROM tab1
----
0
1
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-4331
SELECT - col2 * tab2.col1 DIV CAST( ( - col0 ) AS SIGNED ) + + col1 * col2 * col2 AS col0 FROM tab2
----
22718
24556
39903

skipif mysql # not compatible
query I rowsort label-4331
SELECT - col2 * tab2.col1 / CAST ( ( - col0 ) AS INTEGER ) + + col1 * col2 * col2 AS col0 FROM tab2
----
22718
24556
39903

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4332
SELECT ( - col1 ) + CAST( NULL AS SIGNED ) / + col1 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4332
SELECT ( - col1 ) + CAST ( NULL AS INTEGER ) / + col1 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + 62 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

query I rowsort
SELECT - + 33 + - col1 FROM tab1 AS cor0
----
-43
-46
-59

query I rowsort
SELECT DISTINCT + 92 * - col1 + + cor0.col1 FROM tab0 AS cor0
----
-7826
-8281
-8827

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( + cor0.col1 ) * col0 col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - 61 FROM tab1, tab0 AS cor0
----
9 values hashing to 51f53697966a79d306a4570537cd91a1

query I rowsort
SELECT + col2 * col1 + - col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT ALL - col1 - - col0 AS col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT 28 * tab2.col2 AS col2 FROM tab2
----
1064
728
756

query I rowsort
SELECT 81 AS col2 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * 82 col2 FROM tab0 AS cor0
----
-7052
-7462
-7954

query I rowsort
SELECT + - col2 + ( 40 ) * col2 FROM tab2 cor0
----
1014
1053
1482

query I rowsort
SELECT ALL col0 * + 13 FROM tab2 AS cor0
----
1014
1027
91

query I rowsort
SELECT ALL - col1 + col2 * col1 * col2 FROM tab1 AS cor0
----
119795
32480
75790

query I rowsort
SELECT - + col1 + ( + 94 ) AS col2 FROM tab0 AS cor0
----
-3
3
8

query I rowsort
SELECT + + 90 + col2 FROM tab2 AS cor0
----
116
117
128

query I rowsort
SELECT ALL - 56 * 45 + - col1 * col1 FROM tab2 cor0
----
-2809
-3481
-6001

query I rowsort
SELECT DISTINCT + 43 * col0 AS col0 FROM tab2 AS cor0
----
301
3354
3397

query I rowsort
SELECT DISTINCT + + col1 * + 67 + col2 * - col0 FROM tab2 cor0
----
-1863
1888
1925

query I rowsort
SELECT ALL + col0 - 63 AS col0 FROM tab2 AS cor0
----
-56
15
16

query I rowsort
SELECT + - col2 * col2 + cor0.col0 AS col1 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT ALL ( + cor0.col2 ) + col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + + 89 * + cor0.col1 - - col1 * 59 FROM tab2 AS cor0
----
2516
4588
8732

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4355
SELECT DISTINCT - CAST( NULL AS SIGNED ) - - 33 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4355
SELECT DISTINCT - CAST ( NULL AS INTEGER ) - - 33 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + 95 + col1 * - col0 AS col2 FROM tab1 AS cor0
----
-545
-945
17

query I rowsort
SELECT - col0 - - 0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT 90 + col1 AS col0 FROM tab1 AS cor0
----
100
103
116

query I rowsort
SELECT DISTINCT col0 * - col1 - col0 * + ( + col1 ) FROM tab0 AS cor0
----
-16198
-4128
-6790

query I rowsort
SELECT - col2 + col1 * - 89 AS col0 FROM tab0 AS cor0
----
-7687
-8181
-8634

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0, tab1 cor1, tab2 AS cor2
----
972 values hashing to 49c8bf3e931a898ba7af63d0e377eb79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4362
SELECT ALL cor0.col0 DIV - col1 + - col1 AS col1 FROM tab2 AS cor0
----
-21
-31
-60

skipif mysql # not compatible
query I rowsort label-4362
SELECT ALL cor0.col0 / - col1 + - col1 AS col1 FROM tab2 AS cor0
----
-21
-31
-60

query I rowsort
SELECT + 66 FROM tab2, tab0 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

onlyif mysql # use DIV operator for integer division
query I rowsort label-4364
SELECT DISTINCT col2 DIV + ( + tab2.col0 + col0 * col2 ) AS col0 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-4364
SELECT DISTINCT col2 / + ( + tab2.col0 + col0 * col2 ) AS col0 FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4365
SELECT ALL col1 DIV - ( - ( + col1 ) ) AS col1 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4365
SELECT ALL col1 / - ( - ( + col1 ) ) AS col1 FROM tab2
----
1
1
1

query I rowsort
SELECT 21 - ( - col2 ) FROM tab2 AS cor0
----
47
48
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-4367
SELECT col1 * + ( + col2 ) + + col1 DIV - col2 + col1 * col1 * - col1 col2 FROM tab1 AS cor0
----
-16172
-430
-949

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4367
SELECT col1 * + ( + col2 ) + + col1 / - col2 + col1 * col1 * - col1 col2 FROM tab1 AS cor0
----
-16172
-430
-949

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * ( col0 * 43 ) + 37 * - col1 + col1 col0 FROM tab0 cor0
----
-1987
30960
310538

query I rowsort
SELECT + + col2 + - 95 + col0 * - col2 AS col2 FROM tab0 cor0
----
-129
-7311
-854

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4370
SELECT ALL col1 + 38 - + col2 / CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4370
SELECT ALL col1 + 38 - + col2 / CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - - col2 * col2 + + col0 * col0 FROM tab1 AS cor0
----
15616
2925
7345

query I rowsort
SELECT ALL col0 * col1 + - cor0.col1 * col1 * col1 FROM tab0 AS cor0
----
-633992
-745472
-909278

query I rowsort
SELECT ALL cor0.col2 * 99 AS col2 FROM tab1 AS cor0
----
5346
5643
9504

query I rowsort
SELECT col0 + col2 * col0 * + 39 AS col2 FROM tab0 AS cor0
----
1400
284711
30912

query I rowsort
SELECT - col0 * col0 * col0 FROM tab1 AS cor0
----
-262144
-27
-512000

onlyif mysql # use DIV operator for integer division
query I rowsort label-4376
SELECT col0 * + col0 + + cor0.col1 DIV col1 + + col2 AS col1 FROM tab0 AS cor0
----
1227
610
8004

skipif mysql # not compatible
query I rowsort label-4376
SELECT col0 * + col0 + + cor0.col1 / col1 + + col2 AS col1 FROM tab0 AS cor0
----
1227
610
8004

query I rowsort
SELECT DISTINCT col2 * 78 FROM tab2 AS cor0
----
2028
2106
2964

query I rowsort
SELECT + 59 * ( - col1 ) FROM tab1 AS cor0
----
-1534
-590
-767

query I rowsort
SELECT - + 64 * col0 + - col0 FROM tab0 cor0
----
-1560
-2275
-5785

onlyif mysql # use DIV operator for integer division
query I rowsort label-4380
SELECT - col1 + - cor0.col2 DIV col1 col1 FROM tab1 AS cor0
----
-15
-20
-28

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4380
SELECT - col1 + - cor0.col2 / col1 col1 FROM tab1 AS cor0
----
-15
-20
-28

onlyif mysql # use DIV operator for integer division
query I rowsort label-4381
SELECT 50 + + col0 DIV + col1 AS col0 FROM tab1 AS cor0
----
50
56
56

skipif mysql # not compatible
query I rowsort label-4381
SELECT 50 + + col0 / + col1 AS col0 FROM tab1 AS cor0
----
50
56
56

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4382
SELECT cor0.col1 * + CAST( 43 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
1333
2537
731

skipif mysql # not compatible
query I rowsort label-4382
SELECT cor0.col1 * + CAST ( 43 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
1333
2537
731

query I rowsort
SELECT DISTINCT + col0 * + ( col1 ) * - col2 + col0 * + col0 FROM tab2 AS cor0
----
-113568
-44793
-5810

query I rowsort
SELECT ALL + - col1 + - cor0.col0 * 82 FROM tab1 AS cor0
----
-272
-5258
-6573

onlyif mysql # use DIV operator for integer division
query I rowsort label-4385
SELECT ALL - col0 DIV - col1 + cor0.col2 FROM tab2 AS cor0
----
27
27
42

skipif mysql # not compatible
query I rowsort label-4385
SELECT ALL - col0 / - col1 + cor0.col2 FROM tab2 AS cor0
----
27
27
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-4386
SELECT + col0 DIV 98 + - col0 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-4386
SELECT + col0 / 98 + - col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + col0 * + ( cor0.col1 ) + - col0 * cor0.col2 FROM tab1 AS cor0
----
-3008
-6640
-84

query I rowsort
SELECT - + col1 + - 65 AS col0 FROM tab0 AS cor0
----
-151
-156
-162

query I rowsort
SELECT DISTINCT - 17 * - col2 FROM tab0
----
1394
17
561

onlyif mysql # use DIV operator for integer division
query I rowsort label-4390
SELECT DISTINCT - col0 DIV 9 + ( + col1 ) AS col2 FROM tab1 AS cor0
----
26
3
5

skipif mysql # not compatible
query I rowsort label-4390
SELECT DISTINCT - col0 / 9 + ( + col1 ) AS col2 FROM tab1 AS cor0
----
26
3
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4391
SELECT ALL + col2 DIV 26 FROM tab0 AS cor0
----
0
1
3

skipif mysql # not compatible
query I rowsort label-4391
SELECT ALL + col2 / 26 FROM tab0 AS cor0
----
0
1
3

query I rowsort
SELECT ALL + + cor0.col1 - + ( + cor0.col1 ) AS col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT cor0.col0 * + ( col0 ) * col0 + - cor0.col0 FROM tab2 AS cor0
----
336
474474
492960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4394
SELECT + col2 + - CAST( col1 AS SIGNED ) * - col0 AS col2 FROM tab2
----
1381
244
4628

skipif mysql # not compatible
query I rowsort label-4394
SELECT + col2 + - CAST ( col1 AS INTEGER ) * - col0 AS col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT + col0 + + 84 * + ( col1 ) * col2 FROM tab0
----
238416
626897
8183

query I rowsort
SELECT ALL + + col1 * - col1 + col2 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT ALL + col1 * 31 FROM tab1
----
310
403
806

query I rowsort
SELECT ALL - col1 + 12 * col0 - col2 AS col1 FROM tab1
----
-44
701
851

query I rowsort
SELECT ALL + tab2.col0 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT - ( col0 ) * col1 * col0 FROM tab1
----
-234
-40960
-83200

query I rowsort
SELECT DISTINCT + 55 AS col1 FROM tab0, tab0 cor0
----
55

query I rowsort
SELECT DISTINCT - col1 * - tab1.col0 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT col0 + + col0 * 2 FROM tab2
----
21
234
237

query I rowsort
SELECT - + ( cor0.col0 ) * col2 + - 85 + col1 * col0 FROM tab1 AS cor0
----
-169
-3093
-6725

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4405
SELECT - CAST( NULL AS DECIMAL ) - + 52 col0 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4405
SELECT - CAST ( NULL AS REAL ) - + 52 col0 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL - - 81 * - 57 + cor0.col2 * + col0 AS col2 FROM tab0 AS cor0
----
-3825
-4582
2681

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( + 12 ) + col1 col0 FROM tab0 cor0
----
74
79
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 61 col0 FROM tab1 AS cor0
----
-61
-61
-61

query I rowsort
SELECT ALL - 47 * 7 FROM tab0 AS cor0
----
-329
-329
-329

query I rowsort
SELECT DISTINCT - cor0.col0 + col2 + cor0.col0 AS col0 FROM tab2 AS cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 53 + - cor0.col1 col0 FROM tab0 AS cor0
----
-33
-38
-44

query I rowsort
SELECT ALL + col0 + col0 * col1 * col0 + col2 * cor0.col0 AS col0 FROM tab0 AS cor0
----
118895
50352
728198

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4413
SELECT DISTINCT CAST( NULL AS SIGNED ) + ( col2 ) FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4413
SELECT DISTINCT CAST ( NULL AS INTEGER ) + ( col2 ) FROM tab1 cor0
----
NULL

query I rowsort
SELECT cor0.col1 * - 32 + - col1 * - col1 FROM tab0 AS cor0
----
4644
5369
6305

query I rowsort
SELECT ALL + + 6 + + col0 FROM tab1 AS cor0
----
70
86
9

query I rowsort
SELECT DISTINCT - col2 * - col0 * + cor0.col2 FROM tab1 cor0
----
207936
737280
8748

query I rowsort
SELECT ( col2 ) * 23 AS col0 FROM tab1 AS cor0
----
1242
1311
2208

query I rowsort
SELECT + tab0.col0 * + 85 + tab0.col0 AS col2 FROM tab0
----
2064
3010
7654

query I rowsort
SELECT ( col1 ) - col1 AS col0 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4420
SELECT DISTINCT + CAST( col0 AS SIGNED ) DIV col1 AS col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-4420
SELECT DISTINCT + CAST ( col0 AS INTEGER ) / col1 AS col1 FROM tab2
----
0
1
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-4421
SELECT col0 DIV col1 AS col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-4421
SELECT col0 / col1 AS col1 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT ALL - - col1 * + col0 - col2 AS col1 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT DISTINCT + - cor0.col1 + - col0 * col2 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT DISTINCT + col1 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT col0 + ( - cor0.col2 * col0 ) FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL + col0 + - cor0.col2 * ( col0 ) * + 16 AS col2 FROM tab0 AS cor0
----
-116679
-12648
-525

query I rowsort
SELECT ALL - tab0.col2 * ( tab0.col1 ) FROM tab0, tab0 AS cor0
----
9 values hashing to 86c8e75d83d283b29460c020ab5988af

query I rowsort
SELECT DISTINCT - - col2 * + cor0.col2 * 94 FROM tab2 AS cor0
----
135736
63544
68526

query I rowsort
SELECT + col0 - + col1 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT col1 + + 47 * col1 FROM tab2 AS cor0
----
1488
2832
816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4431
SELECT DISTINCT col1 * - CAST( + 54 AS SIGNED ) - + col2 col1 FROM tab0 AS cor0
----
-4677
-4996
-5239

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4431
SELECT DISTINCT col1 * - CAST ( + 54 AS INTEGER ) - + col2 col1 FROM tab0 AS cor0
----
-4677
-4996
-5239

query I rowsort
SELECT + + col0 - + 9 AS col0 FROM tab0 AS cor0
----
15
26
80

query I rowsort
SELECT ALL col0 + + 93 AS col1 FROM tab0 AS cor0
----
117
128
182

query I rowsort
SELECT DISTINCT tab2.col1 + + ( col0 ) AS col0 FROM tab2
----
137
38
96

query I rowsort
SELECT DISTINCT 67 * + 53 FROM tab1, tab2 AS cor0
----
3551

query I rowsort
SELECT col2 * ( tab0.col1 ) FROM tab0
----
2838
7462
97

query I rowsort
SELECT ALL + + col0 + + ( + col2 ) FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT 8 * col0 + col1 AS col2 FROM tab2 AS cor0
----
649
683
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4439
SELECT ALL - CAST( NULL AS SIGNED ) + col1 * cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4439
SELECT ALL - CAST ( NULL AS INTEGER ) + col1 * cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col0 * + col0 + col1 * - col2 + + col1 FROM tab0 AS cor0
----
-1225
-15292
-3328

query I rowsort
SELECT ALL col2 * 95 * col2 + col0 AS col0 FROM tab2
----
137259
64298
69262

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - 72 col0 FROM tab0
----
-39
-71
10

query I rowsort
SELECT ALL - col2 * + col0 * + ( col2 ) + + col0 AS col2 FROM tab2
----
-113997
-5096
-52650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4444
SELECT - 87 * 82 - - col1 * - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4444
SELECT - 87 * 82 - - col1 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * + 66 * + col1 FROM tab1
----
37620
82368
92664

query I rowsort
SELECT + 22 + 67 FROM tab2 AS cor0
----
89
89
89

query I rowsort
SELECT DISTINCT ( 88 ) * - col1 AS col2 FROM tab2
----
-1496
-2728
-5192

query I rowsort
SELECT DISTINCT 99 * 32 FROM tab2 cor0
----
3168

onlyif mysql # use DIV operator for integer division
query I rowsort label-4449
SELECT + + ( + 20 ) DIV col0 + + col1 * col2 FROM tab1 AS cor0
----
1248
1410
570

skipif mysql # not compatible
query I rowsort label-4449
SELECT + + ( + 20 ) / col0 + + col1 * col2 FROM tab1 AS cor0
----
1248
1410
570

query I rowsort
SELECT + - 98 * 63 + col0 AS col0 FROM tab0 AS cor0
----
-6085
-6139
-6150

query I rowsort
SELECT - cor0.col0 + 26 AS col1 FROM tab2 AS cor0
----
-52
-53
19

query I rowsort
SELECT DISTINCT col1 * - 14 + col1 FROM tab0 cor0
----
-1118
-1183
-1261

query I rowsort
SELECT - tab0.col2 * col2 AS col2 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT 86 * + col0 * col2 AS col0 FROM tab0
----
3010
627628
68112

query I rowsort
SELECT - 60 + col0 FROM tab0
----
-25
-36
29

query I rowsort
SELECT 76 * - col0 + col0 FROM tab2
----
-525
-5850
-5925

query I rowsort
SELECT + 24 + + tab1.col0 FROM tab1
----
104
27
88

query I rowsort
SELECT DISTINCT - 8 FROM tab0, tab2, tab2 AS cor0
----
-8

query I rowsort
SELECT - col2 * + col0 + ( 83 + col1 ) FROM tab1
----
-3555
-53
-7584

query I rowsort
SELECT ALL - 91 * + col0 AS col2 FROM tab1
----
-273
-5824
-7280

onlyif mysql # use DIV operator for integer division
query I rowsort label-4461
SELECT DISTINCT 67 DIV + tab2.col0 AS col2 FROM tab2
----
0
9

skipif mysql # not compatible
query I rowsort label-4461
SELECT DISTINCT 67 / + tab2.col0 AS col2 FROM tab2
----
0
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4462
SELECT DISTINCT - CAST( NULL AS SIGNED ) FROM tab2, tab2 AS cor0, tab1 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-4462
SELECT DISTINCT - CAST ( NULL AS INTEGER ) FROM tab2, tab2 AS cor0, tab1 AS cor1
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4463
SELECT + col2 DIV + col1 + col0 * col2 AS col2 FROM tab1 AS cor0
----
164
3653
7687

skipif mysql # not compatible
query I rowsort label-4463
SELECT + col2 / + col1 + col0 * col2 AS col2 FROM tab1 AS cor0
----
164
3653
7687

query I rowsort
SELECT - col2 * col0 + + col2 + col2 * ( - col0 ) FROM tab2 AS cor0
----
-351
-4030
-5966

query I rowsort
SELECT + col2 * - 74 AS col2 FROM tab2
----
-1924
-1998
-2812

query I rowsort
SELECT - tab2.col2 * 59 FROM tab2
----
-1534
-1593
-2242

query I rowsort
SELECT - cor0.col0 + cor0.col2 * col2 AS col1 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT ALL + col1 * + 72 FROM tab1 AS cor0
----
1872
720
936

query I rowsort
SELECT DISTINCT - - col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT + + col1 + - col1 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT col1 * + 32 FROM tab2 AS cor0
----
1888
544
992

query I rowsort
SELECT - - col0 * col1 - 68 * - col1 AS col1 FROM tab2 AS cor0
----
2325
2499
8614

query I rowsort
SELECT - col2 * ( + 45 ) * col2 AS col2 FROM tab1 AS cor0
----
-131220
-146205
-414720

query I rowsort
SELECT + col2 * + 23 FROM tab1 AS cor0
----
1242
1311
2208

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4475
SELECT - col2 * CAST( + col0 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-4475
SELECT - col2 * CAST ( + col0 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - 86 FROM tab0
----
-86
-86
-86

query I rowsort
SELECT ALL 82 * col0 * - col2 FROM tab1
----
-13284
-299136
-629760

onlyif mysql # use DIV operator for integer division
query I rowsort label-4478
SELECT DISTINCT 49 DIV - 27 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
-1

skipif mysql # not compatible
query I rowsort label-4478
SELECT DISTINCT 49 / - 27 AS col2 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
-1

query I rowsort
SELECT DISTINCT - 74 AS col1 FROM tab1, tab0, tab1 AS cor0
----
-74

query I rowsort
SELECT - - cor0.col1 + - cor0.col2 * + col2 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT + - col2 * 50 AS col1 FROM tab2 AS cor0
----
-1300
-1350
-1900

query I rowsort
SELECT - col0 FROM tab0 WHERE NOT NULL BETWEEN + col2 AND ( NULL )
----

query I rowsort
SELECT col1 + + col0 + col0 FROM tab1
----
138
173
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-4484
SELECT ALL - col2 * col2 DIV tab2.col1 AS col1 FROM tab2
----
-11
-23
-84

skipif mysql # not compatible
query I rowsort label-4484
SELECT ALL - col2 * col2 / tab2.col1 AS col1 FROM tab2
----
-11
-23
-84

query I rowsort
SELECT - tab2.col1 * - tab2.col1 * col0 FROM tab2 WHERE NULL NOT IN ( col2 )
----

query I rowsort
SELECT ALL - tab2.col2 + - col2 + col0 FROM tab2
----
-47
26
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-4487
SELECT - col1 DIV tab0.col1 AS col2 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4487
SELECT - col1 / tab0.col1 AS col2 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col1 + + col2 + - col2 AS col0 FROM tab0
----
86
91
97

query I rowsort
SELECT tab0.col2 * - col0 + + col0 AS col2 FROM tab0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT tab2.col1 AS col0 FROM tab2 WHERE + col0 >= ( NULL )
----

query I rowsort
SELECT DISTINCT - col1 + - col0 * - col2 + col2 * - col2 AS col1 FROM tab1
----
-1549
-2780
389

query I rowsort
SELECT - col2 * cor0.col2 * + col1 AS col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT - col1 + + col1 AS col2 FROM tab1 cor0
----
0
0
0

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( NULL ) BETWEEN NULL AND NULL
----

query I rowsort
SELECT + col0 - tab2.col1 * col2 FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT col2 + tab1.col2 * - col1 * + col0 AS col2 FROM tab1
----
-36423
-4158
-99744

query I rowsort
SELECT - + col1 * col1 * col0 + ( + col2 ) * col0 AS col0 FROM tab2 AS cor0
----
-19829
-269490
-6538

query I rowsort
SELECT + + col2 * - col0 + col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT 23 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

query I rowsort
SELECT col2 + tab0.col1 AS col1 FROM tab0
----
119
173
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4501
SELECT - 75 + col2 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4501
SELECT - 75 + col2 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 * - col0 AS col0 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT col2 * - col2 * ( col2 ) + + col1 FROM tab2 AS cor0
----
-17517
-19652
-54855

onlyif mysql # use DIV operator for integer division
query I rowsort label-4504
SELECT ALL - cor0.col0 * + col1 + - 62 * col1 DIV + col1 FROM tab1 AS cor0
----
-1102
-140
-702

skipif mysql # not compatible
query I rowsort label-4504
SELECT ALL - cor0.col0 * + col1 + - 62 * col1 / + col1 FROM tab1 AS cor0
----
-1102
-140
-702

query I rowsort
SELECT DISTINCT + + 47 * + col1 * - col0 - - cor0.col0 * - col1 FROM tab2 AS cor0
----
-10416
-220896
-64464

onlyif mysql # use DIV operator for integer division
query I rowsort label-4506
SELECT + col1 * + col1 + col2 DIV 91 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-4506
SELECT + col1 * + col1 + col2 / 91 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT 56 * + cor0.col0 FROM tab2 AS cor0
----
392
4368
4424

query I rowsort
SELECT DISTINCT col0 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + + 65 * col1 * cor0.col2 + col1 * + col2 col0 FROM tab1 AS cor0
----
37684
82448
92667

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4510
SELECT DISTINCT - - col0 + CAST( col2 AS SIGNED ) * col2 FROM tab0 AS cor0
----
1113
36
6813

skipif mysql # not compatible
query I rowsort label-4510
SELECT DISTINCT - - col0 + CAST ( col2 AS INTEGER ) * col2 FROM tab0 AS cor0
----
1113
36
6813

query I rowsort
SELECT + - col0 * 49 FROM tab0 cor0
----
-1176
-1715
-4361

query I rowsort
SELECT DISTINCT col2 * 58 AS col0 FROM tab2 cor0
----
1508
1566
2204

query I rowsort
SELECT - - 72 * - 45 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 55804156d124fe87ccba0e5acdf75b9d

query I rowsort
SELECT DISTINCT - tab2.col1 * ( - 95 ) AS col1 FROM tab2, tab2 AS cor0
----
1615
2945
5605

query I rowsort
SELECT - 91 - col1 FROM tab0 AS cor0
----
-177
-182
-188

query I rowsort
SELECT 41 * - col2 - + col2 AS col1 FROM tab0 AS cor0
----
-1386
-3444
-42

query I rowsort
SELECT + 9 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

query I rowsort
SELECT DISTINCT - col2 + col1 * col2 AS col2 FROM tab0 cor0
----
2805
7380
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col0 col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT 85 FROM tab0, tab0 cor0
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

onlyif mysql # use DIV operator for integer division
query I rowsort label-4521
SELECT 61 DIV - col2 FROM tab1
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4521
SELECT 61 / - col2 FROM tab1
----
-1
-1
0

query I rowsort
SELECT - 34 * col2 FROM tab2
----
-1292
-884
-918

query I rowsort
SELECT + col2 + + col0 * ( - col1 ) FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT col2 * col0 * + col1 AS col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT + 93 * 11 FROM tab1
----
1023
1023
1023

onlyif mysql # use DIV operator for integer division
query I rowsort label-4526
SELECT + col0 DIV - col1 AS col2 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-4526
SELECT + col0 / - col1 AS col2 FROM tab2
----
-1
-4
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4527
SELECT + + col2 + cor0.col1 DIV col0 FROM tab0 AS cor0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-4527
SELECT + + col2 + cor0.col1 / col0 FROM tab0 AS cor0
----
3
36
83

skipif mysql # not compatible
query I rowsort
SELECT CAST ( 12 AS REAL ) AS col2 FROM tab1
----
12
12
12

onlyif mysql # use DIV operator for integer division
query I rowsort label-4529
SELECT + col2 + col1 - col1 * 29 DIV col0 FROM tab2
----
-70
49
64

skipif mysql # not compatible
query I rowsort label-4529
SELECT + col2 + col1 - col1 * 29 / col0 FROM tab2
----
-70
49
64

query I rowsort
SELECT ALL ( - col0 ) - - col2 AS col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT DISTINCT 40 + + col1 FROM tab1
----
50
53
66

query I rowsort
SELECT DISTINCT col0 + col0 * col1 + col2 AS col1 FROM tab2
----
1460
251
4706

query I rowsort
SELECT DISTINCT + - 44 AS col0 FROM tab1 cor0
----
-44

query I rowsort
SELECT ALL - + col0 + + col1 + + col1 * + col1 FROM tab1 AS cor0
----
102
46
699

query I rowsort
SELECT ALL - + col0 + col2 * + col2 AS col1 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT DISTINCT + + 82 + col2 FROM tab0 AS cor0
----
115
164
83

query I rowsort
SELECT DISTINCT - - ( + col0 ) + - col2 * + col1 AS col1 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT + col1 * col0 * col0 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT DISTINCT + + col2 + - col2 * - col1 AS col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT 57 * + 96 FROM tab1
----
5472

onlyif mysql # use DIV operator for integer division
query I rowsort label-4541
SELECT CAST( + 59 AS SIGNED ) DIV + col0 + - col2 FROM tab1
----
-35
-57
-96

skipif mysql # not compatible
query I rowsort label-4541
SELECT CAST ( + 59 AS INTEGER ) / + col0 + - col2 FROM tab1
----
-35
-57
-96

query I rowsort
SELECT + 45 + ( col2 ) FROM tab0 cor0
----
127
46
78

query I rowsort
SELECT 65 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

onlyif mysql # use DIV operator for integer division
query I rowsort label-4544
SELECT + ( 58 ) DIV + tab0.col0 + - tab0.col0 + col0 FROM tab0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-4544
SELECT + ( 58 ) / + tab0.col0 + - tab0.col0 + col0 FROM tab0
----
0
1
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-4545
SELECT + ( col1 * col1 ) + + col0 + + col1 DIV + col0 col0 FROM tab2
----
3559
368
972

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4545
SELECT + ( col1 * col1 ) + + col0 + + col1 / + col0 col0 FROM tab2
----
3559
368
972

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col1 ) col2 FROM tab0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4547
SELECT - col1 DIV + col1 + + col0 AS col0 FROM tab2
----
6
77
78

skipif mysql # not compatible
query I rowsort label-4547
SELECT - col1 / + col1 + + col0 AS col0 FROM tab2
----
6
77
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4548
SELECT ALL - col1 DIV col0 - + col2 * col1 AS col1 FROM tab0 AS cor0
----
-2841
-7463
-99

skipif mysql # not compatible
query I rowsort label-4548
SELECT ALL - col1 / col0 - + col2 * col1 AS col1 FROM tab0 AS cor0
----
-2841
-7463
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col0 + col2 * col1 + col1 * col0 col2 FROM tab1 AS cor0
----
1274
1485
2368

query I rowsort
SELECT DISTINCT - ( + col0 ) * col1 - + col0 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT DISTINCT + col0 + + 92 AS col1 FROM tab1 AS cor0
----
156
172
95

query I rowsort
SELECT + - 71 AS col2 FROM tab0 AS cor0
----
-71
-71
-71

query I rowsort
SELECT - ( ( col2 ) ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + - ( col1 ) * + col2 + - col2 + + col2 * + col0 * + col0 FROM tab0 AS cor0
----
1127
16137
641978

query I rowsort
SELECT ALL - 85 * + col0 + col1 AS col1 FROM tab1 AS cor0
----
-229
-5430
-6787

query I rowsort
SELECT ALL col0 * + col1 * cor0.col1 AS col2 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT - ( - col2 ) + col0 - + col2 * col2 FROM tab2 AS cor0
----
-1327
-572
-695

onlyif mysql # use DIV operator for integer division
query I rowsort label-4558
SELECT DISTINCT + - 33 + col0 DIV col1 + col1 FROM tab1 cor0
----
-14
-17
-7

skipif mysql # not compatible
query I rowsort label-4558
SELECT DISTINCT + - 33 + col0 / col1 + col1 FROM tab1 cor0
----
-14
-17
-7

query I rowsort
SELECT + 60 * - col1 + col1 - col0 * - col2 FROM tab0 AS cor0
----
-4282
-5688
1929

query I rowsort
SELECT DISTINCT - col1 * col2 + col1 AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT DISTINCT + + col0 + col0 * col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT + ( col0 ) * col1 * + col1 + col1 AS col0 FROM tab0 AS cor0
----
177590
329412
737100

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 + + cor0.col2 * col1 col0 FROM tab0 cor0
----
194
2924
7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4564
SELECT DISTINCT - CAST( col1 AS SIGNED ) - col1 * - col2 AS col2 FROM tab2
----
1475
629
806

skipif mysql # not compatible
query I rowsort label-4564
SELECT DISTINCT - CAST ( col1 AS INTEGER ) - col1 * - col2 AS col2 FROM tab2
----
1475
629
806

query I rowsort
SELECT DISTINCT + ( col1 ) * + col2 * + col2 - col0 * - col2 AS col0 FROM tab2
----
22788
27550
41912

onlyif mysql # use DIV operator for integer division
query I rowsort label-4566
SELECT ALL col0 DIV - col0 - + col2 * col1 FROM tab0
----
-2839
-7463
-98

skipif mysql # not compatible
query I rowsort label-4566
SELECT ALL col0 / - col0 - + col2 * col1 FROM tab0
----
-2839
-7463
-98

query I rowsort
SELECT - - 4 + - cor0.col2 + col1 FROM tab2 AS cor0
----
-17
37
8

query I rowsort
SELECT - 38 * - col0 - + col1 AS col2 FROM tab1 AS cor0
----
2422
3027
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 7 col1 FROM tab0
----
7
7
7

query I rowsort
SELECT ALL col0 + + cor0.col0 + + col1 FROM tab1 AS cor0
----
138
173
32

query I rowsort
SELECT ALL col0 * col1 + col0 FROM tab2 AS cor0
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4572
SELECT col2 DIV + col1 + col2 FROM tab2 AS cor0
----
26
27
40

skipif mysql # not compatible
query I rowsort label-4572
SELECT col2 / + col1 + col2 FROM tab2 AS cor0
----
26
27
40

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + - col1 + col2 col1 FROM tab2 AS cor0
----
-7
23
59

query I rowsort
SELECT col2 + + col1 * col2 AS col0 FROM tab0
----
2871
7544
98

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NOT + col1 * + col0 <= ( NULL )
----

query III rowsort
SELECT ALL * FROM tab1 AS cor0 WHERE NOT NULL IN ( + col1 * + col2 * + col2 )
----

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL IN ( - tab0.col0 + + col0 )
----

query I rowsort
SELECT col2 * + col2 * col2 FROM tab1
----
157464
185193
884736

onlyif mysql # use DIV operator for integer division
query I rowsort label-4579
SELECT + col0 DIV - col2 + - col1 * - tab1.col2 AS col2 FROM tab1
----
1248
1404
569

skipif mysql # not compatible
query I rowsort label-4579
SELECT + col0 / - col2 + - col1 * - tab1.col2 AS col2 FROM tab1
----
1248
1404
569

onlyif mysql # use DIV operator for integer division
query I rowsort label-4580
SELECT DISTINCT + col1 DIV + col0 + - col2 * col1 + + col1 AS col2 FROM tab0
----
-2749
-7370
2

skipif mysql # not compatible
query I rowsort label-4580
SELECT DISTINCT + col1 / + col0 + - col2 * col1 + + col1 AS col2 FROM tab0
----
-2749
-7370
2

query III rowsort
SELECT * FROM tab1 WHERE - col1 + col1 * col1 * col1 <= ( + col2 * - col0 + col1 + - col1 * tab1.col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4582
SELECT ALL - col0 + col1 DIV col0 FROM tab0
----
-21
-33
-88

skipif mysql # not compatible
query I rowsort label-4582
SELECT ALL - col0 + col1 / col0 FROM tab0
----
-21
-33
-88

query III rowsort
SELECT * FROM tab2 WHERE NOT - col1 * + col0 + - col1 IN ( col0 + + col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-4584
SELECT - col0 DIV col0 + + col2 col2 FROM tab2
----
25
26
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4584
SELECT - col0 / col0 + + col2 col2 FROM tab2
----
25
26
37

query I rowsort
SELECT DISTINCT - col0 * col1 * - col0 FROM tab1
----
234
40960
83200

query I rowsort
SELECT ALL + col0 * - col1 - tab2.col0 FROM tab2 WHERE NOT col2 * + col1 + col1 * col1 <= NULL
----

query I rowsort
SELECT + tab0.col2 * - col1 * - col2 FROM tab0
----
611884
93654
97

query I rowsort
SELECT ALL + col0 * tab2.col2 FROM tab2 WHERE NULL NOT IN ( + col0 )
----

query I rowsort
SELECT + tab0.col2 AS col1 FROM tab0 WHERE col0 + + col0 * col0 <= NULL
----

query I rowsort
SELECT - col1 * col1 + tab0.col1 AS col0 FROM tab0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT col1 - + tab0.col2 * col2 FROM tab0
----
-1003
-6633
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * + col0 + + col1 col1 FROM tab2
----
1360
248
4661

query I rowsort
SELECT - col1 * + col2 + - col1 FROM tab1
----
-1261
-1430
-580

onlyif mysql # use DIV operator for integer division
query I rowsort label-4594
SELECT DISTINCT - col0 DIV + col1 + - col2 * + col0 FROM tab0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-4594
SELECT DISTINCT - col0 / + col1 + - col2 * + col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ALL - col1 + col0 * + col1 FROM tab2 cor0
----
1326
186
4543

query I rowsort
SELECT ALL col2 + + col0 * col0 AS col1 FROM tab0 AS cor0 WHERE NOT NULL IN ( + col0 ) OR ( col2 + - col0 / + col0 + + col0 * col0 ) IN ( - col0 * col2 * + col2 )
----

query I rowsort
SELECT ALL + col0 * col1 * - col0 FROM tab1
----
-234
-40960
-83200

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL < NULL AND ( NULL ) < ( - col2 )
----

query I rowsort
SELECT ALL - tab2.col2 * + tab2.col0 AS col1 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT + col2 * col0 * + col0 FROM tab1 cor0
----
233472
486
614400

query I rowsort
SELECT DISTINCT + - col1 * col2 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL 38 FROM tab1, tab0 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT - 55 FROM tab0, tab1 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to 037c686cf473a7e2cc59ce6c19d8dc57

query I rowsort
SELECT ALL - + 63 + 88 AS col2 FROM tab2 AS cor0
----
25
25
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-4605
SELECT ALL + col1 + col1 DIV - col0 AS col1 FROM tab0 cor0
----
83
90
95

skipif mysql # not compatible
query I rowsort label-4605
SELECT ALL + col1 + col1 / - col0 AS col1 FROM tab0 cor0
----
83
90
95

query I rowsort
SELECT + col0 * 34 FROM tab0
----
1190
3026
816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 64 + col1 col0 FROM tab1 AS cor0
----
74
77
90

query I rowsort
SELECT ALL - 44 AS col1 FROM tab1 AS cor0
----
-44
-44
-44

query I rowsort
SELECT DISTINCT + col1 + col0 AS col1 FROM tab2 cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4610
SELECT ALL ( col1 ) + - cor0.col0 DIV + 76 AS col1 FROM tab0 AS cor0
----
86
90
97

skipif mysql # not compatible
query I rowsort label-4610
SELECT ALL ( col1 ) + - cor0.col0 / + 76 AS col1 FROM tab0 AS cor0
----
86
90
97

query I rowsort
SELECT tab1.col1 * col0 * col2 FROM tab1
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4612
SELECT ALL 6 DIV - 46 + col0 FROM tab2
----
7
78
79

skipif mysql # not compatible
query I rowsort label-4612
SELECT ALL 6 / - 46 + col0 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT col2 + + 74 FROM tab0
----
107
156
75

query I rowsort
SELECT DISTINCT - ( tab1.col2 + col2 ) AS col1 FROM tab1
----
-108
-114
-192

query I rowsort
SELECT - 64 * col0 * + col1 FROM tab0
----
-132096
-217280
-518336

query I rowsort
SELECT - col0 - 13 * col0 FROM tab1
----
-1120
-42
-896

query I rowsort
SELECT col1 * 90 + + cor0.col1 FROM tab2 AS cor0
----
1547
2821
5369

query I rowsort
SELECT DISTINCT 40 + + col2 FROM tab2
----
66
67
78

query I rowsort
SELECT - col2 + + col1 AS col2 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT cor0.col0 * 61 + - col0 AS col2 FROM tab0 AS cor0
----
1440
2100
5340

query I rowsort
SELECT DISTINCT + tab0.col2 * tab0.col0 AS col1 FROM tab0, tab1, tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL 78 * + col2 * - tab2.col0 AS col0 FROM tab2
----
-14742
-158184
-234156

query I rowsort
SELECT ALL + 14 * - col0 AS col1 FROM tab0
----
-1246
-336
-490

query I rowsort
SELECT DISTINCT 30 AS col0 FROM tab2, tab0, tab2 AS cor0
----
30

query I rowsort
SELECT + col1 * ( + col2 ) AS col2 FROM tab1
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 91 col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 6ec4feac5c635ab8e5da71006896acab

query I rowsort
SELECT tab2.col2 * col0 * + col0 FROM tab2
----
1323
158184
237158

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab2, tab1 cor2
----
3645 values hashing to 40a052eaf1d698dbf3ba319dc3e245ee

query I rowsort
SELECT + col1 + + ( cor0.col0 ) * + col2 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT col0 * col1 - - col0 AS col2 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT col2 * - ( + col1 ) + + col1 * 90 AS col1 FROM tab2
----
1953
3776
884

onlyif mysql # use DIV operator for integer division
query I rowsort label-4632
SELECT 49 DIV cor0.col2 + + col0 + + 7 * + col0 FROM tab0 AS cor0
----
193
329
712

skipif mysql # not compatible
query I rowsort label-4632
SELECT 49 / cor0.col2 + + col0 + + 7 * + col0 FROM tab0 AS cor0
----
193
329
712

query I rowsort
SELECT DISTINCT cor0.col0 + + 81 AS col2 FROM tab1, tab2 AS cor0
----
159
160
88

query I rowsort
SELECT + tab2.col1 * 80 * col1 AS col0 FROM tab2
----
23120
278480
76880

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4635
SELECT ALL + col2 * CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4635
SELECT ALL + col2 * CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4636
SELECT DISTINCT + col0 * CAST( - col2 AS SIGNED ) AS col1 FROM tab2
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-4636
SELECT DISTINCT + col0 * CAST ( - col2 AS INTEGER ) AS col1 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT - col1 + + col0 * 45 AS col1 FROM tab0
----
1478
3914
994

query I rowsort
SELECT + 29 AS col2 FROM tab0, tab2, tab2 AS cor0, tab1 AS cor1
----
81 values hashing to 40739d223aa019bd2dfe2db99d596302

query I rowsort
SELECT + tab2.col0 * - col2 * + col2 FROM tab2
----
-114076
-5103
-52728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col0 + - tab0.col2 + col1 col2 FROM tab0
----
2117
3491
8108

query I rowsort
SELECT + 80 + - col0 AS col1 FROM tab2 AS cor0
----
1
2
73

query I rowsort
SELECT 10 * 11 + col0 FROM tab0 AS cor0
----
134
145
199

query I rowsort
SELECT DISTINCT ( 35 ) * col2 - + 56 * - 29 AS col2 FROM tab2 AS cor0
----
2534
2569
2954

query I rowsort
SELECT ALL + 16 AS col1 FROM tab2 AS cor0
----
16
16
16

query I rowsort
SELECT ALL - ( ( col1 ) ) FROM tab1 cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-4646
SELECT - cor0.col1 * + ( col1 ) DIV col1 + - col0 FROM tab2 AS cor0
----
-137
-38
-96

skipif mysql # not compatible
query I rowsort label-4646
SELECT - cor0.col1 * + ( col1 ) / col1 + - col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT - 59 * col1 + col2 FROM tab0 AS cor0
----
-5041
-5287
-5722

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( 88 ) col1 FROM tab0 AS cor0
----
-88

query I rowsort
SELECT - - col1 - 66 AS col0 FROM tab2 AS cor0
----
-35
-49
-7

query I rowsort
SELECT DISTINCT + 80 * cor0.col1 FROM tab2 AS cor0
----
1360
2480
4720

query I rowsort
SELECT - 87 * col1 - col0 FROM tab2 AS cor0
----
-1558
-2704
-5211

query I rowsort
SELECT DISTINCT + col0 + - col1 * col2 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT - - col0 + + col1 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL ( + col1 ) * + col0 + col0 * + col0 AS col2 FROM tab2 AS cor0
----
10686
266
7584

query I rowsort
SELECT DISTINCT - ( col0 + + col2 ) FROM tab0
----
-171
-36
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 2 col2 FROM tab1 AS cor0
----
2
2
2

query I rowsort
SELECT ALL - + col2 + + cor0.col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 * col0 * col2 + + col2 + + col0 AS col2 FROM tab0 cor0
----
-3359
-663947
-68055

query I rowsort
SELECT + col2 * col1 + + ( + col0 ) * col2 FROM tab2 AS cor0
----
1026
3562
3648

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4660
SELECT DISTINCT - col1 + + CAST( NULL AS DECIMAL ) * col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4660
SELECT DISTINCT - col1 + + CAST ( NULL AS REAL ) * col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + col2 * + col0 * - cor0.col2 FROM tab2 AS cor0
----
-114076
-5103
-52728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 60 + cor0.col1 col1 FROM tab0, tab1 AS cor0
----
-34
-47
-50

query I rowsort
SELECT ALL + - col2 + 46 FROM tab1 AS cor0
----
-11
-50
-8

query I rowsort
SELECT + col0 + - ( 66 ) * col1 FROM tab0 AS cor0
----
-5652
-5917
-6367

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0, tab2 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to b223aa53e3aafe0f3f3f59048cc7a0d2

query I rowsort
SELECT - - col2 * 58 FROM tab0 AS cor0
----
1914
4756
58

query I rowsort
SELECT tab1.col0 - + col2 FROM tab1
----
-16
-51
7

query I rowsort
SELECT ALL + + col1 + - col0 + 88 AS col2 FROM tab0 AS cor0
----
150
150
90

query I rowsort
SELECT - - col2 + col2 * + ( + col0 ) AS col1 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL + 15 + - col0 FROM tab0 cor0
----
-20
-74
-9

query I rowsort
SELECT + - 22 FROM tab1 cor0
----
-22
-22
-22

query I rowsort
SELECT ALL - - 89 * - col0 + col1 FROM tab0 AS cor0
----
-2050
-3018
-7830

query I rowsort
SELECT DISTINCT + - col0 + + col1 * - 18 FROM tab2 AS cor0
----
-1140
-385
-565

query I rowsort
SELECT ALL - cor0.col0 * + col0 * - ( cor0.col0 ) FROM tab1 cor0
----
262144
27
512000

query I rowsort
SELECT DISTINCT - + 99 * col2 + ( + cor0.col0 ) * + col0 FROM tab2 AS cor0
----
-2624
2479
3510

query I rowsort
SELECT + + col1 - - col1 * col2 FROM tab1 AS cor0
----
1261
1430
580

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 7 col0 FROM tab2
----
-7
-7
-7

query I rowsort
SELECT col0 + - col2 * + col0 * - 55 FROM tab2
----
10402
111618
165189

query I rowsort
SELECT - 2 * - cor0.col1 * + col0 - - col1 AS col0 FROM tab2 cor0
----
2703
465
9263

query I rowsort
SELECT - 94 * col0 AS col1 FROM tab0 AS cor0
----
-2256
-3290
-8366

query I rowsort
SELECT + 82 * col2 FROM tab0
----
2706
6724
82

query I rowsort
SELECT + col1 + tab2.col1 * col1 AS col0 FROM tab2
----
306
3540
992

query I rowsort
SELECT DISTINCT + col2 * col0 + + col2 AS col2 FROM tab0 AS cor0
----
36
7380
825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 - col0 col0 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT ALL - - cor0.col1 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL col2 - - col0 AS col0 FROM tab1 AS cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 62 * col1 + col2 * col0 col2 FROM tab0 AS cor0
----
12940
6049
6124

query I rowsort
SELECT DISTINCT - 12 + col0 * - col1 FROM tab1 AS cor0
----
-1052
-652
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * - col1 col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT - col0 + + ( 74 ) AS col0 FROM tab2
----
-4
-5
67

query I rowsort
SELECT DISTINCT ( - col2 ) * col0 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - ( - col0 ) + + col0 FROM tab0
----
178
48
70

query I rowsort
SELECT ALL - - ( ( col0 ) ) + - ( 32 ) FROM tab0 cor0
----
-8
3
57

query I rowsort
SELECT DISTINCT + 65 * - cor0.col0 FROM tab0 AS cor0
----
-1560
-2275
-5785

query I rowsort
SELECT cor1.col1 AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT DISTINCT + ( col2 ) * col1 * + col1 AS col1 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT - ( col0 ) * col1 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + - col1 * + col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4699
SELECT ALL - + ( ( cor0.col1 ) ) * + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4699
SELECT ALL - + ( ( cor0.col1 ) ) * + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 69 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT DISTINCT - - 3 - col1 AS col0 FROM tab0 cor0
----
-83
-88
-94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4702
SELECT DISTINCT + + CAST( 45 AS SIGNED ) * + col0 FROM tab2 AS cor0
----
315
3510
3555

skipif mysql # not compatible
query I rowsort label-4702
SELECT DISTINCT + + CAST ( 45 AS INTEGER ) * + col0 FROM tab2 AS cor0
----
315
3510
3555

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4703
SELECT + - CAST( NULL AS DECIMAL ) * 76 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4703
SELECT + - CAST ( NULL AS REAL ) * 76 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 78 * + col0 + col2 FROM tab1 AS cor0
----
-180
-4935
-6144

query I rowsort
SELECT DISTINCT - ( - col1 ) * col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL - 74 * cor0.col0 + - col2 * - cor0.col0 FROM tab0 AS cor0
----
-2555
-984
712

query I rowsort
SELECT - - 3 * col1 AS col0 FROM tab0 AS cor0
----
258
273
291

onlyif mysql # use DIV operator for integer division
query I rowsort label-4708
SELECT - - 2 DIV - 61 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4708
SELECT - - 2 / - 61 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4709
SELECT - 12 + - col1 DIV - col1 FROM tab2 AS cor0
----
-11
-11
-11

skipif mysql # not compatible
query I rowsort label-4709
SELECT - 12 + - col1 / - col1 FROM tab2 AS cor0
----
-11
-11
-11

query I rowsort
SELECT DISTINCT + col0 + col0 * + col0 AS col1 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT ALL - tab0.col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT col0 + col1 * + 61 * 78 FROM tab2 cor0
----
147505
280800
80965

query I rowsort
SELECT + - col2 * + cor0.col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT 40 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4715
SELECT ALL col0 * + ( cor0.col2 ) + col2 * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4715
SELECT ALL col0 * + ( cor0.col2 ) + 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-4716
SELECT - col0 * CAST( NULL AS SIGNED ) + + col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4716
SELECT - col0 * CAST ( NULL AS INTEGER ) + + col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + col1 col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT col1 + col1 AS col0 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT + cor0.col2 * + col0 * + col0 FROM tab0 AS cor0
----
1225
19008
649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( + col1 ) * cor0.col0 col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + 21 AS col1 FROM tab2 AS cor0
----
21
21
21

query I rowsort
SELECT DISTINCT - 19 AS col2 FROM tab1, tab2 AS cor0
----
-19

onlyif mysql # use DIV operator for integer division
query I rowsort label-4723
SELECT DISTINCT col2 DIV + 67 AS col0 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-4723
SELECT DISTINCT col2 / + 67 AS col0 FROM tab0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + 24 col0 FROM tab1
----
-40
-56
21

query I rowsort
SELECT ALL col2 * + col0 * - tab1.col2 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT + 26 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 2d1c3129ed17fd721d4876b21c035584

onlyif mysql # use DIV operator for integer division
query I rowsort label-4727
SELECT DISTINCT 4 DIV + tab2.col1 - - col2 AS col2 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-4727
SELECT DISTINCT 4 / + tab2.col1 - - col2 AS col2 FROM tab2
----
26
27
38

query I rowsort
SELECT - - tab1.col1 AS col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + col1 - col1 * - col1 * 75 AS col2 FROM tab1 AS cor0
----
12688
50726
7510

query I rowsort
SELECT DISTINCT - 59 + col2 * - col0 * 13 - - col0 AS col2 FROM tab2
----
-2509
-26345
-39006

query I rowsort
SELECT - ( col1 ) - - 32 AS col1 FROM tab1
----
19
22
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-4732
SELECT col0 DIV + tab1.col1 + - 17 + tab1.col2 FROM tab1
----
37
46
85

skipif mysql # not compatible
query I rowsort label-4732
SELECT col0 / + tab1.col1 + - 17 + tab1.col2 FROM tab1
----
37
46
85

query I rowsort
SELECT DISTINCT - col0 * + tab0.col0 * + col0 - 66 * col2 FROM tab0
----
-16002
-42941
-710381

onlyif mysql # use DIV operator for integer division
query I rowsort label-4734
SELECT + 15 DIV cor0.col1 - col2 * + col1 AS col2 FROM tab1 AS cor0
----
-1247
-1404
-569

skipif mysql # not compatible
query I rowsort label-4734
SELECT + 15 / cor0.col1 - col2 * + col1 AS col2 FROM tab1 AS cor0
----
-1247
-1404
-569

query I rowsort
SELECT DISTINCT + col0 * + 72 AS col0 FROM tab1 AS cor0
----
216
4608
5760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * col0 * 91 col0 FROM tab0 AS cor0
----
111475
52416
720811

query I rowsort
SELECT DISTINCT + col0 * - 13 FROM tab2 AS cor0
----
-1014
-1027
-91

query I rowsort
SELECT - col2 + 80 * col2 FROM tab1 AS cor0
----
4266
4503
7584

query I rowsort
SELECT + col1 * ( 12 ) AS col2 FROM tab1 AS cor0
----
120
156
312

query I rowsort
SELECT col0 + + col1 * - 35 FROM tab1 cor0
----
-286
-375
-907

onlyif mysql # use DIV operator for integer division
query I rowsort label-4741
SELECT + cor0.col2 DIV + col0 col2 FROM tab1 AS cor0
----
0
1
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4741
SELECT + cor0.col2 / + col0 col2 FROM tab1 AS cor0
----
0
1
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-4742
SELECT ALL - col0 DIV - tab0.col2 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-4742
SELECT ALL - col0 / - tab0.col2 FROM tab0
----
0
1
35

query I rowsort
SELECT + - 17 AS col2 FROM tab0 AS cor0
----
-17
-17
-17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 65 col2 FROM tab0 AS cor0
----
65
65
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-4745
SELECT DISTINCT - 33 DIV col1 - - 77 FROM tab1 AS cor0
----
74
75
76

skipif mysql # not compatible
query I rowsort label-4745
SELECT DISTINCT - 33 / col1 - - 77 FROM tab1 AS cor0
----
74
75
76

query I rowsort
SELECT ALL 52 + ( tab1.col2 ) AS col0 FROM tab1
----
106
109
148

query I rowsort
SELECT DISTINCT col0 * - col0 + - col2 AS col1 FROM tab1 cor0
----
-4153
-63
-6496

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4748
SELECT ALL - 80 * + col0 + - ( col2 ) * col2 * - CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4748
SELECT ALL - 80 * + col0 + - ( col2 ) * col2 * - CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col1 * + col2 + 51 AS col2 FROM tab2 cor0
----
1585
697
888

query I rowsort
SELECT - 40 * cor0.col1 FROM tab0 AS cor0
----
-3440
-3640
-3880

query I rowsort
SELECT ALL - col0 * 72 * col0 FROM tab1
----
-294912
-460800
-648

query I rowsort
SELECT tab2.col2 - - 3 AS col0 FROM tab2
----
29
30
41

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 ALL 81 * cor0.col1 FROM tab2, tab1 AS cor0
----
9 values hashing to a41cb13b9f16fe898ec644a492963a64

query I rowsort
SELECT ( ( + col2 ) ) FROM tab0
----
1
33
82

query I rowsort
SELECT + 12 * - 7 AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 02f1688b8610806ca28739b1735f6ae4

query I rowsort
SELECT DISTINCT + tab2.col0 * + col0 AS col1 FROM tab2
----
49
6084
6241

query I rowsort
SELECT ALL + 0 - - col0 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 38 - 40 col0 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to ec11209ab257030053484fc13a1f6d17

query I rowsort
SELECT ALL col2 - col2 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT + col0 - col2 * tab2.col2 AS col2 FROM tab2
----
-1365
-598
-722

query I rowsort
SELECT - col1 + - col1 * - col1 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT ALL col2 * col1 + ( col1 ) AS col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT + 87 * col2 * - col1 AS col2 FROM tab2 AS cor0
----
-133458
-56202
-72819

query I rowsort
SELECT DISTINCT - 6 * col0 FROM tab0 cor0
----
-144
-210
-534

query I rowsort
SELECT - + 57 * col1 AS col2 FROM tab2 AS cor0
----
-1767
-3363
-969

query I rowsort
SELECT ALL + cor0.col0 + + col0 * + 79 AS col2 FROM tab2 AS cor0
----
560
6240
6320

query I rowsort
SELECT ALL tab1.col0 * - ( col1 + tab1.col1 ) FROM tab1
----
-1280
-156
-2080

query I rowsort
SELECT DISTINCT col1 + + col0 * 83 FROM tab0
----
2078
3002
7478

onlyif mysql # use DIV operator for integer division
query I rowsort label-4770
SELECT ALL tab0.col1 DIV - col2 FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-4770
SELECT ALL tab0.col1 / - col2 FROM tab0
----
-1
-2
-97

query I rowsort
SELECT ALL col2 * + col0 + 34 FROM tab1
----
196
3682
7714

query I rowsort
SELECT ALL 71 FROM tab2, tab1 cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT col0 * + 51 FROM tab1 AS cor0
----
153
3264
4080

query I rowsort
SELECT DISTINCT cor1.col0 AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
3
64
80

query I rowsort
SELECT DISTINCT - ( - col2 ) * col0 AS col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT 40 AS col1 FROM tab0 AS cor0
----
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-4777
SELECT + 41 DIV col0 AS col1 FROM tab2 cor0
----
0
0
5

skipif mysql # not compatible
query I rowsort label-4777
SELECT + 41 / col0 AS col1 FROM tab2 cor0
----
0
0
5

query I rowsort
SELECT - + col0 * col1 * + col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - col2 + 3 * cor0.col1 col0 FROM tab0 AS cor0
----
3096
388
7735

query I rowsort
SELECT + col2 * - 67 FROM tab1 AS cor0
----
-3618
-3819
-6432

query I rowsort
SELECT ALL + + col0 * 59 FROM tab0 AS cor0
----
1416
2065
5251

query I rowsort
SELECT ALL col0 + col2 * + col2 AS col2 FROM tab1 AS cor0
----
2919
3313
9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-4783
SELECT DISTINCT - col2 DIV col2 FROM tab1 cor0
----
-1

skipif mysql # not compatible
query I rowsort label-4783
SELECT DISTINCT - col2 / col2 FROM tab1 cor0
----
-1

skipif mysql # not compatible
query I rowsort
SELECT + - col0 * CAST ( col1 AS REAL ) AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - - col1 + + col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT + col0 + - col0 * - col2 AS col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT + - col1 * cor0.col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - - col1 + - ( col1 * col2 ) FROM tab2 AS cor0
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 ) + col1 col1 FROM tab1 AS cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col1 col2 FROM tab0 cor0
----
-86
-91
-97

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab2, tab2 AS cor1, tab1 AS cor2
----
972 values hashing to 4c46de5c1773124597e14f3b372fc4ea

onlyif mysql # use DIV operator for integer division
query I rowsort label-4792
SELECT + col0 DIV col1 - col1 AS col2 FROM tab1 AS cor0
----
-26
-4
-7

skipif mysql # not compatible
query I rowsort label-4792
SELECT + col0 / col1 - col1 AS col2 FROM tab1 AS cor0
----
-26
-4
-7

query I rowsort
SELECT - col1 * 48 FROM tab0 AS cor0
----
-4128
-4368
-4656

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 cor0, tab1 AS cor1, tab1 cor2
----
972 values hashing to fe55095fff3a5ecc2f113d14a8c6f823

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( + col0 ) + - ( + col2 ) col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT + ( col0 ) * col0 + - col2 * col2 FROM tab2 AS cor0
----
-680
4797
5408

query I rowsort
SELECT - 72 + + col2 FROM tab0 AS cor0
----
-39
-71
10

query I rowsort
SELECT DISTINCT + ( - cor0.col2 ) * col1 + col1 AS col0 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT - + col1 + + col2 * - 39 AS col2 FROM tab0 AS cor0
----
-136
-1373
-3289

query I rowsort
SELECT 36 + 38 - col0 * + col0 FROM tab1
----
-4022
-6326
65

query I rowsort
SELECT 48 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 0ef571a8722ab7270aa7272c1174b88e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4803
SELECT ALL ( tab2.col1 ) * - CAST( 77 AS SIGNED ) AS col1 FROM tab2
----
-1309
-2387
-4543

skipif mysql # not compatible
query I rowsort label-4803
SELECT ALL ( tab2.col1 ) * - CAST ( 77 AS INTEGER ) AS col1 FROM tab2
----
-1309
-2387
-4543

query I rowsort
SELECT + + col1 + - col0 * ( - col0 ) FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT DISTINCT - 7 * + col2 AS col2 FROM tab0 cor0
----
-231
-574
-7

query I rowsort
SELECT ALL 10 * col0 FROM tab0 AS cor0
----
240
350
890

query I rowsort
SELECT + - 58 * + col1 AS col0 FROM tab2 AS cor0
----
-1798
-3422
-986

onlyif mysql # use DIV operator for integer division
query I rowsort label-4808
SELECT ALL - 11 DIV - col1 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4808
SELECT ALL - 11 / - col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - 28 + - tab2.col0 AS col2 FROM tab2
----
-106
-107
-35

query I rowsort
SELECT 34 * - col2 AS col2 FROM tab0
----
-1122
-2788
-34

query I rowsort
SELECT cor0.col0 * 66 AS col1 FROM tab0, tab2 cor0, tab1 AS cor1
----
27 values hashing to 38b306b06ee8729d59bb73aea0d34abf

query I rowsort
SELECT DISTINCT + - 61 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
-61

query I rowsort
SELECT + 10 AS col0 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

query I rowsort
SELECT + - cor0.col1 + 94 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 41363ab004b1aa2ac9a58e8e8e1780d1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4815
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-4815
SELECT ALL + col1 + CAST ( NULL AS INTEGER ) + col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * - 7 FROM tab1 AS cor0
----
182
70
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4817
SELECT ALL CAST( NULL AS SIGNED ) * - 48 / + col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4817
SELECT ALL CAST ( NULL AS INTEGER ) * - 48 / + col0 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 91 * 17 col2 FROM tab2
----
1547
1547
1547

query I rowsort
SELECT DISTINCT 68 AS col1 FROM tab2, tab0 AS cor0
----
68

query I rowsort
SELECT + 94 + ( + col0 ) FROM tab2
----
101
172
173

onlyif mysql # use DIV operator for integer division
query I rowsort label-4821
SELECT DISTINCT + 64 + col0 DIV - col1 FROM tab0
----
64

skipif mysql # not compatible
query I rowsort label-4821
SELECT DISTINCT + 64 + col0 / - col1 FROM tab0
----
64

query I rowsort
SELECT ALL col1 * - col2 * + col0 AS col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT ALL 98 FROM tab2, tab0 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT ALL + + 60 + 21 * col0 * + col2 AS col0 FROM tab2 AS cor0
----
4029
42648
63102

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4825
SELECT - CAST( NULL AS SIGNED ) - + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4825
SELECT - CAST ( NULL AS INTEGER ) - + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col1 + - 61 + + cor0.col0 AS col0 FROM tab1 AS cor0
----
-32
13
32

query I rowsort
SELECT DISTINCT - + col0 * col0 + col2 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT ALL 86 * col1 FROM tab0
----
7396
7826
8342

onlyif mysql # use DIV operator for integer division
query I rowsort label-4829
SELECT DISTINCT col0 DIV + 7 FROM tab2 AS cor0
----
1
11

skipif mysql # not compatible
query I rowsort label-4829
SELECT DISTINCT col0 / + 7 FROM tab2 AS cor0
----
1
11

query I rowsort
SELECT ALL 67 * col0 + col1 AS col1 FROM tab2 AS cor0
----
500
5285
5310

query I rowsort
SELECT 71 * col1 + + col2 * - cor0.col2 + + col2 AS col1 FROM tab0 AS cor0
----
-181
5050
6887

query I rowsort
SELECT + + 4 + - cor0.col1 * 77 AS col0 FROM tab1 AS cor0
----
-1998
-766
-997

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 59 + - col1 col0 FROM tab1 AS cor0
----
33
46
49

query I rowsort
SELECT ALL + col1 - + tab0.col2 AS col2 FROM tab0
----
53
9
96

query III rowsort
SELECT * FROM tab0 WHERE ( NULL ) NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT + col2 + col2 * tab1.col2 AS col0 FROM tab1
----
2970
3306
9312

query I rowsort
SELECT ALL col1 * + col1 + col0 AS col2 FROM tab2
----
3559
368
968

query I rowsort
SELECT ALL 79 * - col0 FROM tab2 AS cor0
----
-553
-6162
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-4839
SELECT DISTINCT - ( - col1 ) DIV - ( col1 ) AS col2 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-4839
SELECT DISTINCT - ( - col1 ) / - ( col1 ) AS col2 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT - col1 * + tab1.col0 AS col2 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT - col1 FROM tab0 WHERE NOT col1 IN ( col1 * col2 )
----
-86
-91

query I rowsort
SELECT ALL + col1 + tab1.col0 AS col0 FROM tab1
----
29
74
93

query I rowsort
SELECT + col2 + + tab0.col0 + tab0.col0 AS col1 FROM tab0
----
260
71
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-4844
SELECT DISTINCT - col2 * col0 * - col2 - col0 DIV + col0 AS col2 FROM tab0
----
26135
34
598435

skipif mysql # not compatible
query I rowsort label-4844
SELECT DISTINCT - col2 * col0 * - col2 - col0 / + col0 AS col2 FROM tab0
----
26135
34
598435

query I rowsort
SELECT col1 + col2 * + 16 * - tab1.col2 + tab1.col0 FROM tab1
----
-147363
-46627
-51910

query I rowsort
SELECT ALL 88 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

onlyif mysql # use DIV operator for integer division
query I rowsort label-4847
SELECT DISTINCT 24 DIV - col0 - col2 AS col1 FROM tab2
----
-26
-30
-38

skipif mysql # not compatible
query I rowsort label-4847
SELECT DISTINCT 24 / - col0 - col2 AS col1 FROM tab2
----
-26
-30
-38

query I rowsort
SELECT DISTINCT col0 + - tab2.col1 - + col1 FROM tab2
----
-40
-55
45

query I rowsort
SELECT col2 + + col2 * - 75 FROM tab0 AS cor0
----
-2442
-6068
-74

query I rowsort
SELECT + - col1 - col1 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT DISTINCT tab0.col0 FROM tab0 WHERE NULL = col0
----

query I rowsort
SELECT + col1 - col2 * + col1 AS col0 FROM tab1
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-4853
SELECT + col0 DIV tab1.col2 AS col2 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-4853
SELECT + col0 / tab1.col2 AS col2 FROM tab1
----
0
0
1

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE NOT ( NULL ) NOT IN ( - col0 * col1 + col0 )
----

query I rowsort
SELECT col2 FROM tab1 AS cor0 WHERE ( NULL ) < ( NULL )
----

query III rowsort
SELECT DISTINCT * FROM tab1 cor0 WHERE NOT ( cor0.col2 ) NOT BETWEEN ( col0 ) AND + col2
----
3
26
54
80
13
96

query I rowsort
SELECT ALL + col2 * col1 + + tab2.col1 FROM tab2
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-4858
SELECT col0 - col2 DIV col1 AS col1 FROM tab1
----
1
59
73

skipif mysql # not compatible
query I rowsort label-4858
SELECT col0 - col2 / col1 AS col1 FROM tab1
----
1
59
73

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL = - col0
----

query I rowsort
SELECT + col2 + col0 - - col2 AS col1 FROM tab2
----
130
155
61

query I rowsort
SELECT col2 + - col2 - col1 AS col1 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT DISTINCT col1 * col0 + col1 * - col0 FROM tab1
----
0

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL IN ( col1 )
----

query I rowsort
SELECT ALL - tab2.col1 + + col0 AS col1 FROM tab2
----
-24
19
62

query III rowsort
SELECT * FROM tab2 WHERE NOT col2 NOT BETWEEN col1 AND - col1 * - col0 + + col2 / + col1
----
79
17
38

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( col0 ) >= NULL
----

query I rowsort
SELECT tab1.col2 AS col0 FROM tab1 WHERE - col2 * col1 >= ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * tab2.col2 col0 FROM tab2
----
189
2028
3002

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL <> NULL
----

query I rowsort
SELECT DISTINCT col2 + - col2 * - tab1.col0 * tab1.col2 AS col0 FROM tab1
----
207993
737376
8802

query I rowsort
SELECT ALL 21 * - col2 AS col1 FROM tab2 AS cor0
----
-546
-567
-798

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT 50 + - cor0.col2 * - 14 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to 10b47ed512febf603f6b50376ac03519

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( + 57 * - col1 AS REAL ) + - col1 FROM tab0
----
4816
5096
5432

query I rowsort
SELECT ALL + 91 AS col0 FROM tab1 AS cor0
----
91
91
91

query I rowsort
SELECT DISTINCT + cor0.col0 * - col1 + - col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT - - 47 * col1 AS col1 FROM tab1 AS cor0
----
1222
470
611

query I rowsort
SELECT ALL - - col2 + - col2 * col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT 52 * col2 + col1 * 47 FROM tab0 AS cor0
----
4611
5758
8541

query I rowsort
SELECT ALL + col1 * + col0 * 33 AS col0 FROM tab1 AS cor0
----
21120
2574
34320

onlyif mysql # use DIV operator for integer division
query I rowsort label-4881
SELECT DISTINCT + 51 DIV col0 + + 14 AS col0 FROM tab0 AS cor0
----
14
15
16

skipif mysql # not compatible
query I rowsort label-4881
SELECT DISTINCT + 51 / col0 + + 14 AS col0 FROM tab0 AS cor0
----
14
15
16

query I rowsort
SELECT ALL + col2 * col1 + col1 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-4883
SELECT ALL col0 DIV col0 AS col2 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4883
SELECT ALL col0 / col0 AS col2 FROM tab2 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4884
SELECT DISTINCT - col0 * col1 + col0 DIV + col2 AS col0 FROM tab0 AS cor0
----
-2064
-3360
-8098

skipif mysql # not compatible
query I rowsort label-4884
SELECT DISTINCT - col0 * col1 + col0 / + col2 AS col0 FROM tab0 AS cor0
----
-2064
-3360
-8098

query I rowsort
SELECT cor0.col2 AS col1 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT DISTINCT - col2 * - ( + col2 ) AS col2 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT DISTINCT - + col0 + - col1 + col2 FROM tab1 AS cor0
----
-17
25
3

query I rowsort
SELECT ALL + col1 + col2 * + col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT col0 + + ( + col2 ) AS col0 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4890
SELECT - col1 + - CAST( 92 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-178
-183
-189

skipif mysql # not compatible
query I rowsort label-4890
SELECT - col1 + - CAST ( 92 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-178
-183
-189

query I rowsort
SELECT ALL + + col0 * + ( - col0 ) + col1 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT - col2 + ( - col0 ) FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT ALL + - cor0.col2 + + col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + col0 + + 33 FROM tab0 cor0
----
-2
-56
9

query I rowsort
SELECT ALL - cor0.col0 * - col1 - col1 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-4896
SELECT + + col2 DIV + 9 + + col2 FROM tab0 AS cor0
----
1
36
91

skipif mysql # not compatible
query I rowsort label-4896
SELECT + + col2 / + 9 + + col2 FROM tab0 AS cor0
----
1
36
91

query I rowsort
SELECT + col1 * + 58 FROM tab1 cor0
----
1508
580
754

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4898
SELECT ALL - + col0 + CAST( ( col0 ) AS SIGNED ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4898
SELECT ALL - + col0 + CAST ( ( col0 ) AS INTEGER ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + ( tab2.col2 ) - col0 * - 98 FROM tab2
----
713
7670
7780

onlyif mysql # use DIV operator for integer division
query I rowsort label-4900
SELECT col2 DIV col1 + col0 + - col2 AS col1 FROM tab2
----
-20
43
52

skipif mysql # not compatible
query I rowsort label-4900
SELECT col2 / col1 + col0 + - col2 AS col1 FROM tab2
----
-20
43
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 14 * + col2 * - tab2.col0 + col2 * + col1 col0 FROM tab2
----
-1809
-26858
-41382

query I rowsort
SELECT ALL + 23 + 60 * - cor0.col1 FROM tab0, tab1 AS cor0, tab1 cor1
----
27 values hashing to 73902862b607f9d163528ab1ce30d99e

query I rowsort
SELECT - 25 * cor0.col2 AS col1 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 51d2d4bd3143efe21be977baee82802c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4904
SELECT col2 * - CAST( NULL AS SIGNED ) * - 63 + + col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4904
SELECT col2 * - CAST ( NULL AS INTEGER ) * - 63 + + col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * col2 * - ( col1 ) AS col0 FROM tab2
----
-119652
-51034
-5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-4906
SELECT ALL + col2 DIV col2 + - col1 AS col2 FROM tab0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-4906
SELECT ALL + col2 / col2 + - col1 AS col2 FROM tab0
----
-85
-90
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4907
SELECT col0 DIV - col2 + col0 DIV cor0.col1 FROM tab1 cor0
----
0
5
6

skipif mysql # not compatible
query I rowsort label-4907
SELECT col0 / - col2 + col0 / cor0.col1 FROM tab1 cor0
----
0
5
6

query I rowsort
SELECT col1 * col1 + col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT - col1 + - ( col1 + col2 ) AS col1 FROM tab0 AS cor0
----
-195
-205
-264

query I rowsort
SELECT col2 * - col1 + + col2 FROM tab1 cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT - tab0.col0 + col1 * col1 FROM tab0
----
7372
8192
9374

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2, tab0 cor2
----
3645 values hashing to 62086d53b7dd9376121857c3d03027d6

query I rowsort
SELECT + col1 * 42 * col2 + col0 FROM tab0
----
119220
313493
4109

query I rowsort
SELECT ALL 77 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT ALL 34 * + col1 AS col2 FROM tab1
----
340
442
884

query I rowsort
SELECT - col1 + - 16 AS col2 FROM tab0
----
-102
-107
-113

query I rowsort
SELECT - cor0.col0 * 9 AS col2 FROM tab2 AS cor0
----
-63
-702
-711

query I rowsort
SELECT DISTINCT + + 66 FROM tab0 AS cor0
----
66

query I rowsort
SELECT ALL - col1 * + 69 FROM tab1 AS cor0
----
-1794
-690
-897

query I rowsort
SELECT ALL - ( + 77 ) AS col2 FROM tab2
----
-77
-77
-77

query I rowsort
SELECT + 50 + + col0 FROM tab0
----
139
74
85

query I rowsort
SELECT + 57 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 82 col2 FROM tab0 AS cor0
----
-82
-82
-82

query I rowsort
SELECT ALL + + col2 + col1 AS col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL col2 * - col1 - - col1 AS col1 FROM tab0 cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL + 40 + - col0 AS col1 FROM tab2 AS cor0
----
-38
-39
33

query I rowsort
SELECT ALL ( - col1 * col0 ) AS col1 FROM tab1
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * cor0.col0 col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + ( + col1 ) AS col2 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT - cor0.col1 * - col0 AS col1 FROM tab1 cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col1 col0 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-4932
SELECT - - col1 DIV col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4932
SELECT - - col1 / col1 FROM tab2 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4933
SELECT DISTINCT col2 * 66 DIV col2 FROM tab1 cor0
----
66

skipif mysql # not compatible
query I rowsort label-4933
SELECT DISTINCT col2 * 66 / col2 FROM tab1 cor0
----
66

onlyif mysql # use DIV operator for integer division
query I rowsort label-4934
SELECT + + cor0.col2 + col2 + - 47 DIV - cor0.col1 FROM tab2 AS cor0
----
52
55
78

skipif mysql # not compatible
query I rowsort label-4934
SELECT + + cor0.col2 + col2 + - 47 / - cor0.col1 FROM tab2 AS cor0
----
52
55
78

query I rowsort
SELECT DISTINCT col1 + + col1 * col0 AS col2 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT - col2 * col0 + + col1 * col0 AS col0 FROM tab2 AS cor0
----
-1659
2574
28

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4937
SELECT ALL - col2 + CAST( NULL AS SIGNED ) * - 58 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4937
SELECT ALL - col2 + CAST ( NULL AS INTEGER ) * - 58 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + - col0 * col0 FROM tab2 cor0
----
-22
-6058
-6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-4939
SELECT ALL + - col0 + col2 DIV col0 + col1 col0 FROM tab2 cor0
----
-19
-62
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4939
SELECT ALL + - col0 + col2 / col0 + col1 col0 FROM tab2 cor0
----
-19
-62
27

query I rowsort
SELECT + col2 + - col0 * + ( col0 ) - - col0 * cor0.col0 AS col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - col0 + - 37 * + col1 FROM tab2 AS cor0
----
-1154
-2261
-708

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + - col0 * - cor0.col0 * - col2 - col2 col2 FROM tab2 cor0
----
-1319
-158151
-237179

query I rowsort
SELECT DISTINCT - col0 * + 46 + - 42 AS col1 FROM tab0 AS cor0
----
-1146
-1652
-4136

query I rowsort
SELECT DISTINCT col2 * ( + ( col1 ) + col0 ) AS col0 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT + col2 * 51 + + col1 FROM tab1 AS cor0
----
2780
2917
4909

onlyif mysql # use DIV operator for integer division
query I rowsort label-4946
SELECT col0 + - col2 DIV - col1 + - col1 DIV - col0 FROM tab1 cor0
----
13
69
87

skipif mysql # not compatible
query I rowsort label-4946
SELECT col0 + - col2 / - col1 + - col1 / - col0 FROM tab1 cor0
----
13
69
87

query I rowsort
SELECT 58 * + col0 * + col0 AS col0 FROM tab0 AS cor0
----
33408
459418
71050

query I rowsort
SELECT + + ( + col0 ) + - col1 * + col0 AS col1 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT ( - cor0.col2 ) * col1 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + ( col2 ) * cor0.col1 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + col0 * - col1 + 58 + + col0 FROM tab2
----
-1206
-152
-4466

query IIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab1, tab2 cor1
----
243 values hashing to ea21cea53be47edd19229592e3d26141

query I rowsort
SELECT tab1.col2 * 47 FROM tab1
----
2538
2679
4512

onlyif mysql # use DIV operator for integer division
query I rowsort label-4954
SELECT cor0.col0 DIV - 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-4954
SELECT cor0.col0 / - col1 col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * + col0 + - col0 col2 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT ALL col0 - + col1 * col0 FROM tab1
----
-576
-75
-960

query I rowsort
SELECT cor0.col2 * cor0.col1 - - col0 AS col0 FROM tab1 cor0
----
1328
1407
634

query I rowsort
SELECT - + col0 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-171
-36
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - col0 * col2 col0 FROM tab2
----
-162
-2002
-2964

onlyif mysql # use DIV operator for integer division
query I rowsort label-4960
SELECT + col0 DIV - col2 + + tab0.col0 + - col2 AS col2 FROM tab0
----
-1
-9
6

skipif mysql # not compatible
query I rowsort label-4960
SELECT + col0 / - col2 + + tab0.col0 + - col2 AS col2 FROM tab0
----
-1
-9
6

query III rowsort
SELECT ALL * FROM tab1 AS cor0 WHERE NULL NOT IN ( - col0 )
----

query I rowsort
SELECT DISTINCT col0 + col1 * - tab2.col1 * tab2.col2 AS col1 FROM tab2
----
-10903
-25940
-90428

query I rowsort
SELECT DISTINCT col0 + col2 * col0 FROM tab2
----
196
2106
3081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - col2 col0 FROM tab2 AS cor0
----
0

query IIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0 WHERE NOT ( NULL ) >= + cor0.col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4966
SELECT DISTINCT - col0 + col0 + col1 * cor0.col0 DIV - col2 AS col0 FROM tab1 AS cor0
----
-1
-10
-11

skipif mysql # not compatible
query I rowsort label-4966
SELECT DISTINCT - col0 + col0 + col1 * cor0.col0 / - col2 AS col0 FROM tab1 AS cor0
----
-1
-10
-11

query I rowsort
SELECT + col1 + cor0.col2 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - col2 + ( + 96 * col2 ) AS col2 FROM tab1 AS cor0
----
5130
5415
9120

query I rowsort
SELECT ALL + - col2 + + ( col1 * + col2 ) AS col0 FROM tab0 AS cor0
----
2805
7380
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 - col1 col0 FROM tab0 AS cor0
----
-110
-132
-180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + cor0.col1 + col2 col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT 32 AS col2 FROM tab2
----
32
32
32

query I rowsort
SELECT - 79 FROM tab0, tab1 AS cor0
----
9 values hashing to 1b7b0b34fe3431fb409719624d12791f

query I rowsort
SELECT + - col1 + - col0 AS col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT - cor0.col2 AS col0 FROM tab0, tab1 cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col1 AS REAL ) * + col0 FROM tab1
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4977
SELECT - cor0.col2 * col1 DIV - col1 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-4977
SELECT - cor0.col2 * col1 / - col1 col1 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-4978
SELECT + - ( col1 ) DIV col0 AS col2 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-4978
SELECT + - ( col1 ) / col0 AS col2 FROM tab1 AS cor0
----
-8
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4979
SELECT - col0 DIV 55 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4979
SELECT - col0 / 55 FROM tab0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col2 + + ( col0 ) col1 FROM tab2 AS cor0
----
-1456
-567
-830

onlyif mysql # use DIV operator for integer division
query I rowsort label-4981
SELECT 75 DIV + col1 + 60 col0 FROM tab0
----
60
60
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4981
SELECT 75 / + col1 + 60 col0 FROM tab0
----
60
60
60

query I rowsort
SELECT DISTINCT tab1.col0 * - tab1.col0 AS col0 FROM tab1, tab2 cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4983
SELECT - 22 DIV col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4983
SELECT - 22 / col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col0 + - cor0.col2 * + ( - col2 ) + - col0 * + 51 FROM tab1 AS cor0
----
2766
49
5216

query I rowsort
SELECT ALL + + col1 * - col0 + ( col0 ) FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT - col1 + col1 * col2 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT 96 + col2 FROM tab2 cor0
----
122
123
134

query I rowsort
SELECT - col1 * + col0 + - col0 AS col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT + 15 + col1 * - 29 AS col0 FROM tab0
----
-2479
-2624
-2798

query I rowsort
SELECT + col1 + col2 * 29 * col2 AS col2 FROM tab2
----
19663
21172
41893

query I rowsort
SELECT - 95 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to cf302b83f15b730fe35c19bdd9363c13

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0, tab1 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to 862fba9ac85fdf2cec88a0bec0808b7e

query I rowsort
SELECT ALL - + 64 + col0 FROM tab2 AS cor0
----
-57
14
15

query I rowsort
SELECT ALL + - 39 + cor0.col0 + - 26 FROM tab1 AS cor0
----
-1
-62
15

query I rowsort
SELECT DISTINCT + + col1 + - col2 AS col1 FROM tab2 cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT - col2 + - 59 * - col1 AS col1 FROM tab0 AS cor0
----
5041
5287
5722

query I rowsort
SELECT ALL - col1 * - ( cor0.col1 ) FROM tab1 cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * - cor0.col1 col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT - col0 * cor0.col2 FROM tab1 cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5000
SELECT + + col2 * - CAST( 80 + - col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-1551
-79
164

skipif mysql # not compatible
query I rowsort label-5000
SELECT + + col2 * - CAST ( 80 + - col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-1551
-79
164

query I rowsort
SELECT DISTINCT - col1 * - 52 AS col1 FROM tab2 AS cor0
----
1612
3068
884

query I rowsort
SELECT + col2 * 17 AS col1 FROM tab2 AS cor0
----
442
459
646

query I rowsort
SELECT ALL - + col1 * ( col2 ) + + col2 AS col2 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT ALL + col1 * + 50 AS col2 FROM tab2 AS cor0
----
1550
2950
850

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5005
SELECT ( col1 ) * CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5005
SELECT ( col1 ) * CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5006
SELECT DISTINCT col1 + col2 DIV 56 AS col1 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-5006
SELECT DISTINCT col1 + col2 / 56 AS col1 FROM tab2
----
17
31
59

query I rowsort
SELECT DISTINCT + col2 + col1 + 7 FROM tab0
----
105
126
180

query I rowsort
SELECT - cor0.col2 + col1 * - 54 FROM tab2 cor0
----
-1701
-3212
-956

query I rowsort
SELECT ALL col2 * ( - 8 * + col0 ) AS col1 FROM tab2 AS cor0
----
-1512
-16224
-24016

query I rowsort
SELECT ALL - col1 * - ( + ( col1 ) + 14 ) FROM tab2 AS cor0
----
1395
4307
527

onlyif mysql # use DIV operator for integer division
query I rowsort label-5011
SELECT ALL - cor0.col0 + 2 DIV cor0.col0 col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5011
SELECT ALL - cor0.col0 + 2 / cor0.col0 col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - + col0 * - cor0.col1 + - col1 AS col1 FROM tab2 cor0
----
1326
186
4543

query I rowsort
SELECT + col2 + col2 * + col0 * cor0.col1 AS col1 FROM tab0 AS cor0
----
3396
664200
68145

query I rowsort
SELECT ALL 70 + + col0 FROM tab1 cor0
----
134
150
73

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 ALL - - cor0.col2 + 51 + col0 col0 FROM tab1 AS cor0
----
108
172
227

query I rowsort
SELECT DISTINCT - col1 * + cor0.col0 + - col1 * 78 * ( - col0 ) AS col2 FROM tab0 AS cor0
----
158928
261415
623623

query I rowsort
SELECT ALL + col2 - + cor0.col1 * col1 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT DISTINCT + - col2 * - col1 + col1 + col2 AS col0 FROM tab0 AS cor0
----
195
2957
7635

query I rowsort
SELECT + ( - 31 ) AS col0 FROM tab2 AS cor0
----
-31
-31
-31

query I rowsort
SELECT DISTINCT - 0 + + 41 FROM tab1 AS cor0
----
41

query I rowsort
SELECT ALL + 1 + - col2 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT DISTINCT col1 + + 58 * cor0.col2 AS col0 FROM tab0 AS cor0
----
155
2000
4847

query I rowsort
SELECT ALL + col0 - + col1 * cor0.col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT 34 * + col1 FROM tab2 cor0
----
1054
2006
578

onlyif mysql # use DIV operator for integer division
query I rowsort label-5026
SELECT DISTINCT + - 43 * col1 DIV + col0 AS col0 FROM tab1 cor0
----
-372
-6

skipif mysql # not compatible
query I rowsort label-5026
SELECT DISTINCT + - 43 * col1 / + col0 AS col0 FROM tab1 cor0
----
-372
-6

query I rowsort
SELECT ALL + 15 - tab1.col1 FROM tab2, tab2 AS cor0 CROSS JOIN tab1
----
27 values hashing to 8ce04edc2dbfe49fcca27fc15a543130

query I rowsort
SELECT DISTINCT 45 * col0 AS col2 FROM tab2 cor0
----
315
3510
3555

query I rowsort
SELECT DISTINCT cor2.col1 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab0, tab0 AS cor2
----
86
91
97

query I rowsort
SELECT ALL ( + tab1.col0 * + col1 ) - 61 * col1 * col2 FROM tab1
----
-34130
-75088
-85566

query I rowsort
SELECT ALL - col0 * - 38 - - col0 FROM tab1
----
117
2496
3120

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5032
SELECT col2 + CAST( + col2 AS SIGNED ) FROM tab1
----
108
114
192

skipif mysql # not compatible
query I rowsort label-5032
SELECT col2 + CAST ( + col2 AS INTEGER ) FROM tab1
----
108
114
192

query I rowsort
SELECT + col0 + col1 + + col0 AS col2 FROM tab0
----
134
167
269

query I rowsort
SELECT - + col2 * - 61 AS col1 FROM tab2 AS cor0
----
1586
1647
2318

query I rowsort
SELECT 33 * col0 + col0 + cor0.col1 AS col0 FROM tab1 AS cor0
----
128
2186
2733

query I rowsort
SELECT - 0 * - ( col0 ) + + 26 FROM tab0 AS cor0
----
26
26
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-5037
SELECT ALL col1 DIV ( + tab2.col0 ) + col0 * col1 AS col1 FROM tab2
----
1343
221
4602

skipif mysql # not compatible
query I rowsort label-5037
SELECT ALL col1 / ( + tab2.col0 ) + col0 * col1 AS col1 FROM tab2
----
1343
221
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col2 col1 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT + cor0.col0 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT ALL 84 * - col2 - cor0.col0 * - col1 AS col2 FROM tab0 AS cor0
----
-708
1211
3311

query I rowsort
SELECT + + col2 * col1 + + col0 AS col0 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT + 69 + ( col2 ) FROM tab1 AS cor0
----
123
126
165

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * + col1 + col1 col2 FROM tab2 AS cor0
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-5044
SELECT DISTINCT ( col2 ) * + cor0.col0 + 75 DIV 23 AS col1 FROM tab0 cor0
----
38
7301
795

skipif mysql # not compatible
query I rowsort label-5044
SELECT DISTINCT ( col2 ) * + cor0.col0 + 75 / 23 AS col1 FROM tab0 cor0
----
38
7301
795

query I rowsort
SELECT - - ( 85 ) AS col1 FROM tab1 cor0
----
85
85
85

query I rowsort
SELECT ALL col0 - - col2 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - ( + col1 ) AS col1 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + ( 91 ) AS col0 FROM tab1 AS cor0
----
91

query I rowsort
SELECT ALL - - cor0.col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT + cor0.col0 * cor0.col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL + col2 + col2 AS col2 FROM tab2 cor0
----
52
54
76

query I rowsort
SELECT DISTINCT - col1 * col0 * col1 AS col2 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT - - col2 * + col2 + 99 FROM tab0 AS cor0
----
100
1188
6823

onlyif mysql # use DIV operator for integer division
query I rowsort label-5054
SELECT ALL - ( - col2 ) DIV col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5054
SELECT ALL - ( - col2 ) / col2 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT + 11 + - col1 AS col1 FROM tab1 AS cor0
----
-15
-2
1

query I rowsort
SELECT ALL + 10 * + col2 FROM tab0
----
10
330
820

query I rowsort
SELECT 93 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to 85ef191bf1b307f300b3fd49992fcae7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + + col0 * + 75 col2 FROM tab0 cor0
----
1833
2626
6757

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5059
SELECT DISTINCT + col2 * cor0.col1 + CAST( NULL AS SIGNED ) * col1 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5059
SELECT DISTINCT + col2 * cor0.col1 + CAST ( NULL AS INTEGER ) * col1 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col2 * 76 - col2 AS col2 FROM tab0 AS cor0
----
-2541
-6314
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 col0 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-5062
SELECT + + col1 + 96 + col0 * col0 DIV col1 FROM tab2 AS cor0
----
128
258
480

skipif mysql # not compatible
query I rowsort label-5062
SELECT + + col1 + 96 + col0 * col0 / col1 FROM tab2 AS cor0
----
128
258
480

onlyif mysql # use DIV operator for integer division
query I rowsort label-5063
SELECT DISTINCT cor0.col2 DIV - 4 col0 FROM tab2 cor0
----
-6
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5063
SELECT DISTINCT cor0.col2 / - 4 col0 FROM tab2 cor0
----
-6
-9

query I rowsort
SELECT + 41 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT ALL - col2 * ( + cor0.col0 ) FROM tab2 AS cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col0 + + col2 col0 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5067
SELECT - - cor0.col0 DIV 9 AS col2 FROM tab1 AS cor0
----
0
7
8

skipif mysql # not compatible
query I rowsort label-5067
SELECT - - cor0.col0 / 9 AS col2 FROM tab1 AS cor0
----
0
7
8

query I rowsort
SELECT col1 + ( + col0 ) - cor0.col0 AS col1 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT - col0 * + col2 + col1 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT - - cor0.col0 + - 21 FROM tab0, tab0 AS cor0
----
9 values hashing to 10f738104aad9a6174d9b6f9128a0c10

query I rowsort
SELECT DISTINCT + ( + 4 ) AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
4

query I rowsort
SELECT 95 AS col2 FROM tab2, tab1 cor0, tab1 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT cor0.col0 + 39 AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3cc8c222944825a1907e47b40106bc61

query I rowsort
SELECT 45 * - col1 AS col1 FROM tab1
----
-1170
-450
-585

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( col2 ) col1 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT ALL - 33 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to bbc05afe7eb6fed16e9d75f7f74d1948

onlyif mysql # use DIV operator for integer division
query I rowsort label-5077
SELECT ALL col2 DIV tab1.col2 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5077
SELECT ALL col2 / tab1.col2 AS col1 FROM tab1
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + 89 col1 FROM tab1 cor0
----
-7
32
35

query I rowsort
SELECT tab2.col0 * + tab2.col1 + col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT - + col0 + + cor0.col1 AS col1 FROM tab2 AS cor0
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-5081
SELECT col2 + col0 DIV col2 AS col2 FROM tab0 AS cor0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-5081
SELECT col2 + col0 / col2 AS col2 FROM tab0 AS cor0
----
33
36
83

query I rowsort
SELECT 83 * col1 + + col1 FROM tab0 AS cor0
----
7224
7644
8148

query I rowsort
SELECT + 55 + - col0 * - col1 - col2 AS col0 FROM tab0
----
2086
3449
8072

query I rowsort
SELECT DISTINCT - col1 + + 77 AS col1 FROM tab1
----
51
64
67

query I rowsort
SELECT DISTINCT - 86 AS col2 FROM tab1, tab2 AS cor0 CROSS JOIN tab0
----
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-5086
SELECT col1 DIV 89 col2 FROM tab0 AS cor0
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5086
SELECT col1 / 89 col2 FROM tab0 AS cor0
----
0
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5087
SELECT - cor0.col0 * 65 + col0 DIV + col1 AS col1 FROM tab0 cor0
----
-1560
-2275
-5785

skipif mysql # not compatible
query I rowsort label-5087
SELECT - cor0.col0 * 65 + col0 / + col1 AS col1 FROM tab0 cor0
----
-1560
-2275
-5785

query I rowsort
SELECT DISTINCT + - col0 * + col1 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5089
SELECT ALL + col0 + - 95 DIV + col2 FROM tab0 AS cor0
----
-60
22
88

skipif mysql # not compatible
query I rowsort label-5089
SELECT ALL + col0 + - 95 / + col2 FROM tab0 AS cor0
----
-60
22
88

query I rowsort
SELECT - ( col0 ) * cor0.col1 + - 60 AS col0 FROM tab2 AS cor0
----
-1403
-277
-4662

query I rowsort
SELECT ALL + col0 * col1 * col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT ALL + col2 + col0 + - col1 * col0 AS col2 FROM tab2 AS cor0
----
-1226
-183
-4498

onlyif mysql # use DIV operator for integer division
query I rowsort label-5093
SELECT + - 47 DIV col0 + col2 * col0 FROM tab2 AS cor0
----
183
2028
3002

skipif mysql # not compatible
query I rowsort label-5093
SELECT + - 47 / col0 + col2 * col0 FROM tab2 AS cor0
----
183
2028
3002

query I rowsort
SELECT DISTINCT 13 * - col2 FROM tab2 AS cor0
----
-338
-351
-494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col2 * 43 col1 FROM tab2 AS cor0
----
-1118
-1161
-1634

query I rowsort
SELECT ALL ( col1 ) * col2 * col1 FROM tab2 cor0
----
10982
25947
90506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5097
SELECT CAST( - col2 AS SIGNED ) + col2 * 4 FROM tab0 cor0
----
246
3
99

skipif mysql # not compatible
query I rowsort label-5097
SELECT CAST ( - col2 AS INTEGER ) + col2 * 4 FROM tab0 cor0
----
246
3
99

query I rowsort
SELECT col0 * col0 + col1 AS col0 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT DISTINCT - 3 AS col0 FROM tab1 AS cor0
----
-3

query I rowsort
SELECT ALL - + 2 * - col1 AS col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT + cor0.col0 + col0 + - col1 AS col2 FROM tab0 AS cor0
----
-27
-38
87

query I rowsort
SELECT col1 * col0 + + ( + col0 ) * col0 FROM tab0 AS cor0
----
16020
2640
4620

query I rowsort
SELECT ALL + + col1 + col1 AS col1 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT - + 85 * - col1 AS col1 FROM tab0 AS cor0
----
7310
7735
8245

query I rowsort
SELECT ALL + + 58 FROM tab0 AS cor0
----
58
58
58

query I rowsort
SELECT - - cor0.col1 + - col1 * - 46 AS col1 FROM tab0 AS cor0
----
4042
4277
4559

query I rowsort
SELECT + 19 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

query I rowsort
SELECT - + col1 - - cor0.col0 FROM tab1 AS cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( cor1.col0 ) col2 FROM tab2, tab2 AS cor0, tab2 AS cor1, tab1, tab2 AS cor2
----
243 values hashing to 455e4df3bf7b0fa681c56e89df1a761f

query I rowsort
SELECT DISTINCT - - col0 * + 53 + - col2 - col1 * col2 FROM tab1 cor0
----
-1299
2765
2896

onlyif mysql # use DIV operator for integer division
query I rowsort label-5111
SELECT - col2 - + 71 DIV cor0.col1 col1 FROM tab2 cor0
----
-27
-29
-42

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5111
SELECT - col2 - + 71 / cor0.col1 col1 FROM tab2 cor0
----
-27
-29
-42

query I rowsort
SELECT + col1 - + ( - 81 ) FROM tab2 AS cor0
----
112
140
98

query I rowsort
SELECT - col1 * col1 - + col0 AS col1 FROM tab1 AS cor0
----
-164
-249
-679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col2 + + tab1.col0 + + 96 col2 FROM tab1, tab0 AS cor0
----
9 values hashing to bec547714de0ed06edc8f46262bf7d33

onlyif mysql # use DIV operator for integer division
query I rowsort label-5115
SELECT DISTINCT - col0 DIV 1 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-5115
SELECT DISTINCT - col0 / 1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT + 31 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-5117
SELECT - col1 DIV - 10 AS col1 FROM tab2
----
1
3
5

skipif mysql # not compatible
query I rowsort label-5117
SELECT - col1 / - 10 AS col1 FROM tab2
----
1
3
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-5118
SELECT ALL + col1 DIV col1 AS col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5118
SELECT ALL + col1 / col1 AS col0 FROM tab0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5119
SELECT ALL col1 + + 89 DIV cor0.col2 FROM tab0 AS cor0
----
186
88
92

skipif mysql # not compatible
query I rowsort label-5119
SELECT ALL col1 + + 89 / cor0.col2 FROM tab0 AS cor0
----
186
88
92

query I rowsort
SELECT tab2.col1 - + tab2.col0 FROM tab2
----
-19
-62
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5121
SELECT + col0 * + CAST( NULL AS SIGNED ) + + col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5121
SELECT + col0 * + CAST ( NULL AS INTEGER ) + + col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT - col1 + CAST ( + col2 AS REAL ) * - tab2.col1 * 69 - - col2 * + col0 FROM tab2
----
-103877
-41589
-57595

query I rowsort
SELECT ALL col2 + - col1 - - col0 FROM tab0
----
-29
-61
80

query I rowsort
SELECT col1 * tab0.col0 + col2 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT + col0 * 51 - 74 FROM tab1
----
3190
4006
79

query I rowsort
SELECT DISTINCT + 47 FROM tab0, tab2 AS cor0
----
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5127
SELECT DISTINCT + CAST( NULL AS SIGNED ) + - col2 / col0 AS col2 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5127
SELECT DISTINCT + CAST ( NULL AS INTEGER ) + - col2 / col0 AS col2 FROM tab2 cor0
----
NULL

query I rowsort
SELECT - + 18 + col1 * - col2 AS col2 FROM tab1 AS cor0
----
-1266
-1422
-588

query I rowsort
SELECT - col2 - - 13 * + col1 * 85 AS col0 FROM tab0 AS cor0
----
100473
107184
94997

onlyif mysql # use DIV operator for integer division
query I rowsort label-5130
SELECT ALL - col2 DIV col0 - + col2 col2 FROM tab0
----
-1
-34
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5130
SELECT ALL - col2 / col0 - + col2 col2 FROM tab0
----
-1
-34
-82

query I rowsort
SELECT - 46 * col2 AS col1 FROM tab0 AS cor0
----
-1518
-3772
-46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - col2 ) * + col0 - col0 col1 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT ALL - 90 AS col0 FROM tab0 AS cor0
----
-90
-90
-90

query I rowsort
SELECT + 77 * cor0.col0 AS col1 FROM tab0 AS cor0
----
1848
2695
6853

query I rowsort
SELECT DISTINCT tab1.col1 + col2 * col0 FROM tab1
----
188
3658
7693

query I rowsort
SELECT ALL + ( col2 ) + + tab1.col2 AS col1 FROM tab1
----
108
114
192

query I rowsort
SELECT 53 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 866ae1b4ab9e5b4043ac1bcfd413aaa6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5138
SELECT DISTINCT + CAST( col2 AS SIGNED ) + - col0 FROM tab0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-5138
SELECT DISTINCT + CAST ( col2 AS INTEGER ) + - col0 FROM tab0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5139
SELECT DISTINCT col2 DIV + col2 + col1 AS col0 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-5139
SELECT DISTINCT col2 / + col2 + col1 AS col0 FROM tab1
----
11
14
27

query I rowsort
SELECT DISTINCT - tab0.col1 - + 24 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
-110
-115
-121

query I rowsort
SELECT col2 * col0 + + tab1.col1 AS col2 FROM tab1
----
188
3658
7693

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5142
SELECT - CAST( - col0 AS SIGNED ) + - col1 AS col1 FROM tab2 AS cor0
----
-24
19
62

skipif mysql # not compatible
query I rowsort label-5142
SELECT - CAST ( - col0 AS INTEGER ) + - col1 AS col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT + col1 - + col0 AS col1 FROM tab0 cor0
----
2
62

query I rowsort
SELECT DISTINCT + + 98 - col2 AS col0 FROM tab0 AS cor0
----
16
65
97

query I rowsort
SELECT ALL - cor0.col2 FROM tab2, tab2 cor0, tab2 cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + col1 col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT + - col0 + - col0 AS col0 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT + col1 * 61 - col0 AS col0 FROM tab1 cor0
----
1583
546
713

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5149
SELECT ALL + 64 * col0 * - CAST( NULL AS SIGNED ) col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5149
SELECT ALL + 64 * col0 * - CAST ( NULL AS INTEGER ) col0 FROM tab2
----
NULL
NULL
NULL

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2, tab2 cor0, tab0 AS cor1
----
972 values hashing to e4c748f267e8d2a0e6d563281e1fb975

query I rowsort
SELECT ALL - 64 * + col0 AS col0 FROM tab2
----
-448
-4992
-5056

query I rowsort
SELECT - ( col2 ) * col0 * - col2 AS col0 FROM tab1 AS cor0
----
207936
737280
8748

onlyif mysql # use DIV operator for integer division
query I rowsort label-5153
SELECT + col2 + - col2 DIV ( + col1 ) FROM tab2 AS cor0
----
26
27
36

skipif mysql # not compatible
query I rowsort label-5153
SELECT + col2 + - col2 / ( + col1 ) FROM tab2 AS cor0
----
26
27
36

query I rowsort
SELECT DISTINCT - 43 AS col2 FROM tab0 AS cor0
----
-43

query I rowsort
SELECT DISTINCT col1 + + col0 * col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT 32 * col2 + col2 FROM tab0
----
1089
2706
33

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5157
SELECT DISTINCT - 8 * + col2 * CAST( col1 AS SIGNED ) AS col2 FROM tab1
----
-11232
-4560
-9984

skipif mysql # not compatible
query I rowsort label-5157
SELECT DISTINCT - 8 * + col2 * CAST ( col1 AS INTEGER ) AS col2 FROM tab1
----
-11232
-4560
-9984

query I rowsort
SELECT ALL 96 AS col2 FROM tab1
----
96
96
96

query I rowsort
SELECT ALL - cor0.col0 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5160
SELECT + + col2 DIV col2 AS col0 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5160
SELECT + + col2 / col2 AS col0 FROM tab0 cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * 70 col0 FROM tab1 AS cor0
----
-1820
-700
-910

query I rowsort
SELECT ALL - - cor0.col1 - 9 FROM tab0 cor0
----
77
82
88

query I rowsort
SELECT ALL + col1 * col0 * col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT DISTINCT + col0 + + col0 * col1 AS col2 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT + - cor0.col0 + - col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT ALL - - col1 + 48 FROM tab2 AS cor0
----
107
65
79

query I rowsort
SELECT + cor0.col2 * 8 AS col2 FROM tab2 AS cor0
----
208
216
304

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col1 ) col0 FROM tab0
----
86
91
97

query I rowsort
SELECT ALL - col1 * col2 + - 96 FROM tab2 AS cor0
----
-1630
-742
-933

query I rowsort
SELECT ALL - col2 + - 85 FROM tab1 AS cor0
----
-139
-142
-181

onlyif mysql # use DIV operator for integer division
query I rowsort label-5171
SELECT DISTINCT col0 * 84 DIV col2 AS col2 FROM tab1 AS cor0
----
4
70
94

skipif mysql # not compatible
query I rowsort label-5171
SELECT DISTINCT col0 * 84 / col2 AS col2 FROM tab1 AS cor0
----
4
70
94

query I rowsort
SELECT DISTINCT col2 - + cor0.col0 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - 96 col2 FROM tab2 AS cor0
----
-2496
-2592
-3648

query I rowsort
SELECT ALL col0 * 66 + 16 FROM tab1 AS cor0
----
214
4240
5296

onlyif mysql # use DIV operator for integer division
query I rowsort label-5175
SELECT ALL col0 DIV col2 + - CAST( + col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-33
-81
34

skipif mysql # not compatible
query I rowsort label-5175
SELECT ALL col0 / col2 + - CAST ( + col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-33
-81
34

query I rowsort
SELECT + 17 * + cor0.col1 - - ( - 32 ) * cor0.col1 FROM tab1 AS cor0
----
-150
-195
-390

query I rowsort
SELECT DISTINCT + col2 + col1 + + col1 AS col2 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT + + 24 + col2 AS col0 FROM tab2 AS cor0
----
50
51
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5179
SELECT + cor0.col2 * - CAST( NULL AS SIGNED ) * + ( + col1 ) + col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5179
SELECT + cor0.col2 * - CAST ( NULL AS INTEGER ) * + ( + col1 ) + col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5180
SELECT 33 * col0 DIV 16 col2 FROM tab2
----
14
160
162

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5180
SELECT 33 * col0 / 16 col2 FROM tab2
----
14
160
162

query I rowsort
SELECT 15 AS col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

query I rowsort
SELECT DISTINCT 55 + col0 * 89 FROM tab1
----
322
5751
7175

query I rowsort
SELECT ALL col1 * col1 + 28 + col2 * + col0 FROM tab1
----
3776
7877
866

query I rowsort
SELECT + + col2 * - col1 AS col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - 95 FROM tab1 AS cor0
----
-95
-95
-95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5186
SELECT ALL CAST( NULL AS DECIMAL ) * 65 + + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5186
SELECT ALL CAST ( NULL AS REAL ) * 65 + + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 79 + + ( - cor0.col1 ) FROM tab2 AS cor0
----
20
48
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5188
SELECT - CAST( NULL AS SIGNED ) + - 19 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5188
SELECT - CAST ( NULL AS INTEGER ) + - 19 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 + - 75 FROM tab0
----
-42
-74
7

query I rowsort
SELECT ALL + col0 + col0 * col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT + + col1 * + col1 + + col2 AS col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT - 85 AS col0 FROM tab1 AS cor0
----
-85

query I rowsort
SELECT DISTINCT + ( col2 ) * - col1 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ( col0 ) * cor0.col0 + - ( col0 ) AS col1 FROM tab2 AS cor0
----
42
6006
6162

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5195
SELECT DISTINCT + CAST( + 9 AS SIGNED ) + col2 * + 90 AS col2 FROM tab2 AS cor0
----
2349
2439
3429

skipif mysql # not compatible
query I rowsort label-5195
SELECT DISTINCT + CAST ( + 9 AS INTEGER ) + col2 * + 90 AS col2 FROM tab2 AS cor0
----
2349
2439
3429

query I rowsort
SELECT ALL + + ( - 64 ) + cor0.col0 + + col0 FROM tab2 AS cor0
----
-50
92
94

query I rowsort
SELECT ALL col1 * - 69 + col1 FROM tab2 AS cor0
----
-1156
-2108
-4012

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5198
SELECT DISTINCT CAST( col2 AS SIGNED ) * - col0 - ( - col0 ) AS col0 FROM tab1 AS cor0
----
-159
-3584
-7600

skipif mysql # not compatible
query I rowsort label-5198
SELECT DISTINCT CAST ( col2 AS INTEGER ) * - col0 - ( - col0 ) AS col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL - 61 + - tab1.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 7a797eac05c97e0158bf4beff9aa0670

query I rowsort
SELECT + + 50 AS col0 FROM tab0 cor0
----
50
50
50

query I rowsort
SELECT ALL - 67 * + cor0.col1 AS col2 FROM tab1 cor0
----
-1742
-670
-871

query I rowsort
SELECT DISTINCT + ( - ( col0 ) ) * ( col2 * col2 ) FROM tab2
----
-114076
-5103
-52728

query I rowsort
SELECT - - 70 AS col0 FROM tab1 AS cor0
----
70
70
70

query I rowsort
SELECT DISTINCT col2 * - 33 AS col2 FROM tab0
----
-1089
-2706
-33

query I rowsort
SELECT 37 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

query I rowsort
SELECT col1 * 93 FROM tab1 AS cor0
----
1209
2418
930

query I rowsort
SELECT DISTINCT + col1 * - ( - col1 ) * + cor0.col2 FROM tab0 AS cor0
----
244068
679042
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col2 * - cor0.col1 col0 FROM tab1 AS cor0
----
1328
1407
634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + ( col2 ) col2 FROM tab0
----
171
36
57

query I rowsort
SELECT ALL 33 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 35 + + ( + col0 ) col1 FROM tab0 cor0
----
124
59
70

query I rowsort
SELECT + col1 * - col2 * col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT - col0 + col2 + - tab1.col1 FROM tab1
----
-17
25
3

query I rowsort
SELECT ALL col2 * + tab1.col0 - 37 * 65 FROM tab1
----
-2243
1243
5275

query I rowsort
SELECT - 18 * col2 FROM tab1
----
-1026
-1728
-972

query I rowsort
SELECT DISTINCT - col1 * col2 * + 35 FROM tab2
----
-22610
-29295
-53690

query I rowsort
SELECT DISTINCT - - cor0.col2 + - 47 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
-14
-46
35

skipif mysql # not compatible
query I rowsort
SELECT ALL - col0 * col2 * + ( + col0 ) + col0 - - CAST ( 87 AS REAL ) AS col1 FROM tab2
----
-1229
-158019
-236992

query I rowsort
SELECT + - 78 * - col0 AS col0 FROM tab1 cor0
----
234
4992
6240

query I rowsort
SELECT - ( col1 ) * ( - col2 ) - - cor0.col2 * - ( 77 * + col0 ) AS col0 FROM tab2 AS cor0
----
-13716
-154622
-230508

query I rowsort
SELECT - col1 * - col2 + + col1 + + col2 AS col0 FROM tab0 AS cor0
----
195
2957
7635

query I rowsort
SELECT - cor0.col0 + - ( - col2 ) AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT - + col1 * + ( col2 ) * col1 + + ( - col2 ) FROM tab0 AS cor0
----
-244101
-679124
-9410

query I rowsort
SELECT col2 * 75 FROM tab2 AS cor0
----
1950
2025
2850

query I rowsort
SELECT 17 AS col0 FROM tab0, tab2 cor0, tab0 cor1, tab0 AS cor2
----
81 values hashing to 71801088bb30ca6eac036729ebfbbace

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5226
SELECT + CAST( + 69 AS SIGNED ) + tab2.col2 * col0 AS col1 FROM tab2
----
2097
258
3071

skipif mysql # not compatible
query I rowsort label-5226
SELECT + CAST ( + 69 AS INTEGER ) + tab2.col2 * col0 AS col1 FROM tab2
----
2097
258
3071

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + col1 ) + col1 col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5228
SELECT ALL + CAST( NULL AS SIGNED ) * 4 + col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5228
SELECT ALL + CAST ( NULL AS INTEGER ) * 4 + col2 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 0 + col1 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + cor0.col0 * col2 col0 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT 49 + - col1 AS col1 FROM tab2 AS cor0
----
-10
18
32

query I rowsort
SELECT ALL - - col1 * col1 + col0 AS col2 FROM tab0 AS cor0
----
7420
8370
9444

query I rowsort
SELECT - - col2 + col0 - col1 AS col1 FROM tab0 AS cor0
----
-29
-61
80

query I rowsort
SELECT DISTINCT - col2 + - col0 * col1 + col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + - cor0.col1 - + col1 AS col2 FROM tab2 AS cor0
----
-118
-34
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col0 col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + ( col1 ) * + 11 + col2 AS col2 FROM tab2 AS cor0
----
225
368
675

query I rowsort
SELECT ALL + - col0 + - col2 * ( + col2 ) AS col2 FROM tab0 AS cor0
----
-1113
-36
-6813

onlyif mysql # use DIV operator for integer division
query I rowsort label-5239
SELECT ALL - col0 DIV col0 + - 16 DIV col1 AS col2 FROM tab2 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5239
SELECT ALL - col0 / col0 + - 16 / col1 AS col2 FROM tab2 cor0
----
-1
-1
-1

query I rowsort
SELECT - 79 * col2 + col0 AS col0 FROM tab0 AS cor0
----
-2583
-44
-6389

onlyif mysql # use DIV operator for integer division
query I rowsort label-5241
SELECT ALL + col0 DIV 29 AS col1 FROM tab2
----
0
2
2

skipif mysql # not compatible
query I rowsort label-5241
SELECT ALL + col0 / 29 AS col1 FROM tab2
----
0
2
2

query I rowsort
SELECT ( - col0 ) - col0 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT DISTINCT - 27 FROM tab0, tab2, tab2 cor0
----
-27

query I rowsort
SELECT ALL ( col1 * + tab0.col0 ) FROM tab0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + col1 * col0 + + 27 FROM tab1 AS cor0
----
105
1067
667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 - cor0.col0 col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT - 31 * col0 + - col1 AS col0 FROM tab2 AS cor0
----
-2466
-2477
-248

query I rowsort
SELECT ALL - - col0 + + col2 * + 3 + - 75 FROM tab1 AS cor0
----
160
293
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-5249
SELECT ALL + + ( col1 ) DIV - col0 + + col1 + col2 DIV - col0 FROM tab2 AS cor0
----
17
24
59

skipif mysql # not compatible
query I rowsort label-5249
SELECT ALL + + ( col1 ) / - col0 + + col1 + col2 / - col0 FROM tab2 AS cor0
----
17
24
59

query I rowsort
SELECT DISTINCT + col2 + col1 - + ( ( - col2 ) ) FROM tab2 AS cor0
----
111
85
93

query I rowsort
SELECT ( 27 ) * tab0.col0 - - col2 AS col1 FROM tab0
----
2485
681
946

query I rowsort
SELECT ALL - 8 * col0 FROM tab1
----
-24
-512
-640

query I rowsort
SELECT ALL - ( col2 ) * - ( col2 ) + cor0.col0 AS col0 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT 93 AS col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
81 values hashing to bed80270d2bd273301f8ff63d7ef9f43

query I rowsort
SELECT ALL + 93 - col0 FROM tab2
----
14
15
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col2 * 52 + - tab1.col1 col0 FROM tab1
----
2808
2964
4992

query I rowsort
SELECT DISTINCT col2 * col0 + + tab2.col1 - - tab2.col0 * col2 AS col2 FROM tab2
----
409
4115
6021

onlyif mysql # use DIV operator for integer division
query I rowsort label-5258
SELECT DISTINCT - 0 + col1 - tab0.col1 DIV - col2 FROM tab0
----
194
88
92

skipif mysql # not compatible
query I rowsort label-5258
SELECT DISTINCT - 0 + col1 - tab0.col1 / - col2 FROM tab0
----
194
88
92

query I rowsort
SELECT + col2 * - col2 + - col0 AS col1 FROM tab1 AS cor0
----
-2919
-3313
-9296

query I rowsort
SELECT col2 - - cor0.col0 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL + - 1 * cor0.col2 * - 72 + - col1 FROM tab2 AS cor0
----
1813
1913
2719

query I rowsort
SELECT - col1 * col1 * col1 + col2 FROM tab1
----
-17522
-2101
-943

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5263
SELECT CAST( NULL AS SIGNED ) + + ( cor0.col0 * CAST( NULL AS SIGNED ) ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5263
SELECT CAST ( NULL AS INTEGER ) + + ( cor0.col0 * CAST ( NULL AS INTEGER ) ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 20 + + 49 col1 FROM tab0 AS cor0
----
69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5265
SELECT + - CAST( NULL AS SIGNED ) + ( - cor0.col0 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5265
SELECT + - CAST ( NULL AS INTEGER ) + ( - cor0.col0 ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col2 * 92 FROM tab1 AS cor0
----
-4968
-5244
-8832

query I rowsort
SELECT + 16 * col1 + + col0 * col0 FROM tab0 cor0
----
1952
2777
9377

query I rowsort
SELECT DISTINCT + tab2.col2 + - 40 AS col2 FROM tab2
----
-13
-14
-2

query I rowsort
SELECT DISTINCT - col1 + ( + col1 ) * + col0 AS col1 FROM tab0
----
1978
3298
8008

query I rowsort
SELECT DISTINCT - col2 * col1 + + 29 FROM tab1
----
-1219
-1375
-541

query I rowsort
SELECT ( tab0.col2 ) AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT col1 - tab0.col1 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL + 77 FROM tab0, tab1 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT DISTINCT - 66 + - col0 * + col2 AS col2 FROM tab0 AS cor0
----
-101
-7364
-858

query I rowsort
SELECT DISTINCT - + 50 AS col2 FROM tab1 AS cor0
----
-50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5276
SELECT ALL + - CAST( NULL AS SIGNED ) + + 55 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5276
SELECT ALL + - CAST ( NULL AS INTEGER ) + + 55 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + cor0.col2 - 38 FROM tab1 AS cor0
----
-134
-92
-95

query I rowsort
SELECT ALL - 71 - - col0 AS col1 FROM tab2 AS cor0
----
-64
7
8

query I rowsort
SELECT ALL - col0 * - col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + + ( + col0 ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - + 51 + col2 * cor0.col1 FROM tab1 AS cor0
----
1197
1353
519

query I rowsort
SELECT - - col1 * 22 AS col2 FROM tab0 AS cor0
----
1892
2002
2134

query I rowsort
SELECT ALL - 65 - col1 AS col2 FROM tab0 AS cor0
----
-151
-156
-162

query I rowsort
SELECT DISTINCT + 19 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
19

query I rowsort
SELECT - col2 * 24 AS col0 FROM tab0 AS cor0
----
-1968
-24
-792

query I rowsort
SELECT ALL 8 FROM tab2, tab0 AS cor0
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

onlyif mysql # use DIV operator for integer division
query I rowsort label-5287
SELECT col2 + - 11 DIV - tab2.col0 FROM tab2
----
26
28
38

skipif mysql # not compatible
query I rowsort label-5287
SELECT col2 + - 11 / - tab2.col0 FROM tab2
----
26
28
38

query I rowsort
SELECT col2 * 98 * col1 + col2 FROM tab0
----
278157
731358
9507

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor1.col2 col0 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT - - col1 * + 44 FROM tab2 AS cor0
----
1364
2596
748

query I rowsort
SELECT cor0.col2 AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL - col2 * - 17 FROM tab1 cor0
----
1632
918
969

query I rowsort
SELECT DISTINCT - col1 + col1 * + col1 AS col0 FROM tab0 AS cor0
----
7310
8190
9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 75 col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

onlyif mysql # use DIV operator for integer division
query I rowsort label-5295
SELECT + 54 DIV ( - col1 ) FROM tab1 AS cor0
----
-2
-4
-5

skipif mysql # not compatible
query I rowsort label-5295
SELECT + 54 / ( - col1 ) FROM tab1 AS cor0
----
-2
-4
-5

query I rowsort
SELECT + + col2 - 25 FROM tab2 AS cor0
----
1
13
2

query I rowsort
SELECT - ( col0 ) + + cor0.col1 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-5298
SELECT + - col0 DIV col1 AS col0 FROM tab1 AS cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-5298
SELECT + - col0 / col1 AS col0 FROM tab1 AS cor0
----
-6
-6
0

query I rowsort
SELECT ALL - 6 FROM tab2, tab1 cor0
----
9 values hashing to e92b2679faac7be63701967e3f0c0934

query I rowsort
SELECT col1 * + col1 * col1 AS col1 FROM tab0 AS cor0
----
636056
753571
912673

query I rowsort
SELECT - ( - col0 ) + + col1 * cor0.col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT ALL 95 * col1 AS col0 FROM tab2 AS cor0
----
1615
2945
5605

query I rowsort
SELECT ALL - col0 * col0 * - ( + col0 ) + col1 + + 60 * col0 FROM tab2 AS cor0
----
479291
497796
794

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 54 col0 FROM tab2 AS cor0
----
54

query I rowsort
SELECT ALL - cor0.col0 * cor0.col2 AS col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT - 76 * col1 FROM tab1 cor0
----
-1976
-760
-988

onlyif mysql # use DIV operator for integer division
query I rowsort label-5307
SELECT ALL - 55 * - col2 * - col2 + 99 DIV col2 + + 99 FROM tab1 AS cor0
----
-160280
-178595
-506780

skipif mysql # not compatible
query I rowsort label-5307
SELECT ALL - 55 * - col2 * - col2 + 99 / col2 + + 99 FROM tab1 AS cor0
----
-160280
-178595
-506780

query I rowsort
SELECT ALL - ( col1 ) - col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT + 7 + col0 AS col1 FROM tab1 AS cor0
----
10
71
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-5310
SELECT + col0 + col2 DIV col1 FROM tab2
----
7
78
81

skipif mysql # not compatible
query I rowsort label-5310
SELECT + col0 + col2 / col1 FROM tab2
----
7
78
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-5311
SELECT DISTINCT 96 DIV - col2 + col1 FROM tab0
----
1
84
90

skipif mysql # not compatible
query I rowsort label-5311
SELECT DISTINCT 96 / - col2 + col1 FROM tab0
----
1
84
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5312
SELECT CAST( 38 AS SIGNED ) + + tab1.col2 FROM tab1
----
134
92
95

skipif mysql # not compatible
query I rowsort label-5312
SELECT CAST ( 38 AS INTEGER ) + + tab1.col2 FROM tab1
----
134
92
95

query I rowsort
SELECT + 22 + col2 FROM tab2
----
48
49
60

query I rowsort
SELECT DISTINCT + + 78 * - col0 FROM tab1 AS cor0
----
-234
-4992
-6240

onlyif mysql # use DIV operator for integer division
query I rowsort label-5315
SELECT ALL + + col0 DIV - col2 + - 62 * + col0 col1 FROM tab1 AS cor0
----
-186
-3969
-4960

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5315
SELECT ALL + + col0 / - col2 + - 62 * + col0 col1 FROM tab1 AS cor0
----
-186
-3969
-4960

query I rowsort
SELECT ALL + ( 71 ) * cor0.col1 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f5a86f1c31aa425cec3174d68a2ecc19

query I rowsort
SELECT tab1.col0 * - tab1.col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT ALL + - 42 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 9894093f29c0defae91347934f060329

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5319
SELECT DISTINCT cor0.col1 * + CAST( col1 AS SIGNED ) col2 FROM tab1 AS cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5319
SELECT DISTINCT cor0.col1 * + CAST ( col1 AS INTEGER ) col2 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-5320
SELECT - + col0 DIV col1 + - col2 * + col0 AS col2 FROM tab2 AS cor0
----
-189
-2029
-3006

skipif mysql # not compatible
query I rowsort label-5320
SELECT - + col0 / col1 + - col2 * + col0 AS col2 FROM tab2 AS cor0
----
-189
-2029
-3006

query I rowsort
SELECT ( - col2 ) * tab0.col0 * tab0.col2 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT ALL - tab0.col0 + + tab0.col1 FROM tab0
----
2
62
62

query I rowsort
SELECT ( cor0.col1 ) + col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - - cor0.col1 + - 36 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to d8596d3aebe3663f4fbd017fecb4803a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5325
SELECT + CAST( NULL AS SIGNED ) * cor0.col1 * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5325
SELECT + CAST ( NULL AS INTEGER ) * cor0.col1 * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - ( + col2 ) AS col0 FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * col2 col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT - col1 - - 74 AS col0 FROM tab0 cor0
----
-12
-17
-23

query I rowsort
SELECT - col0 + col0 * col1 * + 34 FROM tab0 AS cor0
----
115395
275277
70152

query I rowsort
SELECT - col0 * col1 * + col0 FROM tab1
----
-234
-40960
-83200

query I rowsort
SELECT ALL ( col0 ) * - ( + col0 * + col2 ) FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT + col2 * - cor0.col0 - col0 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT ALL col0 - + cor0.col2 * + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT + 99 * - col0 * col1 - 48 * - col1 FROM tab1 cor0
----
-102336
-62880
-6474

query I rowsort
SELECT ALL + 66 + col0 AS col0 FROM tab2 AS cor0
----
144
145
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5336
SELECT DISTINCT col0 * col2 - - CAST( col1 + + cor0.col1 AS SIGNED ) FROM tab2 AS cor0
----
2146
251
3036

skipif mysql # not compatible
query I rowsort label-5336
SELECT DISTINCT col0 * col2 - - CAST ( col1 + + cor0.col1 AS INTEGER ) FROM tab2 AS cor0
----
2146
251
3036

query I rowsort
SELECT ALL - + col1 * col2 + + col2 * + 27 AS col2 FROM tab1 AS cor0
----
1344
54
969

query I rowsort
SELECT DISTINCT - + 29 + + col2 - col2 AS col0 FROM tab2 AS cor0
----
-29

query I rowsort
SELECT + + 67 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to eea8a0738728ea55e4e7ba1506c9905a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5340
SELECT + CAST( NULL AS DECIMAL ) col1 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5340
SELECT + CAST ( NULL AS REAL ) col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 85 AS col0 FROM tab2
----
-85

query I rowsort
SELECT - col1 * + col0 - col2 FROM tab2
----
-1381
-244
-4628

query I rowsort
SELECT DISTINCT + tab2.col2 - - col1 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL - 64 * cor0.col1 + ( col0 ) * col2 FROM tab1 AS cor0
----
-1502
3008
6848

query I rowsort
SELECT DISTINCT 14 * col1 + 91 FROM tab0 AS cor0
----
1295
1365
1449

query I rowsort
SELECT ALL + - 80 + + col0 FROM tab2 AS cor0
----
-1
-2
-73

query I rowsort
SELECT + 27 + col1 AS col0 FROM tab1 AS cor0
----
37
40
53

query I rowsort
SELECT ALL - 92 AS col0 FROM tab2 AS cor0
----
-92
-92
-92

query I rowsort
SELECT ALL - col0 + + col0 + + col0 * + cor0.col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - col0 - col2 AS col0 FROM tab0 cor0
----
-171
-36
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * cor0.col1 + ( + col1 * col1 ) col1 FROM tab1 AS cor0
----
-540
-871
598

query I rowsort
SELECT 61 + + 55 FROM tab1, tab0 AS cor0
----
9 values hashing to 1b203c14e07bd085fccb96893918131a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 6 col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 + + col2 * + ( - col1 ) col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT col2 + 86 * col0 FROM tab2 cor0
----
629
6734
6832

query I rowsort
SELECT ALL - cor1.col0 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT ALL cor0.col2 FROM tab2, tab1 cor0, tab2 cor1, tab0 AS cor2
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

query I rowsort
SELECT ( 59 ) AS col2 FROM tab2, tab1 AS cor0, tab0 cor1, tab1 AS cor2
----
81 values hashing to 05f41d0d3fd0b5c29af79ab9209cab27

query I rowsort
SELECT + 24 * - 90 AS col0 FROM tab1 AS cor0
----
-2160
-2160
-2160

query I rowsort
SELECT DISTINCT + col2 + col1 + - col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL 9 + 79 AS col0 FROM tab1 AS cor0
----
88
88
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col1 - - col1 col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT ALL + - col2 * + 38 AS col0 FROM tab1 AS cor0
----
-2052
-2166
-3648

onlyif mysql # use DIV operator for integer division
query I rowsort label-5364
SELECT DISTINCT 50 DIV - col0 + col2 AS col0 FROM tab2 AS cor0
----
20
26
38

skipif mysql # not compatible
query I rowsort label-5364
SELECT DISTINCT 50 / - col0 + col2 AS col0 FROM tab2 AS cor0
----
20
26
38

query I rowsort
SELECT - - ( + cor0.col0 ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT - col0 * + 82 + col2 AS col0 FROM tab0 AS cor0
----
-1935
-2869
-7216

onlyif mysql # use DIV operator for integer division
query I rowsort label-5367
SELECT DISTINCT col1 * 95 * + col1 + col0 * col2 DIV col0 AS col2 FROM tab1 AS cor0
----
16151
64274
9557

skipif mysql # not compatible
query I rowsort label-5367
SELECT DISTINCT col1 * 95 * + col1 + col0 * col2 / col0 AS col2 FROM tab1 AS cor0
----
16151
64274
9557

query I rowsort
SELECT DISTINCT - - 73 AS col0 FROM tab1, tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 41 * + col1 col1 FROM tab0 cor0
----
3526
3731
3977

query I rowsort
SELECT ALL + col0 + 8 * col0 FROM tab1 AS cor0
----
27
576
720

query I rowsort
SELECT DISTINCT + - 16 FROM tab0 AS cor0
----
-16

query I rowsort
SELECT + 60 + + col0 * col2 FROM tab1 AS cor0
----
222
3708
7740

query I rowsort
SELECT ALL + col1 + col0 * col0 AS col1 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT 62 AS col1 FROM tab2 AS cor0
----
62
62
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5375
SELECT ALL - - CAST( NULL AS SIGNED ) * + 80 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5375
SELECT ALL - - CAST ( NULL AS INTEGER ) * + 80 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( 94 ) FROM tab0 AS cor0
----
94

query I rowsort
SELECT - + 53 * col1 + cor0.col2 * col1 * + col2 AS col2 FROM tab1 AS cor0
----
119119
31960
74438

query I rowsort
SELECT ALL ( col1 ) * - col1 AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT - 49 AS col0 FROM tab2 AS cor0
----
-49

query I rowsort
SELECT - + col2 * - col1 * col1 FROM tab0 AS cor0
----
244068
679042
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-5381
SELECT + 75 + col0 DIV + col1 FROM tab2 AS cor0
----
75
76
79

skipif mysql # not compatible
query I rowsort label-5381
SELECT + 75 + col0 / + col1 FROM tab2 AS cor0
----
75
76
79

query I rowsort
SELECT DISTINCT - col2 * col2 + cor0.col1 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT + cor0.col2 AS col1 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT DISTINCT - - 50 FROM tab0 AS cor0
----
50

query I rowsort
SELECT + 7 FROM tab0, tab1 cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

query I rowsort
SELECT tab1.col2 + + 2 * col2 FROM tab1
----
162
171
288

query I rowsort
SELECT col1 + col2 * + col2 * col1 AS col0 FROM tab0 AS cor0
----
194
611975
93740

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - ( 57 ) * - col2 col0 FROM tab1 AS cor0
----
3132
3306
5568

query I rowsort
SELECT DISTINCT + - col0 + - col0 - - cor0.col1 * col0 * col0 AS col0 FROM tab0 AS cor0
----
118755
49488
720633

query I rowsort
SELECT DISTINCT - 58 FROM tab0, tab2 AS cor0
----
-58

query I rowsort
SELECT ALL col1 + - 38 + + col2 AS col1 FROM tab1
----
29
42
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-5392
SELECT ALL + tab2.col1 DIV 99 + + col1 + tab2.col1 AS col2 FROM tab2
----
118
34
62

skipif mysql # not compatible
query I rowsort label-5392
SELECT ALL + tab2.col1 / 99 + + col1 + tab2.col1 AS col2 FROM tab2
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5393
SELECT DISTINCT cor0.col0 * CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5393
SELECT DISTINCT cor0.col0 * CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col2 * - ( col1 ) FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5395
SELECT - col1 DIV col0 AS col1 FROM tab0 cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-5395
SELECT - col1 / col0 AS col1 FROM tab0 cor0
----
-1
-2
-3

query I rowsort
SELECT + + col1 + col2 * + col0 - + col1 * + col1 FROM tab2 AS cor0
----
-1394
-741
2730

query I rowsort
SELECT DISTINCT cor0.col1 + col1 * - ( col0 + + 87 * col0 ) FROM tab0 AS cor0
----
-181546
-298663
-712621

query I rowsort
SELECT DISTINCT col1 + + col2 * + col0 AS col0 FROM tab1
----
188
3658
7693

query I rowsort
SELECT DISTINCT - col1 + + ( col1 ) AS col2 FROM tab1
----
0

query I rowsort
SELECT ALL - - 87 FROM tab0 AS cor0
----
87
87
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-5401
SELECT + col0 DIV - col1 col0 FROM tab1 AS cor0
----
-6
-6
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5401
SELECT + col0 / - col1 col0 FROM tab1 AS cor0
----
-6
-6
0

query I rowsort
SELECT DISTINCT - col0 + + col2 * + cor0.col1 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT ALL + 10 * + col2 FROM tab0 AS cor0
----
10
330
820

query I rowsort
SELECT + col0 * 60 FROM tab2 AS cor0
----
420
4680
4740

query I rowsort
SELECT - 28 * - 11 + + col2 FROM tab0 AS cor0
----
309
341
390

onlyif mysql # use DIV operator for integer division
query I rowsort label-5406
SELECT DISTINCT cor0.col2 + col1 DIV cor0.col2 AS col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-5406
SELECT DISTINCT cor0.col2 + col1 / cor0.col2 AS col1 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5407
SELECT ALL tab0.col1 DIV - col1 + + ( + col2 + col1 ) AS col2 FROM tab0
----
118
172
97

skipif mysql # not compatible
query I rowsort label-5407
SELECT ALL tab0.col1 / - col1 + + ( + col2 + col1 ) AS col2 FROM tab0
----
118
172
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 69 col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT DISTINCT + col0 * ( - tab1.col2 ) * col0 + tab1.col2 AS col1 FROM tab1
----
-233415
-432
-614304

query I rowsort
SELECT DISTINCT col2 + 32 FROM tab2
----
58
59
70

query I rowsort
SELECT DISTINCT + tab1.col2 * - col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT + cor1.col1 AS col1 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT DISTINCT + tab0.col0 FROM tab0, tab2, tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + - col0 * + col1 * ( + col0 ) FROM tab2 cor0
----
-106097
-1519
-358956

query I rowsort
SELECT cor0.col0 AS col0 FROM tab0, tab2, tab0 cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL col2 * - 31 + col2 AS col2 FROM tab1
----
-1620
-1710
-2880

query I rowsort
SELECT DISTINCT 15 FROM tab1, tab1 AS cor0
----
15

query I rowsort
SELECT + 97 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

onlyif mysql # use DIV operator for integer division
query I rowsort label-5419
SELECT + col2 + - col2 + col1 DIV col1 AS col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5419
SELECT + col2 + - col2 + col1 / col1 AS col0 FROM tab2
----
1
1
1

query I rowsort
SELECT DISTINCT - 31 + col1 + - col0 FROM tab0
----
-29
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - col0 col0 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT - col0 - col0 * col0 AS col0 FROM tab0 cor0
----
-1260
-600
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-5423
SELECT ALL ( + col0 ) DIV tab2.col0 AS col2 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5423
SELECT ALL ( + col0 ) / tab2.col0 AS col2 FROM tab2
----
1
1
1

query I rowsort
SELECT DISTINCT 33 FROM tab0, tab1 AS cor0
----
33

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5425
SELECT DISTINCT + col2 * col1 - + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5425
SELECT DISTINCT + col2 * col1 - + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + + ( - col1 ) * 18 + ( col1 ) AS col0 FROM tab0 AS cor0
----
-1462
-1547
-1649

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 + col1 * + ( col0 ) col2 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-5428
SELECT DISTINCT + + col2 DIV + col2 AS col0 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-5428
SELECT DISTINCT + + col2 / + col2 AS col0 FROM tab1 AS cor0
----
1

query I rowsort
SELECT - cor0.col1 + col2 * col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT - - 89 * - col0 + - 91 FROM tab2 AS cor0
----
-7033
-7122
-714

query I rowsort
SELECT DISTINCT 2 + col0 * - col2 AS col0 FROM tab0
----
-33
-7296
-790

query I rowsort
SELECT ( col0 ) * + col0 + + col1 * col2 AS col2 FROM tab1 cor0
----
1413
4666
7648

query I rowsort
SELECT + 73 + - col0 FROM tab0 cor0
----
-16
38
49

query I rowsort
SELECT + - 11 FROM tab2 AS cor0
----
-11
-11
-11

query I rowsort
SELECT ( col1 ) * col0 * tab2.col1 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT col0 + col2 * + ( col1 ) + tab1.col0 * 6 AS col0 FROM tab1
----
1018
1425
1808

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5437
SELECT - tab0.col0 * + col2 + CAST( NULL AS SIGNED ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5437
SELECT - tab0.col0 * + col2 + CAST ( NULL AS INTEGER ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col1 ) * col2 * col1 + + tab0.col1 * - col1 - + col1 col1 FROM tab0
----
-18915
-251550
-687414

skipif mysql # not compatible
query I rowsort
SELECT ALL - ( col0 ) - - CAST ( + col2 AS REAL ) * - col0 FROM tab1
----
-165
-3712
-7760

query I rowsort
SELECT - col2 * col1 + - col1 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT - cor0.col0 * + col1 + + col1 AS col0 FROM tab0 cor0
----
-1978
-3298
-8008

query I rowsort
SELECT + + cor0.col1 + cor0.col2 + + 67 FROM tab1 AS cor0
----
134
147
176

query I rowsort
SELECT ALL + col1 * + 68 * - col1 AS col2 FROM tab0 AS cor0
----
-502928
-563108
-639812

query I rowsort
SELECT DISTINCT - - col0 + - 34 * 40 FROM tab1 AS cor0
----
-1280
-1296
-1357

query I rowsort
SELECT col2 + 88 AS col0 FROM tab0 AS cor0
----
121
170
89

query I rowsort
SELECT ALL - col1 + ( + col2 ) FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT col2 * - col0 * - col1 + col0 AS col1 FROM tab1 AS cor0
----
36544
4215
99920

query I rowsort
SELECT ALL - cor0.col0 * 96 AS col2 FROM tab2, tab0, tab1 AS cor0, tab1
----
81 values hashing to c1a05c6c513e2c2460288e71fa3f20ca

query I rowsort
SELECT DISTINCT cor0.col1 + - ( col0 ) AS col0 FROM tab0 AS cor0
----
2
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5450
SELECT CAST( + 63 AS SIGNED ) col2 FROM tab0 AS cor0
----
63
63
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5450
SELECT CAST ( + 63 AS INTEGER ) col2 FROM tab0 AS cor0
----
63
63
63

query I rowsort
SELECT - 82 AS col0 FROM tab0 cor0
----
-82
-82
-82

query I rowsort
SELECT + - 89 * - col2 + - col1 AS col0 FROM tab2 cor0
----
2255
2372
3365

query I rowsort
SELECT + - col1 + - cor0.col1 * - cor0.col2 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT + 87 + + col0 FROM tab2 AS cor0
----
165
166
94

onlyif mysql # use DIV operator for integer division
query I rowsort label-5455
SELECT + 37 DIV cor0.col1 col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5455
SELECT + 37 / cor0.col1 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 55 + ( col2 ) FROM tab2 AS cor0
----
-17
-28
-29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 + + col2 col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT col2 + + col2 - col2 AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT col0 * 84 FROM tab2 AS cor0
----
588
6552
6636

query I rowsort
SELECT ALL cor0.col0 * ( cor0.col1 ) * col1 AS col0 FROM tab0 AS cor0
----
177504
329315
737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-5461
SELECT ALL - cor0.col1 + col0 * cor0.col0 DIV col1 AS col2 FROM tab0 AS cor0
----
-4
-80
-85

skipif mysql # not compatible
query I rowsort label-5461
SELECT ALL - cor0.col1 + col0 * cor0.col0 / col1 AS col2 FROM tab0 AS cor0
----
-4
-80
-85

query I rowsort
SELECT + + col2 + cor0.col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL - col1 + col2 + 27 FROM tab2 AS cor0
----
-6
23
48

query I rowsort
SELECT DISTINCT - cor0.col1 * col1 * + col1 AS col0 FROM tab2 AS cor0
----
-205379
-29791
-4913

query I rowsort
SELECT DISTINCT col2 * 30 AS col2 FROM tab2 AS cor0
----
1140
780
810

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5466
SELECT ALL col1 + + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5466
SELECT ALL col1 + + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT tab2.col2 * - tab2.col0 + + 27 FROM tab2
----
-162
-2001
-2975

query I rowsort
SELECT + - 97 FROM tab1 AS cor0
----
-97
-97
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col2 * col0 col0 FROM tab1 AS cor0
----
-207936
-737280
-8748

query I rowsort
SELECT ALL col1 * col0 + col2 * + 53 FROM tab2 AS cor0
----
1648
3357
5980

query I rowsort
SELECT col1 - + ( tab0.col0 ) * + col0 AS col2 FROM tab0
----
-1128
-490
-7830

query I rowsort
SELECT DISTINCT - 64 * - col0 * - 35 FROM tab0 cor0
----
-199360
-53760
-78400

query I rowsort
SELECT ALL + 65 + col2 * - 40 FROM tab2 AS cor0
----
-1015
-1455
-975

query I rowsort
SELECT DISTINCT - 91 AS col1 FROM tab1, tab1 AS cor0
----
-91

query I rowsort
SELECT DISTINCT + - 72 AS col0 FROM tab1 cor0
----
-72

query I rowsort
SELECT 35 * col2 FROM tab2
----
1330
910
945

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 - + col2 * col0 col1 FROM tab0
----
-706
-7207
62

query I rowsort
SELECT cor0.col0 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

onlyif mysql # use DIV operator for integer division
query I rowsort label-5479
SELECT DISTINCT - col2 DIV + col0 + - col0 * 95 AS col2 FROM tab1
----
-303
-6080
-7601

skipif mysql # not compatible
query I rowsort label-5479
SELECT DISTINCT - col2 / + col0 + - col0 * 95 AS col2 FROM tab1
----
-303
-6080
-7601

onlyif mysql # use DIV operator for integer division
query I rowsort label-5480
SELECT + 86 * + col2 * + tab2.col1 + - col1 DIV col1 FROM tab2
----
131923
55555
71981

skipif mysql # not compatible
query I rowsort label-5480
SELECT + 86 * + col2 * + tab2.col1 + - col1 / col1 FROM tab2
----
131923
55555
71981

onlyif mysql # use DIV operator for integer division
query I rowsort label-5481
SELECT DISTINCT + col1 DIV col0 + + ( ( col0 ) + 4 ) AS col0 FROM tab2
----
15
82
83

skipif mysql # not compatible
query I rowsort label-5481
SELECT DISTINCT + col1 / col0 + + ( ( col0 ) + 4 ) AS col0 FROM tab2
----
15
82
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-5482
SELECT + col0 DIV - col0 + + col2 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-5482
SELECT + col0 / - col0 + + col2 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT - col2 * col1 * + col2 AS col0 FROM tab2
----
-22599
-24548
-39884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col2 + col0 * ( col0 * col2 ) col1 FROM tab1
----
229824
324
606720

query I rowsort
SELECT - ( tab1.col1 * - tab1.col0 ) + - col0 AS col1 FROM tab1
----
576
75
960

query I rowsort
SELECT ALL + col1 + col2 * 48 FROM tab2
----
1307
1327
1841

query I rowsort
SELECT DISTINCT - 30 + col0 AS col1 FROM tab1 AS cor0
----
-27
34
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-5488
SELECT + + col1 DIV col2 + + col2 - col1 AS col1 FROM tab0 cor0
----
-51
-8
1

skipif mysql # not compatible
query I rowsort label-5488
SELECT + + col1 / col2 + + col2 - col1 AS col1 FROM tab0 cor0
----
-51
-8
1

query I rowsort
SELECT + + 81 * col2 FROM tab0 AS cor0
----
2673
6642
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - col0 ) col0 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + - col1 + + col1 * cor0.col2 AS col2 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT ALL + cor0.col1 * col2 + - ( + col1 ) * - col1 FROM tab0 AS cor0
----
10234
15743
9506

query I rowsort
SELECT + col2 * col1 * - 1 AS col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + 97 + tab0.col2 AS col0 FROM tab0
----
130
179
98

query I rowsort
SELECT ALL col0 * 52 * col0 AS col0 FROM tab1 AS cor0
----
212992
332800
468

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - 20 col2 FROM tab0
----
1640
20
660

query I rowsort
SELECT DISTINCT + col2 + - ( - 24 ) AS col1 FROM tab0 AS cor0
----
106
25
57

query I rowsort
SELECT DISTINCT + - col1 * + col2 + cor0.col0 FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5499
SELECT DISTINCT CAST( + col0 AS SIGNED ) * col0 + 43 FROM tab2
----
6127
6284
92

skipif mysql # not compatible
query I rowsort label-5499
SELECT DISTINCT CAST ( + col0 AS INTEGER ) * col0 + 43 FROM tab2
----
6127
6284
92

query I rowsort
SELECT 90 * col1 * + col1 FROM tab1
----
15210
60840
9000

query I rowsort
SELECT - - ( 53 ) AS col2 FROM tab0 AS cor0
----
53
53
53

onlyif mysql # use DIV operator for integer division
query I rowsort label-5502
SELECT + ( - 22 ) * + col2 DIV - col2 + - col0 - - col0 * col0 AS col1 FROM tab1
----
28
4054
6342

skipif mysql # not compatible
query I rowsort label-5502
SELECT + ( - 22 ) * + col2 / - col2 + - col0 - - col0 * col0 AS col1 FROM tab1
----
28
4054
6342

query I rowsort
SELECT DISTINCT tab0.col0 + + tab0.col0 AS col0 FROM tab0
----
178
48
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5504
SELECT CAST( + 28 AS SIGNED ) * col2 * + col0 + col2 FROM tab1
----
102201
215136
4590

skipif mysql # not compatible
query I rowsort label-5504
SELECT CAST ( + 28 AS INTEGER ) * col2 * + col0 + col2 FROM tab1
----
102201
215136
4590

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0, tab1 AS cor1, tab2, tab0 cor2
----
3645 values hashing to fb1fb273a543ea33958edfcaa2e7ed26

query I rowsort
SELECT DISTINCT - ( + col1 ) + - col0 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT - col1 * 37 + col1 * - 48 AS col2 FROM tab2 AS cor0
----
-1445
-2635
-5015

query I rowsort
SELECT - 59 * col2 FROM tab2 AS cor0
----
-1534
-1593
-2242

query I rowsort
SELECT DISTINCT + - ( col2 ) * + col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5510
SELECT DISTINCT + cor0.col2 DIV + 23 AS col0 FROM tab1 AS cor0
----
2
4

skipif mysql # not compatible
query I rowsort label-5510
SELECT DISTINCT + cor0.col2 / + 23 AS col0 FROM tab1 AS cor0
----
2
4

query I rowsort
SELECT ALL cor0.col0 * col0 AS col2 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT 37 + col0 * col2 AS col2 FROM tab1 AS cor0
----
199
3685
7717

query I rowsort
SELECT + 38 + col2 * - col2 FROM tab0 cor0
----
-1051
-6686
37

query I rowsort
SELECT DISTINCT col2 * - col1 * 22 FROM tab0 AS cor0
----
-164164
-2134
-62436

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + - col1 * 50 col0 FROM tab2 AS cor0
----
-1543
-2872
-771

query I rowsort
SELECT ALL - - 56 + col2 AS col1 FROM tab1 AS cor0
----
110
113
152

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 * + col2 + - ( cor0.col2 * col2 ) + col1 col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL ( + col0 ) * - 95 FROM tab1 AS cor0
----
-285
-6080
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-5519
SELECT - + col1 * + cor0.col0 + 67 * + 19 + col1 DIV col1 FROM tab1 AS cor0
----
1196
234
634

skipif mysql # not compatible
query I rowsort label-5519
SELECT - + col1 * + cor0.col0 + 67 * + 19 + col1 / col1 FROM tab1 AS cor0
----
1196
234
634

onlyif mysql # use DIV operator for integer division
query I rowsort label-5520
SELECT - - col0 DIV + col0 + + col1 * - col0 - + col0 AS col2 FROM tab1 AS cor0
----
-1119
-703
-80

skipif mysql # not compatible
query I rowsort label-5520
SELECT - - col0 / + col0 + + col1 * - col0 - + col0 AS col2 FROM tab1 AS cor0
----
-1119
-703
-80

query I rowsort
SELECT + col1 + - cor0.col2 + - 93 * cor0.col2 FROM tab0 cor0
----
-3016
-7617
3

query I rowsort
SELECT 30 + + col2 * + col0 * col2 - - col0 AS col0 FROM tab2
----
114185
5140
52836

query I rowsort
SELECT ( + ( + col1 ) ) * 74 * + 55 - - col0 AS col0 FROM tab0
----
350044
370459
394825

query I rowsort
SELECT DISTINCT ( - col1 ) * - 10 FROM tab0 AS cor0
----
860
910
970

query I rowsort
SELECT DISTINCT - + col2 * cor0.col0 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5526
SELECT + + cor0.col1 / + col2 + CAST( NULL AS SIGNED ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5526
SELECT + + cor0.col1 / + col2 + CAST ( NULL AS INTEGER ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - + 93 col2 FROM tab0
----
-4
-58
-69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - ( + col0 ) * 36 col0 FROM tab2 cor0
----
-259
-2886
-2923

query I rowsort
SELECT + ( col1 ) * - col1 AS col0 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT - - col0 - - col0 * - col0 AS col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT col0 + + col2 AS col1 FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5532
SELECT + 5 DIV + ( col2 ) AS col0 FROM tab0 AS cor0
----
0
0
5

skipif mysql # not compatible
query I rowsort label-5532
SELECT + 5 / + ( col2 ) AS col0 FROM tab0 AS cor0
----
0
0
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5533
SELECT ALL + col1 * CAST( NULL AS SIGNED ) / tab1.col0 + + col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5533
SELECT ALL + col1 * CAST ( NULL AS INTEGER ) / tab1.col0 + + col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5534
SELECT ALL - CAST( + 29 AS SIGNED ) AS col1 FROM tab2
----
-29
-29
-29

skipif mysql # not compatible
query I rowsort label-5534
SELECT ALL - CAST ( + 29 AS INTEGER ) AS col1 FROM tab2
----
-29
-29
-29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col0 ) + - cor0.col1 col0 FROM tab0 AS cor0
----
-2
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - ( col0 ) col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL + 56 * + col1 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
1709
3278
914

query I rowsort
SELECT + + ( - col1 ) + - cor0.col2 * - 80 FROM tab0 AS cor0
----
-17
2554
6469

onlyif mysql # use DIV operator for integer division
query I rowsort label-5539
SELECT ALL + ( col1 ) DIV col0 AS col0 FROM tab1
----
0
0
8

skipif mysql # not compatible
query I rowsort label-5539
SELECT ALL + ( col1 ) / col0 AS col0 FROM tab1
----
0
0
8

query I rowsort
SELECT DISTINCT - tab2.col0 FROM tab2, tab1 cor0
----
-7
-78
-79

query I rowsort
SELECT ALL + 30 * + col0 AS col2 FROM tab2
----
210
2340
2370

query I rowsort
SELECT ALL - 97 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 12bd12d33f03250bee508c5641e140d5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col0 col2 FROM tab1, tab2 cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5544
SELECT - col1 + + col0 DIV - 58 FROM tab2
----
-18
-31
-60

skipif mysql # not compatible
query I rowsort label-5544
SELECT - col1 + + col0 / - 58 FROM tab2
----
-18
-31
-60

query I rowsort
SELECT DISTINCT - tab0.col0 AS col1 FROM tab0, tab1 AS cor0
----
-24
-35
-89

query I rowsort
SELECT 81 * col1 + 8 FROM tab1
----
1061
2114
818

query I rowsort
SELECT - ( + tab1.col1 + + tab1.col2 ) FROM tab1
----
-109
-67
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + col1 * + 26 col2 FROM tab1 AS cor0
----
196
258
673

query I rowsort
SELECT - col0 * col0 - + col2 AS col2 FROM tab0 AS cor0
----
-1226
-609
-8003

query I rowsort
SELECT ALL + cor0.col0 * + col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL + + col0 + + col1 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL - col1 * ( col0 ) + col2 * 11 FROM tab0 AS cor0
----
-1701
-3384
-7197

query I rowsort
SELECT DISTINCT col0 * - col1 + 45 AS col1 FROM tab1 AS cor0
----
-33
-595
-995

query I rowsort
SELECT ALL + col2 * col1 + + col2 AS col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT + cor0.col1 - - col0 AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - col1 * - tab1.col1 AS col2 FROM tab1
----
100
169
676

query I rowsort
SELECT DISTINCT + 50 FROM tab0, tab1 AS cor0
----
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * + col0 col1 FROM tab0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5559
SELECT ALL col0 * + CAST( NULL AS DECIMAL ) AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5559
SELECT ALL col0 * + CAST ( NULL AS REAL ) AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - + cor0.col2 * + ( col2 ) AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + - col2 * 88 AS col0 FROM tab2 cor0
----
-2288
-2376
-3344

query I rowsort
SELECT + + col0 * - col0 * - col2 AS col2 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT - 97 - + col0 AS col2 FROM tab0 cor0
----
-121
-132
-186

query I rowsort
SELECT DISTINCT col1 * col0 * + col1 FROM tab2 AS cor0
----
22831
271518
6727

query I rowsort
SELECT cor0.col1 - col0 * + cor0.col2 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL ( 54 ) AS col1 FROM tab0 AS cor0
----
54
54
54

query I rowsort
SELECT DISTINCT - - col2 + ( col2 ) * col2 AS col1 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT + - cor0.col1 + + col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5569
SELECT + CAST( NULL AS SIGNED ) * + 25 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5569
SELECT + CAST ( NULL AS INTEGER ) * + 25 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5570
SELECT ALL ( 8 ) DIV col1 AS col0 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5570
SELECT ALL ( 8 ) / col1 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL - 66 FROM tab0, tab1 cor0, tab0 AS cor1
----
27 values hashing to cd4a3594ee8b45223ebf9f25840cd112

query I rowsort
SELECT - - 71 - + 23 FROM tab1 AS cor0
----
48
48
48

query I rowsort
SELECT ALL - + col2 - - 34 AS col1 FROM tab1 cor0
----
-20
-23
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + 51 * + col1 col0 FROM tab1 AS cor0
----
1380
567
759

query I rowsort
SELECT - 58 * 86 + + cor0.col1 AS col2 FROM tab0 AS cor0
----
-4891
-4897
-4902

query I rowsort
SELECT + col1 * + col1 + 37 FROM tab2 AS cor0
----
326
3518
998

query I rowsort
SELECT + - col1 * col1 + 70 AS col1 FROM tab0 cor0
----
-7326
-8211
-9339

query I rowsort
SELECT - col1 * - col0 + col2 + - 69 FROM tab0 AS cor0
----
2028
3327
8112

query I rowsort
SELECT + - 93 AS col1 FROM tab2 AS cor0
----
-93
-93
-93

query I rowsort
SELECT + ( + cor0.col0 ) * 46 FROM tab0 AS cor0
----
1104
1610
4094

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5581
SELECT ALL CAST( NULL AS SIGNED ) col2 FROM tab0, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5581
SELECT ALL CAST ( NULL AS INTEGER ) col2 FROM tab0, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + col1 + + ( + col2 ) * col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT + 76 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

query I rowsort
SELECT + tab2.col0 FROM tab2, tab0 cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT + 17 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
17

query I rowsort
SELECT DISTINCT cor0.col1 AS col2 FROM tab0, tab2 cor0
----
17
31
59

query I rowsort
SELECT DISTINCT 13 + + col2 * - col1 AS col1 FROM tab1
----
-1235
-1391
-557

query I rowsort
SELECT 95 * col0 FROM tab1
----
285
6080
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-5589
SELECT DISTINCT ( 47 ) DIV - col0 + 76 FROM tab1
----
61
76

skipif mysql # not compatible
query I rowsort label-5589
SELECT DISTINCT ( 47 ) / - col0 + 76 FROM tab1
----
61
76

query I rowsort
SELECT 70 * + col2 - col2 AS col1 FROM tab0
----
2277
5658
69

query I rowsort
SELECT - col1 * ( - col1 ) FROM tab1 AS cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-5592
SELECT - 39 + ( col0 ) * + col0 + col2 DIV col1 FROM tab2 cor0
----
10
6045
6204

skipif mysql # not compatible
query I rowsort label-5592
SELECT - 39 + ( col0 ) * + col0 + col2 / col1 FROM tab2 cor0
----
10
6045
6204

query I rowsort
SELECT 44 FROM tab1, tab2 cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

onlyif mysql # use DIV operator for integer division
query I rowsort label-5594
SELECT DISTINCT col2 DIV + col2 + - col1 col0 FROM tab0
----
-85
-90
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5594
SELECT DISTINCT col2 / + col2 + - col1 col0 FROM tab0
----
-85
-90
-96

query I rowsort
SELECT ALL - cor0.col1 * 42 AS col2 FROM tab1 cor0
----
-1092
-420
-546

query I rowsort
SELECT ALL 59 AS col1 FROM tab2 AS cor0
----
59
59
59

query I rowsort
SELECT ALL 92 + - col0 FROM tab1 AS cor0
----
12
28
89

query I rowsort
SELECT DISTINCT - - col2 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - 77 * + col1 FROM tab0 AS cor0
----
-6622
-7007
-7469

query I rowsort
SELECT DISTINCT - 41 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
1271
2419
697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - col0 col2 FROM tab1 cor0
----
-128
-160
-6

query I rowsort
SELECT + cor0.col1 + col1 * - 16 FROM tab0 AS cor0
----
-1290
-1365
-1455

query I rowsort
SELECT DISTINCT - + col2 - col0 AS col1 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5604
SELECT ALL - col1 + col1 DIV col2 col2 FROM tab0 AS cor0
----
-84
-90
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5604
SELECT ALL - col1 + col1 / col2 col2 FROM tab0 AS cor0
----
-84
-90
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * cor0.col2 col1 FROM tab2 cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-5606
SELECT 72 DIV - col0 - col0 DIV ( tab2.col0 ) FROM tab2
----
-1
-1
-11

skipif mysql # not compatible
query I rowsort label-5606
SELECT 72 / - col0 - col0 / ( tab2.col0 ) FROM tab2
----
-1
-1
-11

query I rowsort
SELECT DISTINCT col2 + ( col0 ) FROM tab1
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-5608
SELECT DISTINCT 76 DIV - 94 + col1 AS col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-5608
SELECT DISTINCT 76 / - 94 + col1 AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT ( col1 * + col2 ) + + ( ( + col1 ) ) AS col1 FROM tab0
----
194
2924
7553

query I rowsort
SELECT ( cor0.col0 ) * col2 AS col2 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 16 + col0 col2 FROM tab1 cor0
----
19
80
96

query I rowsort
SELECT ALL 60 * col1 - col2 FROM tab2 AS cor0
----
1833
3514
982

onlyif mysql # use DIV operator for integer division
query I rowsort label-5613
SELECT DISTINCT - col2 DIV + cor0.col0 + 23 FROM tab2 AS cor0
----
20
23

skipif mysql # not compatible
query I rowsort label-5613
SELECT DISTINCT - col2 / + cor0.col0 + 23 FROM tab2 AS cor0
----
20
23

query I rowsort
SELECT ALL + col0 * - 24 * + col0 + col2 FROM tab1 AS cor0
----
-153504
-162
-98247

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col1 * + 16 col0 FROM tab2 AS cor0
----
1003
289
527

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 + + 59 col1 FROM tab1 AS cor0
----
-37
2
5

query I rowsort
SELECT ALL + col2 * col1 + - col2 + cor0.col0 * - 94 FROM tab2 AS cor0
----
-5824
-6818
152

onlyif mysql # use DIV operator for integer division
query I rowsort label-5618
SELECT - - col1 + + col1 DIV 47 col1 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5618
SELECT - - col1 + + col1 / 47 col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT col1 * 18 FROM tab0 cor0
----
1548
1638
1746

onlyif mysql # use DIV operator for integer division
query I rowsort label-5620
SELECT col1 DIV CAST( col0 AS SIGNED ) + col1 + CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
-20
-47
-83

skipif mysql # not compatible
query I rowsort label-5620
SELECT col1 / CAST ( col0 AS INTEGER ) + col1 + CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
-20
-47
-83

query I rowsort
SELECT + col2 + - col1 + + cor0.col2 AS col0 FROM tab2 AS cor0
----
-7
23
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - 44 * + col0 col0 FROM tab1 AS cor0
----
180224
281600
396

query I rowsort
SELECT + + col0 * - col2 * - col2 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT - col0 * 78 + + 21 FROM tab1 cor0
----
-213
-4971
-6219

query I rowsort
SELECT DISTINCT - - col0 * 65 FROM tab1 AS cor0
----
195
4160
5200

query I rowsort
SELECT col0 * ( col0 ) - col0 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5627
SELECT DISTINCT - + col0 DIV 60 AS col1 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-5627
SELECT DISTINCT - + col0 / 60 AS col1 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT + col2 * - 13 FROM tab0 AS cor0
----
-1066
-13
-429

query I rowsort
SELECT DISTINCT col2 * - ( + col2 ) * - col2 AS col2 FROM tab1 AS cor0
----
157464
185193
884736

query I rowsort
SELECT ( - col0 ) * + col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT - col2 * ( - tab0.col2 ) FROM tab0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 20 col1 FROM tab2 AS cor0
----
20
20
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 5 + col1 * col0 col0 FROM tab1 AS cor0
----
1045
645
83

query I rowsort
SELECT DISTINCT + + ( - col2 ) FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL col0 * tab2.col1 * col0 - - tab2.col0 AS col0 FROM tab2
----
106176
1526
359034

query I rowsort
SELECT DISTINCT + col2 * col0 - - 11 FROM tab2
----
200
2039
3013

query I rowsort
SELECT col2 - ( col2 ) * col1 AS col1 FROM tab2
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * + col1 * col0 + col2 col0 FROM tab0 cor0
----
-118824
-49503
-720729

onlyif mysql # use DIV operator for integer division
query I rowsort label-5639
SELECT + + 45 DIV col0 - cor0.col2 col1 FROM tab1 cor0
----
-39
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5639
SELECT + + 45 / col0 - cor0.col2 col1 FROM tab1 cor0
----
-39
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col0 col0 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5641
SELECT DISTINCT CAST( col0 AS SIGNED ) * cor0.col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-5641
SELECT DISTINCT CAST ( col0 AS INTEGER ) * cor0.col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5642
SELECT + col0 DIV + 41 - + col0 FROM tab0 cor0
----
-24
-35
-87

skipif mysql # not compatible
query I rowsort label-5642
SELECT + col0 / + 41 - + col0 FROM tab0 cor0
----
-24
-35
-87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 25 col0 FROM tab1 AS cor0
----
25
25
25

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5644
SELECT ALL - CAST( 99 AS SIGNED ) * - col2 AS col1 FROM tab0 AS cor0
----
3267
8118
99

skipif mysql # not compatible
query I rowsort label-5644
SELECT ALL - CAST ( 99 AS INTEGER ) * - col2 AS col1 FROM tab0 AS cor0
----
3267
8118
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-5645
SELECT ALL + col2 DIV + col0 + col0 + + col0 FROM tab0 cor0
----
178
49
70

skipif mysql # not compatible
query I rowsort label-5645
SELECT ALL + col2 / + col0 + col0 + + col0 FROM tab0 cor0
----
178
49
70

query I rowsort
SELECT ( 52 ) * + cor0.col1 - - col1 * col2 AS col2 FROM tab0 AS cor0
----
12194
5141
7310

onlyif mysql # use DIV operator for integer division
query I rowsort label-5647
SELECT DISTINCT - - 15 DIV - col2 FROM tab0 AS cor0
----
-15
0

skipif mysql # not compatible
query I rowsort label-5647
SELECT DISTINCT - - 15 / - col2 FROM tab0 AS cor0
----
-15
0

query I rowsort
SELECT ALL + ( + col2 ) * cor0.col2 AS col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT 86 + - col1 AS col1 FROM tab2 AS cor0
----
27
55
69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5650
SELECT DISTINCT col1 * + CAST( NULL AS SIGNED ) + 34 - col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5650
SELECT DISTINCT col1 * + CAST ( NULL AS INTEGER ) + 34 - col2 FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5651
SELECT + col0 DIV 32 + + col2 * + 45 AS col1 FROM tab0 AS cor0
----
1485
3692
46

skipif mysql # not compatible
query I rowsort label-5651
SELECT + col0 / 32 + + col2 * + 45 AS col1 FROM tab0 AS cor0
----
1485
3692
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5652
SELECT + CAST( NULL AS SIGNED ) + col0 - cor0.col0 * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5652
SELECT + CAST ( NULL AS INTEGER ) + col0 - cor0.col0 * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL tab2.col2 - + 91 FROM tab2
----
-53
-64
-65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5654
SELECT ALL CAST( NULL AS SIGNED ) + + tab1.col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5654
SELECT ALL CAST ( NULL AS INTEGER ) + + tab1.col2 FROM tab1
----
NULL
NULL
NULL

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab2, tab0 cor2
----
13122 values hashing to 6f2487ea4352049f390202030059e970

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( + col1 ) * + col1 + col1 * + cor0.col0 col1 FROM tab0 AS cor0
----
12804
16380
9460

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0 CROSS JOIN tab2, tab1 cor1
----
972 values hashing to dd771e0c15d524f62127686e9bd43f9a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 38 + col0 col2 FROM tab2
----
116
117
45

query I rowsort
SELECT ALL 53 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to fede6033dee346dbd272085c05724fda

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5660
SELECT DISTINCT - col2 * + CAST( + col1 AS SIGNED ) - + col1 col1 FROM tab0 AS cor0
----
-194
-2924
-7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5660
SELECT DISTINCT - col2 * + CAST ( + col1 AS INTEGER ) - + col1 col1 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT ALL cor0.col1 + cor2.col1 FROM tab2, tab1 AS cor0, tab2 AS cor1, tab1, tab2 AS cor2
----
243 values hashing to 096cca2306bf01744e30614086f6d629

query I rowsort
SELECT ALL - - col1 * 42 + - col0 * - col1 + - col2 AS col1 FROM tab0 cor0
----
11839
5643
7468

query I rowsort
SELECT - cor0.col0 + + 12 FROM tab0 AS cor0
----
-12
-23
-77

query I rowsort
SELECT DISTINCT - + 21 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
-21

query I rowsort
SELECT col2 * cor0.col0 * ( col2 ) FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT DISTINCT col1 + 41 AS col0 FROM tab1 AS cor0
----
51
54
67

query I rowsort
SELECT + col1 * + 76 + + col1 AS col2 FROM tab0
----
6622
7007
7469

query I rowsort
SELECT DISTINCT - - col1 + col2 + + 63 AS col0 FROM tab1 AS cor0
----
130
143
172

query I rowsort
SELECT + col1 * + 0 AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5670
SELECT ALL - col0 * - CAST( NULL AS SIGNED ) + + cor0.col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5670
SELECT ALL - col0 * - CAST ( NULL AS INTEGER ) + + cor0.col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 + + col2 * cor0.col2 * col1 AS col1 FROM tab1 cor0
----
119712
32433
75762

query I rowsort
SELECT ALL - - col1 + 35 AS col1 FROM tab2 AS cor0
----
52
66
94

query I rowsort
SELECT DISTINCT - col1 * 23 AS col1 FROM tab0 AS cor0
----
-1978
-2093
-2231

query I rowsort
SELECT 93 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 85ef191bf1b307f300b3fd49992fcae7

onlyif mysql # use DIV operator for integer division
query I rowsort label-5675
SELECT ALL - 13 DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5675
SELECT ALL - 13 / col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - 55 * - col1 AS col1 FROM tab2 AS cor0
----
1705
3245
935

query I rowsort
SELECT + + col1 + col2 * 37 FROM tab1 AS cor0
----
2024
2119
3565

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * - col1 col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT col2 * + 42 FROM tab2 AS cor0
----
1092
1134
1596

query I rowsort
SELECT - cor0.col2 - + ( cor0.col1 * + col2 ) FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT DISTINCT 95 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
95

query I rowsort
SELECT - 93 + - 1 * tab0.col1 AS col2 FROM tab0, tab2 AS cor0, tab2 cor1
----
27 values hashing to d455f20111ac51dd959f7565a6476986

query I rowsort
SELECT DISTINCT 36 + 12 FROM tab0 AS cor0
----
48

query I rowsort
SELECT col1 * + tab0.col1 * + 89 FROM tab0
----
658244
737009
837401

query I rowsort
SELECT + col2 * - ( - tab2.col1 ) FROM tab2
----
1534
646
837

query I rowsort
SELECT - ( 50 ) + col2 * - col2 FROM tab1 AS cor0
----
-2966
-3299
-9266

query I rowsort
SELECT DISTINCT + 34 * tab2.col1 AS col0 FROM tab2
----
1054
2006
578

onlyif mysql # use DIV operator for integer division
query I rowsort label-5688
SELECT ALL col0 DIV ( - col1 ) AS col0 FROM tab2
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-5688
SELECT ALL col0 / ( - col1 ) AS col0 FROM tab2
----
-1
-4
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5689
SELECT 38 + + col1 DIV cor0.col2 AS col2 FROM tab1 AS cor0
----
38
38
38

skipif mysql # not compatible
query I rowsort label-5689
SELECT 38 + + col1 / cor0.col2 AS col2 FROM tab1 AS cor0
----
38
38
38

query I rowsort
SELECT + tab0.col2 * + 51 + - col0 FROM tab0
----
16
1659
4093

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 15 col0 FROM tab2
----
-15
-15
-15

query I rowsort
SELECT ALL - - 43 + - cor0.col1 AS col0 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to e44fcb666fe99338936597184de154f4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5693
SELECT DISTINCT - CAST( NULL AS SIGNED ) * col0 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5693
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * col0 FROM tab2
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 col2 FROM tab0, tab1 cor0, tab0 AS cor1
----
54
57
96

query I rowsort
SELECT DISTINCT - 32 * ( col1 ) AS col1 FROM tab0
----
-2752
-2912
-3104

query I rowsort
SELECT ALL + - col2 - col1 * - ( + cor0.col2 ) AS col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT DISTINCT + col1 * + col1 + - ( - cor0.col1 ) FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT ALL cor0.col0 + + col0 FROM tab0 cor0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-5699
SELECT ALL + cor0.col0 - col0 DIV + 73 AS col0 FROM tab0 cor0
----
24
35
88

skipif mysql # not compatible
query I rowsort label-5699
SELECT ALL + cor0.col0 - col0 / + 73 AS col0 FROM tab0 cor0
----
24
35
88

query I rowsort
SELECT + 65 AS col2 FROM tab0, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 1c9d0bf96cd3361942fadad668138b9c

query I rowsort
SELECT DISTINCT - 88 AS col2 FROM tab0, tab2 AS cor0
----
-88

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 cor0 CROSS JOIN tab1 AS cor1
----
243 values hashing to 9ed1a6a444254225f040123c46b7f70c

query I rowsort
SELECT - + 77 AS col1 FROM tab0 AS cor0
----
-77
-77
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 col0 FROM tab2, tab2 AS cor0, tab2 cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL col1 * - 98 AS col2 FROM tab2
----
-1666
-3038
-5782

query I rowsort
SELECT ALL col2 * 12 FROM tab2
----
312
324
456

query I rowsort
SELECT col0 * 14 AS col2 FROM tab2
----
1092
1106
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 * 22 col0 FROM tab0
----
1958
528
770

query I rowsort
SELECT DISTINCT 24 AS col0 FROM tab1, tab2 AS cor0
----
24

query I rowsort
SELECT DISTINCT tab2.col0 * - tab2.col1 FROM tab2, tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + col1 + - ( + col1 ) - col0 * - col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT col1 * col0 + + col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT - cor0.col0 + + col2 * col1 AS col1 FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # use DIV operator for integer division
query I rowsort label-5714
SELECT 55 DIV cor1.col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to eff82df49d5880477456e4901e030e04

skipif mysql # not compatible
query I rowsort label-5714
SELECT 55 / cor1.col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to eff82df49d5880477456e4901e030e04

query I rowsort
SELECT - col2 + + col2 + tab1.col2 FROM tab1
----
54
57
96

query I rowsort
SELECT - col0 + + cor0.col0 * + col2 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT + - cor0.col1 * 28 * col0 FROM tab0 AS cor0
----
-226772
-57792
-95060

query I rowsort
SELECT DISTINCT + 50 * 7 - - col1 FROM tab2 AS cor0
----
367
381
409

query I rowsort
SELECT + 56 + + col0 AS col2 FROM tab0 AS cor0
----
145
80
91

query I rowsort
SELECT ALL + - col2 + 28 * col2 FROM tab2 AS cor0
----
1026
702
729

query I rowsort
SELECT DISTINCT col0 + 56 AS col2 FROM tab0 cor0
----
145
80
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-5722
SELECT - col2 + - col0 DIV - col0 AS col0 FROM tab2 AS cor0
----
-25
-26
-37

skipif mysql # not compatible
query I rowsort label-5722
SELECT - col2 + - col0 / - col0 AS col0 FROM tab2 AS cor0
----
-25
-26
-37

query I rowsort
SELECT - 90 + col1 AS col1 FROM tab2 AS cor0
----
-31
-59
-73

query I rowsort
SELECT - + cor0.col1 * - 86 + col1 FROM tab2 AS cor0
----
1479
2697
5133

query I rowsort
SELECT ( - col1 ) + col2 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT + col2 * col0 * - col0 AS col0 FROM tab2
----
-1323
-158184
-237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-5727
SELECT DISTINCT - col2 DIV + col2 FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-5727
SELECT DISTINCT - col2 / + col2 FROM tab1
----
-1

query I rowsort
SELECT - col1 + + col0 - col1 AS col0 FROM tab0
----
-148
-159
-93

query I rowsort
SELECT ALL col0 * - col0 + - col1 * - tab0.col2 * + col0 + tab0.col0 AS col0 FROM tab0
----
2205
656286
67560

query I rowsort
SELECT ALL + col2 + col2 + - col0 FROM tab1
----
105
112
50

query I rowsort
SELECT - tab0.col0 * col0 * tab0.col2 + col2 AS col1 FROM tab0
----
-1224
-18975
-649440

query I rowsort
SELECT ALL + col1 * col1 + - col2 FROM tab2
----
251
3455
934

onlyif mysql # use DIV operator for integer division
query I rowsort label-5733
SELECT DISTINCT - col0 DIV col0 AS col0 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-5733
SELECT DISTINCT - col0 / col0 AS col0 FROM tab0
----
-1

query I rowsort
SELECT ALL - col2 FROM tab0 WHERE NOT NULL NOT IN ( col0 )
----

query I rowsort
SELECT col0 - - col0 * + col1 AS col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT DISTINCT col0 + - col1 * - col1 + - col1 FROM tab2
----
3500
351
937

query I rowsort
SELECT + col2 * col1 + - tab0.col0 FROM tab0
----
2814
62
7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-5738
SELECT DISTINCT - tab1.col0 DIV + col2 AS col2 FROM tab1
----
-1
0

skipif mysql # not compatible
query I rowsort label-5738
SELECT DISTINCT - tab1.col0 / + col2 AS col2 FROM tab1
----
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5739
SELECT DISTINCT + col1 DIV + tab1.col2 col2 FROM tab1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5739
SELECT DISTINCT + col1 / + tab1.col2 col2 FROM tab1
----
0

query I rowsort
SELECT ALL tab0.col0 + - col1 * - col0 * + tab0.col2 + + col1 FROM tab0
----
3527
664298
68222

query I rowsort
SELECT tab0.col0 * col1 * tab0.col1 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT + col1 + col0 * col0 FROM tab1
----
35
4106
6413

query I rowsort
SELECT ALL - col1 * + col0 * + col2 FROM tab2
----
-119652
-51034
-5859

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( NULL ) = ( NULL )
----

query I rowsort
SELECT - col2 - + col2 * + col2 FROM tab1
----
-2970
-3306
-9312

query I rowsort
SELECT ALL + tab2.col1 * col2 * tab2.col0 + col0 AS col1 FROM tab2
----
119730
51113
5866

onlyif mysql # use DIV operator for integer division
query I rowsort label-5747
SELECT tab1.col0 + + col2 DIV tab1.col1 FROM tab1
----
5
69
87

skipif mysql # not compatible
query I rowsort label-5747
SELECT tab1.col0 + + col2 / tab1.col1 FROM tab1
----
5
69
87

query I rowsort
SELECT DISTINCT - col1 + col1 * + col2 AS col1 FROM tab0
----
0
2752
7371

query I rowsort
SELECT col1 * col1 * + col1 FROM tab0
----
636056
753571
912673

query I rowsort
SELECT ALL tab2.col2 * col2 + - col1 * + col0 FROM tab2
----
-3926
101
512

query I rowsort
SELECT ALL - tab0.col2 * col2 * col1 AS col1 FROM tab0
----
-611884
-93654
-97

query I rowsort
SELECT col2 * - col1 * col1 + - col2 FROM tab0
----
-244101
-679124
-9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-5753
SELECT DISTINCT col2 + - col1 DIV col0 FROM tab0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-5753
SELECT DISTINCT col2 + - col1 / col0 FROM tab0
----
-1
30
81

query I rowsort
SELECT - col0 + col0 * - cor0.col2 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT DISTINCT cor0.col1 + col1 * col1 AS col1 FROM tab0 AS cor0
----
7482
8372
9506

query III rowsort
SELECT * FROM tab2 cor0 WHERE NOT + col0 * + col2 + col0 * - cor0.col0 BETWEEN ( NULL ) AND ( col2 * col1 + + col1 * + cor0.col1 )
----

query I rowsort
SELECT - col1 * col0 - col1 AS col2 FROM tab2
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT - col2 * - col1 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + col1 * col0 + - col2 * col1 * + col0 AS col0 FROM tab0 AS cor0 WHERE NOT + col0 NOT BETWEEN col1 AND col1
----

query I rowsort
SELECT ALL - - col2 * - col0 + 4 AS col1 FROM tab1 AS cor0
----
-158
-3644
-7676

query I rowsort
SELECT + - col1 * - ( - ( + col1 ) ) AS col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL col1 * - ( col0 * cor0.col1 ) + col2 AS col2 FROM tab0 AS cor0
----
-177471
-329314
-736927

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * - col0 col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - - col2 + - 20 FROM tab1 AS cor0
----
34
37
76

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 AS cor2, tab0 AS cor3
----
3645 values hashing to ac17da4547aa356439ff11568174588c

query I rowsort
SELECT ALL col0 * + 12 FROM tab1
----
36
768
960

query I rowsort
SELECT ALL - cor0.col1 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT ALL - - cor0.col2 * + col2 FROM tab0 AS cor0
----
1
1089
6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5769
SELECT cor0.col0 * - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5769
SELECT cor0.col0 * - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5770
SELECT col0 DIV + 49 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-5770
SELECT col0 / + 49 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT ALL - col2 + - col1 * - col1 FROM tab0 AS cor0
----
7363
8199
9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-5772
SELECT + + col0 DIV - ( - col1 ) AS col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-5772
SELECT + + col0 / - ( - col1 ) AS col1 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT ALL - cor0.col1 * - 3 AS col0 FROM tab0 AS cor0
----
258
273
291

onlyif mysql # use DIV operator for integer division
query I rowsort label-5774
SELECT DISTINCT cor0.col0 DIV - cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-5774
SELECT DISTINCT cor0.col0 / - cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT ALL - cor0.col1 * col1 * - col0 AS col0 FROM tab1 cor0
----
13520
2028
6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-5776
SELECT DISTINCT + col2 + 98 DIV - 27 FROM tab1 AS cor0
----
51
54
93

skipif mysql # not compatible
query I rowsort label-5776
SELECT DISTINCT + col2 + 98 / - 27 FROM tab1 AS cor0
----
51
54
93

query I rowsort
SELECT DISTINCT + 76 + - col2 FROM tab0 AS cor0
----
-6
43
75

query I rowsort
SELECT ALL + 79 + col0 * 53 FROM tab1 AS cor0
----
238
3471
4319

query I rowsort
SELECT DISTINCT - col2 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
-21
33
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 95 + col0 - 16 col2 FROM tab0 cor0
----
-22
-76
-87

query I rowsort
SELECT DISTINCT + 74 + col2 AS col1 FROM tab2 AS cor0
----
100
101
112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col2 * tab0.col1 col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT ALL tab1.col0 + col2 FROM tab1 WHERE NULL BETWEEN ( NULL ) AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5784
SELECT + col1 DIV col1 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5784
SELECT + col1 / col1 AS col1 FROM tab1
----
1
1
1

query I rowsort
SELECT ALL col1 AS col1 FROM tab2 WHERE col1 + + col1 IN ( col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 * col1 col2 FROM tab2
----
1343
217
4602

query III rowsort
SELECT * FROM tab0 WHERE NOT + col0 / + col1 + + col1 NOT IN ( + tab0.col1 + - tab0.col2 )
----

query I rowsort
SELECT DISTINCT tab1.col1 * + col1 AS col0 FROM tab1
----
100
169
676

query I rowsort
SELECT col2 * - col2 * - tab0.col2 AS col2 FROM tab0
----
1
35937
551368

onlyif mysql # use DIV operator for integer division
query I rowsort label-5790
SELECT + col0 + col1 DIV col0 + + col1 AS col2 FROM tab1
----
37
74
93

skipif mysql # not compatible
query I rowsort label-5790
SELECT + col0 + col1 / col0 + + col1 AS col2 FROM tab1
----
37
74
93

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT + col0 + + col2 BETWEEN ( NULL ) AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 88 col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

query I rowsort
SELECT + col0 + + tab0.col1 FROM tab0
----
110
132
180

query I rowsort
SELECT - cor0.col1 + - cor0.col2 + - col0 FROM tab2 AS cor0
----
-134
-163
-65

query I rowsort
SELECT 83 AS col2 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 002a717a3d902d97220759065fb107c3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 27 col0 FROM tab1
----
27
27
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-5797
SELECT DISTINCT col1 DIV col2 + 37 + col1 FROM tab1 AS cor0
----
47
50
63

skipif mysql # not compatible
query I rowsort label-5797
SELECT DISTINCT col1 / col2 + 37 + col1 FROM tab1 AS cor0
----
47
50
63

query I rowsort
SELECT + - col0 * 89 FROM tab2 AS cor0
----
-623
-6942
-7031

query I rowsort
SELECT ALL 10 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query I rowsort
SELECT ALL 13 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to d752a38ff42b067eedd12ad6c3f9365e

query I rowsort
SELECT col0 + - cor0.col0 * col1 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT ALL - 9 AS col2 FROM tab1
----
-9
-9
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5804
SELECT - cor0.col0 DIV + cor0.col1 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 19c49c11cc9b548be21bc64de3610bde

skipif mysql # not compatible
query I rowsort label-5804
SELECT - cor0.col0 / + cor0.col1 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 19c49c11cc9b548be21bc64de3610bde

query I rowsort
SELECT DISTINCT 14 AS col1 FROM tab2, tab1 AS cor0
----
14

query I rowsort
SELECT - ( + 96 ) * col2 AS col0 FROM tab2 AS cor0
----
-2496
-2592
-3648

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5807
SELECT ALL - - col0 + + col1 * CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
1328
1407
634

skipif mysql # not compatible
query I rowsort label-5807
SELECT ALL - - col0 + + col1 * CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT - ( + col2 * - col2 ) AS col0 FROM tab2
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-5809
SELECT - 61 DIV col2 FROM tab0 cor0
----
-1
-61
0

skipif mysql # not compatible
query I rowsort label-5809
SELECT - 61 / col2 FROM tab0 cor0
----
-1
-61
0

query I rowsort
SELECT + - 0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5811
SELECT DISTINCT 70 DIV cor0.col0 FROM tab0 AS cor0
----
0
2

skipif mysql # not compatible
query I rowsort label-5811
SELECT DISTINCT 70 / cor0.col0 FROM tab0 AS cor0
----
0
2

query I rowsort
SELECT ALL - col1 * + col2 + - 83 AS col1 FROM tab2 cor0
----
-1617
-729
-920

query I rowsort
SELECT col2 * cor0.col1 + - col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT - - col2 * - 62 AS col2 FROM tab1 AS cor0
----
-3348
-3534
-5952

query I rowsort
SELECT 72 * - col1 AS col0 FROM tab1
----
-1872
-720
-936

query I rowsort
SELECT DISTINCT 36 * + col2 * + col0 FROM tab1
----
131328
276480
5832

query I rowsort
SELECT + - col0 * col2 + + col0 AS col2 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL + - cor0.col2 * - col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - + col2 * + col2 AS col0 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col2 * cor0.col0 + cor0.col0 col2 FROM tab0 cor0
----
1260
19032
649611

query I rowsort
SELECT DISTINCT - col1 + - col0 * col2 * col2 FROM tab0
----
-132
-26222
-598527

query I rowsort
SELECT col0 - - col2 AS col1 FROM tab1
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + col2 col1 FROM tab1
----
121
176
57

query I rowsort
SELECT ALL + col0 * tab0.col1 + + col0 + - col2 * col1 FROM tab0
----
-750
3333
726

query I rowsort
SELECT + + ( - col1 ) - cor0.col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT - + 52 FROM tab0 AS cor0
----
-52
-52
-52

query I rowsort
SELECT DISTINCT cor0.col0 - cor0.col2 * + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-5828
SELECT - - col1 DIV - col0 + + col1 AS col0 FROM tab2 cor0
----
17
27
59

skipif mysql # not compatible
query I rowsort label-5828
SELECT - - col1 / - col0 + + col1 AS col0 FROM tab2 cor0
----
17
27
59

query I rowsort
SELECT 8 * 24 FROM tab2
----
192
192
192

query I rowsort
SELECT DISTINCT + ( - 22 ) FROM tab1
----
-22

onlyif mysql # use DIV operator for integer division
query I rowsort label-5831
SELECT 29 DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5831
SELECT 29 / col1 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 - - col2 * tab2.col2 AS col0 FROM tab2
----
1523
736
754

query I rowsort
SELECT - cor1.col0 FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT + - col1 + col2 AS col2 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT - - col2 * cor0.col1 * cor0.col1 - col0 AS col1 FROM tab0 AS cor0
----
244044
678953
9374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col0 col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - col1 + col1 * + col1 AS col1 FROM tab1 AS cor0
----
156
650
90

query I rowsort
SELECT ALL - col2 * col2 + + 62 FROM tab0 AS cor0
----
-1027
-6662
61

query I rowsort
SELECT ALL + - 16 * col0 FROM tab2 AS cor0
----
-112
-1248
-1264

onlyif mysql # use DIV operator for integer division
query I rowsort label-5840
SELECT DISTINCT - - col1 DIV cor0.col1 FROM tab2 cor0
----
1

skipif mysql # not compatible
query I rowsort label-5840
SELECT DISTINCT - - col1 / cor0.col1 FROM tab2 cor0
----
1

query I rowsort
SELECT DISTINCT - - 7 * + col0 FROM tab2 cor0
----
49
546
553

onlyif mysql # use DIV operator for integer division
query I rowsort label-5842
SELECT - - col1 DIV - col0 AS col0 FROM tab1 cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-5842
SELECT - - col1 / - col0 AS col0 FROM tab1 cor0
----
-8
0
0

query I rowsort
SELECT - - col0 + + col0 FROM tab1 cor0
----
128
160
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 52 col0 FROM tab1 AS cor0
----
52
52
52

query I rowsort
SELECT DISTINCT + + 53 - cor0.col0 AS col0 FROM tab1 AS cor0
----
-11
-27
50

query I rowsort
SELECT - cor1.col2 - - cor1.col0 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 09b61d5303a3c257c2b4280abfc64db7

query I rowsort
SELECT col1 * col1 + tab2.col2 AS col1 FROM tab2
----
327
3507
988

query I rowsort
SELECT col0 - ( col0 + col0 ) * + cor0.col0 FROM tab1 AS cor0
----
-12720
-15
-8128

query I rowsort
SELECT - ( - col1 ) + col1 AS col2 FROM tab1
----
20
26
52

query I rowsort
SELECT DISTINCT ( - col2 ) + + tab2.col0 * col0 AS col0 FROM tab2
----
22
6058
6203

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5851
SELECT DISTINCT + col2 + col1 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-5851
SELECT DISTINCT + col2 + col1 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT + 74 * - col2 AS col2 FROM tab1
----
-3996
-4218
-7104

query I rowsort
SELECT col2 * - col2 * col0 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT ALL + 31 * + col0 FROM tab2 AS cor0
----
217
2418
2449

query I rowsort
SELECT DISTINCT + 34 + col0 AS col1 FROM tab0 AS cor0
----
123
58
69

query I rowsort
SELECT ALL - 24 + - col0 + - col0 * - col1 FROM tab1 AS cor0
----
51
552
936

query I rowsort
SELECT DISTINCT - tab2.col2 + 75 AS col0 FROM tab2
----
37
48
49

query I rowsort
SELECT DISTINCT - cor0.col1 * + 35 AS col1 FROM tab0, tab2 AS cor0
----
-1085
-2065
-595

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5859
SELECT CAST( NULL AS SIGNED ) + - 55 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5859
SELECT CAST ( NULL AS INTEGER ) + - 55 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 68 * + col1 + - col2 FROM tab1
----
1714
623
788

query I rowsort
SELECT + col1 + - 22 FROM tab0
----
64
69
75

query I rowsort
SELECT ALL + - ( - col2 ) * col1 + + col1 AS col2 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT + ( col0 ) * col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT + col1 * - col1 + + col2 + col1 AS col0 FROM tab0 AS cor0
----
-7277
-8108
-9311

query I rowsort
SELECT + 29 * - ( - col1 ) + col2 * - col1 * col0 AS col2 FROM tab2 AS cor0
----
-117941
-4960
-50541

query I rowsort
SELECT ALL - - 4 FROM tab2 cor0
----
4
4
4

query I rowsort
SELECT DISTINCT + - ( - col2 ) * + col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + - 15 * 25 AS col2 FROM tab2 AS cor0
----
-375
-375
-375

query I rowsort
SELECT + - ( 84 ) AS col2 FROM tab0 AS cor0
----
-84
-84
-84

query I rowsort
SELECT DISTINCT - 65 - col2 FROM tab1 cor0
----
-119
-122
-161

query I rowsort
SELECT ALL + col0 * - 77 FROM tab2 AS cor0
----
-539
-6006
-6083

query I rowsort
SELECT DISTINCT + 56 * col1 + - col2 FROM tab0 cor0
----
4783
5014
5431

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 75 col1 FROM tab1
----
-75
-75
-75

onlyif mysql # use DIV operator for integer division
query I rowsort label-5874
SELECT col2 + - 43 DIV col2 FROM tab0
----
-42
32
82

skipif mysql # not compatible
query I rowsort label-5874
SELECT col2 + - 43 / col2 FROM tab0
----
-42
32
82

query I rowsort
SELECT ALL 83 * - col0 AS col1 FROM tab0
----
-1992
-2905
-7387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 + col1 col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL - 65 AS col0 FROM tab0
----
-65
-65
-65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - 4 ) * + col0 col1 FROM tab0
----
-140
-356
-96

query I rowsort
SELECT DISTINCT - 70 * + col0 + ( col1 ) + col2 * 98 * + 19 AS col2 FROM tab0 cor0
----
-491
146545
59852

query I rowsort
SELECT DISTINCT col1 * - col1 + + ( 25 ) * col0 FROM tab2 AS cor0
----
-1531
-786
1686

query I rowsort
SELECT ALL + ( - cor0.col2 ) - cor0.col0 * + col2 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT ALL - col0 * - cor0.col1 * - 39 AS col0 FROM tab0 AS cor0
----
-132405
-315861
-80496

query I rowsort
SELECT ALL + col2 * + col0 - + col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT + 58 FROM tab2 cor0
----
58

query I rowsort
SELECT - + ( - col1 ) * 47 * - col2 FROM tab1 AS cor0
----
-26790
-58656
-65988

onlyif mysql # use DIV operator for integer division
query I rowsort label-5886
SELECT col2 * ( tab1.col1 ) DIV - tab1.col0 FROM tab1
----
-15
-468
-8

skipif mysql # not compatible
query I rowsort label-5886
SELECT col2 * ( tab1.col1 ) / - tab1.col0 FROM tab1
----
-15
-468
-8

query I rowsort
SELECT col1 * - ( - cor0.col1 ) FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL + + col0 * 39 FROM tab2 cor0
----
273
3042
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-5889
SELECT ALL col2 + col1 DIV 58 col0 FROM tab2 cor0
----
27
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5889
SELECT ALL col2 + col1 / 58 col0 FROM tab2 cor0
----
27
27
38

query I rowsort
SELECT - + col2 + + cor0.col1 AS col1 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5891
SELECT - cor0.col0 * col0 + col0 DIV - col2 AS col0 FROM tab1 AS cor0
----
-4097
-6400
-9

skipif mysql # not compatible
query I rowsort label-5891
SELECT - cor0.col0 * col0 + col0 / - col2 AS col0 FROM tab1 AS cor0
----
-4097
-6400
-9

query I rowsort
SELECT - - col0 * + ( - col2 ) - col2 * 7 FROM tab1 AS cor0
----
-4047
-540
-8352

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5893
SELECT + col0 + - col0 + ( + col0 * - CAST( ( col2 ) AS SIGNED ) ) AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-5893
SELECT + col0 + - col0 + ( + col0 * - CAST ( ( col2 ) AS INTEGER ) ) AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5894
SELECT - + col2 * + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5894
SELECT - + col2 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 + + ( + col1 ) * cor0.col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT - + col2 * ( col1 ) + + cor0.col1 - ( 25 + col2 ) AS col0 FROM tab2 AS cor0
----
-1526
-692
-858

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5897
SELECT - - CAST( + col0 AS SIGNED ) FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-5897
SELECT - - CAST ( + col0 AS INTEGER ) FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + - ( col1 ) + col0 FROM tab2 AS cor0
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 + + col0 * col0 col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT cor2.col0 * 41 FROM tab0, tab1 cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 1e4a95d91dad5211869d88f3661f53fa

query I rowsort
SELECT + - 50 * 68 FROM tab0 AS cor0
----
-3400
-3400
-3400

query I rowsort
SELECT ( tab2.col2 ) AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT - - col0 + + col0 AS col1 FROM tab0 AS cor0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + cor0.col0 col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col0 * + cor0.col2 col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - ( + col2 ) * + tab1.col0 * - col1 FROM tab1
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-5907
SELECT ALL + col0 * col1 DIV 41 col1 FROM tab1
----
1
15
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5907
SELECT ALL + col0 * col1 / 41 col1 FROM tab1
----
1
15
25

query I rowsort
SELECT - cor0.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT 68 + + 3 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 - - col2 col1 FROM tab0
----
119
173
98

query I rowsort
SELECT + - col0 + + col1 + col1 AS col0 FROM tab1 AS cor0
----
-44
-54
49

onlyif mysql # use DIV operator for integer division
query I rowsort label-5912
SELECT + col2 + - 93 + col1 DIV - col0 FROM tab2 AS cor0
----
-55
-67
-70

skipif mysql # not compatible
query I rowsort label-5912
SELECT + col2 + - 93 + col1 / - col0 FROM tab2 AS cor0
----
-55
-67
-70

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0 CROSS JOIN tab1, tab2, tab0 cor1
----
3645 values hashing to 489b7b2b5c4980d50e86e51be30361c3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5914
SELECT + col0 - + col0 * col0 * + CAST( + col0 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-336
-474474
-492960

skipif mysql # not compatible
query I rowsort label-5914
SELECT + col0 - + col0 * col0 * + CAST ( + col0 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-336
-474474
-492960

query I rowsort
SELECT ALL + ( cor0.col0 ) * col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL + col1 * - col1 + - col1 FROM tab1 AS cor0
----
-110
-182
-702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5917
SELECT CAST( col1 AS SIGNED ) + col1 col1 FROM tab0 AS cor0
----
172
182
194

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5917
SELECT CAST ( col1 AS INTEGER ) + col1 col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT ALL + - 42 FROM tab2 AS cor0
----
-42
-42
-42

query I rowsort
SELECT cor0.col2 AS col0 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT + 71 + cor0.col1 FROM tab0 AS cor0
----
157
162
168

query I rowsort
SELECT 52 * - col0 AS col1 FROM tab2 AS cor0
----
-364
-4056
-4108

query I rowsort
SELECT ALL + - 57 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

query I rowsort
SELECT ALL col0 * - col2 - - 71 AS col2 FROM tab2
----
-118
-1957
-2931

query I rowsort
SELECT + cor0.col1 * - col2 - - 21 * + cor0.col0 FROM tab0 AS cor0
----
-2334
-5593
638

query I rowsort
SELECT DISTINCT col1 + + col1 + 88 AS col0 FROM tab2
----
122
150
206

query I rowsort
SELECT + 59 * + col0 - - 78 AS col0 FROM tab0 cor0
----
1494
2143
5329

query I rowsort
SELECT 21 * col2 + 49 + 78 AS col1 FROM tab0 AS cor0
----
148
1849
820

query I rowsort
SELECT DISTINCT - col0 * - ( + col1 ) + col1 * + col2 FROM tab1 AS cor0
----
1210
1482
2288

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + 70 col0 FROM tab2 AS cor0
----
108
96
97

query I rowsort
SELECT DISTINCT + - col2 * ( + 20 ) AS col0 FROM tab0 AS cor0
----
-1640
-20
-660

query I rowsort
SELECT + col0 * + tab1.col2 + + 9 AS col2 FROM tab1
----
171
3657
7689

query I rowsort
SELECT + 38 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT DISTINCT + + col2 * - ( col1 ) * - cor0.col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT ALL - - col0 * + 13 * - 61 + + col2 + - col0 FROM tab2 AS cor0
----
-5531
-61906
-62688

query I rowsort
SELECT + 44 * col2 FROM tab0
----
1452
3608
44

query I rowsort
SELECT ALL col0 + + 55 * 93 AS col1 FROM tab0 AS cor0
----
5139
5150
5204

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 * - col0 col1 FROM tab1 cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5938
SELECT ALL - ( col1 + tab2.col2 ) DIV 45 AS col0 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5938
SELECT ALL - ( col1 + tab2.col2 ) / 45 AS col0 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT ALL - - 54 + + cor0.col2 * + col1 FROM tab1 AS cor0
----
1302
1458
624

query I rowsort
SELECT ( 71 ) * cor0.col1 AS col1 FROM tab1 AS cor0
----
1846
710
923

query I rowsort
SELECT DISTINCT 97 AS col0 FROM tab1, tab2 AS cor0
----
97

query I rowsort
SELECT - cor0.col1 + - col0 * + col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT + 45 * col1 AS col2 FROM tab2 AS cor0
----
1395
2655
765

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5944
SELECT + CAST( NULL AS SIGNED ) + - col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5944
SELECT + CAST ( NULL AS INTEGER ) + - col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 96 * - col2 col2 FROM tab2 AS cor0
----
2496
2592
3648

query I rowsort
SELECT + 34 + col1 + col1 AS col2 FROM tab2 AS cor0
----
152
68
96

query I rowsort
SELECT DISTINCT + col2 * col1 + ( + col0 ) FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-5948
SELECT ALL - col2 DIV tab1.col0 FROM tab1
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-5948
SELECT ALL - col2 / tab1.col0 FROM tab1
----
-1
-18
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5949
SELECT - - col2 + - col1 DIV - col0 FROM tab2 AS cor0
----
26
31
38

skipif mysql # not compatible
query I rowsort label-5949
SELECT - - col2 + - col1 / - col0 FROM tab2 AS cor0
----
26
31
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5950
SELECT ALL + 87 DIV col2 FROM tab0 AS cor0
----
1
2
87

skipif mysql # not compatible
query I rowsort label-5950
SELECT ALL + 87 / col2 FROM tab0 AS cor0
----
1
2
87

query I rowsort
SELECT ALL 62 + col2 * col0 FROM tab0 AS cor0
----
7360
854
97

query I rowsort
SELECT DISTINCT + cor0.col2 + - col1 * col1 AS col2 FROM tab2 AS cor0
----
-251
-3455
-934

query I rowsort
SELECT ALL col0 + + col1 * col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT - col1 - - col2 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - 91 * - col2 AS col0 FROM tab2 cor0
----
2366
2457
3458

query I rowsort
SELECT DISTINCT + - 50 AS col0 FROM tab1 AS cor0
----
-50

query I rowsort
SELECT - 96 * + col0 + - col1 + col0 FROM tab2 AS cor0
----
-696
-7469
-7522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 * + col1 col1 FROM tab0 cor0
----
-2064
-3395
-8099

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2, tab2 cor0, tab1 cor1
----
972 values hashing to 4c46de5c1773124597e14f3b372fc4ea

query I rowsort
SELECT + 10 FROM tab2
----
10
10
10

query I rowsort
SELECT + col0 + + 46 FROM tab2
----
124
125
53

query I rowsort
SELECT col2 * + 42 + tab2.col2 FROM tab2
----
1118
1161
1634

query I rowsort
SELECT + col0 * 17 * ( - col2 ) FROM tab1 AS cor0
----
-130560
-2754
-62016

query I rowsort
SELECT + col2 * - 76 FROM tab1 AS cor0
----
-4104
-4332
-7296

onlyif mysql # use DIV operator for integer division
query I rowsort label-5965
SELECT DISTINCT col0 DIV + 40 FROM tab2 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-5965
SELECT DISTINCT col0 / + 40 FROM tab2 AS cor0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * cor0.col2 col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL col0 * + 8 FROM tab0 AS cor0
----
192
280
712

query I rowsort
SELECT ALL + col2 + 14 * + col0 * - col2 FROM tab1 AS cor0
----
-107424
-2214
-51015

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5969
SELECT + + col1 * - ( col0 + - CAST( ( + cor0.col0 ) AS SIGNED ) ) FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5969
SELECT + + col1 * - ( col0 + - CAST ( ( + cor0.col0 ) AS INTEGER ) ) FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5970
SELECT ALL + CAST( NULL AS SIGNED ) * - cor0.col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5970
SELECT ALL + CAST ( NULL AS INTEGER ) * - cor0.col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5971
SELECT DISTINCT + col1 DIV - cor0.col0 FROM tab1 AS cor0
----
-8
0

skipif mysql # not compatible
query I rowsort label-5971
SELECT DISTINCT + col1 / - cor0.col0 FROM tab1 AS cor0
----
-8
0

query I rowsort
SELECT DISTINCT + ( + 32 ) FROM tab2 AS cor0
----
32

query I rowsort
SELECT - + ( - col2 ) + - col1 * - ( + 62 + col0 ) AS col0 FROM tab0 AS cor0
----
13823
7429
9410

query I rowsort
SELECT + - col0 + col1 * - col2 * - 49 FROM tab2 AS cor0
----
31575
41006
75088

query I rowsort
SELECT col1 * + 26 AS col2 FROM tab1 AS cor0
----
260
338
676

query I rowsort
SELECT ALL col0 * 93 FROM tab1 AS cor0
----
279
5952
7440

query I rowsort
SELECT ALL 40 * ( col0 ) FROM tab2 AS cor0
----
280
3120
3160

query I rowsort
SELECT DISTINCT - col2 * + cor0.col1 AS col1 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT 10 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
10

query I rowsort
SELECT ALL + + 78 * col2 * col2 AS col1 FROM tab0 AS cor0
----
524472
78
84942

query I rowsort
SELECT ALL + cor0.col2 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT ( col0 ) - + ( + col2 ) FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ALL - + 27 AS col2 FROM tab0 cor0
----
-27
-27
-27

query I rowsort
SELECT + col1 * col2 - + col1 AS col2 FROM tab1 AS cor0
----
1235
1378
560

query I rowsort
SELECT + ( + col2 ) * + col0 AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL + cor0.col1 + + col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - 58 * cor0.col0 FROM tab0 AS cor0
----
-1392
-2030
-5162

onlyif mysql # use DIV operator for integer division
query I rowsort label-5988
SELECT ALL + 47 DIV col2 + - col0 * col1 AS col0 FROM tab1 cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-5988
SELECT ALL + 47 / col2 + - col0 * col1 AS col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - + col2 * + col1 * col1 + + col2 AS col0 FROM tab2 cor0
----
-10944
-25920
-90480

query I rowsort
SELECT DISTINCT 19 * col2 + col1 AS col0 FROM tab0 AS cor0
----
116
1649
713

query I rowsort
SELECT 70 + col1 AS col2 FROM tab1 cor0
----
80
83
96

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0, tab2 AS cor0 WHERE NOT NULL BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL col2 - col2 * - col2 FROM tab1
----
2970
3306
9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5994
SELECT CAST( NULL AS SIGNED ) + 94 * + col2 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5994
SELECT CAST ( NULL AS INTEGER ) + 94 * + col2 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 74 + + col2 col1 FROM tab1 AS cor0
----
-17
-20
22

onlyif mysql # use DIV operator for integer division
query I rowsort label-5996
SELECT - cor0.col1 DIV col2 + + col1 FROM tab0 AS cor0
----
0
84
90

skipif mysql # not compatible
query I rowsort label-5996
SELECT - cor0.col1 / col2 + + col1 FROM tab0 AS cor0
----
0
84
90

query I rowsort
SELECT DISTINCT + ( + col1 ) * ( - col0 ) + col2 AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT ALL col1 * cor0.col2 - col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT + + 42 * 95 FROM tab2, tab0, tab1 AS cor0
----
3990

onlyif mysql # use DIV operator for integer division
query I rowsort label-6000
SELECT ALL + col2 + - tab1.col2 * - ( col0 ) + - col0 DIV 58 FROM tab1
----
216
3704
7775

skipif mysql # not compatible
query I rowsort label-6000
SELECT ALL + col2 + - tab1.col2 * - ( col0 ) + - col0 / 58 FROM tab1
----
216
3704
7775

query I rowsort
SELECT ALL - 88 AS col0 FROM tab1 AS cor0
----
-88
-88
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 55 * col1 col2 FROM tab1 AS cor0
----
1430
550
715

onlyif mysql # use DIV operator for integer division
query I rowsort label-6003
SELECT + + col0 * cor0.col0 DIV - col2 FROM tab0 AS cor0
----
-1225
-17
-96

skipif mysql # not compatible
query I rowsort label-6003
SELECT + + col0 * cor0.col0 / - col2 FROM tab0 AS cor0
----
-1225
-17
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6004
SELECT - + col2 + col2 DIV - 78 AS col2 FROM tab0 AS cor0
----
-1
-33
-83

skipif mysql # not compatible
query I rowsort label-6004
SELECT - + col2 + col2 / - 78 AS col2 FROM tab0 AS cor0
----
-1
-33
-83

query I rowsort
SELECT - col2 * tab1.col2 * ( 53 ) + - col2 FROM tab1
----
-154602
-172254
-488544

query I rowsort
SELECT DISTINCT - col1 * col0 + 36 * col2 AS col1 FROM tab1
----
1412
1866
2416

query I rowsort
SELECT + col2 + + col1 * col0 + col2 AS col2 FROM tab1
----
1232
186
754

query I rowsort
SELECT + cor0.col0 + + col0 * - 34 AS col2 FROM tab1 AS cor0
----
-2112
-2640
-99

query I rowsort
SELECT 82 AS col2 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

onlyif mysql # use DIV operator for integer division
query I rowsort label-6010
SELECT - col1 DIV - col1 AS col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6010
SELECT - col1 / - col1 AS col0 FROM tab2
----
1
1
1

query I rowsort
SELECT col0 * 12 FROM tab0
----
1068
288
420

query I rowsort
SELECT - col0 * + 98 * - 16 FROM tab1
----
100352
125440
4704

query I rowsort
SELECT DISTINCT - col1 + 62 + col0 FROM tab0 cor0
----
0
60

query I rowsort
SELECT + col2 * col0 + 28 FROM tab0 AS cor0
----
63
7326
820

query I rowsort
SELECT + col2 * + col1 + - col0 FROM tab2 AS cor0
----
1456
567
830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * ( - col1 ) + col1 * 20 col2 FROM tab0 AS cor0
----
-1455
-344
-6279

onlyif mysql # use DIV operator for integer division
query I rowsort label-6017
SELECT DISTINCT + + col1 + - col1 - 11 DIV - col1 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-6017
SELECT DISTINCT + + col1 + - col1 - 11 / - col1 FROM tab0 cor0
----
0

query I rowsort
SELECT ALL - - cor0.col2 * 81 FROM tab0 AS cor0
----
2673
6642
81

query I rowsort
SELECT + - cor0.col1 + + col2 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col2 + col2 * 26 FROM tab2 AS cor0
----
650
675
950

query I rowsort
SELECT 63 + col2 AS col0 FROM tab2
----
101
89
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6022
SELECT ALL col1 DIV + col0 + col2 * col0 AS col1 FROM tab2 AS cor0
----
193
2028
3002

skipif mysql # not compatible
query I rowsort label-6022
SELECT ALL col1 / + col0 + col2 * col0 AS col1 FROM tab2 AS cor0
----
193
2028
3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 21 col1 FROM tab2 AS cor0
----
21
21
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-6024
SELECT ALL - ( cor0.col0 ) * - col2 - col1 DIV col1 FROM tab1 AS cor0
----
161
3647
7679

skipif mysql # not compatible
query I rowsort label-6024
SELECT ALL - ( cor0.col0 ) * - col2 - col1 / col1 FROM tab1 AS cor0
----
161
3647
7679

query I rowsort
SELECT DISTINCT - 97 * cor0.col1 FROM tab2 AS cor0
----
-1649
-3007
-5723

query I rowsort
SELECT DISTINCT - 98 * - cor0.col0 AS col0 FROM tab2 AS cor0
----
686
7644
7742

query I rowsort
SELECT - 3 + col1 AS col0 FROM tab2 cor0
----
14
28
56

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6028
SELECT DISTINCT + + CAST( NULL AS SIGNED ) - cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6028
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) - cor0.col2 AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - cor0.col0 + col2 * - col0 * ( col2 ) FROM tab0 AS cor0
----
-26160
-598525
-70

query I rowsort
SELECT 47 - col0 AS col0 FROM tab0 AS cor0
----
-42
12
23

query I rowsort
SELECT DISTINCT 56 AS col0 FROM tab0 AS cor0
----
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 19 col0 FROM tab1
----
-19

query I rowsort
SELECT ALL - - col0 + col1 AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - 35 * + col2 + + ( + 94 * cor0.col1 ) FROM tab1 AS cor0
----
-1055
-2138
554

query I rowsort
SELECT + ( cor0.col0 ) - - col0 FROM tab2 AS cor0
----
14
156
158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 52 col1 FROM tab2 AS cor0
----
52
52
52

query I rowsort
SELECT + - 98 - col1 AS col2 FROM tab0 AS cor0
----
-184
-189
-195

query I rowsort
SELECT col0 * col0 - col1 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT - - 51 * col0 AS col2 FROM tab0 AS cor0
----
1224
1785
4539

onlyif mysql # use DIV operator for integer division
query I rowsort label-6040
SELECT ( col0 ) DIV cor0.col1 AS col0 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-6040
SELECT ( col0 ) / cor0.col1 AS col0 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT + col1 * cor0.col0 + - col1 * col1 AS col2 FROM tab0 AS cor0
----
-182
-5332
-6014

query I rowsort
SELECT + col0 * + ( + col2 ) + col2 + + col0 FROM tab2 AS cor0
----
2132
223
3119

query I rowsort
SELECT + - col1 + + col0 + col2 FROM tab2 AS cor0
----
100
3
45

query I rowsort
SELECT 89 + + col0 FROM tab0 AS cor0
----
113
124
178

query I rowsort
SELECT - ( col0 ) * col1 + + 43 AS col1 FROM tab2 AS cor0
----
-1300
-174
-4559

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6046
SELECT CAST( - col2 AS SIGNED ) * col1 + 51 FROM tab0 AS cor0
----
-2787
-46
-7411

skipif mysql # not compatible
query I rowsort label-6046
SELECT CAST ( - col2 AS INTEGER ) * col1 + 51 FROM tab0 AS cor0
----
-2787
-46
-7411

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 + + tab0.col1 col0 FROM tab0
----
132
7389
878

query I rowsort
SELECT + 84 + - 88 FROM tab2 AS cor0
----
-4
-4
-4

query I rowsort
SELECT col2 * - col0 + col1 AS col2 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT cor0.col1 * - 95 + + col1 AS col1 FROM tab1 AS cor0
----
-1222
-2444
-940

query I rowsort
SELECT + 75 + cor0.col0 FROM tab0 AS cor0
----
110
164
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-6052
SELECT DISTINCT + col1 * col2 DIV + col0 FROM tab1
----
15
468
8

skipif mysql # not compatible
query I rowsort label-6052
SELECT DISTINCT + col1 * col2 / + col0 FROM tab1
----
15
468
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-6053
SELECT ALL col1 DIV - 81 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6053
SELECT ALL col1 / - 81 FROM tab0
----
-1
-1
-1

query I rowsort
SELECT - + col0 * - 2 AS col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL col0 + ( + col0 ) * col2 FROM tab1 AS cor0
----
165
3712
7760

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6056
SELECT ALL + - col1 + 65 + - cor0.col1 * CAST( col2 + col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-15587
-3524
-4923

skipif mysql # not compatible
query I rowsort label-6056
SELECT ALL + - col1 + 65 + - cor0.col1 * CAST ( col2 + col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-15587
-3524
-4923

query I rowsort
SELECT - - 34 AS col1 FROM tab0 AS cor0
----
34
34
34

query I rowsort
SELECT - - 37 AS col1 FROM tab1 cor0
----
37
37
37

onlyif mysql # use DIV operator for integer division
query I rowsort label-6059
SELECT DISTINCT - cor0.col0 DIV col0 - + col2 FROM tab0 AS cor0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-6059
SELECT DISTINCT - cor0.col0 / col0 - + col2 FROM tab0 AS cor0
----
-2
-34
-83

query I rowsort
SELECT - col2 + 55 AS col0 FROM tab2
----
17
28
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col1 - + tab2.col2 col0 FROM tab2
----
1305
190
4576

query I rowsort
SELECT col0 + + col0 + col1 FROM tab0
----
134
167
269

query I rowsort
SELECT - col2 + tab1.col1 * + col0 AS col1 FROM tab1
----
24
583
944

query I rowsort
SELECT 8 * col1 - - col1 AS col1 FROM tab0 AS cor0
----
774
819
873

query I rowsort
SELECT + 56 + col1 AS col2 FROM tab0
----
142
147
153

query I rowsort
SELECT ALL col2 - tab0.col2 AS col1 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6067
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + col1 - col0 AS col2 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-6067
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + col1 - col0 AS col2 FROM tab2
----
NULL

query I rowsort
SELECT DISTINCT tab2.col1 + + col1 AS col0 FROM tab2
----
118
34
62

query I rowsort
SELECT tab0.col2 * 54 AS col2 FROM tab0
----
1782
4428
54

query I rowsort
SELECT ALL + - col2 * cor0.col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-6071
SELECT ALL col2 * 9 DIV col2 FROM tab0 AS cor0
----
9
9
9

skipif mysql # not compatible
query I rowsort label-6071
SELECT ALL col2 * 9 / col2 FROM tab0 AS cor0
----
9
9
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6072
SELECT + col1 + 33 DIV col1 AS col0 FROM tab2 AS cor0
----
18
32
59

skipif mysql # not compatible
query I rowsort label-6072
SELECT + col1 + 33 / col1 AS col0 FROM tab2 AS cor0
----
18
32
59

query I rowsort
SELECT DISTINCT - ( - 79 ) * + col2 * col2 + col0 * col1 + 41 AS col2 FROM tab2 AS cor0
----
115460
57849
58047

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6074
SELECT ALL + CAST( NULL AS SIGNED ) / - cor0.col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6074
SELECT ALL + CAST ( NULL AS INTEGER ) / - cor0.col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 - 23 * col2 * col2 FROM tab0 AS cor0
----
-154570
-22
-25014

query I rowsort
SELECT ALL + 0 AS col1 FROM tab1, tab0, tab1 cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT - + ( + col0 ) * col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT - col1 + + ( - col0 ) * col2 AS col2 FROM tab2 AS cor0
----
-2087
-220
-3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * cor0.col2 col0 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6080
SELECT - cor0.col1 * CAST( 57 AS SIGNED ) FROM tab0 AS cor0
----
-4902
-5187
-5529

skipif mysql # not compatible
query I rowsort label-6080
SELECT - cor0.col1 * CAST ( 57 AS INTEGER ) FROM tab0 AS cor0
----
-4902
-5187
-5529

query I rowsort
SELECT DISTINCT - col1 + - 46 * + col1 FROM tab2 AS cor0
----
-1457
-2773
-799

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6082
SELECT DISTINCT + col2 * - CAST( NULL AS SIGNED ) AS col1 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6082
SELECT DISTINCT + col2 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 cor0
----
NULL

query I rowsort
SELECT - - col0 * ( 73 + col0 ) FROM tab2 AS cor0
----
11778
12008
560

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6084
SELECT - - col0 + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6084
SELECT - - col0 + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 * col2 + + col1 FROM tab0
----
-1003
-6633
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6086
SELECT ALL col0 DIV tab1.col2 + col0 col2 FROM tab1
----
3
65
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6086
SELECT ALL col0 / tab1.col2 + col0 col2 FROM tab1
----
3
65
80

query I rowsort
SELECT DISTINCT + col0 + + col2 * - tab2.col0 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT - col0 * + col1 + tab1.col2 * col1 FROM tab1
----
-70
1326
208

onlyif mysql # use DIV operator for integer division
query I rowsort label-6089
SELECT ALL col2 DIV col0 + + col2 * col2 FROM tab0
----
1
1090
6724

skipif mysql # not compatible
query I rowsort label-6089
SELECT ALL col2 / col0 + + col2 * col2 FROM tab0
----
1
1090
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * tab1.col1 col0 FROM tab1
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-6091
SELECT ALL + + col0 DIV col2 + - cor0.col2 col0 FROM tab0 AS cor0
----
-33
-81
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6091
SELECT ALL + + col0 / col2 + - cor0.col2 col0 FROM tab0 AS cor0
----
-33
-81
34

query I rowsort
SELECT DISTINCT + + col2 - + col2 * - col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT col1 + col2 * col1 * + col2 AS col0 FROM tab0 AS cor0
----
194
611975
93740

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * cor0.col0 * col2 col0 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT DISTINCT col0 + cor0.col1 + cor0.col1 AS col1 FROM tab1 AS cor0
----
106
55
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-6096
SELECT - col1 + col1 DIV tab0.col1 AS col2 FROM tab0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-6096
SELECT - col1 + col1 / tab0.col1 AS col2 FROM tab0
----
-85
-90
-96

query I rowsort
SELECT + tab2.col1 + + col1 * + col2 FROM tab2
----
1593
663
868

query I rowsort
SELECT DISTINCT - col0 FROM tab1 AS cor0 WHERE NOT NULL BETWEEN col2 AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6099
SELECT ALL cor0.col2 DIV col0 + - col0 col1 FROM tab2 AS cor0
----
-4
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6099
SELECT ALL cor0.col2 / col0 + - col0 col1 FROM tab2 AS cor0
----
-4
-78
-79

query I rowsort
SELECT DISTINCT col0 * - col0 + - col0 * + col0 AS col2 FROM tab1 AS cor0
----
-12800
-18
-8192

query I rowsort
SELECT DISTINCT + col0 + col0 + + col2 AS col1 FROM tab1
----
185
256
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-6102
SELECT DISTINCT - col0 DIV + col2 + col1 col0 FROM tab1
----
13
26
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6102
SELECT DISTINCT - col0 / + col2 + col1 col0 FROM tab1
----
13
26
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - col1 col0 FROM tab2
----
-118
-34
-62

query I rowsort
SELECT col2 + tab2.col0 + + col1 AS col0 FROM tab2
----
134
163
65

query I rowsort
SELECT - col2 * - col1 + col2 AS col0 FROM tab0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-6106
SELECT + col2 DIV + col1 + col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6106
SELECT + col2 / + col1 + col0 FROM tab0
----
24
35
89

query I rowsort
SELECT col2 + col0 + + col1 * - col1 AS col1 FROM tab1
----
-619
21
7

query I rowsort
SELECT col1 + - tab1.col0 AS col1 FROM tab1
----
-54
-67
23

query I rowsort
SELECT DISTINCT - col2 - + col2 FROM tab2 cor0
----
-52
-54
-76

query I rowsort
SELECT cor0.col1 - - col0 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + + col0 + - col2 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL - cor0.col1 * cor0.col2 FROM tab0 AS cor0
----
-2838
-7462
-97

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 + + col2 - col2 col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col0 + cor0.col0 * cor0.col0 * col2 AS col1 FROM tab1 AS cor0
----
233536
489
614480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 + - col0 * col0 col2 FROM tab1 AS cor0
----
-1413
-4666
-7648

query I rowsort
SELECT ALL + cor0.col0 + col2 * col2 FROM tab0 AS cor0
----
1113
36
6813

onlyif mysql # use DIV operator for integer division
query I rowsort label-6118
SELECT ALL col0 - + col1 DIV - col1 AS col1 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-6118
SELECT ALL col0 - + col1 / - col1 AS col1 FROM tab1 AS cor0
----
4
65
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-6119
SELECT ALL - - col2 - + col1 DIV col0 FROM tab0 cor0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-6119
SELECT ALL - - col2 - + col1 / col0 FROM tab0 cor0
----
-1
30
81

query I rowsort
SELECT DISTINCT + col0 * + col0 * col0 FROM tab0 AS cor0
----
13824
42875
704969

onlyif mysql # use DIV operator for integer division
query I rowsort label-6121
SELECT ALL + col1 * col1 DIV col0 + col1 + - col2 FROM tab0 AS cor0
----
102
361
364

skipif mysql # not compatible
query I rowsort label-6121
SELECT ALL + col1 * col1 / col0 + col1 + - col2 FROM tab0 AS cor0
----
102
361
364

query I rowsort
SELECT DISTINCT - col0 + - col1 - - col1 * - col1 FROM tab2
----
-3618
-385
-999

query I rowsort
SELECT col0 - + col2 * - col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT + tab2.col1 + col1 * + tab2.col2 + - col2 * col0 AS col2 FROM tab2
----
-2339
-435
679

query I rowsort
SELECT ALL tab1.col1 * col0 - col2 FROM tab1
----
24
583
944

query I rowsort
SELECT ALL - col0 + + col0 - col0 AS col2 FROM tab0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6127
SELECT + col2 + col1 * - 40 + ( col1 ) DIV + ( col1 * + col0 ) col0 FROM tab1 AS cor0
----
-343
-424
-986

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6127
SELECT + col2 + col1 * - 40 + ( col1 ) / + ( col1 * + col0 ) col0 FROM tab1 AS cor0
----
-343
-424
-986

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col1 - - col0 col2 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-6129
SELECT + col1 DIV col0 - - col0 FROM tab2 AS cor0
----
11
78
79

skipif mysql # not compatible
query I rowsort label-6129
SELECT + col1 / col0 - - col0 FROM tab2 AS cor0
----
11
78
79

query I rowsort
SELECT - ( cor0.col0 ) - - col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT - + col1 + - col1 * 76 FROM tab0 AS cor0
----
-6622
-7007
-7469

query I rowsort
SELECT + cor0.col0 * cor0.col1 + - col1 FROM tab2 AS cor0
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-6133
SELECT col0 * 54 + - col0 DIV col0 FROM tab1 AS cor0
----
161
3455
4319

skipif mysql # not compatible
query I rowsort label-6133
SELECT col0 * 54 + - col0 / col0 FROM tab1 AS cor0
----
161
3455
4319

query I rowsort
SELECT 55 * - col2 AS col1 FROM tab2
----
-1430
-1485
-2090

onlyif mysql # use DIV operator for integer division
query I rowsort label-6135
SELECT DISTINCT 72 + col1 DIV 58 + - col2 FROM tab2
----
34
45
47

skipif mysql # not compatible
query I rowsort label-6135
SELECT DISTINCT 72 + col1 / 58 + - col2 FROM tab2
----
34
45
47

query I rowsort
SELECT col0 * col0 + col2 AS col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT col1 * col2 + + cor0.col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT - col1 + - 30 FROM tab0 AS cor0
----
-116
-121
-127

onlyif mysql # use DIV operator for integer division
query I rowsort label-6139
SELECT - 96 DIV col1 FROM tab0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-6139
SELECT - 96 / col1 FROM tab0
----
-1
-1
0

query I rowsort
SELECT + 77 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to d7b027bca5d37c67e29013904def8125

query I rowsort
SELECT ALL 44 * - col2 FROM tab2
----
-1144
-1188
-1672

query I rowsort
SELECT - col1 * + col1 * + 93 FROM tab2
----
-26877
-323733
-89373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col2 col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - 99 + col1 FROM tab0
----
-13
-2
-8

query I rowsort
SELECT DISTINCT + 38 * - col0 + + col1 FROM tab1
----
-2422
-3027
-88

query I rowsort
SELECT ALL 40 AS col1 FROM tab2
----
40
40
40

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT IN ( - col2 + col2 * col0 )
----

query I rowsort
SELECT DISTINCT col1 + col1 * col2 AS col2 FROM tab0
----
194
2924
7553

query I rowsort
SELECT DISTINCT - col0 + + col1 * - col2 * col1 AS col1 FROM tab0
----
-244092
-679131
-9444

query I rowsort
SELECT ALL + tab1.col1 + col2 * - col1 FROM tab1
----
-1235
-1378
-560

query I rowsort
SELECT tab2.col1 + - tab2.col0 AS col0 FROM tab2
----
-19
-62
24

query I rowsort
SELECT col2 + - col1 * + col1 AS col1 FROM tab0
----
-7363
-8199
-9408

query I rowsort
SELECT + col0 - + col0 * + tab1.col0 AS col0 FROM tab1
----
-4032
-6
-6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col0 * - col2 col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT tab2.col2 + - col0 * - col0 AS col0 FROM tab2
----
6110
6279
76

query I rowsort
SELECT ALL col0 + col2 * + col1 FROM tab1
----
1328
1407
634

query I rowsort
SELECT tab2.col2 FROM tab2 WHERE ( NULL ) BETWEEN col2 AND - col1 + - col0 + col2
----

query I rowsort
SELECT + col2 + col2 + col1 FROM tab1 WHERE - col0 / col2 < NULL
----

query I rowsort
SELECT DISTINCT col0 + col2 FROM tab0 WHERE NOT ( NULL ) NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT + tab0.col0 + + col0 AS col2 FROM tab0
----
178
48
70

query I rowsort
SELECT col1 + col2 FROM tab1 WHERE NOT NULL < NULL
----

query I rowsort
SELECT col0 + - col0 * - col0 FROM tab1
----
12
4160
6480

query I rowsort
SELECT DISTINCT cor0.col2 AS col0 FROM tab0 cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 AS cor2
----
1
33
82

query I rowsort
SELECT ALL 12 FROM tab1, tab2 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT - col1 + 16 AS col1 FROM tab2 AS cor0
----
-1
-15
-43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + 53 * col1 col2 FROM tab1 AS cor0
----
1324
473
593

query I rowsort
SELECT + + cor0.col0 + - 14 AS col0 FROM tab1 AS cor0
----
-11
50
66

query I rowsort
SELECT DISTINCT - col1 * col0 + - cor0.col1 AS col2 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT col2 + ( - 73 ) FROM tab1 AS cor0
----
-16
-19
23

query I rowsort
SELECT - - col1 + 96 AS col2 FROM tab0 AS cor0
----
182
187
193

onlyif mysql # use DIV operator for integer division
query I rowsort label-6171
SELECT DISTINCT + + col2 * - 41 * col2 + col0 DIV - col2 + col2 col0 FROM tab1 AS cor0
----
-119502
-133153
-377760

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6171
SELECT DISTINCT + + col2 * - 41 * col2 + col0 / - col2 + col2 col0 FROM tab1 AS cor0
----
-119502
-133153
-377760

query I rowsort
SELECT 83 * cor0.col1 FROM tab2 AS cor0
----
1411
2573
4897

query I rowsort
SELECT + col1 * + 97 AS col1 FROM tab2 AS cor0
----
1649
3007
5723

query I rowsort
SELECT ( + col2 ) * col1 FROM tab0 cor0
----
2838
7462
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6175
SELECT CAST( NULL AS SIGNED ) / + ( col0 + col2 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6175
SELECT CAST ( NULL AS INTEGER ) / + ( col0 + col2 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col2 * 61 AS col0 FROM tab0 cor0
----
2013
5002
61

query I rowsort
SELECT 99 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
-693
-7722
-7821

query I rowsort
SELECT ALL - 3 AS col0 FROM tab1 cor0
----
-3
-3
-3

query I rowsort
SELECT + - col2 * - col2 AS col1 FROM tab0 cor0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * cor0.col0 col1 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT cor0.col2 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL + + col0 * + col0 AS col1 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6183
SELECT - - 8 DIV + col2 FROM tab0 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-6183
SELECT - - 8 / + col2 FROM tab0 AS cor0
----
0
0
8

query I rowsort
SELECT DISTINCT + 61 + - cor0.col1 FROM tab0 AS cor0
----
-25
-30
-36

query I rowsort
SELECT DISTINCT + + 89 + + col0 FROM tab2 cor0
----
167
168
96

query I rowsort
SELECT - 78 FROM tab1
----
-78
-78
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 71 col2 FROM tab0
----
-71

query I rowsort
SELECT - ( + col0 ) * col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT - 27 + col0 + col2 AS col0 FROM tab2 AS cor0
----
7
77
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6190
SELECT col0 DIV - col2 FROM tab0 cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-6190
SELECT col0 / - col2 FROM tab0 cor0
----
-1
-35
0

query I rowsort
SELECT - col1 + col2 * col2 AS col1 FROM tab2 AS cor0
----
1427
617
698

query I rowsort
SELECT DISTINCT + + 23 + + col1 AS col1 FROM tab2 AS cor0
----
40
54
82

query I rowsort
SELECT - - col1 + col2 AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT 3 * - col2 FROM tab2
----
-114
-78
-81

query I rowsort
SELECT + col0 - col0 * col2 * col2 AS col0 FROM tab0
----
-26112
-598347
0

query I rowsort
SELECT col0 * + col1 * tab1.col0 FROM tab1
----
234
40960
83200

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6197
SELECT CAST( NULL AS SIGNED ) col2 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-6197
SELECT CAST ( NULL AS INTEGER ) col2 FROM tab1, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-6198
SELECT + 61 DIV 20 + col2 + col1 AS col0 FROM tab1 AS cor0
----
112
70
83

skipif mysql # not compatible
query I rowsort label-6198
SELECT + 61 / 20 + col2 + col1 AS col0 FROM tab1 AS cor0
----
112
70
83

query I rowsort
SELECT DISTINCT - - ( col1 ) + + col1 * - col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT + 60 * - cor0.col0 FROM tab1 AS cor0
----
-180
-3840
-4800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 46 * 25 col2 FROM tab0 AS cor0
----
1150

onlyif mysql # use DIV operator for integer division
query I rowsort label-6202
SELECT - col0 DIV + 58 + col1 + + col1 * col1 * + col2 col2 FROM tab2
----
10998
25978
90564

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6202
SELECT - col0 / + 58 + col1 + + col1 * col1 * + col2 col2 FROM tab2
----
10998
25978
90564

query I rowsort
SELECT 93 * - tab0.col1 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to a5cf9dd72007793e6e03569eadfed7bc

onlyif mysql # use DIV operator for integer division
query I rowsort label-6204
SELECT - 78 DIV - 63 + - col1 DIV tab0.col0 FROM tab0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-6204
SELECT - 78 / - 63 + - col1 / tab0.col0 FROM tab0
----
-1
-2
0

query I rowsort
SELECT 6 + - col1 * tab2.col2 AS col0 FROM tab2
----
-1528
-640
-831

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 94 + - tab2.col1 col0 FROM tab2
----
35
63
77

query I rowsort
SELECT col2 * 62 AS col0 FROM tab0
----
2046
5084
62

query I rowsort
SELECT + col1 - + ( - col2 ) AS col1 FROM tab2
----
55
58
85

query I rowsort
SELECT DISTINCT + col0 * col2 + col2 AS col1 FROM tab0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-6210
SELECT DISTINCT - col0 * + col1 + - col2 DIV col0 + col0 FROM tab1
----
-576
-93
-961

skipif mysql # not compatible
query I rowsort label-6210
SELECT DISTINCT - col0 * + col1 + - col2 / col0 + col0 FROM tab1
----
-576
-93
-961

query I rowsort
SELECT DISTINCT + 77 FROM tab0, tab0 AS cor0
----
77

query I rowsort
SELECT DISTINCT col2 - tab0.col1 AS col0 FROM tab0
----
-53
-9
-96

skipif mysql # not compatible
query I rowsort
SELECT - col2 + CAST ( + col2 * - col1 AS REAL ) AS col1 FROM tab1
----
-1344
-1458
-627

query I rowsort
SELECT ALL ( col0 ) + col2 AS col1 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6215
SELECT + CAST( col0 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6215
SELECT + CAST ( col0 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL - col1 + ( + 97 ) FROM tab1
----
71
84
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6217
SELECT ( cor0.col1 ) / tab0.col2 - + CAST( NULL AS SIGNED ) FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6217
SELECT ( cor0.col1 ) / tab0.col2 - + CAST ( NULL AS INTEGER ) FROM tab0, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - tab2.col0 * + ( col1 ) AS col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT - col2 * 25 FROM tab2
----
-650
-675
-950

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - - col2 col1 FROM tab2
----
52
54
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-6221
SELECT DISTINCT ( col2 ) DIV tab1.col0 + - 61 AS col2 FROM tab1
----
-43
-60
-61

skipif mysql # not compatible
query I rowsort label-6221
SELECT DISTINCT ( col2 ) / tab1.col0 + - 61 AS col2 FROM tab1
----
-43
-60
-61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6222
SELECT DISTINCT CAST( NULL AS SIGNED ) + + 35 + col1 AS col1 FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-6222
SELECT DISTINCT CAST ( NULL AS INTEGER ) + + 35 + col1 AS col1 FROM tab2
----
NULL

query I rowsort
SELECT 72 + - col1 FROM tab2
----
13
41
55

query I rowsort
SELECT DISTINCT col1 * + col1 + + tab2.col0 FROM tab2
----
3559
368
968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6225
SELECT ( - ( col0 ) * - CAST( NULL AS SIGNED ) ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6225
SELECT ( - ( col0 ) * - CAST ( NULL AS INTEGER ) ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 23 + 93 + tab0.col0 AS col1 FROM tab0
----
140
151
205

query I rowsort
SELECT DISTINCT 45 AS col2 FROM tab2, tab1 AS cor0
----
45

query I rowsort
SELECT ALL col2 * - ( col1 ) * col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT ALL 14 * 24 FROM tab1 AS cor0
----
336
336
336

onlyif mysql # use DIV operator for integer division
query I rowsort label-6230
SELECT ALL + col1 * 22 DIV col1 + + 36 AS col2 FROM tab0 AS cor0
----
58
58
58

skipif mysql # not compatible
query I rowsort label-6230
SELECT ALL + col1 * 22 / col1 + + 36 AS col2 FROM tab0 AS cor0
----
58
58
58

query I rowsort
SELECT ( 43 + col1 ) AS col0 FROM tab2
----
102
60
74

query I rowsort
SELECT ALL - + col1 * col0 - col1 * col2 AS col2 FROM tab2 AS cor0
----
-1054
-1989
-6136

query I rowsort
SELECT DISTINCT + ( col0 ) AS col2 FROM tab0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6234
SELECT ALL - 31 * col1 + + col1 * 65 + - cor0.col2 DIV - ( + cor0.col0 ) FROM tab1 AS cor0
----
340
443
902

skipif mysql # not compatible
query I rowsort label-6234
SELECT ALL - 31 * col1 + + col1 * 65 + - cor0.col2 / - ( + cor0.col0 ) FROM tab1 AS cor0
----
340
443
902

query I rowsort
SELECT + - 71 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 3907e0aa4f29c002120742c4abb3e23a

query I rowsort
SELECT + ( + 21 ) FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 312c166f4dc412730c43555105b1f44b

query I rowsort
SELECT DISTINCT + - cor0.col1 * + col2 + - 63 FROM tab0 AS cor0
----
-160
-2901
-7525

query I rowsort
SELECT DISTINCT + + col0 * 60 AS col2 FROM tab2 AS cor0
----
420
4680
4740

query I rowsort
SELECT DISTINCT + col0 * col0 + + 13 AS col1 FROM tab1 AS cor0
----
22
4109
6413

query I rowsort
SELECT ALL col2 - ( - col2 ) FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT DISTINCT - col1 + 96 - + col2 FROM tab2 AS cor0
----
11
38
41

query I rowsort
SELECT DISTINCT col0 + + ( - cor0.col2 ) * + col2 AS col0 FROM tab0 AS cor0
----
-1065
-6635
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 39 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT ALL - col0 * 12 + - 25 AS col1 FROM tab2
----
-109
-961
-973

query I rowsort
SELECT DISTINCT + + col2 + 16 * 76 + col1 AS col0 FROM tab1 AS cor0
----
1283
1296
1325

query I rowsort
SELECT ALL + cor0.col2 * col2 + col1 AS col0 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT ALL cor0.col2 + cor0.col2 * col1 * + col0 AS col1 FROM tab0 cor0
----
3396
664200
68145

query I rowsort
SELECT ALL - - cor0.col0 * col2 - + col1 AS col0 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT ALL - + col1 - col2 AS col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ( cor0.col2 ) AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT + cor0.col2 * col1 AS col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT - col1 * + 74 AS col0 FROM tab2 cor0
----
-1258
-2294
-4366

query I rowsort
SELECT + col0 * - ( + col1 * - col1 ) AS col1 FROM tab0 AS cor0
----
177504
329315
737009

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * 82 col0 FROM tab0 AS cor0
----
-2706
-6724
-82

query I rowsort
SELECT ( + 32 ) FROM tab0 cor0
----
32
32
32

query I rowsort
SELECT 94 + 49 FROM tab0 AS cor0
----
143
143
143

query I rowsort
SELECT col1 * 94 AS col0 FROM tab1 AS cor0
----
1222
2444
940

query I rowsort
SELECT - 98 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

query I rowsort
SELECT - 60 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 1a0b29f8e6f82c54623a665ba4af8fd1

query I rowsort
SELECT + + ( 14 ) * - col2 AS col1 FROM tab2 AS cor0
----
-364
-378
-532

onlyif mysql # use DIV operator for integer division
query I rowsort label-6261
SELECT ALL - col1 + col1 DIV + cor0.col1 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-6261
SELECT ALL - col1 + col1 / + cor0.col1 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT DISTINCT + + 61 + + col0 * + col1 FROM tab1 AS cor0
----
1101
139
701

query I rowsort
SELECT DISTINCT - ( + col1 ) * - 9 AS col2 FROM tab2 AS cor0
----
153
279
531

query I rowsort
SELECT - col2 * col2 + col1 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
-1512
-2679
-7968

query I rowsort
SELECT DISTINCT + - 31 + + col0 FROM tab1 AS cor0
----
-28
33
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 9 col2 FROM tab1 AS cor0
----
-9
-9
-9

query I rowsort
SELECT DISTINCT + + 85 * + col1 FROM tab2 AS cor0
----
1445
2635
5015

query I rowsort
SELECT - + 13 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
1014
1027
91

query I rowsort
SELECT ALL - - ( + col2 ) FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + 63 + col1 AS col2 FROM tab1 AS cor0
----
73
76
89

query I rowsort
SELECT 83 * - col0 + ( col2 ) + - cor0.col0 AS col0 FROM tab0 AS cor0
----
-1983
-2939
-7394

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab1.col2 - 70 col2 FROM tab1
----
-13
-16
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col1 + - col1 * + col0 col0 FROM tab2
----
-2686
-434
-9204

query I rowsort
SELECT - col0 + col2 * + ( 64 ) AS col1 FROM tab1 AS cor0
----
3453
3584
6064

query I rowsort
SELECT DISTINCT 72 * 47 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
3384

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 70 col2 FROM tab1
----
70
70
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 15 col2 FROM tab2
----
15
15
15

query I rowsort
SELECT DISTINCT + 50 AS col2 FROM tab2, tab1 AS cor0
----
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-6279
SELECT ALL - col2 DIV col1 + + col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6279
SELECT ALL - col2 / col1 + + col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT - - col1 * + cor0.col2 + col2 * 41 FROM tab2 AS cor0
----
1944
2204
2600

query I rowsort
SELECT ALL - 23 * - col1 FROM tab1 AS cor0
----
230
299
598

query I rowsort
SELECT 21 + + col0 FROM tab0 AS cor0
----
110
45
56

query I rowsort
SELECT DISTINCT - col2 * cor0.col0 + - 61 AS col0 FROM tab1 AS cor0
----
-223
-3709
-7741

query I rowsort
SELECT + ( + 18 ) + col2 * ( - col2 ) FROM tab0
----
-1071
-6706
17

query I rowsort
SELECT DISTINCT 42 AS col1 FROM tab2
----
42

query I rowsort
SELECT ( 18 ) FROM tab2
----
18
18
18

query I rowsort
SELECT + 85 AS col1 FROM tab0
----
85
85
85

query I rowsort
SELECT + 98 AS col1 FROM tab0
----
98
98
98

query I rowsort
SELECT - ( 40 ) AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f02f17e9bc17e514af018c6f245ed7a9

query I rowsort
SELECT + cor0.col0 + cor0.col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT - 57 + - cor0.col2 * + col1 AS col0 FROM tab0 AS cor0
----
-154
-2895
-7519

onlyif mysql # use DIV operator for integer division
query I rowsort label-6292
SELECT - col0 * col1 DIV - ( col0 ) FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-6292
SELECT - col0 * col1 / - ( col0 ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL + col2 * ( + col2 ) * col0 AS col0 FROM tab0
----
26136
35
598436

query I rowsort
SELECT DISTINCT 63 AS col2 FROM tab2, tab2 AS cor0
----
63

query I rowsort
SELECT DISTINCT + 87 FROM tab1, tab1 AS cor0
----
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 * col1 col1 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6297
SELECT + col2 * CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6297
SELECT + col2 * CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6298
SELECT DISTINCT + col1 DIV col1 FROM tab1 cor0
----
1

skipif mysql # not compatible
query I rowsort label-6298
SELECT DISTINCT + col1 / col1 FROM tab1 cor0
----
1

query I rowsort
SELECT col1 * - 52 AS col0 FROM tab0 AS cor0
----
-4472
-4732
-5044

skipif mysql # not compatible
query I rowsort
SELECT + + CAST ( ( cor0.col0 ) AS REAL ) * col0 FROM tab1 AS cor0
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + 21 ) col1 FROM tab2 AS cor0
----
-21
-21
-21

onlyif mysql # use DIV operator for integer division
query I rowsort label-6302
SELECT - + ( col2 ) DIV - col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6302
SELECT - + ( col2 ) / - col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col1 + - 36 FROM tab1 cor0
----
-10
-23
-26

query I rowsort
SELECT + col1 * col0 + - col1 AS col1 FROM tab2 AS cor0
----
1326
186
4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-6305
SELECT DISTINCT + - 8 DIV + col0 AS col2 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-6305
SELECT DISTINCT + - 8 / + col0 AS col2 FROM tab2 AS cor0
----
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6306
SELECT ALL - CAST( + 34 AS SIGNED ) * - col1 FROM tab0 cor0
----
2924
3094
3298

skipif mysql # not compatible
query I rowsort label-6306
SELECT ALL - CAST ( + 34 AS INTEGER ) * - col1 FROM tab0 cor0
----
2924
3094
3298

onlyif mysql # use DIV operator for integer division
query I rowsort label-6307
SELECT 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-6307
SELECT col1 / + col0 col2 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT ALL + + cor0.col0 * + cor0.col0 + - col0 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT - 76 + + col0 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
-42
28
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-6310
SELECT DISTINCT CAST( col2 AS SIGNED ) + + col2 DIV ( - 4 ) + col2 AS col0 FROM tab1 AS cor0
----
100
168
95

skipif mysql # not compatible
query I rowsort label-6310
SELECT DISTINCT CAST ( col2 AS INTEGER ) + + col2 / ( - 4 ) + col2 AS col0 FROM tab1 AS cor0
----
100
168
95

query I rowsort
SELECT - col0 + - col1 * 43 AS col1 FROM tab1 AS cor0
----
-1121
-494
-639

query I rowsort
SELECT + - col1 * + col0 * - col2 AS col2 FROM tab2 AS cor0
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + col2 col0 FROM tab2 cor0
----
-41
-52
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 * cor0.col2 col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ( + cor1.col2 ) FROM tab0, tab1 AS cor0 CROSS JOIN tab2, tab1, tab0 AS cor1
----
243 values hashing to 291cdf20f55dc7bbcb55f561dc0b74d8

query I rowsort
SELECT ALL col2 + ( + col1 ) + col0 FROM tab2 AS cor0
----
134
163
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * col0 * col1 + - col0 col1 FROM tab1 AS cor0
----
-36544
-4215
-99920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + cor0.col1 - + 30 col2 FROM tab2 AS cor0
----
107
66
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 97 col2 FROM tab1
----
97
97
97

query I rowsort
SELECT ALL tab1.col2 * col1 AS col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL + col0 * ( col0 ) + col1 - 3 FROM tab2
----
6140
6255
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + 40 ) * col0 col2 FROM tab0 AS cor0
----
-1400
-3560
-960

query I rowsort
SELECT DISTINCT - ( col1 ) * + col1 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL + ( 27 ) + - col1 FROM tab2 AS cor0
----
-32
-4
10

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6325
SELECT CAST( NULL AS DECIMAL ) * 92 * - 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-6325
SELECT CAST ( NULL AS REAL ) * 92 * - col2 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - 18 + col0 AS col2 FROM tab2 AS cor0
----
-11
60
61

query I rowsort
SELECT DISTINCT col2 + - col2 * 15 * tab1.col2 AS col2 FROM tab1
----
-138144
-43686
-48678

query I rowsort
SELECT + col0 - 39 AS col1 FROM tab2
----
-32
39
40

query I rowsort
SELECT ALL tab2.col1 - + col0 * col0 * col2 FROM tab2
----
-1292
-158125
-237141

query I rowsort
SELECT ALL + col0 * col1 + + 68 AS col1 FROM tab0
----
2132
3463
8167

query I rowsort
SELECT DISTINCT + + 21 AS col0 FROM tab2 AS cor0
----
21

query I rowsort
SELECT DISTINCT + col1 + col1 * col1 FROM tab0 AS cor0
----
7482
8372
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-6333
SELECT ALL + + 68 DIV col1 AS col2 FROM tab1 AS cor0
----
2
5
6

skipif mysql # not compatible
query I rowsort label-6333
SELECT ALL + + 68 / col1 AS col2 FROM tab1 AS cor0
----
2
5
6

query I rowsort
SELECT DISTINCT - 41 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
-41

onlyif mysql # use DIV operator for integer division
query I rowsort label-6335
SELECT DISTINCT - - 31 DIV col0 AS col2 FROM tab2 AS cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-6335
SELECT DISTINCT - - 31 / col0 AS col2 FROM tab2 AS cor0
----
0
4

query I rowsort
SELECT ALL - cor0.col2 + - cor0.col0 * col0 FROM tab0 AS cor0
----
-1226
-609
-8003

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 41 col2 FROM tab0 AS cor0
----
41
41
41

query I rowsort
SELECT ALL col0 + - col0 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 68 * + col1 FROM tab2 AS cor0
----
1156
2108
4012

query I rowsort
SELECT + + 23 * - col2 AS col2 FROM tab0 AS cor0
----
-1886
-23
-759

query I rowsort
SELECT DISTINCT - 73 * - cor0.col1 AS col1 FROM tab1 AS cor0
----
1898
730
949

query I rowsort
SELECT DISTINCT - 74 * - col1 AS col1 FROM tab2 AS cor0
----
1258
2294
4366

query I rowsort
SELECT + 48 + - col1 AS col0 FROM tab0 AS cor0
----
-38
-43
-49

query I rowsort
SELECT + + cor0.col0 + 87 * + 50 AS col0 FROM tab0 AS cor0
----
4374
4385
4439

query I rowsort
SELECT 24 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT ALL - - cor0.col2 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + 61 col1 FROM tab2 AS cor0
----
-1037
-1891
-3599

onlyif mysql # use DIV operator for integer division
query I rowsort label-6348
SELECT col0 DIV col0 + + col0 AS col1 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-6348
SELECT col0 / col0 + + col0 AS col1 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT + ( + 84 ) * + col2 * cor0.col2 + col2 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
244944
272916
774144

query I rowsort
SELECT ALL col2 * + ( - col0 ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT col2 + 35 FROM tab0 AS cor0
----
117
36
68

query I rowsort
SELECT + - col2 * - ( col2 + + ( + cor0.col2 ) ) AS col2 FROM tab2 AS cor0
----
1352
1458
2888

query I rowsort
SELECT - col0 * 94 + col1 FROM tab0
----
-2170
-3193
-8275

query I rowsort
SELECT ALL + tab2.col1 * col0 AS col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL + tab0.col1 * tab0.col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL ( + ( tab2.col0 ) + - 95 ) AS col1 FROM tab2
----
-16
-17
-88

query I rowsort
SELECT + ( 86 ) AS col1 FROM tab2 AS cor0
----
86
86
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col2 ) * col0 col1 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( cor0.col2 ) * + col1 col0 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6360
SELECT CAST( ( + col1 ) + col0 AS SIGNED ) FROM tab2
----
137
38
96

skipif mysql # not compatible
query I rowsort label-6360
SELECT CAST ( ( + col1 ) + col0 AS INTEGER ) FROM tab2
----
137
38
96

query I rowsort
SELECT ALL + ( - 11 ) AS col1 FROM tab1
----
-11
-11
-11

query I rowsort
SELECT + ( col1 ) + - col1 * + col2 AS col0 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT 57 * col1 * + 20 FROM tab0 AS cor0
----
103740
110580
98040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 71 * + col2 * col0 col0 FROM tab1
----
-11502
-259008
-545280

query I rowsort
SELECT - 49 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to adfccb10c9468825d9961e3613140f89

query I rowsort
SELECT DISTINCT - col1 * tab0.col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT col0 * 3 + col1 * - tab1.col0 FROM tab1
----
-448
-69
-800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6368
SELECT + col2 * CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6368
SELECT + col2 * CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + tab0.col2 + ( - 74 ) * tab0.col1 AS col0 FROM tab0
----
-6331
-6652
-7177

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6370
SELECT + col1 * - CAST( NULL AS SIGNED ) + - tab2.col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6370
SELECT + col1 * - CAST ( NULL AS INTEGER ) + - tab2.col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + col2 + + col1 * col1 FROM tab0 AS cor0
----
7363
8199
9408

query I rowsort
SELECT - + 32 * col2 + + col1 AS col0 FROM tab1 AS cor0
----
-1702
-1814
-3059

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6373
SELECT DISTINCT - CAST( 20 AS SIGNED ) + - col0 + col0 FROM tab1 AS cor0
----
-20

skipif mysql # not compatible
query I rowsort label-6373
SELECT DISTINCT - CAST ( 20 AS INTEGER ) + - col0 + col0 FROM tab1 AS cor0
----
-20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6374
SELECT ALL CAST( NULL AS SIGNED ) + 64 * col0 + + ( - col0 + + col2 ) * - col2 * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6374
SELECT ALL CAST ( NULL AS INTEGER ) + 64 * col0 + + ( - col0 + + col2 ) * - col2 * col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor0.col0 + - 62 AS col1 FROM tab2 AS cor0
----
-55
16
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6376
SELECT DISTINCT tab0.col0 * CAST( + col0 AS SIGNED ) * col0 + col2 FROM tab0
----
13857
42876
705051

skipif mysql # not compatible
query I rowsort label-6376
SELECT DISTINCT tab0.col0 * CAST ( + col0 AS INTEGER ) * col0 + col2 FROM tab0
----
13857
42876
705051

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 * 91 col1 FROM tab1
----
273
5824
7280

query I rowsort
SELECT col1 + 34 AS col1 FROM tab1 AS cor0
----
44
47
60

query I rowsort
SELECT + 45 * col0 + - col1 AS col1 FROM tab2 AS cor0
----
284
3451
3538

query I rowsort
SELECT - cor0.col1 + + col1 AS col1 FROM tab2 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 67 + col2 col2 FROM tab1 AS cor0
----
-10
-13
29

query I rowsort
SELECT + + col1 * - 95 FROM tab0 AS cor0
----
-8170
-8645
-9215

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6383
SELECT + col1 * - CAST( - col2 AS SIGNED ) AS col0 FROM tab0 cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-6383
SELECT + col1 * - CAST ( - col2 AS INTEGER ) AS col0 FROM tab0 cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6384
SELECT ALL col2 DIV col0 AS col2 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-6384
SELECT ALL col2 / col0 AS col2 FROM tab2 AS cor0
----
0
0
3

query I rowsort
SELECT ALL col1 + col2 * + col2 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT ALL - - 66 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 29794915b585eea848ad670075452c88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 8 col0 FROM tab0, tab1 AS cor0
----
9 values hashing to ffc5b4c98b57ae546521175995c49c57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6388
SELECT - col0 DIV + 64 FROM tab2 cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-6388
SELECT - col0 / + 64 FROM tab2 cor0
----
-1
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6389
SELECT DISTINCT ( col0 ) * cor0.col0 + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6389
SELECT DISTINCT ( col0 ) * cor0.col0 + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - + cor0.col1 * cor0.col2 * - col0 + ( 14 ) FROM tab0 AS cor0
----
3409
664132
68126

query I rowsort
SELECT - + 47 AS col0 FROM tab1 AS cor0
----
-47
-47
-47

query I rowsort
SELECT DISTINCT + 55 * 48 FROM tab1 AS cor0
----
2640

query I rowsort
SELECT ALL + 58 * col2 FROM tab0 AS cor0
----
1914
4756
58

query I rowsort
SELECT - col1 + + col0 * col0 AS col1 FROM tab0
----
1128
490
7830

query I rowsort
SELECT - tab1.col1 + - col0 * - col0 FROM tab1
----
-17
4086
6387

query I rowsort
SELECT + col1 * + 0 - - col1 AS col0 FROM tab1
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6397
SELECT DISTINCT - col0 + CAST( + col2 AS SIGNED ) + + col1 AS col1 FROM tab1
----
29
3
77

skipif mysql # not compatible
query I rowsort label-6397
SELECT DISTINCT - col0 + CAST ( + col2 AS INTEGER ) + + col1 AS col1 FROM tab1
----
29
3
77

query I rowsort
SELECT ALL ( + ( tab2.col1 ) ) AS col0 FROM tab2, tab0 cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT DISTINCT + tab0.col2 + ( col1 ) AS col2 FROM tab0
----
119
173
98

query I rowsort
SELECT ALL 48 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT DISTINCT col1 * 25 + col2 * - col2 AS col1 FROM tab0
----
-4449
1061
2424

query I rowsort
SELECT DISTINCT - - 91 * - cor0.col0 + ( cor0.col1 * col1 ) FROM tab0 AS cor0
----
182
5212
6224

query I rowsort
SELECT 67 + col2 * ( col1 ) * col0 + col1 * + 21 AS col2 FROM tab1 AS cor0
----
100180
36757
4825

query I rowsort
SELECT - + col1 + - col2 - ( col0 ) * + col2 * 74 AS col1 FROM tab0 AS cor0
----
-2688
-540225
-58727

query I rowsort
SELECT DISTINCT + ( - col1 ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT - col1 + - col2 + 9 FROM tab2 AS cor0
----
-46
-49
-76

query I rowsort
SELECT - 96 * - col0 + - col1 AS col0 FROM tab1 AS cor0
----
262
6134
7667

query I rowsort
SELECT 43 * - col0 + 71 - + col2 FROM tab0 AS cor0
----
-1435
-3838
-994

query I rowsort
SELECT DISTINCT - ( - 88 ) FROM tab2
----
88

query I rowsort
SELECT + 18 FROM tab0, tab1 AS cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT + ( col1 ) * + col1 AS col2 FROM tab2
----
289
3481
961

query I rowsort
SELECT DISTINCT - ( + col2 * col2 + col0 ) FROM tab1
----
-2919
-3313
-9296

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - tab2.col0 col1 FROM tab2
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col2 col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT col2 * + col1 - col1 AS col1 FROM tab2 cor0
----
1475
629
806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) + col0 col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL + 52 + col2 + col1 AS col1 FROM tab0
----
150
171
225

onlyif mysql # use DIV operator for integer division
query I rowsort label-6418
SELECT ALL col1 DIV col2 - col0 AS col2 FROM tab0
----
-22
-88
62

skipif mysql # not compatible
query I rowsort label-6418
SELECT ALL col1 / col2 - col0 AS col2 FROM tab0
----
-22
-88
62

query I rowsort
SELECT 87 * - col2 AS col1 FROM tab2
----
-2262
-2349
-3306

query I rowsort
SELECT ALL + cor0.col0 + col1 * + cor0.col1 FROM tab2 cor0
----
3559
368
968

query I rowsort
SELECT DISTINCT - col1 + + 51 AS col1 FROM tab2 AS cor0
----
-8
20
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-6422
SELECT - col1 DIV + 28 AS col2 FROM tab2 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-6422
SELECT - col1 / + 28 AS col2 FROM tab2 AS cor0
----
-1
-2
0

query I rowsort
SELECT ALL col0 - + tab2.col1 * - 93 FROM tab2
----
1660
2890
5565

query I rowsort
SELECT ALL - col2 * col0 + + col2 AS col2 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT col2 * tab1.col1 + col2 FROM tab1
----
1344
1458
627

query I rowsort
SELECT + col0 * + col2 + col2 AS col1 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT + cor0.col2 AS col1 FROM tab1, tab2, tab1 AS cor0, tab0
----
54
57
96

query I rowsort
SELECT + col1 + + col1 + - col2 FROM tab1
----
-2
-37
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6429
SELECT cor0.col0 * - ( + 17 * - col0 ) + - CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
108896
207
69689

skipif mysql # not compatible
query I rowsort label-6429
SELECT cor0.col0 * - ( + 17 * - col0 ) + - CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
108896
207
69689

onlyif mysql # use DIV operator for integer division
query I rowsort label-6430
SELECT DISTINCT col2 + col1 DIV + col1 AS col0 FROM tab2 cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-6430
SELECT DISTINCT col2 + col1 / + col1 AS col0 FROM tab2 cor0
----
27
28
39

query I rowsort
SELECT DISTINCT + - cor0.col1 * - col0 + + 17 FROM tab0 cor0
----
2081
3412
8116

query I rowsort
SELECT + col2 + 20 FROM tab2 AS cor0
----
46
47
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col2 + col2 col1 FROM tab0 AS cor0
----
246
3
99

query I rowsort
SELECT ALL + col2 + + 72 AS col0 FROM tab0
----
105
154
73

query I rowsort
SELECT DISTINCT - col1 * + col2 AS col0 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + cor0.col0 * col1 + + col2 AS col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT - - cor0.col0 + + col0 * col1 * col1 AS col0 FROM tab1 AS cor0
----
13600
2031
6464

query I rowsort
SELECT ALL - col2 * ( + col2 ) - - col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT ALL - col0 + + 78 * ( - col0 ) AS col1 FROM tab2 AS cor0
----
-553
-6162
-6241

query I rowsort
SELECT ALL - col2 + col1 * + cor0.col0 * col0 FROM tab2 AS cor0
----
106059
1492
358930

query I rowsort
SELECT - col0 * col0 + cor0.col1 AS col2 FROM tab0 AS cor0
----
-1128
-490
-7830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6442
SELECT ALL + col1 * + CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-6442
SELECT ALL + col1 * + CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL + col1 * cor0.col2 * + col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT + col1 + + ( + 20 ) FROM tab1 AS cor0
----
30
33
46

query I rowsort
SELECT + col0 * col1 + + 66 AS col2 FROM tab2 cor0
----
1409
283
4668

onlyif mysql # use DIV operator for integer division
query I rowsort label-6446
SELECT ALL - col0 + - col1 * col0 DIV col2 FROM tab0 cor0
----
-187
-3430
-86

skipif mysql # not compatible
query I rowsort label-6446
SELECT ALL - col0 + - col1 * col0 / col2 FROM tab0 cor0
----
-187
-3430
-86

query I rowsort
SELECT ALL - - col0 - - 63 * 83 FROM tab2 AS cor0
----
5236
5307
5308

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col2 ) col0 FROM tab0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col1 col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT 15 + - 91 AS col0 FROM tab0
----
-76
-76
-76

query I rowsort
SELECT DISTINCT - - 8 + 85 * + col1 FROM tab0 AS cor0
----
7318
7743
8253

query I rowsort
SELECT ( - 82 ) FROM tab2 AS cor0
----
-82
-82
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-6453
SELECT DISTINCT - ( col2 ) DIV col0 AS col1 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-6453
SELECT DISTINCT - ( col2 ) / col0 AS col1 FROM tab1 AS cor0
----
-1
-18
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6454
SELECT ALL CAST( + col0 AS SIGNED ) - - col2 * + col2 FROM tab1 AS cor0
----
2919
3313
9296

skipif mysql # not compatible
query I rowsort label-6454
SELECT ALL CAST ( + col0 AS INTEGER ) - - col2 * + col2 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT DISTINCT col1 + + col0 * + col2 AS col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT + 39 * cor0.col0 FROM tab1 AS cor0
----
117
2496
3120

query I rowsort
SELECT ALL - + col2 * - cor0.col1 + col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT + cor0.col1 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT col1 * col1 - col0 AS col1 FROM tab1 AS cor0
----
36
673
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6460
SELECT ALL - + col2 + col0 DIV 19 FROM tab1 AS cor0
----
-54
-54
-92

skipif mysql # not compatible
query I rowsort label-6460
SELECT ALL - + col2 + col0 / 19 FROM tab1 AS cor0
----
-54
-54
-92

query I rowsort
SELECT ALL - + col1 * col1 + - 49 AS col2 FROM tab2 cor0
----
-1010
-338
-3530

query I rowsort
SELECT ALL - ( - cor0.col0 ) FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + + col1 - col0 * - 12 FROM tab2 AS cor0
----
115
965
995

query I rowsort
SELECT ALL + col0 + col1 AS col2 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - col2 * + col0 - - cor0.col0 FROM tab1 cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL - - col1 * col0 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab2, tab0 cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT ALL - col0 * col0 + + ( - col1 ) AS col1 FROM tab0 AS cor0
----
-1322
-662
-8012

query I rowsort
SELECT ALL - - col1 * + col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT col1 + ( + col1 ) AS col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL cor0.col0 + col2 * col2 AS col2 FROM tab2 cor0
----
1523
736
754

query I rowsort
SELECT DISTINCT col0 * + ( + cor0.col2 ) AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL + col2 * + ( cor0.col2 ) AS col1 FROM tab1 cor0
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6474
SELECT ALL - cor0.col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6474
SELECT ALL - cor0.col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + - ( - cor0.col2 ) * cor0.col1 AS col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT - + col2 * + 80 AS col1 FROM tab2 AS cor0
----
-2080
-2160
-3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-6477
SELECT ALL col2 DIV col2 + col1 AS col0 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-6477
SELECT ALL col2 / col2 + col1 AS col0 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT DISTINCT 69 AS col0 FROM tab0, tab0 AS cor0
----
69

query I rowsort
SELECT DISTINCT - col1 * + col2 + + col2 * col1 * col1 FROM tab1 cor0
----
14976
35100
5130

query I rowsort
SELECT - col1 * cor0.col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + col2 * 23 + cor0.col0 FROM tab2 AS cor0
----
628
676
953

query I rowsort
SELECT ALL + + 93 * col1 + col2 AS col1 FROM tab1 AS cor0
----
1305
2472
987

query I rowsort
SELECT - 10 * col1 + + col0 FROM tab1 AS cor0
----
-257
-36
-50

query I rowsort
SELECT + 11 + - col1 FROM tab1 AS cor0
----
-15
-2
1

query I rowsort
SELECT DISTINCT - + ( + col1 ) * col2 + col2 AS col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT + 63 - - col2 * col1 FROM tab0
----
160
2901
7525

onlyif mysql # use DIV operator for integer division
query I rowsort label-6487
SELECT - col1 DIV - col1 + - cor0.col0 - - cor0.col1 * cor0.col2 FROM tab0 AS cor0
----
2815
63
7374

skipif mysql # not compatible
query I rowsort label-6487
SELECT - col1 / - col1 + - cor0.col0 - - cor0.col1 * cor0.col2 FROM tab0 AS cor0
----
2815
63
7374

query I rowsort
SELECT DISTINCT + + 11 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
-187
-341
-649

query I rowsort
SELECT + - col2 + - col0 * - col2 AS col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT DISTINCT - tab1.col0 * - col2 + - col2 AS col0 FROM tab1
----
108
3591
7584

query I rowsort
SELECT ALL + col0 + - 13 AS col2 FROM tab2 cor0
----
-6
65
66

query I rowsort
SELECT ALL + - col1 - 88 FROM tab1 AS cor0
----
-101
-114
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * ( 72 ) * cor0.col2 col1 FROM tab1 AS cor0
----
11664
262656
552960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6494
SELECT - col2 * - CAST( col1 AS SIGNED ) FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-6494
SELECT - col2 * - CAST ( col1 AS INTEGER ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - col0 - col0 AS col2 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT - + col2 * + col1 + 86 * col0 FROM tab0 AS cor0
----
-774
192
2913

query I rowsort
SELECT DISTINCT col0 + col0 + col0 * + col2 * + col1 AS col0 FROM tab0
----
3465
664296
68160

query I rowsort
SELECT 62 + + tab2.col2 AS col0 FROM tab2
----
100
88
89

query I rowsort
SELECT - 1 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 84da757b1b7b0069ce25607f39bc08d9

query I rowsort
SELECT 62 * - col0 + + col1 * col1 * col0 FROM tab0
----
176016
327145
731491

query I rowsort
SELECT DISTINCT 97 + col1 FROM tab2
----
114
128
156

onlyif mysql # use DIV operator for integer division
query I rowsort label-6502
SELECT + - col0 DIV - col1 + + 94 * col2 col1 FROM tab0 AS cor0
----
3102
7708
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6502
SELECT + - col0 / - col1 + + 94 * col2 col1 FROM tab0 AS cor0
----
3102
7708
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * 40 col1 FROM tab1 AS cor0
----
-1040
-400
-520

query I rowsort
SELECT - col1 + + ( + ( - tab1.col1 ) ) AS col0 FROM tab1
----
-20
-26
-52

query I rowsort
SELECT ALL + col1 * - col0 * col1 AS col1 FROM tab1
----
-13520
-2028
-6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col1 * col1 col2 FROM tab1 AS cor0
----
-13520
-2028
-6400

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT col1 * CAST ( + 53 * - col1 AS REAL ) col0 FROM tab2
----
-15317
-184493
-50933

query I rowsort
SELECT ALL + cor0.col1 AS col0 FROM tab0, tab2 cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT - 22 - 66 FROM tab0, tab0 AS cor0
----
9 values hashing to 467301f887614eb7beda22c561b0fad2

query I rowsort
SELECT - tab2.col1 * - tab2.col2 + col1 FROM tab2
----
1593
663
868

query I rowsort
SELECT - 59 * + col2 AS col1 FROM tab1 AS cor0
----
-3186
-3363
-5664

query I rowsort
SELECT DISTINCT - 79 * cor0.col1 FROM tab1, tab2 AS cor0
----
-1343
-2449
-4661

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6513
SELECT DISTINCT CAST( + col1 + - col2 AS SIGNED ) AS col0 FROM tab2
----
-21
33
4

skipif mysql # not compatible
query I rowsort label-6513
SELECT DISTINCT CAST ( + col1 + - col2 AS INTEGER ) AS col0 FROM tab2
----
-21
33
4

query I rowsort
SELECT ALL ( col0 ) + ( - col1 ) AS col0 FROM tab2 cor0
----
-24
19
62

query I rowsort
SELECT - col1 * - col1 + col0 * ( cor0.col1 ) FROM tab0 AS cor0
----
12804
16380
9460

query I rowsort
SELECT ALL + 34 * + col2 FROM tab2 AS cor0
----
1292
884
918

query I rowsort
SELECT 85 * + col1 + 57 FROM tab1 AS cor0
----
1162
2267
907

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6518
SELECT + col1 + col2 / - CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6518
SELECT + col1 + col2 / - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - col1 + - col0 + + 50 FROM tab1 cor0
----
-17
-4
73

query I rowsort
SELECT ALL - 7 * col2 * - col1 AS col1 FROM tab0 AS cor0
----
19866
52234
679

query I rowsort
SELECT DISTINCT + cor0.col2 * + col1 + - ( 34 ) FROM tab2 AS cor0
----
1500
612
803

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 22 col0 FROM tab0 AS cor0
----
-22
-22
-22

query I rowsort
SELECT - cor0.col1 - + col2 * + 57 AS col1 FROM tab2 AS cor0
----
-1541
-1570
-2183

query I rowsort
SELECT DISTINCT + 17 FROM tab2, tab1 AS cor0
----
17

query I rowsort
SELECT ALL - + 29 FROM tab2 AS cor0
----
-29
-29
-29

query I rowsort
SELECT + - 70 + - ( - col2 ) * 88 + col1 FROM tab1 AS cor0
----
4708
4956
8391

onlyif mysql # use DIV operator for integer division
query I rowsort label-6527
SELECT DISTINCT + cor0.col1 + col1 DIV col2 FROM tab0 AS cor0
----
194
88
92

skipif mysql # not compatible
query I rowsort label-6527
SELECT DISTINCT + cor0.col1 + col1 / col2 FROM tab0 AS cor0
----
194
88
92

query I rowsort
SELECT - 29 * col1 AS col0 FROM tab0 AS cor0
----
-2494
-2639
-2813

query I rowsort
SELECT ALL - ( + col1 ) - cor0.col2 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT DISTINCT 1 * - col1 + col2 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT - + 14 AS col0 FROM tab2 AS cor0
----
-14

query I rowsort
SELECT DISTINCT 33 + - col1 AS col0 FROM tab1 AS cor0
----
20
23
7

query I rowsort
SELECT ALL - cor0.col1 - - col2 AS col0 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT - col1 * 76 FROM tab1
----
-1976
-760
-988

query I rowsort
SELECT DISTINCT - 97 * - col0 AS col0 FROM tab1 AS cor0
----
291
6208
7760

query I rowsort
SELECT - col2 * col1 + ( + col2 ) * - col0 + col0 FROM tab0 AS cor0
----
-14671
-3606
-97

query I rowsort
SELECT - - col2 * - col2 * - cor0.col1 AS col1 FROM tab0 cor0
----
611884
93654
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6538
SELECT - + col2 * CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort label-6538
SELECT - + col2 * CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - tab2.col1 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT col0 - - 32 FROM tab1 AS cor0
----
112
35
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col0 * + col2 col1 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT + col2 * tab2.col2 AS col1 FROM tab2
----
1444
676
729

query I rowsort
SELECT + cor0.col1 * ( - col0 ) FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6544
SELECT col2 DIV col1 AS col0 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-6544
SELECT col2 / col1 AS col0 FROM tab2
----
0
0
2

query I rowsort
SELECT ALL - - col1 * 9 AS col2 FROM tab2 AS cor0
----
153
279
531

query I rowsort
SELECT DISTINCT - + 72 * 56 FROM tab2 cor0
----
-4032

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + col2 ) * col2 col0 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + col0 + + col2 * cor0.col2 * col0 AS col2 FROM tab0 AS cor0
----
26160
598525
70

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( col1 AS REAL ) FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL - - col1 * - 18 AS col1 FROM tab1 AS cor0
----
-180
-234
-468

query I rowsort
SELECT ALL - - col1 * - col2 FROM tab2 cor0
----
-1534
-646
-837

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-6553
SELECT - 42 DIV + col0 FROM tab2 AS cor0
----
-6
0
0

skipif mysql # not compatible
query I rowsort label-6553
SELECT - 42 / + col0 FROM tab2 AS cor0
----
-6
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6554
SELECT + 92 DIV + col0 col2 FROM tab0 cor0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6554
SELECT + 92 / + col0 col2 FROM tab0 cor0
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-6555
SELECT + col2 * + CAST( col1 AS SIGNED ) DIV col1 + + tab2.col0 DIV 66 FROM tab2
----
27
27
39

skipif mysql # not compatible
query I rowsort label-6555
SELECT + col2 * + CAST ( col1 AS INTEGER ) / col1 + + tab2.col0 / 66 FROM tab2
----
27
27
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - 83 col1 FROM tab0
----
14
3
8

query I rowsort
SELECT + tab2.col0 * - col0 + - 31 FROM tab2
----
-6115
-6272
-80

query I rowsort
SELECT + col1 - - ( - tab0.col0 ) AS col0 FROM tab0
----
2
62
62

query I rowsort
SELECT DISTINCT + col2 + - col1 - + tab0.col2 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT 53 - - col1 FROM tab2 AS cor0
----
112
70
84

query I rowsort
SELECT DISTINCT + ( col1 ) - - col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT - - col1 * + col1 + col1 * - cor0.col2 FROM tab1 AS cor0
----
-1079
-470
-728

query I rowsort
SELECT DISTINCT - 16 + col2 FROM tab2 AS cor0
----
10
11
22

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6564
SELECT + + CAST( NULL AS SIGNED ) * col1 + + col2 AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6564
SELECT + + CAST ( NULL AS INTEGER ) * col1 + + col2 AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( col0 ) AS col1 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT ALL col1 * col1 * col1 + - col2 AS col1 FROM tab2
----
205353
29764
4875

query I rowsort
SELECT + 33 * + col0 * - cor0.col2 + ( + cor0.col1 ) FROM tab1 AS cor0
----
-120374
-253427
-5320

query I rowsort
SELECT - + 25 + col2 AS col2 FROM tab1 AS cor0
----
29
32
71

query I rowsort
SELECT DISTINCT cor0.col1 FROM tab1, tab0 cor0, tab0 AS cor1, tab2 AS cor2
----
86
91
97

query I rowsort
SELECT ALL + + cor0.col2 + ( col1 ) AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT + 5 AS col0 FROM tab0, tab0 AS cor0, tab2 cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

query I rowsort
SELECT ALL col0 * + col2 + ( cor0.col2 ) * - ( 60 ) AS col0 FROM tab0 AS cor0
----
-1188
-25
2378

query I rowsort
SELECT DISTINCT + col1 + + cor0.col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL cor0.col0 + + 34 AS col0 FROM tab1 AS cor0
----
114
37
98

query I rowsort
SELECT DISTINCT col2 + + col2 * col0 AS col0 FROM tab2 AS cor0
----
2054
216
3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6576
SELECT ALL - + col0 + CAST( col2 AS SIGNED ) FROM tab0 AS cor0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-6576
SELECT ALL - + col0 + CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6577
SELECT ALL col0 + CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6577
SELECT ALL col0 + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 - col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT + col0 * col2 + + ( + cor0.col0 ) FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT ALL - tab0.col1 AS col0 FROM tab1, tab2, tab1 cor0, tab0
----
81 values hashing to 786a240f80bef6f9c6a190e92cd4f9e8

query I rowsort
SELECT - + col0 * - 92 FROM tab1 AS cor0
----
276
5888
7360

query I rowsort
SELECT + - cor0.col2 * 6 * - col2 FROM tab1 AS cor0
----
17496
19494
55296

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6583
SELECT + col0 * col0 + CAST( + col1 AS SIGNED ) + col1 * - col0 FROM tab0
----
-1402
-2073
-87

skipif mysql # not compatible
query I rowsort label-6583
SELECT + col0 * col0 + CAST ( + col1 AS INTEGER ) + col1 * - col0 FROM tab0
----
-1402
-2073
-87

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 cor2, tab0 cor3
----
3645 values hashing to ab1725cc571093d8268326e5b556cfaf

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6585
SELECT + + col0 * - CAST( col2 AS SIGNED ) + - col0 FROM tab1 cor0
----
-165
-3712
-7760

skipif mysql # not compatible
query I rowsort label-6585
SELECT + + col0 * - CAST ( col2 AS INTEGER ) + - col0 FROM tab1 cor0
----
-165
-3712
-7760

query I rowsort
SELECT DISTINCT + col0 * - ( col0 * + col2 ) AS col0 FROM tab0 cor0
----
-1225
-19008
-649522

onlyif mysql # use DIV operator for integer division
query I rowsort label-6587
SELECT col2 + - CAST( col2 AS SIGNED ) DIV col1 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6587
SELECT col2 + - CAST ( col2 AS INTEGER ) / col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + tab0.col0 FROM tab2, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + 92 + cor0.col2 AS col1 FROM tab2, tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
81 values hashing to 952b3c5df2e1a24446170e89435499b3

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( + col2 AS REAL ) + + tab2.col1 AS col0 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL - + col2 * cor0.col1 + + col1 - - ( col1 ) AS col0 FROM tab2 AS cor0
----
-1416
-612
-775

query I rowsort
SELECT + - col2 * - 63 AS col1 FROM tab2 cor0
----
1638
1701
2394

query I rowsort
SELECT - ( - ( cor0.col1 ) ) * col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT ( col2 ) * col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT ( + cor0.col2 ) + col0 AS col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + 91 * col2 FROM tab2 AS cor0
----
2366
2457
3458

query I rowsort
SELECT 98 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT ALL - cor0.col1 + col1 * ( + col2 ) FROM tab0 cor0
----
0
2752
7371

query I rowsort
SELECT + 17 * col1 - - col1 AS col2 FROM tab2 AS cor0
----
1062
306
558

query I rowsort
SELECT ALL cor0.col0 + cor0.col1 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT - + col0 * + col0 * 49 FROM tab2 AS cor0
----
-2401
-298116
-305809

onlyif mysql # use DIV operator for integer division
query I rowsort label-6602
SELECT + + col2 DIV - col1 - - ( cor0.col1 ) AS col2 FROM tab2 AS cor0
----
15
31
59

skipif mysql # not compatible
query I rowsort label-6602
SELECT + + col2 / - col1 - - ( cor0.col1 ) AS col2 FROM tab2 AS cor0
----
15
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 - col0 col2 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT - col0 * - col2 * - col0 - - col1 FROM tab2 cor0
----
-1292
-158125
-237141

query I rowsort
SELECT - + 28 * col1 FROM tab0 AS cor0
----
-2408
-2548
-2716

query I rowsort
SELECT + + col2 - 64 AS col2 FROM tab2 AS cor0
----
-26
-37
-38

query I rowsort
SELECT DISTINCT cor0.col2 * - cor0.col0 + col1 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT - ( col0 ) * - col2 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 35 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT + - 51 FROM tab2 cor0
----
-51
-51
-51

query I rowsort
SELECT + - col0 + - cor0.col0 * col2 * - ( col2 * + cor0.col2 ) AS col0 FROM tab1 AS cor0
----
11852288
472389
70778800

query I rowsort
SELECT + ( - 79 ) FROM tab2
----
-79
-79
-79

query I rowsort
SELECT + 45 * + cor0.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 7ce3641fa36f0b29cae048c6237e46ab

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6614
SELECT ALL CAST( - col0 AS SIGNED ) * - col1 + 56 - - col0 * cor0.col2 AS col2 FROM tab2 cor0
----
4401
462
6686

skipif mysql # not compatible
query I rowsort label-6614
SELECT ALL CAST ( - col0 AS INTEGER ) * - col1 + 56 - - col0 * cor0.col2 AS col2 FROM tab2 cor0
----
4401
462
6686

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6615
SELECT ALL - CAST( NULL AS SIGNED ) * cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6615
SELECT ALL - CAST ( NULL AS INTEGER ) * cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 36 - 28 * cor0.col2 AS col0 FROM tab0 AS cor0
----
-2332
-64
-960

query I rowsort
SELECT DISTINCT 60 FROM tab2, tab0 AS cor0
----
60

query I rowsort
SELECT DISTINCT + col2 + - tab1.col0 + col0 FROM tab1
----
54
57
96

query I rowsort
SELECT + col0 * - 13 + - col1 AS col2 FROM tab0
----
-1248
-398
-552

query I rowsort
SELECT 83 * col0 + col0 + + 89 FROM tab2
----
6641
6725
677

query I rowsort
SELECT - - 73 - ( - cor0.col1 ) * - 23 FROM tab1 AS cor0
----
-157
-226
-525

query I rowsort
SELECT DISTINCT - col1 + - 47 + + col1 FROM tab0 AS cor0
----
-47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6623
SELECT + - col0 * col1 - - col0 * + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6623
SELECT + - col0 * col1 - - col0 * + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6624
SELECT ALL - col2 * cor0.col2 + col2 DIV col1 col0 FROM tab1 AS cor0
----
-2914
-3244
-9209

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6624
SELECT ALL - col2 * cor0.col2 + col2 / col1 col0 FROM tab1 AS cor0
----
-2914
-3244
-9209

query I rowsort
SELECT ALL 2 FROM tab0, tab1 cor0, tab1 cor1
----
27 values hashing to 535345c50a19fdab97ce05d1837b1f09

query I rowsort
SELECT DISTINCT tab1.col0 + tab1.col1 * - 18 FROM tab1
----
-116
-154
-465

query I rowsort
SELECT ( col0 + 24 * 93 ) AS col1 FROM tab2
----
2239
2310
2311

query I rowsort
SELECT ALL - tab1.col0 * + 10 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 61078693a69c9f1a2095d9ffa3080946

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6629
SELECT DISTINCT CAST( cor1.col2 AS SIGNED ) AS col1 FROM tab0, tab1 AS cor0, tab1 cor1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6629
SELECT DISTINCT CAST ( cor1.col2 AS INTEGER ) AS col1 FROM tab0, tab1 AS cor0, tab1 cor1
----
54
57
96

query I rowsort
SELECT - cor0.col0 + cor0.col1 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to c99cbeca6e6fdb3507b2e08470c1cda6

query I rowsort
SELECT - + 52 AS col2 FROM tab1 cor0
----
-52
-52
-52

query I rowsort
SELECT ALL + col2 * - col2 + 33 FROM tab2 AS cor0
----
-1411
-643
-696

query I rowsort
SELECT - + col2 * + cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL - + col2 + 49 * col0 FROM tab0 AS cor0
----
1143
1714
4279

query I rowsort
SELECT DISTINCT - cor0.col2 - - 56 FROM tab2 AS cor0
----
18
29
30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6636
SELECT DISTINCT + col1 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6636
SELECT DISTINCT + col1 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL col2 + col2 + + ( + col2 ) FROM tab2 AS cor0
----
114
78
81

query I rowsort
SELECT ALL + cor0.col2 + + ( - ( col1 ) ) FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL + col1 * + 22 + col0 AS col2 FROM tab1 AS cor0
----
284
366
575

query I rowsort
SELECT ALL col0 * tab2.col0 AS col0 FROM tab2
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-6641
SELECT ALL + col2 DIV + 49 + col1 FROM tab1 cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-6641
SELECT ALL + col2 / + 49 + col1 FROM tab1 cor0
----
11
14
27

query I rowsort
SELECT ALL col1 + ( col0 ) AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL col1 * ( col2 ) FROM tab2
----
1534
646
837

query I rowsort
SELECT + col1 + - 65 AS col2 FROM tab1
----
-39
-52
-55

query I rowsort
SELECT ALL - cor0.col1 * 85 FROM tab0 AS cor0
----
-7310
-7735
-8245

query I rowsort
SELECT DISTINCT - + col1 * - ( col2 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT + col0 + + col0 * - col0 FROM tab2 AS cor0
----
-42
-6006
-6162

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6648
SELECT + col1 * CAST( + cor0.col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
100
169
676

skipif mysql # not compatible
query I rowsort label-6648
SELECT + col1 * CAST ( + cor0.col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6649
SELECT DISTINCT + - col1 * - CAST( NULL AS SIGNED ) col2 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6649
SELECT DISTINCT + - col1 * - CAST ( NULL AS INTEGER ) col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - - 13 * - ( - cor0.col0 ) AS col2 FROM tab2 cor0
----
1014
1027
91

query I rowsort
SELECT ALL - + cor0.col1 + 4 AS col0 FROM tab1 AS cor0
----
-22
-6
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6652
SELECT DISTINCT + col2 * 88 / - col2 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6652
SELECT DISTINCT + col2 * 88 / - col2 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col2 * + col1 * col2 + - col2 AS col2 FROM tab1
----
-119904
-32547
-75870

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + 57 ) col2 FROM tab2 AS cor0
----
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 13 + + cor0.col0 col2 FROM tab2 AS cor0
----
20
91
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 + + col1 col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT col0 + 74 * cor0.col2 + + col1 FROM tab1 cor0
----
4025
4292
7197

query I rowsort
SELECT ALL + + ( - col0 ) + col1 * col1 + + 72 AS col0 FROM tab2 AS cor0
----
1026
282
3475

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - 93 ) * col0 col0 FROM tab2 AS cor0
----
-651
-7254
-7347

query I rowsort
SELECT col0 + col0 * tab0.col1 AS col1 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT - col0 * + col1 * + col2 FROM tab1
----
-36480
-4212
-99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-6662
SELECT ALL - - col0 DIV - cor0.col0 FROM tab0 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6662
SELECT ALL - - col0 / - cor0.col0 FROM tab0 cor0
----
-1
-1
-1

query I rowsort
SELECT ALL 70 + + col0 AS col2 FROM tab2 AS cor0
----
148
149
77

query I rowsort
SELECT - 82 * col0 + - cor0.col2 AS col1 FROM tab2 cor0
----
-601
-6422
-6516

query I rowsort
SELECT DISTINCT 17 AS col0 FROM tab1 AS cor0
----
17

query I rowsort
SELECT + 4 * - col1 + - col0 AS col0 FROM tab0 AS cor0
----
-368
-423
-453

query I rowsort
SELECT + ( col0 ) + col0 AS col2 FROM tab2 cor0
----
14
156
158

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 + 89 + + col1 AS col0 FROM tab1 AS cor0
----
102
115
99

query I rowsort
SELECT + 45 * col1 + - col1 FROM tab1 AS cor0
----
1144
440
572

query I rowsort
SELECT ALL - 16 * - col1 AS col2 FROM tab1 AS cor0
----
160
208
416

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * + col2 col2 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL + - 99 FROM tab0 cor0
----
-99
-99
-99

query I rowsort
SELECT ALL + 88 - tab2.col2 FROM tab2
----
50
61
62

query I rowsort
SELECT col0 * + col2 + + col1 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-6676
SELECT DISTINCT - 14 DIV col2 + + ( col2 + - col1 ) AS col1 FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-6676
SELECT DISTINCT - 14 / col2 + + ( col2 + - col1 ) AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL 37 + - tab2.col0 * 69 FROM tab2
----
-446
-5345
-5414

query I rowsort
SELECT DISTINCT + col1 * - 32 FROM tab2 AS cor0
----
-1888
-544
-992

query I rowsort
SELECT + col0 * - 16 * + col2 + - ( 87 * - col0 ) + 99 AS col0 FROM tab1 AS cor0
----
-115821
-2232
-52701

query I rowsort
SELECT cor0.col1 * - 26 + col2 * - ( + 77 ) FROM tab0 AS cor0
----
-2599
-4777
-8680

query I rowsort
SELECT DISTINCT + 24 + col0 FROM tab1 AS cor0
----
104
27
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-6682
SELECT DISTINCT - + col2 DIV + col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6682
SELECT DISTINCT - + col2 / + col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL + col2 * col2 + col2 FROM tab1 cor0
----
2970
3306
9312

query I rowsort
SELECT DISTINCT - - cor0.col0 * - col0 * - col2 FROM tab0 AS cor0
----
1225
19008
649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col1 ) + + col1 col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6686
SELECT - ( col1 ) + - col2 * - 85 - col0 DIV cor0.col2 AS col2 FROM tab0 AS cor0
----
-47
2719
6878

skipif mysql # not compatible
query I rowsort label-6686
SELECT - ( col1 ) + - col2 * - 85 - col0 / cor0.col2 AS col2 FROM tab0 AS cor0
----
-47
2719
6878

query I rowsort
SELECT ALL col2 - - col1 * ( - col0 ) * 28 FROM tab0
----
-226690
-57759
-95059

query I rowsort
SELECT ALL + col0 + 30 * + col1 * + col2 FROM tab1
----
17164
37520
42123

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6689
SELECT DISTINCT + CAST( NULL AS SIGNED ) FROM tab2, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6689
SELECT DISTINCT + CAST ( NULL AS INTEGER ) FROM tab2, tab1 AS cor0
----
NULL

query I rowsort
SELECT ( - col1 ) + col2 * ( col2 + col0 ) FROM tab0 AS cor0
----
-61
13931
1795

query I rowsort
SELECT ALL - col0 - - ( col1 ) FROM tab2
----
-19
-62
24

query I rowsort
SELECT - cor0.col1 * + col2 + col2 - col1 AS col0 FROM tab2 AS cor0
----
-1567
-625
-841

query I rowsort
SELECT + - col2 + + 87 AS col0 FROM tab1 cor0
----
-9
30
33

query I rowsort
SELECT 71 + 45 - - cor0.col2 AS col1 FROM tab1 AS cor0
----
170
173
212

query I rowsort
SELECT + ( 39 ) FROM tab2 AS cor0
----
39
39
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-6696
SELECT DISTINCT col1 DIV 33 AS col0 FROM tab2
----
0
1

skipif mysql # not compatible
query I rowsort label-6696
SELECT DISTINCT col1 / 33 AS col0 FROM tab2
----
0
1

query I rowsort
SELECT DISTINCT 73 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
73

query I rowsort
SELECT + col0 * - 61 * cor0.col0 FROM tab2 AS cor0
----
-2989
-371124
-380701

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6699
SELECT col1 * CAST( 69 AS SIGNED ) FROM tab0 cor0
----
5934
6279
6693

skipif mysql # not compatible
query I rowsort label-6699
SELECT col1 * CAST ( 69 AS INTEGER ) FROM tab0 cor0
----
5934
6279
6693

query I rowsort
SELECT + cor0.col0 AS col0 FROM tab0, tab2 cor0, tab2 cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT col0 + - col1 * col1 AS col2 FROM tab1
----
-36
-673
-89

query I rowsort
SELECT DISTINCT 97 FROM tab2, tab2 cor0
----
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6703
SELECT ALL col2 DIV col0 AS col1 FROM tab0 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6703
SELECT ALL col2 / col0 AS col1 FROM tab0 cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6704
SELECT ALL col0 DIV tab1.col1 AS col0 FROM tab1
----
0
6
6

skipif mysql # not compatible
query I rowsort label-6704
SELECT ALL col0 / tab1.col1 AS col0 FROM tab1
----
0
6
6

query I rowsort
SELECT + 36 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - col0 col0 FROM tab1 AS cor0
----
-121
-176
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + 58 col0 FROM tab1 AS cor0
----
68
71
84

query I rowsort
SELECT DISTINCT 34 AS col1 FROM tab0, tab1 AS cor0
----
34

query I rowsort
SELECT ALL + col2 + ( - col0 ) AS col2 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6710
SELECT ALL cor0.col2 + CAST( NULL AS DECIMAL ) * 97 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6710
SELECT ALL cor0.col2 + CAST ( NULL AS REAL ) * 97 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * + 46 * col1 + col2 AS col0 FROM tab2 AS cor0
----
13332
160152
44233

query I rowsort
SELECT DISTINCT + - cor0.col2 * - 84 + + col0 AS col0 FROM tab1 AS cor0
----
4539
4852
8144

query I rowsort
SELECT - - col2 + + cor0.col0 * + 25 FROM tab1 AS cor0
----
129
1657
2096

query I rowsort
SELECT ALL + - cor0.col1 * col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + 62 FROM tab2, tab0 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 0bc652564a158b9c0f7952026f90b60a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 28 - col0 col0 FROM tab0
----
-61
-7
4

query I rowsort
SELECT 1 * + 22 AS col0 FROM tab0 AS cor0
----
22
22
22

onlyif mysql # use DIV operator for integer division
query I rowsort label-6718
SELECT ALL - col2 + - cor0.col0 * col2 DIV col0 AS col1 FROM tab0 AS cor0
----
-164
-2
-66

skipif mysql # not compatible
query I rowsort label-6718
SELECT ALL - col2 + - cor0.col0 * col2 / col0 AS col1 FROM tab0 AS cor0
----
-164
-2
-66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6719
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col1 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-6719
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col1 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
NULL

query I rowsort
SELECT + ( col1 + 42 ) * + col0 FROM tab1
----
204
3328
4400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 26 col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 4e49eac022daeae6f88f610644ba3754

query I rowsort
SELECT DISTINCT - cor0.col0 + col1 AS col2 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT + col1 + col0 * - cor0.col0 FROM tab1 AS cor0
----
-4086
-6387
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-6724
SELECT + 69 DIV col1 FROM tab1 AS cor0
----
2
5
6

skipif mysql # not compatible
query I rowsort label-6724
SELECT + 69 / col1 FROM tab1 AS cor0
----
2
5
6

query I rowsort
SELECT + + cor0.col0 * 79 + cor0.col2 AS col1 FROM tab1 AS cor0
----
291
5113
6416

query I rowsort
SELECT ALL + 63 AS col0 FROM tab1
----
63
63
63

query I rowsort
SELECT ( + col1 * + tab2.col1 ) FROM tab2
----
289
3481
961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6728
SELECT + col2 * CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6728
SELECT + col2 * CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 18 * + col1 AS col0 FROM tab0 AS cor0
----
-1548
-1638
-1746

query I rowsort
SELECT ALL 19 * cor0.col1 AS col0 FROM tab1 AS cor0
----
190
247
494

query I rowsort
SELECT - + col0 * cor0.col0 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6732
SELECT col1 * col1 / - CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6732
SELECT col1 * col1 / - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6733
SELECT DISTINCT col2 * + col0 + CAST( NULL AS SIGNED ) * 72 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6733
SELECT DISTINCT col2 * + col0 + CAST ( NULL AS INTEGER ) * 72 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL 37 + + 99 * - tab1.col2 * col1 FROM tab1
----
-123515
-138959
-56393

query I rowsort
SELECT DISTINCT + cor1.col0 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
3
64
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6736
SELECT - col2 * + col1 + + col2 * ( - tab2.col0 + + CAST( col0 AS SIGNED ) ) AS col1 FROM tab2
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-6736
SELECT - col2 * + col1 + + col2 * ( - tab2.col0 + + CAST ( col0 AS INTEGER ) ) AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT - + 34 AS col0 FROM tab0 AS cor0
----
-34
-34
-34

query I rowsort
SELECT ALL + cor0.col0 + tab1.col2 AS col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 8217d522e32ec5cc4f9826fb5b492e52

query I rowsort
SELECT DISTINCT - + 35 AS col1 FROM tab0 AS cor0
----
-35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6740
SELECT DISTINCT CAST( - col2 AS SIGNED ) + - col2 * col1 FROM tab0 AS cor0
----
-2871
-7544
-98

skipif mysql # not compatible
query I rowsort label-6740
SELECT DISTINCT CAST ( - col2 AS INTEGER ) + - col2 * col1 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT - col2 * 97 AS col1 FROM tab2 AS cor0
----
-2522
-2619
-3686

query I rowsort
SELECT - + col0 + col0 + col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT col2 + - ( col0 * + col1 ) FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT col2 * 3 - + 34 * + col0 AS col0 FROM tab0
----
-1187
-2780
-717

query I rowsort
SELECT + + ( + 4 ) * - col2 + - ( col2 ) FROM tab2 AS cor0
----
-130
-135
-190

onlyif mysql # use DIV operator for integer division
query I rowsort label-6746
SELECT ALL col2 DIV - col0 + col2 - - col1 FROM tab2 AS cor0
----
55
55
85

skipif mysql # not compatible
query I rowsort label-6746
SELECT ALL col2 / - col0 + col2 - - col1 FROM tab2 AS cor0
----
55
55
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6747
SELECT ALL + CAST( NULL AS SIGNED ) + col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6747
SELECT ALL + CAST ( NULL AS INTEGER ) + col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 46 * + col2 + col1 AS col1 FROM tab2 cor0
----
1255
1273
1765

query I rowsort
SELECT DISTINCT + - col1 + + 69 FROM tab0 AS cor0
----
-17
-22
-28

query I rowsort
SELECT 94 + - cor0.col0 FROM tab0 AS cor0
----
5
59
70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6751
SELECT + CAST( 64 AS SIGNED ) AS col0 FROM tab2 cor0
----
64
64
64

skipif mysql # not compatible
query I rowsort label-6751
SELECT + CAST ( 64 AS INTEGER ) AS col0 FROM tab2 cor0
----
64
64
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-6752
SELECT + - 84 * col1 + + col0 DIV 61 AS col1 FROM tab2 AS cor0
----
-1427
-2604
-4955

skipif mysql # not compatible
query I rowsort label-6752
SELECT + - 84 * col1 + + col0 / 61 AS col1 FROM tab2 AS cor0
----
-1427
-2604
-4955

onlyif mysql # use DIV operator for integer division
query I rowsort label-6753
SELECT - ( col1 ) DIV col2 + + col2 FROM tab0 AS cor0
----
-96
31
81

skipif mysql # not compatible
query I rowsort label-6753
SELECT - ( col1 ) / col2 + + col2 FROM tab0 AS cor0
----
-96
31
81

query I rowsort
SELECT ( + cor0.col0 ) + 90 FROM tab2, tab1 AS cor0
----
9 values hashing to 0e3c74fd4edf7f13800f09c38f957065

query I rowsort
SELECT ALL ( + col2 ) + - col2 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT - col1 * + 55 * col1 FROM tab2
----
-15895
-191455
-52855

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6757
SELECT DISTINCT + CAST( col1 AS SIGNED ) + + col2 * + col2 AS col2 FROM tab0
----
1175
6815
98

skipif mysql # not compatible
query I rowsort label-6757
SELECT DISTINCT + CAST ( col1 AS INTEGER ) + + col2 * + col2 AS col2 FROM tab0
----
1175
6815
98

query I rowsort
SELECT DISTINCT + - col1 * col2 + col2 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT ALL 64 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT - cor1.col1 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

onlyif mysql # use DIV operator for integer division
query I rowsort label-6761
SELECT DISTINCT - + 86 - col2 DIV + col0 FROM tab2 AS cor0
----
-86
-89

skipif mysql # not compatible
query I rowsort label-6761
SELECT DISTINCT - + 86 - col2 / + col0 FROM tab2 AS cor0
----
-86
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 * + col2 col0 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT - - ( - col0 ) + - 99 FROM tab0 cor0
----
-123
-134
-188

query I rowsort
SELECT ALL - - col1 * - col0 + - col2 + - 13 * col2 AS col2 FROM tab1 AS cor0
----
-1438
-2384
-834

query I rowsort
SELECT ALL + 82 * + col1 AS col2 FROM tab1 AS cor0
----
1066
2132
820

query I rowsort
SELECT DISTINCT + + ( + cor0.col1 ) + col0 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT DISTINCT col2 * col1 * + col0 + + 5 * col1 + 2 AS col1 FROM tab2 AS cor0
----
119949
51121
6016

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 87 + col2 col0 FROM tab0 cor0
----
120
169
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 + + col2 col0 FROM tab1
----
109
67
80

query I rowsort
SELECT + 58 * + col2 - - col2 AS col1 FROM tab1
----
3186
3363
5664

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 44 + 62 col2 FROM tab2
----
106
106
106

query I rowsort
SELECT DISTINCT - col0 + 25 AS col2 FROM tab0
----
-10
-64
1

query I rowsort
SELECT DISTINCT + col0 * - 44 + + col2 FROM tab0
----
-1023
-1539
-3834

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 77 * + col2 col1 FROM tab2 cor0
----
2002
2079
2926

query I rowsort
SELECT ALL cor0.col1 * col0 + col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT DISTINCT + col0 + - col2 - - col1 FROM tab2 AS cor0
----
11
111
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 + col1 col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6778
SELECT ALL - + col2 * - CAST( NULL AS DECIMAL ) * - col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6778
SELECT ALL - + col2 * - CAST ( NULL AS REAL ) * - col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * ( - 4 ) + - col1 FROM tab2 AS cor0
----
-139
-163
-169

query I rowsort
SELECT cor0.col0 * - col1 + - col1 * col2 FROM tab1 AS cor0
----
-1210
-1482
-2288

query I rowsort
SELECT + - col0 * - col0 + col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT + + col1 + col2 + col1 FROM tab0 AS cor0
----
195
205
264

query I rowsort
SELECT col0 - col1 * + col1 * col0 FROM tab0 AS cor0
----
-177480
-329280
-736920

query I rowsort
SELECT DISTINCT - + col2 + + col0 * col0 AS col1 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT ALL + + col1 + - 84 * cor0.col0 AS col0 FROM tab0 cor0
----
-1930
-2843
-7385

query I rowsort
SELECT + col1 * + 41 - col1 FROM tab1 AS cor0
----
1040
400
520

query I rowsort
SELECT DISTINCT - - col1 * - 5 AS col1 FROM tab1 AS cor0
----
-130
-50
-65

query I rowsort
SELECT ALL - + col1 * - ( col0 ) * col1 AS col2 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT + col1 * + ( - 73 ) - + col0 AS col0 FROM tab1 AS cor0
----
-1029
-1901
-794

onlyif mysql # use DIV operator for integer division
query I rowsort label-6790
SELECT ALL - + col2 DIV - col0 AS col2 FROM tab0 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6790
SELECT ALL - + col2 / - col0 AS col2 FROM tab0 cor0
----
0
0
1

query I rowsort
SELECT - cor0.col1 * 68 - + col1 FROM tab1 AS cor0
----
-1794
-690
-897

query I rowsort
SELECT + 1 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to da8a72a7967c0c73d91239275230aed9

query I rowsort
SELECT + - col0 * - col0 + col0 AS col2 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT ALL cor0.col1 * ( col0 ) AS col2 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - - ( col0 ) * + col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL - col2 * col0 * - col0 - + col0 AS col1 FROM tab1
----
233408
483
614320

query I rowsort
SELECT - col0 - 78 FROM tab2
----
-156
-157
-85

query I rowsort
SELECT + 86 + cor0.col1 * - 67 AS col2 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 5db9f6827a5219196084b1f42858ba56

query I rowsort
SELECT ALL 3 AS col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 3e22859a313d85a6146c6df5f23d77cf

query I rowsort
SELECT DISTINCT + col0 * + col0 + 86 AS col1 FROM tab2 AS cor0
----
135
6170
6327

skipif mysql # not compatible
query I rowsort
SELECT ALL + 38 + col0 + - CAST ( + 59 AS REAL ) * col1 AS col2 FROM tab0 AS cor0
----
-5012
-5242
-5650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 + col0 col1 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6803
SELECT ALL - 80 * col0 DIV 78 - - col0 * col0 * - ( cor0.col2 * col1 ) FROM tab2 cor0
----
-4031767
-41020
-9332936

skipif mysql # not compatible
query I rowsort label-6803
SELECT ALL - 80 * col0 / 78 - - col0 * col0 * - ( cor0.col2 * col1 ) FROM tab2 cor0
----
-4031767
-41020
-9332936

query I rowsort
SELECT col0 - + ( + 39 ) * col2 AS col0 FROM tab1 AS cor0
----
-2103
-2159
-3664

onlyif mysql # use DIV operator for integer division
query I rowsort label-6805
SELECT + col0 + - col2 DIV 46 AS col1 FROM tab0 AS cor0
----
24
35
88

skipif mysql # not compatible
query I rowsort label-6805
SELECT + col0 + - col2 / 46 AS col1 FROM tab0 AS cor0
----
24
35
88

query I rowsort
SELECT col0 * col0 - - col2 AS col1 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT - + col1 * + col0 * + col2 - col0 AS col2 FROM tab2 AS cor0
----
-119730
-51113
-5866

onlyif mysql # use DIV operator for integer division
query I rowsort label-6808
SELECT col1 * ( - 56 ) DIV - cor0.col2 FROM tab0 AS cor0
----
145
5432
62

skipif mysql # not compatible
query I rowsort label-6808
SELECT col1 * ( - 56 ) / - cor0.col2 FROM tab0 AS cor0
----
145
5432
62

skipif mysql # not compatible
query I rowsort
SELECT col2 / - tab0.col1 + - CAST ( + 93 AS REAL ) FROM tab0
----
-93
-93
-93

query I rowsort
SELECT ALL - col0 + col2 * - col0 FROM tab2 AS cor0
----
-196
-2106
-3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-6811
SELECT DISTINCT + col0 DIV 87 - - col1 AS col0 FROM tab0 AS cor0
----
86
92
97

skipif mysql # not compatible
query I rowsort label-6811
SELECT DISTINCT + col0 / 87 - - col1 AS col0 FROM tab0 AS cor0
----
86
92
97

query I rowsort
SELECT DISTINCT col2 + col0 * - col0 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT DISTINCT + + ( col2 ) AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - col1 * - 80 AS col0 FROM tab1 cor0
----
1040
2080
800

query I rowsort
SELECT ALL 93 * col1 AS col2 FROM tab2 AS cor0
----
1581
2883
5487

onlyif mysql # use DIV operator for integer division
query I rowsort label-6816
SELECT + - col2 DIV 5 FROM tab2 AS cor0
----
-5
-5
-7

skipif mysql # not compatible
query I rowsort label-6816
SELECT + - col2 / 5 FROM tab2 AS cor0
----
-5
-5
-7

query I rowsort
SELECT ALL + + cor0.col2 * - col2 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-6818
SELECT DISTINCT - 96 + 20 DIV - col1 FROM tab0 AS cor0
----
-96

skipif mysql # not compatible
query I rowsort label-6818
SELECT DISTINCT - 96 + 20 / - col1 FROM tab0 AS cor0
----
-96

query I rowsort
SELECT ALL - col2 + + 37 + - col2 FROM tab0 AS cor0
----
-127
-29
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6820
SELECT DISTINCT - - CAST( + col1 AS SIGNED ) * - cor0.col0 - + 51 FROM tab0 cor0
----
-2115
-3446
-8150

skipif mysql # not compatible
query I rowsort label-6820
SELECT DISTINCT - - CAST ( + col1 AS INTEGER ) * - cor0.col0 - + 51 FROM tab0 cor0
----
-2115
-3446
-8150

query I rowsort
SELECT DISTINCT ( ( - cor0.col1 ) ) * + col1 AS col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT col2 + cor0.col0 * - col0 AS col2 FROM tab2 AS cor0
----
-22
-6058
-6203

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6823
SELECT + + CAST( col2 AS SIGNED ) * + col0 FROM tab1 cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-6823
SELECT + + CAST ( col2 AS INTEGER ) * + col0 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT + tab0.col1 + + col0 AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT + 78 * + col1 FROM tab2 AS cor0
----
1326
2418
4602

query I rowsort
SELECT 28 * - cor0.col2 * col2 AS col0 FROM tab0 AS cor0
----
-188272
-28
-30492

query I rowsort
SELECT DISTINCT 23 FROM tab0, tab1 AS cor0 CROSS JOIN tab1
----
23

query I rowsort
SELECT ALL 39 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

onlyif mysql # use DIV operator for integer division
query I rowsort label-6829
SELECT - col0 * + col2 + + col2 DIV - col0 col0 FROM tab2 AS cor0
----
-192
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6829
SELECT - col0 * + col2 + + col2 / - col0 col0 FROM tab2 AS cor0
----
-192
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6830
SELECT + col1 * + col2 + - CAST( - cor0.col1 AS SIGNED ) * col2 FROM tab1 cor0
----
1140
2496
2808

skipif mysql # not compatible
query I rowsort label-6830
SELECT + col1 * + col2 + - CAST ( - cor0.col1 AS INTEGER ) * col2 FROM tab1 cor0
----
1140
2496
2808

query I rowsort
SELECT - ( cor0.col1 ) * col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6832
SELECT ALL CAST( col1 AS SIGNED ) DIV + col1 AS col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6832
SELECT ALL CAST ( col1 AS INTEGER ) / + col1 AS col2 FROM tab1
----
1
1
1

query I rowsort
SELECT 20 + col0 FROM tab1
----
100
23
84

query I rowsort
SELECT DISTINCT - col0 + + ( 23 ) * col0 AS col1 FROM tab1 AS cor0
----
1408
1760
66

query I rowsort
SELECT + cor0.col2 * col0 - + col1 FROM tab0 cor0
----
-62
706
7207

query I rowsort
SELECT cor1.col1 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + 13 * col1 col1 FROM tab1 AS cor0
----
120
156
312

query I rowsort
SELECT ALL - ( + 98 * - col1 + tab0.col0 ) AS col0 FROM tab0
----
8404
8829
9471

query I rowsort
SELECT ALL - 3 FROM tab1
----
-3
-3
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + 32 col2 FROM tab1 cor0
----
19
22
6

query I rowsort
SELECT ALL - col1 * - 73 FROM tab2 AS cor0
----
1241
2263
4307

query I rowsort
SELECT DISTINCT + col2 * + 14 FROM tab0 AS cor0
----
1148
14
462

onlyif mysql # use DIV operator for integer division
query I rowsort label-6843
SELECT + col0 + - 15 DIV + col2 FROM tab0 AS cor0
----
20
24
89

skipif mysql # not compatible
query I rowsort label-6843
SELECT + col0 + - 15 / + col2 FROM tab0 AS cor0
----
20
24
89

query I rowsort
SELECT ALL - cor0.col2 * 96 + cor0.col0 AS col0 FROM tab0 AS cor0
----
-3144
-61
-7783

query I rowsort
SELECT - - col1 + + col1 * cor0.col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT ALL + cor0.col2 * + col2 - col2 AS col2 FROM tab1 AS cor0
----
2862
3192
9120

query I rowsort
SELECT ALL + - col2 + ( 6 ) * col0 * - col1 AS col2 FROM tab2 AS cor0
----
-1329
-27638
-8096

query I rowsort
SELECT + col2 * + col2 + col2 AS col2 FROM tab0 cor0
----
1122
2
6806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6849
SELECT - col2 * CAST( - ( - col2 ) AS SIGNED ) + 86 FROM tab2 AS cor0
----
-1358
-590
-643

skipif mysql # not compatible
query I rowsort label-6849
SELECT - col2 * CAST ( - ( - col2 ) AS INTEGER ) + 86 FROM tab2 AS cor0
----
-1358
-590
-643

query I rowsort
SELECT DISTINCT - + ( col1 ) + col1 AS col2 FROM tab0 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6851
SELECT ALL - CAST( + col2 AS SIGNED ) + cor0.col0 FROM tab2 AS cor0
----
-20
41
52

skipif mysql # not compatible
query I rowsort label-6851
SELECT ALL - CAST ( + col2 AS INTEGER ) + cor0.col0 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6852
SELECT - - CAST( + 8 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
8
8
8

skipif mysql # not compatible
query I rowsort label-6852
SELECT - - CAST ( + 8 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
8
8
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * 56 + cor0.col1 * - 76 col2 FROM tab0 AS cor0
----
-11900
-7880
-9332

query I rowsort
SELECT ALL 47 * cor0.col0 - + col0 * - 38 * - 46 FROM tab1 AS cor0
----
-108864
-136080
-5103

onlyif mysql # use DIV operator for integer division
query I rowsort label-6855
SELECT DISTINCT - cor0.col0 * - col0 + - col1 DIV cor0.col2 + + col2 AS col0 FROM tab0 AS cor0
----
1129
607
8002

skipif mysql # not compatible
query I rowsort label-6855
SELECT DISTINCT - cor0.col0 * - col0 + - col1 / cor0.col2 + + col2 AS col0 FROM tab0 AS cor0
----
1129
607
8002

query I rowsort
SELECT DISTINCT - cor0.col1 + + col1 * col2 * col0 FROM tab2 AS cor0
----
119593
51017
5828

query I rowsort
SELECT 44 * col1 * col2 FROM tab0 AS cor0
----
124872
328328
4268

query I rowsort
SELECT ALL + col0 + + 73 FROM tab2 AS cor0
----
151
152
80

query I rowsort
SELECT - 45 AS col1 FROM tab1 cor0
----
-45
-45
-45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + col1 + - 43 col2 FROM tab2
----
246
3438
918

onlyif mysql # use DIV operator for integer division
query I rowsort label-6861
SELECT ALL + - ( - col2 ) + + col0 DIV col0 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-6861
SELECT ALL + - ( - col2 ) + + col0 / col0 FROM tab2 AS cor0
----
27
28
39

query I rowsort
SELECT DISTINCT cor0.col1 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
10
13
26

query I rowsort
SELECT + + 2 AS col1 FROM tab1 AS cor0
----
2
2
2

query I rowsort
SELECT + cor1.col0 AS col1 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ALL - col0 - col0 AS col0 FROM tab0
----
-178
-48
-70

query I rowsort
SELECT + - col0 + 7 FROM tab2 AS cor0
----
-71
-72
0

query I rowsort
SELECT ALL + + col2 * col0 AS col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL 75 + col2 FROM tab0
----
108
157
76

query I rowsort
SELECT DISTINCT - 41 * + col0 + ( col2 ) * - col2 + + 4 FROM tab1
----
-12492
-3035
-5869

query I rowsort
SELECT - ( col0 ) * ( + 58 ) + + col1 + col0 FROM tab2
----
-368
-4387
-4486

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col1 * + ( cor0.col1 ) + - col1 * col1 + - 49 col2 FROM tab0 AS cor0
----
-18867
-251513
-687372

query I rowsort
SELECT DISTINCT - tab2.col0 + + col0 AS col2 FROM tab2
----
0

query I rowsort
SELECT ALL 59 * + col0 + - col0 FROM tab2
----
406
4524
4582

query I rowsort
SELECT 71 + col2 FROM tab1
----
125
128
167

query I rowsort
SELECT ALL col1 * + col1 + 23 FROM tab1 AS cor0
----
123
192
699

query I rowsort
SELECT + - col0 * - ( col1 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL col2 * - col2 + col2 * col2 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT - 93 * col1 FROM tab1
----
-1209
-2418
-930

query I rowsort
SELECT col2 * - ( + 77 ) * - tab2.col0 + - col0 AS col0 FROM tab2
----
14546
156078
231075

query I rowsort
SELECT col1 * + ( col2 ) AS col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT col0 * - ( - 10 ) + - col2 FROM tab0
----
207
349
808

query I rowsort
SELECT + col1 + 57 AS col1 FROM tab1
----
67
70
83

query I rowsort
SELECT DISTINCT + col0 * ( + col1 ) + + col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL - + col2 + + ( - col1 ) FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT - 96 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to c89b545346f99713888a7934e4caa539

query I rowsort
SELECT ALL 89 * cor1.col1 AS col1 FROM tab2, tab1 AS cor0, tab1 cor1
----
27 values hashing to a16eced4b3f016c55b5389ad8394fd88

query I rowsort
SELECT + + col0 * col0 + col1 - cor0.col1 FROM tab1 cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6888
SELECT ALL ( - col0 ) DIV col2 AS col2 FROM tab1
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6888
SELECT ALL ( - col0 ) / col2 AS col2 FROM tab1
----
-1
0
0

query I rowsort
SELECT ALL + 44 + - cor0.col2 FROM tab1, tab1 AS cor0
----
9 values hashing to d084a5ec9dc4018693cf51edfec3ad99

query I rowsort
SELECT - ( col1 ) + - col1 AS col0 FROM tab0
----
-172
-182
-194

onlyif mysql # use DIV operator for integer division
query I rowsort label-6891
SELECT + col1 * col2 + col1 DIV col1 FROM tab2
----
1535
647
838

skipif mysql # not compatible
query I rowsort label-6891
SELECT + col1 * col2 + col1 / col1 FROM tab2
----
1535
647
838

query I rowsort
SELECT ALL col1 * - col1 + col0 AS col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT ALL - - ( + ( - col1 ) ) AS col0 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT + 91 + col2 FROM tab0 AS cor0
----
124
173
92

query I rowsort
SELECT + 74 * 40 FROM tab2 AS cor0
----
2960
2960
2960

query I rowsort
SELECT ALL ( + 33 ) FROM tab0
----
33
33
33

query I rowsort
SELECT DISTINCT 38 * - col1 AS col1 FROM tab1 AS cor0
----
-380
-494
-988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col2 * - col2 + - col1 * cor0.col2 col1 FROM tab1 AS cor0
----
-10464
-3819
-4320

query I rowsort
SELECT - cor0.col1 * col0 + col0 * - cor0.col0 - col2 FROM tab1 cor0
----
-141
-4793
-7536

query I rowsort
SELECT - col0 + col1 * + ( 52 ) * col2 FROM tab0 AS cor0
----
147552
387935
5009

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 86 + col2 col2 FROM tab1 AS cor0
----
140
143
182

query I rowsort
SELECT ALL - 73 * - col1 + + 8 FROM tab1 AS cor0
----
1906
738
957

query I rowsort
SELECT DISTINCT + - 85 + col0 + 49 AS col0 FROM tab0 AS cor0
----
-1
-12
53

query I rowsort
SELECT DISTINCT - col1 * + col2 + - ( 71 ) * - col1 AS col1 FROM tab1 AS cor0
----
-325
140
442

query I rowsort
SELECT - + 89 AS col1 FROM tab0 cor0
----
-89
-89
-89

query I rowsort
SELECT + + 52 * cor0.col0 + 14 FROM tab0 AS cor0
----
1262
1834
4642

query I rowsort
SELECT ALL 45 + - col0 + - 32 * + col2 FROM tab1 AS cor0
----
-1686
-1843
-3107

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL IN ( col1 / - col2 ) AND NOT ( NULL ) NOT BETWEEN NULL AND col1
----

query I rowsort
SELECT col0 * + col0 * col1 + + col0 FROM tab0
----
118860
49560
720900

query I rowsort
SELECT - - col2 * + col2 AS col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT tab1.col2 + + tab1.col1 * col0 * col2 AS col1 FROM tab1
----
36537
4266
99936

query I rowsort
SELECT + col0 * + col0 * col2 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT - - col0 * col2 + cor0.col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT cor0.col2 + cor0.col2 AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT + col1 * + col2 + col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT + cor0.col1 + col0 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL - + col1 * + col1 + col2 FROM tab0 cor0
----
-7363
-8199
-9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + col1 col1 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT - 23 FROM tab2
----
-23
-23
-23

query I rowsort
SELECT - + 5 * - col1 FROM tab2 cor0
----
155
295
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6921
SELECT ALL + 64 DIV col0 - + col1 FROM tab0 AS cor0
----
-84
-91
-96

skipif mysql # not compatible
query I rowsort label-6921
SELECT ALL + 64 / col0 - + col1 FROM tab0 AS cor0
----
-84
-91
-96

query I rowsort
SELECT DISTINCT + 55 * + col0 FROM tab1 cor0
----
165
3520
4400

query I rowsort
SELECT col2 * + col0 + + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT + ( + col2 ) * col1 AS col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT + + col2 + + col1 + - cor0.col1 FROM tab1 cor0
----
54
57
96

query I rowsort
SELECT col0 - col0 * col0 FROM tab1 cor0
----
-4032
-6
-6320

query I rowsort
SELECT ALL + col0 * - col1 + col1 * col2 + col0 FROM tab0 AS cor0
----
-3263
-548
798

query I rowsort
SELECT - col2 * col0 + col1 + col0 * + col0 AS col0 FROM tab1 cor0
----
-1267
-127
458

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + col2 col2 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT ALL - - cor0.col0 * + col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - + col1 * - col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab1.col2 * - col1 + + col2 col2 FROM tab1
----
-1152
-1350
-513

query III rowsort
SELECT * FROM tab1 WHERE NOT ( ( NULL ) NOT IN ( tab1.col2 ) ) AND NOT ( NULL ) < ( + col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6934
SELECT ALL + col0 + col2 DIV tab2.col0 + tab2.col1 AS col0 FROM tab2
----
137
41
96

skipif mysql # not compatible
query I rowsort label-6934
SELECT ALL + col0 + col2 / tab2.col0 + tab2.col1 AS col0 FROM tab2
----
137
41
96

query III rowsort
SELECT ALL * FROM tab0 WHERE + col1 * col0 + col2 >= NULL
----

query III rowsort
SELECT * FROM tab0 WHERE NULL NOT IN ( + col1 )
----

query I rowsort
SELECT col2 * col2 * + col0 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT DISTINCT - col2 * col0 + col0 + col2 AS col1 FROM tab2
----
-155
-1924
-2885

query I rowsort
SELECT + tab2.col2 + col0 + tab2.col0 AS col1 FROM tab2
----
182
196
41

query I rowsort
SELECT DISTINCT + col0 * tab2.col1 + col1 * + col1 * - col1 + + col1 FROM tab2
----
-200718
-29543
-3553

onlyif mysql # use DIV operator for integer division
query I rowsort label-6941
SELECT - tab2.col0 DIV + col0 AS col0 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6941
SELECT - tab2.col0 / + col0 AS col0 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT - col0 + col0 * col2 AS col2 FROM tab1
----
159
3584
7600

query I rowsort
SELECT ALL + col0 * + col0 * - col0 FROM tab0
----
-13824
-42875
-704969

query I rowsort
SELECT col0 - tab1.col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT - col2 + col0 - + col1 FROM tab0
----
-63
-84
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + col2 + col2 col1 FROM tab2
----
-1508
-608
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-6947
SELECT - 8 + cor0.col1 DIV col2 AS col2 FROM tab1 AS cor0
----
-8
-8
-8

skipif mysql # not compatible
query I rowsort label-6947
SELECT - 8 + cor0.col1 / col2 AS col2 FROM tab1 AS cor0
----
-8
-8
-8

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE col0 * col0 * col0 IN ( - cor0.col2 )
----

query I rowsort
SELECT ALL tab1.col0 AS col0 FROM tab2 AS cor0 CROSS JOIN tab1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT tab1.col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6951
SELECT - col0 DIV + col1 + col2 * col0 FROM tab1
----
162
3642
7674

skipif mysql # not compatible
query I rowsort label-6951
SELECT - col0 / + col1 + col2 * col0 FROM tab1
----
162
3642
7674

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col0 col0 FROM tab2
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-6953
SELECT DISTINCT col0 DIV - col0 + - col0 DIV - col1 AS col1 FROM tab1
----
-1
5

skipif mysql # not compatible
query I rowsort label-6953
SELECT DISTINCT col0 / - col0 + - col0 / - col1 AS col1 FROM tab1
----
-1
5

query I rowsort
SELECT DISTINCT + col2 + col0 AS col1 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL - col0 + col0 * col0 AS col0 FROM tab1
----
4032
6
6320

query I rowsort
SELECT + col2 * col1 * - col0 - + cor0.col1 AS col1 FROM tab1 cor0
----
-36490
-4238
-99853

query I rowsort
SELECT ALL col1 + - col1 * + col2 * col2 FROM tab1
----
-119795
-32480
-75790

query I rowsort
SELECT col0 + + col2 + col0 AS col1 FROM tab2 AS cor0
----
182
196
41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6959
SELECT DISTINCT - CAST( NULL AS SIGNED ) AS col0 FROM tab1, tab2 cor0 CROSS JOIN tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-6959
SELECT DISTINCT - CAST ( NULL AS INTEGER ) AS col0 FROM tab1, tab2 cor0 CROSS JOIN tab2
----
NULL

query I rowsort
SELECT col0 * + tab1.col1 + - col0 + col2 * + col1 FROM tab1
----
1146
1479
2208

query I rowsort
SELECT ALL + col1 - + col2 AS col0 FROM tab0
----
53
9
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6962
SELECT DISTINCT + - CAST( NULL AS SIGNED ) * - col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6962
SELECT DISTINCT + - CAST ( NULL AS INTEGER ) * - col1 FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6963
SELECT CAST( NULL AS DECIMAL ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6963
SELECT CAST ( NULL AS REAL ) AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( - 71 ) + col0 FROM tab0 AS cor0
----
-36
-47
18

query I rowsort
SELECT ALL - 72 * + col0 + col1 FROM tab2 AS cor0
----
-473
-5557
-5671

query I rowsort
SELECT DISTINCT 87 + col1 AS col0 FROM tab0 cor0
----
173
178
184

query I rowsort
SELECT DISTINCT + col0 + col1 * cor0.col0 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT + col1 + + col0 AS col2 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT ALL 58 + col2 * + 54 FROM tab0 AS cor0
----
112
1840
4486

query I rowsort
SELECT DISTINCT + 55 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
55

query I rowsort
SELECT 99 AS col1 FROM tab0 AS cor0
----
99
99
99

query I rowsort
SELECT col2 * + col2 + + col2 FROM tab0 AS cor0
----
1122
2
6806

query I rowsort
SELECT DISTINCT + - ( col1 ) + - col1 * + col0 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT DISTINCT - - ( + cor0.col2 ) + - cor0.col2 FROM tab2 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6975
SELECT - CAST( NULL AS SIGNED ) FROM tab1, tab0 cor0 CROSS JOIN tab2
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6975
SELECT - CAST ( NULL AS INTEGER ) FROM tab1, tab0 cor0 CROSS JOIN tab2
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT 44 + 11 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

query I rowsort
SELECT ALL - + 57 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
-1482
-570
-741

query I rowsort
SELECT ALL col2 * 56 AS col1 FROM tab0
----
1848
4592
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * ( cor0.col1 + + col1 ) col0 FROM tab1 AS cor0
----
1140
2496
2808

onlyif mysql # use DIV operator for integer division
query I rowsort label-6980
SELECT + - col0 DIV - cor0.col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-6980
SELECT + - col0 / - cor0.col2 FROM tab0 AS cor0
----
0
1
35

query I rowsort
SELECT DISTINCT + col2 - + 6 FROM tab0 AS cor0
----
-5
27
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6982
SELECT DISTINCT + CAST( 19 AS SIGNED ) * col2 FROM tab1 AS cor0
----
1026
1083
1824

skipif mysql # not compatible
query I rowsort label-6982
SELECT DISTINCT + CAST ( 19 AS INTEGER ) * col2 FROM tab1 AS cor0
----
1026
1083
1824

query I rowsort
SELECT ALL - ( - col2 ) * col0 + - 81 FROM tab2 AS cor0
----
108
1947
2921

query I rowsort
SELECT ALL - ( col1 ) + col0 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT + + ( 44 ) - - col0 FROM tab0 AS cor0
----
133
68
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6986
SELECT tab2.col2 DIV + col1 AS col1 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-6986
SELECT tab2.col2 / + col1 AS col1 FROM tab2
----
0
0
2

query I rowsort
SELECT DISTINCT + 91 * 8 AS col0 FROM tab1 AS cor0
----
728

onlyif mysql # use DIV operator for integer division
query I rowsort label-6988
SELECT ALL + 93 DIV + col0 AS col2 FROM tab2 AS cor0
----
1
1
13

skipif mysql # not compatible
query I rowsort label-6988
SELECT ALL + 93 / + col0 AS col2 FROM tab2 AS cor0
----
1
1
13

query I rowsort
SELECT 73 * col2 AS col2 FROM tab0 cor0
----
2409
5986
73

query I rowsort
SELECT DISTINCT + + cor0.col1 * + col2 AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + - 56 + col0 FROM tab1 AS cor0
----
-53
24
8

query I rowsort
SELECT ALL col0 + - cor0.col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT + 50 FROM tab0, tab0 cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT - col0 * - ( + ( col1 ) ) FROM tab2
----
1343
217
4602

query I rowsort
SELECT - 81 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to d0bfe8494f52235d9fcafb5ac5de3f81

query I rowsort
SELECT ( - cor0.col0 ) * + col1 * col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT 32 * col2 AS col1 FROM tab2 AS cor0
----
1216
832
864

onlyif mysql # use DIV operator for integer division
query I rowsort label-6998
SELECT DISTINCT + + col0 - + col2 DIV col2 AS col1 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-6998
SELECT DISTINCT + + col0 - + col2 / col2 AS col1 FROM tab0 AS cor0
----
23
34
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6999
SELECT ALL - + CAST( + col2 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-6999
SELECT ALL - + CAST ( + col2 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT cor0.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
54
57
96

query I rowsort
SELECT - tab1.col0 * col0 - 99 AS col0 FROM tab1
----
-108
-4195
-6499

query I rowsort
SELECT ALL + col0 * - ( col1 ) FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - - 72 * 92 FROM tab1 AS cor0
----
6624

query I rowsort
SELECT - ( col1 ) + col1 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
156
650
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( cor0.col2 ) col2 FROM tab1, tab0 cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL col1 - tab1.col2 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT DISTINCT col0 * - ( - tab2.col0 ) + + col0 FROM tab2
----
56
6162
6320

query I rowsort
SELECT col1 * + col2 + col0 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-7009
SELECT DISTINCT 54 + + col0 DIV + col1 FROM tab0
----
54

skipif mysql # not compatible
query I rowsort label-7009
SELECT DISTINCT 54 + + col0 / + col1 FROM tab0
----
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-7010
SELECT DISTINCT + CAST( col0 AS SIGNED ) DIV - col1 + col1 * col0 + col2 col1 FROM tab0
----
2097
3396
8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7010
SELECT DISTINCT + CAST ( col0 AS INTEGER ) / - col1 + col1 * col0 + col2 col1 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT 61 + col2 * col1 + col1 * col0 AS col1 FROM tab1
----
1271
1543
2349

query I rowsort
SELECT ALL ( 76 ) + - col2 AS col1 FROM tab2 AS cor0
----
38
49
50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7013
SELECT + CAST( col2 AS SIGNED ) * + col2 FROM tab1
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-7013
SELECT + CAST ( col2 AS INTEGER ) * + col2 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT - col2 * - col2 * - col2 FROM tab1
----
-157464
-185193
-884736

query I rowsort
SELECT ALL 36 * + 99 + col2 * col1 AS col0 FROM tab0
----
11026
3661
6402

query I rowsort
SELECT - col2 * + ( cor0.col0 ) AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT tab0.col0 * + col2 * + col1 - - col2 FROM tab0
----
3396
664200
68145

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7018
SELECT ALL - col2 + CAST( - col1 AS SIGNED ) + - col1 FROM tab1 AS cor0
----
-106
-122
-77

skipif mysql # not compatible
query I rowsort label-7018
SELECT ALL - col2 + CAST ( - col1 AS INTEGER ) + - col1 FROM tab1 AS cor0
----
-106
-122
-77

query I rowsort
SELECT DISTINCT - - col0 * + 25 AS col0 FROM tab1 AS cor0
----
1600
2000
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7020
SELECT DISTINCT cor0.col1 + - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7020
SELECT DISTINCT cor0.col1 + - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - 25 + col2 FROM tab2
----
1
13
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-7022
SELECT col2 * col0 + CAST( col0 AS SIGNED ) DIV + col0 FROM tab1
----
163
3649
7681

skipif mysql # not compatible
query I rowsort label-7022
SELECT col2 * col0 + CAST ( col0 AS INTEGER ) / + col0 FROM tab1
----
163
3649
7681

query I rowsort
SELECT ALL + col0 + - col0 * + tab0.col1 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT + col0 * col1 + col0 FROM tab1
----
1120
704
81

query I rowsort
SELECT DISTINCT col0 + + col2 * 24 AS col1 FROM tab0
----
2057
59
816

query I rowsort
SELECT col2 * col2 * + col1 - tab1.col1 FROM tab1
----
119795
32480
75790

query I rowsort
SELECT 22 AS col1 FROM tab1
----
22
22
22

onlyif mysql # use DIV operator for integer division
query I rowsort label-7028
SELECT ALL - cor0.col1 DIV 84 + col0 AS col2 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-7028
SELECT ALL - cor0.col1 / 84 + col0 AS col2 FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7029
SELECT ALL + col2 * CAST( NULL AS SIGNED ) + - col0 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7029
SELECT ALL + col2 * CAST ( NULL AS INTEGER ) + - col0 AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * - 42 AS col1 FROM tab0 AS cor0
----
-1386
-3444
-42

query I rowsort
SELECT col2 * 26 AS col2 FROM tab1 AS cor0
----
1404
1482
2496

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7032
SELECT + cor0.col0 * CAST( + col2 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-7032
SELECT + cor0.col0 * CAST ( + col2 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL col0 + 38 * - ( - col1 ) * - col0 + - col1 FROM tab2 AS cor0
----
-174857
-50972
-8270

query I rowsort
SELECT - col1 * col1 + col2 * + col2 AS col2 FROM tab2 AS cor0
----
-232
-2805
1155

onlyif mysql # use DIV operator for integer division
query I rowsort label-7035
SELECT + + cor0.col1 DIV col1 AS col2 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7035
SELECT + + cor0.col1 / col1 AS col2 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT ALL ( + col2 ) * - ( tab1.col1 * col0 ) FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT + col1 + col2 * 97 AS col1 FROM tab2 AS cor0
----
2581
2650
3703

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7038
SELECT ALL + CAST( NULL AS DECIMAL ) FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-7038
SELECT ALL + CAST ( NULL AS REAL ) FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 col1 FROM tab1, tab2 AS cor0
----
26
27
38

query I rowsort
SELECT 57 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT DISTINCT col1 * 97 FROM tab1
----
1261
2522
970

query I rowsort
SELECT col2 * 9 AS col1 FROM tab1
----
486
513
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7043
SELECT ALL + col0 * + CAST( col0 AS SIGNED ) FROM tab2
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-7043
SELECT ALL + col0 * + CAST ( col0 AS INTEGER ) FROM tab2
----
49
6084
6241

query I rowsort
SELECT ALL - tab1.col0 * col0 + col1 FROM tab1
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT col0 + 21 FROM tab2
----
100
28
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-7046
SELECT + 10 * - cor0.col1 DIV + col1 + cor0.col0 * col0 FROM tab2 AS cor0
----
39
6074
6231

skipif mysql # not compatible
query I rowsort label-7046
SELECT + 10 * - cor0.col1 / + col1 + cor0.col0 * col0 FROM tab2 AS cor0
----
39
6074
6231

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 39 col1 FROM tab0 AS cor0
----
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-7048
SELECT DISTINCT - ( tab2.col2 + - col2 ) DIV col1 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-7048
SELECT DISTINCT - ( tab2.col2 + - col2 ) / col1 FROM tab2
----
0

query I rowsort
SELECT 20 AS col0 FROM tab0
----
20
20
20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7050
SELECT col2 * - col2 / CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7050
SELECT col2 * - col2 / CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 26 AS col1 FROM tab0 cor0
----
26
26
26

query I rowsort
SELECT DISTINCT 38 * - col2 * ( ( + col1 ) ) AS col0 FROM tab2 cor0
----
-24548
-31806
-58292

query I rowsort
SELECT + + 2 FROM tab2 cor0
----
2
2
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-7054
SELECT + col1 DIV col0 + col0 * col2 - col0 * ( col1 * + col1 + col1 ) col1 FROM tab1 AS cor0
----
-1936
-3392
-6880

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7054
SELECT + col1 / col0 + col0 * col2 - col0 * ( col1 * + col1 + col1 ) col1 FROM tab1 AS cor0
----
-1936
-3392
-6880

query I rowsort
SELECT - col2 - + col0 AS col0 FROM tab2 cor0
----
-104
-117
-34

query I rowsort
SELECT ALL + 93 * + col1 FROM tab0 AS cor0
----
7998
8463
9021

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 44 + col0 col0 FROM tab2 AS cor0
----
-37
34
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-7058
SELECT + - col1 + - col1 DIV 46 AS col1 FROM tab2 AS cor0
----
-17
-31
-60

skipif mysql # not compatible
query I rowsort label-7058
SELECT + - col1 + - col1 / 46 AS col1 FROM tab2 AS cor0
----
-17
-31
-60

query I rowsort
SELECT - col0 * - col2 + + 90 - - col2 AS col2 FROM tab1 AS cor0
----
306
3795
7866

onlyif mysql # use DIV operator for integer division
query I rowsort label-7060
SELECT ( col2 ) DIV + 13 FROM tab1
----
4
4
7

skipif mysql # not compatible
query I rowsort label-7060
SELECT ( col2 ) / + 13 FROM tab1
----
4
4
7

query I rowsort
SELECT ALL + col1 * - col0 AS col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL 75 AS col2 FROM tab2, tab0, tab1 cor0
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

onlyif mysql # use DIV operator for integer division
query I rowsort label-7063
SELECT tab1.col0 DIV col0 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7063
SELECT tab1.col0 / col0 AS col1 FROM tab1
----
1
1
1

query I rowsort
SELECT DISTINCT - 17 AS col0 FROM tab2, tab2 AS cor0, tab0 cor1
----
-17

query I rowsort
SELECT ALL - tab0.col2 * - 99 + + cor0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to af43fa8ae9fb14bdac1499e219ce9191

query I rowsort
SELECT - col0 * + 39 * ( + col1 ) + + 18 FROM tab1 AS cor0
----
-24942
-3024
-40542

query I rowsort
SELECT + col2 * 17 + - col1 * col0 * col2 AS col1 FROM tab2 AS cor0
----
-119210
-50388
-5400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7068
SELECT + col0 + + CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
121
176
57

skipif mysql # not compatible
query I rowsort label-7068
SELECT + col0 + + CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-7069
SELECT + col2 * + cor0.col0 * col1 + col2 DIV + col2 AS col0 FROM tab1 cor0
----
36481
4213
99841

skipif mysql # not compatible
query I rowsort label-7069
SELECT + col2 * + cor0.col0 * col1 + col2 / + col2 AS col0 FROM tab1 cor0
----
36481
4213
99841

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7070
SELECT + col2 + + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7070
SELECT + col2 + + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * + ( ( + col2 ) ) - col2 AS col2 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT ALL - + col1 + 14 * - col1 AS col2 FROM tab0 AS cor0
----
-1290
-1365
-1455

onlyif mysql # use DIV operator for integer division
query I rowsort label-7073
SELECT DISTINCT cor0.col1 * 82 + + 23 DIV - col0 AS col1 FROM tab1 AS cor0
----
1066
2125
820

skipif mysql # not compatible
query I rowsort label-7073
SELECT DISTINCT cor0.col1 * 82 + + 23 / - col0 AS col1 FROM tab1 AS cor0
----
1066
2125
820

query I rowsort
SELECT col1 * col0 + ( col1 ) * col2 AS col0 FROM tab1 AS cor0
----
1210
1482
2288

onlyif mysql # use DIV operator for integer division
query I rowsort label-7075
SELECT DISTINCT + cor0.col0 * 42 + col2 + - col1 DIV col0 AS col0 FROM tab0 AS cor0
----
1038
1469
3819

skipif mysql # not compatible
query I rowsort label-7075
SELECT DISTINCT + cor0.col0 * 42 + col2 + - col1 / col0 AS col0 FROM tab0 AS cor0
----
1038
1469
3819

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - + col0 col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT ALL + col0 * ( + col2 ) + - cor0.col0 FROM tab1 AS cor0
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-7078
SELECT 94 DIV + col1 col2 FROM tab0
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7078
SELECT 94 / + col1 col2 FROM tab0
----
0
1
1

query I rowsort
SELECT ALL cor0.col0 + - col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col1 * ( cor0.col1 ) + col2 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
3349
3592
9385

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + + cor0.col2 col2 FROM tab2 AS cor0
----
52
54
76

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab0 AS cor2
----
3645 values hashing to 181d902c42955a43a374f13a73d8b0a1

query I rowsort
SELECT + + col0 * + col1 * + cor0.col2 + col0 AS col2 FROM tab0 cor0
----
3430
664207
68136

query I rowsort
SELECT + + ( ( + cor0.col1 ) ) AS col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL - 58 * + col0 + + col1 AS col2 FROM tab0 AS cor0
----
-1306
-1933
-5071

query I rowsort
SELECT ALL 21 AS col1 FROM tab2 cor0
----
21
21
21

query I rowsort
SELECT DISTINCT 2 + + col0 * + col2 + + col2 FROM tab1 AS cor0
----
218
3707
7778

query I rowsort
SELECT - - 19 * + col2 * - ( + col0 ) FROM tab1 AS cor0
----
-145920
-3078
-69312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 60 col1 FROM tab2 AS cor0
----
60
60
60

query I rowsort
SELECT + + 35 * col1 AS col1 FROM tab0 AS cor0
----
3010
3185
3395

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * col2 col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - 57 * - col2 + + col2 FROM tab2 AS cor0
----
1508
1566
2204

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7093
SELECT ALL - - CAST( - col0 AS SIGNED ) + + col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7093
SELECT ALL - - CAST ( - col0 AS INTEGER ) + + col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - 98 * + cor0.col0 + cor0.col2 * col0 FROM tab2 AS cor0
----
-4740
-497
-5616

query I rowsort
SELECT DISTINCT + col2 + - col2 AS col2 FROM tab2 cor0
----
0

query I rowsort
SELECT DISTINCT + 28 * - cor0.col1 FROM tab0 cor0
----
-2408
-2548
-2716

query I rowsort
SELECT + ( - col2 ) * - col1 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7098
SELECT DISTINCT CAST( + col2 AS SIGNED ) + - col2 col0 FROM tab1 cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7098
SELECT DISTINCT CAST ( + col2 AS INTEGER ) + - col2 col0 FROM tab1 cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7099
SELECT - CAST( NULL AS DECIMAL ) * 51 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7099
SELECT - CAST ( NULL AS REAL ) * 51 col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + 41 AS col0 FROM tab2 AS cor0
----
119
120
48

query I rowsort
SELECT ALL - - 76 FROM tab2 AS cor0
----
76
76
76

query I rowsort
SELECT ALL col2 * 50 AS col0 FROM tab2
----
1300
1350
1900

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7103
SELECT col0 * ( 38 ) * col1 + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7103
SELECT col0 * ( 38 ) * col1 + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7104
SELECT col1 + CAST( col1 AS SIGNED ) FROM tab2
----
118
34
62

skipif mysql # not compatible
query I rowsort label-7104
SELECT col1 + CAST ( col1 AS INTEGER ) FROM tab2
----
118
34
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col1 * col2 * col1 col2 FROM tab2
----
11061
25954
90584

query I rowsort
SELECT + col2 + col1 + - cor0.col2 AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT - cor0.col0 * - col2 * col0 AS col2 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT DISTINCT + + col2 + 35 FROM tab2 AS cor0
----
61
62
73

query I rowsort
SELECT + + 7 + - col0 + col0 * + col0 AS col2 FROM tab0 cor0
----
1197
559
7839

query I rowsort
SELECT ALL 44 + + cor0.col1 FROM tab2 AS cor0
----
103
61
75

query I rowsort
SELECT col2 - col1 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + - ( 81 ) * + col2 + 85 * - col2 + - cor0.col1 FROM tab2 cor0
----
-4375
-4513
-6325

query I rowsort
SELECT DISTINCT - 97 AS col2 FROM tab0 AS cor0
----
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab1.col2 col2 FROM tab1, tab2 AS cor0
----
54
57
96

query I rowsort
SELECT 24 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 92 col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT col0 + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT - cor0.col2 + cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - col2 - + col2 FROM tab1
----
-108
-114
-192

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7120
SELECT ALL - col0 + CAST( NULL AS SIGNED ) * ( col1 ) * 85 + 97 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7120
SELECT ALL - col0 + CAST ( NULL AS INTEGER ) * ( col1 ) * 85 + 97 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * + 69 AS col0 FROM tab2 AS cor0
----
483
5382
5451

query I rowsort
SELECT ALL - col0 * ( cor0.col2 ) + + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT ALL - 86 + 11 FROM tab1, tab1 AS cor0
----
9 values hashing to 258bc565c64924d905a55eaaa6e57547

query I rowsort
SELECT col1 + 12 * col1 * - col0 AS col2 FROM tab1 AS cor0
----
-12467
-7670
-910

query I rowsort
SELECT DISTINCT + cor0.col0 + col1 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT col0 * col0 + - 89 FROM tab2
----
-40
5995
6152

query I rowsort
SELECT + col1 + - ( + col1 ) * - col2 AS col2 FROM tab0
----
194
2924
7553

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + 76 * - cor0.col0 col0 FROM tab0 AS cor0
----
-1800
-2625
-6675

query I rowsort
SELECT DISTINCT + col0 * ( - 70 ) + - col2 * + col2 FROM tab1 AS cor0
----
-14816
-3126
-7729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + ( col1 ) - col2 col2 FROM tab2 AS cor0
----
-4
35
92

query I rowsort
SELECT ALL - col0 - + col1 AS col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT ALL cor0.col1 * - cor0.col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - col1 + + ( + ( + col1 ) * col0 ) + col1 AS col1 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7134
SELECT ALL + col0 * + CAST( + col2 AS SIGNED ) FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-7134
SELECT ALL + col0 * + CAST ( + col2 AS INTEGER ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + - col2 + 48 FROM tab0 AS cor0
----
-34
15
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-7136
SELECT ALL - - col2 + 18 DIV 88 FROM tab1 cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-7136
SELECT ALL - - col2 + 18 / 88 FROM tab1 cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7137
SELECT ALL - cor0.col0 DIV col1 + + ( - col0 ) AS col1 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-7137
SELECT ALL - cor0.col0 / col1 + + ( - col0 ) AS col1 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7138
SELECT - col0 * CAST( col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-7138
SELECT - col0 * CAST ( col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-7139
SELECT DISTINCT + col1 DIV ( + cor0.col0 ) AS col0 FROM tab1 AS cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-7139
SELECT DISTINCT + col1 / ( + cor0.col0 ) AS col0 FROM tab1 AS cor0
----
0
8

query I rowsort
SELECT ALL 98 + + col0 AS col1 FROM tab1 AS cor0
----
101
162
178

onlyif mysql # use DIV operator for integer division
query I rowsort label-7141
SELECT ( 66 ) DIV cor0.col1 FROM tab1 AS cor0
----
2
5
6

skipif mysql # not compatible
query I rowsort label-7141
SELECT ( 66 ) / cor0.col1 FROM tab1 AS cor0
----
2
5
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( col2 ) * + cor0.col2 col2 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT + + ( 89 ) + col0 FROM tab1 AS cor0
----
153
169
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-7144
SELECT ALL - col1 DIV col2 + col1 AS col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-7144
SELECT ALL - col1 / col2 + col1 AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + 13 - + col2 * - 63 AS col1 FROM tab0 AS cor0
----
2092
5179
76

query I rowsort
SELECT col0 * col1 * 47 AS col1 FROM tab1
----
30080
3666
48880

query I rowsort
SELECT ALL - 60 * col1 AS col1 FROM tab0 AS cor0
----
-5160
-5460
-5820

query I rowsort
SELECT cor0.col2 * col0 + - cor0.col2 FROM tab2 AS cor0
----
162
2002
2964

query I rowsort
SELECT DISTINCT - 2 - 85 * col2 FROM tab1
----
-4592
-4847
-8162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 5 col2 FROM tab0 cor0
----
-5
-5
-5

query I rowsort
SELECT DISTINCT + ( col0 ) * + col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - - 22 * + col2 + col2 AS col1 FROM tab0 AS cor0
----
1886
23
759

query I rowsort
SELECT ALL - 28 * cor0.col2 AS col1 FROM tab1 AS cor0
----
-1512
-1596
-2688

query I rowsort
SELECT DISTINCT 48 + tab1.col1 FROM tab1
----
58
61
74

query I rowsort
SELECT ALL col0 - - 58 FROM tab2 AS cor0
----
136
137
65

query I rowsort
SELECT DISTINCT + - col0 + col0 AS col0 FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7157
SELECT DISTINCT - col1 + - col1 DIV 53 AS col0 FROM tab0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-7157
SELECT DISTINCT - col1 + - col1 / 53 AS col0 FROM tab0
----
-87
-92
-98

query I rowsort
SELECT + 94 * col0 AS col0 FROM tab1
----
282
6016
7520

query I rowsort
SELECT col0 + col1 * col0 * - ( col2 * - 70 ) AS col1 FROM tab0
----
237685
46488349
4767864

query I rowsort
SELECT - 89 * col1 - + col2 * + col0 AS col1 FROM tab0
----
-15397
-8446
-8668

query I rowsort
SELECT ( tab0.col1 + - col0 ) FROM tab0
----
2
62
62

query I rowsort
SELECT 41 * + col1 * - col1 FROM tab2
----
-11849
-142721
-39401

onlyif mysql # use DIV operator for integer division
query I rowsort label-7163
SELECT DISTINCT - col2 DIV col2 + - col2 FROM tab1
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-7163
SELECT DISTINCT - col2 / col2 + - col2 FROM tab1
----
-55
-58
-97

query I rowsort
SELECT DISTINCT 89 + - tab2.col1 AS col0 FROM tab2
----
30
58
72

query I rowsort
SELECT ALL + col0 + cor0.col2 AS col0 FROM tab2 cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + ( col2 ) ) * - ( + col2 ) col0 FROM tab2 AS cor0
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 93 col1 FROM tab1
----
5022
5301
8928

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7168
SELECT - + CAST( NULL AS SIGNED ) + - cor0.col2 * cor0.col0 * + col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7168
SELECT - + CAST ( NULL AS INTEGER ) + - cor0.col2 * cor0.col0 * + col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 - col2 AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT - - 89 - col1 FROM tab2 AS cor0
----
30
58
72

query I rowsort
SELECT - + 69 * - cor0.col0 + - col1 FROM tab0 AS cor0
----
1570
2318
6050

query I rowsort
SELECT DISTINCT - col0 + - col1 * tab2.col0 FROM tab2
----
-1422
-224
-4680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7173
SELECT ( - 48 ) + + col2 + CAST( NULL AS SIGNED ) * 85 / + col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7173
SELECT ( - 48 ) + + col2 + CAST ( NULL AS INTEGER ) * 85 / + col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 + ( col2 ) AS col0 FROM tab0
----
0

query I rowsort
SELECT cor0.col1 - + col1 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT ( + col1 * tab1.col2 ) + + tab1.col0 * 95 AS col0 FROM tab1
----
1689
6650
8848

query I rowsort
SELECT DISTINCT + 73 * - col0 FROM tab0
----
-1752
-2555
-6497

query I rowsort
SELECT 28 * col0 FROM tab2
----
196
2184
2212

query I rowsort
SELECT + col1 * ( col1 ) AS col1 FROM tab1 cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * + ( col1 ) * col1 col1 FROM tab2 AS cor0
----
205379
29791
4913

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + 58 col2 FROM tab1 AS cor0
----
-3132
-3306
-5568

onlyif mysql # use DIV operator for integer division
query I rowsort label-7182
SELECT - col2 DIV + 50 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7182
SELECT - col2 / + 50 AS col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - + col2 * 94 * col2 FROM tab1 cor0
----
-274104
-305406
-866304

query I rowsort
SELECT col0 * col1 + + col2 FROM tab1
----
1136
132
697

query I rowsort
SELECT - 92 FROM tab2, tab0 AS cor0
----
9 values hashing to 1af709a79a3e56281ffdce4d931d5965

query I rowsort
SELECT ALL + col2 + + 11 * - cor0.col2 FROM tab1 AS cor0
----
-540
-570
-960

query I rowsort
SELECT ALL + + cor0.col0 + col2 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-7188
SELECT + cor0.col0 DIV + col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7188
SELECT + cor0.col0 / + col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT 56 * - cor0.col2 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to a25528cb2adafb9953cec876765cb142

query I rowsort
SELECT DISTINCT + - col1 + - 98 FROM tab2 AS cor0
----
-115
-129
-157

query I rowsort
SELECT DISTINCT col1 + col1 * - col0 AS col0 FROM tab2 AS cor0
----
-1326
-186
-4543

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7192
SELECT DISTINCT - CAST( NULL AS DECIMAL ) col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7192
SELECT DISTINCT - CAST ( NULL AS REAL ) col1 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7193
SELECT - col0 DIV col0 AS col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7193
SELECT - col0 / col0 AS col1 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + 32 + - cor0.col0 AS col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to cf5666fbed652564752bdf661b7d17b2

query I rowsort
SELECT ALL 79 AS col0 FROM tab0, tab1 cor0 CROSS JOIN tab1
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7196
SELECT CAST( NULL AS DECIMAL ) - tab1.col2 * col1 * CAST( 78 AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7196
SELECT CAST ( NULL AS REAL ) - tab1.col2 * col1 * CAST ( 78 AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0 CROSS JOIN tab0, tab0 AS cor1
----
972 values hashing to ea0f747588ddf5869ee18a5e22d9f237

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 95 col2 FROM tab1 AS cor0
----
95
95
95

query I rowsort
SELECT + 16 * + 73 + - col0 AS col1 FROM tab1 AS cor0
----
1088
1104
1165

query I rowsort
SELECT 11 + - col1 AS col0 FROM tab0 AS cor0
----
-75
-80
-86

query I rowsort
SELECT - 56 * - col1 FROM tab1 cor0
----
1456
560
728

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 40 * + col2 + col1 col2 FROM tab0 AS cor0
----
-1234
-3189
57

query I rowsort
SELECT + 86 * - col0 FROM tab2
----
-602
-6708
-6794

query I rowsort
SELECT - col2 * col0 * 71 AS col1 FROM tab1
----
-11502
-259008
-545280

query I rowsort
SELECT 59 + - col1 AS col0 FROM tab2 AS cor0
----
0
28
42

query I rowsort
SELECT - cor0.col0 * col2 + - col2 FROM tab2 AS cor0
----
-2054
-216
-3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7207
SELECT + - col0 / - CAST( NULL AS SIGNED ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7207
SELECT + - col0 / - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7208
SELECT col0 + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7208
SELECT col0 + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col2 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT DISTINCT + col0 * cor0.col1 + col1 AS col2 FROM tab2 cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT cor0.col0 + col1 AS col1 FROM tab0 AS cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 79 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT + - col1 + ( + cor0.col1 ) FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL + + col1 + - cor0.col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col0 + + col0 * + cor0.col0 FROM tab2 cor0
----
56
6162
6320

query I rowsort
SELECT + - 5 * col0 FROM tab0 AS cor0
----
-120
-175
-445

onlyif mysql # use DIV operator for integer division
query I rowsort label-7217
SELECT + - 3 DIV col1 AS col1 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7217
SELECT + - 3 / col1 AS col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL + 9 + col2 AS col1 FROM tab2 AS cor0
----
35
36
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7219
SELECT ALL col1 + - col2 * + CAST( NULL AS DECIMAL ) * col2 - col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7219
SELECT ALL col1 + - col2 * + CAST ( NULL AS REAL ) * col2 - col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + 47 + col1 AS col2 FROM tab0 AS cor0
----
133
138
144

query I rowsort
SELECT DISTINCT ( + col0 * + col0 ) FROM tab2
----
49
6084
6241

query I rowsort
SELECT 3 * col2 FROM tab1
----
162
171
288

query I rowsort
SELECT ALL ( tab2.col1 ) + - col2 FROM tab2
----
-21
33
4

query I rowsort
SELECT DISTINCT + col2 * col0 * col0 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT ALL + 24 + + col1 * col2 FROM tab0 AS cor0
----
121
2862
7486

query I rowsort
SELECT ALL - 89 AS col1 FROM tab2 cor0
----
-89
-89
-89

query I rowsort
SELECT DISTINCT cor0.col0 - - tab2.col1 FROM tab2, tab0 AS cor0
----
9 values hashing to fb176be5d9b49c1f744e4199c3ae250f

query I rowsort
SELECT DISTINCT - cor0.col2 * ( + 51 * - col1 ) FROM tab0 AS cor0
----
144738
380562
4947

query I rowsort
SELECT + cor0.col2 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7230
SELECT ALL - col1 + + cor0.col2 * - col1 / - CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7230
SELECT ALL - col1 + + cor0.col2 * - col1 / - CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7231
SELECT - col2 DIV col0 + + col2 - - col1 AS col1 FROM tab0
----
118
173
98

skipif mysql # not compatible
query I rowsort label-7231
SELECT - col2 / col0 + + col2 - - col1 AS col1 FROM tab0
----
118
173
98

query I rowsort
SELECT + 53 - ( - col0 * - tab2.col2 ) FROM tab2
----
-136
-1975
-2949

query I rowsort
SELECT - 10 * col2 AS col2 FROM tab2
----
-260
-270
-380

query I rowsort
SELECT - 69 + - col2 AS col1 FROM tab0
----
-102
-151
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-7235
SELECT 83 DIV col0 + col1 AS col0 FROM tab2
----
18
42
60

skipif mysql # not compatible
query I rowsort label-7235
SELECT 83 / col0 + col1 AS col0 FROM tab2
----
18
42
60

query I rowsort
SELECT DISTINCT 60 * + tab1.col0 + - col1 AS col1 FROM tab1
----
154
3830
4787

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 91 col2 FROM tab1
----
91
91
91

query I rowsort
SELECT DISTINCT - ( 88 ) * - col1 + - col2 FROM tab1
----
1048
2234
823

onlyif mysql # use DIV operator for integer division
query I rowsort label-7239
SELECT ALL - + 0 DIV 48 AS col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7239
SELECT ALL - + 0 / 48 AS col2 FROM tab1 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 51 + + col1 col0 FROM tab1
----
61
64
77

query I rowsort
SELECT - col0 * - 42 AS col1 FROM tab2 AS cor0
----
294
3276
3318

query I rowsort
SELECT - 94 + 63 * + col1 AS col0 FROM tab1 AS cor0
----
1544
536
725

query I rowsort
SELECT - cor0.col1 * + 46 FROM tab0 AS cor0
----
-3956
-4186
-4462

query I rowsort
SELECT cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT DISTINCT - + col1 * col2 - col2 AS col2 FROM tab1 cor0
----
-1344
-1458
-627

query I rowsort
SELECT ALL + ( ( col1 ) ) + - ( + col2 ) + - col1 * + col0 AS col2 FROM tab1 AS cor0
----
-106
-1123
-687

query I rowsort
SELECT ALL - ( + cor0.col0 ) + col0 * ( + col2 + + col2 ) FROM tab0 AS cor0
----
14507
1560
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 13 + col0 * col1 col2 FROM tab0 AS cor0
----
2077
3408
8112

query I rowsort
SELECT DISTINCT + - 19 AS col0 FROM tab0 AS cor0
----
-19

query I rowsort
SELECT ALL + + 90 AS col2 FROM tab2 AS cor0
----
90
90
90

query I rowsort
SELECT ALL 69 * cor0.col0 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to c28b77c5cfbef3617defcc65a6024196

query I rowsort
SELECT ALL - 41 * - 43 AS col1 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to b53a0110e77c2ae180dd991309f675d4

query I rowsort
SELECT DISTINCT + col0 * + col0 + 67 + col2 * + col2 AS col2 FROM tab1 AS cor0
----
15683
2992
7412

query I rowsort
SELECT + col1 + - cor0.col1 FROM tab0 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7255
SELECT ALL CAST( NULL AS SIGNED ) col2 FROM tab0, tab2 AS cor0, tab1 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7255
SELECT ALL CAST ( NULL AS INTEGER ) col2 FROM tab0, tab2 AS cor0, tab1 cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - + 9 * col1 * + col1 FROM tab0 AS cor0
----
-66564
-74529
-84681

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 + col1 col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT + 36 * col2 AS col2 FROM tab2 AS cor0
----
1368
936
972

onlyif mysql # use DIV operator for integer division
query I rowsort label-7259
SELECT 75 DIV cor0.col2 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 3daf191600c64328f2c60722189235c6

skipif mysql # not compatible
query I rowsort label-7259
SELECT 75 / cor0.col2 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 3daf191600c64328f2c60722189235c6

onlyif mysql # use DIV operator for integer division
query I rowsort label-7260
SELECT + col2 DIV - cor0.col2 - - cor0.col0 AS col2 FROM tab0 cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-7260
SELECT + col2 / - cor0.col2 - - cor0.col0 AS col2 FROM tab0 cor0
----
23
34
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - ( col1 ) * col1 col2 FROM tab1 AS cor0
----
-156
-650
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7262
SELECT col2 * - ( col1 * col2 ) + CAST( NULL AS DECIMAL ) AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7262
SELECT col2 * - ( col1 * col2 ) + CAST ( NULL AS REAL ) AS col0 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7263
SELECT + col2 + ( + col0 ) DIV + tab2.col0 + ( - ( col2 ) ) col1 FROM tab2
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7263
SELECT + col2 + ( + col0 ) / + tab2.col0 + ( - ( col2 ) ) col1 FROM tab2
----
1
1
1

query I rowsort
SELECT DISTINCT - col1 * - 26 - col1 AS col2 FROM tab0 AS cor0
----
2150
2275
2425

query I rowsort
SELECT col2 + col2 * col0 * - col2 FROM tab2 AS cor0
----
-114038
-5076
-52702

query I rowsort
SELECT - - col0 - 23 FROM tab2 AS cor0
----
-16
55
56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 - + 2 col2 FROM tab2 cor0
----
24
25
36

query I rowsort
SELECT + + col2 * ( - 7 ) + - col0 FROM tab0 cor0
----
-255
-42
-663

query I rowsort
SELECT ALL + col2 + - ( col2 ) * col0 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT DISTINCT 39 AS col2 FROM tab0 cor0
----
39

query I rowsort
SELECT 17 AS col0 FROM tab2 AS cor0
----
17
17
17

query I rowsort
SELECT DISTINCT + col2 * - 8 AS col1 FROM tab1 AS cor0
----
-432
-456
-768

query I rowsort
SELECT DISTINCT - cor0.col1 + - col1 AS col2 FROM tab0 AS cor0
----
-172
-182
-194

onlyif mysql # use DIV operator for integer division
query I rowsort label-7274
SELECT ALL + + 28 + - col2 DIV + col1 AS col1 FROM tab2 AS cor0
----
26
28
28

skipif mysql # not compatible
query I rowsort label-7274
SELECT ALL + + 28 + - col2 / + col1 AS col1 FROM tab2 AS cor0
----
26
28
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-7275
SELECT + col0 DIV - cor0.col0 - col1 FROM tab2 AS cor0
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-7275
SELECT + col0 / - cor0.col0 - col1 FROM tab2 AS cor0
----
-18
-32
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-7276
SELECT DISTINCT + ( + col1 ) DIV - col1 + col0 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-7276
SELECT DISTINCT + ( + col1 ) / - col1 + col0 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT + 12 - + 86 FROM tab2 AS cor0
----
-74
-74
-74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 59 col2 FROM tab1 AS cor0
----
59

query I rowsort
SELECT + col0 * col0 + + col1 AS col1 FROM tab2 cor0
----
6143
6258
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7280
SELECT DISTINCT - + CAST( - ( + col2 ) AS SIGNED ) * col0 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-7280
SELECT DISTINCT - + CAST ( - ( + col2 ) AS INTEGER ) * col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL cor0.col0 + col0 AS col1 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT + - 60 AS col2 FROM tab0 AS cor0
----
-60
-60
-60

query I rowsort
SELECT DISTINCT - 96 - - ( + col2 ) AS col1 FROM tab1 AS cor0
----
-39
-42
0

query I rowsort
SELECT DISTINCT + 52 * 54 + col0 + - 48 FROM tab0 AS cor0
----
2784
2795
2849

query I rowsort
SELECT DISTINCT ( - col0 ) - - cor0.col2 * - col0 AS col2 FROM tab0 AS cor0
----
-70
-7387
-816

onlyif mysql # use DIV operator for integer division
query I rowsort label-7286
SELECT + - 89 DIV 82 + col0 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-7286
SELECT + - 89 / 82 + col0 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT ALL + - 59 + ( - col1 ) FROM tab2 AS cor0
----
-118
-76
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7288
SELECT - col1 + - CAST( + col0 AS SIGNED ) + col2 AS col0 FROM tab0
----
-131
-77
-98

skipif mysql # not compatible
query I rowsort label-7288
SELECT - col1 + - CAST ( + col0 AS INTEGER ) + col2 AS col0 FROM tab0
----
-131
-77
-98

query I rowsort
SELECT DISTINCT + ( ( col0 ) ) * + ( col2 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + - ( + 98 ) + cor0.col2 AS col0 FROM tab0 AS cor0
----
-16
-65
-97

query I rowsort
SELECT - ( + col1 ) + col2 AS col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + + col0 + - col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - 77 AS col0 FROM tab1 AS cor0
----
-77
-77
-77

query I rowsort
SELECT ALL ( - col0 ) * col0 AS col2 FROM tab2
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col1 + cor0.col0 + - col1 col1 FROM tab0 cor0
----
-7458
-8283
-9471

query I rowsort
SELECT A