sqllogictest
Artifact Content
Not logged in

Artifact 7a6214ec5381bbcbe9a05a12ff3005bf6ba6e9e6:


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 38 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT DISTINCT + 78 AS col1 FROM tab2, tab0 AS cor0
----
78

query I rowsort
SELECT ALL - col0 + tab2.col0 FROM tab2 WHERE NULL >= col1
----

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

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

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

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

skipif mysql # not compatible
query I rowsort label-6
SELECT col2 - - tab2.col0 / + tab2.col1 AS col1 FROM tab2
----
27
27
42

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

query I rowsort
SELECT ALL - col2 + + tab2.col2 FROM tab2
----
0
0
0

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

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

skipif mysql # not compatible
query I rowsort label-10
SELECT DISTINCT col2 / tab0.col1 + col0 * - tab0.col0 AS col1 FROM tab0
----
-1225
-576
-7921

query III rowsort
SELECT * FROM tab0 WHERE ( NULL ) BETWEEN + col0 + + col2 * + col2 AND NULL
----

query I rowsort
SELECT ALL col1 + + col2 * - tab2.col1 AS col2 FROM tab2 WHERE NOT NULL >= NULL
----

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

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

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

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

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

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

query I rowsort
SELECT ALL + col0 - col0 * tab2.col1 FROM tab2
----
-1264
-210
-4524

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-21
SELECT + col0 DIV tab0.col2 col1 FROM tab0
----
0
1
35

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-27
SELECT ALL cor0.col1 * - col1 DIV cor0.col1 - + col1 AS col1 FROM tab2 AS cor0
----
-118
-34
-62

skipif mysql # not compatible
query I rowsort label-27
SELECT ALL cor0.col1 * - col1 / cor0.col1 - + col1 AS col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT - col0 * - col2 + - col1 * col2 AS col2 FROM tab0 cor0
----
-164
-2046
-62

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

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

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

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

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

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

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

query I rowsort
SELECT ALL + col1 * - col1 * + col0 AS col2 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL col0 AS col1 FROM tab1 WHERE NOT NULL < ( NULL )
----

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

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

query I rowsort
SELECT + col1 * col2 + col0 + + col1 * tab1.col0 AS col2 FROM tab1
----
1274
1485
2368

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

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

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

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

query I rowsort
SELECT DISTINCT - col1 FROM tab1 WHERE NULL >= ( - col2 * col1 * - col2 + - col1 )
----

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

query III rowsort
SELECT * FROM tab0 WHERE NOT + col1 * - col2 + + col0 * + col0 <= + col0 / + col2 + tab0.col0
----
35
97
1
89
91
82

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

query I rowsort
SELECT ALL tab1.col1 * - col2 AS col0 FROM tab1
----
-1248
-1404
-570

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

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

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

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

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

query I rowsort
SELECT ALL - col0 * - col1 + + 30 * col0 AS col2 FROM tab2 AS cor0
----
3713
427
6942

query I rowsort
SELECT DISTINCT + col2 * + 99 + - col1 * col0 AS col0 FROM tab1
----
5003
5268
8464

query I rowsort
SELECT + 26 + col0 AS col0 FROM tab0 AS cor0
----
115
50
61

query I rowsort
SELECT ALL - + ( - col2 ) + + col0 * + 57 FROM tab2 cor0
----
426
4472
4541

onlyif mysql # use DIV operator for integer division
query I rowsort label-56
SELECT DISTINCT - col0 * + col1 + col0 * - col0 DIV cor0.col0 + col1 * col1 AS col1 FROM tab2 AS cor0
----
-1133
-1199
737

skipif mysql # not compatible
query I rowsort label-56
SELECT DISTINCT - col0 * + col1 + col0 * - col0 / cor0.col0 + col1 * col1 AS col1 FROM tab2 AS cor0
----
-1133
-1199
737

query I rowsort
SELECT 54 + + tab1.col2 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to f4f955d4ded7cdde1a8c9cd78ded9361

query I rowsort
SELECT + 79 * + 93 AS col1 FROM tab0
----
7347
7347
7347

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

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

query I rowsort
SELECT - 86 * 54 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
-4565
-4566
-4637

query I rowsort
SELECT ALL col2 * - 20 AS col1 FROM tab2 AS cor0
----
-520
-540
-760

query I rowsort
SELECT DISTINCT - 25 + 62 FROM tab0 cor0
----
37

query I rowsort
SELECT + - col2 * col0 + col1 * + cor0.col2 + 66 AS col0 FROM tab1 AS cor0
----
-3012
-6366
1308

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

skipif mysql # not compatible
query I rowsort label-65
SELECT - tab1.col2 / 1 + - 0 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 0dc9bbe392d52df93d2a115d7f622dba

query I rowsort
SELECT ALL - tab1.col1 - 30 * + 88 FROM tab1, tab1 AS cor0
----
9 values hashing to 1e3527ab84af5311956ef29ace793a65

query I rowsort
SELECT ALL 3 * cor0.col2 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 9df9b70f0ce9b74a1172dc2d08f634c0

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

query I rowsort
SELECT ALL 78 AS col0 FROM tab0
----
78
78
78

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

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

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

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

query I rowsort
SELECT DISTINCT - col2 * - 50 FROM tab1 AS cor0
----
2700
2850
4800

query I rowsort
SELECT + cor0.col2 + ( + col0 + + col2 ) * col2 AS col2 FROM tab1 AS cor0
----
16992
3132
6954

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

query I rowsort
SELECT col0 * col0 + + cor0.col0 * col2 FROM tab0 AS cor0
----
1260
1368
15219

query I rowsort
SELECT + cor0.col0 + - ( 95 ) * + col1 AS col2 FROM tab1 AS cor0
----
-1155
-2467
-886

onlyif mysql # use DIV operator for integer division
query I rowsort label-78
SELECT ALL + - col2 DIV - col2 + + 75 FROM tab1 AS cor0
----
76
76
76

skipif mysql # not compatible
query I rowsort label-78
SELECT ALL + - col2 / - col2 + + 75 FROM tab1 AS cor0
----
76
76
76

query I rowsort
SELECT ALL + + cor0.col2 - - col2 * 93 AS col0 FROM tab1 AS cor0
----
5076
5358
9024

onlyif mysql # use DIV operator for integer division
query I rowsort label-80
SELECT + col1 DIV + 66 - ( col1 + - col2 ) AS col0 FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-80
SELECT + col1 / + 66 - ( col1 + - col2 ) AS col0 FROM tab1 AS cor0
----
28
47
83

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

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

skipif mysql # not compatible
query I rowsort
SELECT ALL + col2 * CAST ( 27 AS REAL ) AS col1 FROM tab0 AS cor0
----
2214
27
891

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

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

query I rowsort
SELECT - - col0 + + 25 FROM tab2 AS cor0
----
103
104
32

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

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

query I rowsort
SELECT 27 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 701bf12d86392cb1585d9e4f3c72e9a8

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

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( 84 AS REAL ) * col2 + cor0.col1 * cor0.col2 FROM tab0 AS cor0
----
13
574
66

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

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

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

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

query I rowsort
SELECT - 5 + col2 FROM tab2
----
21
22
33

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

query I rowsort
SELECT 17 * - col0 AS col0 FROM tab1
----
-1088
-1360
-51

query I rowsort
SELECT DISTINCT - tab1.col0 * - 8 FROM tab1
----
24
512
640

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

query I rowsort
SELECT ( col2 + - col1 ) * col0 AS col2 FROM tab1
----
3008
6640
84

query I rowsort
SELECT 7 * + tab0.col2 AS col2 FROM tab0
----
231
574
7

query I rowsort
SELECT 66 * 16 * col1 AS col0 FROM tab1
----
10560
13728
27456

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

query I rowsort
SELECT DISTINCT + col1 * + 9 AS col0 FROM tab2
----
153
279
531

query I rowsort
SELECT DISTINCT - 23 FROM tab2
----
-23

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

query I rowsort
SELECT + col2 + col2 AS col1 FROM tab0
----
164
2
66

query I rowsort
SELECT - col1 * cor0.col2 + col0 AS col1 FROM tab2 AS cor0
----
-1456
-567
-830

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-112
SELECT ALL - col2 DIV ( - tab0.col1 ) FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-112
SELECT ALL - col2 / ( - tab0.col1 ) FROM tab0
----
0
0
0

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

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

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

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

query I rowsort
SELECT col2 + - col2 AS col0 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-118
SELECT - tab1.col2 * tab1.col0 DIV + col1 + col1 DIV - col1 AS col1 FROM tab1
----
-365
-591
-7

skipif mysql # not compatible
query I rowsort label-118
SELECT - tab1.col2 * tab1.col0 / + col1 + col1 / - col1 AS col1 FROM tab1
----
-365
-591
-7

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

query I rowsort
SELECT - col2 * + col2 * col1 + - cor0.col2 * col1 AS col1 FROM tab2 AS cor0
----
-23436
-25194
-41418

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-122
SELECT - - col2 * col1 DIV - col1 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-122
SELECT - - col2 * col1 / - col1 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT - col0 * col0 + - tab2.col0 * col0 AS col0 FROM tab2
----
-12168
-12482
-98

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-125
SELECT DISTINCT col2 DIV tab1.col0 - col2 * + col0 AS col2 FROM tab1
----
-144
-3648
-7679

skipif mysql # not compatible
query I rowsort label-125
SELECT DISTINCT col2 / tab1.col0 - col2 * + col0 AS col2 FROM tab1
----
-144
-3648
-7679

query I rowsort
SELECT tab2.col2 - col2 AS col0 FROM tab2
----
0
0
0

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

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

query I rowsort
SELECT ALL - - cor0.col2 + col2 * - col1 + - col0 AS col1 FROM tab1 cor0
----
-1232
-1353
-577

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-130
SELECT + cor0.col1 + col2 / col0 col2 FROM tab2 AS cor0
----
17
34
59

query I rowsort
SELECT ALL col0 * col2 + - col2 + col0 AS col2 FROM tab1 AS cor0
----
111
3655
7664

query I rowsort
SELECT DISTINCT - - col1 + col2 + cor0.col2 AS col2 FROM tab2 AS cor0
----
111
85
93

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

query I rowsort
SELECT DISTINCT col1 FROM tab0 cor0 WHERE - col0 <= + col2 OR NOT NULL >= + col1 * col1 + + col1 * col2 + col1
----
86
91
97

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-142
SELECT + 30 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-142
SELECT + 30 / - col1 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - + col0 * - col1 + + 17 FROM tab2 AS cor0
----
1360
234
4619

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-144
SELECT DISTINCT + CAST( + 97 AS SIGNED ) + + cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
123
124
135

skipif mysql # not compatible
query I rowsort label-144
SELECT DISTINCT + CAST ( + 97 AS INTEGER ) + + cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
123
124
135

query I rowsort
SELECT + cor1.col1 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-148
SELECT - col2 * col2 * CAST( - col1 AS SIGNED ) + - col2 * + ( 86 ) FROM tab0 AS cor0
----
11
604832
90816

skipif mysql # not compatible
query I rowsort label-148
SELECT - col2 * col2 * CAST ( - col1 AS INTEGER ) + - col2 * + ( 86 ) FROM tab0 AS cor0
----
11
604832
90816

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

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

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

query I rowsort
SELECT 19 + cor0.col2 FROM tab0 AS cor0
----
101
20
52

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

query I rowsort
SELECT DISTINCT + 83 * cor0.col0 FROM tab1 cor0
----
249
5312
6640

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

query I rowsort
SELECT ALL col0 + + ( + 25 ) AS col1 FROM tab2 AS cor0
----
103
104
32

query I rowsort
SELECT ALL - col0 * + col0 + + col2 AS col2 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT ALL col1 * col2 - col0 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT + 12 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

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

query I rowsort
SELECT DISTINCT 68 AS col2 FROM tab2 AS cor0
----
68

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 - ( + cor0.col2 ) * col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT col1 * + ( col1 + + ( + col0 ) ) FROM tab1 cor0
----
1209
740
754

query I rowsort
SELECT + col0 * 80 FROM tab0 AS cor0
----
1920
2800
7120

query I rowsort
SELECT DISTINCT - 10 + col2 * + cor0.col1 AS col2 FROM tab2 AS cor0
----
1524
636
827

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

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( + cor0.col0 AS REAL ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT ( 73 ) AS col2 FROM tab0
----
73
73
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - ( col0 ) ) col0 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT DISTINCT ( + ( col0 ) ) + - col1 * 27 - + col0 FROM tab1
----
-270
-351
-702

query I rowsort
SELECT + cor0.col2 AS col2 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

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

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

query I rowsort
SELECT col1 * col1 + - col0 FROM tab0 AS cor0
----
7372
8192
9374

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

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

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

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

query I rowsort
SELECT - col1 * col1 + + col1 FROM tab2 AS cor0
----
-272
-3422
-930

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - 78 ) + col1 col1 FROM tab1
----
104
88
91

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

query I rowsort
SELECT + + 33 AS col2 FROM tab2 AS cor0
----
33
33
33

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

skipif mysql # not compatible
query I rowsort label-182
SELECT - ( col2 ) + 64 / 74 FROM tab2 AS cor0
----
-26
-27
-38

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

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

query I rowsort
SELECT ALL cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

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

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

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

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

query I rowsort
SELECT ALL tab0.col2 + col0 + col1 * + 5 FROM tab0
----
487
521
626

onlyif mysql # use DIV operator for integer division
query I rowsort label-190
SELECT + 34 DIV col1 AS col2 FROM tab1 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-190
SELECT + 34 / col1 AS col2 FROM tab1 AS cor0
----
1
2
3

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-193
SELECT + col1 * col2 DIV - 57 FROM tab1
----
-10
-21
-24

skipif mysql # not compatible
query I rowsort label-193
SELECT + col1 * col2 / - 57 FROM tab1
----
-10
-21
-24

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

query I rowsort
SELECT col1 + col1 * 28 FROM tab1
----
290
377
754

query I rowsort
SELECT - col0 * col1 + + 34 FROM tab2
----
-1309
-183
-4568

onlyif mysql # use DIV operator for integer division
query I rowsort label-197
SELECT col1 + 80 DIV col0 AS col2 FROM tab1
----
11
14
52

skipif mysql # not compatible
query I rowsort label-197
SELECT col1 + 80 / col0 AS col2 FROM tab1
----
11
14
52

query I rowsort
SELECT + col0 - + 33 AS col0 FROM tab0
----
-9
2
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-199
SELECT - col0 * tab1.col1 DIV col2 - + col2 AS col2 FROM tab1
----
-106
-55
-68

skipif mysql # not compatible
query I rowsort label-199
SELECT - col0 * tab1.col1 / col2 - + col2 AS col2 FROM tab1
----
-106
-55
-68

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * ( - col1 ) + - cor0.col2 * col2 col2 FROM tab0 AS cor0
----
1749
738
96

query I rowsort
SELECT DISTINCT - col0 - - 73 AS col0 FROM tab1 AS cor0
----
-7
70
9

query I rowsort
SELECT + col2 * - 14 FROM tab1
----
-1344
-756
-798

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

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

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

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

skipif mysql # not compatible
query I rowsort label-209
SELECT ALL + col0 / ( - col0 ) + + col1 AS col1 FROM tab1 AS cor0
----
12
25
9

query I rowsort
SELECT DISTINCT 61 AS col2 FROM tab0
----
61

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

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

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

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

query I rowsort
SELECT DISTINCT + - 64 * - 67 AS col0 FROM tab1 AS cor0
----
4288

onlyif mysql # use DIV operator for integer division
query I rowsort label-215
SELECT 31 DIV + 8 FROM tab2 cor0
----
3
3
3

skipif mysql # not compatible
query I rowsort label-215
SELECT 31 / + 8 FROM tab2 cor0
----
3
3
3

query I rowsort
SELECT DISTINCT - 27 * + col0 AS col2 FROM tab2 AS cor0
----
-189
-2106
-2133

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

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

query I rowsort
SELECT - 58 FROM tab0, tab1 cor0
----
9 values hashing to de0811e670e75d2aeeb657e32bddb0c0

query I rowsort
SELECT + 21 * + ( - cor0.col1 + + col1 * - col2 ) AS col0 FROM tab1 cor0
----
-12180
-26481
-30030

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

query I rowsort
SELECT ( 92 ) + col2 FROM tab0 AS cor0
----
125
174
93

query I rowsort
SELECT - ( 98 ) FROM tab0, tab1 AS cor0
----
9 values hashing to f17b7008a7deae1eb5a2e707ec237638

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

query I rowsort
SELECT - cor0.col0 * tab2.col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 778568a0294a40217171bb2f1bbf2149

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-228
SELECT + ( - col0 ) DIV + cor0.col0 + + col2 * col0 DIV col0 + - col0 * - col0 AS col1 FROM tab2 AS cor0
----
6109
6278
75

skipif mysql # not compatible
query I rowsort label-228
SELECT + ( - col0 ) / + cor0.col0 + + col2 * col0 / col0 + - col0 * - col0 AS col1 FROM tab2 AS cor0
----
6109
6278
75

query I rowsort
SELECT ( - col1 ) AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - 13 * - 50 * + cor0.col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 5b1bc8802f50a218799cff20d433d064

skipif mysql # not compatible
query I rowsort
SELECT + 5 + col1 * col2 * 23 + col1 * CAST ( - col0 AS REAL ) * col2 AS col0 FROM tab0 AS cor0
----
-1159
-2833
-492487

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

query I rowsort
SELECT col0 + + 44 AS col0 FROM tab2
----
122
123
51

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

query I rowsort
SELECT ( col0 * 82 ) FROM tab0
----
1968
2870
7298

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

skipif mysql # not compatible
query I rowsort label-236
SELECT ALL col2 + CAST ( + col0 + + col0 AS INTEGER ) FROM tab2 AS cor0
----
182
196
41

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

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

query I rowsort
SELECT ALL - col1 * + 97 + + cor0.col0 + + col2 * + 52 * - col1 FROM tab2 AS cor0
----
-35162
-46524
-85413

query I rowsort
SELECT ALL - + col2 * cor0.col1 + - 74 AS col0 FROM tab0 AS cor0
----
-171
-2912
-7536

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

query I rowsort
SELECT ALL + 88 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

onlyif mysql # use DIV operator for integer division
query I rowsort label-243
SELECT DISTINCT + 97 DIV - col1 + 66 FROM tab0
----
65

skipif mysql # not compatible
query I rowsort label-243
SELECT DISTINCT + 97 / - col1 + 66 FROM tab0
----
65

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

query I rowsort
SELECT ALL + 81 * col0 AS col0 FROM tab2
----
567
6318
6399

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-247
SELECT + - cor0.col2 DIV 80 col0 FROM tab2 AS cor0
----
0
0
0

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

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

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0 CROSS JOIN tab1, tab0 AS cor1
----
972 values hashing to b51b4342db121ebc2d3d353dcd8ed521

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

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

query I rowsort
SELECT col1 * - 35 + col2 FROM tab0 AS cor0
----
-2977
-3103
-3394

query I rowsort
SELECT + + 61 * - cor0.col1 + col0 AS col1 FROM tab1 AS cor0
----
-1583
-546
-713

onlyif mysql # use DIV operator for integer division
query I rowsort label-254
SELECT - + CAST( col1 AS SIGNED ) * + col2 * - 72 - col2 DIV + col1 AS col1 FROM tab0 cor0
----
204336
537264
6984

skipif mysql # not compatible
query I rowsort label-254
SELECT - + CAST ( col1 AS INTEGER ) * + col2 * - 72 - col2 / + col1 AS col1 FROM tab0 cor0
----
204336
537264
6984

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-258
SELECT 58 + 95 DIV cor1.col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to e3d39faf222a133fdc73c33cd5d83966

skipif mysql # not compatible
query I rowsort label-258
SELECT 58 + 95 / cor1.col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to e3d39faf222a133fdc73c33cd5d83966

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

query I rowsort
SELECT - 80 + col2 FROM tab2 AS cor0
----
-42
-53
-54

query I rowsort
SELECT DISTINCT col1 - + 92 FROM tab2
----
-33
-61
-75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 - ( + 85 ) col0 FROM tab1
----
-139
-142
-181

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-263
SELECT col1 + - CAST ( + col0 AS INTEGER ) * - col0 col0 FROM tab0
----
1322
662
8012

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

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

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

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

query I rowsort
SELECT ALL - - tab2.col2 + + 17 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to f9c9ab355d69c4d7914487878ef3a1fe

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
972 values hashing to 0fcd8d0934383dd58863be894b07a6ed

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-270
SELECT - 7 * + col0 DIV col0 FROM tab1 AS cor0
----
-7
-7
-7

skipif mysql # not compatible
query I rowsort label-270
SELECT - 7 * + col0 / col0 FROM tab1 AS cor0
----
-7
-7
-7

query I rowsort
SELECT DISTINCT - - col2 * + 22 + col1 FROM tab2 AS cor0
----
625
631
853

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

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

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

query I rowsort
SELECT ALL - cor0.col1 * 45 + + col0 FROM tab2 cor0
----
-1388
-2577
-686

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

query I rowsort
SELECT col0 * - col1 + - col1 * col2 FROM tab0 AS cor0
----
-15561
-3492
-4902

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

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

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

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-281
SELECT ALL + - CAST( NULL AS DECIMAL ) * cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-281
SELECT ALL + - CAST ( NULL AS REAL ) * cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

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

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

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

query I rowsort
SELECT + col2 * - col2 + + 53 AS col1 FROM tab1 cor0
----
-2863
-3196
-9163

query I rowsort
SELECT ALL - cor0.col1 + col2 + col0 FROM tab2 cor0
----
100
3
45

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

query I rowsort
SELECT DISTINCT - 67 * + col2 - 37 FROM tab1 AS cor0
----
-3655
-3856
-6469

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

query I rowsort
SELECT DISTINCT + + col1 * + 16 FROM tab1 AS cor0
----
160
208
416

query I rowsort
SELECT + col0 * + 80 + - col0 FROM tab0 AS cor0
----
1896
2765
7031

query I rowsort
SELECT DISTINCT + col0 + 92 AS col1 FROM tab2 AS cor0
----
170
171
99

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

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

query I rowsort
SELECT ALL - - col1 * 5 AS col2 FROM tab2 AS cor0
----
155
295
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - 8 + + ( col2 ) * col0 col2 FROM tab2 AS cor0
----
133
1404
2370

query I rowsort
SELECT + 95 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

query I rowsort
SELECT DISTINCT + col0 * 58 FROM tab1 AS cor0
----
174
3712
4640

query I rowsort
SELECT ALL + cor0.col2 AS col0 FROM tab0 cor0
----
1
33
82

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

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

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

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

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

query I rowsort
SELECT + col2 * 15 * col2 AS col2 FROM tab1 AS cor0
----
138240
43740
48735

query I rowsort
SELECT ALL - cor0.col1 + + col0 * - ( col0 * 41 ) FROM tab1 AS cor0
----
-167946
-262413
-395

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

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

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

query I rowsort
SELECT DISTINCT + col1 * - col1 - - 69 FROM tab1 AS cor0
----
-100
-31
-607

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

query I rowsort
SELECT col0 * ( col2 ) * - tab2.col0 + col2 FROM tab2
----
-1296
-158158
-237120

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

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

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

query I rowsort
SELECT + 60 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 1d2ab302ae60f95b15e68cf89083b162

query I rowsort
SELECT DISTINCT + col1 * col1 AS col2 FROM tab0
----
7396
8281
9409

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

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

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

query I rowsort
SELECT 25 AS col1 FROM tab2, tab0 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to 68fc0eecd4f434589f3ec576bbd0c540

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-322
SELECT CAST ( col0 AS INTEGER ) + col0 col1 FROM tab2 AS cor0
----
14
156
158

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

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

query I rowsort
SELECT col2 * - col2 + col2 * col1 * col0 AS col0 FROM tab0
----
3394
657394
67023

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + cor0.col2 * + ( - col1 ) col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT - col2 * col1 * + col1 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT - - 54 * col2 FROM tab2 AS cor0
----
1404
1458
2052

query I rowsort
SELECT - tab0.col0 * ( 60 ) AS col0 FROM tab0
----
-1440
-2100
-5340

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

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

query I rowsort
SELECT ALL + 72 FROM tab1, tab2 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

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

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

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

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

query I rowsort
SELECT - 74 + col0 AS col0 FROM tab0 AS cor0
----
-39
-50
15

query I rowsort
SELECT 30 FROM tab0, tab2 AS cor0
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

query I rowsort
SELECT - + cor0.col1 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT ALL 34 + + col1 FROM tab2
----
51
65
93

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-346
SELECT DISTINCT + 45 + - col0 DIV col2 FROM tab0 cor0
----
10
44
45

skipif mysql # not compatible
query I rowsort label-346
SELECT DISTINCT + 45 + - col0 / col2 FROM tab0 cor0
----
10
44
45

query I rowsort
SELECT ALL col1 - 45 FROM tab0 AS cor0
----
41
46
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-348
SELECT ALL - 26 * col0 + - col1 DIV + 66 FROM tab1 AS cor0
----
-1664
-2080
-78

skipif mysql # not compatible
query I rowsort label-348
SELECT ALL - 26 * col0 + - col1 / + 66 FROM tab1 AS cor0
----
-1664
-2080
-78

query I rowsort
SELECT ALL - 29 * - col1 + - 54 FROM tab1 AS cor0
----
236
323
700

query I rowsort
SELECT ALL - 26 * 45 FROM tab1
----
-1170
-1170
-1170

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-352
SELECT ALL - cor0.col2 + + col2 DIV - 43 FROM tab2 cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-352
SELECT ALL - cor0.col2 + + col2 / - 43 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + 89 * - cor0.col1 + 87 FROM tab2 cor0
----
-1426
-2672
-5164

onlyif mysql # use DIV operator for integer division
query I rowsort label-354
SELECT DISTINCT + + cor0.col1 * col1 - col0 DIV + col0 AS col0 FROM tab1 AS cor0
----
168
675
99

skipif mysql # not compatible
query I rowsort label-354
SELECT DISTINCT + + cor0.col1 * col1 - col0 / + col0 AS col0 FROM tab1 AS cor0
----
168
675
99

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

query I rowsort
SELECT DISTINCT - + 5 * col2 + + 57 * + col1 + cor0.col1 FROM tab1 AS cor0
----
1238
274
295

query I rowsort
SELECT ALL - ( + col2 ) * ( + cor0.col2 * cor0.col1 ) - + col2 AS col1 FROM tab2 AS cor0
----
-22626
-24586
-39910

query I rowsort
SELECT ALL - col1 + + 22 * col1 AS col2 FROM tab0 AS cor0
----
1806
1911
2037

query I rowsort
SELECT col0 + col1 * - 48 FROM tab1 cor0
----
-1245
-416
-544

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

query I rowsort
SELECT col2 + col1 * cor0.col1 FROM tab0 cor0
----
7429
8363
9410

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

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

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

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

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

query I rowsort
SELECT cor0.col1 + col2 - col0 AS col2 FROM tab1 AS cor0
----
29
3
77

query I rowsort
SELECT - col1 + 65 + col2 FROM tab0 AS cor0
----
-31
12
56

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

query I rowsort
SELECT + col0 + 90 * + 61 AS col0 FROM tab0 AS cor0
----
5514
5525
5579

query I rowsort
SELECT ALL - col2 * col1 * 25 FROM tab0
----
-186550
-2425
-70950

query I rowsort
SELECT + tab2.col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

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

query I rowsort
SELECT + col1 + cor0.col0 - col2 AS col2 FROM tab0 AS cor0
----
131
77
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 55 * - col2 col0 FROM tab2 AS cor0
----
1430
1485
2090

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

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

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

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

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

query I rowsort
SELECT DISTINCT + + 51 * - col0 * col0 AS col0 FROM tab0 AS cor0
----
-29376
-403971
-62475

query I rowsort
SELECT ALL - 27 * col1 + - 67 AS col2 FROM tab0 cor0
----
-2389
-2524
-2686

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

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

query I rowsort
SELECT DISTINCT - - 62 * cor0.col0 FROM tab1 AS cor0
----
186
3968
4960

query I rowsort
SELECT ALL + - 23 + + col1 AS col0 FROM tab1 AS cor0
----
-10
-13
3

query I rowsort
SELECT col1 * - tab2.col1 + col1 * col0 AS col1 FROM tab2
----
-744
1054
1121

query I rowsort
SELECT DISTINCT tab1.col2 * col2 AS col1 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT + 20 * + tab2.col2 - - col1 AS col1 FROM tab2
----
571
579
777

query I rowsort
SELECT DISTINCT 3 + - col2 * 58 FROM tab0 AS cor0
----
-1911
-4753
-55

onlyif mysql # use DIV operator for integer division
query I rowsort label-387
SELECT ALL - col0 + col1 DIV col0 FROM tab0 AS cor0
----
-21
-33
-88

skipif mysql # not compatible
query I rowsort label-387
SELECT ALL - col0 + col1 / col0 FROM tab0 AS cor0
----
-21
-33
-88

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

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

query I rowsort
SELECT ALL + col1 * - 77 AS col0 FROM tab1
----
-1001
-2002
-770

query I rowsort
SELECT + + cor1.col1 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT ALL ( cor1.col1 ) - - cor0.col2 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to b266f8b689a93b61e6ea0be4166767f5

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

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

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

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

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

query I rowsort
SELECT DISTINCT - col0 + 14 FROM tab0
----
-10
-21
-75

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

query I rowsort
SELECT DISTINCT + 31 + - col0 FROM tab0 AS cor0
----
-4
-58
7

query I rowsort
SELECT + col2 * + cor0.col1 * + cor0.col1 + + col2 FROM tab0 AS cor0
----
244101
679124
9410

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 9 * + 27 + - cor0.col0 - col2 col2 FROM tab0 AS cor0
----
-279
-300
-414

query I rowsort
SELECT 51 + + 25 FROM tab2
----
76
76
76

query I rowsort
SELECT DISTINCT + col2 + + col0 + cor0.col0 AS col1 FROM tab2 AS cor0
----
182
196
41

query I rowsort
SELECT ( 76 ) + - col0 + col2 FROM tab0 AS cor0
----
42
69
85

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

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

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

query I rowsort
SELECT ALL - col1 * 9 * col2 AS col0 FROM tab1 AS cor0
----
-11232
-12636
-5130

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

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

query I rowsort
SELECT DISTINCT - + ( ( col0 ) ) * 97 FROM tab0 cor0
----
-2328
-3395
-8633

query I rowsort
SELECT DISTINCT - ( cor0.col0 ) + col2 - - 92 FROM tab1 AS cor0
----
108
143
85

query I rowsort
SELECT DISTINCT - 96 + cor0.col2 FROM tab2 cor0
----
-58
-69
-70

query I rowsort
SELECT DISTINCT - 96 * cor0.col2 FROM tab0 AS cor0
----
-3168
-7872
-96

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

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

query I rowsort
SELECT - 40 + - 77 AS col2 FROM tab2 AS cor0
----
-117
-117
-117

onlyif mysql # use DIV operator for integer division
query I rowsort label-420
SELECT ALL + CAST( - col1 AS SIGNED ) DIV - col1 + + col1 * + col1 FROM tab1 cor0
----
101
170
677

skipif mysql # not compatible
query I rowsort label-420
SELECT ALL + CAST ( - col1 AS INTEGER ) / - col1 + + col1 * + col1 FROM tab1 cor0
----
101
170
677

query I rowsort
SELECT + 9 + - cor0.col2 FROM tab2 AS cor0
----
-17
-18
-29

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

query I rowsort
SELECT ALL - col0 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
-128
-160
-6

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

query I rowsort
SELECT ALL 98 - - col1 AS col1 FROM tab1 AS cor0
----
108
111
124

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

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

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

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

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

query I rowsort
SELECT cor0.col0 * 53 - 67 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to d880f29aaf5c91844abd67bccfd9a252

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 * - 98 col0 FROM tab1 AS cor0
----
-1274
-2548
-980

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

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

query I rowsort
SELECT tab1.col0 + + 73 FROM tab1, tab0 AS cor0
----
9 values hashing to 0f57767cd84a75460a1ded6f4ec18d38

onlyif mysql # use DIV operator for integer division
query I rowsort label-435
SELECT col0 DIV - col1 + col2 AS col0 FROM tab1 AS cor0
----
51
54
90

skipif mysql # not compatible
query I rowsort label-435
SELECT col0 / - col1 + col2 AS col0 FROM tab1 AS cor0
----
51
54
90

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

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

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

query I rowsort
SELECT - + col0 + - 26 * + col2 * - col1 AS col1 FROM tab1 AS cor0
----
14756
32368
36501

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

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

query I rowsort
SELECT ALL col2 + 44 * + ( + cor0.col2 ) FROM tab1 AS cor0
----
2430
2565
4320

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - col1 * 43 * - tab2.col2 col2 FROM tab2
----
27857
35998
66040

query I rowsort
SELECT DISTINCT - 80 * col1 - + col2 FROM tab1 AS cor0
----
-1136
-2134
-857

query I rowsort
SELECT 7 + + col0 * + col1 FROM tab1 cor0
----
1047
647
85

query I rowsort
SELECT + 7 * - col2 + + col2 FROM tab2 AS cor0
----
-156
-162
-228

query I rowsort
SELECT - - col0 + - 95 AS col0 FROM tab0 AS cor0
----
-6
-60
-71

query I rowsort
SELECT - 75 FROM tab2, tab1 AS cor0
----
9 values hashing to 258bc565c64924d905a55eaaa6e57547

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

query I rowsort
SELECT + 60 AS col2 FROM tab1, tab0 AS cor0, tab2 cor1
----
27 values hashing to 1d2ab302ae60f95b15e68cf89083b162

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-452
SELECT ALL col1 DIV col1 + col2 * + col2 AS col0 FROM tab2
----
1445
677
730

skipif mysql # not compatible
query I rowsort label-452
SELECT ALL col1 / col1 + col2 * + col2 AS col0 FROM tab2
----
1445
677
730

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

query I rowsort
SELECT + col1 * 88 + + cor0.col2 * col0 FROM tab0 AS cor0
----
15306
8360
8571

query I rowsort
SELECT cor0.col1 * + cor0.col1 + col2 * - col2 AS col1 FROM tab0 AS cor0
----
1557
6307
9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-456
SELECT + col1 DIV - ( col2 ) + + col2 AS col0 FROM tab0 AS cor0
----
-96
31
81

skipif mysql # not compatible
query I rowsort label-456
SELECT + col1 / - ( col2 ) + + col2 AS col0 FROM tab0 AS cor0
----
-96
31
81

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor1.col1 + - 78 col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 015cc3c791bd32cb6814b297e7e4557f

query I rowsort
SELECT + + 16 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

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

query I rowsort
SELECT - col1 * 15 * + tab0.col2 AS col2 FROM tab0
----
-111930
-1455
-42570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-462
SELECT + + col2 * + ( - col2 ) + - col0 * - CAST( + 80 AS SIGNED ) * - col2 + col0 AS col1 FROM tab2 AS cor0
----
-15842
-162838
-241525

skipif mysql # not compatible
query I rowsort label-462
SELECT + + col2 * + ( - col2 ) + - col0 * - CAST ( + 80 AS INTEGER ) * - col2 + col0 AS col1 FROM tab2 AS cor0
----
-15842
-162838
-241525

query I rowsort
SELECT col2 * - 29 AS col1 FROM tab0 AS cor0
----
-2378
-29
-957

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

query I rowsort
SELECT - + col1 + col0 + - 26 AS col1 FROM tab0 AS cor0
----
-28
-88
-88

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-468
SELECT 21 DIV + col0 col0 FROM tab2
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-468
SELECT 21 / + col0 col0 FROM tab2
----
0
0
3

query I rowsort
SELECT ALL - + 99 * 84 AS col0 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 8c9128a84bd9b0d8f82c20350ed7e230

query I rowsort
SELECT - col2 * 0 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL - 23 + + col0 FROM tab2
----
-16
55
56

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

query I rowsort
SELECT DISTINCT - 97 + 22 FROM tab2 cor0
----
-75

query I rowsort
SELECT - 51 * col1 FROM tab1 AS cor0
----
-1326
-510
-663

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

query I rowsort
SELECT + + col1 * + col1 * - 32 + - ( + col0 ) FROM tab0 cor0
----
-236696
-265081
-301123

query I rowsort
SELECT - 59 * + col2 - + 73 AS col2 FROM tab0 AS cor0
----
-132
-2020
-4911

query I rowsort
SELECT - 95 + + col1 * col2 AS col0 FROM tab2 AS cor0
----
1439
551
742

onlyif mysql # use DIV operator for integer division
query I rowsort label-479
SELECT + + col1 * col2 DIV 13 + - ( col0 ) * + cor0.col2 AS col2 FROM tab0 AS cor0
----
-28
-574
-6724

skipif mysql # not compatible
query I rowsort label-479
SELECT + + col1 * col2 / 13 + - ( col0 ) * + cor0.col2 AS col2 FROM tab0 AS cor0
----
-28
-574
-6724

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

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

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

query I rowsort
SELECT + cor0.col2 * - col1 + - 42 FROM tab2 AS cor0
----
-1576
-688
-879

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

query I rowsort
SELECT 51 + + col1 AS col1 FROM tab2
----
110
68
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-486
SELECT DISTINCT + col2 * - col2 - - tab0.col1 DIV col0 AS col2 FROM tab0
----
-1086
-6723
1

skipif mysql # not compatible
query I rowsort label-486
SELECT DISTINCT + col2 * - col2 - - tab0.col1 / col0 AS col2 FROM tab0
----
-1086
-6723
1

query I rowsort
SELECT - 18 * + col0 - ( col0 ) AS col1 FROM tab2
----
-133
-1482
-1501

query I rowsort
SELECT DISTINCT + + col2 + - col2 * 70 * + col2 + col2 AS col2 FROM tab2 AS cor0
----
-101004
-47268
-50976

query I rowsort
SELECT - + 34 * col2 AS col1 FROM tab0 AS cor0
----
-1122
-2788
-34

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

query I rowsort
SELECT ALL - 29 FROM tab0, tab1 AS cor0
----
9 values hashing to 0cc9ddad93fc783055518ae4b6be054b

query I rowsort
SELECT DISTINCT col2 * cor0.col2 - + ( - col0 ) * col0 FROM tab0 AS cor0
----
1226
14645
1665

query I rowsort
SELECT col2 * 53 + col1 FROM tab1 AS cor0
----
2888
3031
5101

query I rowsort
SELECT ALL - - col2 + - 32 + col1 FROM tab0 cor0
----
141
66
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-495
SELECT ALL - col0 DIV - ( col0 ) + cor0.col2 AS col0 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-495
SELECT ALL - col0 / - ( col0 ) + cor0.col2 AS col0 FROM tab1 AS cor0
----
55
58
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-496
SELECT col1 DIV cor0.col1 - 16 FROM tab1 AS cor0
----
-15
-15
-15

skipif mysql # not compatible
query I rowsort label-496
SELECT col1 / cor0.col1 - 16 FROM tab1 AS cor0
----
-15
-15
-15

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

query I rowsort
SELECT ALL + - col1 * + 42 + cor0.col0 AS col2 FROM tab1 AS cor0
----
-1089
-356
-466

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 + 33 * tab1.col0 FROM tab1
----
2112
2640
99

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

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

query I rowsort
SELECT DISTINCT + + col2 + 80 + col0 AS col2 FROM tab1 AS cor0
----
137
201
256

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT 9 + 66 * cor0.col1 FROM tab0 cor0
----
5685
6015
6411

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

skipif mysql # not compatible
query I rowsort label-509
SELECT ALL - + ( ( - col2 ) ) / + col0 FROM tab0 AS cor0
----
0
0
1

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

query I rowsort
SELECT ( - 22 ) * + col2 FROM tab1 AS cor0
----
-1188
-1254
-2112

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

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

query I rowsort
SELECT 95 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

query I rowsort
SELECT - - 38 * - col0 AS col2 FROM tab1 AS cor0
----
-114
-2432
-3040

query I rowsort
SELECT DISTINCT + + 66 + col0 * col2 FROM tab1 AS cor0
----
228
3714
7746

onlyif mysql # use DIV operator for integer division
query I rowsort label-517
SELECT DISTINCT col0 DIV 88 col1 FROM tab0
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-517
SELECT DISTINCT col0 / 88 col1 FROM tab0
----
0
1

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

query I rowsort
SELECT ( - col0 + tab0.col2 ) * col1 FROM tab0
----
-3298
-637
774

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0, tab1 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to 1260d4dbe7a8d809e8010586a3c398c5

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

query I rowsort
SELECT DISTINCT + col1 * ( + cor0.col0 * col2 ) - 25 FROM tab1 AS cor0
----
36455
4187
99815

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-525
SELECT + col1 DIV + cor0.col0 + cor0.col2 col2 FROM tab2 AS cor0
----
26
31
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-525
SELECT + col1 / + cor0.col0 + cor0.col2 col2 FROM tab2 AS cor0
----
26
31
38

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT - 93 + col0 * - 31 FROM tab0 AS cor0
----
-1178
-2852
-837

query I rowsort
SELECT - + 43 + - col2 AS col0 FROM tab2 AS cor0
----
-69
-70
-81

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

query I rowsort
SELECT DISTINCT 74 * + col0 + col2 FROM tab1 AS cor0
----
276
4793
6016

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

query I rowsort
SELECT ALL + 70 AS col0 FROM tab2 cor0
----
70
70
70

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

query I rowsort
SELECT 60 + col0 * tab0.col2 FROM tab0
----
7358
852
95

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

skipif mysql # not compatible
query I rowsort label-539
SELECT ALL + col1 * CAST ( + col2 * - col2 + 71 AS INTEGER ) FROM tab0 AS cor0
----
-605423
-87548
6790

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

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

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

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-546
SELECT DISTINCT col0 - col1 DIV + col2 FROM tab0
----
-62
22
88

skipif mysql # not compatible
query I rowsort label-546
SELECT DISTINCT col0 - col1 / + col2 FROM tab0
----
-62
22
88

query I rowsort
SELECT DISTINCT + col2 - - col0 * - 56 AS col1 FROM tab0
----
-1311
-1959
-4902

query I rowsort
SELECT - - 75 AS col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

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

query I rowsort
SELECT + cor0.col0 * col0 + - col0 * - col1 * cor0.col1 - col1 FROM tab1 AS cor0
----
10486
19907
2011

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-551
SELECT DISTINCT - col0 * - CAST( - 67 AS SIGNED ) FROM tab0 AS cor0
----
-1608
-2345
-5963

skipif mysql # not compatible
query I rowsort label-551
SELECT DISTINCT - col0 * - CAST ( - 67 AS INTEGER ) FROM tab0 AS cor0
----
-1608
-2345
-5963

query I rowsort
SELECT ALL - col2 - + ( + 99 * col2 ) FROM tab2 cor0
----
-2600
-2700
-3800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col0 + + col2 * + col2 col0 FROM tab0
----
-34
1065
6635

query I rowsort
SELECT ALL + col0 + ( 96 ) * col1 AS col0 FROM tab0
----
8280
8825
9347

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

query I rowsort
SELECT - 42 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 56f86ff01cd96a3511acd46e0e811e27

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

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

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

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

query I rowsort
SELECT 42 FROM tab0, tab2 cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-562
SELECT - CAST( 39 AS SIGNED ) * col0 + - col0 FROM tab0 AS cor0
----
-1400
-3560
-960

skipif mysql # not compatible
query I rowsort label-562
SELECT - CAST ( 39 AS INTEGER ) * col0 + - col0 FROM tab0 AS cor0
----
-1400
-3560
-960

query I rowsort
SELECT + col2 + col0 * col2 AS col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT - + 35 * col0 + - col0 AS col0 FROM tab1 AS cor0
----
-108
-2304
-2880

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

skipif mysql # not compatible
query I rowsort label-565
SELECT - - CAST ( 20 AS INTEGER ) + + col1 - cor0.col1 FROM tab1 AS cor0
----
20
20
20

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

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

query I rowsort
SELECT ALL - col2 + col1 * + ( col1 ) * + tab1.col0 FROM tab1
----
13424
1974
6343

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

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

skipif mysql # not compatible
query I rowsort label-570
SELECT + + CAST ( + col0 AS INTEGER ) * col0 AS col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT 30 - col2 FROM tab2 AS cor0
----
-8
3
4

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-573
SELECT DISTINCT - col0 * cor0.col1 DIV - col1 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-573
SELECT DISTINCT - col0 * cor0.col1 / - col1 col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL 10 * cor0.col1 FROM tab2 AS cor0
----
170
310
590

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

query I rowsort
SELECT DISTINCT - 55 FROM tab2
----
-55

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

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

query I rowsort
SELECT ALL + 6 * - col2 + 5 * + col2 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-580
SELECT ALL - ( - col0 ) + CAST( + ( col2 ) AS SIGNED ) * - 65 col2 FROM tab0 AS cor0
----
-2121
-30
-5241

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-580
SELECT ALL - ( - col0 ) + CAST ( + ( col2 ) AS INTEGER ) * - 65 col2 FROM tab0 AS cor0
----
-2121
-30
-5241

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

query I rowsort
SELECT col2 + 78 AS col0 FROM tab1 AS cor0
----
132
135
174

onlyif mysql # use DIV operator for integer division
query I rowsort label-583
SELECT tab2.col2 * tab2.col1 DIV 24 FROM tab2
----
26
34
63

skipif mysql # not compatible
query I rowsort label-583
SELECT tab2.col2 * tab2.col1 / 24 FROM tab2
----
26
34
63

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-585
SELECT DISTINCT col1 DIV + 55 AS col2 FROM tab2
----
0
1

skipif mysql # not compatible
query I rowsort label-585
SELECT DISTINCT col1 / + 55 AS col2 FROM tab2
----
0
1

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

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

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

query I rowsort
SELECT - col1 * - 10 FROM tab0 AS cor0
----
860
910
970

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

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

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

query I rowsort
SELECT - 51 * cor0.col1 AS col2 FROM tab2 cor0
----
-1581
-3009
-867

query I rowsort
SELECT - col1 * col2 - + 20 FROM tab2 AS cor0
----
-1554
-666
-857

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

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

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

query I rowsort
SELECT DISTINCT - - col0 + + col2 + - 56 FROM tab2 AS cor0
----
-22
48
61

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

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

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

query I rowsort
SELECT 67 * + col2 * - 22 + + cor0.col1 + - col1 * col0 AS col0 FROM tab1 AS cor0
----
-142531
-79648
-84648

query I rowsort
SELECT + 78 - - col2 * col1 FROM tab1 AS cor0
----
1326
1482
648

query I rowsort
SELECT - col0 - - col1 * - col1 AS col1 FROM tab0 cor0
----
-7420
-8370
-9444

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

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

query I rowsort
SELECT cor1.col2 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

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

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

query I rowsort
SELECT - 13 FROM tab2, tab2 AS cor0
----
9 values hashing to e95f5f4bd0f480397cced5f5e8a23792

query I rowsort
SELECT ALL + 33 + - ( col2 + ( - col2 ) ) * + col1 FROM tab2
----
33
33
33

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-611
SELECT ALL CAST( col2 AS SIGNED ) FROM tab1
----
54
57
96

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

query I rowsort
SELECT 37 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

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

query I rowsort
SELECT - 2 AS col0 FROM tab2 AS cor0
----
-2
-2
-2

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

skipif mysql # not compatible
query I rowsort label-615
SELECT DISTINCT + + col0 / - col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT DISTINCT - 72 FROM tab2, tab2 cor0
----
-72

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

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

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

query I rowsort
SELECT 32 + col1 + col2 * 11 FROM tab2
----
360
377
467

onlyif mysql # use DIV operator for integer division
query I rowsort label-620
SELECT 48 * + col2 DIV ( col2 ) AS col2 FROM tab1
----
48
48
48

skipif mysql # not compatible
query I rowsort label-620
SELECT 48 * + col2 / ( col2 ) AS col2 FROM tab1
----
48
48
48

query I rowsort
SELECT ALL + col1 * - col0 - col0 FROM tab0
----
-2088
-3430
-8188

query I rowsort
SELECT DISTINCT - col1 + col1 * + col2 * - 83 - col2 FROM tab0
----
-235673
-619519
-8149

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

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

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

query I rowsort
SELECT 12 * col1 AS col1 FROM tab2 AS cor0
----
204
372
708

query I rowsort
SELECT + col2 + + ( col1 ) * + col1 AS col1 FROM tab2
----
327
3507
988

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + ( 68 ) col1 FROM tab0 cor0
----
101
150
69

query I rowsort
SELECT - + col2 * + col1 + 82 AS col1 FROM tab2 AS cor0
----
-1452
-564
-755

onlyif mysql # use DIV operator for integer division
query I rowsort label-631
SELECT ALL + col1 DIV - tab0.col2 + 93 FROM tab0
----
-4
91
92

skipif mysql # not compatible
query I rowsort label-631
SELECT ALL + col1 / - tab0.col2 + 93 FROM tab0
----
-4
91
92

query I rowsort
SELECT ALL + col1 + - 21 FROM tab0
----
65
70
76

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

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

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

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

query I rowsort
SELECT ALL + col1 * + ( + col2 * + 95 ) + - col2 AS col1 FROM tab1 AS cor0
----
118464
133326
54093

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

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

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

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

query I rowsort
SELECT 63 * cor0.col1 + + col0 AS col2 FROM tab0 AS cor0
----
5442
5822
6146

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

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

query I rowsort
SELECT + col2 + ( col2 ) + col0 * 62 FROM tab2 AS cor0
----
488
4888
4974

query I rowsort
SELECT ALL + + 87 AS col1 FROM tab1 AS cor0
----
87
87
87

query I rowsort
SELECT DISTINCT - tab1.col0 * 36 FROM tab1
----
-108
-2304
-2880

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + 3 col0 FROM tab1 AS cor0
----
57
60
99

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

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

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

query I rowsort
SELECT ALL + 29 * - col1 + - col0 FROM tab0 AS cor0
----
-2518
-2728
-2848

onlyif mysql # use DIV operator for integer division
query I rowsort label-652
SELECT - + 52 * 96 DIV - col2 FROM tab1 AS cor0
----
52
87
92

skipif mysql # not compatible
query I rowsort label-652
SELECT - + 52 * 96 / - col2 FROM tab1 AS cor0
----
52
87
92

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

query I rowsort
SELECT DISTINCT ( cor1.col1 ) AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
10
13
26

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-656
SELECT DISTINCT + cor0.col2 DIV col1 + col0 + ( col1 ) AS col2 FROM tab2 cor0
----
137
38
98

skipif mysql # not compatible
query I rowsort label-656
SELECT DISTINCT + cor0.col2 / col1 + col0 + ( col1 ) AS col2 FROM tab2 cor0
----
137
38
98

query I rowsort
SELECT - ( cor1.col1 ) FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col1 * + col2 * 22 col1 FROM tab0 AS cor0
----
164255
2231
62522

query I rowsort
SELECT - 20 FROM tab2 AS cor0
----
-20
-20
-20

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-661
SELECT DISTINCT - col1 * - col1 + CAST( - 13 AS SIGNED ) * tab0.col2 AS col1 FROM tab0
----
6967
7215
9396

skipif mysql # not compatible
query I rowsort label-661
SELECT DISTINCT - col1 * - col1 + CAST ( - 13 AS INTEGER ) * tab0.col2 AS col1 FROM tab0
----
6967
7215
9396

query I rowsort
SELECT DISTINCT col0 * col0 + col1 FROM tab0
----
1322
662
8012

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

query I rowsort
SELECT DISTINCT + col1 + 98 FROM tab0 AS cor0
----
184
189
195

onlyif mysql # use DIV operator for integer division
query I rowsort label-665
SELECT cor0.col0 DIV - 85 + ( col2 ) * - ( + cor0.col0 ) FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-665
SELECT cor0.col0 / - 85 + ( col2 ) * - ( + cor0.col0 ) FROM tab2 AS cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - 24 * - ( col2 ) col1 FROM tab0 AS cor0
----
2050
25
825

query I rowsort
SELECT DISTINCT - + col1 * col2 + col0 + - col2 FROM tab2 AS cor0
----
-1482
-605
-857

query I rowsort
SELECT DISTINCT col0 * - col0 + + ( col0 * - col2 ) - - col0 AS col1 FROM tab1 AS cor0
----
-14000
-168
-7680

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-670
SELECT ALL col0 DIV + ( + 53 + col1 ) FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-670
SELECT ALL col0 / + ( + 53 + col1 ) FROM tab1
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 + + col0 col2 FROM tab0 AS cor0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-672
SELECT ALL + col1 + cor0.col2 + 80 DIV col0 FROM tab0 AS cor0
----
100
122
173

skipif mysql # not compatible
query I rowsort label-672
SELECT ALL + col1 + cor0.col2 + 80 / col0 FROM tab0 AS cor0
----
100
122
173

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

query I rowsort
SELECT DISTINCT col2 * - col2 + + 13 * col2 AS col1 FROM tab1
----
-2214
-2508
-7968

query I rowsort
SELECT - col1 + - ( col1 + col1 ) FROM tab0 AS cor0
----
-258
-273
-291

query I rowsort
SELECT ALL 88 + col1 AS col2 FROM tab2
----
105
119
147

query I rowsort
SELECT + - col0 * - 87 + ( + col2 ) * col0 FROM tab2 AS cor0
----
798
8814
9875

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

skipif mysql # not compatible
query I rowsort label-678
SELECT DISTINCT + col2 + CAST ( col1 * + col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
2097
3396
8181

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

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

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

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

skipif mysql # not compatible
query I rowsort label-681
SELECT DISTINCT - col1 / CAST ( - col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
1
2
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-682
SELECT - col1 DIV + ( col1 ) + + col1 + + 5 FROM tab1 AS cor0
----
14
17
30

skipif mysql # not compatible
query I rowsort label-682
SELECT - col1 / + ( col1 ) + + col1 + + 5 FROM tab1 AS cor0
----
14
17
30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * ( - cor0.col1 ) + col0 col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-686
SELECT ALL ( - 58 ) DIV cor0.col1 AS col0 FROM tab2 AS cor0
----
-1
-3
0

skipif mysql # not compatible
query I rowsort label-686
SELECT ALL ( - 58 ) / cor0.col1 AS col0 FROM tab2 AS cor0
----
-1
-3
0

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

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

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

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

query I rowsort
SELECT ALL 84 * col2 FROM tab2
----
2184
2268
3192

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

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

query I rowsort
SELECT - col1 * 43 + + col2 AS col0 FROM tab1 AS cor0
----
-1064
-373
-463

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

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

query I rowsort
SELECT ALL - + col1 * - 36 - + col1 AS col1 FROM tab1 AS cor0
----
350
455
910

query I rowsort
SELECT - - 48 FROM tab2 AS cor0
----
48
48
48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( + col1 ) + - col0 * + 20 col2 FROM tab0 AS cor0
----
-1871
-566
-797

query I rowsort
SELECT DISTINCT - col2 * + col1 + col1 * + 35 AS col1 FROM tab2 AS cor0
----
-51
248
531

query I rowsort
SELECT + 78 * col0 FROM tab1 AS cor0
----
234
4992
6240

query I rowsort
SELECT ALL - + col0 + + col1 * cor0.col2 FROM tab2 AS cor0
----
1456
567
830

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

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

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

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

query I rowsort
SELECT DISTINCT + 92 + col1 AS col0 FROM tab2 AS cor0
----
109
123
151

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

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

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

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

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

query I rowsort
SELECT ALL + 96 * - col1 FROM tab1 AS cor0
----
-1248
-2496
-960

query I rowsort
SELECT ALL - 49 * col2 FROM tab1 AS cor0
----
-2646
-2793
-4704

query I rowsort
SELECT ALL - cor0.col2 + + col1 * 20 FROM tab0 AS cor0
----
1687
1738
1939

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

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

query I rowsort
SELECT ALL + col1 * col1 + col2 * col2 + - col0 AS col0 FROM tab2 AS cor0
----
1654
1683
4079

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

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

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

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

query I rowsort
SELECT ALL + 63 * + col0 + col1 * col1 AS col2 FROM tab2 AS cor0
----
1402
5266
8395

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 43 - col0 col1 FROM tab0
----
-46
19
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-722
SELECT ALL CAST( 58 AS SIGNED ) - tab0.col0 FROM tab0
----
-31
23
34

skipif mysql # not compatible
query I rowsort label-722
SELECT ALL CAST ( 58 AS INTEGER ) - tab0.col0 FROM tab0
----
-31
23
34

query I rowsort
SELECT DISTINCT - 60 * col2 AS col0 FROM tab1 AS cor0
----
-3240
-3420
-5760

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

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

skipif mysql # not compatible
query I rowsort label-725
SELECT DISTINCT - + 37 * - col2 * + CAST ( + col1 AS INTEGER ) FROM tab0 AS cor0
----
105006
276094
3589

query I rowsort
SELECT + + 17 * col2 FROM tab2 AS cor0
----
442
459
646

query I rowsort
SELECT DISTINCT + 1 * + col2 FROM tab2
----
26
27
38

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

query I rowsort
SELECT 13 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

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

query I rowsort
SELECT + 95 + col0 AS col0 FROM tab0 AS cor0
----
119
130
184

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

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

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

query I rowsort
SELECT DISTINCT cor1.col0 * - 49 * - 4 - cor1.col1 * + 35 AS col2 FROM tab0, tab0 cor0, tab1 AS cor1
----
-322
12194
15225

query I rowsort
SELECT + ( tab1.col1 ) AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT ( - ( - tab1.col0 ) ) AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * + col1 col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT cor1.col2 * + 85 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 8a6bbdecdd24b0062023f0f6c0cac73a

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

query I rowsort
SELECT DISTINCT - 18 + + col1 FROM tab2 AS cor0
----
-1
13
41

query I rowsort
SELECT ALL - 27 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 90b76caf54a4e48ee4a9784f52997a6a

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-748
SELECT + 30 * - col0 + cor0.col0 DIV + col2 FROM tab0 cor0
----
-1015
-2669
-720

skipif mysql # not compatible
query I rowsort label-748
SELECT + 30 * - col0 + cor0.col0 / + col2 FROM tab0 cor0
----
-1015
-2669
-720

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

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

query I rowsort
SELECT col2 + - cor0.col0 * - cor0.col0 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT DISTINCT col2 * + 70 + col1 FROM tab0 cor0
----
167
2396
5831

query I rowsort
SELECT ALL + 77 * - 90 FROM tab2 AS cor0
----
-6930
-6930
-6930

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

query I rowsort
SELECT - ( - 81 ) + col2 FROM tab0 cor0
----
114
163
82

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

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

query I rowsort
SELECT ALL 91 AS col2 FROM tab1, tab1 AS cor0 CROSS JOIN tab2, tab2 cor1
----
81 values hashing to 8a48d0ac75792561e233f0311a8872fd

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

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

query I rowsort
SELECT col2 + + 79 * col1 AS col1 FROM tab2 AS cor0
----
1381
2476
4687

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-763
SELECT DISTINCT + col0 * 65 - 68 DIV col1 AS col0 FROM tab1 AS cor0
----
193
4154
5195

skipif mysql # not compatible
query I rowsort label-763
SELECT DISTINCT + col0 * 65 - 68 / col1 AS col0 FROM tab1 AS cor0
----
193
4154
5195

skipif mysql # not compatible
query I rowsort
SELECT ALL - cor0.col2 + CAST ( col0 AS REAL ) AS col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT + 20 FROM tab0, tab2, tab1 cor0
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT + + 81 AS col0 FROM tab1, tab0, tab1 cor0
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT - + cor0.col2 + ( + ( cor0.col2 ) ) * col2 + col1 FROM tab1 AS cor0
----
2888
3202
9133

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

query I rowsort
SELECT + col1 * col1 + + 73 + - col0 AS col1 FROM tab2 AS cor0
----
1027
283
3476

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

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

query I rowsort
SELECT ALL ( col2 + + ( col1 ) * + col2 ) AS col1 FROM tab1
----
1344
1458
627

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

query I rowsort
SELECT 55 - - 48 FROM tab1, tab2 AS cor0
----
9 values hashing to a6436390b76d026d00c9c9e8c68d8420

query I rowsort
SELECT DISTINCT - - 64 AS col0 FROM tab0 AS cor0
----
64

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

skipif mysql # not compatible
query I rowsort label-776
SELECT CAST ( NULL AS REAL ) - - 49 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

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

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

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

query I rowsort
SELECT + col1 * + col0 + ( + col2 + + col2 ) FROM tab1
----
1232
186
754

query I rowsort
SELECT DISTINCT + col0 * 86 AS col0 FROM tab0
----
2064
3010
7654

query I rowsort
SELECT - - 83 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 002a717a3d902d97220759065fb107c3

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-783
SELECT 84 DIV + col0 FROM tab1
----
1
1
28

skipif mysql # not compatible
query I rowsort label-783
SELECT 84 / + col0 FROM tab1
----
1
1
28

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

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

query I rowsort
SELECT ALL - col2 + col0 * + col0 FROM tab0 AS cor0
----
1224
543
7839

onlyif mysql # use DIV operator for integer division
query I rowsort label-786
SELECT - 15 - - cor0.col0 DIV 52 FROM tab0 cor0
----
-14
-15
-15

skipif mysql # not compatible
query I rowsort label-786
SELECT - 15 - - cor0.col0 / 52 FROM tab0 cor0
----
-14
-15
-15

query I rowsort
SELECT DISTINCT - col0 + 83 * col0 - - 77 AS col0 FROM tab2
----
6473
651
6555

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1, tab2 cor0, tab1 AS cor1
----
972 values hashing to 4c0813b2179303fdf58f082d81d6d03c

onlyif mysql # use DIV operator for integer division
query I rowsort label-789
SELECT DISTINCT - col0 DIV tab2.col0 - col2 * 74 col2 FROM tab2
----
-1925
-1999
-2813

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-789
SELECT DISTINCT - col0 / tab2.col0 - col2 * 74 col2 FROM tab2
----
-1925
-1999
-2813

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

query I rowsort
SELECT DISTINCT col0 + + col2 + 25 AS col1 FROM tab2
----
129
142
59

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

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

query I rowsort
SELECT 7 * - col2 - col2 * + tab0.col2 FROM tab0
----
-1320
-7298
-8

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

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

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

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

query I rowsort
SELECT - - 67 * + col1 + + 27 + col2 FROM tab0 AS cor0
----
5822
6206
6527

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-799
SELECT + + ( 15 ) * + cor0.col1 + CAST( col1 * + col1 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
1066
250
364

skipif mysql # not compatible
query I rowsort label-799
SELECT + + ( 15 ) * + cor0.col1 + CAST ( col1 * + col1 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
1066
250
364

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

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

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

query I rowsort
SELECT + 24 * col0 + + col1 * - cor0.col1 * + 45 FROM tab2 cor0
----
-11109
-154773
-43077

onlyif mysql # use DIV operator for integer division
query I rowsort label-804
SELECT ALL - col2 DIV tab0.col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-804
SELECT ALL - col2 / tab0.col1 FROM tab0
----
0
0
0

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

query I rowsort
SELECT ALL - 7 + col0 AS col0 FROM tab1
----
-4
57
73

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-808
SELECT ALL col0 + - 88 DIV + col0 AS col2 FROM tab2
----
-5
77
78

skipif mysql # not compatible
query I rowsort label-808
SELECT ALL col0 + - 88 / + col0 AS col2 FROM tab2
----
-5
77
78

query I rowsort
SELECT ALL - 43 AS col0 FROM tab1 AS cor0
----
-43
-43
-43

query I rowsort
SELECT ALL + col2 + + 8 AS col0 FROM tab0 AS cor0
----
41
9
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-811
SELECT tab2.col1 DIV - col0 FROM tab2
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-811
SELECT tab2.col1 / - col0 FROM tab2
----
-4
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-812
SELECT ALL col0 * col2 DIV col0 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-812
SELECT ALL col0 * col2 / col0 FROM tab2
----
26
27
38

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

query I rowsort
SELECT - 70 * - col1 + ( + col2 ) AS col0 FROM tab0
----
6053
6452
6791

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1, tab2 AS cor0, tab0 AS cor1
----
972 values hashing to 58757c5bbbd4217c03cf2ac0b6126e55

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

query I rowsort
SELECT - 33 + + col0 FROM tab1
----
-30
31
47

query I rowsort
SELECT DISTINCT + 71 * - col2 + - col0 * + col1 AS col1 FROM tab2 AS cor0
----
-2134
-4041
-6448

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

query I rowsort
SELECT DISTINCT 2 * col2 + col2 AS col0 FROM tab0 AS cor0
----
246
3
99

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

query I rowsort
SELECT DISTINCT - - col1 * 31 * col0 FROM tab2 AS cor0
----
142662
41633
6727

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-825
SELECT ALL + col2 + - col0 DIV 78 FROM tab1 AS cor0
----
54
57
95

skipif mysql # not compatible
query I rowsort label-825
SELECT ALL + col2 + - col0 / 78 FROM tab1 AS cor0
----
54
57
95

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

query I rowsort
SELECT - col0 * ( + col0 * - col2 ) AS col0 FROM tab1 AS cor0
----
233472
486
614400

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

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

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col2 * + CAST ( + 56 AS REAL ) FROM tab1 AS cor0
----
-3024
-3192
-5376

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-833
SELECT DISTINCT + cor0.col0 DIV 32 + - col2 AS col1 FROM tab2 AS cor0
----
-24
-27
-36

skipif mysql # not compatible
query I rowsort label-833
SELECT DISTINCT + cor0.col0 / 32 + - col2 AS col1 FROM tab2 AS cor0
----
-24
-27
-36

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

skipif mysql # not compatible
query I rowsort label-834
SELECT DISTINCT + - col1 / - col1 AS col0 FROM tab2 AS cor0
----
1

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

query I rowsort
SELECT 1 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT - - col0 + + 24 AS col2 FROM tab0 AS cor0
----
113
48
59

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-840
SELECT - + cor0.col1 * col1 DIV col2 FROM tab1 AS cor0
----
-1
-1
-12

skipif mysql # not compatible
query I rowsort label-840
SELECT - + cor0.col1 * col1 / col2 FROM tab1 AS cor0
----
-1
-1
-12

query I rowsort
SELECT - 42 + ( - col1 ) * + col1 FROM tab2 cor0
----
-1003
-331
-3523

onlyif mysql # use DIV operator for integer division
query I rowsort label-842
SELECT - col1 DIV col0 + + 42 * col2 FROM tab1
----
2260
2394
4032

skipif mysql # not compatible
query I rowsort label-842
SELECT - col1 / col0 + + 42 * col2 FROM tab1
----
2260
2394
4032

onlyif mysql # use DIV operator for integer division
query I rowsort label-843
SELECT DISTINCT col0 DIV 98 AS col0 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-843
SELECT DISTINCT col0 / 98 AS col0 FROM tab2
----
0

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

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

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

query I rowsort
SELECT ALL col2 + + col1 * - cor0.col2 - + col0 FROM tab0 cor0
----
-131
-2829
-7469

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

query I rowsort
SELECT DISTINCT - 27 * + col1 + col2 FROM tab0 AS cor0
----
-2289
-2375
-2618

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

query I rowsort
SELECT DISTINCT - - 91 + - col0 * - 27 FROM tab0 AS cor0
----
1036
2494
739

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-853
SELECT col1 DIV - col1 + 62 FROM tab2 AS cor0
----
61
61
61

skipif mysql # not compatible
query I rowsort label-853
SELECT col1 / - col1 + 62 FROM tab2 AS cor0
----
61
61
61

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

skipif mysql # not compatible
query I rowsort label-854
SELECT - - cor0.col2 / ( + cor1.col2 ) FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 679109ec98464e08d806ca7bc5887fe1

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

query I rowsort
SELECT 33 * - col2 * + 50 - - col1 FROM tab0 cor0
----
-135209
-1553
-54364

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

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

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

query I rowsort
SELECT + col2 + col1 * - 59 FROM tab0 AS cor0
----
-5041
-5287
-5722

query I rowsort
SELECT - col2 + + col1 * + 67 * + col0 FROM tab0 AS cor0
----
138255
227464
542551

query I rowsort
SELECT 77 + col0 AS col2 FROM tab2 AS cor0
----
155
156
84

query I rowsort
SELECT DISTINCT + ( - cor0.col0 ) FROM tab2, tab2 AS cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-864
SELECT + tab1.col0 DIV - 81 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-864
SELECT + tab1.col0 / - 81 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + 88 AS col1 FROM tab1
----
88
88
88

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

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

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

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

query I rowsort
SELECT - - 60 + + cor0.col2 FROM tab2 AS cor0
----
86
87
98

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

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

query I rowsort
SELECT ALL - 13 * + col2 FROM tab2 AS cor0
----
-338
-351
-494

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

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

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

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

query I rowsort
SELECT + 13 FROM tab2, tab2 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

query I rowsort
SELECT ALL - ( col0 * + col0 ) + + 77 FROM tab1
----
-4019
-6323
68

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-881
SELECT + col2 + col2 DIV 7 AS col0 FROM tab2 AS cor0
----
29
30
43

skipif mysql # not compatible
query I rowsort label-881
SELECT + col2 + col2 / 7 AS col0 FROM tab2 AS cor0
----
29
30
43

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

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

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

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

query I rowsort
SELECT + col0 + + col1 * + col0 + - col0 * - col0 FROM tab0 AS cor0
----
16109
2664
4655

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 + - col2 + col2 * cor0.col2 col2 FROM tab1 AS cor0
----
2836
3182
9107

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

query I rowsort
SELECT col1 + 55 * + col2 AS col2 FROM tab1 AS cor0
----
2996
3145
5293

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

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

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

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

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

query I rowsort
SELECT 9 * - tab1.col1 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 2574cf6458d01677e1fbd386f422c352

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

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

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

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

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

query I rowsort
SELECT col2 + + 33 FROM tab1 AS cor0
----
129
87
90

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

query I rowsort
SELECT DISTINCT - col2 + col0 * col0 * + col1 FROM tab2 AS cor0
----
106059
1492
358930

query I rowsort
SELECT - 11 + - cor0.col0 AS col2 FROM tab0 cor0
----
-100
-35
-46

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( + col0 ) + cor0.col0 col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT DISTINCT 49 - - col1 * col2 AS col0 FROM tab0 AS cor0
----
146
2887
7511

query I rowsort
SELECT + col2 * - col2 + - col2 * col2 AS col1 FROM tab2 AS cor0
----
-1352
-1458
-2888

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

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

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

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

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

query I rowsort
SELECT DISTINCT 69 * 11 * - col0 FROM tab0 AS cor0
----
-18216
-26565
-67551

query I rowsort
SELECT DISTINCT + + ( + 2 ) + - col2 * 29 FROM tab0 cor0
----
-2376
-27
-955

query I rowsort
SELECT ALL - ( - col0 ) + + 8 * - cor0.col0 + col0 FROM tab1 AS cor0
----
-18
-384
-480

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

query I rowsort
SELECT DISTINCT col2 * col1 * + col0 + - 61 * col2 - - col1 AS col0 FROM tab1 AS cor0
----
33013
93997
944

query I rowsort
SELECT DISTINCT + 62 * - col2 + - 35 + col1 * + col0 FROM tab2 AS cor0
----
-1048
-1492
2955

query I rowsort
SELECT ALL + col1 * + col1 + + 99 * + 26 FROM tab1 cor0
----
2674
2743
3250

query I rowsort
SELECT ALL ( cor0.col2 ) + - 78 + col0 FROM tab0 AS cor0
----
-21
-42
93

query I rowsort
SELECT + 83 FROM tab2, tab1 AS cor0
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

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

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

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

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

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

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

query I rowsort
SELECT ALL col1 * - 84 FROM tab0 AS cor0
----
-7224
-7644
-8148

query I rowsort
SELECT DISTINCT + col2 * 26 AS col0 FROM tab2 AS cor0
----
676
702
988

query I rowsort
SELECT + col0 * 12 FROM tab2 cor0
----
84
936
948

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

skipif mysql # not compatible
query I rowsort label-926
SELECT + col2 / + 32 FROM tab0
----
0
1
2

query I rowsort
SELECT + col2 * + ( col1 ) * + col1 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT cor0.col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

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

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

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

query I rowsort
SELECT DISTINCT col1 * col2 * 8 - col0 * 50 FROM tab1
----
11082
1360
5984

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

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

query I rowsort
SELECT DISTINCT - 53 + - col2 FROM tab2 AS cor0
----
-79
-80
-91

query I rowsort
SELECT ALL + 39 + ( col1 ) * - cor0.col0 + - col1 FROM tab2 AS cor0
----
-1321
-209
-4622

query I rowsort
SELECT DISTINCT + 61 + 58 + - col0 FROM tab0 AS cor0
----
30
84
95

query I rowsort
SELECT ( + 31 ) * - cor0.col0 FROM tab2 cor0
----
-217
-2418
-2449

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

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

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

query I rowsort
SELECT col0 * + 28 * + 23 FROM tab0
----
15456
22540
57316

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - 36 col2 FROM tab0
----
-125
-60
-71

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

skipif mysql # not compatible
query I rowsort label-941
SELECT - col2 / ( - col0 ) FROM tab2
----
0
0
3

query I rowsort
SELECT DISTINCT col2 * col2 * - tab2.col2 - + col2 AS col0 FROM tab2
----
-17602
-19710
-54910

onlyif mysql # use DIV operator for integer division
query I rowsort label-943
SELECT DISTINCT + cor0.col1 DIV cor0.col1 FROM tab1 cor0
----
1

skipif mysql # not compatible
query I rowsort label-943
SELECT DISTINCT + cor0.col1 / cor0.col1 FROM tab1 cor0
----
1

query III rowsort
SELECT * FROM tab1 WHERE NULL NOT BETWEEN - col0 AND ( NULL )
----

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

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

skipif mysql # not compatible
query I rowsort label-946
SELECT DISTINCT col1 / - col1 FROM tab2 cor0
----
-1

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

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

query III rowsort
SELECT * FROM tab0 WHERE + col2 BETWEEN col2 AND ( col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-950
SELECT + col0 * col1 + col2 * - col0 DIV + col0 + col1 AS col1 FROM tab0
----
2117
3491
8108

skipif mysql # not compatible
query I rowsort label-950
SELECT + col0 * col1 + col2 * - col0 / + col0 + col1 AS col1 FROM tab0
----
2117
3491
8108

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

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

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

query III rowsort
SELECT * FROM tab1 WHERE NOT - col1 = col0 - col1
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

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

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

query III rowsort
SELECT ALL * FROM tab2 WHERE col1 < + col0
----
78
59
26
79
17
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-958
SELECT DISTINCT col2 + + col0 DIV - col2 FROM tab0
----
-34
33
81

skipif mysql # not compatible
query I rowsort label-958
SELECT DISTINCT col2 + + col0 / - col2 FROM tab0
----
-34
33
81

query I rowsort
SELECT col0 + - col0 * tab0.col0 * col1 + col1 * tab0.col2 AS col1 FROM tab0
----
-118693
-46674
-713260

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col2 col2 FROM tab0 WHERE NOT NULL BETWEEN NULL AND + col0 + - col0
----

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-964
SELECT col1 + + col0 + - cor0.col0 DIV - col0 AS col2 FROM tab1 AS cor0
----
30
75
94

skipif mysql # not compatible
query I rowsort label-964
SELECT col1 + + col0 + - cor0.col0 / - col0 AS col2 FROM tab1 AS cor0
----
30
75
94

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

query I rowsort
SELECT DISTINCT + col2 * - col2 * - col2 AS col1 FROM tab2 AS cor0
----
17576
19683
54872

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

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

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

query I rowsort
SELECT ALL - col2 * col1 + + col2 * + col2 AS col1 FROM tab1
----
1512
2679
7968

query I rowsort
SELECT DISTINCT - tab0.col1 * col0 + col2 * col1 FROM tab0
----
-3298
-637
774

onlyif mysql # use DIV operator for integer division
query I rowsort label-972
SELECT ALL col2 * col2 DIV col0 + tab2.col2 AS col1 FROM tab2
----
131
34
56

skipif mysql # not compatible
query I rowsort label-972
SELECT ALL col2 * col2 / col0 + tab2.col2 AS col1 FROM tab2
----
131
34
56

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 col2 FROM tab2 AS cor0 CROSS JOIN tab1
----
26
27
38

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-979
SELECT + 65 + + col2 DIV + col1 FROM tab0
----
65
65
65

skipif mysql # not compatible
query I rowsort label-979
SELECT + 65 + + col2 / + col1 FROM tab0
----
65
65
65

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

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

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

query I rowsort
SELECT DISTINCT - + 74 + col0 + col2 * col0 AS col0 FROM tab0 AS cor0
----
-4
7313
742

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col0 + + cor0.col0 col1 FROM tab1 AS cor0
----
138
173
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-984
SELECT DISTINCT col1 DIV + col1 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-984
SELECT DISTINCT col1 / + col1 FROM tab0
----
1

query I rowsort
SELECT + 98 FROM tab2, tab0 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT + col1 + + 94 AS col2 FROM tab1 AS cor0
----
104
107
120

query I rowsort
SELECT col0 + - col2 * col2 * + col2 AS col1 FROM tab0 cor0
----
-35913
-551279
34

query I rowsort
SELECT + - cor0.col1 + 23 * col0 FROM tab1 AS cor0
----
1462
1827
43

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-990
SELECT col2 DIV + col2 + tab1.col2 * - tab1.col0 AS col0 FROM tab1
----
-161
-3647
-7679

skipif mysql # not compatible
query I rowsort label-990
SELECT col2 / + col2 + tab1.col2 * - tab1.col0 AS col0 FROM tab1
----
-161
-3647
-7679

query I rowsort
SELECT ALL - col2 + - col2 AS col1 FROM tab2 WHERE NULL BETWEEN NULL AND ( col0 / col0 )
----

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-993
SELECT col1 DIV - col1 + col0 * col0 AS col2 FROM tab2
----
48
6083
6240

skipif mysql # not compatible
query I rowsort label-993
SELECT col1 / - col1 + col0 * col0 AS col2 FROM tab2
----
48
6083
6240

query I rowsort
SELECT DISTINCT col0 * + col1 * + col1 - - col0 FROM tab1
----
13600
2031
6464

query I rowsort
SELECT ALL col2 - - col1 AS col0 FROM tab0 WHERE NOT NULL NOT BETWEEN ( NULL ) AND ( col2 * col2 * - col2 )
----

query I rowsort
SELECT col1 * tab0.col1 * col2 + tab0.col2 AS col2 FROM tab0
----
244101
679124
9410

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

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

query I rowsort
SELECT tab1.col1 * + col1 - col1 * - col2 FROM tab1
----
1417
2080
670

query I rowsort
SELECT col0 / col0 + + col2 + + col0 FROM tab0 WHERE NOT NULL BETWEEN NULL AND ( + col1 )
----

query I rowsort
SELECT ALL col2 * - col0 + col0 * + col1 FROM tab1
----
-3008
-6640
-84

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

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

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

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

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

query I rowsort
SELECT tab1.col1 * col2 * tab1.col1 FROM tab1
----
16224
36504
5700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 * - col2 + + col0 col2 FROM tab0
----
-3360
-664029
-68088

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

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

query I rowsort
SELECT + - cor0.col2 + + cor0.col0 * - ( 71 ) AS col1 FROM tab0 AS cor0
----
-1737
-2486
-6401

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1013
SELECT - + col0 / col0 AS col2 FROM tab2 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + 25 col1 FROM tab2 cor0
----
51
52
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 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-1016
SELECT DISTINCT + + col2 * CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab2 AS cor0
----
NULL

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

query I rowsort
SELECT col1 * 96 * col1 AS col1 FROM tab0 AS cor0
----
710016
794976
903264

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

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

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

skipif mysql # not compatible
query I rowsort label-1020
SELECT ALL + col0 / + col0 FROM tab0
----
1
1
1

query I rowsort
SELECT ALL cor0.col0 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 col0 FROM tab2, tab2 AS cor0
----
26
27
38

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

query I rowsort
SELECT DISTINCT + cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
26
27
38

query I rowsort
SELECT - cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT + cor0.col0 + - 78 AS col0 FROM tab1 AS cor0
----
-14
-75
2

query I rowsort
SELECT col1 + - 18 * + col2 AS col0 FROM tab0
----
-1385
-508
79

query I rowsort
SELECT DISTINCT tab1.col0 + ( + 86 ) + col2 AS col1 FROM tab1
----
143
207
262

query IIIIIIIII rowsort
SELECT * FROM tab1 cor0 CROSS JOIN tab0, tab2 cor1
----
243 values hashing to 60bd71ee2159222231bb3b5819bc5dca

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1031
SELECT DISTINCT + col1 * 0 DIV - col1 AS col1 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-1031
SELECT DISTINCT + col1 * 0 / - col1 AS col1 FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1032
SELECT 30 * - col0 DIV - col0 AS col2 FROM tab2
----
30
30
30

skipif mysql # not compatible
query I rowsort label-1032
SELECT 30 * - col0 / - col0 AS col2 FROM tab2
----
30
30
30

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

query I rowsort
SELECT DISTINCT - 37 AS col0 FROM tab0 AS cor0
----
-37

query I rowsort
SELECT - col2 + cor0.col2 - 22 * 29 AS col1 FROM tab1 AS cor0
----
-638
-638
-638

query I rowsort
SELECT ALL - 68 AS col2 FROM tab1
----
-68
-68
-68

query I rowsort
SELECT + 64 + col1 + + col2 FROM tab1
----
131
144
173

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

query I rowsort
SELECT col2 * + col1 + col0 * + 59 + - col0 * tab2.col0 AS col2 FROM tab2
----
-934
1201
52

query I rowsort
SELECT ALL - tab0.col2 * - ( - cor0.col0 ) + tab0.col1 FROM tab0, tab0 cor0
----
9 values hashing to 746d22a16641a2c03beada37ebdb4cdf

query I rowsort
SELECT ALL col1 - - tab2.col2 FROM tab2
----
55
58
85

query I rowsort
SELECT DISTINCT 14 * tab0.col1 AS col2 FROM tab0
----
1204
1274
1358

query I rowsort
SELECT 62 - - col0 * ( 99 ) AS col1 FROM tab0
----
2438
3527
8873

query I rowsort
SELECT - 5 + + col1 * + col1 AS col0 FROM tab1 AS cor0
----
164
671
95

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

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

query I rowsort
SELECT ALL + 52 - col2 * col1 AS col1 FROM tab0
----
-2786
-45
-7410

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

query I rowsort
SELECT - 12 + - col0 FROM tab0 cor0
----
-101
-36
-47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 7 * + col0 + col2 col2 FROM tab1 AS cor0
----
505
656
75

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1051
SELECT DISTINCT - tab2.col1 DIV + col0 - + tab2.col1 AS col1 FROM tab2
----
-17
-35
-59

skipif mysql # not compatible
query I rowsort label-1051
SELECT DISTINCT - tab2.col1 / + col0 - + tab2.col1 AS col1 FROM tab2
----
-17
-35
-59

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

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

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

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

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

query I rowsort
SELECT ALL col1 * col1 + cor0.col2 * cor0.col0 AS col2 FROM tab1 cor0
----
3748
7849
838

query I rowsort
SELECT DISTINCT - col1 * col1 + col2 AS col2 FROM tab1 AS cor0
----
-43
-622
-73

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

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

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 cor0 WHERE NOT NULL NOT BETWEEN NULL AND cor0.col2
----

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

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

query I rowsort
SELECT ALL - - col0 * col2 + - cor0.col0 * + col1 AS col0 FROM tab0 AS cor0
----
-1272
-3360
-801

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

query I rowsort
SELECT DISTINCT 52 AS col2 FROM tab2
----
52

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1067
SELECT col0 DIV tab0.col0 + + col1 * - col2 col1 FROM tab0
----
-2837
-7461
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1067
SELECT col0 / tab0.col0 + + col1 * - col2 col1 FROM tab0
----
-2837
-7461
-96

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1069
SELECT DISTINCT + - cor0.col2 DIV 96 - - col2 AS col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1069
SELECT DISTINCT + - cor0.col2 / 96 - - col2 AS col2 FROM tab0 AS cor0
----
1
33
82

query IIIIII rowsort
SELECT ALL * FROM tab2, tab2 AS cor0 WHERE NOT ( NULL ) IN ( cor0.col1 )
----

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

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

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

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

query I rowsort
SELECT DISTINCT + col1 * - col0 + + cor0.col2 * - col2 + + col1 FROM tab2 AS cor0
----
-2770
-5219
-915

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

query I rowsort
SELECT DISTINCT + + 11 * col1 + + col2 AS col0 FROM tab1 AS cor0
----
167
239
340

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

query I rowsort
SELECT - col0 * - col2 + cor0.col2 FROM tab1 AS cor0
----
216
3705
7776

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

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

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

query I rowsort
SELECT DISTINCT 78 * + col0 FROM tab1 cor0
----
234
4992
6240

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col1 ) - - col2 col2 FROM tab2
----
55
58
85

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

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

query I rowsort
SELECT ALL + ( col0 ) * - col2 - + cor0.col2 * col0 * col2 AS col1 FROM tab1 AS cor0
----
-211584
-744960
-8910

query I rowsort
SELECT DISTINCT - 58 FROM tab1 AS cor0
----
-58

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

skipif mysql # not compatible
query I rowsort label-1089
SELECT DISTINCT ( 45 ) / - col2 + col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + col0 + - col2 * + col0 - 40 AS col2 FROM tab2 AS cor0
----
-1990
-222
-2963

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

query I rowsort
SELECT 68 * - 95 FROM tab1 AS cor0
----
-6460
-6460
-6460

query I rowsort
SELECT ALL - ( ( col1 ) ) + col2 * - col2 AS col0 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT col1 * + col2 + + col0 + + ( + 42 + cor0.col2 * + col0 ) FROM tab1 AS cor0
----
1611
4324
9050

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

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

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

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

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

query I rowsort
SELECT ALL - 93 + + col1 FROM tab2 AS cor0
----
-34
-62
-76

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

query I rowsort
SELECT + - 61 + col1 AS col1 FROM tab2 AS cor0
----
-2
-30
-44

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1104
SELECT ALL + col1 / col1 + ( col1 ) col1 FROM tab0 cor0
----
87
92
98

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

skipif mysql # not compatible
query I rowsort label-1105
SELECT - col1 * CAST ( NULL AS INTEGER ) * 61 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + - col1 + cor0.col1 AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + cor0.col2 + + 71 * 33 AS col0 FROM tab2 cor0
----
2369
2370
2381

query I rowsort
SELECT DISTINCT - + col1 + - 2 * - col2 + + col0 AS col2 FROM tab1 AS cor0
----
168
259
85

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

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

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

query I rowsort
SELECT + col1 * 98 AS col0 FROM tab2 AS cor0
----
1666
3038
5782

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

query I rowsort
SELECT + col0 + 4 AS col2 FROM tab2 AS cor0
----
11
82
83

query I rowsort
SELECT - - col0 * col1 + - col0 FROM tab1 cor0
----
576
75
960

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

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

query I rowsort
SELECT - col0 * - 45 FROM tab1
----
135
2880
3600

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

skipif mysql # not compatible
query I rowsort label-1119
SELECT ALL col1 / ( 69 ) + col1 FROM tab2
----
17
31
59

query I rowsort
SELECT 76 + + tab1.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to fecdcf462c7f2a6342efe29cc9190eba

query I rowsort
SELECT ALL - col2 + + 20 FROM tab1
----
-34
-37
-76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1122
SELECT DISTINCT + col1 + CAST( 98 AS SIGNED ) AS col0 FROM tab2
----
115
129
157

skipif mysql # not compatible
query I rowsort label-1122
SELECT DISTINCT + col1 + CAST ( 98 AS INTEGER ) AS col0 FROM tab2
----
115
129
157

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

query I rowsort
SELECT DISTINCT tab0.col0 + + 69 FROM tab0
----
104
158
93

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + col0 col0 FROM tab1
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-1127
SELECT ALL col0 * col1 + ( col2 + - 70 ) DIV 49 FROM tab2
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-1127
SELECT ALL col0 * col1 + ( col2 + - 70 ) / 49 FROM tab2
----
1343
217
4602

query I rowsort
SELECT - 78 + col0 - + col2 AS col2 FROM tab0 AS cor0
----
-44
-71
-87

query I rowsort
SELECT col1 * + 49 * col1 FROM tab0
----
362404
405769
461041

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

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

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

query I rowsort
SELECT cor0.col0 * cor0.col2 + 49 * 18 AS col1 FROM tab2 AS cor0
----
1071
2910
3884

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

query I rowsort
SELECT - 24 FROM tab1, tab1 AS cor0
----
9 values hashing to 797d0f7c145f8ac623924448c714bbcc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - 45 col0 FROM tab1
----
-135
-2880
-3600

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

query I rowsort
SELECT DISTINCT + 92 AS col0 FROM tab2, tab0, tab0 AS cor0, tab1
----
92

query I rowsort
SELECT + 4 + tab2.col1 AS col2 FROM tab2
----
21
35
63

query I rowsort
SELECT col1 * 21 AS col0 FROM tab2 cor0
----
1239
357
651

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

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

query I rowsort
SELECT - ( 93 ) AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1147
SELECT DISTINCT col0 DIV - col0 - ( - col1 ) FROM tab1
----
12
25
9

skipif mysql # not compatible
query I rowsort label-1147
SELECT DISTINCT col0 / - col0 - ( - col1 ) FROM tab1
----
12
25
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - tab2.col0 * col0 * + col2 + - col1 col1 FROM tab2
----
-1381
-158269
-237213

query I rowsort
SELECT - col2 * - col1 + - ( 65 ) FROM tab1 AS cor0
----
1183
1339
505

query I rowsort
SELECT col2 * col2 + tab2.col1 + - col2 FROM tab2
----
1423
709
733

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

query I rowsort
SELECT + 29 + - col1 * + col1 + col0 * col0 * 54 AS col0 FROM tab1
----
-161
221113
345460

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1156
SELECT - ( + col2 ) * CAST ( col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

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

query I rowsort
SELECT col1 * - col0 + col0 AS col1 FROM tab1 AS cor0
----
-576
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + 79 col0 FROM tab2 AS cor0
----
105
106
117

query I rowsort
SELECT DISTINCT + col0 + 31 AS col1 FROM tab1 AS cor0
----
111
34
95

query I rowsort
SELECT - - col0 + 18 AS col1 FROM tab2 AS cor0
----
25
96
97

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

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

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

query I rowsort
SELECT DISTINCT col0 * 56 FROM tab2 AS cor0
----
392
4368
4424

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

skipif mysql # not compatible
query I rowsort label-1166
SELECT ALL + cor0.col0 / + ( + 64 ) AS col0 FROM tab0 AS cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1167
SELECT + 82 DIV + col0 AS col2 FROM tab1
----
1
1
27

skipif mysql # not compatible
query I rowsort label-1167
SELECT + 82 / + col0 AS col2 FROM tab1
----
1
1
27

query I rowsort
SELECT col2 * col0 * ( 34 ) FROM tab0
----
1190
248132
26928

query I rowsort
SELECT - col2 * + ( + cor0.col2 ) + col0 * cor0.col2 FROM tab1 AS cor0
----
-1536
-2754
399

query I rowsort
SELECT DISTINCT - col0 * 75 + - col2 + + col2 FROM tab2 AS cor0
----
-525
-5850
-5925

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

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

query I rowsort
SELECT - - cor0.col0 * 55 AS col2 FROM tab1 cor0
----
165
3520
4400

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

query I rowsort
SELECT ALL + 54 * - ( + col1 ) FROM tab0 AS cor0
----
-4644
-4914
-5238

query I rowsort
SELECT DISTINCT - 52 + cor0.col0 FROM tab0 cor0
----
-17
-28
37

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

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

query I rowsort
SELECT DISTINCT - - col1 * col0 * col1 AS col2 FROM tab0 AS cor0
----
177504
329315
737009

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

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

query I rowsort
SELECT ALL 49 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

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

query I rowsort
SELECT + cor0.col2 * - cor1.col0 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 5ac8aba7baafe9bd6ceb7b5654f2c0b7

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

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

query I rowsort
SELECT ALL 28 * + col2 * - 54 + + col1 * col1 AS col0 FROM tab0 AS cor0
----
-115703
-42500
7897

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

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

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

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

query I rowsort
SELECT + - 70 * + col1 AS col0 FROM tab0 AS cor0
----
-6020
-6370
-6790

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1198
SELECT DISTINCT - + col2 + col2 * CAST( + 92 + + col1 AS SIGNED ) DIV - ( - ( col0 ) ) FROM tab1 AS cor0
----
2070
30
33

skipif mysql # not compatible
query I rowsort label-1198
SELECT DISTINCT - + col2 + col2 * CAST ( + 92 + + col1 AS INTEGER ) / - ( - ( col0 ) ) FROM tab1 AS cor0
----
2070
30
33

query I rowsort
SELECT ALL + col0 * col0 + - 3 AS col0 FROM tab1 AS cor0
----
4093
6
6397

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

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

query I rowsort
SELECT ALL 50 * + col0 * - 84 + + col0 FROM tab0 AS cor0
----
-100776
-146965
-373711

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

query I rowsort
SELECT ALL - 18 + + col2 FROM tab0 AS cor0
----
-17
15
64

query I rowsort
SELECT + 11 * col1 + col0 FROM tab1
----
174
223
289

query I rowsort
SELECT ALL - col1 - - col2 AS col0 FROM tab1
----
28
47
83

query I rowsort
SELECT + 64 * cor0.col2 FROM tab2 AS cor0
----
1664
1728
2432

query I rowsort
SELECT DISTINCT - tab0.col0 * 30 FROM tab0, tab0 AS cor0
----
-1050
-2670
-720

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

query I rowsort
SELECT DISTINCT 49 * - col2 FROM tab1 AS cor0
----
-2646
-2793
-4704

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1212
SELECT DISTINCT - col1 * col0 + - cor0.col2 DIV - col2 FROM tab1 AS cor0
----
-1039
-639
-77

skipif mysql # not compatible
query I rowsort label-1212
SELECT DISTINCT - col1 * col0 + - cor0.col2 / - col2 FROM tab1 AS cor0
----
-1039
-639
-77

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

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

query I rowsort
SELECT + 99 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

query I rowsort
SELECT DISTINCT - + 84 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
-84

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1218
SELECT ALL - CAST( - cor0.col1 AS SIGNED ) DIV - col0 col2 FROM tab2 AS cor0
----
-4
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1218
SELECT ALL - CAST ( - cor0.col1 AS INTEGER ) / - col0 col2 FROM tab2 AS cor0
----
-4
0
0

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

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

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

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

query I rowsort
SELECT DISTINCT - 89 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab0 AS cor2
----
-89

query I rowsort
SELECT + 39 + + 4 FROM tab0
----
43
43
43

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col1 ) col0 FROM tab2 AS cor0
----
-17
-31
-59

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * 33 col2 FROM tab2 AS cor0
----
-231
-2574
-2607

query I rowsort
SELECT ALL + 19 + col2 FROM tab2 AS cor0
----
45
46
57

query I rowsort
SELECT + + 71 * col0 FROM tab2 AS cor0
----
497
5538
5609

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

query I rowsort
SELECT - 46 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 491ad1fb79fec0b5715ea54949d1aa2d

query I rowsort
SELECT ALL cor0.col0 * 97 FROM tab1, tab2 AS cor0
----
9 values hashing to 680888a24a416fac4670ec8fb277d7c9

query I rowsort
SELECT ALL - cor0.col0 * col0 AS col2 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT - col1 * ( 83 ) FROM tab0
----
-7138
-7553
-8051

query I rowsort
SELECT DISTINCT tab1.col1 * + 28 * - tab1.col1 FROM tab1
----
-18928
-2800
-4732

query I rowsort
SELECT col2 + - col1 * 32 FROM tab1 AS cor0
----
-263
-320
-778

query I rowsort
SELECT DISTINCT + col0 * - 99 * col0 AS col0 FROM tab1 AS cor0
----
-405504
-633600
-891

query I rowsort
SELECT ALL - - col1 + + 81 AS col2 FROM tab2 AS cor0
----
112
140
98

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

query I rowsort
SELECT - col1 + ( - col0 ) * 29 AS col1 FROM tab2
----
-2308
-2321
-234

query I rowsort
SELECT col1 + + 29 FROM tab1
----
39
42
55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - col1 ) col1 FROM tab2
----
-17
-31
-59

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

query I rowsort
SELECT + ( col2 ) * + col1 + 30 AS col0 FROM tab2 cor0
----
1564
676
867

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

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

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

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

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0, tab0 cor0, tab1 cor1
----
972 values hashing to 9af67d6f98010464af5d560bf949d487

query I rowsort
SELECT + col1 * + 34 AS col0 FROM tab0 AS cor0
----
2924
3094
3298

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

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

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

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

query I rowsort
SELECT ALL - + col0 * col2 + + 40 FROM tab0 AS cor0
----
-7258
-752
5

query I rowsort
SELECT ALL + 87 AS col0 FROM tab2 AS cor0
----
87
87
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-1261
SELECT col2 + col1 DIV col1 AS col0 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-1261
SELECT col2 + col1 / col1 AS col0 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT DISTINCT 90 + + col2 * 3 FROM tab2 AS cor0
----
168
171
204

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1265
SELECT DISTINCT - 37 DIV + col0 AS col1 FROM tab2
----
-5
0

skipif mysql # not compatible
query I rowsort label-1265
SELECT DISTINCT - 37 / + col0 AS col1 FROM tab2
----
-5
0

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

query I rowsort
SELECT - - 54 - cor0.col2 AS col1 FROM tab2 AS cor0
----
16
27
28

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

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

query I rowsort
SELECT cor0.col0 * + cor0.col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 41d4c126bfd4bfab59ba5e83427c98e0

query I rowsort
SELECT + - 25 * col0 FROM tab1 cor0
----
-1600
-2000
-75

query I rowsort
SELECT DISTINCT + - 65 FROM tab2, tab2 AS cor0
----
-65

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

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

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

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

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

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

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

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

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

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

query I rowsort
SELECT ALL 35 * - col2 + - 15 FROM tab0
----
-1170
-2885
-50

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

query I rowsort
SELECT - + 73 * + col0 AS col2 FROM tab1 AS cor0
----
-219
-4672
-5840

query I rowsort
SELECT 30 * + col0 FROM tab2 AS cor0
----
210
2340
2370

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

query I rowsort
SELECT - 91 * - cor0.col2 FROM tab0 AS cor0
----
3003
7462
91

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

query I rowsort
SELECT col1 + - 98 AS col0 FROM tab0
----
-1
-12
-7

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

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

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

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

query I rowsort
SELECT ALL col0 * col0 - - col1 AS col0 FROM tab1 AS cor0
----
35
4106
6413

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

query I rowsort
SELECT col2 * + tab1.col0 + + 86 FROM tab1
----
248
3734
7766

query I rowsort
SELECT DISTINCT + cor0.col2 + 94 FROM tab1, tab0, tab1 AS cor0
----
148
151
190

query I rowsort
SELECT ALL col0 * + 96 * col2 FROM tab1
----
15552
350208
737280

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

query I rowsort
SELECT - + col2 * 74 FROM tab2 AS cor0
----
-1924
-1998
-2812

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

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

query I rowsort
SELECT - - 94 FROM tab1 AS cor0
----
94
94
94

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

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

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT - 17 + - col1 AS col0 FROM tab2 AS cor0
----
-34
-48
-76

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

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

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

query I rowsort
SELECT ALL 43 FROM tab1 AS cor0
----
43
43
43

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

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

query I rowsort
SELECT 85 * - cor0.col1 AS col2 FROM tab0 AS cor0
----
-7310
-7735
-8245

query I rowsort
SELECT + col0 + + col1 * - 10 AS col1 FROM tab1 cor0
----
-257
-36
-50

query I rowsort
SELECT + 98 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

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

query I rowsort
SELECT + + 23 + - col0 FROM tab2 AS cor0
----
-55
-56
16

query I rowsort
SELECT - 75 + + cor0.col0 FROM tab1 cor0
----
-11
-72
5

query I rowsort
SELECT - - col2 + col0 * 81 AS col2 FROM tab2 AS cor0
----
594
6344
6437

query I rowsort
SELECT + col2 + 4 AS col1 FROM tab0 AS cor0
----
37
5
86

query I rowsort
SELECT ALL - col0 + - cor0.col2 * - 25 AS col1 FROM tab1 AS cor0
----
1347
1361
2320

query I rowsort
SELECT DISTINCT - + cor0.col0 * - 79 FROM tab1 AS cor0
----
237
5056
6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - 93 col2 FROM tab1 AS cor0
----
-279
-5952
-7440

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

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

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

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

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

query I rowsort
SELECT ALL + col2 - 88 AS col1 FROM tab1 AS cor0
----
-31
-34
8

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

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

query I rowsort
SELECT DISTINCT - col0 * - 32 + col0 AS col2 FROM tab2 AS cor0
----
231
2574
2607

onlyif mysql # use DIV operator for integer division
query I rowsort label-1336
SELECT DISTINCT col2 + 7 DIV col0 FROM tab1 AS cor0
----
56
57
96

skipif mysql # not compatible
query I rowsort label-1336
SELECT DISTINCT col2 + 7 / col0 FROM tab1 AS cor0
----
56
57
96

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

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

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

query I rowsort
SELECT ALL - + cor0.col1 * - 22 FROM tab0 AS cor0
----
1892
2002
2134

query I rowsort
SELECT - tab2.col1 + tab2.col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

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

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

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

query I rowsort
SELECT DISTINCT cor0.col2 * 77 FROM tab2 AS cor0
----
2002
2079
2926

query I rowsort
SELECT ALL - col0 + - 84 FROM tab0 AS cor0
----
-108
-119
-173

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col1 * 94 + col2 col0 FROM tab1
----
15982
63598
9457

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

query I rowsort
SELECT ALL + ( + 76 ) * col2 + + col1 + col2 FROM tab2 AS cor0
----
2061
2110
2943

query I rowsort
SELECT DISTINCT 82 + 35 AS col0 FROM tab0, tab2 AS cor0
----
117

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

query I rowsort
SELECT ALL col2 * col0 + - col0 FROM tab0 cor0
----
0
7209
768

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 23 + col2 col1 FROM tab0 AS cor0
----
105
24
56

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

query I rowsort
SELECT ALL col2 * + 6 - - col0 FROM tab0
----
222
41
581

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

query I rowsort
SELECT - 3 FROM tab0, tab2 AS cor0
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

query I rowsort
SELECT ALL + tab1.col2 * - ( + col1 ) + 89 - ( tab1.col1 ) AS col1 FROM tab1
----
-1172
-1341
-491

query I rowsort
SELECT ALL - 0 + - col2 FROM tab0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col2 FROM tab2, tab0 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT DISTINCT - cor0.col0 * 75 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
-525
-5850
-5925

query I rowsort
SELECT 38 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

query I rowsort
SELECT DISTINCT col2 * + col1 + 72 FROM tab1
----
1320
1476
642

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

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

query I rowsort
SELECT - ( - 37 ) FROM tab0, tab2 AS cor0, tab1 cor1
----
27 values hashing to c023509f63faa044d654943e6df55ca2

query I rowsort
SELECT ALL 13 + cor0.col0 AS col1 FROM tab1 cor0
----
16
77
93

query I rowsort
SELECT + 98 + + col2 FROM tab0 AS cor0
----
131
180
99

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

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1374
SELECT DISTINCT + col1 + col2 DIV col1 FROM tab1 AS cor0
----
15
20
28

skipif mysql # not compatible
query I rowsort label-1374
SELECT DISTINCT + col1 + col2 / col1 FROM tab1 AS cor0
----
15
20
28

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

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

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

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) <= ( - col0 * col2 * + col1 + - col2 )
----

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

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE NOT ( + col1 ) NOT IN ( col2 + - col2 )
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE - col1 BETWEEN ( NULL ) AND tab2.col1 - + col1
----

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

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col2 * col1 col0 FROM tab0
----
3395
664118
68112

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

query I rowsort
SELECT ALL col1 * + col1 * + col0 FROM tab0
----
177504
329315
737009

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

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

query I rowsort
SELECT + 73 + col2 FROM tab0
----
106
155
74

query I rowsort
SELECT col0 * - col0 + + col1 * + col0 AS col0 FROM tab0
----
1488
178
2170

query I rowsort
SELECT DISTINCT + 13 * - col1 FROM tab2
----
-221
-403
-767

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

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

query I rowsort
SELECT - 22 AS col2 FROM tab0 AS cor0
----
-22
-22
-22

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

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

query I rowsort
SELECT ALL col0 + col2 + col2 AS col1 FROM tab2 AS cor0
----
130
155
61

query I rowsort
SELECT ALL tab1.col0 + col0 - + col0 FROM tab1 WHERE NOT ( NULL ) <> NULL
----

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

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

query I rowsort
SELECT col0 * col0 * cor0.col1 + col2 * col2 FROM tab0 cor0
----
118826
50625
727535

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE ( NULL ) <= NULL
----

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col2 / col0 col0 FROM tab2 WHERE NULL <> NULL
----

query I rowsort
SELECT - col1 * - col1 + col1 + col0 * col2 FROM tab1
----
3758
7862
864

query I rowsort
SELECT DISTINCT tab2.col1 * col0 * col0 AS col0 FROM tab2
----
106097
1519
358956

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT + col1 + + col0 > NULL
----

query I rowsort
SELECT DISTINCT - tab1.col1 * + tab1.col1 FROM tab1
----
-100
-169
-676

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

skipif mysql # not compatible
query I rowsort label-1412
SELECT - col2 + + col0 / + col2 + tab1.col2 FROM tab1
----
0
0
1

query I rowsort
SELECT col0 FROM tab1 WHERE col1 + col2 NOT BETWEEN + col0 AND NULL
----

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

query I rowsort
SELECT - col1 + col1 * + col1 * + col2 AS col0 FROM tab1
----
16211
36478
5690

onlyif mysql # use DIV operator for integer division
query I rowsort label-1416
SELECT - col0 - - col1 DIV col0 AS col1 FROM tab1
----
-64
-80
5

skipif mysql # not compatible
query I rowsort label-1416
SELECT - col0 - - col1 / col0 AS col1 FROM tab1
----
-64
-80
5

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

query I rowsort
SELECT 5 FROM tab1 cor0
----
5
5
5

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

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

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

query I rowsort
SELECT DISTINCT - 1 AS col0 FROM tab2 cor0
----
-1

query I rowsort
SELECT DISTINCT - - 4 * + col1 - col2 AS col0 FROM tab1 AS cor0
----
-17
-44
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * col1 col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT - 41 * + col2 AS col0 FROM tab1 cor0
----
-2214
-2337
-3936

query I rowsort
SELECT ALL ( col2 ) * col0 + + ( ( - col0 ) ) FROM tab2
----
182
1950
2923

query I rowsort
SELECT DISTINCT col1 + - cor0.col0 AS col0 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-1428
SELECT ALL + + col1 DIV - ( - col1 ) AS col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1428
SELECT ALL + + col1 / - ( - col1 ) AS col2 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT 25 * col2 * + 97 FROM tab2
----
63050
65475
92150

query I rowsort
SELECT + 55 + + tab0.col2 FROM tab0
----
137
56
88

query I rowsort
SELECT DISTINCT + tab0.col2 * col0 * tab0.col0 AS col1 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT 99 + + cor0.col1 * + col2 AS col0 FROM tab2 AS cor0
----
1633
745
936

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col1 + col1 col2 FROM tab2
----
1593
663
868

query I rowsort
SELECT - 22 * col1 + + col0 AS col2 FROM tab1
----
-156
-206
-569

onlyif mysql # use DIV operator for integer division
query I rowsort label-1435
SELECT + col2 DIV - tab0.col1 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1435
SELECT + col2 / - tab0.col1 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL + + 52 + + col0 FROM tab0 AS cor0
----
141
76
87

query I rowsort
SELECT - 83 * + col0 + - col1 * cor0.col2 AS col1 FROM tab2 AS cor0
----
-1418
-7203
-8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1438
SELECT DISTINCT - CAST( NULL AS DECIMAL ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1438
SELECT DISTINCT - CAST ( NULL AS REAL ) AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - 49 + col1 AS col2 FROM tab0 AS cor0
----
37
42
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1440
SELECT ALL CAST( NULL AS SIGNED ) * + 65 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1440
SELECT ALL CAST ( NULL AS INTEGER ) * + 65 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1441
SELECT DISTINCT + col2 * ( col1 ) - - col2 * CAST( - col1 AS SIGNED ) FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-1441
SELECT DISTINCT + col2 * ( col1 ) - - col2 * CAST ( - col1 AS INTEGER ) FROM tab2
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1442
SELECT ALL - col2 DIV 37 + + col1 col0 FROM tab2
----
16
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1442
SELECT ALL - col2 / 37 + + col1 col0 FROM tab2
----
16
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - 51 col1 FROM tab1
----
-153
-3264
-4080

query I rowsort
SELECT ALL - ( col1 ) + col0 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT + ( + col2 ) * col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT - + 52 * col1 FROM tab1 AS cor0
----
-1352
-520
-676

query I rowsort
SELECT DISTINCT col2 * + col2 + tab0.col1 FROM tab0
----
1175
6815
98

query I rowsort
SELECT DISTINCT 6 AS col1 FROM tab0, tab1 AS cor0
----
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1449
SELECT + - CAST( - col1 AS SIGNED ) + cor0.col1 AS col2 FROM tab1 AS cor0
----
20
26
52

skipif mysql # not compatible
query I rowsort label-1449
SELECT + - CAST ( - col1 AS INTEGER ) + cor0.col1 AS col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT - + col1 + 75 * col2 AS col1 FROM tab0 AS cor0
----
-22
2389
6059

query I rowsort
SELECT + - cor0.col2 + cor0.col1 AS col0 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - col1 + 56 FROM tab2 AS cor0
----
-3
25
39

query I rowsort
SELECT + - col1 + 41 * col0 AS col0 FROM tab1 AS cor0
----
2614
3267
97

query I rowsort
SELECT DISTINCT - - col1 * - col2 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - + cor0.col0 + + col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + - ( + 86 ) + - col2 * + col0 AS col1 FROM tab0 cor0
----
-121
-7384
-878

query I rowsort
SELECT + col1 * - col2 AS col1 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT cor0.col0 * cor0.col0 + + col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT ALL + col2 * 34 FROM tab1 AS cor0
----
1836
1938
3264

query I rowsort
SELECT ALL 96 + 17 + - col1 AS col1 FROM tab0
----
16
22
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - col1 + - col2 col1 FROM tab0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 52 col2 FROM tab1, tab0 cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT ALL - 13 + - col1 + + col2 * + col2 FROM tab0
----
-109
6620
990

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1464
SELECT + CAST( + col1 AS SIGNED ) AS col2 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-1464
SELECT + CAST ( + col1 AS INTEGER ) AS col2 FROM tab1
----
10
13
26

query I rowsort
SELECT - 8 + + col2 * + col0 FROM tab0
----
27
7290
784

query I rowsort
SELECT col1 * - col0 - col2 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT col0 * 12 + col2 FROM tab1
----
1056
825
90

query I rowsort
SELECT ALL - + ( - col1 ) + + col1 * cor0.col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT ALL + 88 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT + cor0.col1 * - ( cor0.col0 ) + - cor0.col2 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT ALL - + ( col1 ) + + col0 AS col1 FROM tab0 AS cor0
----
-2
-62
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1472
SELECT DISTINCT CAST( NULL AS DECIMAL ) + 92 * col2 AS col0 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1472
SELECT DISTINCT CAST ( NULL AS REAL ) + 92 * col2 AS col0 FROM tab2 cor0
----
NULL

query I rowsort
SELECT DISTINCT 82 AS col2 FROM tab0
----
82

query I rowsort
SELECT - 62 * col0 + + col0 + col2 FROM tab2 AS cor0
----
-400
-4732
-4781

query I rowsort
SELECT ALL - col0 + col2 * + cor0.col1 AS col2 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT - + cor0.col0 + + col0 + col0 AS col2 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT ALL + - 95 * + col2 AS col0 FROM tab2 AS cor0
----
-2470
-2565
-3610

query I rowsort
SELECT ALL + ( - cor0.col2 ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT 55 AS col0 FROM tab0 AS cor0
----
55
55
55

query I rowsort
SELECT DISTINCT tab2.col0 + + col0 * + col1 AS col1 FROM tab2
----
1422
224
4680

query I rowsort
SELECT 39 * - col0 * col0 AS col2 FROM tab0 AS cor0
----
-22464
-308919
-47775

query I rowsort
SELECT ALL + - 5 + col2 * - col0 FROM tab2 AS cor0
----
-194
-2033
-3007

query I rowsort
SELECT - + col0 * col2 * col2 + + col2 + col1 * col1 FROM tab0 cor0
----
-18707
-590073
9375

query I rowsort
SELECT 75 * - col2 AS col2 FROM tab2 AS cor0
----
-1950
-2025
-2850

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 32 * + col1 col1 FROM tab0 AS cor0
----
-2752
-2912
-3104

query I rowsort
SELECT ALL - 92 * col0 AS col0 FROM tab0 AS cor0
----
-2208
-3220
-8188

query I rowsort
SELECT DISTINCT + - col1 + + 2 FROM tab1 AS cor0
----
-11
-24
-8

query I rowsort
SELECT DISTINCT - col1 * - ( - ( + col1 ) ) + cor0.col0 * col1 FROM tab1 AS cor0
----
-598
540
871

query I rowsort
SELECT DISTINCT col0 + cor0.col2 * 92 * + col2 FROM tab2 AS cor0
----
132927
62270
67075

onlyif mysql # use DIV operator for integer division
query I rowsort label-1490
SELECT ALL - + col1 DIV - ( col0 ) FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-1490
SELECT ALL - + col1 / - ( col0 ) FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT DISTINCT - col0 * cor0.col0 + col1 AS col2 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT ALL + - col1 + - col2 AS col1 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1493
SELECT + - col2 * + CAST( - 53 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
2862
3021
5088

skipif mysql # not compatible
query I rowsort label-1493
SELECT + - col2 * + CAST ( - 53 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
2862
3021
5088

query I rowsort
SELECT ALL + + col1 + col1 - + ( col1 ) * col2 FROM tab0 AS cor0
----
-2666
-7280
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1495
SELECT ALL + col1 + + 51 DIV col2 AS col0 FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-1495
SELECT ALL + col1 + + 51 / col2 AS col0 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + + col2 * ( - col1 ) - col2 * col0 FROM tab0 AS cor0
----
-132
-14760
-3630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1497
SELECT + - col0 + CAST( - col2 AS SIGNED ) * - col1 AS col1 FROM tab2 AS cor0
----
1456
567
830

skipif mysql # not compatible
query I rowsort label-1497
SELECT + - col0 + CAST ( - col2 AS INTEGER ) * - col1 AS col1 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT ALL col0 * + 14 FROM tab2 AS cor0
----
1092
1106
98

query I rowsort
SELECT ALL + - col2 + col0 * col1 + col2 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - + col1 + - col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT - - col0 * + 76 FROM tab1 AS cor0
----
228
4864
6080

onlyif mysql # use DIV operator for integer division
query I rowsort label-1502
SELECT ALL col1 + ( col1 ) DIV col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-1502
SELECT ALL col1 + ( col1 ) / col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL col1 * ( 2 ) - cor0.col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1504
SELECT DISTINCT - - col1 DIV + col1 AS col1 FROM tab2 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-1504
SELECT DISTINCT - - col1 / + col1 AS col1 FROM tab2 AS cor0
----
1

query I rowsort
SELECT col0 + 18 FROM tab0 cor0
----
107
42
53

query I rowsort
SELECT DISTINCT - cor0.col1 + + col2 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT - col0 * col2 - col1 AS col0 FROM tab2 AS cor0
----
-2087
-220
-3019

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1508
SELECT - CAST( col1 AS SIGNED ) + col0 * col0 FROM tab0 cor0
----
1128
490
7830

skipif mysql # not compatible
query I rowsort label-1508
SELECT - CAST ( col1 AS INTEGER ) + col0 * col0 FROM tab0 cor0
----
1128
490
7830

query I rowsort
SELECT + + col1 * cor0.col0 + cor0.col1 + col2 * col1 AS col2 FROM tab2 AS cor0
----
1085
2006
6195

query I rowsort
SELECT DISTINCT col2 - + 23 FROM tab2
----
15
3
4

query I rowsort
SELECT DISTINCT cor1.col2 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
26
27
38

query I rowsort
SELECT ALL - col1 - - col0 FROM tab1
----
-23
54
67

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2 AS cor0 CROSS JOIN tab2, tab1 cor1, tab2 AS cor2
----
972 values hashing to caf6adb9936510208f5945a7e5c76f14

query I rowsort
SELECT DISTINCT + col2 * col2 * col2 + col0 FROM tab1 AS cor0
----
157467
185257
884816

query I rowsort
SELECT col0 + 46 FROM tab1 cor0
----
110
126
49

query I rowsort
SELECT DISTINCT col0 + + ( cor0.col1 ) AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL col1 + - cor0.col2 FROM tab2 AS cor0
----
-21
33
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * ( - col0 ) + col0 col1 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT DISTINCT + col2 * cor0.col0 AS col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - col2 + + cor0.col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col2 - 22 AS col1 FROM tab1 AS cor0
----
-118
-76
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col2 + col0 * cor0.col1 + col0 col1 FROM tab1 AS cor0
----
243
4352
8800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1523
SELECT + - col0 * CAST( NULL AS SIGNED ) + - cor0.col0 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1523
SELECT + - col0 * CAST ( NULL AS INTEGER ) + - cor0.col0 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col0 * + ( col0 ) + col2 AS col2 FROM tab2 AS cor0
----
6110
6279
76

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab0 AS cor1, tab1, tab2 cor2
----
3645 values hashing to df00d19f178a708f636b036dcb6c6f87

query I rowsort
SELECT 25 AS col0 FROM tab1 cor0
----
25
25
25

query I rowsort
SELECT ALL 56 FROM tab0, tab2 AS cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT ALL + cor0.col1 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT - col2 * cor0.col0 + + col0 AS col2 FROM tab1 cor0
----
-159
-3584
-7600

query I rowsort
SELECT cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT - ( + 87 ) FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 cor2
----
81 values hashing to edb5a8bbcb3204ac8254e54507073328

query I rowsort
SELECT ALL col0 - + col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT - 91 + + cor0.col2 FROM tab0 AS cor0
----
-58
-9
-90

query I rowsort
SELECT col2 + col2 * cor0.col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT 11 + - col1 * - 56 * col2 FROM tab0 AS cor0
----
158939
417883
5443

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0, tab1 AS cor1, tab2, tab2 AS cor2
----
3645 values hashing to c670882ff9ea3f0bb08fc55ec569be96

query I rowsort
SELECT DISTINCT col2 * cor0.col0 + + col0 * + 99 FROM tab2 AS cor0
----
10823
882
9750

onlyif mysql # use DIV operator for integer division
query I rowsort label-1538
SELECT + - col2 * + col0 DIV cor0.col0 + + col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1538
SELECT + - col2 * + col0 / cor0.col0 + + col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 + 46 AS col2 FROM tab1
----
56
59
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-1540
SELECT - - col2 * + col1 + cor0.col1 * cor0.col0 DIV cor0.col1 FROM tab1 AS cor0
----
1328
1407
634

skipif mysql # not compatible
query I rowsort label-1540
SELECT - - col2 * + col1 + cor0.col1 * cor0.col0 / cor0.col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT - - ( - col2 ) + col0 * 56 FROM tab0 AS cor0
----
1311
1959
4902

query I rowsort
SELECT ALL 99 FROM tab1, tab2 AS cor0, tab2, tab0 cor1
----
81 values hashing to c841a8d826151b422ecdb71db0250739

query I rowsort
SELECT - 39 + col2 FROM tab0
----
-38
-6
43

query I rowsort
SELECT ALL - + 74 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 5a477330c946251f814fbbfd08e77c28

query I rowsort
SELECT DISTINCT - 52 + cor0.col1 AS col0 FROM tab1, tab0, tab2 AS cor0
----
-21
-35
7

query I rowsort
SELECT col2 + 3 FROM tab1 AS cor0
----
57
60
99

query I rowsort
SELECT ALL - ( - col2 + col1 ) AS col0 FROM tab2
----
-33
-4
21

query I rowsort
SELECT + 80 * - col1 AS col1 FROM tab1
----
-1040
-2080
-800

query I rowsort
SELECT + col0 * + col1 + + col1 FROM tab1
----
104
1053
650

query I rowsort
SELECT col0 * col0 + + col0 AS col1 FROM tab2
----
56
6162
6320

query I rowsort
SELECT + + cor0.col2 FROM tab1, tab0, tab1 AS cor0, tab2
----
81 values hashing to 9d355f1f2edc347a359dad00d2d3f886

onlyif mysql # use DIV operator for integer division
query I rowsort label-1552
SELECT + - col2 + + 2 DIV + col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-1552
SELECT + - col2 + + 2 / + col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + cor1.col1 FROM tab2 cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT - col0 + ( - col1 + + col2 ) FROM tab0 cor0
----
-131
-77
-98

query I rowsort
SELECT col2 + - ( ( col1 ) ) * col2 * ( + col2 ) FROM tab2 AS cor0
----
-22572
-24510
-39858

query I rowsort
SELECT ALL - col0 + ( col2 ) FROM tab1
----
-7
16
51

query I rowsort
SELECT DISTINCT + - cor0.col1 AS col1 FROM tab0, tab2, tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT ALL - - cor0.col0 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL 88 FROM tab2 AS cor0
----
88
88
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1560
SELECT CAST( col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1560
SELECT CAST ( col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + ( col1 ) + - col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT + col1 + - cor0.col2 AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - - col0 * + col2 + col1 AS col2 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-1564
SELECT 62 DIV col1 - + ( cor0.col0 ) AS col1 FROM tab2 AS cor0
----
-5
-76
-77

skipif mysql # not compatible
query I rowsort label-1564
SELECT 62 / col1 - + ( cor0.col0 ) AS col1 FROM tab2 AS cor0
----
-5
-76
-77

query I rowsort
SELECT 88 - + cor0.col2 AS col2 FROM tab0 AS cor0
----
55
6
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1566
SELECT + CAST( NULL AS SIGNED ) * + tab2.col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1566
SELECT + CAST ( NULL AS INTEGER ) * + tab2.col0 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1567
SELECT + col2 + + col1 * CAST( + 37 AS SIGNED ) DIV + col1 FROM tab0 AS cor0
----
119
38
70

skipif mysql # not compatible
query I rowsort label-1567
SELECT + col2 + + col1 * CAST ( + 37 AS INTEGER ) / + col1 FROM tab0 AS cor0
----
119
38
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-1568
SELECT + col0 DIV - col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1568
SELECT + col0 / - col0 AS col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - col0 + col2 - + col1 * - 38 AS col1 FROM tab2 AS cor0
----
1198
2190
605

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 * - col2 + + col1 col0 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL 8 + - tab1.col2 FROM tab1
----
-46
-49
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( tab1.col2 ) + col1 * col1 col2 FROM tab1
----
157
265
730

query I rowsort
SELECT 50 FROM tab1 cor0
----
50
50
50

query I rowsort
SELECT 5 * col2 + - col0 AS col1 FROM tab1 AS cor0
----
221
267
400

query I rowsort
SELECT cor0.col2 + cor0.col0 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1576
SELECT DISTINCT + CAST( NULL AS SIGNED ) - col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1576
SELECT DISTINCT + CAST ( NULL AS INTEGER ) - col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1577
SELECT DISTINCT + 89 DIV 94 + - col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-1577
SELECT DISTINCT + 89 / 94 + - col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + ( col0 ) - col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - - col2 + - col0 * + col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-1580
SELECT ( col2 ) DIV + cor0.col1 + - 29 AS col0 FROM tab2 AS cor0
----
-27
-29
-29

skipif mysql # not compatible
query I rowsort label-1580
SELECT ( col2 ) / + cor0.col1 + - 29 AS col0 FROM tab2 AS cor0
----
-27
-29
-29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1581
SELECT ALL + 54 * col1 + + CAST( cor0.col2 + + col0 AS SIGNED ) FROM tab2 cor0
----
1035
1708
3290

skipif mysql # not compatible
query I rowsort label-1581
SELECT ALL + 54 * col1 + + CAST ( cor0.col2 + + col0 AS INTEGER ) FROM tab2 cor0
----
1035
1708
3290

query I rowsort
SELECT ALL - col1 + col0 * + col1 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT ALL + 54 + cor0.col1 FROM tab1 AS cor0
----
64
67
80

query I rowsort
SELECT DISTINCT col2 + col0 * col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT - cor0.col0 + cor0.col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + 8 * - col0 + col0 AS col0 FROM tab1 cor0
----
-21
-448
-560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 + + col2 col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + - col1 * 72 + cor0.col2 FROM tab1 AS cor0
----
-1818
-663
-840

query I rowsort
SELECT ALL col0 + ( col1 ) * col0 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL - col2 * - 73 AS col1 FROM tab0 cor0
----
2409
5986
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1591
SELECT DISTINCT col2 + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1591
SELECT DISTINCT col2 + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * ( - 56 ) col2 FROM tab0 AS cor0
----
-4816
-5096
-5432

query I rowsort
SELECT DISTINCT - col1 * ( 18 ) * + col2 FROM tab0 AS cor0
----
-134316
-1746
-51084

query I rowsort
SELECT ALL - - col1 * ( + col2 ) - - cor0.col2 AS col1 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1595
SELECT col1 + ( + col0 ) * col2 * + CAST( col2 AS SIGNED ) FROM tab1 AS cor0
----
207946
737293
8774

skipif mysql # not compatible
query I rowsort label-1595
SELECT col1 + ( + col0 ) * col2 * + CAST ( col2 AS INTEGER ) FROM tab1 AS cor0
----
207946
737293
8774

query I rowsort
SELECT ALL col1 - + 10 FROM tab1 AS cor0
----
0
16
3

query I rowsort
SELECT - cor0.col2 + ( col1 ) FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL + col2 * col0 * - col1 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT - 58 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to de0811e670e75d2aeeb657e32bddb0c0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1600
SELECT cor0.col1 * col1 + 87 * + col0 * - CAST( ( + col0 ) AS SIGNED ) + - cor0.col1 AS col1 FROM tab0 cor0
----
-42802
-680937
-97263

skipif mysql # not compatible
query I rowsort label-1600
SELECT cor0.col1 * col1 + 87 * + col0 * - CAST ( ( + col0 ) AS INTEGER ) + - cor0.col1 AS col1 FROM tab0 cor0
----
-42802
-680937
-97263

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1601
SELECT + cor0.col0 * - CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
-4096
-6400
-9

skipif mysql # not compatible
query I rowsort label-1601
SELECT + cor0.col0 * - CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT + col0 - - 35 AS col1 FROM tab1 AS cor0
----
115
38
99

query I rowsort
SELECT ALL col1 - - col2 AS col1 FROM tab1
----
109
67
80

query I rowsort
SELECT - tab0.col0 + col2 * col2 FROM tab0
----
-34
1065
6635

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + col0 col2 FROM tab0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1606
SELECT ALL + CAST( + col1 AS SIGNED ) * + col2 AS col1 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-1606
SELECT ALL + CAST ( + col1 AS INTEGER ) * + col2 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT col1 + + 23 FROM tab0 AS cor0
----
109
114
120

query I rowsort
SELECT DISTINCT - col2 + col0 * col1 - + col1 AS col0 FROM tab1
----
-2
573
931

query I rowsort
SELECT + + col0 + ( col1 ) * - ( + col1 ) - col0 AS col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ( 9 ) - + cor0.col1 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 60a8647ffef2047e2e1f2040a4e0dcbc

query I rowsort
SELECT DISTINCT col1 + + 81 - 61 FROM tab2
----
37
51
79

query I rowsort
SELECT DISTINCT + 55 FROM tab1, tab2 cor0
----
55

query I rowsort
SELECT ALL + col0 - - ( tab0.col1 ) FROM tab0
----
110
132
180

query I rowsort
SELECT col2 + col0 + - col0 FROM tab2
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1615
SELECT + CAST( col2 AS SIGNED ) + col1 col0 FROM tab1 cor0
----
109
67
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1615
SELECT + CAST ( col2 AS INTEGER ) + col1 col0 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT - 82 AS col0 FROM tab0, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to ce62f59690969f4492d78eb57c3181f0

query I rowsort
SELECT DISTINCT - col2 * + 84 * col2 AS col1 FROM tab2 AS cor0
----
-121296
-56784
-61236

query I rowsort
SELECT DISTINCT 47 + - cor0.col1 FROM tab1 cor0
----
21
34
37

query I rowsort
SELECT DISTINCT + - col0 * ( col2 ) AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT + - 30 * 29 AS col0 FROM tab0 AS cor0
----
-870

query I rowsort
SELECT ALL + - ( + col2 ) * col1 + col1 FROM tab1 cor0
----
-1235
-1378
-560

query I rowsort
SELECT ( ( col2 ) ) + 76 AS col0 FROM tab0 AS cor0
----
109
158
77

query I rowsort
SELECT DISTINCT - + 31 + col1 - col1 AS col2 FROM tab0 cor0
----
-31

query I rowsort
SELECT + - col1 * col1 * col1 + - 20 + col1 AS col2 FROM tab0 AS cor0
----
-635990
-753500
-912596

query I rowsort
SELECT ALL - 91 FROM tab2 cor0
----
-91
-91
-91

query I rowsort
SELECT DISTINCT + ( - 27 ) FROM tab0 AS cor0
----
-27

query I rowsort
SELECT 73 + cor0.col0 - + col2 * col1 AS col0 FROM tab2 AS cor0
----
-1383
-494
-757

query I rowsort
SELECT DISTINCT col2 * + col1 * - ( - col2 ) AS col1 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT DISTINCT ( col1 ) + - 57 FROM tab1 AS cor0
----
-31
-44
-47

query I rowsort
SELECT ALL + 56 * col1 - col0 FROM tab2 AS cor0
----
1729
3226
873

query I rowsort
SELECT ALL - + 73 AS col2 FROM tab2 cor0
----
-73
-73
-73

query I rowsort
SELECT DISTINCT - - ( + col2 ) + col1 * + 31 * - col0 AS col1 FROM tab1 AS cor0
----
-19783
-2364
-32144

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col2 col0 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - 38 AS col1 FROM tab0 AS cor0
----
-38

query I rowsort
SELECT ALL + - col0 - col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT DISTINCT - + col0 - col1 * ( - cor0.col2 ) AS col0 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT cor0.col1 * + cor0.col2 FROM tab0 cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 74 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 5a567947d14593676e3825756f8e6130

query I rowsort
SELECT + + col1 + - cor0.col1 * + col0 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT col1 * + ( col2 ) AS col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT 27 AS col1 FROM tab2
----
27

query I rowsort
SELECT - ( - cor0.col0 ) FROM tab2, tab1 AS cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + ( + col2 ) * col0 col0 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT DISTINCT + - col2 * 95 AS col2 FROM tab2 cor0
----
-2470
-2565
-3610

query I rowsort
SELECT ALL - col1 * + 19 AS col1 FROM tab0
----
-1634
-1729
-1843

query I rowsort
SELECT + - 91 AS col0 FROM tab0 AS cor0
----
-91
-91
-91

query I rowsort
SELECT DISTINCT - ( ( + col1 ) ) + + 70 FROM tab1 AS cor0
----
44
57
60

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 10 * col2 * col2 AS col0 FROM tab1
----
29160
32490
92160

query I rowsort
SELECT DISTINCT - col1 * col1 * col1 FROM tab2
----
-205379
-29791
-4913

query I rowsort
SELECT ALL 52 FROM tab1, tab0 AS cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 16 * + col1 ) col0 FROM tab0
----
1376
1456
1552

onlyif mysql # use DIV operator for integer division
query I rowsort label-1654
SELECT ALL + col0 * col1 DIV - col1 FROM tab2
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-1654
SELECT ALL + col0 * col1 / - col1 FROM tab2
----
-7
-78
-79

query I rowsort
SELECT + col0 + col0 * col2 + col2 FROM tab0 AS cor0
----
71
7469
849

query I rowsort
SELECT col2 * + cor0.col1 * col0 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT col0 * cor0.col1 + + 89 FROM tab1 AS cor0
----
1129
167
729

query I rowsort
SELECT + 92 * col1 FROM tab1 AS cor0
----
1196
2392
920

query I rowsort
SELECT - - 0 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL + 59 AS col2 FROM tab2 cor0 CROSS JOIN tab2 cor1
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT DISTINCT + col1 + cor0.col2 * col2 * col2 AS col2 FROM tab0 AS cor0
----
36023
551459
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + 41 col0 FROM tab2 AS cor0
----
67
68
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-1663
SELECT + col2 DIV - 5 - + col0 AS col1 FROM tab2 AS cor0
----
-12
-83
-86

skipif mysql # not compatible
query I rowsort label-1663
SELECT + col2 / - 5 - + col0 AS col1 FROM tab2 AS cor0
----
-12
-83
-86

query I rowsort
SELECT - col2 * col2 - - cor0.col2 AS col0 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT ALL + col2 + col2 * col2 AS col1 FROM tab2 AS cor0
----
1482
702
756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col0 + 70 col2 FROM tab2 cor0
----
2098
259
3072

query I rowsort
SELECT DISTINCT col2 * - 34 AS col0 FROM tab0 AS cor0
----
-1122
-2788
-34

query I rowsort
SELECT ALL - + cor0.col1 * ( - col0 * col0 ) + col0 * + col2 FROM tab2 AS cor0
----
109099
1708
360984

query I rowsort
SELECT + - col1 + + 95 + + col1 AS col0 FROM tab1 AS cor0
----
95
95
95

query I rowsort
SELECT - col0 * + col2 + col2 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT + - col0 * col2 + col2 * col1 AS col0 FROM tab0 AS cor0
----
164
2046
62

query I rowsort
SELECT - - col0 + - col1 FROM tab1 AS cor0
----
-23
54
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 col0 FROM tab2, tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT - col0 * + col2 + col1 * - cor0.col1 FROM tab0 AS cor0
----
-15579
-8188
-9444

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 AS cor2
----
972 values hashing to 89714dd446b7a97f8787d5744bdbf323

query I rowsort
SELECT DISTINCT - col0 * - col2 + - col2 AS col0 FROM tab1
----
108
3591
7584

query I rowsort
SELECT - 5 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 74665fbb47d5b17da011bca567195b21

onlyif mysql # use DIV operator for integer division
query I rowsort label-1678
SELECT + + ( + 82 ) * + col0 + + col1 * 74 DIV col1 AS col0 FROM tab2 AS cor0
----
6470
648
6552

skipif mysql # not compatible
query I rowsort label-1678
SELECT + + ( + 82 ) * + col0 + + col1 * 74 / col1 AS col0 FROM tab2 AS cor0
----
6470
648
6552

onlyif mysql # use DIV operator for integer division
query I rowsort label-1679
SELECT + ( - col0 ) DIV - col2 - col0 col2 FROM tab1 AS cor0
----
-3
-63
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1679
SELECT + ( - col0 ) / - col2 - col0 col2 FROM tab1 AS cor0
----
-3
-63
-80

query I rowsort
SELECT + ( - col0 ) - cor0.col1 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT 52 * 57 AS col0 FROM tab2 AS cor0
----
2964
2964
2964

query I rowsort
SELECT ALL 12 + + col0 FROM tab0 cor0
----
101
36
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1683
SELECT 14 + ( col0 ) * CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
1357
231
4616

skipif mysql # not compatible
query I rowsort label-1683
SELECT 14 + ( col0 ) * CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
1357
231
4616

query I rowsort
SELECT DISTINCT - 45 + col0 FROM tab1 AS cor0
----
-42
19
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-1685
SELECT DISTINCT + col0 DIV + 89 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-1685
SELECT DISTINCT + col0 / + 89 FROM tab0 AS cor0
----
0
1

query I rowsort
SELECT ALL col1 + 65 * - col1 FROM tab2 AS cor0
----
-1088
-1984
-3776

query I rowsort
SELECT - 30 AS col2 FROM tab0 AS cor0
----
-30
-30
-30

onlyif mysql # use DIV operator for integer division
query I rowsort label-1688
SELECT ALL + - 1 DIV + cor0.col1 - col2 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-1688
SELECT ALL + - 1 / + cor0.col1 - col2 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1689
SELECT DISTINCT - - col2 * 26 * col1 - ( col1 + + col1 ) * - CAST( NULL AS SIGNED ) col0 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1689
SELECT DISTINCT - - col2 * 26 * col1 - ( col1 + + col1 ) * - CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col2 * - ( col0 ) AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1691
SELECT + + CAST( NULL AS SIGNED ) - col1 * + col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1691
SELECT + + CAST ( NULL AS INTEGER ) - col1 * + col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( - cor0.col0 ) + - col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1693
SELECT 88 DIV 68 + - cor0.col2 * + ( ( - col1 ) ) AS col2 FROM tab2 AS cor0
----
1535
647
838

skipif mysql # not compatible
query I rowsort label-1693
SELECT 88 / 68 + - cor0.col2 * + ( ( - col1 ) ) AS col2 FROM tab2 AS cor0
----
1535
647
838

query I rowsort
SELECT DISTINCT + col0 + col1 * - col1 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT + col1 + col0 AS col2 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - ( col0 ) + col0 * + col1 FROM tab0 cor0
----
2040
3360
8010

query I rowsort
SELECT ALL 98 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c758e8afbdfa6aae279045b0e9cbacc2

query I rowsort
SELECT - cor0.col1 * col2 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - col1 * col2 + col0 * col2 AS col0 FROM tab2 AS cor0
----
-648
2356
494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 36 col0 FROM tab0, tab1 AS cor0, tab1, tab1 AS cor1
----
81 values hashing to aea3eb70e9270b660d4c81f39b11409b

onlyif mysql # use DIV operator for integer division
query I rowsort label-1701
SELECT DISTINCT + 98 * - 15 - col1 DIV col0 AS col2 FROM tab1
----
-1470
-1478

skipif mysql # not compatible
query I rowsort label-1701
SELECT DISTINCT + 98 * - 15 - col1 / col0 AS col2 FROM tab1
----
-1470
-1478

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab1 AS cor2
----
3645 values hashing to d8caf2ef7d9c405db0aec8c013a5107c

query I rowsort
SELECT cor1.col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1704
SELECT - + col1 * CAST( ( col1 ) + ( - col0 ) AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-598
540
871

skipif mysql # not compatible
query I rowsort label-1704
SELECT - + col1 * CAST ( ( col1 ) + ( - col0 ) AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-598
540
871

query I rowsort
SELECT DISTINCT - + 31 + + ( - cor0.col0 ) * cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to e534c11fd55bfdd4936b8e5190c05b59

onlyif mysql # use DIV operator for integer division
query I rowsort label-1706
SELECT DISTINCT col2 * col2 DIV + col1 + + col2 AS col1 FROM tab1 AS cor0
----
166
381
804

skipif mysql # not compatible
query I rowsort label-1706
SELECT DISTINCT col2 * col2 / + col1 + + col2 AS col1 FROM tab1 AS cor0
----
166
381
804

query I rowsort
SELECT DISTINCT + 34 AS col2 FROM tab0, tab2 AS cor0
----
34

query I rowsort
SELECT - 83 FROM tab0, tab1 AS cor0
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

query I rowsort
SELECT - col0 * - 88 * 74 AS col1 FROM tab1 AS cor0
----
19536
416768
520960

query I rowsort
SELECT + col0 + ( col1 ) * + col1 FROM tab2 AS cor0
----
3559
368
968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1711
SELECT + + CAST( NULL AS DECIMAL ) * + 12 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-1711
SELECT + + CAST ( NULL AS REAL ) * + 12 AS col2 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT tab2.col0 - col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT col1 + col2 - col2 AS col0 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT + col1 * - cor0.col2 + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) - - col2 col0 FROM tab2 cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-1716
SELECT DISTINCT - + col0 DIV + col2 + 82 DIV cor0.col2 AS col1 FROM tab1 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-1716
SELECT DISTINCT - + col0 / + col2 + 82 / cor0.col2 AS col1 FROM tab1 cor0
----
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1717
SELECT ALL - + col2 * + col1 + - 65 DIV col1 FROM tab1 AS cor0
----
-1253
-1406
-576

skipif mysql # not compatible
query I rowsort label-1717
SELECT ALL - + col2 * + col1 + - 65 / col1 FROM tab1 AS cor0
----
-1253
-1406
-576

query I rowsort
SELECT col0 * + col2 + cor0.col0 * + 44 * col2 AS col2 FROM tab0 AS cor0
----
1575
328410
35640

query I rowsort
SELECT DISTINCT 72 AS col2 FROM tab2 AS cor0
----
72

query I rowsort
SELECT + col1 + col1 * col0 FROM tab1
----
104
1053
650

query I rowsort
SELECT + - col1 + - col2 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT col0 + + col2 * - 63 * + col1 FROM tab1 cor0
----
-35846
-78544
-88449

query I rowsort
SELECT + col0 + col2 FROM tab0 cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col2 col1 FROM tab0, tab2 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * 43 + - cor0.col0 col0 FROM tab1 cor0
----
126
2688
3360

query I rowsort
SELECT - col0 + 97 FROM tab0 AS cor0
----
62
73
8

query I rowsort
SELECT - - col1 + + 36 FROM tab1 AS cor0
----
46
49
62

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-1729
SELECT ALL - + col2 DIV - 10 + - col2 FROM tab1 cor0
----
-49
-52
-87

skipif mysql # not compatible
query I rowsort label-1729
SELECT ALL - + col2 / - 10 + - col2 FROM tab1 cor0
----
-49
-52
-87

query I rowsort
SELECT ALL - + col2 * - 23 FROM tab1 AS cor0
----
1242
1311
2208

query I rowsort
SELECT + + col1 + - col2 * col1 - - col2 AS col1 FROM tab1 AS cor0
----
-1139
-1324
-503

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + 37 * + col0 * col1 col0 FROM tab0
----
125650
299752
76392

query I rowsort
SELECT + 96 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * 86 + cor0.col0 col1 FROM tab0 cor0
----
2088
3045
7743

query I rowsort
SELECT ALL - ( + 99 ) FROM tab2 cor0
----
-99
-99
-99

query I rowsort
SELECT DISTINCT 80 * - col2 * - col2 AS col2 FROM tab0 cor0
----
537920
80
87120

query I rowsort
SELECT + ( - cor0.col1 ) FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1738
SELECT + - CAST( 14 AS SIGNED ) FROM tab2 AS cor0
----
-14
-14
-14

skipif mysql # not compatible
query I rowsort label-1738
SELECT + - CAST ( 14 AS INTEGER ) FROM tab2 AS cor0
----
-14
-14
-14

query I rowsort
SELECT DISTINCT + + col2 + - col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL + 62 FROM tab2, tab1 AS cor0
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

query I rowsort
SELECT ALL - - 93 * col2 * + col2 FROM tab2 AS cor0
----
134292
62868
67797

query I rowsort
SELECT + - 92 * + col2 AS col1 FROM tab1 AS cor0
----
-4968
-5244
-8832

query I rowsort
SELECT ALL - 45 AS col0 FROM tab0 AS cor0
----
-45
-45
-45

query I rowsort
SELECT - col1 * + col0 * - 42 FROM tab0 cor0
----
142590
340158
86688

query I rowsort
SELECT ALL + + col2 AS col1 FROM tab1 cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + col0 * col0 col1 FROM tab2 AS cor0
----
6143
6258
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 51 col1 FROM tab0 cor0
----
51
51
51

query I rowsort
SELECT ALL - 92 + + col1 + cor0.col2 AS col0 FROM tab0 AS cor0
----
27
6
81

query I rowsort
SELECT ALL - col1 * col0 * - col1 + col0 FROM tab0 AS cor0
----
177528
329350
737098

query I rowsort
SELECT DISTINCT + + ( cor0.col2 ) * col2 AS col0 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL + col2 * + col0 + col1 + ( - col1 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL col0 + + col0 AS col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT DISTINCT - - col2 * col0 AS col0 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * col0 col0 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + col1 + + col2 * + col1 AS col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT + 38 * col0 FROM tab0 AS cor0
----
1330
3382
912

query I rowsort
SELECT DISTINCT + col1 * + col0 + + col1 * col2 FROM tab1 cor0
----
1210
1482
2288

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 81 col1 FROM tab2, tab0 cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT ALL tab0.col1 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ALL + 30 AS col2 FROM tab0
----
30
30
30

query I rowsort
SELECT + + 65 * + col2 + - col0 AS col1 FROM tab0 AS cor0
----
2121
30
5241

query I rowsort
SELECT ALL - + cor0.col1 * cor0.col0 AS col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL tab0.col2 AS col0 FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 7786718bd8042022537378d40ec87475

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1764
SELECT CAST( 34 AS SIGNED ) AS col0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

skipif mysql # not compatible
query I rowsort label-1764
SELECT CAST ( 34 AS INTEGER ) AS col0 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 4e2ca147a59e0d5661c28cf3e5431caa

onlyif mysql # use DIV operator for integer division
query I rowsort label-1765
SELECT col0 DIV - col1 + - col2 * - col0 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-1765
SELECT col0 / - col1 + - col2 * - col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT col2 * + col1 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT ALL - 51 AS col0 FROM tab2
----
-51
-51
-51

query I rowsort
SELECT 61 + col2 AS col2 FROM tab0
----
143
62
94

query I rowsort
SELECT DISTINCT + 83 + - 76 FROM tab0 AS cor0
----
7

query I rowsort
SELECT + col2 * + 94 + col0 * + 7 AS col0 FROM tab2 AS cor0
----
2587
2990
4125

query I rowsort
SELECT DISTINCT + col2 * 84 + col1 FROM tab2
----
2243
2299
3209

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1772
SELECT + CAST( + col2 AS SIGNED ) * + col0 FROM tab2 AS cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-1772
SELECT + CAST ( + col2 AS INTEGER ) * + col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL 62 * col1 * col2 + ( - 93 ) * + cor0.col2 + + col0 * 79 * + col0 AS col0 FROM tab1 AS cor0
----
353623
574048
82737

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1774
SELECT DISTINCT CAST( NULL AS SIGNED ) * + col0 + + col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1774
SELECT DISTINCT CAST ( NULL AS INTEGER ) * + col0 + + col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ( + cor0.col1 ) + - col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT DISTINCT + - ( col2 ) - - col2 * - 78 FROM tab2 AS cor0
----
-2054
-2133
-3002

query I rowsort
SELECT - - 33 * 8 FROM tab1 AS cor0
----
264
264
264

onlyif mysql # use DIV operator for integer division
query I rowsort label-1778
SELECT - col2 + - 41 DIV col2 FROM tab1 cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-1778
SELECT - col2 + - 41 / col2 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT + 49 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT ALL + tab1.col1 + 84 + + col1 FROM tab1
----
104
110
136

query I rowsort
SELECT - cor0.col0 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT DISTINCT col0 * col0 + - 25 FROM tab0
----
1200
551
7896

query I rowsort
SELECT ALL col2 + ( col2 ) AS col1 FROM tab2
----
52
54
76

query I rowsort
SELECT + 30 + 89 FROM tab1
----
119
119
119

query I rowsort
SELECT DISTINCT - + 90 FROM tab2 AS cor0
----
-90

query I rowsort
SELECT 97 + 28 * - col2 FROM tab2 cor0
----
-631
-659
-967

query I rowsort
SELECT ALL + - 40 FROM tab1 cor0
----
-40
-40
-40

query I rowsort
SELECT DISTINCT - 98 AS col0 FROM tab1 AS cor0
----
-98

query I rowsort
SELECT ALL 47 AS col1 FROM tab1 AS cor0
----
47
47
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col1 col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL col0 + - 88 AS col2 FROM tab2 AS cor0
----
-10
-81
-9

query I rowsort
SELECT - col1 + - 96 * - col2 FROM tab1 AS cor0
----
5158
5462
9203

query I rowsort
SELECT DISTINCT - 47 * - cor0.col1 * col2 FROM tab2 AS cor0
----
30362
39339
72098

query I rowsort
SELECT col1 + col0 AS col2 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT ALL - col0 * + col1 * col2 FROM tab1 cor0
----
-36480
-4212
-99840

query I rowsort
SELECT + + col0 + col0 * 9 AS col0 FROM tab0 AS cor0
----
240
350
890

query I rowsort
SELECT + + col1 * - col0 * col1 + col0 FROM tab1 AS cor0
----
-13440
-2025
-6336

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1798
SELECT + col0 * + CAST( NULL AS SIGNED ) + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1798
SELECT + col0 * + CAST ( NULL AS INTEGER ) + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + 33 FROM tab2 cor0
----
59
60
71

query I rowsort
SELECT DISTINCT cor0.col2 FROM tab2, tab2 AS cor0, tab0 cor1
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-1801
SELECT ALL col0 DIV ( + col0 ) FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1801
SELECT ALL col0 / ( + col0 ) FROM tab0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1802
SELECT ALL ( cor0.col2 ) + + col0 DIV ( 33 ) FROM tab2 AS cor0
----
27
28
40

skipif mysql # not compatible
query I rowsort label-1802
SELECT ALL ( cor0.col2 ) + + col0 / ( 33 ) FROM tab2 AS cor0
----
27
28
40

query I rowsort
SELECT - + ( + col1 ) + col2 FROM tab2 AS cor0
----
-33
-4
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1804
SELECT DISTINCT CAST( NULL AS DECIMAL ) * col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1804
SELECT DISTINCT CAST ( NULL AS REAL ) * col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + + col0 * 35 * cor0.col1 AS col0 FROM tab2 AS cor0
----
161070
47005
7595

query I rowsort
SELECT 64 AS col2 FROM tab0
----
64
64
64

query I rowsort
SELECT ALL + - cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT 15 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-1200
-45
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-1809
SELECT col2 * col1 DIV + tab0.col2 AS col0 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-1809
SELECT col2 * col1 / + tab0.col2 AS col0 FROM tab0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1810
SELECT - + cor0.col2 * cor0.col2 * - CAST( col2 * - cor0.col0 AS SIGNED ) FROM tab2 AS cor0
----
-1370928
-137781
-4334888

skipif mysql # not compatible
query I rowsort label-1810
SELECT - + cor0.col2 * cor0.col2 * - CAST ( col2 * - cor0.col0 AS INTEGER ) FROM tab2 AS cor0
----
-1370928
-137781
-4334888

onlyif mysql # use DIV operator for integer division
query I rowsort label-1811
SELECT + ( + col1 ) DIV + 63 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1811
SELECT + ( + col1 ) / + 63 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 + - col1 + ( + col2 ) FROM tab2 cor0
----
-35
-92
4

query I rowsort
SELECT DISTINCT tab0.col2 * tab0.col1 AS col0 FROM tab0
----
2838
7462
97

query I rowsort
SELECT 72 AS col0 FROM tab1
----
72
72
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-1815
SELECT DISTINCT col0 DIV col2 col1 FROM tab1
----
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1815
SELECT DISTINCT col0 / col2 col1 FROM tab1
----
0
1

query I rowsort
SELECT ALL + + 48 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT ALL - 11 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 05cc989122d7724c7abefaba9625ef3d

onlyif mysql # use DIV operator for integer division
query I rowsort label-1818
SELECT + + col2 + + col0 DIV - col0 AS col0 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-1818
SELECT + + col2 + + col0 / - col0 AS col0 FROM tab0 AS cor0
----
0
32
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + 49 * - col1 * col0 col1 FROM tab2 AS cor0
----
-10602
-225439
-65790

query I rowsort
SELECT - col0 * col0 - cor0.col1 AS col0 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT DISTINCT - 0 AS col2 FROM tab2
----
0

query I rowsort
SELECT ALL + 56 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to b5ba4b44e3deadce1edb30e76df61200

query I rowsort
SELECT DISTINCT col2 + + col1 + col0 * - col0 FROM tab0 AS cor0
----
-1127
-457
-7748

query I rowsort
SELECT - 24 * + col0 FROM tab2 AS cor0
----
-168
-1872
-1896

query I rowsort
SELECT ALL 46 * - col1 + + col1 AS col2 FROM tab2
----
-1395
-2655
-765

query I rowsort
SELECT + + col1 + 91 AS col1 FROM tab0 cor0
----
177
182
188

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1827
SELECT + + CAST( col0 AS SIGNED ) * + col1 FROM tab1 AS cor0
----
1040
640
78

skipif mysql # not compatible
query I rowsort label-1827
SELECT + + CAST ( col0 AS INTEGER ) * + col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT 88 AS col2 FROM tab1 cor0
----
88
88
88

query I rowsort
SELECT + 33 AS col0 FROM tab0 cor0
----
33
33
33

query I rowsort
SELECT ( + 48 ) + - col1 AS col2 FROM tab1 AS cor0
----
22
35
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col0 + + col1 * 31 col0 FROM tab0 AS cor0
----
2690
2910
3042

query I rowsort
SELECT DISTINCT - - 47 * col0 FROM tab0 AS cor0
----
1128
1645
4183

query I rowsort
SELECT DISTINCT - col2 * col1 + + ( - col2 ) + col1 AS col0 FROM tab1 AS cor0
----
-1331
-1432
-617

query I rowsort
SELECT + col1 * - col2 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT + + 53 AS col0 FROM tab0 cor0
----
53
53
53

query I rowsort
SELECT DISTINCT - 37 * col1 AS col1 FROM tab2 AS cor0
----
-1147
-2183
-629

query I rowsort
SELECT ALL - ( - tab2.col2 * - col1 ) AS col1 FROM tab2
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 75 * + col0 + col1 col2 FROM tab0 AS cor0
----
1886
2722
6766

query I rowsort
SELECT + 99 + col2 AS col1 FROM tab1 cor0
----
153
156
195

query I rowsort
SELECT ALL col0 - 65 FROM tab1 AS cor0
----
-1
-62
15

query I rowsort
SELECT - - 29 * 0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 81 * col2 + - col1 + - col0 FROM tab0 AS cor0
----
-51
2563
6462

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab1, tab1 AS cor1, tab2 AS cor2, tab2 AS cor3
----
3645 values hashing to 5a114c3d024b82b28eeddb04849c8215

query I rowsort
SELECT + ( ( col0 ) * col2 ) + + col0 FROM tab2
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-1845
SELECT col0 + col0 DIV col0 + col1 AS col1 FROM tab1
----
30
75
94

skipif mysql # not compatible
query I rowsort label-1845
SELECT col0 + col0 / col0 + col1 AS col1 FROM tab1
----
30
75
94

query I rowsort
SELECT ALL + tab1.col1 + + col1 AS col1 FROM tab1
----
20
26
52

query I rowsort
SELECT DISTINCT ( - 6 ) - - col2 * - col0 AS col1 FROM tab2
----
-195
-2034
-3008

query I rowsort
SELECT + 36 * col1 FROM tab1
----
360
468
936

query I rowsort
SELECT ALL + ( + 31 ) + col2 * - col1 * + col0 AS col1 FROM tab0
----
-3364
-664087
-68081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1850
SELECT CAST( + col1 AS SIGNED ) + - col1 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
110
182
702

skipif mysql # not compatible
query I rowsort label-1850
SELECT CAST ( + col1 AS INTEGER ) + - col1 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT - col0 + ( col2 ) * col0 * col0 FROM tab0 AS cor0
----
1190
18984
649433

query I rowsort
SELECT 94 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to b0ffb7527f4fbf44f30945e1ccb58c24

query I rowsort
SELECT + cor0.col1 * - cor0.col0 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 9b23e5e74ef3405a4dbf05cceb18c8a8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1854
SELECT - + CAST( col0 AS SIGNED ) * col1 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-1854
SELECT - + CAST ( col0 AS INTEGER ) * col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT 6 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * 79 col1 FROM tab1 AS cor0
----
4266
4503
7584

query I rowsort
SELECT DISTINCT col0 * + 54 FROM tab0 AS cor0
----
1296
1890
4806

query I rowsort
SELECT ALL - ( - col0 ) * + col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT 70 AS col1 FROM tab0 cor0
----
70
70
70

query I rowsort
SELECT ALL + ( 44 ) FROM tab2 AS cor0
----
44
44
44

query I rowsort
SELECT ALL + ( col0 ) + + 11 FROM tab2
----
18
89
90

query I rowsort
SELECT 95 * + col0 FROM tab0
----
2280
3325
8455

onlyif mysql # use DIV operator for integer division
query I rowsort label-1863
SELECT DISTINCT + col2 DIV col1 + - 64 * + ( - col1 ) AS col1 FROM tab2
----
1090
1984
3776

skipif mysql # not compatible
query I rowsort label-1863
SELECT DISTINCT + col2 / col1 + - 64 * + ( - col1 ) AS col1 FROM tab2
----
1090
1984
3776

query I rowsort
SELECT + - col1 * + col0 + 54 AS col1 FROM tab0 AS cor0
----
-2010
-3341
-8045

query I rowsort
SELECT ALL - col0 + col1 AS col1 FROM tab2
----
-19
-62
24

query I rowsort
SELECT ALL + tab0.col2 + + tab0.col1 + - tab0.col2 FROM tab0
----
86
91
97

query I rowsort
SELECT col0 * + 99 AS col2 FROM tab0 cor0
----
2376
3465
8811

query I rowsort
SELECT DISTINCT + + col0 + col0 * + 33 * col1 FROM tab2 cor0
----
151944
44398
7168

query I rowsort
SELECT DISTINCT - + col2 * ( - 92 ) FROM tab2 AS cor0
----
2392
2484
3496

query I rowsort
SELECT + - col2 + - ( col1 ) * col1 FROM tab1 AS cor0
----
-157
-265
-730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - 82 col0 FROM tab0 AS cor0
----
-2706
-6724
-82

query I rowsort
SELECT - + col0 * - 66 FROM tab0 AS cor0
----
1584
2310
5874

query I rowsort
SELECT ALL - col0 * + ( + col0 ) + + col0 AS col2 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT DISTINCT + col1 * 21 AS col2 FROM tab1 cor0
----
210
273
546

query I rowsort
SELECT ALL + - col2 * - 66 AS col0 FROM tab1 AS cor0
----
3564
3762
6336

query I rowsort
SELECT + - col0 * + col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT col0 * cor0.col1 AS col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT - col2 + col2 + 40 FROM tab0 AS cor0
----
40

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1879
SELECT + - col2 * ( 65 ) + + col0 * CAST( col2 + col2 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
-1377
2366
3534

skipif mysql # not compatible
query I rowsort label-1879
SELECT + - col2 * ( 65 ) + + col0 * CAST ( col2 + col2 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
-1377
2366
3534

query I rowsort
SELECT DISTINCT + 87 * 85 AS col0 FROM tab2, tab1 AS cor0
----
7395

query I rowsort
SELECT + col0 * col2 + - col0 AS col1 FROM tab2
----
182
1950
2923

query I rowsort
SELECT ALL 45 AS col1 FROM tab2, tab0 AS cor0, tab1 cor1
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

query I rowsort
SELECT ALL - cor0.col2 * ( + col2 + cor0.col2 ) FROM tab2 AS cor0
----
-1352
-1458
-2888

query I rowsort
SELECT col0 + + 47 * + cor0.col1 AS col2 FROM tab2 AS cor0
----
1464
2851
878

query I rowsort
SELECT DISTINCT - col1 * ( - col1 ) + cor0.col2 AS col0 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT ALL col1 * + col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - - col0 + + 84 FROM tab2 AS cor0
----
162
163
91

onlyif mysql # use DIV operator for integer division
query I rowsort label-1888
SELECT DISTINCT + col2 DIV + 97 + + col0 + cor0.col1 FROM tab2 AS cor0
----
137
38
96

skipif mysql # not compatible
query I rowsort label-1888
SELECT DISTINCT + col2 / + 97 + + col0 + cor0.col1 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1889
SELECT - + col1 DIV cor0.col1 FROM tab0 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1889
SELECT - + col1 / cor0.col1 FROM tab0 cor0
----
-1
-1
-1

query I rowsort
SELECT - col0 * - col1 * - col2 FROM tab1 AS cor0
----
-36480
-4212
-99840

query I rowsort
SELECT - ( cor0.col2 ) * col2 AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-1892
SELECT + 7 DIV col0 col2 FROM tab0 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1892
SELECT + 7 / col0 col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL + 94 + col0 * + col2 AS col2 FROM tab2 AS cor0
----
2122
283
3096

query I rowsort
SELECT col0 + - col2 * col0 FROM tab1 cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL + + 62 AS col0 FROM tab0 AS cor0
----
62
62
62

query I rowsort
SELECT DISTINCT - - ( + ( + col1 ) ) * cor0.col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - + ( col2 ) * + col1 AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL 38 - col2 AS col2 FROM tab2 AS cor0
----
0
11
12

query I rowsort
SELECT DISTINCT - 37 AS col1 FROM tab2 AS cor0
----
-37

query I rowsort
SELECT DISTINCT col2 * cor0.col1 - - ( 66 ) FROM tab2 AS cor0
----
1600
712
903

query I rowsort
SELECT DISTINCT - ( + col0 ) * + 51 FROM tab2 AS cor0
----
-357
-3978
-4029

onlyif mysql # use DIV operator for integer division
query I rowsort label-1902
SELECT col0 + col2 DIV col0 - + 82 FROM tab0 AS cor0
----
-47
-57
7

skipif mysql # not compatible
query I rowsort label-1902
SELECT col0 + col2 / col0 - + 82 FROM tab0 AS cor0
----
-47
-57
7

query I rowsort
SELECT - 26 AS col1 FROM tab0 AS cor0
----
-26
-26
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-1904
SELECT ALL - 7 + + cor0.col0 DIV + ( + 59 ) AS col1 FROM tab0 cor0
----
-6
-7
-7

skipif mysql # not compatible
query I rowsort label-1904
SELECT ALL - 7 + + cor0.col0 / + ( + 59 ) AS col1 FROM tab0 cor0
----
-6
-7
-7

query I rowsort
SELECT ALL + - col2 + + col0 AS col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT + + col0 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-1907
SELECT + - col2 DIV - col1 + col1 FROM tab2 AS cor0
----
19
31
59

skipif mysql # not compatible
query I rowsort label-1907
SELECT + - col2 / - col1 + col1 FROM tab2 AS cor0
----
19
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1908
SELECT ALL + ( ( col0 ) ) - + CAST( NULL AS SIGNED ) AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1908
SELECT ALL + ( ( col0 ) ) - + CAST ( NULL AS INTEGER ) AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + ( col0 ) + + col0 - 64 FROM tab2
----
-50
92
94

query I rowsort
SELECT DISTINCT 37 * + col1 - - col2 * ( + 62 ) FROM tab2
----
2821
2985
3795

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1, tab0 cor0, tab2 AS cor1
----
972 values hashing to 9600bdf5bac0caec3229e87170cc40b3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 66 + col1 * - col1 * col1 col2 FROM tab1
----
-17510
-2131
-934

query I rowsort
SELECT DISTINCT + col1 + col1 * col0 + 49 FROM tab1 AS cor0
----
1102
153
699

query I rowsort
SELECT DISTINCT + col2 * col1 - - col2 * col2 FROM tab1 AS cor0
----
10464
3819
4320

query I rowsort
SELECT col2 - cor0.col0 AS col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + - 75 + col2 AS col0 FROM tab1 AS cor0
----
-18
-21
21

query I rowsort
SELECT DISTINCT - 24 + col1 * cor0.col2 FROM tab2 AS cor0
----
1510
622
813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + 86 - + col0 col1 FROM tab2
----
1383
2659
4996

query I rowsort
SELECT DISTINCT + cor0.col0 AS col2 FROM tab2, tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - ( - 18 ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT DISTINCT - 65 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
-65

query I rowsort
SELECT cor0.col0 * + col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT - col2 + + tab0.col1 FROM tab0
----
53
9
96

query I rowsort
SELECT DISTINCT - col0 + - col0 AS col1 FROM tab1
----
-128
-160
-6

query I rowsort
SELECT tab1.col0 * - col0 + 62 AS col1 FROM tab1
----
-4034
-6338
53

query I rowsort
SELECT 11 + col2 * + col0 FROM tab0 AS cor0
----
46
7309
803

query I rowsort
SELECT DISTINCT - 87 AS col2 FROM tab1
----
-87

query I rowsort
SELECT ALL ( 62 ) FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

onlyif mysql # use DIV operator for integer division
query I rowsort label-1929
SELECT + col0 DIV tab0.col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1929
SELECT + col0 / tab0.col0 FROM tab0
----
1
1
1

query I rowsort
SELECT + cor0.col0 * col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT + + col0 + cor0.col1 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1932
SELECT DISTINCT col1 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1932
SELECT DISTINCT col1 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1933
SELECT col2 + - col1 DIV cor0.col0 FROM tab1 AS cor0
----
46
57
96

skipif mysql # not compatible
query I rowsort label-1933
SELECT col2 + - col1 / cor0.col0 FROM tab1 AS cor0
----
46
57
96

query I rowsort
SELECT ALL - col2 * - col1 * + 30 FROM tab0 AS cor0
----
223860
2910
85140

query I rowsort
SELECT + col2 * 68 + 14 AS col1 FROM tab2 AS cor0
----
1782
1850
2598

query I rowsort
SELECT DISTINCT - 89 + cor0.col0 + tab2.col0 FROM tab2, tab0, tab2 AS cor0
----
-3
-4
-75
67
68
69

query I rowsort
SELECT DISTINCT ( tab0.col0 ) * - cor1.col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
9 values hashing to 5ac8aba7baafe9bd6ceb7b5654f2c0b7

query I rowsort
SELECT - 99 AS col1 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 761f5f1a166a00db99360141565a85da

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1939
SELECT - CAST( NULL AS SIGNED ) AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-1939
SELECT - CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - + 44 + - ( col0 ) FROM tab2 AS cor0
----
-122
-123
-51

query I rowsort
SELECT - 59 AS col0 FROM tab0 AS cor0
----
-59
-59
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( col0 ) * col1 col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + 48 AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 0ef571a8722ab7270aa7272c1174b88e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1944
SELECT DISTINCT - col1 * CAST( - col1 AS SIGNED ) FROM tab0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-1944
SELECT DISTINCT - col1 * CAST ( - col1 AS INTEGER ) FROM tab0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-1945
SELECT ALL + - 47 * + col2 + - col2 DIV - 53 FROM tab0 AS cor0
----
-1551
-3853
-47

skipif mysql # not compatible
query I rowsort label-1945
SELECT ALL + - 47 * + col2 + - col2 / - 53 FROM tab0 AS cor0
----
-1551
-3853
-47

query I rowsort
SELECT DISTINCT - + col1 - cor0.col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT ALL - 86 * + col2 + col2 FROM tab0 AS cor0
----
-2805
-6970
-85

query I rowsort
SELECT - 21 + - cor0.col0 * col0 AS col0 FROM tab0 AS cor0
----
-1246
-597
-7942

query I rowsort
SELECT DISTINCT - - 57 + + col1 * col0 * + 54 + cor0.col2 AS col1 FROM tab2 AS cor0
----
11802
248591
72617

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1950
SELECT ALL - CAST( NULL AS SIGNED ) - + 93 / + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1950
SELECT ALL - CAST ( NULL AS INTEGER ) - + 93 / + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col2 - + col1 AS col1 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT + + 54 FROM tab2 AS cor0
----
54
54
54

query I rowsort
SELECT ALL + ( - col0 ) + col2 AS col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL + - cor0.col0 * col1 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * col1 col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + col0 * - col2 AS col0 FROM tab1 cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1957
SELECT cor0.col0 + col1 * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1957
SELECT cor0.col0 + col1 * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col0 * + cor0.col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - cor0.col1 + - cor0.col2 * col1 AS col2 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT + - col2 * col0 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - 35 + - col1 + 53 FROM tab2 AS cor0
----
-13
-41
1

query I rowsort
SELECT ALL col0 + 47 AS col0 FROM tab2
----
125
126
54

query I rowsort
SELECT DISTINCT + ( + col1 ) FROM tab1
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1964
SELECT DISTINCT - - CAST( NULL AS SIGNED ) + cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-1964
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) + cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

query I rowsort
SELECT ( - col2 ) + - ( ( - col1 ) ) * + 76 * + tab2.col2 AS col2 FROM tab2
----
116558
49058
63585

query I rowsort
SELECT + 10 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to a47194429f3e0358a3aebffd5f050113

query I rowsort
SELECT + + col2 + col0 * - 22 AS col1 FROM tab2 AS cor0
----
-127
-1690
-1700

query I rowsort
SELECT DISTINCT + - cor0.col0 * + cor0.col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + 70 AS col0 FROM tab2 AS cor0
----
70
70
70

query I rowsort
SELECT cor1.col1 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT - 24 * cor1.col2 AS col1 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 77d6b4249cd2df12720e884e3bd46068

query I rowsort
SELECT + - cor0.col2 + col2 * col2 AS col2 FROM tab1 AS cor0
----
2862
3192
9120

skipif mysql # not compatible
query I rowsort
SELECT + col2 + CAST ( ( col2 ) AS REAL ) * col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT col0 - + 27 FROM tab1 cor0
----
-24
37
53

query I rowsort
SELECT col0 * - col1 + cor0.col2 AS col0 FROM tab1 AS cor0
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-1976
SELECT - col1 DIV + CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-1976
SELECT - col1 / + CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + col1 * + col0 - col1 AS col0 FROM tab2 cor0
----
1326
186
4543

query I rowsort
SELECT - col2 * - ( - cor0.col1 ) AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1979
SELECT - col0 + + col2 * - cor0.col2 + - CAST( + 41 AS SIGNED ) FROM tab2 cor0
----
-1564
-777
-795

skipif mysql # not compatible
query I rowsort label-1979
SELECT - col0 + + col2 * - cor0.col2 + - CAST ( + 41 AS INTEGER ) FROM tab2 cor0
----
-1564
-777
-795

query I rowsort
SELECT ALL 33 + 34 AS col1 FROM tab2
----
67
67
67

query I rowsort
SELECT - + col1 + - col0 AS col2 FROM tab2 cor0
----
-137
-38
-96

query I rowsort
SELECT - + ( cor0.col2 ) * - col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col0 + 81 FROM tab1 AS cor0
----
145
161
84

query I rowsort
SELECT ALL + + 89 * - col0 FROM tab2 AS cor0
----
-623
-6942
-7031

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 9 col2 FROM tab1 AS cor0
----
9

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 cor0, tab2 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to 59ca7c96f3955e014bebd08b5442edff

query I rowsort
SELECT + 57 AS col1 FROM tab1 AS cor0
----
57
57
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 58 col0 FROM tab1 cor0
----
58

query I rowsort
SELECT ALL + col2 * cor0.col0 + 36 FROM tab0 AS cor0
----
71
7334
828

onlyif mysql # use DIV operator for integer division
query I rowsort label-1990
SELECT ALL - - col0 DIV - 5 + + col0 * col1 AS col0 FROM tab1 AS cor0
----
1024
628
78

skipif mysql # not compatible
query I rowsort label-1990
SELECT ALL - - col0 / - 5 + + col0 * col1 AS col0 FROM tab1 AS cor0
----
1024
628
78

query I rowsort
SELECT DISTINCT - + cor0.col2 * col2 AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

query IIIIIIIIIIII rowsort
SELECT * FROM tab2 cor0 CROSS JOIN tab2, tab0 cor1, tab1 AS cor2
----
972 values hashing to 2d99dda76af061a3fac120e0e49e6c53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * ( col0 * cor0.col2 ) + + col2 col0 FROM tab1 AS cor0
----
-233415
-432
-614304

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + + col0 col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL - + col1 - ( 28 ) AS col2 FROM tab2 AS cor0
----
-45
-59
-87

onlyif mysql # use DIV operator for integer division
query I rowsort label-1996
SELECT DISTINCT - col1 DIV col1 AS col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-1996
SELECT DISTINCT - col1 / col1 AS col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT DISTINCT + - col2 * - 25 + - ( - col1 ) FROM tab2 AS cor0
----
706
709
967

query I rowsort
SELECT - col0 + 70 AS col1 FROM tab0 AS cor0
----
-19
35
46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * col1 + - col0 * - col1 col1 FROM tab1 AS cor0
----
1210
1482
2288

query I rowsort
SELECT DISTINCT + col1 * ( col1 ) + + col0 AS col0 FROM tab0 cor0
----
7420
8370
9444

query I rowsort
SELECT ALL - + cor0.col2 - - col1 FROM tab0 AS cor0
----
53
9
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2002
SELECT DISTINCT - col0 DIV - col1 AS col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2002
SELECT DISTINCT - col0 / - col1 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col0 * col0 + 7 FROM tab0 cor0
----
1232
583
7928

query I rowsort
SELECT ALL + - col1 + + col2 * + 97 AS col2 FROM tab1 AS cor0
----
5212
5519
9299

query I rowsort
SELECT DISTINCT + col1 + ( + ( + cor0.col1 ) ) * + col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT col1 + col0 * ( col0 ) AS col2 FROM tab0 cor0
----
1322
662
8012

query I rowsort
SELECT - 97 * - col1 AS col2 FROM tab0 AS cor0
----
8342
8827
9409

query I rowsort
SELECT col1 + 82 FROM tab0
----
168
173
179

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1 cor0 CROSS JOIN tab0, tab0 AS cor1, tab2 AS cor2
----
972 values hashing to 1e9d01970ae508486ddabec967bb176c

query I rowsort
SELECT ALL - 23 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to ce60bf4b0647d0fcb18a0562e351c52d

query I rowsort
SELECT + 51 * col0 AS col1 FROM tab0 AS cor0
----
1224
1785
4539

query I rowsort
SELECT ALL + col0 * - col0 + cor0.col0 * - 79 + cor0.col2 AS col1 FROM tab0 cor0
----
-14870
-2439
-3989

query I rowsort
SELECT cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT ( 38 ) AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

query I rowsort
SELECT ALL + ( - col0 ) + 68 AS col2 FROM tab0 AS cor0
----
-21
33
44

query I rowsort
SELECT ALL + - col2 + + col0 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT - - col0 + col0 * + 19 FROM tab0 AS cor0
----
1780
480
700

query I rowsort
SELECT DISTINCT + + 42 FROM tab2 cor0
----
42

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + cor0.col0 * ( ( - col1 ) * - 80 ) col1 FROM tab0 AS cor0
----
165153
271601
648002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col1 col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2021
SELECT ALL col2 + tab0.col2 - col0 DIV tab0.col0 AS col0 FROM tab0
----
1
163
65

skipif mysql # not compatible
query I rowsort label-2021
SELECT ALL col2 + tab0.col2 - col0 / tab0.col0 AS col0 FROM tab0
----
1
163
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-2022
SELECT ALL col0 DIV + tab1.col2 AS col1 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2022
SELECT ALL col0 / + tab1.col2 AS col1 FROM tab1
----
0
0
1

query I rowsort
SELECT - col1 * + col0 - - col2 AS col2 FROM tab0
----
-2031
-3394
-8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-2024
SELECT ALL col2 DIV + tab1.col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-2024
SELECT ALL col2 / + tab1.col1 FROM tab1
----
2
5
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2025
SELECT DISTINCT tab1.col2 DIV col2 col2 FROM tab1
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2025
SELECT DISTINCT tab1.col2 / col2 col2 FROM tab1
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2026
SELECT ALL col0 DIV + col2 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-2026
SELECT ALL col0 / + col2 FROM tab0
----
0
1
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-2027
SELECT ALL + col2 + col2 DIV + col1 AS col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2027
SELECT ALL + col2 + col2 / + col1 AS col1 FROM tab0
----
1
33
82

query I rowsort
SELECT DISTINCT + col0 + - tab2.col1 * ( col2 ) FROM tab2
----
-1456
-567
-830

query I rowsort
SELECT ALL - col1 * + col0 + + col1 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT ( 94 ) * tab0.col1 * 13 + tab0.col1 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 4ad458a3b415d92354cf66c79682e613

query I rowsort
SELECT ALL cor0.col1 * cor0.col1 FROM tab2, tab1 AS cor0
----
9 values hashing to ae5946db6904798b8afac35f5777bb79

query I rowsort
SELECT ALL 50 AS col1 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 314aace40e704c20a6be06204a329f80

onlyif mysql # use DIV operator for integer division
query I rowsort label-2033
SELECT - 61 DIV - col0 + + col2 FROM tab2 AS cor0
----
26
35
38

skipif mysql # not compatible
query I rowsort label-2033
SELECT - 61 / - col0 + + col2 FROM tab2 AS cor0
----
26
35
38

query I rowsort
SELECT ALL + 11 - + cor0.col2 FROM tab2 AS cor0
----
-15
-16
-27

query I rowsort
SELECT ALL - tab0.col1 * col1 * 17 + col1 AS col1 FROM tab0
----
-125646
-140686
-159856

query I rowsort
SELECT ALL col2 + tab2.col1 * + col0 AS col1 FROM tab2
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-2037
SELECT DISTINCT - ( tab2.col0 ) DIV + 97 + 60 * col0 AS col1 FROM tab2
----
420
4680
4740

skipif mysql # not compatible
query I rowsort label-2037
SELECT DISTINCT - ( tab2.col0 ) / + 97 + 60 * col0 AS col1 FROM tab2
----
420
4680
4740

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2038
SELECT + col0 + + CAST( NULL AS SIGNED ) * - cor0.col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2038
SELECT + col0 + + CAST ( NULL AS INTEGER ) * - cor0.col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT tab0.col2 + - col2 * - col1 FROM tab0
----
2871
7544
98

query I rowsort
SELECT tab2.col0 * + col2 AS col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + cor0.col0 FROM tab2, tab1, tab1 cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col0 col0 FROM tab0, tab0 AS cor0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + 10 + - col0 col0 FROM tab2 AS cor0
----
10
10
10

query I rowsort
SELECT ALL col0 - + col1 AS col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT + cor0.col2 - 28 * - col0 AS col0 FROM tab0 cor0
----
2574
705
981

query I rowsort
SELECT col1 * col0 + col0 * col0 FROM tab1
----
4736
7440
87

query I rowsort
SELECT ( + col0 ) + - tab1.col1 * col1 FROM tab1
----
-36
-673
-89

query I rowsort
SELECT 76 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

query I rowsort
SELECT + col1 + col2 * - col2 AS col0 FROM tab2
----
-1427
-617
-698

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2050
SELECT ALL - + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2050
SELECT ALL - + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT - 89 * ( tab0.col1 ) FROM tab0
----
-7654
-8099
-8633

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 6 col1 FROM tab1 AS cor0
----
-6
-6
-6

query I rowsort
SELECT ALL - + ( - col1 ) FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - 60 * - col1 AS col2 FROM tab0 AS cor0
----
5160
5460
5820

query I rowsort
SELECT ALL - 45 * - cor0.col2 FROM tab0 AS cor0
----
1485
3690
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2057
SELECT + 89 - + col1 DIV col0 col0 FROM tab1 AS cor0
----
81
89
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2057
SELECT + 89 - + col1 / col0 col0 FROM tab1 AS cor0
----
81
89
89

query I rowsort
SELECT - 0 * - col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 48 * col0 AS col1 FROM tab1 AS cor0
----
-144
-3072
-3840

query I rowsort
SELECT - - 44 AS col1 FROM tab1 AS cor0
----
44
44
44

query I rowsort
SELECT ALL cor0.col0 * col0 AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - col2 + + col0 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT ALL + - 20 + - cor0.col2 FROM tab1 AS cor0
----
-116
-74
-77

query I rowsort
SELECT DISTINCT + + ( - col2 ) * - 27 AS col2 FROM tab1 AS cor0
----
1458
1539
2592

query I rowsort
SELECT - - ( - cor0.col0 ) + cor0.col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL + 61 FROM tab2 AS cor0
----
61
61
61

query I rowsort
SELECT DISTINCT col2 * col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT 82 * ( tab0.col0 * col0 ) AS col0 FROM tab0
----
100450
47232
649522

onlyif mysql # use DIV operator for integer division
query I rowsort label-2069
SELECT DISTINCT + col0 DIV col1 - - col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2069
SELECT DISTINCT + col0 / col1 - - col0 FROM tab0
----
24
35
89

query I rowsort
SELECT + 80 + 40 * + col1 + - col0 FROM tab0
----
3496
3631
3925

onlyif mysql # use DIV operator for integer division
query I rowsort label-2071
SELECT - col1 * 17 DIV col0 FROM tab0
----
-17
-47
-60

skipif mysql # not compatible
query I rowsort label-2071
SELECT - col1 * 17 / col0 FROM tab0
----
-17
-47
-60

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2072
SELECT DISTINCT - CAST( col0 AS SIGNED ) + col2 - + col0 AS col1 FROM tab0
----
-15
-69
-96

skipif mysql # not compatible
query I rowsort label-2072
SELECT DISTINCT - CAST ( col0 AS INTEGER ) + col2 - + col0 AS col1 FROM tab0
----
-15
-69
-96

query I rowsort
SELECT + 9 * + col0 * - 23 + - col1 * - col1 - - col1 AS col1 FROM tab1 AS cor0
----
-13138
-16378
81

query I rowsort
SELECT - col0 * col0 + + col1 - + col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + col1 * + 96 FROM tab0
----
8256
8736
9312

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab1 AS cor1, tab1 cor2
----
972 values hashing to fe55095fff3a5ecc2f113d14a8c6f823

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 64 col2 FROM tab2, tab2 AS cor0
----
-64

query I rowsort
SELECT DISTINCT - col1 + 29 * + col1 FROM tab0 AS cor0
----
2408
2548
2716

onlyif mysql # use DIV operator for integer division
query I rowsort label-2079
SELECT ALL col2 DIV + col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2079
SELECT ALL col2 / + col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + 40 * 24 FROM tab0 AS cor0
----
960
960
960

query I rowsort
SELECT col1 * + col1 AS col0 FROM tab1 cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-2082
SELECT + + col1 DIV col2 FROM tab0 cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-2082
SELECT + + col1 / col2 FROM tab0 cor0
----
1
2
97

query I rowsort
SELECT - ( col2 ) + col1 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL - col2 * cor0.col0 + + 48 AS col0 FROM tab2 AS cor0
----
-141
-1980
-2954

onlyif mysql # use DIV operator for integer division
query I rowsort label-2085
SELECT 1 + col0 DIV 84 col1 FROM tab0 cor0
----
1
1
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2085
SELECT 1 + col0 / 84 col1 FROM tab0 cor0
----
1
1
2

query I rowsort
SELECT ALL + col0 * col1 * ( 84 + + cor0.col2 ) AS col1 FROM tab0 AS cor0
----
1344434
241488
288575

query I rowsort
SELECT + ( col2 ) + + cor0.col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT - - 18 FROM tab0 AS cor0
----
18
18
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-2089
SELECT - + ( col2 ) * + 0 + + col2 DIV + cor0.col0 AS col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2089
SELECT - + ( col2 ) * + 0 + + col2 / + cor0.col0 AS col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT + col1 + - cor0.col1 AS col2 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2091
SELECT col2 * col1 DIV 20 + + 96 DIV - col0 FROM tab0 AS cor0
----
137
2
372

skipif mysql # not compatible
query I rowsort label-2091
SELECT col2 * col1 / 20 + + 96 / - col0 FROM tab0 AS cor0
----
137
2
372

query I rowsort
SELECT - cor0.col2 + + col1 AS col2 FROM tab2 AS cor0
----
-21
33
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-2093
SELECT + col0 + 51 DIV - col1 AS col0 FROM tab2 AS cor0
----
6
76
78

skipif mysql # not compatible
query I rowsort label-2093
SELECT + col0 + 51 / - col1 AS col0 FROM tab2 AS cor0
----
6
76
78

query I rowsort
SELECT + 74 + tab1.col2 AS col2 FROM tab1
----
128
131
170

query I rowsort
SELECT cor0.col0 + - 91 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 95f3bcfff5f703cf94b1d2a4e14bbc44

query I rowsort
SELECT + 54 * 26 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 47fec8e6abb9da5d4da181dadcc9a3a3

query I rowsort
SELECT DISTINCT + col2 + ( - col2 ) FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + - col0 * + col2 AS col1 FROM tab2 cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-2099
SELECT DISTINCT + col0 DIV 21 - col1 FROM tab2 AS cor0
----
-14
-31
-56

skipif mysql # not compatible
query I rowsort label-2099
SELECT DISTINCT + col0 / 21 - col1 FROM tab2 AS cor0
----
-14
-31
-56

query I rowsort
SELECT col2 * 5 FROM tab1 AS cor0
----
270
285
480

query I rowsort
SELECT ALL + col1 + + 62 * col0 FROM tab1 AS cor0
----
212
3978
4973

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2102
SELECT DISTINCT - cor0.col1 * CAST( col2 + - col1 AS SIGNED ) * + cor0.col0 AS col2 FROM tab1 cor0
----
-2184
-30080
-86320

skipif mysql # not compatible
query I rowsort label-2102
SELECT DISTINCT - cor0.col1 * CAST ( col2 + - col1 AS INTEGER ) * + cor0.col0 AS col2 FROM tab1 cor0
----
-2184
-30080
-86320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2103
SELECT ALL - + col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2103
SELECT ALL - + col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2104
SELECT DISTINCT + col1 DIV CAST( + col0 * + col1 AS SIGNED ) FROM tab2 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2104
SELECT DISTINCT + col1 / CAST ( + col0 * + col1 AS INTEGER ) FROM tab2 AS cor0
----
0

query I rowsort
SELECT + + col0 + ( + col1 * + col1 ) FROM tab0 AS cor0
----
7420
8370
9444

onlyif mysql # use DIV operator for integer division
query I rowsort label-2106
SELECT col1 * ( col2 ) + - col2 DIV - cor0.col0 AS col2 FROM tab2 AS cor0
----
1534
646
840

skipif mysql # not compatible
query I rowsort label-2106
SELECT col1 * ( col2 ) + - col2 / - cor0.col0 AS col2 FROM tab2 AS cor0
----
1534
646
840

onlyif mysql # use DIV operator for integer division
query I rowsort label-2107
SELECT DISTINCT col1 + - col1 - - col1 DIV col0 AS col2 FROM tab2 AS cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-2107
SELECT DISTINCT col1 + - col1 - - col1 / col0 AS col2 FROM tab2 AS cor0
----
0
4

query I rowsort
SELECT col2 + col0 * + col0 * + col2 FROM tab2
----
1350
158210
237196

query I rowsort
SELECT + 26 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to ede8226bb7e602e221f9d98345b4da37

query I rowsort
SELECT DISTINCT - tab1.col0 + col0 AS col0 FROM tab1
----
0

query I rowsort
SELECT + col0 * ( col0 ) + col0 * col1 AS col2 FROM tab2 AS cor0
----
10686
266
7584

query I rowsort
SELECT + col0 * + 76 AS col0 FROM tab2
----
532
5928
6004

onlyif mysql # use DIV operator for integer division
query I rowsort label-2113
SELECT - col2 DIV + col0 AS col0 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2113
SELECT - col2 / + col0 AS col0 FROM tab0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2114
SELECT col1 DIV 10 FROM tab2
----
1
3
5

skipif mysql # not compatible
query I rowsort label-2114
SELECT col1 / 10 FROM tab2
----
1
3
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 25 * col2 * tab0.col1 col2 FROM tab0
----
186550
2425
70950

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2116
SELECT DISTINCT - CAST( 51 AS SIGNED ) FROM tab0, tab1 AS cor0
----
-51

skipif mysql # not compatible
query I rowsort label-2116
SELECT DISTINCT - CAST ( 51 AS INTEGER ) FROM tab0, tab1 AS cor0
----
-51

query I rowsort
SELECT ALL - 38 * + col0 * + cor0.col2 - 20 AS col2 FROM tab2 AS cor0
----
-114096
-7202
-77084

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 30 col0 FROM tab0, tab2 AS cor0
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2119
SELECT CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-2119
SELECT CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col1 - col2 col1 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT ALL 36 * - col0 + col1 * - col1 FROM tab1
----
-2404
-3049
-784

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + tab2.col1 col0 FROM tab2
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-2123
SELECT ALL 79 DIV - cor0.col0 AS col0 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to e5212c3c9e2dcf2e1883cdf96538fa7c

skipif mysql # not compatible
query I rowsort label-2123
SELECT ALL 79 / - cor0.col0 AS col0 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to e5212c3c9e2dcf2e1883cdf96538fa7c

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2124
SELECT DISTINCT - col0 * col1 * + col1 + ( - col1 ) + col0 * + CAST( NULL AS DECIMAL ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2124
SELECT DISTINCT - col0 * col1 * + col1 + ( - col1 ) + col0 * + CAST ( NULL AS REAL ) FROM tab1
----
NULL

query I rowsort
SELECT ALL - ( 34 ) * cor0.col1 + + col0 AS col1 FROM tab0 AS cor0
----
-2900
-3005
-3263

onlyif mysql # use DIV operator for integer division
query I rowsort label-2126
SELECT ALL - - col1 DIV + col1 + - col0 AS col2 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-2126
SELECT ALL - - col1 / + col1 + - col0 AS col2 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT DISTINCT - 33 * col0 + col2 AS col0 FROM tab1 AS cor0
----
-2055
-2544
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2128
SELECT + col1 - col1 DIV col2 AS col0 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2128
SELECT + col1 - col1 / col2 AS col0 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-2129
SELECT DISTINCT + - col2 + + col0 DIV - cor0.col1 AS col0 FROM tab1 AS cor0
----
-102
-54
-63

skipif mysql # not compatible
query I rowsort label-2129
SELECT DISTINCT + - col2 + + col0 / - cor0.col1 AS col0 FROM tab1 AS cor0
----
-102
-54
-63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 94 + - 57 * + cor0.col0 * - col2 col1 FROM tab0 cor0
----
2089
416080
45238

query I rowsort
SELECT + 51 * - col2 + col1 AS col2 FROM tab0 AS cor0
----
-1597
-4091
46

query I rowsort
SELECT ALL + col1 * - col1 + cor0.col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT col2 + col1 * + col1 FROM tab2 AS cor0
----
327
3507
988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col0 ) * col0 col2 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL col0 * col2 + + col0 + - 15 FROM tab1 AS cor0
----
150
3697
7745

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2136
SELECT + CAST( NULL AS DECIMAL ) + + col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2136
SELECT + CAST ( NULL AS REAL ) + + col2 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col1 * col1 AS col0 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - col1 + + col2 * + col0 + col0 * - col1 FROM tab0 AS cor0
----
-1358
-3457
-892

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 5 * col2 col2 FROM tab2 AS cor0
----
-130
-135
-190

query I rowsort
SELECT cor0.col0 + col1 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-2141
SELECT DISTINCT - 40 DIV + cor0.col1 FROM tab1 AS cor0
----
-1
-3
-4

skipif mysql # not compatible
query I rowsort label-2141
SELECT DISTINCT - 40 / + cor0.col1 FROM tab1 AS cor0
----
-1
-3
-4

query I rowsort
SELECT ALL + 66 AS col0 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 897b6122ac98340b78905f39d81897fc

query I rowsort
SELECT ALL + + cor0.col0 * cor0.col1 + 98 FROM tab1 AS cor0
----
1138
176
738

query I rowsort
SELECT + 10 AS col2 FROM tab2, tab0 cor0, tab0 cor1
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

query I rowsort
SELECT ALL col1 + col1 AS col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT - cor0.col0 * - cor0.col1 + + cor0.col2 AS col1 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT - 60 + - cor0.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 326a6a90f1d534b22c35e886570d0152

query I rowsort
SELECT DISTINCT + col2 - ( col0 ) AS col0 FROM tab1
----
-7
16
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2149
SELECT ALL + CAST( + col1 AS SIGNED ) * col2 col2 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2149
SELECT ALL + CAST ( + col1 AS INTEGER ) * col2 col2 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2150
SELECT + - CAST( NULL AS SIGNED ) * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2150
SELECT + - CAST ( NULL AS INTEGER ) * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2151
SELECT - col2 DIV + col0 + col0 AS col1 FROM tab1 cor0
----
-15
64
79

skipif mysql # not compatible
query I rowsort label-2151
SELECT - col2 / + col0 + col0 AS col1 FROM tab1 cor0
----
-15
64
79

query I rowsort
SELECT DISTINCT - 24 * - cor0.col2 + cor0.col2 * col2 FROM tab0 AS cor0
----
1881
25
8692

query I rowsort
SELECT DISTINCT 0 * cor0.col1 - col2 * + ( + 2 ) FROM tab0 cor0
----
-164
-2
-66

query I rowsort
SELECT ALL col1 * - 38 FROM tab0 AS cor0
----
-3268
-3458
-3686

query I rowsort
SELECT + col1 - col1 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - - ( col2 ) + + col1 * - 82 * 51 FROM tab1 AS cor0
----
-108678
-41763
-54270

onlyif mysql # use DIV operator for integer division
query I rowsort label-2157
SELECT - col2 DIV 62 AS col0 FROM tab0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2157
SELECT - col2 / 62 AS col0 FROM tab0
----
-1
0
0

query I rowsort
SELECT DISTINCT col1 - - ( col1 ) FROM tab2
----
118
34
62

query I rowsort
SELECT col1 - + ( col2 ) AS col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT ALL ( + ( col0 ) ) AS col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + 92 FROM tab0, tab2 cor0
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT DISTINCT + cor1.col2 AS col1 FROM tab2, tab0 cor0, tab0 AS cor1
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2163
SELECT ALL col1 + 37 DIV - col0 FROM tab2
----
17
26
59

skipif mysql # not compatible
query I rowsort label-2163
SELECT ALL col1 + 37 / - col0 FROM tab2
----
17
26
59

query I rowsort
SELECT ALL - ( + 55 ) FROM tab0
----
-55
-55
-55

query I rowsort
SELECT DISTINCT + 53 FROM tab1, tab2 cor0
----
53

query I rowsort
SELECT DISTINCT ( col1 ) * + cor0.col0 * col0 + - col0 AS col1 FROM tab2 AS cor0
----
106018
1512
358878

query I rowsort
SELECT + + ( col1 ) AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + col1 + 73 FROM tab0 AS cor0
----
159
164
170

query I rowsort
SELECT - ( - col1 ) + tab0.col2 FROM tab0
----
119
173
98

query I rowsort
SELECT - - col1 + + col0 * col2 AS col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT - cor0.col0 * tab2.col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to c7d8c1f00ed770fc7c219c3c68edd7d7

query I rowsort
SELECT DISTINCT + + col2 * + col2 * col2 FROM tab1 AS cor0
----
157464
185193
884736

query I rowsort
SELECT + cor0.col2 FROM tab1, tab1 cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT ALL tab0.col1 * 19 FROM tab0, tab1 AS cor0
----
9 values hashing to 5bb85ac8dc21877ff66a0789ba6bef8e

query I rowsort
SELECT ALL col2 * + ( - col2 ) + - col2 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT - - col1 * ( - col2 ) FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + + col1 * col2 - col1 * cor0.col2 AS col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT - col1 + - col0 AS col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT - cor0.col1 AS col0 FROM tab0, tab1 cor0, tab1 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT col0 * col2 * 98 AS col0 FROM tab2 AS cor0
----
18522
198744
294196

query I rowsort
SELECT ALL col1 * + cor0.col2 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-2182
SELECT ALL - col2 DIV + cor0.col0 AS col1 FROM tab0 cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2182
SELECT ALL - col2 / + cor0.col0 AS col1 FROM tab0 cor0
----
-1
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2183
SELECT ALL - col2 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2183
SELECT ALL - col2 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 58 * - col1 AS col0 FROM tab1 AS cor0
----
-1508
-580
-754

query I rowsort
SELECT DISTINCT + col2 * col1 AS col0 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - 49 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to adfccb10c9468825d9961e3613140f89

query I rowsort
SELECT ALL + cor0.col1 AS col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0, tab1, tab1 AS cor1
----
972 values hashing to 7864aada86bf5bf5e1621c7905de8dcd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 30 col1 FROM tab0
----
30

query I rowsort
SELECT 62 AS col2 FROM tab1
----
62
62
62

query I rowsort
SELECT ALL col1 * - col2 + col2 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT ALL col0 * - ( 85 + + col1 ) * - col0 AS col1 FROM tab0
----
1394096
222950
98496

query I rowsort
SELECT ALL - col1 + col0 * - 25 + - col2 FROM tab2
----
-2030
-2035
-233

query I rowsort
SELECT - col0 * - col2 + + 68 FROM tab0
----
103
7366
860

onlyif mysql # use DIV operator for integer division
query I rowsort label-2195
SELECT ALL col0 * col2 DIV 87 FROM tab2
----
2
23
34

skipif mysql # not compatible
query I rowsort label-2195
SELECT ALL col0 * col2 / 87 FROM tab2
----
2
23
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2196
SELECT + col0 DIV 2 FROM tab2
----
3
39
39

skipif mysql # not compatible
query I rowsort label-2196
SELECT + col0 / 2 FROM tab2
----
3
39
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + 88 col1 FROM tab2 AS cor0
----
166
167
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2198
SELECT col0 * col0 + - col2 * + col1 * CAST( col0 AS SIGNED ) + cor0.col2 * - 97 FROM tab2 AS cor0
----
-116090
-48479
-8429

skipif mysql # not compatible
query I rowsort label-2198
SELECT col0 * col0 + - col2 * + col1 * CAST ( col0 AS INTEGER ) + cor0.col2 * - 97 FROM tab2 AS cor0
----
-116090
-48479
-8429

query I rowsort
SELECT ALL col1 * + ( col0 ) AS col0 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT - - col0 * - 3 + - col0 FROM tab2 AS cor0
----
-28
-312
-316

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + 56 col1 FROM tab2 cor0
----
-3
25
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2202
SELECT + CAST( NULL AS SIGNED ) * + col0 + col2 / - 13 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2202
SELECT + CAST ( NULL AS INTEGER ) * + col0 + col2 / - 13 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 64 AS col1 FROM tab0 AS cor0
----
64
64
64

query I rowsort
SELECT - + col2 * - col1 AS col2 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-2205
SELECT - 51 + tab2.col2 DIV col1 AS col1 FROM tab2
----
-49
-51
-51

skipif mysql # not compatible
query I rowsort label-2205
SELECT - 51 + tab2.col2 / col1 AS col1 FROM tab2
----
-49
-51
-51

onlyif mysql # use DIV operator for integer division
query I rowsort label-2206
SELECT + col0 + col0 DIV + col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2206
SELECT + col0 + col0 / + col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - col2 + + col2 * col2 FROM tab0 cor0
----
0
1056
6642

query I rowsort
SELECT + col0 * 70 FROM tab2 cor0
----
490
5460
5530

query I rowsort
SELECT 12 * col2 + cor0.col1 AS col0 FROM tab2 AS cor0
----
355
371
473

query I rowsort
SELECT - cor0.col2 + 13 * - col0 FROM tab2 AS cor0
----
-1040
-1065
-118

query I rowsort
SELECT - 12 AS col2 FROM tab2
----
-12
-12
-12

query I rowsort
SELECT - 69 * + col2 FROM tab0
----
-2277
-5658
-69

query I rowsort
SELECT DISTINCT - 33 FROM tab1, tab1 AS cor0
----
-33

onlyif mysql # use DIV operator for integer division
query I rowsort label-2214
SELECT col2 DIV col2 col1 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2214
SELECT col2 / col2 col1 FROM tab0
----
1
1
1

query I rowsort
SELECT ( col0 ) + - col0 - col1 * + col0 * col2 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT + col2 + + col0 AS col2 FROM tab1
----
121
176
57

query I rowsort
SELECT DISTINCT 35 - ( - col1 ) AS col1 FROM tab0
----
121
126
132

query I rowsort
SELECT 89 + col2 FROM tab2
----
115
116
127

query I rowsort
SELECT 9 * - 60 * + col2 + cor0.col0 FROM tab1 AS cor0
----
-29157
-30716
-51760

query I rowsort
SELECT DISTINCT + ( 22 ) + col1 AS col1 FROM tab1 AS cor0
----
32
35
48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * - col1 + + col0 col2 FROM tab0 AS cor0
----
-2814
-62
-7373

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( + col2 AS REAL ) + col2 * cor0.col2 AS col1 FROM tab1 AS cor0
----
2862
3192
9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-2223
SELECT - ( - col2 ) + col1 DIV 36 FROM tab2 AS cor0
----
27
27
38

skipif mysql # not compatible
query I rowsort label-2223
SELECT - ( - col2 ) + col1 / 36 FROM tab2 AS cor0
----
27
27
38

query I rowsort
SELECT DISTINCT - + col2 + - col1 AS col1 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT + - col0 + col1 AS col2 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT - ( - col0 ) + 94 + col0 AS col1 FROM tab1 AS cor0
----
100
222
254

query I rowsort
SELECT DISTINCT - - cor0.col2 + col1 FROM tab0 cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2228
SELECT - col2 DIV cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2228
SELECT - col2 / cor0.col2 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + cor0.col0 + col2 AS col0 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-2230
SELECT 59 DIV - col0 FROM tab2 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-2230
SELECT 59 / - col0 FROM tab2 AS cor0
----
-8
0
0

query I rowsort
SELECT ALL - col1 + + col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 78 * - col2 AS col0 FROM tab2 AS cor0
----
-2028
-2106
-2964

query I rowsort
SELECT + - col1 * cor0.col1 * col1 AS col1 FROM tab1 AS cor0
----
-1000
-17576
-2197

query I rowsort
SELECT DISTINCT + - 18 + col2 * - 60 * col2 AS col2 FROM tab0 AS cor0
----
-403458
-65358
-78

query I rowsort
SELECT col0 * ( col1 * + 48 ) AS col0 FROM tab1
----
30720
3744
49920

query I rowsort
SELECT ALL - col0 * - col0 AS col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT DISTINCT ( - tab2.col2 * col1 ) - tab2.col0 AS col1 FROM tab2
----
-1612
-725
-844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2238
SELECT DISTINCT - 9 + col1 * - CAST( NULL AS SIGNED ) col1 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2238
SELECT DISTINCT - 9 + col1 * - CAST ( NULL AS INTEGER ) col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + cor0.col0 * - col0 * 50 AS col0 FROM tab1 AS cor0
----
-204800
-320000
-450

query I rowsort
SELECT ( + col2 ) * + ( col2 ) AS col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT - 47 * - col0 AS col2 FROM tab1 AS cor0
----
141
3008
3760

onlyif mysql # use DIV operator for integer division
query I rowsort label-2242
SELECT ALL + 73 DIV + col2 AS col2 FROM tab0
----
0
2
73

skipif mysql # not compatible
query I rowsort label-2242
SELECT ALL + 73 / + col2 AS col2 FROM tab0
----
0
2
73

query I rowsort
SELECT DISTINCT - - col0 * - ( col2 ) + - col1 + + 66 FROM tab0 cor0
----
-66
-7323
-812

query I rowsort
SELECT ALL - col2 * - col0 + 1 + col0 * - ( 21 ) FROM tab1 cor0
----
100
2305
6001

query I rowsort
SELECT + - col2 + + col0 AS col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT + col2 * - 31 * + col2 + - col1 FROM tab1 AS cor0
----
-100729
-285709
-90422

query I rowsort
SELECT ALL - cor0.col2 * col0 + col2 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT - 57 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

query I rowsort
SELECT ( - col0 ) + col2 * - col1 * - col1 FROM tab1 AS cor0
----
16144
36501
5636

query I rowsort
SELECT ALL - 62 + + col1 + col0 * + col0 * cor0.col2 AS col0 FROM tab1 AS cor0
----
233420
450
614351

query I rowsort
SELECT ALL ( + 31 ) * + col0 + col0 AS col1 FROM tab2 AS cor0
----
224
2496
2528

query I rowsort
SELECT DISTINCT - 91 - + col0 * + col1 AS col1 FROM tab2
----
-1434
-308
-4693

query I rowsort
SELECT DISTINCT - 67 * + col2 - + col2 FROM tab0
----
-2244
-5576
-68

query I rowsort
SELECT DISTINCT - tab2.col2 - + col2 * col0 FROM tab2
----
-2054
-216
-3040

query I rowsort
SELECT DISTINCT - - cor0.col2 AS col2 FROM tab2 cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-2256
SELECT - + col1 - - col1 DIV cor0.col1 AS col0 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-2256
SELECT - + col1 - - col1 / cor0.col1 AS col0 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT - col2 * - col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT - col2 + - col2 - cor0.col0 * - col1 AS col1 FROM tab0 cor0
----
1998
3393
7935

onlyif mysql # use DIV operator for integer division
query I rowsort label-2259
SELECT tab1.col0 DIV col1 AS col2 FROM tab1
----
0
6
6

skipif mysql # not compatible
query I rowsort label-2259
SELECT tab1.col0 / col1 AS col2 FROM tab1
----
0
6
6

query I rowsort
SELECT + 61 * col1 FROM tab0
----
5246
5551
5917

query I rowsort
SELECT ALL + col1 + col2 + - col2 * + col2 FROM tab2
----
-1389
-591
-671

query I rowsort
SELECT DISTINCT + 10 + + col1 FROM tab0
----
101
107
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col0 col2 FROM tab0
----
178
48
70

query I rowsort
SELECT col2 * - ( ( - col1 ) ) AS col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT col0 + - 77 AS col0 FROM tab0 AS cor0
----
-42
-53
12

query I rowsort
SELECT DISTINCT + + col0 * + col0 - - col2 FROM tab1 AS cor0
----
4153
63
6496

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2267
SELECT + col0 + - ( 6 + - col0 ) * + CAST( - 5 + col1 AS SIGNED ) * col0 AS col0 FROM tab2 AS cor0
----
189
303342
69283

skipif mysql # not compatible
query I rowsort label-2267
SELECT + col0 + - ( 6 + - col0 ) * + CAST ( - 5 + col1 AS INTEGER ) * col0 AS col0 FROM tab2 AS cor0
----
189
303342
69283

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2268
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-2268
SELECT ALL + cor0.col1 * - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * + ( + col0 ) + + col2 FROM tab0 cor0
----
1226
609
8003

query I rowsort
SELECT DISTINCT + col1 * ( 60 ) AS col1 FROM tab0 AS cor0
----
5160
5460
5820

onlyif mysql # use DIV operator for integer division
query I rowsort label-2271
SELECT ALL + cor0.col1 DIV + 69 + + ( col0 ) FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-2271
SELECT ALL + cor0.col1 / + 69 + + ( col0 ) FROM tab0 AS cor0
----
25
36
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2272
SELECT - col1 DIV cor0.col0 - - col1 AS col0 FROM tab0 AS cor0
----
83
90
95

skipif mysql # not compatible
query I rowsort label-2272
SELECT - col1 / cor0.col0 - - col1 AS col0 FROM tab0 AS cor0
----
83
90
95

query I rowsort
SELECT DISTINCT + - col0 * - 33 * + 87 + + col1 * - col1 AS col1 FROM tab2 AS cor0
----
19136
220457
226520

query I rowsort
SELECT DISTINCT + col2 - - col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL col1 + + ( + 24 ) - col1 AS col1 FROM tab0 AS cor0
----
24
24
24

query I rowsort
SELECT - + cor0.col0 * col1 + 5 FROM tab2 AS cor0
----
-1338
-212
-4597

query I rowsort
SELECT DISTINCT - col2 * - 72 + - 80 FROM tab0 cor0
----
-8
2296
5824

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + 0 col0 FROM tab2
----
17
31
59

query I rowsort
SELECT - ( - col1 * col0 ) - col0 FROM tab2
----
1264
210
4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-2280
SELECT DISTINCT ( col1 ) DIV - col0 FROM tab1
----
-8
0

skipif mysql # not compatible
query I rowsort label-2280
SELECT DISTINCT ( col1 ) / - col0 FROM tab1
----
-8
0

query I rowsort
SELECT ALL 56 * col0 AS col1 FROM tab0 AS cor0
----
1344
1960
4984

query I rowsort
SELECT DISTINCT - ( 11 ) FROM tab1 AS cor0
----
-11

query I rowsort
SELECT ALL - col2 + - col0 + - col1 FROM tab2 cor0
----
-134
-163
-65

query I rowsort
SELECT ALL 17 * cor0.col2 FROM tab1 AS cor0
----
1632
918
969

onlyif mysql # use DIV operator for integer division
query I rowsort label-2285
SELECT 34 DIV ( col1 ) FROM tab1 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-2285
SELECT 34 / ( col1 ) FROM tab1 AS cor0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + col0 * - col1 col0 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT DISTINCT 28 AS col0 FROM tab2 AS cor0
----
28

query I rowsort
SELECT ALL - col0 + col1 * + ( 99 ) + - col2 FROM tab2 AS cor0
----
1566
3035
5737

query I rowsort
SELECT 35 - cor1.col0 AS col2 FROM tab1, tab0 AS cor0, tab2 cor1, tab1 cor2
----
81 values hashing to f0bfac671f6ef050256d54726000a66b

query I rowsort
SELECT DISTINCT - 46 * - cor0.col1 + cor0.col1 FROM tab0 AS cor0
----
4042
4277
4559

query I rowsort
SELECT - col2 * + col1 * ( ( - col1 ) ) FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT ALL ( cor0.col2 ) + + ( + col0 ) * + col2 FROM tab1 AS cor0
----
216
3705
7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-2293
SELECT + col2 + col1 DIV tab1.col1 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-2293
SELECT + col2 + col1 / tab1.col1 FROM tab1
----
55
58
97

query I rowsort
SELECT DISTINCT ( col1 ) * + col0 AS col1 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2295
SELECT DISTINCT - - 35 * - col2 DIV + col2 FROM tab1 AS cor0
----
-35

skipif mysql # not compatible
query I rowsort label-2295
SELECT DISTINCT - - 35 * - col2 / + col2 FROM tab1 AS cor0
----
-35

query I rowsort
SELECT + 28 * - col0 FROM tab2 AS cor0
----
-196
-2184
-2212

query I rowsort
SELECT ALL + 26 FROM tab2 AS cor0
----
26
26
26

query I rowsort
SELECT ALL + 15 * - cor0.col2 FROM tab1 cor0
----
-1440
-810
-855

query I rowsort
SELECT 65 * - col2 * + 24 AS col0 FROM tab2 AS cor0
----
-40560
-42120
-59280

query I rowsort
SELECT ALL + 31 FROM tab1 AS cor0
----
31
31
31

query I rowsort
SELECT - col0 * 0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - - 95 AS col1 FROM tab1 AS cor0
----
95
95
95

query I rowsort
SELECT ALL - col1 * - col2 + col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT + col0 + col1 * + col0 - - 41 AS col1 FROM tab0 AS cor0
----
2129
3471
8229

query I rowsort
SELECT + + ( - ( - col0 ) ) * + ( ( col0 ) ) * - col1 + + col1 AS col0 FROM tab0 AS cor0
----
-118728
-49450
-720720

query I rowsort
SELECT col1 + ( 1 + - col2 ) FROM tab2
----
-20
34
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-2307
SELECT col2 * col1 + col1 DIV + 61 AS col0 FROM tab1
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-2307
SELECT col2 * col1 + col1 / + 61 AS col0 FROM tab1
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-2308
SELECT ALL col2 DIV ( - col1 ) AS col2 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-2308
SELECT ALL col2 / ( - col1 ) AS col2 FROM tab1
----
-2
-5
-7

query I rowsort
SELECT ALL + + cor0.col1 + + col1 * col0 AS col0 FROM tab0 cor0
----
2150
3492
8190

query I rowsort
SELECT ALL 94 - col1 AS col1 FROM tab0 AS cor0
----
-3
3
8

query I rowsort
SELECT DISTINCT col2 * col0 * col0 AS col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT ALL ( cor0.col1 ) FROM tab0, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT col2 + 38 AS col2 FROM tab1
----
134
92
95

query I rowsort
SELECT + col1 * - col1 AS col2 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT - col2 - col0 * col2 AS col1 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT + col2 * + col2 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
2913
3185
9136

query I rowsort
SELECT + tab2.col0 AS col0 FROM tab2, tab0 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query I rowsort
SELECT + cor0.col1 * col2 + - cor0.col2 * col0 FROM tab0 AS cor0
----
164
2046
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2319
SELECT col1 DIV - col1 + cor0.col2 AS col0 FROM tab1 cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-2319
SELECT col1 / - col1 + cor0.col2 AS col0 FROM tab1 cor0
----
53
56
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-2320
SELECT ALL + col2 DIV tab0.col2 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2320
SELECT ALL + col2 / tab0.col2 FROM tab0
----
1
1
1

query I rowsort
SELECT ALL + col1 * col1 + col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT DISTINCT + col1 * col0 AS col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT col0 * cor0.col0 + - col2 * - col1 AS col0 FROM tab1 AS cor0
----
1413
4666
7648

query I rowsort
SELECT col1 - - col0 * col2 FROM tab1
----
188
3658
7693

query I rowsort
SELECT - col1 - + col1 AS col0 FROM tab0
----
-172
-182
-194

query IIIIIIIII rowsort
SELECT * FROM tab1, tab2, tab2 AS cor0 WHERE NOT NULL <> ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2327
SELECT DISTINCT + col0 + - col1 DIV + col1 FROM tab2
----
6
77
78

skipif mysql # not compatible
query I rowsort label-2327
SELECT DISTINCT + col0 + - col1 / + col1 FROM tab2
----
6
77
78

query I rowsort
SELECT col1 - - col1 AS col2 FROM tab1
----
20
26
52

query I rowsort
SELECT tab0.col2 * - col0 AS col1 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT - tab1.col1 * - col2 FROM tab1
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2331
SELECT + CAST( 85 * + tab1.col1 AS SIGNED ) FROM tab1
----
1105
2210
850

skipif mysql # not compatible
query I rowsort label-2331
SELECT + CAST ( 85 * + tab1.col1 AS INTEGER ) FROM tab1
----
1105
2210
850

query I rowsort
SELECT col1 + 29 * - col1 FROM tab2
----
-1652
-476
-868

query I rowsort
SELECT - + 52 * + col0 AS col1 FROM tab0 AS cor0
----
-1248
-1820
-4628

query I rowsort
SELECT ALL col2 * + 74 FROM tab1
----
3996
4218
7104

query I rowsort
SELECT DISTINCT ( - col0 * + col2 ) FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL + tab2.col1 * - tab2.col1 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT col1 * col0 * + col0 AS col2 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT + + ( col0 ) * col0 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT ALL - + ( col2 ) FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - col0 + + col1 FROM tab0
----
2
62

query I rowsort
SELECT ALL tab0.col1 AS col2 FROM tab0 WHERE NOT NULL < NULL
----

query I rowsort
SELECT DISTINCT - col1 AS col2 FROM tab2 WHERE NULL < NULL
----

query I rowsort
SELECT DISTINCT - col0 * + col0 * + col2 + + col0 FROM tab2
----
-1316
-158106
-237079

query I rowsort
SELECT col2 FROM tab1 WHERE - col0 * col0 NOT IN ( - tab1.col2 + - tab1.col0 - - col1 * tab1.col2 )
----
54
57
96

query I rowsort
SELECT + col0 * tab1.col1 FROM tab1
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2346
SELECT ALL col0 + - col0 DIV col0 AS col2 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-2346
SELECT ALL col0 + - col0 / col0 AS col2 FROM tab1
----
2
63
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-2347
SELECT col0 + col1 + - tab0.col0 DIV col1 col0 FROM tab0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2347
SELECT col0 + col1 + - tab0.col0 / col1 col0 FROM tab0
----
110
132
180

query I rowsort
SELECT ALL + col0 + col1 * + tab1.col0 AS col1 FROM tab1 WHERE NOT ( + col1 * - col2 + - col0 ) NOT BETWEEN NULL AND ( + col0 )
----

query I rowsort
SELECT DISTINCT + col2 FROM tab0 WHERE ( NULL ) IN ( - col2 * - col1 + col0 )
----

query I rowsort
SELECT DISTINCT - col1 * + col0 AS col0 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT col1 * col1 + col2 * col0 + col1 FROM tab2
----
1181
3308
5568

query I rowsort
SELECT ALL - tab1.col0 * + col2 AS col0 FROM tab1
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2353
SELECT col1 DIV tab1.col0 + + col2 * + col1 * col0 + tab1.col0 AS col2 FROM tab1
----
36544
4223
99920

skipif mysql # not compatible
query I rowsort label-2353
SELECT col1 / tab1.col0 + + col2 * + col1 * col0 + tab1.col0 AS col2 FROM tab1
----
36544
4223
99920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col0 * col0 col0 FROM tab1
----
-4096
-6400
-9

query III rowsort
SELECT * FROM tab1 WHERE NOT ( NULL ) NOT IN ( tab1.col2 * + col1 * - col2 + + col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2356
SELECT DISTINCT + col2 DIV col1 + + col1 - col0 AS col1 FROM tab1
----
-49
-60
25

skipif mysql # not compatible
query I rowsort label-2356
SELECT DISTINCT + col2 / col1 + + col1 - col0 AS col1 FROM tab1
----
-49
-60
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col2 + + col0 col1 FROM tab2
----
182
196
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + col0 col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT col2 * col2 * col1 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT - col1 * + col1 * col1 FROM tab0
----
-636056
-753571
-912673

query I rowsort
SELECT DISTINCT - col2 FROM tab0 WHERE NOT ( col2 * - col0 + - col0 * col2 ) NOT IN ( - col0 )
----

query I rowsort
SELECT DISTINCT col1 * col0 AS col2 FROM tab0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2363
SELECT - tab1.col2 * - col0 + col1 DIV + col1 FROM tab1
----
163
3649
7681

skipif mysql # not compatible
query I rowsort label-2363
SELECT - tab1.col2 * - col0 + col1 / + col1 FROM tab1
----
163
3649
7681

query I rowsort
SELECT - col2 * col0 * + col1 + + col1 + col1 * + col0 FROM tab0 AS cor0
----
-655928
-65962
97

query I rowsort
SELECT ALL - col0 * + col0 FROM tab1 WHERE tab1.col0 + col2 IN ( tab1.col2 * + col2 )
----

query I rowsort
SELECT + col0 + col0 * - col0 FROM tab1
----
-4032
-6
-6320

query I rowsort
SELECT DISTINCT + col2 * + col2 + + col0 AS col0 FROM tab2
----
1523
736
754

query I rowsort
SELECT col0 * cor0.col1 + cor0.col2 AS col2 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL + col2 + + col1 + col0 * col0 AS col0 FROM tab1 AS cor0
----
4163
6509
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2370
SELECT + + cor0.col1 + - col2 DIV col2 AS col0 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-2370
SELECT + + cor0.col1 + - col2 / col2 AS col0 FROM tab0 AS cor0
----
85
90
96

query I rowsort
SELECT - cor0.col1 + cor0.col2 + col0 * col1 AS col2 FROM tab1 AS cor0
----
106
1123
687

query I rowsort
SELECT DISTINCT col0 FROM tab2 AS cor0 WHERE ( NULL ) BETWEEN NULL AND col0 + col0 OR NOT NULL >= NULL
----

query I rowsort
SELECT cor0.col0 * - col0 + - col2 FROM tab2 AS cor0
----
-6110
-6279
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-2374
SELECT + + col1 DIV - col2 + col2 + + col2 * cor0.col0 FROM tab0 AS cor0
----
-61
7379
823

skipif mysql # not compatible
query I rowsort label-2374
SELECT + + col1 / - col2 + col2 + + col2 * cor0.col0 FROM tab0 AS cor0
----
-61
7379
823

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NULL IN ( col1 - col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col0 * - col2 col0 FROM tab0 cor0
----
26136
35
598436

onlyif mysql # use DIV operator for integer division
query I rowsort label-2377
SELECT DISTINCT col2 * - cor0.col0 DIV + col0 FROM tab2 AS cor0 WHERE NOT - col2 = ( + col1 * + col0 )
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-2377
SELECT DISTINCT col2 * - cor0.col0 / + col0 FROM tab2 AS cor0 WHERE NOT - col2 = ( + col1 * + col0 )
----
-26
-27
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-2378
SELECT ALL + col1 * col0 DIV col0 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2378
SELECT ALL + col1 * col0 / col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + col1 AS col1 FROM tab1 cor0 WHERE NOT col1 < col1
----
10
13
26

query I rowsort
SELECT col1 * + col1 * col2 FROM tab1 WHERE NOT ( col1 ) > + col2 + col2
----
16224
36504
5700

query I rowsort
SELECT + 67 AS col2 FROM tab0 AS cor0
----
67
67
67

query I rowsort
SELECT DISTINCT + - 57 + - col2 AS col1 FROM tab0 AS cor0
----
-139
-58
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2383
SELECT DISTINCT + + 13 DIV col0 + col0 FROM tab2 AS cor0
----
78
79
8

skipif mysql # not compatible
query I rowsort label-2383
SELECT DISTINCT + + 13 / col0 + col0 FROM tab2 AS cor0
----
78
79
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 54 col0 FROM tab0 AS cor0
----
54
54
54

query I rowsort
SELECT 97 AS col0 FROM tab0 AS cor0
----
97
97
97

query I rowsort
SELECT DISTINCT + - 19 * cor0.col0 + col0 FROM tab0 AS cor0
----
-1602
-432
-630

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2387
SELECT + + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2387
SELECT + + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 18 + - col2 * col0 FROM tab2 AS cor0
----
-2046
-207
-3020

onlyif mysql # use DIV operator for integer division
query I rowsort label-2389
SELECT ALL - - col2 * col0 DIV + cor0.col0 AS col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2389
SELECT ALL - - col2 * col0 / + cor0.col0 AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT col2 + + col0 * + col2 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-2391
SELECT + col1 DIV - ( + ( + col2 ) ) - + col1 AS col2 FROM tab0
----
-194
-88
-92

skipif mysql # not compatible
query I rowsort label-2391
SELECT + col1 / - ( + ( + col2 ) ) - + col1 AS col2 FROM tab0
----
-194
-88
-92

query I rowsort
SELECT ALL + tab0.col1 * - 5 FROM tab0
----
-430
-455
-485

query I rowsort
SELECT ALL 4 * - col1 + col1 * col2 AS col1 FROM tab1
----
1196
1300
530

query I rowsort
SELECT ALL col0 - - col2 FROM tab1
----
121
176
57

query I rowsort
SELECT - col1 * col1 + + col0 * 0 + - col1 * + col0 FROM tab0
----
-12804
-16380
-9460

query I rowsort
SELECT 82 AS col0 FROM tab0, tab2 cor0 CROSS JOIN tab2
----
27 values hashing to 99920d9f7cd9cdccef99cfa459ae6944

query I rowsort
SELECT - 97 + col1 AS col0 FROM tab2 cor0
----
-38
-66
-80

query I rowsort
SELECT ALL - ( col2 ) + + cor0.col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT - - ( + cor0.col2 ) * col2 - - 91 AS col2 FROM tab1 AS cor0
----
3007
3340
9307

onlyif mysql # use DIV operator for integer division
query I rowsort label-2400
SELECT DISTINCT + cor0.col1 + col1 DIV col0 AS col0 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-2400
SELECT DISTINCT + cor0.col1 + col1 / col0 AS col0 FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT DISTINCT - 14 - + col1 FROM tab0 cor0
----
-100
-105
-111

query I rowsort
SELECT ALL + + col0 * 81 AS col0 FROM tab0 AS cor0
----
1944
2835
7209

query I rowsort
SELECT ALL + 58 AS col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 9ee363c6ac19cfdb8a50c7dfd5cc2b8a

query I rowsort
SELECT - + col0 * + ( col0 ) AS col2 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL + cor0.col1 * + 13 FROM tab0 AS cor0
----
1118
1183
1261

query I rowsort
SELECT col1 * - col1 + - 8 FROM tab1
----
-108
-177
-684

query I rowsort
SELECT - col0 + - cor0.col2 * + cor0.col0 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT DISTINCT tab2.col2 + col1 * - 29 AS col0 FROM tab2
----
-1685
-455
-872

query I rowsort
SELECT col0 + - col2 * + tab0.col2 FROM tab0
----
-1065
-6635
34

query I rowsort
SELECT col1 * + 62 + tab2.col0 FROM tab2
----
1133
1929
3736

query I rowsort
SELECT ALL - - col1 - + col1 AS col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2412
SELECT col0 + - 2 DIV col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2412
SELECT col0 + - 2 / col1 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 - + col2 col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT - col2 + - ( - col0 ) FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2415
SELECT ALL col1 * - CAST( NULL AS SIGNED ) * + 48 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2415
SELECT ALL col1 * - CAST ( NULL AS INTEGER ) * + 48 AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col0 * - 66 AS col2 FROM tab0 AS cor0
----
-1584
-2310
-5874

query I rowsort
SELECT DISTINCT col0 + col0 AS col1 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT col0 + - 13 FROM tab2 AS cor0
----
-6
65
66

query I rowsort
SELECT ALL - col2 + - col1 * + col1 FROM tab1 cor0
----
-157
-265
-730

query I rowsort
SELECT DISTINCT + + col0 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2421
SELECT + cor0.col1 + - col2 * - 38 * - col0 + + col2 DIV + col0 AS col2 FROM tab1 cor0
----
-138614
-291826
-6112

skipif mysql # not compatible
query I rowsort label-2421
SELECT + cor0.col1 + - col2 * - 38 * - col0 + + col2 / + col0 AS col2 FROM tab1 cor0
----
-138614
-291826
-6112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2422
SELECT CAST( col0 AS SIGNED ) + - cor0.col2 * - col2 AS col1 FROM tab0 AS cor0
----
1113
36
6813

skipif mysql # not compatible
query I rowsort label-2422
SELECT CAST ( col0 AS INTEGER ) + - cor0.col2 * - col2 AS col1 FROM tab0 AS cor0
----
1113
36
6813

onlyif mysql # use DIV operator for integer division
query I rowsort label-2423
SELECT DISTINCT - - col2 DIV 48 - + col2 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-2423
SELECT DISTINCT - - col2 / 48 - + col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT 91 * + cor0.col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 3bb8b0ae7730338f8d9e91a83d5538a6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2425
SELECT - - col0 * cor0.col2 DIV col0 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-2425
SELECT - - col0 * cor0.col2 / col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - + col1 + 95 * + col1 FROM tab1 AS cor0
----
1222
2444
940

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2427
SELECT CAST( + col0 AS SIGNED ) FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2427
SELECT CAST ( + col0 AS INTEGER ) FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2428
SELECT - col1 + CAST( NULL AS SIGNED ) col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2428
SELECT - col1 + CAST ( NULL AS INTEGER ) col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 57 FROM tab2, tab0 AS cor0
----
-57

query IIIIII rowsort
SELECT ALL * FROM tab1, tab2 cor0 WHERE NULL NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT - 0 AS col0 FROM tab1, tab2 AS cor0
----
0

query I rowsort
SELECT 36 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
132
90
93

query I rowsort
SELECT - 63 * - ( cor0.col0 ) AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 017daa55605ea2553df31867b1638263

onlyif mysql # use DIV operator for integer division
query I rowsort label-2434
SELECT - col1 DIV + col2 + + 18 FROM tab1 AS cor0
----
18
18
18

skipif mysql # not compatible
query I rowsort label-2434
SELECT - col1 / + col2 + + 18 FROM tab1 AS cor0
----
18
18
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2435
SELECT ALL + col1 * col0 + - CAST( col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
1978
3298
8008

skipif mysql # not compatible
query I rowsort label-2435
SELECT ALL + col1 * col0 + - CAST ( col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
1978
3298
8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-2436
SELECT ALL - - col0 + col1 DIV cor0.col2 AS col2 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-2436
SELECT ALL - - col0 + col1 / cor0.col2 AS col2 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + + col0 + + col0 + + col2 AS col2 FROM tab1 AS cor0
----
185
256
60

query I rowsort
SELECT - 25 * + col0 FROM tab0
----
-2225
-600
-875

query I rowsort
SELECT DISTINCT - 15 + + col1 FROM tab2 AS cor0
----
16
2
44

query I rowsort
SELECT + 0 * col1 + col0 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2441
SELECT DISTINCT + col0 + col2 DIV + col0 AS col1 FROM tab0 cor0
----
25
35
89

skipif mysql # not compatible
query I rowsort label-2441
SELECT DISTINCT + col0 + col2 / + col0 AS col1 FROM tab0 cor0
----
25
35
89

query I rowsort
SELECT col1 * col2 + - col2 AS col2 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT + - col2 * ( + col2 ) AS col0 FROM tab0 cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-2444
SELECT + col1 DIV - ( - col0 ) + col0 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-2444
SELECT + col1 / - ( - col0 ) + col0 FROM tab1 AS cor0
----
11
64
80

query I rowsort
SELECT - col0 * - col1 + - col0 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT col0 + ( - col2 ) * - col2 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT + col1 * col0 + - col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT ALL + tab2.col1 + col0 * + 47 * 65 AS col1 FROM tab2
----
21416
238349
241362

query I rowsort
SELECT - cor0.col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT DISTINCT + col0 * col2 + 11 FROM tab2
----
200
2039
3013

onlyif mysql # use DIV operator for integer division
query I rowsort label-2451
SELECT ALL col1 DIV col0 + 54 * + tab1.col0 + + col0 AS col2 FROM tab1
----
173
3520
4400

skipif mysql # not compatible
query I rowsort label-2451
SELECT ALL col1 / col0 + 54 * + tab1.col0 + + col0 AS col2 FROM tab1
----
173
3520
4400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + + col0 + 9 col2 FROM tab1
----
9
9
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col1 * col0 col2 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT ALL - - 77 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT tab2.col1 + + 72 FROM tab2, tab1 cor0
----
9 values hashing to 765edb99c0b97dffc91a059697db17fc

onlyif mysql # use DIV operator for integer division
query I rowsort label-2456
SELECT - - 75 DIV cor0.col0 FROM tab2 AS cor0
----
0
0
10

skipif mysql # not compatible
query I rowsort label-2456
SELECT - - 75 / cor0.col0 FROM tab2 AS cor0
----
0
0
10

query I rowsort
SELECT - col2 + col1 * - ( - col0 * + col2 ) FROM tab0 AS cor0
----
3394
664036
68079

query I rowsort
SELECT - col0 + + cor0.col2 + col0 AS col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT + - col2 * col0 + col1 * - col2 FROM tab0 cor0
----
-132
-14760
-3630

query I rowsort
SELECT - + col0 + + col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT + col0 + - col0 - cor0.col1 * + col2 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2462
SELECT ALL - + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2462
SELECT ALL - + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - col0 * + col1 - col0 * col1 FROM tab0 AS cor0
----
-16198
-4128
-6790

query I rowsort
SELECT ALL - - col2 * + ( + col0 ) + col0 * - col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col2 + 70 AS col2 FROM tab2 AS cor0
----
108
96
97

query I rowsort
SELECT - + col1 + ( - col1 ) AS col0 FROM tab1 cor0
----
-20
-26
-52

query I rowsort
SELECT 58 * - 21 * col0 + col2 * col0 AS col1 FROM tab0
----
-101104
-28440
-42595

query I rowsort
SELECT - - ( col0 ) AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - ( col1 ) * col2 + ( 56 ) + + col2 FROM tab2 AS cor0
----
-1452
-552
-754

query I rowsort
SELECT DISTINCT + 40 AS col2 FROM tab1, tab0 AS cor0
----
40

query I rowsort
SELECT DISTINCT + 20 AS col1 FROM tab0, tab0 AS cor0
----
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-2472
SELECT ALL col0 + cor0.col0 DIV - 42 AS col2 FROM tab0 AS cor0
----
24
35
87

skipif mysql # not compatible
query I rowsort label-2472
SELECT ALL col0 + cor0.col0 / - 42 AS col2 FROM tab0 AS cor0
----
24
35
87

query I rowsort
SELECT ALL - - col2 * col1 * - 9 FROM tab2 AS cor0
----
-13806
-5814
-7533

query I rowsort
SELECT DISTINCT col0 * tab0.col1 FROM tab0
----
2064
3395
8099

query I rowsort
SELECT ALL cor0.col1 FROM tab0, tab1 AS cor0, tab0 cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + 94 * col1 * + col0 AS col1 FROM tab0 AS cor0
----
194016
319130
761306

query I rowsort
SELECT cor0.col2 + col0 * - 55 FROM tab2 AS cor0
----
-358
-4264
-4307

query I rowsort
SELECT DISTINCT cor0.col0 * col2 + - ( + col0 * - col2 ) FROM tab2 AS cor0
----
378
4056
6004

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 10 col2 FROM tab1 cor0
----
10
10
10

query I rowsort
SELECT DISTINCT - col0 * col0 - - col1 FROM tab1 AS cor0
----
-4086
-6387
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 18 * cor0.col0 col2 FROM tab1 cor0
----
-1152
-1440
-54

query I rowsort
SELECT ALL - col2 + cor0.col0 FROM tab0 cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT - + 15 * - col1 FROM tab1 AS cor0
----
150
195
390

onlyif mysql # use DIV operator for integer division
query I rowsort label-2484
SELECT ALL + col1 DIV - cor0.col2 + 51 FROM tab1 AS cor0
----
51
51
51

skipif mysql # not compatible
query I rowsort label-2484
SELECT ALL + col1 / - cor0.col2 + 51 FROM tab1 AS cor0
----
51
51
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-2485
SELECT ALL col0 * col1 - - col2 DIV + col0 FROM tab2 AS cor0
----
1343
220
4602

skipif mysql # not compatible
query I rowsort label-2485
SELECT ALL col0 * col1 - - col2 / + col0 FROM tab2 AS cor0
----
1343
220
4602

query I rowsort
SELECT DISTINCT - 93 AS col1 FROM tab2
----
-93

query I rowsort
SELECT DISTINCT + col2 * 88 FROM tab1
----
4752
5016
8448

query I rowsort
SELECT - col0 * cor0.col0 AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2489
SELECT DISTINCT - col2 DIV - col2 AS col0 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-2489
SELECT DISTINCT - col2 / - col2 AS col0 FROM tab0 AS cor0
----
1

query I rowsort
SELECT ALL ( 44 ) AS col1 FROM tab1 AS cor0
----
44
44
44

query I rowsort
SELECT DISTINCT col0 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT - col1 * tab2.col1 + 89 FROM tab2
----
-200
-3392
-872

query I rowsort
SELECT + col1 + ( col1 ) * col1 FROM tab0
----
7482
8372
9506

query I rowsort
SELECT + col0 + - 18 + col1 AS col0 FROM tab1
----
11
56
75

query I rowsort
SELECT DISTINCT - col1 - tab2.col2 * ( col2 ) * - col1 FROM tab2
----
22568
24531
39825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 20 - + col1 col2 FROM tab2
----
-13
16
41

query I rowsort
SELECT 16 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT - ( 30 ) AS col0 FROM tab0 AS cor0
----
-30
-30
-30

onlyif mysql # use DIV operator for integer division
query I rowsort label-2499
SELECT ALL + col1 DIV - col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2499
SELECT ALL + col1 / - col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 76 + 16 col2 FROM tab0 AS cor0
----
92
92
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-2501
SELECT DISTINCT - ( 27 ) DIV + col1 + col0 * 78 * col1 FROM tab1 AS cor0
----
49918
6083
81118

skipif mysql # not compatible
query I rowsort label-2501
SELECT DISTINCT - ( 27 ) / + col1 + col0 * 78 * col1 FROM tab1 AS cor0
----
49918
6083
81118

query I rowsort
SELECT DISTINCT - col0 * - col1 * col1 + ( + col0 ) AS col1 FROM tab0 AS cor0
----
177528
329350
737098

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - ( + cor0.col2 ) - + col1 col1 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT - 6 + + 8 AS col0 FROM tab0 AS cor0
----
2
2
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + 0 * col0 * - col2 col2 FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT ALL + col2 - - col0 AS col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - + ( + col1 ) + col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col2 * col0 + col1 FROM tab0 cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-2509
SELECT col1 + 21 DIV - ( col0 ) AS col0 FROM tab1 AS cor0
----
10
13
19

skipif mysql # not compatible
query I rowsort label-2509
SELECT col1 + 21 / - ( col0 ) AS col0 FROM tab1 AS cor0
----
10
13
19

query I rowsort
SELECT + - col0 + col2 AS col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL - + cor0.col1 * col1 AS col1 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT col1 * ( cor0.col0 * cor0.col1 ) + - cor0.col0 + + col2 AS col0 FROM tab1 AS cor0
----
13536
2079
6393

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2513
SELECT + + cor0.col2 * - CAST( NULL AS SIGNED ) + - col1 + + cor0.col1 * + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2513
SELECT + + cor0.col2 * - CAST ( NULL AS INTEGER ) + - col1 + + cor0.col1 * + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + + col2 + cor0.col1 * 37 * cor0.col1 FROM tab2 AS cor0
----
10731
128823
35584

query I rowsort
SELECT + - col2 + - col1 + col1 * col1 FROM tab2 AS cor0
----
234
3396
903

query I rowsort
SELECT + 91 AS col0 FROM tab1 AS cor0
----
91
91
91

query I rowsort
SELECT - + 9 * + col1 FROM tab2 AS cor0
----
-153
-279
-531

onlyif mysql # use DIV operator for integer division
query I rowsort label-2518
SELECT DISTINCT col0 DIV 38 AS col0 FROM tab1 cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-2518
SELECT DISTINCT col0 / 38 AS col0 FROM tab1 cor0
----
0
1
2

query I rowsort
SELECT + ( + 47 ) FROM tab0 AS cor0
----
47
47
47

query I rowsort
SELECT ALL 9 FROM tab2 AS cor0
----
9
9
9

query I rowsort
SELECT - 95 * ( col2 ) FROM tab0 AS cor0
----
-3135
-7790
-95

query I rowsort
SELECT DISTINCT + - 12 * col0 FROM tab0 AS cor0
----
-1068
-288
-420

query I rowsort
SELECT ALL + 56 * + col2 + + col0 AS col1 FROM tab0 AS cor0
----
1872
4681
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 62 col0 FROM tab1 AS cor0
----
62
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2525
SELECT ALL tab2.col1 DIV - col0 col0 FROM tab2
----
-4
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2525
SELECT ALL tab2.col1 / - col0 col0 FROM tab2
----
-4
0
0

query I rowsort
SELECT ALL - col2 * + col1 - col2 AS col0 FROM tab2 AS cor0
----
-1560
-684
-864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + cor0.col2 col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT - ( - cor0.col2 ) + col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT + - 49 * col0 + cor0.col1 FROM tab2 AS cor0
----
-312
-3763
-3854

query I rowsort
SELECT DISTINCT - + col1 + col2 AS col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT DISTINCT cor0.col0 + col1 + + cor0.col2 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT ALL - col0 + col0 * ( 78 ) FROM tab2 AS cor0
----
539
6006
6083

query I rowsort
SELECT - col0 * col1 + 2 * - col0 FROM tab2 AS cor0
----
-1501
-231
-4758

query I rowsort
SELECT DISTINCT + col2 * + col2 + + ( + 44 * col1 ) AS col0 FROM tab1 AS cor0
----
3689
4060
9788

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 + + col2 col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL - ( col1 ) - col2 AS col0 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT col1 - col2 * - col2 AS col1 FROM tab2
----
1461
735
760

query I rowsort
SELECT + 36 + 40 FROM tab1
----
76
76
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col2 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT DISTINCT - 80 * col1 + + col1 FROM tab2 cor0
----
-1343
-2449
-4661

query I rowsort
SELECT col1 + col1 + + col1 AS col2 FROM tab1 AS cor0
----
30
39
78

query I rowsort
SELECT ALL - + 62 AS col1 FROM tab2 AS cor0
----
-62
-62
-62

query I rowsort
SELECT DISTINCT tab0.col2 * col2 + - 69 AS col2 FROM tab0
----
-68
1020
6655

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2544
SELECT + + col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2544
SELECT + + col0 + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( tab0.col0 * col1 ) FROM tab0
----
2064
3395
8099

query I rowsort
SELECT col0 * + col1 * tab2.col1 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT - - col2 * 51 + 80 FROM tab0 AS cor0
----
131
1763
4262

query I rowsort
SELECT + - cor0.col2 * - col0 + - col0 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT - col2 * 46 + 40 FROM tab0 AS cor0
----
-1478
-3732
-6

query I rowsort
SELECT - col1 + col0 * col2 * + col2 AS col0 FROM tab0 AS cor0
----
-62
26050
598345

query I rowsort
SELECT 64 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

query I rowsort
SELECT + 87 FROM tab0 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT - cor1.col2 FROM tab1, tab0 AS cor0, tab1 cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT tab0.col2 + + 61 AS col1 FROM tab0
----
143
62
94

query I rowsort
SELECT DISTINCT + col1 * col1 AS col1 FROM tab1 cor0
----
100
169
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT - cor0.col0 * + col0 FROM tab0 cor0
----
-1225
-576
-7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2558
SELECT ALL + CAST( NULL AS SIGNED ) + - cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2558
SELECT ALL + CAST ( NULL AS INTEGER ) + - cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 + cor0.col0 * col1 AS col2 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT 11 FROM tab1, tab2 AS cor0
----
11

query I rowsort
SELECT + + 37 + cor0.col0 AS col1 FROM tab0 AS cor0
----
126
61
72

query I rowsort
SELECT ALL - + 9 * - col1 + + col1 FROM tab1 cor0
----
100
130
260

query I rowsort
SELECT DISTINCT + col1 * - col2 AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - 88 * - col1 AS col1 FROM tab2 AS cor0
----
1496
2728
5192

query I rowsort
SELECT + cor0.col2 + cor0.col0 + + cor0.col2 * - col0 AS col2 FROM tab1 AS cor0
----
-105
-3527
-7504

query I rowsort
SELECT ALL - + 3 * col0 FROM tab0 AS cor0
----
-105
-267
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 29 * col2 col1 FROM tab0 AS cor0
----
2378
29
957

onlyif mysql # use DIV operator for integer division
query I rowsort label-2568
SELECT + col2 + - col2 DIV + ( col1 ) AS col0 FROM tab1 cor0
----
52
52
89

skipif mysql # not compatible
query I rowsort label-2568
SELECT + col2 + - col2 / + ( col1 ) AS col0 FROM tab1 cor0
----
52
52
89

query I rowsort
SELECT - + ( - cor0.col2 ) + - col0 FROM tab1 AS cor0
----
-7
16
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * cor0.col2 col0 FROM tab1 AS cor0
----
162
3648
7680

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab0, tab1 cor1, tab1 AS cor2
----
972 values hashing to d222ba302bd1ddd1c8b2ddf1a4d0b07a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2572
SELECT DISTINCT - col2 + CAST( col0 AS SIGNED ) + col0 AS col0 FROM tab0
----
15
69
96

skipif mysql # not compatible
query I rowsort label-2572
SELECT DISTINCT - col2 + CAST ( col0 AS INTEGER ) + col0 AS col0 FROM tab0
----
15
69
96

query I rowsort
SELECT DISTINCT 51 * + col0 * - col1 AS col0 FROM tab2
----
-11067
-234702
-68493

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * - col0 col1 FROM tab2 cor0
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 57 col2 FROM tab0, tab0 AS cor0
----
57

query I rowsort
SELECT - ( - tab2.col0 ) * col0 + col0 * col1 FROM tab2
----
10686
266
7584

query I rowsort
SELECT ALL - 44 * tab0.col1 AS col2 FROM tab0
----
-3784
-4004
-4268

query I rowsort
SELECT + - 16 * - 31 FROM tab0 AS cor0
----
496
496
496

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0, tab1 cor1, tab0 cor2
----
972 values hashing to 5e655b1287771868a8f868574a94d749

query I rowsort
SELECT - col0 * + 3 FROM tab0 AS cor0
----
-105
-267
-72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 * - col2 col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT + col1 + - col0 * - col1 + 26 * + col0 AS col0 FROM tab0 AS cor0
----
10504
2774
4402

onlyif mysql # use DIV operator for integer division
query I rowsort label-2583
SELECT DISTINCT + col1 * + col1 DIV - col1 FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-2583
SELECT DISTINCT + col1 * + col1 / - col1 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT - 29 * - col0 AS col1 FROM tab2
----
203
2262
2291

onlyif mysql # use DIV operator for integer division
query I rowsort label-2585
SELECT + 69 DIV + col1 + + ( - col1 ) AS col1 FROM tab2 AS cor0
----
-13
-29
-58

skipif mysql # not compatible
query I rowsort label-2585
SELECT + 69 / + col1 + + ( - col1 ) AS col1 FROM tab2 AS cor0
----
-13
-29
-58

query I rowsort
SELECT - 40 * col1 + - col0 * cor0.col0 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
-160544
-237838
-2563

query I rowsort
SELECT - - col2 + + 27 * - 61 + col2 FROM tab2 AS cor0
----
-1571
-1593
-1595

onlyif mysql # use DIV operator for integer division
query I rowsort label-2588
SELECT - - col1 DIV + col2 FROM tab0 cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-2588
SELECT - - col1 / + col2 FROM tab0 cor0
----
1
2
97

query I rowsort
SELECT + col0 * - cor0.col1 * + col2 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT + col1 + - ( 92 ) + + col0 * - col1 FROM tab2 AS cor0
----
-1418
-278
-4635

query I rowsort
SELECT + col0 * col1 * 67 FROM tab0 AS cor0
----
138288
227465
542633

query I rowsort
SELECT col2 * + ( + col1 ) + col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT + cor0.col0 * + 16 + + 14 + + cor0.col1 AS col2 FROM tab2 AS cor0
----
1295
1321
157

query I rowsort
SELECT ALL 36 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to eee96a85519f92856a7500dc8b6cf752

query I rowsort
SELECT DISTINCT + - col2 * + 52 FROM tab1 AS cor0
----
-2808
-2964
-4992

query I rowsort
SELECT DISTINCT cor0.col2 * - col2 AS col0 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL - col1 + + ( ( col2 ) ) FROM tab2
----
-33
-4
21

query I rowsort
SELECT ALL + - col0 + + col2 AS col2 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2599
SELECT ALL col0 DIV + col2 + + col1 col1 FROM tab1 AS cor0
----
11
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2599
SELECT ALL col0 / + col2 + + col1 col1 FROM tab1 AS cor0
----
11
13
26

query I rowsort
SELECT DISTINCT - col0 + 63 AS col1 FROM tab1 AS cor0
----
-1
-17
60

query I rowsort
SELECT ALL - + col2 * 33 + col0 * col2 + col0 FROM tab0 AS cor0
----
-273
37
4681

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2602
SELECT DISTINCT + cor0.col1 + + CAST( col1 AS SIGNED ) + col1 FROM tab1 AS cor0
----
30
39
78

skipif mysql # not compatible
query I rowsort label-2602
SELECT DISTINCT + cor0.col1 + + CAST ( col1 AS INTEGER ) + col1 FROM tab1 AS cor0
----
30
39
78

query I rowsort
SELECT DISTINCT + 56 + col0 AS col1 FROM tab0 AS cor0
----
145
80
91

query I rowsort
SELECT DISTINCT - 55 + + col1 * + cor0.col1 FROM tab0 AS cor0
----
7341
8226
9354

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * cor0.col1 col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - col1 * ( + col0 + + 8 * cor0.col1 ) AS col0 FROM tab0 AS cor0
----
-61232
-74347
-78667

query I rowsort
SELECT + 29 + col0 AS col2 FROM tab2 AS cor0
----
107
108
36

query I rowsort
SELECT DISTINCT + ( - col2 ) * + col0 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + col2 col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL - - 98 FROM tab2 cor0
----
98
98
98

query I rowsort
SELECT ALL + 51 + - col1 FROM tab1 AS cor0
----
25
38
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-2612
SELECT DISTINCT + + 77 * ( + col1 ) + + col1 * 2 DIV + cor0.col0 + - col1 FROM tab0 AS cor0
----
6543
6918
7377

skipif mysql # not compatible
query I rowsort label-2612
SELECT DISTINCT + + 77 * ( + col1 ) + + col1 * 2 / + cor0.col0 + - col1 FROM tab0 AS cor0
----
6543
6918
7377

query I rowsort
SELECT - cor0.col1 * col2 + col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT cor0.col1 + - cor0.col2 FROM tab2 AS cor0
----
-21
33
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + + 44 col0 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to e598e6783e1ea47ed1cb350c2563a05d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2616
SELECT ALL col2 + - CAST( NULL AS DECIMAL ) col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2616
SELECT ALL col2 + - CAST ( NULL AS REAL ) col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 - - col1 * 10 AS col1 FROM tab1
----
164
210
263

query I rowsort
SELECT ALL col2 + tab1.col2 FROM tab1
----
108
114
192

query I rowsort
SELECT + 95 * col1 - ( + col2 + col0 ) AS col0 FROM tab1 AS cor0
----
1059
2413
829

query I rowsort
SELECT ALL + 14 * - col0 AS col0 FROM tab0 AS cor0
----
-1246
-336
-490

query I rowsort
SELECT DISTINCT - + 39 * col0 + + cor0.col0 FROM tab0 AS cor0
----
-1330
-3382
-912

query I rowsort
SELECT ALL - col0 + - col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT ALL - + 67 + + col2 * ( col2 ) AS col2 FROM tab2 AS cor0
----
1377
609
662

query I rowsort
SELECT - + col1 - cor0.col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT DISTINCT col1 + - cor0.col2 * 37 + col1 * col2 AS col2 FROM tab0 AS cor0
----
157
1703
4519

query I rowsort
SELECT col2 * col0 + col2 FROM tab2 AS cor0
----
2054
216
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-2627
SELECT ALL + - col1 * col1 + 86 DIV + 24 + + col1 AS col0 FROM tab1 AS cor0
----
-153
-647
-87

skipif mysql # not compatible
query I rowsort label-2627
SELECT ALL + - col1 * col1 + 86 / + 24 + + col1 AS col0 FROM tab1 AS cor0
----
-153
-647
-87

query I rowsort
SELECT - 46 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 491ad1fb79fec0b5715ea54949d1aa2d

query I rowsort
SELECT ALL - 24 AS col2 FROM tab1
----
-24
-24
-24

query I rowsort
SELECT col0 * col1 * - 92 + 42 FROM tab1 AS cor0
----
-58838
-7134
-95638

query I rowsort
SELECT 87 AS col1 FROM tab1 AS cor0
----
87
87
87

query I rowsort
SELECT ALL - col1 + + col1 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2633
SELECT ALL + 27 + col1 + + col2 DIV col2 FROM tab1
----
38
41
54

skipif mysql # not compatible
query I rowsort label-2633
SELECT ALL + 27 + col1 + + col2 / col2 FROM tab1
----
38
41
54

query I rowsort
SELECT ALL + tab2.col1 AS col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL - 84 + 15 FROM tab2
----
-69
-69
-69

query I rowsort
SELECT - col1 - + col0 * - col2 FROM tab1
----
136
3638
7667

query I rowsort
SELECT + 78 * 45 + + col2 FROM tab1 cor0
----
3564
3567
3606

query I rowsort
SELECT + 13 + - cor0.col1 * - col0 * - col0 FROM tab2 AS cor0
----
-106084
-1506
-358943

query I rowsort
SELECT DISTINCT + cor0.col0 * col1 + + 45 FROM tab1 AS cor0
----
1085
123
685

query I rowsort
SELECT col2 + + cor0.col2 * - 19 AS col1 FROM tab0 AS cor0
----
-1476
-18
-594

query I rowsort
SELECT DISTINCT - cor0.col2 * + col0 + - col2 * ( col0 * - col1 ) FROM tab1 AS cor0
----
32832
4050
92160

query I rowsort
SELECT ALL + + 49 + + col2 FROM tab2 AS cor0
----
75
76
87

query I rowsort
SELECT ALL 28 * col2 AS col0 FROM tab0 AS cor0
----
2296
28
924

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2644
SELECT DISTINCT + + col1 + - col0 * - CAST( col1 AS SIGNED ) * col1 FROM tab0 AS cor0
----
177590
329412
737100

skipif mysql # not compatible
query I rowsort label-2644
SELECT DISTINCT + + col1 + - col0 * - CAST ( col1 AS INTEGER ) * col1 FROM tab0 AS cor0
----
177590
329412
737100

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 78 * + col0 col2 FROM tab0
----
1872
2730
6942

onlyif mysql # use DIV operator for integer division
query I rowsort label-2646
SELECT ALL cor0.col2 DIV col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2646
SELECT ALL cor0.col2 / col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + - col2 * col1 * - col1 AS col0 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT - 84 + - cor0.col0 FROM tab2 AS cor0
----
-162
-163
-91

query I rowsort
SELECT + - col0 * cor0.col0 * + cor0.col1 AS col1 FROM tab0 cor0
----
-118825
-49536
-720811

onlyif mysql # use DIV operator for integer division
query I rowsort label-2650
SELECT DISTINCT col1 * - col0 + - col0 + - 72 DIV - ( col2 ) FROM tab1
----
-1120
-703
-80

skipif mysql # not compatible
query I rowsort label-2650
SELECT DISTINCT col1 * - col0 + - col0 + - 72 / - ( col2 ) FROM tab1
----
-1120
-703
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2651
SELECT DISTINCT col0 * col1 + tab1.col0 * + CAST( - 6 + - col2 AS SIGNED ) * + ( - col2 ) AS col0 FROM tab1
----
230464
784400
9798

skipif mysql # not compatible
query I rowsort label-2651
SELECT DISTINCT col0 * col1 + tab1.col0 * + CAST ( - 6 + - col2 AS INTEGER ) * + ( - col2 ) AS col0 FROM tab1
----
230464
784400
9798

query I rowsort
SELECT ALL + col2 - cor0.col1 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT ALL + + col2 + col0 * - col1 AS col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT - col0 * ( col0 ) FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL cor0.col0 * + col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab1, tab1 cor1, tab2 cor2, tab2 cor3
----
3645 values hashing to 1a92b418ae3c05ba566f88a890a407ae

query I rowsort
SELECT ALL col1 * - ( + col0 ) AS col1 FROM tab2 cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-2658
SELECT - col0 * cor0.col1 DIV - 61 FROM tab1 AS cor0
----
1
10
17

skipif mysql # not compatible
query I rowsort label-2658
SELECT - col0 * cor0.col1 / - 61 FROM tab1 AS cor0
----
1
10
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2659
SELECT DISTINCT - col0 + - CAST( NULL AS SIGNED ) * - 78 + col2 * col1 col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2659
SELECT DISTINCT - col0 + - CAST ( NULL AS INTEGER ) * - 78 + col2 * col1 col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + - col0 + col0 + col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT - cor0.col1 + - col2 + col0 AS col2 FROM tab2 AS cor0
----
-51
-7
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-2662
SELECT + + col2 DIV col2 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2662
SELECT + + col2 / col2 AS col0 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2663
SELECT ALL - - col0 + + CAST( NULL AS SIGNED ) * - 68 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2663
SELECT ALL - - col0 + + CAST ( NULL AS INTEGER ) * - 68 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + + col0 * - col0 col0 FROM tab0 AS cor0
----
-1224
-543
-7839

onlyif mysql # use DIV operator for integer division
query I rowsort label-2665
SELECT + col0 DIV cor0.col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-2665
SELECT + col0 / cor0.col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT ALL + 68 * - 51 + + col1 AS col1 FROM tab0 AS cor0
----
-3371
-3377
-3382

query I rowsort
SELECT col1 + col0 * col1 AS col1 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT ALL 99 * col1 AS col2 FROM tab2 AS cor0
----
1683
3069
5841

query I rowsort
SELECT ALL + + cor0.col0 * - 92 + col2 * + col0 FROM tab0 AS cor0
----
-1416
-3185
-890

query I rowsort
SELECT + 44 + + 94 FROM tab2 AS cor0
----
138
138
138

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2671
SELECT ALL - col2 * - CAST( col0 AS SIGNED ) + + col0 * + col1 - + col2 FROM tab2
----
379
4307
6604

skipif mysql # not compatible
query I rowsort label-2671
SELECT ALL - col2 * - CAST ( col0 AS INTEGER ) + + col0 * + col1 - + col2 FROM tab2
----
379
4307
6604

query I rowsort
SELECT - - col1 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2673
SELECT col1 + cor0.col1 DIV col1 col1 FROM tab1 AS cor0
----
11
14
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2673
SELECT col1 + cor0.col1 / col1 col1 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT ALL - + col2 * + cor0.col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + - col1 - ( col1 ) FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT DISTINCT + ( + cor0.col2 ) * col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2677
SELECT ALL - - col2 DIV col1 + + col0 FROM tab2 AS cor0
----
7
78
81

skipif mysql # not compatible
query I rowsort label-2677
SELECT ALL - - col2 / col1 + + col0 FROM tab2 AS cor0
----
7
78
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2678
SELECT + ( - col0 ) * col2 + CAST( col1 AS SIGNED ) FROM tab1 AS cor0
----
-136
-3638
-7667

skipif mysql # not compatible
query I rowsort label-2678
SELECT + ( - col0 ) * col2 + CAST ( col1 AS INTEGER ) FROM tab1 AS cor0
----
-136
-3638
-7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-2679
SELECT - - 31 * 25 + col2 DIV 77 col0 FROM tab2 AS cor0
----
775
775
775

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2679
SELECT - - 31 * 25 + col2 / 77 col0 FROM tab2 AS cor0
----
775
775
775

query I rowsort
SELECT + 55 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

query I rowsort
SELECT + 98 * col2 AS col1 FROM tab1 AS cor0
----
5292
5586
9408

query I rowsort
SELECT col2 + 8 * - col0 FROM tab1
----
-455
-544
30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2683
SELECT col0 * CAST( NULL AS SIGNED ) + col0 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2683
SELECT col0 * CAST ( NULL AS INTEGER ) + col0 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + 17 * col1 AS col1 FROM tab0 AS cor0
----
1462
1547
1649

query I rowsort
SELECT ALL - 63 * - col1 + col0 AS col2 FROM tab2
----
1150
1960
3795

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab2 AS cor0, tab2 AS cor1, tab0, tab1 cor2
----
3645 values hashing to d865c68b86e66898eeac28f450e48e70

query I rowsort
SELECT DISTINCT - 22 FROM tab2
----
-22

query I rowsort
SELECT + 11 AS col0 FROM tab1
----
11
11
11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2689
SELECT ALL ( cor0.col1 * CAST( NULL AS SIGNED ) ) col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2689
SELECT ALL ( cor0.col1 * CAST ( NULL AS INTEGER ) ) col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL + 95 FROM tab2, tab2 AS cor0
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor1.col0 col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL - cor0.col1 + + col2 AS col2 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT - col1 * + 6 FROM tab0 AS cor0
----
-516
-546
-582

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2694
SELECT DISTINCT + CAST( NULL AS SIGNED ) AS col0 FROM tab1, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2694
SELECT DISTINCT + CAST ( NULL AS INTEGER ) AS col0 FROM tab1, tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2695
SELECT DISTINCT - + col2 DIV ( + col0 ) AS col2 FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-2695
SELECT DISTINCT - + col2 / ( + col0 ) AS col2 FROM tab0 AS cor0
----
-1
0

query I rowsort
SELECT DISTINCT + col1 + col0 * - col1 * col2 FROM tab0 AS cor0
----
-3298
-664027
-68026

query I rowsort
SELECT - - col1 + + col0 * + cor0.col1 FROM tab2 cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT - cor0.col2 * - cor0.col2 + col2 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL - col0 + - col2 - col2 * col1 FROM tab2 AS cor0
----
-1638
-763
-871

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) + + col1 * col0 FROM tab0 cor0
----
2150
3492
8190

query I rowsort
SELECT ALL + + cor0.col2 * + cor0.col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2702
SELECT - 87 DIV cor0.col0 + col1 * + col2 FROM tab1 AS cor0
----
1247
1375
569

skipif mysql # not compatible
query I rowsort label-2702
SELECT - 87 / cor0.col0 + col1 * + col2 FROM tab1 AS cor0
----
1247
1375
569

query I rowsort
SELECT ALL - ( ( - col2 ) ) AS col0 FROM tab2
----
26
27
38

query I rowsort
SELECT + tab1.col2 * - col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT cor0.col0 * + col2 FROM tab2 cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-2706
SELECT - + cor0.col0 + col0 + + cor0.col1 DIV - col0 AS col1 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-2706
SELECT - + cor0.col0 + col0 + + cor0.col1 / - col0 AS col1 FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT ALL + col1 + - col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL - 59 AS col1 FROM tab2 AS cor0
----
-59
-59
-59

query I rowsort
SELECT - col0 * + col0 AS col2 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT - 28 * - col1 FROM tab0
----
2408
2548
2716

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2711
SELECT DISTINCT - CAST( NULL AS SIGNED ) * cor0.col1 / col0 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2711
SELECT DISTINCT - CAST ( NULL AS INTEGER ) * cor0.col1 / col0 AS col1 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2712
SELECT - col2 DIV col0 AS col1 FROM tab1
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-2712
SELECT - col2 / col0 AS col1 FROM tab1
----
-1
-18
0

query I rowsort
SELECT DISTINCT + + cor0.col2 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
26
27
38

query I rowsort
SELECT + col0 * - col1 - + cor0.col1 * cor0.col0 AS col2 FROM tab2 cor0
----
-2686
-434
-9204

query I rowsort
SELECT ALL + + ( col0 ) + col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + 71 + col0 FROM tab0 AS cor0
----
106
160
95

query I rowsort
SELECT DISTINCT - + col0 * col0 - col1 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT - ( + ( + tab1.col2 ) * + col0 ) AS col0 FROM tab1
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2719
SELECT col0 DIV 2 AS col0 FROM tab2
----
3
39
39

skipif mysql # not compatible
query I rowsort label-2719
SELECT col0 / 2 AS col0 FROM tab2
----
3
39
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2720
SELECT CAST( col2 AS SIGNED ) + col2 AS col1 FROM tab2
----
52
54
76

skipif mysql # not compatible
query I rowsort label-2720
SELECT CAST ( col2 AS INTEGER ) + col2 AS col1 FROM tab2
----
52
54
76

query I rowsort
SELECT DISTINCT + col2 + + col2 FROM tab1
----
108
114
192

query I rowsort
SELECT + 78 * + 33 AS col2 FROM tab2
----
2574
2574
2574

query I rowsort
SELECT DISTINCT + col2 + col1 AS col2 FROM tab1
----
109
67
80

query I rowsort
SELECT col0 * col0 + + col2 FROM tab0 AS cor0
----
1226
609
8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-2725
SELECT 1 DIV - cor0.col0 + + col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-2725
SELECT 1 / - cor0.col0 + + col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT - col1 + + col0 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT - ( + col1 ) + - col1 * - col2 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT ALL tab0.col0 + col2 * + col1 AS col0 FROM tab0
----
132
2862
7551

query I rowsort
SELECT ALL col1 + col2 * - col2 FROM tab1
----
-2890
-3239
-9203

onlyif mysql # use DIV operator for integer division
query I rowsort label-2730
SELECT DISTINCT tab0.col1 DIV col2 + - tab0.col0 - col0 FROM tab0
----
-177
-46
27

skipif mysql # not compatible
query I rowsort label-2730
SELECT DISTINCT tab0.col1 / col2 + - tab0.col0 - col0 FROM tab0
----
-177
-46
27

query I rowsort
SELECT ALL + col0 - tab0.col2 * - col1 AS col0 FROM tab0
----
132
2862
7551

query I rowsort
SELECT DISTINCT col0 + tab2.col0 AS col1 FROM tab2
----
14
156
158

query I rowsort
SELECT - col0 + col2 * col1 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT DISTINCT + - col0 + + cor0.col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - col2 + - col1 AS col1 FROM tab1
----
-109
-67
-80

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL >= - col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2737
SELECT ALL tab1.col2 + + col1 * col1 DIV tab1.col2 AS col1 FROM tab1
----
58
66
97

skipif mysql # not compatible
query I rowsort label-2737
SELECT ALL tab1.col2 + + col1 * col1 / tab1.col2 AS col1 FROM tab1
----
58
66
97

query I rowsort
SELECT DISTINCT - col2 * + col0 FROM tab2 AS cor0 WHERE NULL BETWEEN col1 * + col2 AND NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * - cor0.col2 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 315ab91f9844de122b0c28cd16e982e4

query I rowsort
SELECT DISTINCT - col0 * - col0 * - col2 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT ALL col2 * col1 + + col2 FROM tab0
----
2871
7544
98

query I rowsort
SELECT DISTINCT - col2 * + tab2.col2 + - col1 * + col0 FROM tab2
----
-2787
-5278
-946

query I rowsort
SELECT + col0 + col0 AS col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT col1 - + col1 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col1 + + col0 - - col0 AS col1 FROM tab0 AS cor0
----
134
167
269

query I rowsort
SELECT DISTINCT - col0 * col1 - - col2 AS col0 FROM tab1 cor0
----
-24
-583
-944

query I rowsort
SELECT cor0.col1 + + cor0.col2 FROM tab0 AS cor0
----
119
173
98

query IIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0 WHERE NOT ( NULL ) < ( NULL )
----

query I rowsort
SELECT DISTINCT - col2 * col2 + col1 FROM tab2 cor0
----
-1427
-617
-698

query I rowsort
SELECT DISTINCT + col0 - col2 * - col0 AS col2 FROM tab1 cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-2751
SELECT ALL col0 DIV col2 AS col1 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-2751
SELECT ALL col0 / col2 AS col1 FROM tab0
----
0
1
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-2752
SELECT + col0 + + col1 DIV col1 AS col1 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-2752
SELECT + col0 + + col1 / col1 AS col1 FROM tab0
----
25
36
90

query I rowsort
SELECT col2 + + col2 * - col2 FROM tab0
----
-1056
-6642
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2754
SELECT - col2 DIV cor0.col1 FROM tab2 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-2754
SELECT - col2 / cor0.col1 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT ALL - - col1 * col0 * + col0 AS col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT + col2 * - col0 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-2757
SELECT + - col0 * col1 DIV - col1 AS col2 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2757
SELECT + - col0 * col1 / - col1 AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL - + col2 * - col0 * - cor0.col2 AS col0 FROM tab2 cor0
----
-114076
-5103
-52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-2759
SELECT ALL + col1 DIV col1 col1 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2759
SELECT ALL + col1 / col1 col1 FROM tab0 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2760
SELECT + col0 DIV col0 col0 FROM tab2 cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2760
SELECT + col0 / col0 col0 FROM tab2 cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-2761
SELECT - col0 DIV + col0 FROM tab0 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2761
SELECT - col0 / + col0 FROM tab0 cor0
----
-1
-1
-1

query I rowsort
SELECT ALL col1 + + col1 FROM tab1 AS cor0
----
20
26
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - col0 col1 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-2764
SELECT DISTINCT - col2 DIV + col0 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
23
35
89

skipif mysql # not compatible
query I rowsort label-2764
SELECT DISTINCT - col2 / + col0 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
23
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2765
SELECT + + col1 * col2 DIV col1 AS col2 FROM tab2 cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-2765
SELECT + + col1 * col2 / col1 AS col2 FROM tab2 cor0
----
26
27
38

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE col0 * col0 > NULL OR NOT NULL IN ( + col2 )
----

query I rowsort
SELECT + col2 * + col0 - cor0.col1 AS col0 FROM tab0 cor0
----
-62
706
7207

query I rowsort
SELECT col2 - col0 AS col0 FROM tab1
----
-7
16
51

query I rowsort
SELECT ALL + col2 * + tab0.col0 FROM tab0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-2770
SELECT DISTINCT col1 - - col2 DIV col0 AS col2 FROM tab0 AS cor0
----
87
91
97

skipif mysql # not compatible
query I rowsort label-2770
SELECT DISTINCT col1 - - col2 / col0 AS col2 FROM tab0 AS cor0
----
87
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2771
SELECT - + col0 DIV - 24 + - col0 AS col1 FROM tab2 AS cor0
----
-7
-75
-76

skipif mysql # not compatible
query I rowsort label-2771
SELECT - + col0 / - 24 + - col0 AS col1 FROM tab2 AS cor0
----
-7
-75
-76

query I rowsort
SELECT + - col0 - ( ( col0 ) + + col2 ) AS col1 FROM tab2 AS cor0
----
-182
-196
-41

query I rowsort
SELECT - + col0 + + col1 AS col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT col1 - - 71 FROM tab0 AS cor0
----
157
162
168

query I rowsort
SELECT + cor0.col0 + - col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT - col1 * ( 86 ) * col2 + - col0 + ( col0 ) FROM tab1
----
-107328
-120744
-49020

query I rowsort
SELECT DISTINCT 96 AS col2 FROM tab1, tab0 cor0, tab2 AS cor1
----
96

query I rowsort
SELECT 61 AS col2 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

query I rowsort
SELECT DISTINCT + tab0.col2 * - col1 + col1 AS col1 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT + col2 * col0 + 64 FROM tab1
----
226
3712
7744

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 82 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

onlyif mysql # use DIV operator for integer division
query I rowsort label-2782
SELECT ALL col2 DIV ( - ( col0 ) ) FROM tab2
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-2782
SELECT ALL col2 / ( - ( col0 ) ) FROM tab2
----
-3
0
0

query I rowsort
SELECT ALL - + col1 + + col1 * col1 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT DISTINCT - col0 * + col2 + - col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT ALL + cor0.col2 + cor0.col1 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-2786
SELECT - tab1.col2 DIV - ( + col0 ) FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-2786
SELECT - tab1.col2 / - ( + col0 ) FROM tab1
----
0
1
18

query I rowsort
SELECT 57 * col1 FROM tab0 cor0
----
4902
5187
5529

query I rowsort
SELECT 49 AS col2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to a40d8754a5be3ce2309c61bfd3e00197

query I rowsort
SELECT ALL ( - col2 ) * - col2 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL + - col2 + col2 * cor0.col1 AS col0 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT - 96 * - col2 FROM tab2 AS cor0
----
2496
2592
3648

query I rowsort
SELECT + 69 + col0 * - col0 * - col0 FROM tab1
----
262213
512069
96

query I rowsort
SELECT DISTINCT + - 85 * col2 FROM tab2 AS cor0
----
-2210
-2295
-3230

query I rowsort
SELECT DISTINCT - ( - col1 ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + + 95 * - col1 AS col0 FROM tab2 AS cor0
----
-1615
-2945
-5605

query I rowsort
SELECT ALL + 44 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
-38
11
43

query I rowsort
SELECT ALL col2 * cor0.col1 + - col0 AS col2 FROM tab0 AS cor0
----
2814
62
7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 36 * col1 col2 FROM tab2 AS cor0
----
-1116
-2124
-612

query I rowsort
SELECT DISTINCT + - ( cor0.col0 ) * col2 * + col2 FROM tab1 AS cor0
----
-207936
-737280
-8748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + col2 + - col2 col1 FROM tab1 cor0
----
1152
1350
513

query I rowsort
SELECT DISTINCT - 72 * col2 AS col0 FROM tab2
----
-1872
-1944
-2736

onlyif mysql # use DIV operator for integer division
query I rowsort label-2802
SELECT DISTINCT + ( - col1 ) DIV - col0 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-2802
SELECT DISTINCT + ( - col1 ) / - col0 FROM tab0
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-2803
SELECT - 94 DIV + col0 FROM tab0 cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-2803
SELECT - 94 / + col0 FROM tab0 cor0
----
-1
-2
-3

query I rowsort
SELECT col0 * 37 FROM tab2 AS cor0
----
259
2886
2923

query I rowsort
SELECT + col1 * 32 FROM tab1 cor0
----
320
416
832

onlyif mysql # use DIV operator for integer division
query I rowsort label-2806
SELECT - col0 DIV + ( - ( col1 ) ) AS col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-2806
SELECT - col0 / + ( - ( col1 ) ) AS col1 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT ALL + col2 * - col0 - col0 FROM tab0
----
-70
-7387
-816

query I rowsort
SELECT col1 * + 82 + 98 FROM tab1 AS cor0
----
1164
2230
918

query I rowsort
SELECT DISTINCT + col0 + 75 * col1 AS col1 FROM tab1 AS cor0
----
1055
1953
814

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col1 + - col0 * 14 col1 FROM tab0 AS cor0
----
-1337
-422
-587

query I rowsort
SELECT + 29 AS col1 FROM tab1
----
29
29
29

query I rowsort
SELECT DISTINCT + 10 AS col2 FROM tab2
----
10

query I rowsort
SELECT + col1 * + 35 AS col2 FROM tab1 AS cor0
----
350
455
910

query I rowsort
SELECT ( + cor0.col0 ) + + col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT DISTINCT - col0 * + 81 * + col0 + - col0 + cor0.col1 FROM tab2 AS cor0
----
-3945
-492823
-505583

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 96 col2 FROM tab2 cor0
----
96
96
96

query I rowsort
SELECT + 14 + + 92 AS col1 FROM tab0 AS cor0
----
106
106
106

query I rowsort
SELECT ALL + 89 AS col1 FROM tab1 AS cor0
----
89
89
89

query I rowsort
SELECT + - col1 * + col0 * - col0 AS col2 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT - 59 * - 69 + + cor0.col1 + + col0 AS col1 FROM tab0 AS cor0
----
4181
4203
4251

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col0 + + col2 * - col1 + col0 col0 FROM tab2 AS cor0
----
-6808
-7540
-879

query I rowsort
SELECT 34 + - 64 * + col2 FROM tab0 AS cor0
----
-2078
-30
-5214

onlyif mysql # use DIV operator for integer division
query I rowsort label-2823
SELECT - - col2 DIV col2 AS col0 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2823
SELECT - - col2 / col2 AS col0 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT - - col2 * + col0 - cor0.col2 * col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL 75 + + 93 AS col0 FROM tab0
----
168
168
168

query I rowsort
SELECT ALL 93 + 78 * col0 AS col0 FROM tab2
----
6177
6255
639

onlyif mysql # use DIV operator for integer division
query I rowsort label-2827
SELECT ( + col1 ) + - col1 DIV CAST( - col0 * + col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2827
SELECT ( + col1 ) + - col1 / CAST ( - col0 * + col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT col0 + - 25 FROM tab2 cor0
----
-18
53
54

query I rowsort
SELECT DISTINCT + col2 * col1 + cor0.col0 * 43 AS col1 FROM tab1 AS cor0
----
1533
3322
4688

onlyif mysql # use DIV operator for integer division
query I rowsort label-2830
SELECT col2 * cor0.col2 DIV col1 FROM tab2 AS cor0
----
11
23
84

skipif mysql # not compatible
query I rowsort label-2830
SELECT col2 * cor0.col2 / col1 FROM tab2 AS cor0
----
11
23
84

query I rowsort
SELECT ALL + - col0 * 57 AS col0 FROM tab2 AS cor0
----
-399
-4446
-4503

query I rowsort
SELECT 55 - - col0 FROM tab0 cor0
----
144
79
90

query I rowsort
SELECT - 11 + col0 * col0 AS col1 FROM tab2 AS cor0
----
38
6073
6230

onlyif mysql # use DIV operator for integer division
query I rowsort label-2834
SELECT DISTINCT - 4 + ( + col2 ) DIV 55 col2 FROM tab2 AS cor0
----
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2834
SELECT DISTINCT - 4 + ( + col2 ) / 55 col2 FROM tab2 AS cor0
----
-4

query I rowsort
SELECT + col0 + - col0 * col2 AS col1 FROM tab1 AS cor0
----
-159
-3584
-7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-2836
SELECT 75 DIV - col1 FROM tab2 AS cor0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-2836
SELECT 75 / - col1 FROM tab2 AS cor0
----
-1
-2
-4

query I rowsort
SELECT col1 * - col0 + + cor0.col2 * col0 - + cor0.col2 AS col1 FROM tab0 cor0
----
-1305
-3361
-883

query I rowsort
SELECT ALL - 55 * - col0 + col2 AS col1 FROM tab0 AS cor0
----
1353
1926
4977

query I rowsort
SELECT DISTINCT - 77 AS col1 FROM tab0 AS cor0
----
-77

query I rowsort
SELECT DISTINCT 59 * col2 AS col1 FROM tab2 AS cor0
----
1534
1593
2242

query I rowsort
SELECT 62 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

onlyif mysql # use DIV operator for integer division
query I rowsort label-2842
SELECT ALL + col1 DIV + col2 + + 94 * + ( col1 ) FROM tab1 AS cor0
----
1222
2444
940

skipif mysql # not compatible
query I rowsort label-2842
SELECT ALL + col1 / + col2 + + 94 * + ( col1 ) FROM tab1 AS cor0
----
1222
2444
940

query I rowsort
SELECT DISTINCT ( - cor0.col2 ) FROM tab1, tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT + cor0.col2 * 27 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to f0321cf9fd3eef0e3f1c9529425df9d3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 10 col2 FROM tab0, tab2 AS cor0, tab2, tab2 AS cor1
----
81 values hashing to bf75e71325a06683558cf93fd725ad16

query IIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0 CROSS JOIN tab2 cor1
----
243 values hashing to ea21cea53be47edd19229592e3d26141

query I rowsort
SELECT col1 * - 23 FROM tab1 AS cor0
----
-230
-299
-598

query I rowsort
SELECT DISTINCT col0 * 63 FROM tab2 AS cor0
----
441
4914
4977

query I rowsort
SELECT ALL - cor0.col2 * 12 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 9e1f42d89ed4fe96e1beaed86d689cbb

query I rowsort
SELECT DISTINCT - + col1 + + col0 * col1 AS col1 FROM tab0 AS cor0
----
1978
3298
8008

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 57 col1 FROM tab1
----
57
57
57

query I rowsort
SELECT ALL + ( ( + col1 ) ) FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - - 52 * cor0.col1 - col0 AS col0 FROM tab2 AS cor0
----
1605
2990
805

query I rowsort
SELECT DISTINCT - col0 * + col2 + + col2 AS col0 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT - - ( 69 ) FROM tab0 cor0
----
69
69
69

query I rowsort
SELECT DISTINCT + - ( - 18 ) * col2 AS col0 FROM tab2 AS cor0
----
468
486
684

query I rowsort
SELECT - ( col0 ) + col2 FROM tab0 cor0
----
-34
-7
9

query I rowsort
SELECT ALL cor1.col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL col1 * - 86 FROM tab1
----
-1118
-2236
-860

query I rowsort
SELECT - col0 * ( col0 ) + - col1 FROM tab1
----
-35
-4106
-6413

query I rowsort
SELECT DISTINCT + 15 * + 80 FROM tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 AS cor2
----
1200

query I rowsort
SELECT DISTINCT - 59 + - col2 * tab0.col1 FROM tab0
----
-156
-2897
-7521

query I rowsort
SELECT DISTINCT + 13 - 59 FROM tab0
----
-46

query I rowsort
SELECT DISTINCT col2 * 45 + col1 AS col2 FROM tab2
----
1229
1246
1727

query I rowsort
SELECT DISTINCT 72 * - col0 FROM tab1 cor0
----
-216
-4608
-5760

query I rowsort
SELECT DISTINCT 31 FROM tab2, tab2 AS cor0, tab2 AS cor1, tab0 AS cor2
----
31

query I rowsort
SELECT ALL + col1 + + tab1.col1 AS col0 FROM tab1
----
20
26
52

query I rowsort
SELECT ALL 18 + col0 FROM tab1
----
21
82
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2869
SELECT - col2 DIV 55 + col2 AS col1 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-2869
SELECT - col2 / 55 + col2 AS col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL - - col1 + + 16 * + col0 * + col0 FROM tab1 AS cor0
----
102413
170
65546

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col2 + - col1 + + col0 * col0 col1 FROM tab0
----
-2348
1031
368

query I rowsort
SELECT - 7 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 82db7c0390abae7ccf4512b1302a6466

query I rowsort
SELECT DISTINCT 2 + - col1 * col0 * tab0.col0 AS col0 FROM tab0
----
-118823
-49534
-720809

query I rowsort
SELECT - cor0.col1 * col0 + col2 AS col0 FROM tab2 AS cor0
----
-1305
-190
-4576

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2875
SELECT ALL - col2 + - tab0.col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2875
SELECT ALL - col2 + - tab0.col0 + CAST ( NULL AS INTEGER ) AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 * col1 * 95 AS col1 FROM tab0 AS cor0
----
269610
708890
9215

query I rowsort
SELECT DISTINCT + + col1 + col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + cor0.col1 * 74 - - col0 AS col1 FROM tab0 AS cor0
----
6388
6823
7213

query I rowsort
SELECT ALL ( - 19 ) AS col2 FROM tab1, tab0 cor0
----
9 values hashing to 339c9d62143bf2f7566b89a1b56eeeb4

query I rowsort
SELECT ALL - col2 + + col0 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-2881
SELECT DISTINCT col0 DIV 53 AS col0 FROM tab1 cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-2881
SELECT DISTINCT col0 / 53 AS col0 FROM tab1 cor0
----
0
1

query I rowsort
SELECT DISTINCT - 98 * col0 AS col0 FROM tab1
----
-294
-6272
-7840

query I rowsort
SELECT DISTINCT + col2 * + col1 + - col0 AS col0 FROM tab2 AS cor0
----
1456
567
830

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2884
SELECT DISTINCT col1 + CAST( - col1 AS SIGNED ) FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-2884
SELECT DISTINCT col1 + CAST ( - col1 AS INTEGER ) FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2885
SELECT ALL col2 * ( 63 ) + - col2 * CAST( + col0 AS SIGNED ) - - cor0.col0 DIV - col1 AS col0 FROM tab0 AS cor0
----
-2132
1287
28

skipif mysql # not compatible
query I rowsort label-2885
SELECT ALL col2 * ( 63 ) + - col2 * CAST ( + col0 AS INTEGER ) - - cor0.col0 / - col1 AS col0 FROM tab0 AS cor0
----
-2132
1287
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-2886
SELECT ALL col2 DIV 7 FROM tab0 AS cor0
----
0
11
4

skipif mysql # not compatible
query I rowsort label-2886
SELECT ALL col2 / 7 FROM tab0 AS cor0
----
0
11
4

query I rowsort
SELECT DISTINCT - - col0 * col1 + col2 FROM tab2 AS cor0
----
1381
244
4628

query I rowsort
SELECT DISTINCT - + 18 FROM tab2 AS cor0
----
-18

query I rowsort
SELECT DISTINCT col0 * cor0.col0 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT + + 71 * col0 AS col2 FROM tab2 AS cor0
----
497
5538
5609

query I rowsort
SELECT ALL - cor0.col2 * col1 * col2 + - ( col2 ) AS col2 FROM tab2 AS cor0
----
-22626
-24586
-39910

query I rowsort
SELECT - - col1 * col2 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT - 63 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to fc0b533c2773a0a802e1fc8317dcebf2

onlyif mysql # use DIV operator for integer division
query I rowsort label-2894
SELECT tab0.col0 DIV + tab0.col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2894
SELECT tab0.col0 / + tab0.col0 FROM tab0
----
1
1
1

query I rowsort
SELECT DISTINCT 89 AS col2 FROM tab0, tab1, tab2 AS cor0
----
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 6 col1 FROM tab0
----
6
6
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-2897
SELECT col2 + 79 DIV + 11 FROM tab2 AS cor0
----
33
34
45

skipif mysql # not compatible
query I rowsort label-2897
SELECT col2 + 79 / + 11 FROM tab2 AS cor0
----
33
34
45

query I rowsort
SELECT - cor0.col0 + - 10 * + cor0.col1 FROM tab0 cor0
----
-1005
-884
-999

query I rowsort
SELECT DISTINCT tab1.col1 * + col2 * ( 37 ) FROM tab1
----
21090
46176
51948

query I rowsort
SELECT cor0.col1 AS col1 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT DISTINCT ( - col2 + + 84 ) FROM tab1
----
-12
27
30

onlyif mysql # use DIV operator for integer division
query I rowsort label-2902
SELECT DISTINCT col1 DIV tab0.col2 AS col1 FROM tab0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-2902
SELECT DISTINCT col1 / tab0.col2 AS col1 FROM tab0
----
1
2
97

query I rowsort
SELECT DISTINCT col2 * - tab1.col1 * col2 AS col1 FROM tab1
----
-119808
-32490
-75816

query I rowsort
SELECT + col0 * - col2 + col0 + col1 FROM tab0
----
-682
-7118
97

query I rowsort
SELECT ALL - tab2.col1 * col2 AS col0 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT - col1 AS col2 FROM tab2 WHERE ( NULL ) >= ( + col2 * col1 / col0 )
----

query I rowsort
SELECT + col1 + + col2 + - col1 FROM tab0
----
1
33
82

query I rowsort
SELECT + col0 + tab0.col1 * col0 AS col1 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT col2 * col2 + col1 AS col0 FROM tab2
----
1461
735
760

query I rowsort
SELECT + col0 - tab0.col1 AS col2 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT - col0 + col2 * col2 * col1 FROM tab1
----
119728
32426
75813

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT - col0 + col2 NOT IN ( col0 + + col2 )
----

query I rowsort
SELECT ALL tab0.col1 * col1 + col2 * tab0.col2 FROM tab0
----
15005
8485
9410

query I rowsort
SELECT DISTINCT + col2 * + col0 + + col1 FROM tab2
----
2087
220
3019

query I rowsort
SELECT DISTINCT + col1 * col1 AS col2 FROM tab2
----
289
3481
961

query III rowsort
SELECT ALL * FROM tab0 WHERE NULL > ( + col0 / - col1 )
----

query I rowsort
SELECT + col0 AS col0 FROM tab1 WHERE NOT NULL BETWEEN ( NULL ) AND col2 * - col2
----

query I rowsort
SELECT col1 + tab1.col1 AS col2 FROM tab1
----
20
26
52

query I rowsort
SELECT col2 + col0 FROM tab1 WHERE NULL < NULL
----

query I rowsort
SELECT DISTINCT col1 - + col1 * col2 AS col1 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT col2 * col2 FROM tab0 WHERE NOT ( col0 ) BETWEEN col1 * + col1 AND col2
----
1
1089
6724

query I rowsort
SELECT + tab1.col1 + tab1.col0 FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT col1 - col0 FROM tab2
----
-19
-62
24

query I rowsort
SELECT + col2 + col2 * col1 AS col2 FROM tab1
----
1344
1458
627

query I rowsort
SELECT + col0 + - col1 FROM tab1 WHERE NULL < col0
----

query I rowsort
SELECT ALL - col0 * - col2 AS col2 FROM tab0 WHERE ( col0 ) >= NULL
----

query I rowsort
SELECT ALL col2 * + col2 + - col1 * col1 FROM tab0
----
-1557
-6307
-9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 80 col2 FROM tab0
----
-80
-80
-80

query I rowsort
SELECT - - col1 + + col2 * col2 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT + - 6 + + cor0.col0 * + col2 AS col0 FROM tab1 AS cor0
----
156
3642
7674

onlyif mysql # use DIV operator for integer division
query I rowsort label-2931
SELECT + 46 + - col1 DIV + col0 AS col1 FROM tab2 AS cor0
----
42
46
46

skipif mysql # not compatible
query I rowsort label-2931
SELECT + 46 + - col1 / + col0 AS col1 FROM tab2 AS cor0
----
42
46
46

query I rowsort
SELECT - 87 FROM tab2, tab2 AS cor0
----
9 values hashing to 84bcab58a965cc8ae97b39d2d01b3d23

query I rowsort
SELECT tab0.col1 * + 35 AS col1 FROM tab0
----
3010
3185
3395

query I rowsort
SELECT DISTINCT - ( tab0.col1 ) AS col0 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT - - cor0.col2 + col2 * + cor0.col0 AS col1 FROM tab2 cor0
----
2054
216
3040

query I rowsort
SELECT - 67 * col0 FROM tab0 AS cor0
----
-1608
-2345
-5963

query I rowsort
SELECT - col2 * col1 + col0 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT - - col1 + col0 * col1 AS col0 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT + cor0.col2 + cor0.col0 AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + col2 * cor0.col0 AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT col2 + + col0 - - 4 AS col1 FROM tab0 AS cor0
----
175
40
61

query I rowsort
SELECT DISTINCT col2 * + col2 * - col0 FROM tab1 cor0
----
-207936
-737280
-8748

query I rowsort
SELECT - col2 * - ( col0 ) + cor0.col1 * col0 AS col0 FROM tab0 cor0
----
15397
2856
3430

onlyif mysql # use DIV operator for integer division
query I rowsort label-2944
SELECT DISTINCT - + col2 DIV - col2 AS col2 FROM tab1 cor0
----
1

skipif mysql # not compatible
query I rowsort label-2944
SELECT DISTINCT - + col2 / - col2 AS col2 FROM tab1 cor0
----
1

query I rowsort
SELECT + - col0 * 53 FROM tab0 cor0
----
-1272
-1855
-4717

query I rowsort
SELECT col1 * + col2 * + col1 + col0 AS col1 FROM tab0 AS cor0
----
244092
679131
9444

query I rowsort
SELECT - col2 + + cor0.col1 * cor0.col0 AS col1 FROM tab0 AS cor0
----
2031
3394
8017

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2948
SELECT DISTINCT + + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2948
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2949
SELECT DISTINCT + col1 DIV col1 + col0 DIV tab0.col2 FROM tab0
----
1
2
36

skipif mysql # not compatible
query I rowsort label-2949
SELECT DISTINCT + col1 / col1 + col0 / tab0.col2 FROM tab0
----
1
2
36

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + col1 * + CAST ( col2 AS REAL ) AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - + cor0.col2 - - col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL cor0.col1 * + col0 + col2 + - col0 AS col0 FROM tab2 AS cor0
----
1302
237
4550

query I rowsort
SELECT 96 AS col1 FROM tab2
----
96
96
96

query I rowsort
SELECT ( col0 ) * 0 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + cor0.col1 * + 54 col1 FROM tab2 cor0
----
1647
3160
880

query I rowsort
SELECT - - col1 + + 72 * col2 AS col2 FROM tab1 AS cor0
----
3914
4114
6925

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + 5 col2 FROM tab2
----
12
83
84

query I rowsort
SELECT DISTINCT - + cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab2 cor1
----
-1
-33
-82

query I rowsort
SELECT DISTINCT col0 * + col2 + - cor0.col0 + - col2 * - 4 AS col0 FROM tab0 cor0
----
4
7537
900

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2960
SELECT ALL col0 - CAST( NULL AS SIGNED ) / col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2960
SELECT ALL col0 - CAST ( NULL AS INTEGER ) / col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col0 * + 47 + - col1 * col1 FROM tab2 AS cor0
----
-1290
-4002
-7147

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2962
SELECT + cor0.col2 + - CAST( NULL AS SIGNED ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2962
SELECT + cor0.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 DISTINCT - col1 + + col1 col0 FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL + + cor0.col1 - - col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT DISTINCT col0 * - cor0.col0 * - col2 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT ALL + col0 + col2 + cor0.col0 FROM tab0 AS cor0
----
260
71
81

query I rowsort
SELECT DISTINCT cor0.col1 * + col1 * ( col1 ) + - col0 AS col2 FROM tab0 cor0
----
636032
753482
912638

query I rowsort
SELECT - cor0.col1 + ( + col1 + - col1 ) * 15 FROM tab2 cor0
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-2969
SELECT cor0.col0 DIV + 74 - + 13 FROM tab2 AS cor0
----
-12
-12
-13

skipif mysql # not compatible
query I rowsort label-2969
SELECT cor0.col0 / + 74 - + 13 FROM tab2 AS cor0
----
-12
-12
-13

query I rowsort
SELECT ALL + cor0.col0 + - col0 * col2 * col2 FROM tab2 AS cor0
----
-113997
-5096
-52650

query I rowsort
SELECT ALL + col1 + col0 * 42 FROM tab2 AS cor0
----
325
3335
3335

onlyif mysql # use DIV operator for integer division
query I rowsort label-2972
SELECT + tab2.col0 DIV - 8 + col0 FROM tab2
----
69
7
70

skipif mysql # not compatible
query I rowsort label-2972
SELECT + tab2.col0 / - 8 + col0 FROM tab2
----
69
7
70

query I rowsort
SELECT DISTINCT 52 FROM tab0, tab2 cor0
----
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 41 * + col2 col0 FROM tab0
----
1353
3362
41

query I rowsort
SELECT - 98 FROM tab1 AS cor0
----
-98
-98
-98

query I rowsort
SELECT DISTINCT 51 * 36 + - cor0.col0 FROM tab0 AS cor0
----
1747
1801
1812

onlyif mysql # use DIV operator for integer division
query I rowsort label-2977
SELECT ( + col2 ) DIV col2 FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-2977
SELECT ( + col2 ) / col2 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT - ( 66 ) AS col1 FROM tab0 AS cor0
----
-66
-66
-66

query I rowsort
SELECT + ( 70 ) * col2 AS col1 FROM tab2 AS cor0
----
1820
1890
2660

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2980
SELECT - CAST( + col0 AS SIGNED ) col2 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2980
SELECT - CAST ( + col0 AS INTEGER ) col2 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2981
SELECT ALL - col0 DIV col1 AS col2 FROM tab1 AS cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-2981
SELECT ALL - col0 / col1 AS col2 FROM tab1 AS cor0
----
-6
-6
0

query I rowsort
SELECT - ( + col2 ) * - col0 + - col1 FROM tab1 cor0
----
136
3638
7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col0 * - col0 col2 FROM tab1 cor0
----
4096
6400
9

query I rowsort
SELECT - cor0.col2 + cor0.col1 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query IIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0 CROSS JOIN tab0 cor1
----
243 values hashing to 5c33e96b85afe1ea51bb6d4e9fa6f993

onlyif mysql # use DIV operator for integer division
query I rowsort label-2986
SELECT DISTINCT - ( col0 ) DIV col1 + - 62 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
-1058
-1922
-3659

skipif mysql # not compatible
query I rowsort label-2986
SELECT DISTINCT - ( col0 ) / col1 + - 62 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
-1058
-1922
-3659

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 + col1 + - col1 col1 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT + 64 + + col0 AS col1 FROM tab1 cor0
----
128
144
67

query I rowsort
SELECT DISTINCT - col1 * - col1 + ( cor0.col2 ) AS col2 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT DISTINCT + col1 * col2 + 56 FROM tab0 cor0
----
153
2894
7518

query I rowsort
SELECT - + cor0.col2 + col2 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 69 FROM tab1 cor0
----
69
69
69

query I rowsort
SELECT ALL - col0 * + col0 + 89 * + ( col0 ) AS col2 FROM tab0 AS cor0
----
0
1560
1890

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 52 * col0 col0 FROM tab2 AS cor0
----
-364
-4056
-4108

query I rowsort
SELECT ALL + + cor0.col1 * col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL - 76 * col2 FROM tab1 AS cor0
----
-4104
-4332
-7296

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 93 col0 FROM tab2 AS cor0
----
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-2998
SELECT - - 26 DIV col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2998
SELECT - - 26 / col0 FROM tab0 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col2 ) + col0 col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT - col0 + - cor0.col0 FROM tab2 AS cor0
----
-14
-156
-158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 84 col0 FROM tab0 AS cor0
----
-84
-84
-84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * - col1 col0 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-3003
SELECT - + cor0.col1 DIV 17 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3003
SELECT - + cor0.col1 / 17 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT + - col1 + + 91 * + 30 FROM tab0 AS cor0
----
2633
2639
2644

query I rowsort
SELECT + col2 * + 52 FROM tab1 cor0
----
2808
2964
4992

onlyif mysql # use DIV operator for integer division
query I rowsort label-3006
SELECT ALL - - col1 + col0 DIV col0 AS col0 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-3006
SELECT ALL - - col1 + col0 / col0 AS col0 FROM tab1 AS cor0
----
11
14
27

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0, tab2 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to b225d3765f33551c12574f545c8c91eb

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 cor0, tab0 cor1, tab1, tab0 AS cor2
----
3645 values hashing to a3c09af95301183ccb084eb1936b14e3

onlyif mysql # use DIV operator for integer division
query I rowsort label-3009
SELECT ALL - col1 DIV - col0 AS col1 FROM tab1
----
0
0
8

skipif mysql # not compatible
query I rowsort label-3009
SELECT ALL - col1 / - col0 AS col1 FROM tab1
----
0
0
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3010
SELECT + - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3010
SELECT + - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - 79 - col2 AS col2 FROM tab1 AS cor0
----
-133
-136
-175

query I rowsort
SELECT ALL ( + col0 ) - + col2 FROM tab0 cor0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3013
SELECT ALL + CAST( + col0 AS SIGNED ) FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-3013
SELECT ALL + CAST ( + col0 AS INTEGER ) FROM tab2 AS cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3014
SELECT col0 * ( - col0 ) DIV + ( - 58 ) + + col2 AS col1 FROM tab2 AS cor0
----
130
145
27

skipif mysql # not compatible
query I rowsort label-3014
SELECT col0 * ( - col0 ) / + ( - 58 ) + + col2 AS col1 FROM tab2 AS cor0
----
130
145
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-3015
SELECT ALL - + CAST( col1 AS SIGNED ) + col1 DIV cor0.col1 AS col1 FROM tab0 cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-3015
SELECT ALL - + CAST ( col1 AS INTEGER ) + col1 / cor0.col1 AS col1 FROM tab0 cor0
----
-85
-90
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col1 ) + col2 col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT 26 * col0 + col2 AS col2 FROM tab2 AS cor0
----
2054
209
2092

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - 59 + cor0.col2 * ( col0 * + col2 ) col1 FROM tab1 AS cor0
----
204160
732560
8571

query I rowsort
SELECT ALL + col2 - col1 AS col0 FROM tab0
----
-53
-9
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 - 92 col1 FROM tab2
----
-13
-14
-85

query I rowsort
SELECT col1 * tab0.col1 + + col0 FROM tab0
----
7420
8370
9444

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1, tab1 AS cor0, tab2 AS cor1
----
972 values hashing to 0fcd8d0934383dd58863be894b07a6ed

query I rowsort
SELECT ALL + tab2.col1 + col1 FROM tab2
----
118
34
62

query I rowsort
SELECT DISTINCT - col2 + tab1.col1 + - col1 AS col1 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT col2 + - 58 * col1 AS col1 FROM tab2
----
-1771
-3396
-948

query I rowsort
SELECT + ( - col2 ) - - col2 AS col0 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3027
SELECT ALL 97 + + tab0.col1 DIV col2 AS col0 FROM tab0
----
194
98
99

skipif mysql # not compatible
query I rowsort label-3027
SELECT ALL 97 + + tab0.col1 / col2 AS col0 FROM tab0
----
194
98
99

query I rowsort
SELECT DISTINCT tab2.col1 + - 16 AS col0 FROM tab2
----
1
15
43

query I rowsort
SELECT ALL + 69 + + col0 FROM tab0
----
104
158
93

query I rowsort
SELECT DISTINCT - - ( - col0 ) + + col2 AS col0 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT - 4 * + col0 + + col2 + col2 * col2 AS col1 FROM tab0 AS cor0
----
-138
1026
6450

query I rowsort
SELECT ALL ( 71 ) + - col2 + col2 FROM tab0 cor0
----
71
71
71

query I rowsort
SELECT ALL + ( col2 ) * + col0 + col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL + + col1 * col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL - col1 + - col2 AS col2 FROM tab0
----
-119
-173
-98

query I rowsort
SELECT ALL col1 + + 17 FROM tab0
----
103
108
114

query I rowsort
SELECT 88 FROM tab0, tab1, tab1 AS cor0, tab2
----
81 values hashing to 663c36cf4bc51cf4ea19f7275ac6d30e

query I rowsort
SELECT cor0.col0 * col0 + cor0.col1 AS col1 FROM tab1 AS cor0
----
35
4106
6413

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 + - col1 col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - col1 * - col1 AS col2 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT col0 * - 56 + + col2 AS col1 FROM tab0 AS cor0
----
-1311
-1959
-4902

query I rowsort
SELECT ALL - col0 + ( + col0 + col1 ) AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + + cor0.col1 * + ( col0 ) FROM tab1 AS cor0
----
1040
640
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3044
SELECT ALL + - col2 DIV - ( col1 ) - - col2 FROM tab1 AS cor0
----
103
56
62

skipif mysql # not compatible
query I rowsort label-3044
SELECT ALL + - col2 / - ( col1 ) - - col2 FROM tab1 AS cor0
----
103
56
62

query I rowsort
SELECT DISTINCT - col2 * + ( col1 + col1 * ( col0 ) ) FROM tab1 cor0
----
-101088
-37050
-5616

query I rowsort
SELECT - col2 * 54 FROM tab2 AS cor0
----
-1404
-1458
-2052

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3047
SELECT + CAST( NULL AS SIGNED ) * - 92 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3047
SELECT + CAST ( NULL AS INTEGER ) * - 92 AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 5 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3049
SELECT ALL + 45 DIV + 24 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3049
SELECT ALL + 45 / + 24 AS col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL + - 63 * 34 FROM tab2 AS cor0
----
-2142
-2142
-2142

query I rowsort
SELECT 80 AS col2 FROM tab2 AS cor0
----
80
80
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * col0 col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT + cor0.col2 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3054
SELECT - - 59 DIV - col1 AS col1 FROM tab1 cor0
----
-2
-4
-5

skipif mysql # not compatible
query I rowsort label-3054
SELECT - - 59 / - col1 AS col1 FROM tab1 cor0
----
-2
-4
-5

query I rowsort
SELECT DISTINCT + ( + cor0.col1 ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL + 11 * - col0 FROM tab1 AS cor0
----
-33
-704
-880

query I rowsort
SELECT ALL - col2 * - col0 + col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT + col0 * cor0.col2 - 32 AS col2 FROM tab0 AS cor0
----
3
7266
760

query I rowsort
SELECT col1 * col2 * - col2 + + col2 AS col0 FROM tab1 cor0
----
-119712
-32433
-75762

query I rowsort
SELECT - cor0.col1 * + col0 + - ( - col0 ) - - col1 AS col2 FROM tab1 AS cor0
----
-49
-566
-947

onlyif mysql # use DIV operator for integer division
query I rowsort label-3061
SELECT DISTINCT + col2 + col1 DIV 65 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-3061
SELECT DISTINCT + col2 + col1 / 65 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT 71 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

query I rowsort
SELECT DISTINCT cor1.col0 FROM tab2, tab2 AS cor0, tab1 cor1, tab1 AS cor2
----
3
64
80

query I rowsort
SELECT + - 53 * + col0 + + col1 AS col1 FROM tab1 AS cor0
----
-133
-3382
-4227

onlyif mysql # use DIV operator for integer division
query I rowsort label-3065
SELECT + col0 DIV col2 - ( - col2 ) * col2 AS col1 FROM tab1 AS cor0
----
2916
3250
9216

skipif mysql # not compatible
query I rowsort label-3065
SELECT + col0 / col2 - ( - col2 ) * col2 AS col1 FROM tab1 AS cor0
----
2916
3250
9216

query I rowsort
SELECT + - cor0.col0 + - 66 * col1 FROM tab0 AS cor0
----
-5700
-6095
-6437

query I rowsort
SELECT + - cor0.col0 * 75 * col0 + + col0 FROM tab2 AS cor0
----
-3668
-456222
-467996

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3068
SELECT - col1 * + CAST( col0 * + col2 + col1 AS SIGNED ) FROM tab0 AS cor0
----
-12804
-672399
-75508

skipif mysql # not compatible
query I rowsort label-3068
SELECT - col1 * + CAST ( col0 * + col2 + col1 AS INTEGER ) FROM tab0 AS cor0
----
-12804
-672399
-75508

query I rowsort
SELECT - col1 * col0 * cor0.col0 AS col1 FROM tab1 AS cor0
----
-234
-40960
-83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-3070
SELECT - - col1 DIV + col2 + + col2 + col0 FROM tab1 AS cor0
----
121
176
57

skipif mysql # not compatible
query I rowsort label-3070
SELECT - - col1 / + col2 + + col2 + col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT 45 * + col0 FROM tab2
----
315
3510
3555

query I rowsort
SELECT DISTINCT col1 * - col1 * tab0.col2 + + 23 * + tab0.col1 FROM tab0
----
-242090
-676949
-7178

query I rowsort
SELECT DISTINCT 7 + col0 + ( - 43 ) * col2 AS col2 FROM tab0
----
-1
-1388
-3430

query I rowsort
SELECT DISTINCT - 57 AS col1 FROM tab0, tab1 AS cor0
----
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3075
SELECT col1 + 19 DIV - col2 AS col0 FROM tab0 AS cor0
----
78
86
91

skipif mysql # not compatible
query I rowsort label-3075
SELECT col1 + 19 / - col2 AS col0 FROM tab0 AS cor0
----
78
86
91

query I rowsort
SELECT + - col2 * - col2 + + col2 FROM tab0 AS cor0
----
1122
2
6806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 95 col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e57d8ed879dfd04d04aae87725c970d3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + 15 col0 FROM tab0 AS cor0
----
1290
1365
1455

query I rowsort
SELECT - 53 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to fee5c00ad71c23e23683a32c71fe6e7d

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3080
SELECT ALL + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3080
SELECT ALL + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3081
SELECT DISTINCT + CAST( NULL AS SIGNED ) / - col2 col1 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3081
SELECT DISTINCT + CAST ( NULL AS INTEGER ) / - col2 col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT ( 97 ) FROM tab1 AS cor0
----
97

query I rowsort
SELECT DISTINCT + tab2.col1 FROM tab2, tab1, tab1 AS cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - col2 + col0 col0 FROM tab0
----
-63
-84
-95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 17 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT tab0.col2 + ( - col1 ) FROM tab0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT col1 * - col1 + 7 + - tab2.col0 * + 72 AS col2 FROM tab2
----
-1458
-5970
-9090

query I rowsort
SELECT col0 * ( 33 ) * col1 FROM tab0
----
112035
267267
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-3089
SELECT CAST( 20 AS SIGNED ) + col1 * col2 DIV tab0.col2 FROM tab0
----
106
111
117

skipif mysql # not compatible
query I rowsort label-3089
SELECT CAST ( 20 AS INTEGER ) + col1 * col2 / tab0.col2 FROM tab0
----
106
111
117

query I rowsort
SELECT - 12 AS col0 FROM tab2 cor0
----
-12
-12
-12

query I rowsort
SELECT + 92 FROM tab2 cor0
----
92
92
92

query I rowsort
SELECT - 23 - 32 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to b90e74bece5521b514096c5b6e105fde

query I rowsort
SELECT DISTINCT + ( - col1 ) * col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ( 78 ) AS col0 FROM tab0
----
78
78
78

query I rowsort
SELECT ALL - ( - col0 + col2 * tab1.col0 ) AS col0 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT + 72 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 92cc3d5daa550304e96c1542787691c7

query I rowsort
SELECT 40 + col0 FROM tab0 AS cor0
----
129
64
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 89 * col0 - col1 * - 25 col0 FROM tab2 AS cor0
----
1398
7456
8417

query I rowsort
SELECT ALL - cor0.col1 - - cor0.col0 AS col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT DISTINCT - - 5 AS col1 FROM tab2 AS cor0
----
5

query I rowsort
SELECT DISTINCT 81 * - 54 + - col1 * + col2 FROM tab0 AS cor0
----
-11836
-4471
-7212

query I rowsort
SELECT - + ( col1 ) AS col0 FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT + ( 26 ) + - col0 * - col0 FROM tab2 AS cor0
----
6110
6267
75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + col1 col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL - col1 * + col2 - cor0.col0 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT ALL - col1 * - col1 + - col0 + col1 AS col1 FROM tab0 AS cor0
----
7458
8283
9471

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3107
SELECT DISTINCT - CAST( col0 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3107
SELECT DISTINCT - CAST ( col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - + col0 * + 77 + col1 * 68 AS col1 FROM tab0 cor0
----
-665
3901
4000

query I rowsort
SELECT DISTINCT col1 + + tab1.col2 * + 29 AS col0 FROM tab1
----
1592
1663
2797

query I rowsort
SELECT DISTINCT tab0.col0 + - 0 * col2 AS col2 FROM tab0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3111
SELECT ALL col2 + - col0 DIV + 1 FROM tab1
----
-7
16
51

skipif mysql # not compatible
query I rowsort label-3111
SELECT ALL col2 + - col0 / + 1 FROM tab1
----
-7
16
51

query I rowsort
SELECT tab2.col2 * tab2.col1 AS col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 00f153c5d80e692faff5018d8701b92d

query I rowsort
SELECT + - col1 * 78 FROM tab1 AS cor0
----
-1014
-2028
-780

query I rowsort
SELECT DISTINCT - ( cor0.col0 ) FROM tab1 cor0
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3115
SELECT - CAST( + col0 AS SIGNED ) + col1 AS col1 FROM tab2 cor0
----
-19
-62
24

skipif mysql # not compatible
query I rowsort label-3115
SELECT - CAST ( + col0 AS INTEGER ) + col1 AS col1 FROM tab2 cor0
----
-19
-62
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col2 col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - - col1 * + col2 + + col2 + + col1 AS col2 FROM tab2 AS cor0
----
1619
701
895

onlyif mysql # use DIV operator for integer division
query I rowsort label-3118
SELECT ALL col1 * col0 DIV col0 AS col0 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-3118
SELECT ALL col1 * col0 / col0 AS col0 FROM tab2
----
17
31
59

query I rowsort
SELECT - + col0 + col0 * + col2 AS col1 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT ALL + tab0.col0 * 71 FROM tab0, tab0 cor0
----
9 values hashing to e674318d1c1f37f21287c95f3070a6b9

query I rowsort
SELECT ALL + col0 + + col2 * 86 FROM tab2
----
2314
2329
3347

onlyif mysql # use DIV operator for integer division
query I rowsort label-3122
SELECT - col2 + - col0 DIV col1 FROM tab1 cor0
----
-102
-54
-63

skipif mysql # not compatible
query I rowsort label-3122
SELECT - col2 + - col0 / col1 FROM tab1 cor0
----
-102
-54
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-3123
SELECT - col1 DIV 53 + col1 FROM tab0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-3123
SELECT - col1 / 53 + col1 FROM tab0
----
85
90
96

query I rowsort
SELECT ALL col1 * + col1 + col2 * + col0 * tab2.col1 FROM tab2
----
123133
51323
6820

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3125
SELECT ALL col0 * + CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3125
SELECT ALL col0 * + CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col0 * 59 - col0 AS col2 FROM tab1 AS cor0
----
-180
-3840
-4800

query I rowsort
SELECT ALL col2 + - 94 * col0 FROM tab1 AS cor0
----
-228
-5959
-7424

query I rowsort
SELECT + cor0.col2 + ( + col1 * + col2 ) FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL + + col2 - - 11 AS col2 FROM tab2 AS cor0
----
37
38
49

query I rowsort
SELECT DISTINCT + cor0.col2 AS col2 FROM tab2, tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + col2 + + 91 * col1 AS col1 FROM tab2 AS cor0
----
1585
2848
5395

query I rowsort
SELECT - + col0 + - col2 * + col2 AS col2 FROM tab0 AS cor0
----
-1113
-36
-6813

query I rowsort
SELECT ALL + 51 FROM tab1, tab1 AS cor0
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

skipif mysql # not compatible
query I rowsort
SELECT col1 + - CAST ( col2 AS REAL ) * col1 AS col1 FROM tab1
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-3135
SELECT ALL col2 DIV - col2 AS col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3135
SELECT ALL col2 / - col2 AS col2 FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3136
SELECT DISTINCT col1 + CAST( 86 AS SIGNED ) FROM tab2
----
103
117
145

skipif mysql # not compatible
query I rowsort label-3136
SELECT DISTINCT col1 + CAST ( 86 AS INTEGER ) FROM tab2
----
103
117
145

query I rowsort
SELECT DISTINCT col2 * + col2 * col2 + col0 FROM tab2
----
17654
19690
54951

query I rowsort
SELECT - col1 + + ( - col2 ) AS col0 FROM tab1 AS cor0
----
-109
-67
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3139
SELECT ALL - col1 DIV col0 AS col1 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-3139
SELECT ALL - col1 / col0 AS col1 FROM tab0 AS cor0
----
-1
-2
-3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3140
SELECT + + col0 * CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3140
SELECT + + col0 * CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * - ( col0 ) + col1 FROM tab1 AS cor0
----
-4086
-6387
17

query I rowsort
SELECT ALL + col0 + + col0 AS col0 FROM tab0 AS cor0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-3143
SELECT DISTINCT + col1 DIV 70 AS col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3143
SELECT DISTINCT + col1 / 70 AS col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL + cor0.col0 AS col2 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT - col1 + 68 + col0 AS col0 FROM tab0 AS cor0
----
6
6
66

query I rowsort
SELECT DISTINCT + cor0.col1 * - 62 * - col2 FROM tab2 AS cor0
----
40052
51894
95108

query I rowsort
SELECT - - col2 + - col0 * - 65 AS col1 FROM tab1 AS cor0
----
249
4217
5296

query I rowsort
SELECT DISTINCT ( + cor0.col1 ) + cor0.col2 AS col0 FROM tab1 AS cor0
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3149
SELECT DISTINCT 11 * col2 DIV - col1 FROM tab1 cor0
----
-22
-62
-81

skipif mysql # not compatible
query I rowsort label-3149
SELECT DISTINCT 11 * col2 / - col1 FROM tab1 cor0
----
-22
-62
-81

query I rowsort
SELECT ALL ( 13 ) AS col1 FROM tab2 AS cor0
----
13
13
13

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0, tab1 AS cor1, tab2 cor2
----
972 values hashing to 49c8bf3e931a898ba7af63d0e377eb79

query I rowsort
SELECT ALL - - 71 + 20 * - cor0.col2 FROM tab1 AS cor0
----
-1009
-1069
-1849

query I rowsort
SELECT ALL col0 * + 84 FROM tab2 AS cor0
----
588
6552
6636

query I rowsort
SELECT DISTINCT col0 + - ( - col0 * tab2.col0 + col2 ) FROM tab2
----
29
6136
6282

query I rowsort
SELECT ALL 83 * - col0 FROM tab1 AS cor0
----
-249
-5312
-6640

onlyif mysql # use DIV operator for integer division
query I rowsort label-3156
SELECT DISTINCT + col0 + + col2 DIV col2 FROM tab0 AS cor0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-3156
SELECT DISTINCT + col0 + + col2 / col2 FROM tab0 AS cor0
----
25
36
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3157
SELECT - CAST( NULL AS SIGNED ) AS col2 FROM tab0, tab2 cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-3157
SELECT - CAST ( NULL AS INTEGER ) AS col2 FROM tab0, tab2 cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL ( - col1 ) * ( - col1 ) * col0 + + 54 AS col0 FROM tab2 AS cor0
----
22885
271572
6781

query I rowsort
SELECT - col1 - - cor0.col0 * col2 AS col1 FROM tab1 cor0
----
136
3638
7667

query I rowsort
SELECT + col2 * col2 + + 3 FROM tab2 AS cor0
----
1447
679
732

query I rowsort
SELECT ALL + 68 * col0 AS col2 FROM tab1 AS cor0
----
204
4352
5440

query I rowsort
SELECT + ( + col2 * 23 ) AS col1 FROM tab0
----
1886
23
759

query I rowsort
SELECT ALL + col1 - + col2 FROM tab0
----
53
9
96

query I rowsort
SELECT DISTINCT + 28 - + tab2.col0 AS col2 FROM tab2
----
-50
-51
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col2 + col2 col1 FROM tab0 AS cor0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + 64 col0 FROM tab2 AS cor0
----
1664
1728
2432

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3167
SELECT - - col1 * CAST( - col1 AS SIGNED ) + - col0 * - 69 + 80 FROM tab0 AS cor0
----
-2060
-5660
-6914

skipif mysql # not compatible
query I rowsort label-3167
SELECT - - col1 * CAST ( - col1 AS INTEGER ) + - col0 * - 69 + 80 FROM tab0 AS cor0
----
-2060
-5660
-6914

query I rowsort
SELECT - - cor0.col1 + cor0.col2 AS col0 FROM tab0 AS cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3169
SELECT DISTINCT + col2 DIV col2 AS col2 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-3169
SELECT DISTINCT + col2 / col2 AS col2 FROM tab1 AS cor0
----
1

query I rowsort
SELECT + col1 * 33 * col0 + col0 * ( col1 ) FROM tab1 AS cor0
----
21760
2652
35360

query I rowsort
SELECT ALL + - col2 * col2 + 55 FROM tab0 AS cor0
----
-1034
-6669
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-3172
SELECT + col2 DIV col2 + - col1 + 0 AS col2 FROM tab0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-3172
SELECT + col2 / col2 + - col1 + 0 AS col2 FROM tab0
----
-85
-90
-96

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1, tab0 AS cor0, tab2 cor1
----
972 values hashing to a9068b700464993db9fae6f630605fde

query I rowsort
SELECT col0 + col2 + 10 AS col0 FROM tab2
----
114
127
44

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3175
SELECT - CAST( + 50 AS SIGNED ) AS col2 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to faf91d5263c18db4877a3c30c47e2487

skipif mysql # not compatible
query I rowsort label-3175
SELECT - CAST ( + 50 AS INTEGER ) AS col2 FROM tab1, tab0 AS cor0, tab0 cor1
----
27 values hashing to faf91d5263c18db4877a3c30c47e2487

onlyif mysql # use DIV operator for integer division
query I rowsort label-3176
SELECT - col0 DIV col1 AS col0 FROM tab1
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-3176
SELECT - col0 / col1 AS col0 FROM tab1
----
-6
-6
0

query I rowsort
SELECT - ( - col2 ) * - col0 + + 76 AS col0 FROM tab1
----
-3572
-7604
-86

query I rowsort
SELECT DISTINCT + 71 + - col0 + + tab0.col1 AS col0 FROM tab0
----
133
73

query I rowsort
SELECT ALL + ( 75 * tab1.col0 ) + col0 FROM tab1
----
228
4864
6080

query I rowsort
SELECT col0 * col1 + cor0.col0 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT ALL tab0.col0 AS col0 FROM tab0, tab0 AS cor0, tab2, tab0 AS cor1
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3182
SELECT DISTINCT CAST( NULL AS DECIMAL ) AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-3182
SELECT DISTINCT CAST ( NULL AS REAL ) AS col0 FROM tab1
----
NULL

query I rowsort
SELECT - 16 FROM tab1, tab2 AS cor0
----
9 values hashing to be22ac76b42c6f7212ecc0ba7c89eb34

query I rowsort
SELECT - 14 FROM tab1, tab0 AS cor0
----
9 values hashing to d321461994ba49c3a70fa6373032fc94

query I rowsort
SELECT tab2.col2 + + col2 AS col2 FROM tab2
----
52
54
76

query I rowsort
SELECT - 15 AS col2 FROM tab2
----
-15
-15
-15

query I rowsort
SELECT 77 * + col1 * - col0 + 80 FROM tab1 AS cor0
----
-49200
-5926
-80000

query I rowsort
SELECT 55 AS col1 FROM tab1, tab1 cor0, tab2 AS cor1
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

query I rowsort
SELECT DISTINCT - col1 - + col2 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-2087
-220
-3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-3190
SELECT + col2 DIV col0 + + ( ( - col1 ) + - cor0.col2 ) AS col1 FROM tab1 AS cor0
----
-108
-62
-67

skipif mysql # not compatible
query I rowsort label-3190
SELECT + col2 / col0 + + ( ( - col1 ) + - cor0.col2 ) AS col1 FROM tab1 AS cor0
----
-108
-62
-67

query I rowsort
SELECT cor0.col2 + - cor0.col1 AS col1 FROM tab2 cor0
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-3192
SELECT ALL + - 33 * - col0 + 58 DIV + 5 AS col0 FROM tab0 AS cor0
----
1166
2948
803

skipif mysql # not compatible
query I rowsort label-3192
SELECT ALL + - 33 * - col0 + 58 / + 5 AS col0 FROM tab0 AS cor0
----
1166
2948
803

onlyif mysql # use DIV operator for integer division
query I rowsort label-3193
SELECT DISTINCT - col0 DIV - ( col1 ) col1 FROM tab0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3193
SELECT DISTINCT - col0 / - ( col1 ) col1 FROM tab0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col2 col1 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT DISTINCT + tab0.col2 + - col2 * col2 + + tab0.col0 AS col1 FROM tab0
----
-1032
-6553
35

query I rowsort
SELECT col0 * 86 FROM tab2
----
602
6708
6794

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3197
SELECT CAST( NULL AS DECIMAL ) FROM tab0, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3197
SELECT CAST ( NULL AS REAL ) FROM tab0, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + 43 * tab2.col2 FROM tab2, tab0 cor0
----
9 values hashing to ee721a23e251261c22e7528d8775b679

onlyif mysql # use DIV operator for integer division
query I rowsort label-3199
SELECT ALL - cor0.col1 + + col0 DIV + 6 FROM tab0 AS cor0
----
-77
-82
-92

skipif mysql # not compatible
query I rowsort label-3199
SELECT ALL - cor0.col1 + + col0 / + 6 FROM tab0 AS cor0
----
-77
-82
-92

query I rowsort
SELECT + - col0 * ( + 43 ) FROM tab2 cor0
----
-301
-3354
-3397

query I rowsort
SELECT - col0 * cor0.col0 + col0 - - col2 AS col0 FROM tab2 AS cor0
----
-15
-5980
-6124

query I rowsort
SELECT col2 + + col2 * cor0.col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT - 51 * col2 FROM tab1 AS cor0
----
-2754
-2907
-4896

query I rowsort
SELECT + - col0 * + col0 + + col1 FROM tab2 AS cor0
----
-18
-6025
-6224

onlyif mysql # use DIV operator for integer division
query I rowsort label-3205
SELECT ALL - cor0.col0 * + ( cor0.col2 ) + col2 DIV col0 FROM tab2 AS cor0
----
-186
-2028
-3002

skipif mysql # not compatible
query I rowsort label-3205
SELECT ALL - cor0.col0 * + ( cor0.col2 ) + col2 / col0 FROM tab2 AS cor0
----
-186
-2028
-3002

query I rowsort
SELECT ALL - col1 * - 0 - + col1 FROM tab2 AS cor0
----
-17
-31
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-3207
SELECT DISTINCT - 51 * col0 DIV + col1 AS col0 FROM tab1 AS cor0
----
-313
-326
-5

skipif mysql # not compatible
query I rowsort label-3207
SELECT DISTINCT - 51 * col0 / + col1 AS col0 FROM tab1 AS cor0
----
-313
-326
-5

query I rowsort
SELECT - col2 - col1 * col2 FROM tab2 AS cor0
----
-1560
-684
-864

query I rowsort
SELECT ALL + - ( - cor0.col1 ) * - cor0.col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL - 47 * 55 FROM tab2 AS cor0
----
-2585
-2585
-2585

query I rowsort
SELECT - - col0 * - 8 AS col0 FROM tab1 AS cor0
----
-24
-512
-640

query I rowsort
SELECT DISTINCT - - 73 FROM tab2 AS cor0
----
73

query I rowsort
SELECT - - 67 + col0 AS col1 FROM tab2 cor0
----
145
146
74

query I rowsort
SELECT tab1.col0 + + col1 - - col1 FROM tab1
----
106
55
84

query I rowsort
SELECT col2 * col1 + ( tab0.col2 * col2 ) FROM tab0
----
14186
3927
98

query I rowsort
SELECT ALL + tab2.col2 + + 98 AS col0 FROM tab2
----
124
125
136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab0.col2 * col2 + - col2 col1 FROM tab0
----
-1122
-2
-6806

query I rowsort
SELECT + 64 - + col0 * - col2 AS col2 FROM tab2 cor0
----
2092
253
3066

query I rowsort
SELECT + col0 * - cor0.col0 + col2 AS col2 FROM tab1 AS cor0
----
-4039
-6304
45

query I rowsort
SELECT 90 - col2 FROM tab1 AS cor0
----
-6
33
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 61 * 18 + - col2 * col2 - tab0.col2 col1 FROM tab0
----
-24
-5708
1096

query I rowsort
SELECT - ( + cor0.col0 ) FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + col1 * 58 * col2 FROM tab1 AS cor0
----
33060
72384
81432

query I rowsort
SELECT + 66 + + col2 * - col2 AS col0 FROM tab0 cor0
----
-1023
-6658
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-3225
SELECT - - col1 * + col1 + - col1 DIV col1 - - col2 FROM tab0 AS cor0
----
7428
8362
9409

skipif mysql # not compatible
query I rowsort label-3225
SELECT - - col1 * + col1 + - col1 / col1 - - col2 FROM tab0 AS cor0
----
7428
8362
9409

query I rowsort
SELECT - + col2 * - col2 + cor0.col1 FROM tab1 cor0
----
2942
3259
9229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 69 + + col2 * cor0.col2 col1 FROM tab1 AS cor0
----
2985
3318
9285

query I rowsort
SELECT cor0.col1 + + col1 - + col2 AS col2 FROM tab0 AS cor0
----
100
139
193

query I rowsort
SELECT + + 86 * col1 * col1 AS col1 FROM tab0 AS cor0
----
636056
712166
809174

query I rowsort
SELECT ALL - col1 * col1 * col2 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT - col2 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - col0 * - 83 FROM tab2 cor0
----
581
6474
6557

query I rowsort
SELECT - 10 * - col2 + 79 AS col0 FROM tab2
----
339
349
459

query I rowsort
SELECT - + col0 + cor0.col2 AS col1 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT - col1 * cor0.col2 * col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT DISTINCT 19 FROM tab2, tab1 cor0
----
19

query I rowsort
SELECT - col0 * col2 * - col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT - cor0.col1 + 26 * - 93 FROM tab2 AS cor0
----
-2435
-2449
-2477

query I rowsort
SELECT cor0.col0 * 70 AS col0 FROM tab1 AS cor0
----
210
4480
5600

query I rowsort
SELECT ALL - col2 * + col2 * col0 AS col1 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT + + col1 + 93 AS col1 FROM tab1 cor0
----
103
106
119

query I rowsort
SELECT col0 + cor0.col0 * 45 AS col1 FROM tab1 AS cor0
----
138
2944
3680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - col0 + + col1 col0 FROM tab1 cor0
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-3244
SELECT DISTINCT + - col0 + col2 DIV col0 col1 FROM tab2 cor0
----
-4
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3244
SELECT DISTINCT + - col0 + col2 / col0 col1 FROM tab2 cor0
----
-4
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - ( cor0.col0 ) col1 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT ( + 35 ) AS col2 FROM tab1 AS cor0
----
35
35
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 * - 48 + + col0 col1 FROM tab1 AS cor0
----
147
3136
3920

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col1 ) col1 FROM tab2 AS cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - + col0 col1 FROM tab2
----
-14
-156
-158

query I rowsort
SELECT ALL col0 * - col2 + - col1 AS col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT ( col0 ) * - cor0.col1 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3252
SELECT DISTINCT + - col0 * col0 DIV + col1 FROM tab1 AS cor0
----
-409
-492
0

skipif mysql # not compatible
query I rowsort label-3252
SELECT DISTINCT + - col0 * col0 / + col1 FROM tab1 AS cor0
----
-409
-492
0

query I rowsort
SELECT + cor0.col2 + - 27 * col0 AS col2 FROM tab2 AS cor0
----
-162
-2080
-2095

query I rowsort
SELECT ALL - col2 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3255
SELECT - CAST( - col2 AS SIGNED ) * - col0 FROM tab1 cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-3255
SELECT - CAST ( - col2 AS INTEGER ) * - col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT + 55 + col0 * - col0 AS col2 FROM tab2 AS cor0
----
-6029
-6186
6

query I rowsort
SELECT ALL 78 AS col2 FROM tab1 AS cor0
----
78
78
78

query I rowsort
SELECT ALL col0 + + col1 * col1 + - col1 * col1 FROM tab2
----
7
78
79

query I rowsort
SELECT ALL col2 + col0 + col0 AS col1 FROM tab2
----
182
196
41

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2, tab1 cor0, tab0 AS cor1
----
972 values hashing to 67c5300bc5cba0be4f54a444dc6f05b9

query I rowsort
SELECT DISTINCT - col2 + 85 AS col1 FROM tab1
----
-11
28
31

query I rowsort
SELECT - 44 FROM tab0, tab0 cor0
----
9 values hashing to 07457d9e571e036a9a3a0f5a5a2e1ef2

query I rowsort
SELECT ALL + + 0 * cor0.col0 + 87 FROM tab2 AS cor0
----
87
87
87

query I rowsort
SELECT ALL - cor0.col2 + col0 * - col1 AS col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT ALL 54 * col0 + - col0 AS col0 FROM tab2 cor0
----
371
4134
4187

onlyif mysql # use DIV operator for integer division
query I rowsort label-3266
SELECT col0 + + col1 DIV - col1 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-3266
SELECT col0 + + col1 / - col1 FROM tab1 AS cor0
----
2
63
79

query I rowsort
SELECT DISTINCT 88 * - col1 FROM tab0 AS cor0
----
-7568
-8008
-8536

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 - col2 col0 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT - col0 - - col1 * - ( + cor0.col1 ) AS col1 FROM tab0 AS cor0
----
-7420
-8370
-9444

onlyif mysql # use DIV operator for integer division
query I rowsort label-3270
SELECT ALL - + col2 * + col2 + - ( 37 ) DIV + cor0.col1 AS col2 FROM tab2 cor0
----
-1446
-676
-730

skipif mysql # not compatible
query I rowsort label-3270
SELECT ALL - + col2 * + col2 + - ( 37 ) / + cor0.col1 AS col2 FROM tab2 cor0
----
-1446
-676
-730

query I rowsort
SELECT - col0 * + col1 * + col0 + col1 FROM tab1 AS cor0
----
-208
-40950
-83187

query I rowsort
SELECT DISTINCT - - 44 + col1 * + col1 FROM tab0 AS cor0
----
7440
8325
9453

query I rowsort
SELECT ALL - + cor0.col2 + + col2 * - col1 AS col0 FROM tab2 cor0
----
-1560
-684
-864

onlyif mysql # use DIV operator for integer division
query I rowsort label-3274
SELECT - col1 DIV col1 + col1 FROM tab2 AS cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-3274
SELECT - col1 / col1 + col1 FROM tab2 AS cor0
----
16
30
58

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3275
SELECT cor0.col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3275
SELECT cor0.col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT col2 * col0 - ( 19 + col0 ) * + col1 FROM tab1
----
-410
2818
6393

query I rowsort
SELECT DISTINCT - 33 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
-33

query I rowsort
SELECT + col2 - col0 * + col1 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT - 61 * col1 AS col1 FROM tab1 AS cor0
----
-1586
-610
-793

query I rowsort
SELECT - col2 + cor0.col2 * - col1 FROM tab0 AS cor0
----
-2871
-7544
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 56 col2 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT ALL - col1 - - tab1.col1 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT 9 + + col2 + - col0 AS col1 FROM tab2
----
-32
-43
29

onlyif mysql # use DIV operator for integer division
query I rowsort label-3284
SELECT + col2 * col1 DIV ( col0 ) + col1 FROM tab0
----
174
204
99

skipif mysql # not compatible
query I rowsort label-3284
SELECT + col2 * col1 / ( col0 ) + col1 FROM tab0
----
174
204
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-3285
SELECT - + col1 - + ( col0 ) DIV col2 AS col0 FROM tab0 AS cor0
----
-132
-86
-92

skipif mysql # not compatible
query I rowsort label-3285
SELECT - + col1 - + ( col0 ) / col2 AS col0 FROM tab0 AS cor0
----
-132
-86
-92

query I rowsort
SELECT + col2 + + ( - col1 ) AS col2 FROM tab0 AS cor0
----
-53
-9
-96

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 DISTINCT - tab1.col1 + + tab1.col0 FROM tab1
----
-23
54
67

query I rowsort
SELECT ALL 58 + col0 * col0 FROM tab2
----
107
6142
6299

query I rowsort
SELECT 28 * col1 + - ( - 91 + + col0 ) AS col0 FROM tab2
----
1665
488
952

query I rowsort
SELECT DISTINCT col2 * - col2 + + ( col2 ) FROM tab1
----
-2862
-3192
-9120

query I rowsort
SELECT - - 37 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to c023509f63faa044d654943e6df55ca2

query I rowsort
SELECT 90 AS col2 FROM tab1
----
90
90
90

query I rowsort
SELECT ALL 86 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 2d8c3a0d19ea51447f83cd18b49fee19

onlyif mysql # use DIV operator for integer division
query I rowsort label-3295
SELECT DISTINCT col2 * 9 + - ( tab2.col1 ) DIV col1 FROM tab2
----
233
242
341

skipif mysql # not compatible
query I rowsort label-3295
SELECT DISTINCT col2 * 9 + - ( tab2.col1 ) / col1 FROM tab2
----
233
242
341

query I rowsort
SELECT + col2 * col2 * col2 FROM tab1 AS cor0
----
157464
185193
884736

onlyif mysql # use DIV operator for integer division
query I rowsort label-3297
SELECT ALL - + cor0.col2 DIV 31 FROM tab0 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-3297
SELECT ALL - + cor0.col2 / 31 FROM tab0 AS cor0
----
-1
-2
0

query I rowsort
SELECT DISTINCT - col0 * col2 + - col1 AS col2 FROM tab0 AS cor0
----
-132
-7389
-878

onlyif mysql # use DIV operator for integer division
query I rowsort label-3299
SELECT ALL - cor0.col2 + + cor0.col2 DIV 76 + - col1 FROM tab0 AS cor0
----
-119
-172
-98

skipif mysql # not compatible
query I rowsort label-3299
SELECT ALL - cor0.col2 + + cor0.col2 / 76 + - col1 FROM tab0 AS cor0
----
-119
-172
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-3300
SELECT ALL + + col2 * - col2 + col0 * col1 DIV + col2 FROM tab1 AS cor0
----
-2915
-3238
-9206

skipif mysql # not compatible
query I rowsort label-3300
SELECT ALL + + col2 * - col2 + col0 * col1 / + col2 FROM tab1 AS cor0
----
-2915
-3238
-9206

query I rowsort
SELECT ALL + col0 * - ( + 27 ) - col1 AS col1 FROM tab2 AS cor0
----
-2150
-2165
-220

query I rowsort
SELECT ALL - cor0.col1 * col2 + col0 * - col2 FROM tab1 AS cor0
----
-1566
-4218
-8928

query I rowsort
SELECT - col2 + ( 60 ) + col2 FROM tab0 AS cor0
----
60
60
60

query I rowsort
SELECT DISTINCT + col1 * col1 + + col1 FROM tab2 AS cor0
----
306
3540
992

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3305
SELECT ALL CAST( + col0 AS SIGNED ) * - col2 * col0 AS col2 FROM tab2
----
-1323
-158184
-237158

skipif mysql # not compatible
query I rowsort label-3305
SELECT ALL CAST ( + col0 AS INTEGER ) * - col2 * col0 AS col2 FROM tab2
----
-1323
-158184
-237158

query I rowsort
SELECT tab0.col0 + - col1 * + col0 FROM tab0
----
-2040
-3360
-8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3307
SELECT DISTINCT + + 88 * + ( + col1 ) + CAST( col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
1575
2735
5270

skipif mysql # not compatible
query I rowsort label-3307
SELECT DISTINCT + + 88 * + ( + col1 ) + CAST ( col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
1575
2735
5270

query I rowsort
SELECT + 35 * col0 AS col2 FROM tab1 AS cor0
----
105
2240
2800

query I rowsort
SELECT DISTINCT - + 20 AS col2 FROM tab1 AS cor0
----
-20

onlyif mysql # use DIV operator for integer division
query I rowsort label-3310
SELECT ALL col1 + col1 DIV col2 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3310
SELECT ALL col1 + col1 / col2 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL cor0.col0 - col0 * + col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT + 79 + 41 * - col1 FROM tab1 cor0
----
-331
-454
-987

query I rowsort
SELECT + ( + 28 ) * + col2 FROM tab0 AS cor0
----
2296
28
924

query I rowsort
SELECT ALL - col0 + ( col0 ) FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - cor0.col1 + + 8 FROM tab2 AS cor0
----
-23
-51
-9

query I rowsort
SELECT DISTINCT col0 * cor0.col2 + + col1 * + cor0.col1 AS col0 FROM tab0 AS cor0
----
15579
8188
9444

query I rowsort
SELECT DISTINCT + - col0 + col0 AS col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT - + col1 + + col0 * col1 AS col1 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT - col0 + - col1 + - ( col2 ) * col0 * - col0 AS col2 FROM tab2
----
1285
158047
237062

query I rowsort
SELECT ( - tab1.col0 ) FROM tab1
----
-3
-64
-80

query I rowsort
SELECT + 90 + col2 * ( col0 * col1 ) FROM tab0 AS cor0
----
3485
664208
68202

query I rowsort
SELECT ALL 44 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

query I rowsort
SELECT ALL - ( cor0.col1 ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - col2 * col0 + 80 AS col0 FROM tab1 AS cor0
----
-3568
-7600
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3325
SELECT ALL col0 DIV + col0 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3325
SELECT ALL col0 / + col0 AS col1 FROM tab1
----
1
1
1

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE tab0.col1 + col0 * + col2 - col1 NOT BETWEEN ( NULL ) AND - col2
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query III rowsort
SELECT * FROM tab0 WHERE col0 - col2 >= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3328
SELECT ALL tab2.col0 DIV + col1 AS col2 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-3328
SELECT ALL tab2.col0 / + col1 AS col2 FROM tab2
----
0
1
4

query I rowsort
SELECT - col0 * - tab1.col1 * - col1 AS col1 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT tab2.col0 + + col2 * col0 * col0 + + col2 AS col0 FROM tab2
----
1357
158288
237275

query I rowsort
SELECT ALL tab1.col2 + + col2 + col0 FROM tab1
----
111
178
272

query I rowsort
SELECT col2 + col2 * col0 AS col0 FROM tab0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-3333
SELECT ALL + col1 + col2 DIV col0 AS col2 FROM tab1
----
10
14
44

skipif mysql # not compatible
query I rowsort label-3333
SELECT ALL + col1 + col2 / col0 AS col2 FROM tab1
----
10
14
44

query I rowsort
SELECT DISTINCT col0 FROM tab1 WHERE ( NULL ) NOT IN ( - col1 * col1 )
----

query I rowsort
SELECT - col2 + col1 + + col1 AS col1 FROM tab2
----
-4
35
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-3336
SELECT ALL + col0 + + tab0.col0 DIV + tab0.col0 + col1 FROM tab0
----
111
133
181

skipif mysql # not compatible
query I rowsort label-3336
SELECT ALL + col0 + + tab0.col0 / + tab0.col0 + col1 FROM tab0
----
111
133
181

onlyif mysql # use DIV operator for integer division
query I rowsort label-3337
SELECT col0 + - col1 - + col2 DIV col2 FROM tab1
----
-24
53
66

skipif mysql # not compatible
query I rowsort label-3337
SELECT col0 + - col1 - + col2 / col2 FROM tab1
----
-24
53
66

query I rowsort
SELECT ALL col0 * - tab0.col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT col0 AS col2 FROM tab2 WHERE NOT col0 + col0 <= - col2
----
7
78
79

query III rowsort
SELECT ALL * FROM tab0 WHERE + col1 / col2 + col2 + col2 * - col0 < ( col0 * col1 + - col1 - col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT DISTINCT tab2.col2 * tab2.col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT DISTINCT col1 - - col2 FROM tab0
----
119
173
98

query I rowsort
SELECT + 5 * col2 * + col0 FROM tab1 cor0
----
18240
38400
810

query I rowsort
SELECT - col2 AS col1 FROM tab2 WHERE NOT col0 * col0 IN ( + tab2.col1 + tab2.col1 )
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col0 * - col2 + col1 col1 FROM tab1 WHERE ( + col2 ) > NULL
----

query III rowsort
SELECT * FROM tab1 WHERE NULL = col2
----

query I rowsort
SELECT + col2 * col2 + - col2 * - col1 * + col2 AS col1 FROM tab1
----
129024
35739
78732

onlyif mysql # use DIV operator for integer division
query I rowsort label-3348
SELECT - col2 DIV tab2.col1 + col2 * - col2 AS col1 FROM tab2
----
-1446
-676
-729

skipif mysql # not compatible
query I rowsort label-3348
SELECT - col2 / tab2.col1 + col2 * - col2 AS col1 FROM tab2
----
-1446
-676
-729

query I rowsort
SELECT ALL col0 - - col0 * col1 AS col0 FROM tab2
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3350
SELECT + tab0.col2 DIV col1 + col2 DIV col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3350
SELECT + tab0.col2 / col1 + col2 / col1 FROM tab0
----
0
0
0

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE NULL NOT IN ( - cor0.col1 )
----

query I rowsort
SELECT + tab1.col1 FROM tab0 AS cor0 CROSS JOIN tab1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT + col2 * - tab1.col0 + tab1.col0 FROM tab1 WHERE NOT ( NULL ) IN ( col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col0 col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT DISTINCT + col1 * col2 * tab0.col2 FROM tab0 WHERE NULL = col0
----

query I rowsort
SELECT + col1 - - col2 FROM tab2
----
55
58
85

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL NOT BETWEEN NULL AND - col1
----

query I rowsort
SELECT DISTINCT - col0 + col2 AS col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT + col1 * + col2 FROM tab0 WHERE ( + col0 * - col0 * col2 ) <= + col0
----
2838
7462
97

query I rowsort
SELECT + col2 + + col1 * tab1.col1 FROM tab1
----
157
265
730

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT BETWEEN col2 AND NULL
----

query I rowsort
SELECT - cor0.col2 * cor0.col1 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 315ab91f9844de122b0c28cd16e982e4

query I rowsort
SELECT - + ( + 6 ) FROM tab2 cor0
----
-6
-6
-6

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab1, tab2 cor1, tab2 AS cor2, tab2 AS cor3
----
3645 values hashing to db428ec66bce13149e3129b417b0fe94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3365
SELECT ( ( col0 ) ) + - CAST( - col1 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
137
38
96

skipif mysql # not compatible
query I rowsort label-3365
SELECT ( ( col0 ) ) + - CAST ( - col1 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL ( + 41 ) FROM tab0
----
41
41
41

query I rowsort
SELECT ALL + col2 * + col0 + - col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT ALL 94 * col0 AS col2 FROM tab0 AS cor0
----
2256
3290
8366

query I rowsort
SELECT DISTINCT - col0 * + tab0.col1 AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - tab0.col2 * + col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT ALL + ( - tab0.col1 ) FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT tab0.col1 AS col1 FROM tab0, tab1 cor0
----
86
91
97

query I rowsort
SELECT 82 * col1 AS col2 FROM tab1
----
1066
2132
820

query I rowsort
SELECT - + col0 * col1 + 74 AS col2 FROM tab1 AS cor0
----
-4
-566
-966

query I rowsort
SELECT + - 36 + col1 * - col1 FROM tab2 AS cor0
----
-325
-3517
-997

onlyif mysql # use DIV operator for integer division
query I rowsort label-3376
SELECT col2 + + cor0.col1 DIV ( col1 ) AS col2 FROM tab0 cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-3376
SELECT col2 + + cor0.col1 / ( col1 ) AS col2 FROM tab0 cor0
----
2
34
83

query I rowsort
SELECT - + ( + cor0.col1 ) AS col1 FROM tab2, tab2 cor0
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

onlyif mysql # use DIV operator for integer division
query I rowsort label-3378
SELECT - - col2 + col2 DIV col0 AS col1 FROM tab1 cor0
----
57
72
97

skipif mysql # not compatible
query I rowsort label-3378
SELECT - - col2 + col2 / col0 AS col1 FROM tab1 cor0
----
57
72
97

query I rowsort
SELECT + + col0 + + col0 AS col1 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT - col1 * ( col1 ) FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT + col2 + 70 * - col1 * cor0.col0 FROM tab0 AS cor0
----
-144447
-237649
-566848

query I rowsort
SELECT col0 * - col2 * + 99 FROM tab2 AS cor0
----
-18711
-200772
-297198

query I rowsort
SELECT ALL 68 FROM tab0, tab1, tab2 cor0
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

query I rowsort
SELECT ALL + - col1 * + ( - col0 ) AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + - col1 * + col0 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - - cor0.col2 * 84 * col0 FROM tab2 cor0
----
15876
170352
252168

onlyif mysql # use DIV operator for integer division
query I rowsort label-3387
SELECT col1 + 11 DIV 77 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-3387
SELECT col1 + 11 / 77 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT DISTINCT 86 + col2 * + col2 * + tab0.col0 + col0 AS col1 FROM tab0
----
156
26246
598611

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + col1 * + tab0.col1 col2 FROM tab0
----
7310
8190
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-3390
SELECT DISTINCT tab2.col1 DIV col0 - - col1 FROM tab2
----
17
35
59

skipif mysql # not compatible
query I rowsort label-3390
SELECT DISTINCT tab2.col1 / col0 - - col1 FROM tab2
----
17
35
59

query I rowsort
SELECT col0 * col1 + col1 * - col1 FROM tab1
----
-598
540
871

query I rowsort
SELECT + 51 * + tab2.col0 AS col0 FROM tab2
----
357
3978
4029

onlyif mysql # use DIV operator for integer division
query I rowsort label-3393
SELECT - col2 + col2 DIV col1 FROM tab2
----
-26
-27
-36

skipif mysql # not compatible
query I rowsort label-3393
SELECT - col2 + col2 / col1 FROM tab2
----
-26
-27
-36

query I rowsort
SELECT DISTINCT + 90 * 71 AS col0 FROM tab2 AS cor0
----
6390

query I rowsort
SELECT DISTINCT + col2 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT col1 * - col0 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT - + ( + col2 ) + + col1 * - col0 AS col0 FROM tab2 AS cor0
----
-1381
-244
-4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3398
SELECT - CAST( NULL AS SIGNED ) + + col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3398
SELECT - CAST ( NULL AS INTEGER ) + + col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 86 * col2 * + 28 FROM tab2 cor0
----
62608
65016
91504

query I rowsort
SELECT DISTINCT - col1 * col1 * ( cor0.col0 ) FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT ALL 90 AS col0 FROM tab2 AS cor0
----
90
90
90

query I rowsort
SELECT + col1 + + col1 * - 69 AS col1 FROM tab1 cor0
----
-1768
-680
-884

query I rowsort
SELECT DISTINCT col1 * - col0 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3404
SELECT ALL - col2 DIV col2 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3404
SELECT ALL - col2 / col2 AS col0 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - 79 + + cor0.col2 * col1 AS col2 FROM tab2 AS cor0
----
1455
567
758

query I rowsort
SELECT + col0 * - col1 + col1 * col2 FROM tab0 AS cor0
----
-3298
-637
774

query I rowsort
SELECT DISTINCT - col2 * - col1 * col1 AS col0 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT DISTINCT - - 35 * + col0 + col1 FROM tab1 AS cor0
----
131
2250
2813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 28 col2 FROM tab2 cor0
----
28
28
28

query I rowsort
SELECT ALL + col0 * col1 - col2 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT DISTINCT - 17 * 51 AS col1 FROM tab1, tab2, tab2 cor0
----
-867

query I rowsort
SELECT ALL - - 64 FROM tab2 cor0
----
64
64
64

query I rowsort
SELECT DISTINCT ( - col0 ) - - 36 * - col2 AS col1 FROM tab1 AS cor0
----
-1947
-2116
-3536

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3414
SELECT + + col2 * + col1 * CAST( NULL AS SIGNED ) + 22 * col2 col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3414
SELECT + + col2 * + col1 * CAST ( NULL AS INTEGER ) + 22 * col2 col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 39 col1 FROM tab0 AS cor0
----
-1365
-3471
-936

query I rowsort
SELECT DISTINCT + col2 * 20 FROM tab2 AS cor0
----
520
540
760

onlyif mysql # use DIV operator for integer division
query I rowsort label-3417
SELECT col2 + ( 81 ) DIV col0 FROM tab1 AS cor0
----
58
81
97

skipif mysql # not compatible
query I rowsort label-3417
SELECT col2 + ( 81 ) / col0 FROM tab1 AS cor0
----
58
81
97

query I rowsort
SELECT - col2 + - 17 FROM tab2 AS cor0
----
-43
-44
-55

query I rowsort
SELECT DISTINCT + col0 * 45 FROM tab1 AS cor0
----
135
2880
3600

query I rowsort
SELECT DISTINCT col2 + + col1 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL + + cor0.col1 + + col0 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-3422
SELECT - - 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-3422
SELECT - - col0 / col0 col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL + col2 + - cor0.col2 * + col2 AS col0 FROM tab0 cor0
----
-1056
-6642
0

query I rowsort
SELECT ALL ( + col2 ) * - col1 AS col0 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL cor0.col0 AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT - col2 + - ( + col0 ) - - col0 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + - cor0.col1 * + ( + cor0.col2 ) + col1 * - col1 FROM tab1 AS cor0
----
-1417
-2080
-670

query I rowsort
SELECT DISTINCT + col0 * 13 FROM tab0
----
1157
312
455

query I rowsort
SELECT - tab1.col2 + + ( col1 ) FROM tab1
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-3430
SELECT ALL - + col0 DIV - col1 + col0 AS col1 FROM tab1 AS cor0
----
3
70
86

skipif mysql # not compatible
query I rowsort label-3430
SELECT ALL - + col0 / - col1 + col0 AS col1 FROM tab1 AS cor0
----
3
70
86

query I rowsort
SELECT DISTINCT - col0 * col0 + col1 + + 98 FROM tab2 AS cor0
----
-5927
-6126
80

query I rowsort
SELECT ALL - + col1 + - col2 + - col0 FROM tab0 cor0
----
-133
-143
-262

query I rowsort
SELECT + col1 + - 38 AS col2 FROM tab0 AS cor0
----
48
53
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3434
SELECT ALL - - col2 * - ( + col0 ) + ( + col2 ) + - col2 * CAST( + col1 AS SIGNED ) FROM tab0 AS cor0
----
-131
-14678
-3597

skipif mysql # not compatible
query I rowsort label-3434
SELECT ALL - - col2 * - ( + col0 ) + ( + col2 ) + - col2 * CAST ( + col1 AS INTEGER ) FROM tab0 AS cor0
----
-131
-14678
-3597

query I rowsort
SELECT DISTINCT ( 50 ) FROM tab0 cor0
----
50

query I rowsort
SELECT ALL 84 + + col0 + col2 FROM tab1 AS cor0
----
141
205
260

query I rowsort
SELECT ( 55 ) FROM tab0 AS cor0
----
55
55
55

query I rowsort
SELECT + 92 * 47 FROM tab2 AS cor0
----
4324
4324
4324

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 57 * - cor0.col2 col0 FROM tab0 AS cor0
----
-1881
-4674
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 41 col1 FROM tab0 AS cor0
----
41

query I rowsort
SELECT + + ( - cor0.col1 ) + - cor0.col0 * + ( col2 ) AS col2 FROM tab1 cor0
----
-188
-3658
-7693

query I rowsort
SELECT ALL - col2 + ( col0 * - col1 ) AS col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT cor0.col2 * 99 AS col2 FROM tab2 AS cor0
----
2574
2673
3762

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3444
SELECT ALL CAST( NULL AS DECIMAL ) * 43 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3444
SELECT ALL CAST ( NULL AS REAL ) * 43 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3445
SELECT ALL col0 * CAST( - col0 AS SIGNED ) * - col2 AS col0 FROM tab1
----
233472
486
614400

skipif mysql # not compatible
query I rowsort label-3445
SELECT ALL col0 * CAST ( - col0 AS INTEGER ) * - col2 AS col0 FROM tab1
----
233472
486
614400

query I rowsort
SELECT ALL 2 + + 39 * tab1.col2 FROM tab1
----
2108
2225
3746

query I rowsort
SELECT ALL - 85 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 8ebc8ffafb1517ea04e3a6fc4059d88a

query I rowsort
SELECT + col0 * cor0.col2 - + ( cor0.col0 ) FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT DISTINCT ( - cor0.col1 ) * cor0.col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + - ( col1 ) * + col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-3451
SELECT - 11 DIV col2 AS col2 FROM tab0 AS cor0
----
-11
0
0

skipif mysql # not compatible
query I rowsort label-3451
SELECT - 11 / col2 AS col2 FROM tab0 AS cor0
----
-11
0
0

query I rowsort
SELECT DISTINCT - col2 + - cor0.col1 AS col0 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT + + col1 * + col0 * + col2 FROM tab0 AS cor0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-3454
SELECT ALL - col1 DIV + 29 + + tab1.col0 AS col1 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3454
SELECT ALL - col1 / + 29 + + tab1.col0 AS col1 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL + tab0.col0 * - tab0.col2 + + ( + 20 ) * - tab0.col0 AS col2 FROM tab0
----
-1272
-735
-9078

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col1 col0 FROM tab0 AS cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL - col2 * - ( + col0 ) FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + - col1 * col1 + col0 FROM tab1 AS cor0
----
-36
-673
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 18 + + col0 * col2 col0 FROM tab2
----
2046
207
3020

query I rowsort
SELECT col0 + col2 * + 1 FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3462
SELECT ALL col0 + tab0.col1 DIV + col2 AS col2 FROM tab0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-3462
SELECT ALL col0 + tab0.col1 / + col2 AS col2 FROM tab0
----
132
26
90

query I rowsort
SELECT - col2 + col1 AS col1 FROM tab2
----
-21
33
4

query I rowsort
SELECT DISTINCT + col2 * - 62 - col0 * col0 AS col0 FROM tab2 AS cor0
----
-1723
-7696
-8597

query I rowsort
SELECT col0 * 25 + + col0 * col2 * 29 AS col2 FROM tab0
----
1890
213867
23568

query I rowsort
SELECT tab2.col2 + - col2 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT - col1 + 9 FROM tab0
----
-77
-82
-88

query I rowsort
SELECT + - col1 * col2 + - col0 FROM tab2 cor0
----
-1612
-725
-844

query I rowsort
SELECT DISTINCT - col1 * col1 + col0 * - col1 * + ( col1 ) AS col1 FROM tab0 AS cor0
----
-184900
-338724
-745290

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3470
SELECT DISTINCT + col0 * - CAST( col1 AS SIGNED ) FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-3470
SELECT DISTINCT + col0 * - CAST ( col1 AS INTEGER ) FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + 13 * - col2 AS col1 FROM tab1 AS cor0
----
-1248
-702
-741

onlyif mysql # use DIV operator for integer division
query I rowsort label-3472
SELECT ALL + col0 DIV - col0 col0 FROM tab2 AS cor0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3472
SELECT ALL + col0 / - col0 col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - + col2 + col1 * col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT ALL + col1 + + col2 * + ( 43 ) FROM tab1 AS cor0
----
2348
2461
4141

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3475
SELECT - cor0.col1 + + CAST( NULL AS SIGNED ) / ( col0 ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3475
SELECT - cor0.col1 + + CAST ( NULL AS INTEGER ) / ( col0 ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 48 FROM tab0, tab1 cor0, tab0 AS cor1
----
-48

query I rowsort
SELECT - col1 + col1 * - 68 AS col2 FROM tab1 cor0
----
-1794
-690
-897

onlyif mysql # use DIV operator for integer division
query I rowsort label-3478
SELECT ALL col1 DIV - col0 AS col2 FROM tab2
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-3478
SELECT ALL col1 / - col0 AS col2 FROM tab2
----
-4
0
0

query I rowsort
SELECT - 24 + - cor0.col1 FROM tab1 cor0
----
-34
-37
-50

query I rowsort
SELECT cor0.col0 AS col1 FROM tab1, tab2 cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

onlyif mysql # use DIV operator for integer division
query I rowsort label-3481
SELECT + + col0 DIV col0 col0 FROM tab1 cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3481
SELECT + + col0 / col0 col0 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT ALL + 94 + - col0 * col0 AS col0 FROM tab0 AS cor0
----
-1131
-482
-7827

onlyif mysql # use DIV operator for integer division
query I rowsort label-3483
SELECT DISTINCT - + col1 + ( col1 ) DIV - col0 col2 FROM tab0 cor0
----
-89
-92
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3483
SELECT DISTINCT - + col1 + ( col1 ) / - col0 col2 FROM tab0 cor0
----
-89
-92
-99

query I rowsort
SELECT col1 + col2 + cor0.col0 * - col1 * 39 FROM tab2 AS cor0
----
-179393
-52322
-8405

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 + - 16 col0 FROM tab1 AS cor0
----
-26
-29
-42

query I rowsort
SELECT DISTINCT ( + 20 ) + col1 AS col0 FROM tab0 AS cor0
----
106
111
117

query I rowsort
SELECT + 68 + - 32 + cor0.col0 AS col1 FROM tab1 cor0
----
100
116
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 78 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 2aff42d3e015022a738905090a20dfd4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3489
SELECT ALL + 53 DIV 10 FROM tab0
----
5
5
5

skipif mysql # not compatible
query I rowsort label-3489
SELECT ALL + 53 / 10 FROM tab0
----
5
5
5

query I rowsort
SELECT ALL + 52 AS col0 FROM tab1
----
52
52
52

query I rowsort
SELECT ALL col2 * 33 AS col0 FROM tab1
----
1782
1881
3168

query I rowsort
SELECT - 62 AS col2 FROM tab0
----
-62
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3493
SELECT 36 DIV - cor0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 7a46b7b0a5578e903d3acf08c027edab

skipif mysql # not compatible
query I rowsort label-3493
SELECT 36 / - cor0.col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 7a46b7b0a5578e903d3acf08c027edab

query I rowsort
SELECT + 42 * col1 FROM tab0 AS cor0
----
3612
3822
4074

query I rowsort
SELECT DISTINCT ( + col0 ) AS col0 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL col2 + col2 * 10 AS col1 FROM tab0 AS cor0
----
11
363
902

query I rowsort
SELECT - 91 * cor0.col1 FROM tab1 cor0
----
-1183
-2366
-910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 97 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to e4a6bd848a69226cbb7ad3d154be321b

query I rowsort
SELECT 98 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c758e8afbdfa6aae279045b0e9cbacc2

query I rowsort
SELECT DISTINCT col1 * - col2 * col2 AS col1 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT + - 97 + - col0 FROM tab0 AS cor0
----
-121
-132
-186

onlyif mysql # use DIV operator for integer division
query I rowsort label-3502
SELECT cor0.col0 DIV + cor0.col1 + + cor0.col0 FROM tab0, tab1 cor0
----
9 values hashing to 9182ce84a5a91f41e144f88a0367eb41

skipif mysql # not compatible
query I rowsort label-3502
SELECT cor0.col0 / + cor0.col1 + + cor0.col0 FROM tab0, tab1 cor0
----
9 values hashing to 9182ce84a5a91f41e144f88a0367eb41

query I rowsort
SELECT + 19 AS col1 FROM tab2, tab1, tab1 cor0
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

query I rowsort
SELECT ALL tab2.col1 * col2 AS col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT tab0.col1 * + col0 * - ( + col0 ) AS col1 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT - col2 * col1 * col0 AS col2 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT - col1 + 93 AS col1 FROM tab2 AS cor0
----
34
62
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 3 + 1 col2 FROM tab2 AS cor0
----
4
4
4

query I rowsort
SELECT col1 * - cor0.col0 * col1 + col1 * - col2 * col0 AS col0 FROM tab1 cor0
----
-113360
-42880
-6240

query I rowsort
SELECT - - 2 AS col2 FROM tab2 AS cor0
----
2
2
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-3511
SELECT - col0 DIV col0 + col0 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-3511
SELECT - col0 / col0 + col0 FROM tab1 AS cor0
----
2
63
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + col0 col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - 46 AS col2 FROM tab2 cor0
----
-46
-46
-46

query I rowsort
SELECT ALL - col0 + cor0.col0 + - col2 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT + col1 + - col0 FROM tab1 cor0
----
-54
-67
23

query I rowsort
SELECT col0 * + col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + ( col1 ) FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT ALL col0 + - ( 73 ) FROM tab0 AS cor0
----
-38
-49
16

query I rowsort
SELECT ALL - + col1 + + col2 AS col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col0 + + ( col0 ) * - cor0.col1 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT DISTINCT col2 + col0 AS col2 FROM tab2 AS cor0
----
104
117
34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3522
SELECT + ( col2 ) + - CAST( - 72 AS SIGNED ) FROM tab1
----
126
129
168

skipif mysql # not compatible
query I rowsort label-3522
SELECT + ( col2 ) + - CAST ( - 72 AS INTEGER ) FROM tab1
----
126
129
168

query I rowsort
SELECT + col1 * - col1 + col1 FROM tab0
----
-7310
-8190
-9312

query I rowsort
SELECT 46 AS col0 FROM tab2
----
46
46
46

query I rowsort
SELECT ALL + + 41 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT + tab1.col0 * + tab1.col1 + col0 FROM tab1
----
1120
704
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-3527
SELECT col1 DIV - col1 + - tab2.col2 + + col2 AS col0 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3527
SELECT col1 / - col1 + - tab2.col2 + + col2 AS col0 FROM tab2
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - 79 * - col1 col0 FROM tab0
----
6818
7278
7698

query I rowsort
SELECT ALL 13 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 184e52d7aa5aa66591291e39c67a3dfb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col2 col2 FROM tab2
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3531
SELECT DISTINCT - col0 * CAST( NULL AS SIGNED ) + tab1.col1 + - col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-3531
SELECT DISTINCT - col0 * CAST ( NULL AS INTEGER ) + tab1.col1 + - col1 FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT + 31 * tab1.col0 + - cor0.col2 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 9961f3a774c3d63c105e036136391eea

query I rowsort
SELECT ALL + col0 * 21 FROM tab1 AS cor0
----
1344
1680
63

query I rowsort
SELECT ALL col2 * col0 + col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT ALL + col2 + - ( ( col2 ) ) AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - cor0.col1 + 37 * + col2 AS col2 FROM tab1 AS cor0
----
1972
2099
3539

query I rowsort
SELECT - col2 + + ( - col1 * + col0 ) FROM tab2 AS cor0
----
-1381
-244
-4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3538
SELECT tab1.col1 * CAST( 93 AS SIGNED ) AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to f4eeb2d2bf692021f3b80eb37cb53359

skipif mysql # not compatible
query I rowsort label-3538
SELECT tab1.col1 * CAST ( 93 AS INTEGER ) AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to f4eeb2d2bf692021f3b80eb37cb53359

query I rowsort
SELECT ALL col2 * col1 + + tab2.col0 FROM tab2
----
1612
725
844

query I rowsort
SELECT DISTINCT 92 AS col1 FROM tab2
----
92

query I rowsort
SELECT ( col2 * col2 ) AS col1 FROM tab0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - col1 + 69 FROM tab2
----
10
38
52

query I rowsort
SELECT col1 * col2 * - col2 + - col1 FROM tab1
----
-119821
-32500
-75842

onlyif mysql # use DIV operator for integer division
query I rowsort label-3544
SELECT - - col2 + + col2 * - col0 DIV - col0 AS col0 FROM tab0 AS cor0
----
164
2
66

skipif mysql # not compatible
query I rowsort label-3544
SELECT - - col2 + + col2 * - col0 / - col0 AS col0 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT cor0.col1 + - cor0.col2 AS col1 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT DISTINCT + cor1.col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
1
33
82

query I rowsort
SELECT DISTINCT cor0.col2 - + col2 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - 20 * + ( col1 ) FROM tab2
----
-1180
-340
-620

query I rowsort
SELECT ALL + - col2 + + col2 - + col1 AS col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL - col2 * col1 + 61 AS col0 FROM tab1 cor0
----
-1187
-1343
-509

query I rowsort
SELECT + 62 * - col1 AS col2 FROM tab0 cor0
----
-5332
-5642
-6014

query I rowsort
SELECT - cor0.col2 + col2 * cor0.col2 AS col0 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT - + 48 * cor0.col1 FROM tab2 cor0
----
-1488
-2832
-816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3554
SELECT DISTINCT + + cor0.col2 * - col0 + - CAST( col1 * col0 AS SIGNED ) FROM tab0 AS cor0
----
-15397
-2856
-3430

skipif mysql # not compatible
query I rowsort label-3554
SELECT DISTINCT + + cor0.col2 * - col0 + - CAST ( col1 * col0 AS INTEGER ) FROM tab0 AS cor0
----
-15397
-2856
-3430

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 50 + + col2 col2 FROM tab0 AS cor0
----
132
51
83

query I rowsort
SELECT DISTINCT - 38 * + col0 * + col0 + col1 * col2 AS col1 FROM tab1 AS cor0
----
-155078
-241952
1062

onlyif mysql # use DIV operator for integer division
query I rowsort label-3557
SELECT DISTINCT + cor0.col1 * col2 DIV 49 AS col2 FROM tab1 AS cor0
----
11
25
28

skipif mysql # not compatible
query I rowsort label-3557
SELECT DISTINCT + cor0.col1 * col2 / 49 AS col2 FROM tab1 AS cor0
----
11
25
28

query I rowsort
SELECT 82 * + col0 AS col2 FROM tab0 AS cor0
----
1968
2870
7298

onlyif mysql # use DIV operator for integer division
query I rowsort label-3559
SELECT ALL + - col1 DIV - col2 + 15 AS col2 FROM tab1 cor0
----
15
15
15

skipif mysql # not compatible
query I rowsort label-3559
SELECT ALL + - col1 / - col2 + 15 AS col2 FROM tab1 cor0
----
15
15
15

query I rowsort
SELECT DISTINCT + - cor0.col2 + + col1 AS col0 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT + col2 * tab0.col2 AS col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT 66 + + col2 + + 94 FROM tab1 AS cor0
----
214
217
256

query I rowsort
SELECT - - 65 FROM tab2 AS cor0
----
65
65
65

query I rowsort
SELECT + 46 + + col2 + col2 AS col2 FROM tab2 AS cor0
----
100
122
98

query I rowsort
SELECT + - col1 + + col0 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT - - col1 * col2 * col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT ( col0 ) * - 86 AS col1 FROM tab2 AS cor0
----
-602
-6708
-6794

query I rowsort
SELECT DISTINCT - 55 AS col0 FROM tab2 AS cor0
----
-55

query I rowsort
SELECT - cor0.col1 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT col2 * - 26 AS col0 FROM tab0 cor0
----
-2132
-26
-858

query I rowsort
SELECT DISTINCT col2 + - 66 * + col1 FROM tab0 AS cor0
----
-5643
-5924
-6401

onlyif mysql # use DIV operator for integer division
query I rowsort label-3572
SELECT ALL - col0 DIV col1 + col0 AS col2 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3572
SELECT ALL - col0 / col1 + col0 AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + - col0 * - col1 + col0 * + col0 FROM tab2 cor0
----
10686
266
7584

query I rowsort
SELECT DISTINCT - cor0.col1 * 12 - cor0.col0 FROM tab1 AS cor0
----
-184
-236
-315

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3575
SELECT DISTINCT - col0 + CAST( NULL AS SIGNED ) * - 89 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3575
SELECT DISTINCT - col0 + CAST ( NULL AS INTEGER ) * - 89 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col1 + + tab2.col1 col1 FROM tab2
----
1593
663
868

skipif mysql # not compatible
query I rowsort
SELECT - col2 * CAST ( + 4 AS REAL ) AS col0 FROM tab1 AS cor0
----
-216
-228
-384

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * - col0 * - 86 col1 FROM tab0 AS cor0
----
105350
49536
681206

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * + tab2.col0 col1 FROM tab2
----
-189
-2028
-3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3580
SELECT ALL CAST( col0 AS SIGNED ) * + col0 + - col2 * col0 * + col1 FROM tab2 AS cor0
----
-113568
-44793
-5810

skipif mysql # not compatible
query I rowsort label-3580
SELECT ALL CAST ( col0 AS INTEGER ) * + col0 + - col2 * col0 * + col1 FROM tab2 AS cor0
----
-113568
-44793
-5810

query I rowsort
SELECT DISTINCT ( + col0 ) * col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + + 50 AS col2 FROM tab2 AS cor0
----
50
50
50

query I rowsort
SELECT DISTINCT + col1 * + 87 AS col2 FROM tab1 AS cor0
----
1131
2262
870

onlyif mysql # use DIV operator for integer division
query I rowsort label-3584
SELECT ALL + CAST( - col2 AS SIGNED ) * + col0 + col0 DIV col2 AS col2 FROM tab1 AS cor0
----
-162
-3647
-7680

skipif mysql # not compatible
query I rowsort label-3584
SELECT ALL + CAST ( - col2 AS INTEGER ) * + col0 + col0 / col2 AS col2 FROM tab1 AS cor0
----
-162
-3647
-7680

query I rowsort
SELECT + - col1 + - col2 * col0 + - col1 FROM tab2 AS cor0
----
-2146
-251
-3036

query I rowsort
SELECT ALL - ( - cor0.col2 ) FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 76 + col0 col1 FROM tab1 AS cor0
----
140
156
79

query I rowsort
SELECT 16 * - col0 * col0 AS col2 FROM tab1 AS cor0
----
-102400
-144
-65536

query I rowsort
SELECT - ( col2 ) + + col0 * - col2 AS col1 FROM tab0 cor0
----
-36
-7380
-825

query I rowsort
SELECT - cor0.col1 + col0 + + col0 FROM tab2 AS cor0
----
-17
141
97

query I rowsort
SELECT ALL - 68 * + cor0.col2 FROM tab0 AS cor0
----
-2244
-5576
-68

query I rowsort
SELECT DISTINCT + 69 * 50 AS col2 FROM tab1 AS cor0
----
3450

query I rowsort
SELECT + col2 + - col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 - 90 FROM tab2
----
-11
-12
-83

query I rowsort
SELECT - col0 + - 22 FROM tab0
----
-111
-46
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3596
SELECT + - col0 + + 29 DIV col0 FROM tab1 AS cor0
----
-64
-80
6

skipif mysql # not compatible
query I rowsort label-3596
SELECT + - col0 + + 29 / col0 FROM tab1 AS cor0
----
-64
-80
6

query I rowsort
SELECT 16 + col2 AS col1 FROM tab1 AS cor0
----
112
70
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3598
SELECT ( + col2 ) * col2 - CAST( col0 AS SIGNED ) * + col2 AS col0 FROM tab2 AS cor0
----
-1352
-1558
540

skipif mysql # not compatible
query I rowsort label-3598
SELECT ( + col2 ) * col2 - CAST ( col0 AS INTEGER ) * + col2 AS col0 FROM tab2 AS cor0
----
-1352
-1558
540

query I rowsort
SELECT DISTINCT - col2 + - col2 * col1 AS col0 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT ALL + 20 FROM tab1 cor0
----
20
20
20

query I rowsort
SELECT ALL + 54 AS col2 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to 81150d59d6c3fc48b4ef5a4a5495bc7a

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0, tab2 cor1, tab1 AS cor2
----
972 values hashing to 9364ef7545b07c67767dceb70f02c643

query I rowsort
SELECT 81 * + ( col2 ) * col1 + - col2 FROM tab1
----
100992
113670
46113

query I rowsort
SELECT DISTINCT - ( col1 ) + - col2 AS col1 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT ( 67 ) FROM tab2
----
67
67
67

query I rowsort
SELECT DISTINCT 65 * col1 AS col2 FROM tab0
----
5590
5915
6305

query I rowsort
SELECT - col0 * col0 + + col1 * - col1 AS col2 FROM tab2
----
-1010
-6530
-9565

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3608
SELECT - + CAST( col0 AS SIGNED ) + cor0.col2 FROM tab1 AS cor0
----
-7
16
51

skipif mysql # not compatible
query I rowsort label-3608
SELECT - + CAST ( col0 AS INTEGER ) + cor0.col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT + col0 + - cor0.col0 * col0 AS col1 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT tab1.col2 * - ( + col1 ) FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT + 13 FROM tab1 AS cor0
----
13
13
13

onlyif mysql # use DIV operator for integer division
query I rowsort label-3612
SELECT - 0 DIV + col2 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3612
SELECT - 0 / + col2 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + + 3 FROM tab2 AS cor0
----
3
3
3

query I rowsort
SELECT ALL 37 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c023509f63faa044d654943e6df55ca2

query I rowsort
SELECT cor0.col1 + + col0 * + ( - col2 ) - - cor0.col1 * 2 FROM tab2 AS cor0
----
-1851
-2951
-96

query I rowsort
SELECT 23 * col0 + cor0.col1 AS col2 FROM tab2 AS cor0
----
1834
1853
192

query I rowsort
SELECT col0 + col2 AS col1 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT + - col1 + col2 * col2 FROM tab2 AS cor0
----
1427
617
698

onlyif mysql # use DIV operator for integer division
query I rowsort label-3619
SELECT ALL col0 DIV + col0 AS col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3619
SELECT ALL col0 / + col0 AS col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT ( 97 ) AS col2 FROM tab1, tab0 AS cor0
----
97

query I rowsort
SELECT - - col0 + 80 * col0 AS col2 FROM tab1 AS cor0
----
243
5184
6480

query I rowsort
SELECT - col1 + + ( + 42 ) AS col0 FROM tab0 AS cor0
----
-44
-49
-55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * col2 + - col2 col0 FROM tab0 AS cor0
----
0
1056
6642

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3624
SELECT - col2 + CAST( 42 AS SIGNED ) * cor0.col0 FROM tab0 AS cor0
----
1469
3656
975

skipif mysql # not compatible
query I rowsort label-3624
SELECT - col2 + CAST ( 42 AS INTEGER ) * cor0.col0 FROM tab0 AS cor0
----
1469
3656
975

onlyif mysql # use DIV operator for integer division
query I rowsort label-3625
SELECT ALL col0 DIV col0 + - col0 FROM tab0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-3625
SELECT ALL col0 / col0 + - col0 FROM tab0
----
-23
-34
-88

query I rowsort
SELECT + 32 * 17 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to fed70c4a488a38621e743f7851c5cfb9

query I rowsort
SELECT + - col0 - - ( - col0 ) * col0 AS col2 FROM tab1 cor0
----
-12
-4160
-6480

query I rowsort
SELECT + col1 * + 79 FROM tab2 cor0
----
1343
2449
4661

query I rowsort
SELECT ALL - col0 + col0 * + col1 AS col2 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT ALL - - col1 + - cor0.col1 AS col2 FROM tab0 cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3631
SELECT + - col2 + CAST( col2 AS SIGNED ) FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3631
SELECT + - col2 + CAST ( col2 AS INTEGER ) FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT ALL + col0 * - ( 61 ) AS col2 FROM tab1 AS cor0
----
-183
-3904
-4880

onlyif mysql # use DIV operator for integer division
query I rowsort label-3633
SELECT ALL + col2 DIV - 35 AS col0 FROM tab0 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-3633
SELECT ALL + col2 / - 35 AS col0 FROM tab0 AS cor0
----
-2
0
0

query I rowsort
SELECT + col2 - + 15 * 60 * + col2 AS col1 FROM tab2 AS cor0
----
-23374
-24273
-34162

query I rowsort
SELECT DISTINCT col2 * 41 FROM tab1 AS cor0
----
2214
2337
3936

query I rowsort
SELECT ALL - col1 + - 99 * 60 AS col1 FROM tab2 cor0
----
-5957
-5971
-5999

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3637
SELECT - col0 * col2 * - 40 + + col0 * - CAST( - col2 AS SIGNED ) FROM tab0 cor0
----
1435
299218
32472

skipif mysql # not compatible
query I rowsort label-3637
SELECT - col0 * col2 * - 40 + + col0 * - CAST ( - col2 AS INTEGER ) FROM tab0 cor0
----
1435
299218
32472

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3638
SELECT - - col0 + CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3638
SELECT - - col0 + CAST ( NULL AS INTEGER ) * col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col2 * + col1 + col0 FROM tab2 cor0
----
-1456
-567
-830

query I rowsort
SELECT ALL - cor0.col1 + 38 + col2 AS col2 FROM tab2 AS cor0
----
34
5
59

query I rowsort
SELECT - cor0.col0 + cor0.col0 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT + 43 AS col2 FROM tab2 cor0
----
43

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3643
SELECT - CAST( 69 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-69
-69
-69

skipif mysql # not compatible
query I rowsort label-3643
SELECT - CAST ( 69 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-69
-69
-69

onlyif mysql # use DIV operator for integer division
query I rowsort label-3644
SELECT DISTINCT + 11 * col0 + col2 DIV col0 FROM tab1 AS cor0
----
51
704
881

skipif mysql # not compatible
query I rowsort label-3644
SELECT DISTINCT + 11 * col0 + col2 / col0 FROM tab1 AS cor0
----
51
704
881

query I rowsort
SELECT - + col2 + + col2 AS col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL - - col0 - - 88 FROM tab0 AS cor0
----
112
123
177

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3647
SELECT ALL CAST( NULL AS DECIMAL ) + - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3647
SELECT ALL CAST ( NULL AS REAL ) + - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col0 - col2 AS col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT - col0 * cor0.col1 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + - 82 + cor0.col1 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 2b4d2a1a9f2ff64e6a9c687087a291d2

onlyif mysql # use DIV operator for integer division
query I rowsort label-3651
SELECT DISTINCT col1 * col1 + col2 DIV col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

skipif mysql # not compatible
query I rowsort label-3651
SELECT DISTINCT col1 * col1 + col2 / col1 AS col2 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT - + 5 FROM tab1 AS cor0
----
-5
-5
-5

query I rowsort
SELECT + + col0 * + col1 * col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT 38 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to a7827a79248ee7bf2cee915a631d02cb

query I rowsort
SELECT ALL 95 + + col0 * col2 AS col0 FROM tab1 cor0
----
257
3743
7775

onlyif mysql # use DIV operator for integer division
query I rowsort label-3656
SELECT ALL col2 DIV - col1 col2 FROM tab2
----
-2
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3656
SELECT ALL col2 / - col1 col2 FROM tab2
----
-2
0
0

query I rowsort
SELECT DISTINCT 24 AS col0 FROM tab1, tab0, tab1 AS cor0
----
24

query I rowsort
SELECT + 59 * + col0 FROM tab2
----
413
4602
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-3659
SELECT ALL 23 - + col0 DIV - col1 AS col1 FROM tab1
----
23
29
29

skipif mysql # not compatible
query I rowsort label-3659
SELECT ALL 23 - + col0 / - col1 AS col1 FROM tab1
----
23
29
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 68 - col0 col2 FROM tab2
----
-146
-147
-75

query I rowsort
SELECT ALL + + cor0.col0 * col2 * cor0.col1 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-3662
SELECT ALL 49 DIV - col2 col1 FROM tab0 AS cor0
----
-1
-49
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3662
SELECT ALL 49 / - col2 col1 FROM tab0 AS cor0
----
-1
-49
0

query I rowsort
SELECT DISTINCT col2 * + cor0.col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT - - col2 + - col2 * - col0 AS col2 FROM tab2 AS cor0
----
2054
216
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-3665
SELECT DISTINCT + + 88 DIV + col0 AS col2 FROM tab1 AS cor0
----
1
29

skipif mysql # not compatible
query I rowsort label-3665
SELECT DISTINCT + + 88 / + col0 AS col2 FROM tab1 AS cor0
----
1
29

query I rowsort
SELECT - col1 + - col2 * col1 FROM tab1 cor0
----
-1261
-1430
-580

query I rowsort
SELECT - col2 * 33 AS col0 FROM tab2 AS cor0
----
-1254
-858
-891

query I rowsort
SELECT ALL cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3669
SELECT ALL + col2 + + col2 DIV - col0 + col1 AS col0 FROM tab1
----
108
62
67

skipif mysql # not compatible
query I rowsort label-3669
SELECT ALL + col2 + + col2 / - col0 + col1 AS col0 FROM tab1
----
108
62
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3670
SELECT + CAST( + col2 AS SIGNED ) col2 FROM tab2 AS cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3670
SELECT + CAST ( + col2 AS INTEGER ) col2 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-3671
SELECT DISTINCT + ( cor0.col2 ) + col1 DIV col2 col1 FROM tab1 cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3671
SELECT DISTINCT + ( cor0.col2 ) + col1 / col2 col1 FROM tab1 cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3672
SELECT DISTINCT - col0 + 11 DIV col2 AS col0 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3672
SELECT DISTINCT - col0 + 11 / col2 AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL 30 * + 71 FROM tab1
----
2130
2130
2130

query I rowsort
SELECT + - ( col1 ) * cor0.col2 AS col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT - col1 + 29 AS col2 FROM tab0
----
-57
-62
-68

onlyif mysql # use DIV operator for integer division
query I rowsort label-3676
SELECT DISTINCT ( col1 ) DIV + col0 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-3676
SELECT DISTINCT ( col1 ) / + col0 FROM tab0
----
1
2
3

query I rowsort
SELECT + - ( - col1 ) * - col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - ( col1 ) * + cor0.col2 AS col2 FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT 52 AS col2 FROM tab0, tab1 AS cor0
----
52

query I rowsort
SELECT + 55 FROM tab1, tab0 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT 12 AS col1 FROM tab0
----
12
12
12

query I rowsort
SELECT DISTINCT - col1 + 85 AS col2 FROM tab0 AS cor0
----
-1
-12
-6

query I rowsort
SELECT ALL - col2 * col1 + + 82 AS col0 FROM tab1 AS cor0
----
-1166
-1322
-488

query I rowsort
SELECT - col0 - - col1 FROM tab1
----
-54
-67
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col2 * ( - 97 ) col0 FROM tab0
----
194
3287
8045

query I rowsort
SELECT - 88 * + col0 AS col1 FROM tab0
----
-2112
-3080
-7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-3687
SELECT col1 + - col2 DIV - col0 + col2 AS col2 FROM tab0
----
120
173
98

skipif mysql # not compatible
query I rowsort label-3687
SELECT col1 + - col2 / - col0 + col2 AS col2 FROM tab0
----
120
173
98

query I rowsort
SELECT ALL col0 - tab0.col1 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT col0 * - col0 + ( - col2 ) * - col0 AS col2 FROM tab1
----
-448
1280
153

query I rowsort
SELECT col0 + + col0 * ( col1 ) - + col1 AS col1 FROM tab1
----
1107
55
694

query I rowsort
SELECT - col1 * - 63 FROM tab0
----
5418
5733
6111

query I rowsort
SELECT ALL + - col0 + col0 * + col2 AS col2 FROM tab1 AS cor0
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-3693
SELECT - - col1 * col2 DIV col1 + col0 AS col2 FROM tab0 AS cor0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-3693
SELECT - - col1 * col2 / col1 + col0 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL - col0 + 92 * 18 FROM tab0 AS cor0
----
1567
1621
1632

query I rowsort
SELECT ALL + col1 * - col2 * + col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL + col0 + ( - col0 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col0 * col2 + 19 * col1 FROM tab1 AS cor0
----
3838
656
7927

query I rowsort
SELECT ALL + + col2 * + col2 - + col2 AS col0 FROM tab1 cor0
----
2862
3192
9120

query I rowsort
SELECT ALL + tab0.col1 + - tab0.col1 * + tab0.col2 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT ALL + col1 * col2 + - col0 AS col2 FROM tab0
----
2814
62
7373

query I rowsort
SELECT ALL - col0 * - tab2.col1 AS col1 FROM tab2
----
1343
217
4602

query I rowsort
SELECT tab2.col2 + col2 AS col0 FROM tab2
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col1 col2 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL - col0 * col2 + + col2 AS col2 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT - col1 + - cor0.col1 AS col1 FROM tab2 AS cor0
----
-118
-34
-62

query I rowsort
SELECT DISTINCT - col2 * + col0 + - col2 AS col2 FROM tab0 AS cor0
----
-36
-7380
-825

query I rowsort
SELECT DISTINCT - col1 + col0 * + col1 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT ALL - col2 * tab0.col1 AS col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT ALL col0 + - col1 * + col2 * - col1 AS col2 FROM tab0 AS cor0
----
244092
679131
9444

query I rowsort
SELECT ALL - col2 * + col0 + col1 AS col2 FROM tab0 AS cor0
----
-706
-7207
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col1 col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + col0 + + cor0.col2 AS col1 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - col2 * col0 - col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT cor0.col1 * + col1 + - col1 FROM tab2 AS cor0
----
272
3422
930

query I rowsort
SELECT DISTINCT + col0 * col2 + + cor0.col1 AS col1 FROM tab0 AS cor0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-3716
SELECT col1 + cor0.col2 DIV - cor0.col0 FROM tab1 AS cor0
----
10
12
8

skipif mysql # not compatible
query I rowsort label-3716
SELECT col1 + cor0.col2 / - cor0.col0 FROM tab1 AS cor0
----
10
12
8

query I rowsort
SELECT ALL + col1 * col2 + cor0.col1 FROM tab2 cor0
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + tab1.col2 * - col1 col0 FROM tab1
----
-1328
-1407
-634

query I rowsort
SELECT - - 78 + - col0 * col2 + - col0 AS col2 FROM tab2 AS cor0
----
-118
-2028
-3003

query I rowsort
SELECT ALL + ( col0 ) * col1 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + - col1 + - col2 - - col0 FROM tab2 AS cor0
----
-51
-7
24

query I rowsort
SELECT DISTINCT + + col0 * col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT - - col0 * col0 AS col2 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL - + 48 AS col1 FROM tab1 AS cor0
----
-48
-48
-48

query I rowsort
SELECT ALL + - ( col0 ) + col1 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL - + col1 * col0 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT - 67 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
1139
2077
3953

query I rowsort
SELECT 55 * col1 FROM tab2 AS cor0
----
1705
3245
935

query I rowsort
SELECT + + col0 + - col2 + col2 AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - col1 * col2 * + col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT ALL + 9 + - cor0.col0 AS col0 FROM tab2 AS cor0
----
-69
-70
2

query I rowsort
SELECT + - 62 * col1 AS col1 FROM tab2 AS cor0
----
-1054
-1922
-3658

query I rowsort
SELECT + - col0 * col1 * - cor0.col2 + - col2 FROM tab2 AS cor0
----
119626
50996
5832

query I rowsort
SELECT cor0.col2 + + col1 * - col1 - + col0 FROM tab0 AS cor0
----
-7387
-8288
-9443

query I rowsort
SELECT ALL + - col0 * + col1 - - col2 AS col1 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL - col1 * col1 + cor0.col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT ALL col2 - - col0 FROM tab2 cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col2 + - col1 col2 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-3739
SELECT ALL + tab1.col2 - col1 DIV + col1 AS col1 FROM tab1
----
53
56
95

skipif mysql # not compatible
query I rowsort label-3739
SELECT ALL + tab1.col2 - col1 / + col1 AS col1 FROM tab1
----
53
56
95

query I rowsort
SELECT col1 * col1 + + 34 FROM tab1 AS cor0
----
134
203
710

query I rowsort
SELECT + col0 * col1 + + col1 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT - 0 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 + + col1 * ( + 15 ) * col0 + col0 AS col1 FROM tab0 AS cor0
----
121663
31008
50995

onlyif mysql # use DIV operator for integer division
query I rowsort label-3744
SELECT - col0 DIV col0 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-3744
SELECT - col0 / col0 + - cor0.col2 AS col1 FROM tab0 AS cor0
----
-2
-34
-83

query I rowsort
SELECT + col2 * - col1 + col0 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT ALL - tab0.col0 + - 28 AS col1 FROM tab0
----
-117
-52
-63

query I rowsort
SELECT + col1 * + col1 * col1 FROM tab2
----
205379
29791
4913

query I rowsort
SELECT ALL - + 8 * - 4 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT - 35 * cor0.col1 + - ( - cor0.col1 ) AS col1 FROM tab2 cor0
----
-1054
-2006
-578

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 75 * col0 + col2 * - 8 col1 FROM tab1 AS cor0
----
-5256
-657
-6768

query I rowsort
SELECT col2 - col2 * - col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT - - col0 * - 82 + col0 FROM tab0 AS cor0
----
-1944
-2835
-7209

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab2, tab0 AS cor2, tab0
----
13122 values hashing to 16a325869d3ff3692928743ecc2edcdb

query I rowsort
SELECT DISTINCT + 63 * - 47 FROM tab2, tab1 cor0
----
-2961

query I rowsort
SELECT 8 + + 25 * col1 FROM tab0 cor0
----
2158
2283
2433

query I rowsort
SELECT DISTINCT cor0.col1 * + col1 + - col0 AS col2 FROM tab2 AS cor0
----
210
3403
954

query I rowsort
SELECT ALL - col2 + cor0.col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT col0 - - col1 FROM tab0
----
110
132
180

query I rowsort
SELECT - ( - tab2.col1 ) AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3760
SELECT CAST( NULL AS SIGNED ) / - 95 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3760
SELECT CAST ( NULL AS INTEGER ) / - 95 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 80 * col2 AS col1 FROM tab1
----
-4320
-4560
-7680

query I rowsort
SELECT - + 66 FROM tab2 AS cor0
----
-66
-66
-66

query I rowsort
SELECT - col0 + - ( col1 ) AS col0 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT - - cor0.col0 + col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT - col1 * + 32 FROM tab1 AS cor0
----
-320
-416
-832

query I rowsort
SELECT - 30 + col0 * cor0.col2 * + col0 FROM tab0 AS cor0
----
1195
18978
649492

onlyif mysql # use DIV operator for integer division
query I rowsort label-3767
SELECT DISTINCT - col0 + col2 - col0 DIV + 94 col2 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3767
SELECT DISTINCT - col0 + col2 - col0 / + 94 col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT - cor0.col0 + - col2 * ( - cor0.col2 * - cor0.col2 ) FROM tab1 AS cor0
----
-157467
-185257
-884816

query I rowsort
SELECT + cor0.col1 + col1 * - ( col1 ) * + col2 FROM tab0 AS cor0
----
-243982
-678951
-9312

query I rowsort
SELECT + - 67 * - col2 AS col0 FROM tab1 cor0
----
3618
3819
6432

query I rowsort
SELECT ( + ( cor0.col0 ) ) AS col1 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL + - col1 * cor0.col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT col1 + + col0 * + 90 AS col0 FROM tab2 AS cor0
----
661
7079
7127

query I rowsort
SELECT DISTINCT tab1.col1 * 55 FROM tab1
----
1430
550
715

onlyif mysql # use DIV operator for integer division
query I rowsort label-3775
SELECT DISTINCT + col1 DIV + cor0.col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3775
SELECT DISTINCT + col1 / + cor0.col2 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3776
SELECT - col0 DIV + col2 AS col1 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-3776
SELECT - col0 / + col2 AS col1 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT ALL + 40 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to e4d10f7d6c34a281f524e45e82ebd2a0

query I rowsort
SELECT - 59 * col2 + col2 FROM tab2 AS cor0
----
-1508
-1566
-2204

query I rowsort
SELECT DISTINCT - + 22 AS col1 FROM tab2 AS cor0
----
-22

onlyif mysql # use DIV operator for integer division
query I rowsort label-3780
SELECT ALL - + ( cor0.col0 ) DIV + cor0.col0 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3780
SELECT ALL - + ( cor0.col0 ) / + cor0.col0 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col0 * ( - 71 ) FROM tab1
----
-213
-4544
-5680

query I rowsort
SELECT DISTINCT - ( col2 ) + col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL + 4 FROM tab0, tab0 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT cor0.col0 AS col0 FROM tab0, tab2 cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT DISTINCT - col0 * + tab2.col2 AS col0 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT col2 + 19 FROM tab0
----
101
20
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 col2 FROM tab0, tab1 cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3788
SELECT col2 DIV ( col2 ) + - col2 FROM tab1
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-3788
SELECT col2 / ( col2 ) + - col2 FROM tab1
----
-53
-56
-95

query I rowsort
SELECT ALL - 38 AS col2 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to e8c064543bf0f2e57329db1bb0a411e3

query I rowsort
SELECT DISTINCT - cor0.col1 * col1 * 46 FROM tab0 cor0
----
-340216
-380926
-432814

query I rowsort
SELECT DISTINCT + - cor0.col0 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT - - col2 + ( cor0.col1 ) * col2 AS col2 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3793
SELECT ALL - col2 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3793
SELECT ALL - col2 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3794
SELECT DISTINCT - col0 DIV + 11 AS col0 FROM tab2 AS cor0
----
-7
0

skipif mysql # not compatible
query I rowsort label-3794
SELECT DISTINCT - col0 / + 11 AS col0 FROM tab2 AS cor0
----
-7
0

query I rowsort
SELECT ALL - col1 - + 14 FROM tab1 cor0
----
-24
-27
-40

query I rowsort
SELECT + col2 * - 34 + col0 AS col2 FROM tab0 AS cor0
----
-1098
-2699
1

query I rowsort
SELECT ALL cor0.col2 * - 98 FROM tab1 AS cor0
----
-5292
-5586
-9408

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 * - col0 col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + - col0 * + col1 + + col0 * + col2 AS col2 FROM tab1 AS cor0
----
3008
6640
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * - ( - col0 ) + col0 col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT - ( col2 ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT + 6 * col1 AS col1 FROM tab1 AS cor0
----
156
60
78

query I rowsort
SELECT + ( col2 ) + + col0 * + 96 FROM tab0 cor0
----
2337
3361
8626

query I rowsort
SELECT DISTINCT + col2 * - col2 - col2 AS col2 FROM tab0 AS cor0
----
-1122
-2
-6806

query I rowsort
SELECT ALL - 78 AS col2 FROM tab1 AS cor0
----
-78
-78
-78

query I rowsort
SELECT DISTINCT + cor0.col0 + + col1 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + col2 + - 25 * - cor0.col1 * col1 AS col0 FROM tab0 AS cor0
----
184933
207107
235226

query I rowsort
SELECT col0 + col0 * col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + 30 + col1 + ( + 87 ) FROM tab2
----
134
148
176

query I rowsort
SELECT 40 + col1 AS col0 FROM tab0 cor0
----
126
131
137

query I rowsort
SELECT ALL 47 + + cor0.col0 + - col2 FROM tab1 AS cor0
----
-4
31
54

query I rowsort
SELECT DISTINCT cor0.col1 * col1 AS col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL - - 64 + + col1 * + ( + 43 ) FROM tab1 cor0
----
1182
494
623

query I rowsort
SELECT - col2 * col2 + col1 * - col1 + - col0 * col2 AS col1 FROM tab2 cor0
----
-1879
-4735
-6185

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - - col2 col2 FROM tab1
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3816
SELECT ALL - ( col0 ) DIV - 10 + - tab0.col1 * col2 AS col1 FROM tab0
----
-2836
-7454
-94

skipif mysql # not compatible
query I rowsort label-3816
SELECT ALL - ( col0 ) / - 10 + - tab0.col1 * col2 AS col1 FROM tab0
----
-2836
-7454
-94

query I rowsort
SELECT ALL + - col2 * + cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + col2 + - 73 * 32 FROM tab0 AS cor0
----
-2254
-2303
-2335

query I rowsort
SELECT ALL + + col0 - ( - col0 * col2 ) AS col0 FROM tab0 AS cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-3820
SELECT DISTINCT + cor0.col2 DIV 77 + + 23 DIV col0 AS col0 FROM tab2 cor0
----
0
3

skipif mysql # not compatible
query I rowsort label-3820
SELECT DISTINCT + cor0.col2 / 77 + + 23 / col0 AS col0 FROM tab2 cor0
----
0
3

query I rowsort
SELECT - ( + col0 ) + 7 * + tab0.col0 AS col1 FROM tab0
----
144
210
534

query I rowsort
SELECT col2 + - col0 + 14 FROM tab0
----
-20
23
7

query I rowsort
SELECT 27 * + col2 + col0 FROM tab0
----
2303
62
915

query I rowsort
SELECT DISTINCT + col1 + col1 * - 44 AS col0 FROM tab1
----
-1118
-430
-559

query I rowsort
SELECT ( + col2 ) * col0 FROM tab2
----
189
2028
3002

query I rowsort
SELECT - 37 * col2 AS col0 FROM tab0
----
-1221
-3034
-37

query I rowsort
SELECT DISTINCT col2 + - tab1.col1 + tab1.col1 FROM tab1
----
54
57
96

query I rowsort
SELECT - - col2 - 42 FROM tab2 AS cor0
----
-15
-16
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-3829
SELECT col2 DIV - 37 FROM tab0 AS cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-3829
SELECT col2 / - 37 FROM tab0 AS cor0
----
-2
0
0

query I rowsort
SELECT - col0 + - col0 * col0 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT - + col1 * ( col1 * + col2 ) + - 53 * col2 AS col2 FROM tab2 AS cor0
----
-12996
-27378
-91884

onlyif mysql # use DIV operator for integer division
query I rowsort label-3832
SELECT 59 * col1 DIV col1 + + col0 + - col2 FROM tab0
----
50
66
93

skipif mysql # not compatible
query I rowsort label-3832
SELECT 59 * col1 / col1 + + col0 + - col2 FROM tab0
----
50
66
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3833
SELECT 72 DIV col2 AS col1 FROM tab0
----
0
2
72

skipif mysql # not compatible
query I rowsort label-3833
SELECT 72 / col2 AS col1 FROM tab0
----
0
2
72

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * - col2 * - 65 + tab1.col1 col2 FROM tab1
----
189566
211195
599053

query I rowsort
SELECT DISTINCT + tab1.col2 AS col1 FROM tab1, tab2 cor0
----
54
57
96

query I rowsort
SELECT col2 + 64 + 76 FROM tab0
----
141
173
222

query I rowsort
SELECT ALL 17 AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to e0dd9155e4d67132637a04c18ef46b2a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3838
SELECT DISTINCT - col0 * CAST( NULL AS DECIMAL ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3838
SELECT DISTINCT - col0 * CAST ( NULL AS REAL ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + col2 + + 61 FROM tab2 AS cor0
----
87
88
99

query I rowsort
SELECT DISTINCT - - cor0.col1 + 41 AS col1 FROM tab1 AS cor0
----
51
54
67

query I rowsort
SELECT - col1 * col1 + - col2 FROM tab2 AS cor0
----
-327
-3507
-988

query I rowsort
SELECT DISTINCT 24 + tab2.col0 AS col0 FROM tab2, tab2 AS cor0
----
102
103
31

query I rowsort
SELECT - 46 AS col1 FROM tab2 AS cor0
----
-46
-46
-46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3844
SELECT ALL CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3844
SELECT ALL CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 + - ( + col2 ) AS col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL + 33 * cor0.col0 AS col0 FROM tab2 AS cor0
----
231
2574
2607

query I rowsort
SELECT DISTINCT + col0 * + col0 AS col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL + + col2 + + cor0.col2 AS col1 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT - 90 * + cor0.col2 + col2 * 20 FROM tab2 cor0
----
-1820
-1890
-2660

query I rowsort
SELECT 19 AS col0 FROM tab2 AS cor0
----
19
19
19

query I rowsort
SELECT + - 56 * - col1 AS col1 FROM tab1 AS cor0
----
1456
560
728

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3852
SELECT DISTINCT - col0 + cor0.col1 + - CAST( - col0 AS SIGNED ) FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-3852
SELECT DISTINCT - col0 + cor0.col1 + - CAST ( - col0 AS INTEGER ) FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL - - col0 + - cor0.col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - - 75 * - col0 + col2 AS col0 FROM tab1 AS cor0
----
-171
-4743
-5904

query I rowsort
SELECT DISTINCT - cor0.col0 * + col0 + cor0.col2 AS col0 FROM tab1 cor0
----
-4039
-6304
45

query I rowsort
SELECT ALL + cor0.col1 * + col1 + 0 AS col0 FROM tab2 AS cor0
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-3857
SELECT col0 DIV 15 AS col2 FROM tab0
----
1
2
5

skipif mysql # not compatible
query I rowsort label-3857
SELECT col0 / 15 AS col2 FROM tab0
----
1
2
5

query I rowsort
SELECT 61 AS col2 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 9b52d3939da22c8931e3d5a72ddfb1b1

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0, tab2 AS cor1, tab1 cor2
----
972 values hashing to 75a813ebd5ec5ec2e67a66d0593ff763

query I rowsort
SELECT 52 + ( - col0 + col2 * 14 ) AS col0 FROM tab1 AS cor0
----
1316
786
805

query I rowsort
SELECT + col0 + col0 + + col0 FROM tab0 AS cor0
----
105
267
72

query I rowsort
SELECT + 60 * cor0.col0 AS col2 FROM tab1 cor0
----
180
3840
4800

query I rowsort
SELECT - ( col0 ) - - col2 * col0 * cor0.col0 AS col0 FROM tab1 AS cor0
----
233408
483
614320

query I rowsort
SELECT DISTINCT + + ( + col0 ) * - col0 FROM tab1 cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-3865
SELECT col0 * + col1 + + col0 DIV + col1 col2 FROM tab0 AS cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3865
SELECT col0 * + col1 + + col0 / + col1 col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + + ( col0 ) - + ( + col0 + col2 ) FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - col1 + - col2 * 41 FROM tab1 AS cor0
----
-2240
-2347
-3949

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 - col0 * cor0.col1 col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 23 col1 FROM tab0 AS cor0
----
23
23
23

query I rowsort
SELECT - cor0.col1 * + col2 + - col2 AS col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT - 47 FROM tab1, tab1 AS cor0
----
9 values hashing to 6942a0d9558277afd0d00408d65cf5aa

query I rowsort
SELECT DISTINCT - + ( cor0.col2 ) + + cor0.col2 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL + - col2 + - cor0.col0 AS col0 FROM tab1 cor0
----
-121
-176
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-3874
SELECT - col2 + - col1 DIV cor0.col0 col1 FROM tab0 AS cor0
----
-3
-36
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3874
SELECT - col2 + - col1 / cor0.col0 col1 FROM tab0 AS cor0
----
-3
-36
-83

query I rowsort
SELECT DISTINCT + 77 FROM tab2
----
77

query I rowsort
SELECT col2 * - cor0.col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT col2 * - 23 AS col1 FROM tab0 AS cor0
----
-1886
-23
-759

query I rowsort
SELECT + cor0.col1 * - col0 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + col2 col0 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT - col2 * + ( col2 * col2 ) AS col0 FROM tab0 AS cor0
----
-1
-35937
-551368

onlyif mysql # use DIV operator for integer division
query I rowsort label-3881
SELECT - col1 DIV - 89 AS col1 FROM tab0 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-3881
SELECT - col1 / - 89 AS col1 FROM tab0 AS cor0
----
0
1
1

query I rowsort
SELECT ALL + col1 * - 98 FROM tab0 AS cor0
----
-8428
-8918
-9506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3883
SELECT ( + cor0.col0 ) * + col2 * - CAST( + col0 AS SIGNED ) FROM tab2 cor0
----
-1323
-158184
-237158

skipif mysql # not compatible
query I rowsort label-3883
SELECT ( + cor0.col0 ) * + col2 * - CAST ( + col0 AS INTEGER ) FROM tab2 cor0
----
-1323
-158184
-237158

query I rowsort
SELECT DISTINCT - - 87 * - col0 + - col0 FROM tab1 cor0
----
-264
-5632
-7040

query I rowsort
SELECT - - ( - cor0.col2 ) + - col2 AS col1 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT ALL + - col2 * - col1 AS col0 FROM tab0 AS cor0
----
2838
7462
97

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-3888
SELECT + CAST( 63 AS SIGNED ) * col1 * - 1 AS col0 FROM tab0 cor0
----
-5418
-5733
-6111

skipif mysql # not compatible
query I rowsort label-3888
SELECT + CAST ( 63 AS INTEGER ) * col1 * - 1 AS col0 FROM tab0 cor0
----
-5418
-5733
-6111

query I rowsort
SELECT ALL - 72 * + col2 + - col0 FROM tab1 AS cor0
----
-3891
-4168
-6992

query I rowsort
SELECT + + ( - cor0.col2 ) FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL + 86 AS col2 FROM tab2 AS cor0
----
86
86
86

query I rowsort
SELECT - col0 * col0 - 45 FROM tab0
----
-1270
-621
-7966

query I rowsort
SELECT ALL + tab0.col0 + cor0.col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 5b7e2a7b66ad60562d4872f7ae5eab2b

query I rowsort
SELECT - 8 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to 47f43f23dcd23959d97d8e3b0aab692e

query I rowsort
SELECT + - 1 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL - + col2 * col1 + - col2 * cor0.col0 AS col1 FROM tab1 AS cor0
----
-1566
-4218
-8928

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3897
SELECT - - CAST( NULL AS DECIMAL ) * - 23 * cor0.col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3897
SELECT - - CAST ( NULL AS REAL ) * - 23 * cor0.col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 13 + cor0.col0 * 3 FROM tab1 AS cor0
----
205
22
253

query I rowsort
SELECT - - col1 + + col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT + col1 * col2 + 99 * col1 * col1 FROM tab0 cor0
----
735042
827281
931588

query I rowsort
SELECT ALL + 38 + col0 AS col2 FROM tab1
----
102
118
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-3902
SELECT ( - cor1.col0 ) DIV + ( 25 ) FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e6d63ab432fc7a7f17fe6cf3b6fac380

skipif mysql # not compatible
query I rowsort label-3902
SELECT ( - cor1.col0 ) / + ( 25 ) FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e6d63ab432fc7a7f17fe6cf3b6fac380

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 col1 FROM tab2 cor0
----
26
27
38

query I rowsort
SELECT cor0.col1 + 35 AS col2 FROM tab1 AS cor0
----
45
48
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-3905
SELECT ALL col1 DIV col0 - + col2 DIV col0 FROM tab1 cor0
----
-1
-10
0

skipif mysql # not compatible
query I rowsort label-3905
SELECT ALL col1 / col0 - + col2 / col0 FROM tab1 cor0
----
-1
-10
0

query I rowsort
SELECT DISTINCT col1 * + 40 FROM tab1 AS cor0
----
1040
400
520

onlyif mysql # use DIV operator for integer division
query I rowsort label-3907
SELECT DISTINCT + col0 DIV cor0.col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-3907
SELECT DISTINCT + col0 / cor0.col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT col2 + cor0.col0 * - 56 AS col1 FROM tab1 AS cor0
----
-114
-3527
-4384

onlyif mysql # use DIV operator for integer division
query I rowsort label-3909
SELECT DISTINCT + - col1 + - col2 * col2 DIV - cor0.col2 - + cor0.col0 AS col0 FROM tab0 cor0
----
-131
-77
-98

skipif mysql # not compatible
query I rowsort label-3909
SELECT DISTINCT + - col1 + - col2 * col2 / - cor0.col2 - + cor0.col0 AS col0 FROM tab0 cor0
----
-131
-77
-98

query I rowsort
SELECT DISTINCT + cor0.col1 + + col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT - cor1.col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT ALL + col2 * - cor0.col0 * 79 AS col1 FROM tab1 AS cor0
----
-12798
-288192
-606720

query I rowsort
SELECT ALL tab1.col2 * + 42 + - col2 AS col1 FROM tab1
----
2214
2337
3936

query I rowsort
SELECT DISTINCT ( col0 ) - - col2 FROM tab2
----
104
117
34

query I rowsort
SELECT DISTINCT 9 - col2 * col1 FROM tab0
----
-2829
-7453
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + ( col0 ) col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL cor0.col1 + - col2 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT col1 - col0 AS col1 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3919
SELECT ALL + CAST( ( cor0.col2 ) AS SIGNED ) + - col0 + 42 FROM tab0 AS cor0
----
35
51
8

skipif mysql # not compatible
query I rowsort label-3919
SELECT ALL + CAST ( ( cor0.col2 ) AS INTEGER ) + - col0 + 42 FROM tab0 AS cor0
----
35
51
8

query I rowsort
SELECT + tab2.col0 AS col0 FROM tab0, tab2 AS cor0 CROSS JOIN tab2
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT col2 + + col1 AS col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + 32 + col2 * + 41 AS col1 FROM tab2 AS cor0
----
1098
1139
1590

onlyif mysql # use DIV operator for integer division
query I rowsort label-3923
SELECT DISTINCT + - ( col2 ) * + col0 + 61 DIV - col0 + 65 * + col2 * + col0 FROM tab1 cor0
----
10348
233472
491520

skipif mysql # not compatible
query I rowsort label-3923
SELECT DISTINCT + - ( col2 ) * + col0 + 61 / - col0 + 65 * + col2 * + col0 FROM tab1 cor0
----
10348
233472
491520

query I rowsort
SELECT - - 83 + col1 * 12 * + col2 FROM tab1 AS cor0
----
15059
16931
6923

query I rowsort
SELECT DISTINCT col2 * col2 + + col0 AS col1 FROM tab1 AS cor0
----
2919
3313
9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-3926
SELECT ALL - col1 DIV cor0.col1 - + ( col0 * + cor0.col1 ) AS col0 FROM tab1 AS cor0
----
-1041
-641
-79

skipif mysql # not compatible
query I rowsort label-3926
SELECT ALL - col1 / cor0.col1 - + ( col0 * + cor0.col1 ) AS col0 FROM tab1 AS cor0
----
-1041
-641
-79

query I rowsort
SELECT - ( col2 ) * cor0.col2 + - cor0.col1 FROM tab2 cor0
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT tab1.col1 * - tab1.col2 AS col1 FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort
SELECT ALL + 63 * + col1 + CAST ( - 73 AS REAL ) FROM tab1 AS cor0
----
1565
557
746

onlyif mysql # use DIV operator for integer division
query I rowsort label-3930
SELECT ALL + 46 + col1 DIV - col2 AS col2 FROM tab0 AS cor0
----
-51
44
45

skipif mysql # not compatible
query I rowsort label-3930
SELECT ALL + 46 + col1 / - col2 AS col2 FROM tab0 AS cor0
----
-51
44
45

query I rowsort
SELECT DISTINCT + - col2 * cor0.col2 AS col2 FROM tab1 cor0
----
-2916
-3249
-9216

query I rowsort
SELECT cor0.col1 + col0 * + 39 AS col0 FROM tab0 AS cor0
----
1022
1462
3562

query I rowsort
SELECT ALL + col1 * col1 + - col2 AS col0 FROM tab1 AS cor0
----
43
622
73

query I rowsort
SELECT DISTINCT + - col1 + + col0 AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT + col1 - col0 * ( col0 ) FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT ALL - col2 * ( col0 ) FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL + tab0.col2 * + 13 FROM tab0
----
1066
13
429

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab1 AS cor0, tab0 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to 71180f9f3efadf0ee3a7fec9678208ad

query I rowsort
SELECT + col2 + 59 * col0 FROM tab2 AS cor0
----
440
4628
4699

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3940
SELECT DISTINCT + - cor0.col2 * + CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3940
SELECT DISTINCT + - cor0.col2 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - col1 * 98 FROM tab1 AS cor0
----
-1274
-2548
-980

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3942
SELECT col1 + CAST( - col0 AS SIGNED ) * col0 FROM tab0 cor0
----
-1128
-490
-7830

skipif mysql # not compatible
query I rowsort label-3942
SELECT col1 + CAST ( - col0 AS INTEGER ) * col0 FROM tab0 cor0
----
-1128
-490
-7830

query I rowsort
SELECT col1 * 67 AS col2 FROM tab0 AS cor0
----
5762
6097
6499

query I rowsort
SELECT DISTINCT + col2 * - 2 AS col2 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT - col0 * + 0 AS col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3946
SELECT CAST( NULL AS SIGNED ) - col2 * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3946
SELECT CAST ( NULL AS INTEGER ) - col2 * col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 + + 30 AS col2 FROM tab0 AS cor0
----
119
54
65

query I rowsort
SELECT DISTINCT - col0 * col0 - col2 * ( 62 ) FROM tab0 AS cor0
----
-1287
-13005
-2622

query I rowsort
SELECT + 18 * + 93 + + col0 FROM tab2 AS cor0
----
1681
1752
1753

query I rowsort
SELECT ALL + - col1 - - cor0.col0 * + col2 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT DISTINCT + col1 + col0 * cor0.col1 + + ( col2 ) AS col0 FROM tab1 AS cor0
----
1149
158
707

query I rowsort
SELECT DISTINCT - col2 * ( + cor0.col2 ) AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-3953
SELECT DISTINCT ( col0 ) DIV col0 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-3953
SELECT DISTINCT ( col0 ) / col0 FROM tab0 AS cor0
----
1

query I rowsort
SELECT - 0 * + col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - - 13 + col0 + + col1 FROM tab1 AS cor0
----
106
42
87

query I rowsort
SELECT ALL - + col2 * col0 + col2 FROM tab1 cor0
----
-108
-3591
-7584

query I rowsort
SELECT + col0 - + col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL + cor0.col0 + col1 AS col2 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3959
SELECT DISTINCT - + col0 * + cor0.col1 - col2 * CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3959
SELECT DISTINCT - + col0 * + cor0.col1 - col2 * CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3960
SELECT DISTINCT - 30 * cor0.col0 + + col1 + CAST( - col2 + + col0 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-115
-1903
-2403

skipif mysql # not compatible
query I rowsort label-3960
SELECT DISTINCT - 30 * cor0.col0 + + col1 + CAST ( - col2 + + col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-115
-1903
-2403

query I rowsort
SELECT DISTINCT - + ( col1 ) - - col2 AS col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT ALL ( col2 ) * col2 AS col1 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT + 59 - + ( - col2 + - 90 ) * + 30 AS col2 FROM tab0 AS cor0
----
2789
3749
5219

query I rowsort
SELECT - col0 + - col2 AS col0 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT ALL + col2 + ( col2 ) AS col0 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT ALL - - col1 + col1 * cor0.col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT + ( - col2 ) AS col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL + col0 * ( + col0 ) FROM tab0
----
1225
576
7921

query I rowsort
SELECT DISTINCT - 50 AS col2 FROM tab2 AS cor0
----
-50

query I rowsort
SELECT ALL cor0.col0 * col2 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - col1 * + 23 AS col2 FROM tab2 AS cor0
----
-1357
-391
-713

query I rowsort
SELECT ALL - - ( + col0 ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT DISTINCT col0 * ( - col2 ) FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT cor0.col0 * col2 AS col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-3975
SELECT + ( cor0.col0 ) + col1 * cor0.col2 DIV 4 AS col1 FROM tab1 AS cor0
----
206
354
392

skipif mysql # not compatible
query I rowsort label-3975
SELECT + ( cor0.col0 ) + col1 * cor0.col2 / 4 AS col1 FROM tab1 AS cor0
----
206
354
392

query I rowsort
SELECT - + cor0.col1 + col1 - col1 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT col1 + + 27 + col1 * col2 AS col2 FROM tab2
----
1620
690
895

query I rowsort
SELECT + ( col2 ) * - tab0.col1 FROM tab0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col1 + col0 + - col2 col1 FROM tab1
----
-25
-3
17

query I rowsort
SELECT DISTINCT + tab1.col0 FROM tab1, tab1 cor0
----
3
64
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3981
SELECT CAST( + col2 * - col0 AS SIGNED ) AS col2 FROM tab0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-3981
SELECT CAST ( + col2 * - col0 AS INTEGER ) AS col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT col2 * + col2 + + col0 FROM tab2
----
1523
736
754

query I rowsort
SELECT DISTINCT + 93 * - col1 FROM tab1
----
-1209
-2418
-930

query I rowsort
SELECT DISTINCT - tab0.col2 + + col0 AS col0 FROM tab0
----
-9
34
7

query I rowsort
SELECT DISTINCT + 43 * ( + col0 ) * 37 AS col2 FROM tab0
----
141599
38184
55685

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 46 col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 491ad1fb79fec0b5715ea54949d1aa2d

query I rowsort
SELECT - - col0 + col1 * - cor0.col1 + + col0 AS col0 FROM tab1 AS cor0
----
-670
-9
28

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3988
SELECT + cor0.col2 * CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3988
SELECT + cor0.col2 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * col1 + - col0 AS col2 FROM tab1 AS cor0
----
36
673
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-3990
SELECT + + col0 DIV 6 AS col1 FROM tab0 cor0
----
14
4
5

skipif mysql # not compatible
query I rowsort label-3990
SELECT + + col0 / 6 AS col1 FROM tab0 cor0
----
14
4
5

query I rowsort
SELECT - + cor0.col1 * cor0.col0 AS col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL - - cor0.col0 + + 47 FROM tab1 AS cor0
----
111
127
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-3993
SELECT + cor0.col0 DIV + 23 FROM tab0 cor0
----
1
1
3

skipif mysql # not compatible
query I rowsort label-3993
SELECT + cor0.col0 / + 23 FROM tab0 cor0
----
1
1
3

query I rowsort
SELECT + tab2.col1 * - col0 * 43 FROM tab2
----
-197886
-57749
-9331

query I rowsort
SELECT ALL + 58 + col1 AS col0 FROM tab1
----
68
71
84

query I rowsort
SELECT DISTINCT + tab0.col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3997
SELECT DISTINCT + col1 + - col0 + CAST( NULL AS DECIMAL ) * + col2 AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-3997
SELECT DISTINCT + col1 + - col0 + CAST ( NULL AS REAL ) * + col2 AS col1 FROM tab1
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3998
SELECT + 9 + - col1 * CAST( + col2 AS SIGNED ) AS col1 FROM tab2
----
-1525
-637
-828

skipif mysql # not compatible
query I rowsort label-3998
SELECT + 9 + - col1 * CAST ( + col2 AS INTEGER ) AS col1 FROM tab2
----
-1525
-637
-828

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col0 col0 FROM tab0
----
110
132
180

query I rowsort
SELECT col2 * col1 * - 84 + + 18 AS col2 FROM tab1
----
-104814
-117918
-47862

onlyif mysql # use DIV operator for integer division
query I rowsort label-4001
SELECT col2 + col0 DIV col2 FROM tab0
----
33
36
83

skipif mysql # not compatible
query I rowsort label-4001
SELECT col2 + col0 / col2 FROM tab0
----
33
36
83

query I rowsort
SELECT 95 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT ALL col0 * - 40 + - col0 FROM tab2 AS cor0
----
-287
-3198
-3239

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4004
SELECT - col1 * - CAST( + col0 AS SIGNED ) * + col0 AS col2 FROM tab1 AS cor0
----
234
40960
83200

skipif mysql # not compatible
query I rowsort label-4004
SELECT - col1 * - CAST ( + col0 AS INTEGER ) * + col0 AS col2 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT ALL - col2 + 80 FROM tab0 AS cor0
----
-2
47
79

query I rowsort
SELECT DISTINCT col1 * - ( 30 ) AS col0 FROM tab1 AS cor0
----
-300
-390
-780

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4007
SELECT DISTINCT cor0.col0 + - CAST( - col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
121
176
57

skipif mysql # not compatible
query I rowsort label-4007
SELECT DISTINCT cor0.col0 + - CAST ( - col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4008
SELECT ALL - + col2 * + CAST( NULL AS SIGNED ) + col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4008
SELECT ALL - + col2 * + CAST ( NULL AS INTEGER ) + col2 AS col2 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col0 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT 36 AS col2 FROM tab1
----
36
36
36

query I rowsort
SELECT cor0.col1 AS col2 FROM tab1, tab2, tab0 AS cor0, tab0 cor1
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT + tab0.col1 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT ALL 41 AS col1 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

query I rowsort
SELECT - 78 AS col1 FROM tab1 AS cor0
----
-78
-78
-78

query I rowsort
SELECT + - col0 + ( + col2 ) * + col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT ALL col2 - col0 * col1 AS col1 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT + - col0 * - cor0.col2 - - 86 AS col1 FROM tab1 AS cor0
----
248
3734
7766

query I rowsort
SELECT ALL - col1 * col2 AS col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT + - 25 * - cor0.col1 FROM tab0 AS cor0
----
2150
2275
2425

query I rowsort
SELECT + - col2 + + ( - col1 ) AS col0 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL + ( + 78 ) FROM tab1, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT - - 21 + 48 AS col2 FROM tab2 AS cor0
----
69
69
69

query I rowsort
SELECT + col2 + ( col2 ) + + col1 FROM tab0 AS cor0
----
152
255
99

query I rowsort
SELECT + + 96 + + 77 * col0 AS col2 FROM tab0 AS cor0
----
1944
2791
6949

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4025
SELECT - CAST( col2 AS SIGNED ) * col0 + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

skipif mysql # not compatible
query I rowsort label-4025
SELECT - CAST ( col2 AS INTEGER ) * col0 + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT - 28 * col1 FROM tab2 cor0
----
-1652
-476
-868

query I rowsort
SELECT + col1 + + 44 * + col1 FROM tab0 AS cor0
----
3870
4095
4365

onlyif mysql # use DIV operator for integer division
query I rowsort label-4028
SELECT + + col1 DIV + col1 AS col1 FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4028
SELECT + + col1 / + col1 AS col1 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT + 9 * col2 AS col1 FROM tab1 AS cor0
----
486
513
864

query I rowsort
SELECT ALL + 6 FROM tab2, tab2 AS cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4031
SELECT DISTINCT + + col1 * + col2 * CAST( - col1 AS SIGNED ) FROM tab2 AS cor0
----
-10982
-25947
-90506

skipif mysql # not compatible
query I rowsort label-4031
SELECT DISTINCT + + col1 * + col2 * CAST ( - col1 AS INTEGER ) FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT ALL - col0 * - col1 + - 58 AS col2 FROM tab1 AS cor0
----
20
582
982

query I rowsort
SELECT 45 * - col0 AS col0 FROM tab2 cor0
----
-315
-3510
-3555

query I rowsort
SELECT ALL - - 81 AS col0 FROM tab2 AS cor0
----
81
81
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 14 + col2 col0 FROM tab0 AS cor0
----
-13
19
68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4036
SELECT col2 + col1 + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4036
SELECT col2 + col1 + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 83 * col0 AS col0 FROM tab0
----
1992
2905
7387

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4038
SELECT ALL + + col2 + + col1 + CAST( - 99 AS SIGNED ) col1 FROM tab0 AS cor0
----
-1
20
74

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4038
SELECT ALL + + col2 + + col1 + CAST ( - 99 AS INTEGER ) col1 FROM tab0 AS cor0
----
-1
20
74

query I rowsort
SELECT col2 * col0 + + col1 AS col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL + + col0 + col2 AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - 71 * cor0.col1 + - col0 AS col1 FROM tab2 AS cor0
----
-1286
-2208
-4267

onlyif mysql # use DIV operator for integer division
query I rowsort label-4042
SELECT + - col2 DIV + col1 + col2 col0 FROM tab2 cor0
----
26
27
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4042
SELECT + - col2 / + col1 + col2 col0 FROM tab2 cor0
----
26
27
36

query I rowsort
SELECT DISTINCT 66 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 11 col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 05cc989122d7724c7abefaba9625ef3d

query I rowsort
SELECT + cor0.col0 + + col2 * col2 AS col0 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT - 12 + col0 + - col0 AS col1 FROM tab2 AS cor0
----
-12
-12
-12

query I rowsort
SELECT DISTINCT - - cor0.col2 + - col0 AS col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT 5 - - col0 * col1 AS col2 FROM tab2 AS cor0
----
1348
222
4607

onlyif mysql # use DIV operator for integer division
query I rowsort label-4049
SELECT DISTINCT - col0 + - col1 DIV - col0 FROM tab1 AS cor0
----
-64
-80
5

skipif mysql # not compatible
query I rowsort label-4049
SELECT DISTINCT - col0 + - col1 / - col0 FROM tab1 AS cor0
----
-64
-80
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4050
SELECT + tab2.col1 * CAST( + 84 AS SIGNED ) FROM tab2
----
1428
2604
4956

skipif mysql # not compatible
query I rowsort label-4050
SELECT + tab2.col1 * CAST ( + 84 AS INTEGER ) FROM tab2
----
1428
2604
4956

onlyif mysql # use DIV operator for integer division
query I rowsort label-4051
SELECT col1 - col2 DIV + col0 AS col2 FROM tab1
----
10
12
8

skipif mysql # not compatible
query I rowsort label-4051
SELECT col1 - col2 / + col0 AS col2 FROM tab1
----
10
12
8

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2
----
972 values hashing to 5342fb4caf4767cb98bd21989bad099f

query I rowsort
SELECT ( + col1 ) AS col0 FROM tab2
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-4054
SELECT + col1 * ( + col0 ) + col0 DIV col2 - - tab1.col2 FROM tab1
----
1136
132
698

skipif mysql # not compatible
query I rowsort label-4054
SELECT + col1 * ( + col0 ) + col0 / col2 - - tab1.col2 FROM tab1
----
1136
132
698

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + ( - col2 + tab1.col0 ) col2 FROM tab1
----
-48
64
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4056
SELECT + CAST( NULL AS SIGNED ) * ( col2 ) + 42 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4056
SELECT + CAST ( NULL AS INTEGER ) * ( col2 ) + 42 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ( 32 ) * col0 + - tab2.col2 * ( col0 ) AS col2 FROM tab2
----
-474
35
468

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4058
SELECT CAST( NULL AS DECIMAL ) + col1 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4058
SELECT CAST ( NULL AS REAL ) + col1 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - tab1.col1 + cor0.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 6d41c12cb7dc2feb0f506cde1620da9c

query I rowsort
SELECT col0 * tab1.col1 * col2 AS col2 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT - + col1 * + cor0.col2 - + col1 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT + + 11 + 17 AS col2 FROM tab0 AS cor0
----
28
28
28

query I rowsort
SELECT ALL - col1 * - col1 AS col2 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT col0 + cor0.col1 * - col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT - cor0.col2 * col0 * + 92 FROM tab0 AS cor0
----
-3220
-671416
-72864

query I rowsort
SELECT col2 * - col0 AS col0 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + - col1 * col2 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - col1 + + col0 * + 97 FROM tab1 AS cor0
----
265
6198
7747

query I rowsort
SELECT tab0.col1 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-4070
SELECT - col2 * tab0.col1 DIV + col2 - - col0 FROM tab0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort label-4070
SELECT - col2 * tab0.col1 / + col2 - - col0 FROM tab0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4071
SELECT col1 + col2 DIV ( tab1.col2 ) FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-4071
SELECT col1 + col2 / ( tab1.col2 ) FROM tab1
----
11
14
27

query I rowsort
SELECT ALL + col0 + - 41 * col0 FROM tab1
----
-120
-2560
-3200

query I rowsort
SELECT ALL - col2 + col2 * col1 + - col0 AS col1 FROM tab0 AS cor0
----
2781
61
7291

query I rowsort
SELECT - cor0.col2 * col2 + col0 - + col0 AS col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT - - col0 * 4 + - 53 AS col1 FROM tab0 AS cor0
----
303
43
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-4076
SELECT DISTINCT + + col0 DIV col1 + - col2 FROM tab0 cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-4076
SELECT DISTINCT + + col0 / col1 + - col2 FROM tab0 cor0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 + col2 * + ( col2 ) col2 FROM tab2 AS cor0
----
1406
650
702

onlyif mysql # use DIV operator for integer division
query I rowsort label-4078
SELECT ALL - col2 + ( - col1 ) DIV col1 col0 FROM tab0
----
-2
-34
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4078
SELECT ALL - col2 + ( - col1 ) / col1 col0 FROM tab0
----
-2
-34
-83

query I rowsort
SELECT DISTINCT - tab2.col1 * 69 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
-1173
-2139
-4071

query I rowsort
SELECT + cor1.col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ALL col1 + + tab2.col0 * - col0 FROM tab2
----
-18
-6025
-6224

query I rowsort
SELECT ALL + tab0.col2 * col1 + col0 AS col0 FROM tab0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-4083
SELECT - col0 + - col1 DIV + ( - col1 * col0 ) FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-4083
SELECT - col0 + - col1 / + ( - col1 * col0 ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT - col1 * + cor0.col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT cor0.col0 * - cor0.col0 FROM tab2 cor0
----
-49
-6084
-6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-4086
SELECT DISTINCT - col0 DIV + col1 FROM tab2 cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-4086
SELECT DISTINCT - col0 / + col1 FROM tab2 cor0
----
-1
-4
0

query I rowsort
SELECT - ( + col0 ) * tab2.col0 + 18 FROM tab2
----
-31
-6066
-6223

query I rowsort
SELECT + - cor0.col0 + col1 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT + cor0.col1 + + col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT + col0 + cor0.col0 * - col2 AS col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT ALL + cor0.col1 * + cor0.col0 - col2 AS col1 FROM tab2 cor0
----
1305
190
4576

query I rowsort
SELECT DISTINCT + 8 * col1 AS col2 FROM tab2 AS cor0
----
136
248
472

onlyif mysql # use DIV operator for integer division
query I rowsort label-4093
SELECT col2 * + tab1.col2 * + col1 + - col0 DIV + col1 AS col2 FROM tab1
----
119802
32484
75816

skipif mysql # not compatible
query I rowsort label-4093
SELECT col2 * + tab1.col2 * + col1 + - col0 / + col1 AS col2 FROM tab1
----
119802
32484
75816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4094
SELECT ALL + CAST( col0 AS SIGNED ) * - col1 - + col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

skipif mysql # not compatible
query I rowsort label-4094
SELECT ALL + CAST ( col0 AS INTEGER ) * - col1 - + col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 79 + col2 col1 FROM tab2 AS cor0
----
105
106
117

query I rowsort
SELECT - cor1.col2 AS col1 FROM tab2, tab2 AS cor0, tab2 cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT DISTINCT + + ( 10 ) * col1 FROM tab1 AS cor0
----
100
130
260

query I rowsort
SELECT 17 * col2 FROM tab2
----
442
459
646

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4099
SELECT + CAST( NULL AS SIGNED ) + + 6 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4099
SELECT + CAST ( NULL AS INTEGER ) + + 6 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + col0 * col0 - + col2 AS col1 FROM tab1 AS cor0
----
-19
4049
6317

onlyif mysql # use DIV operator for integer division
query I rowsort label-4101
SELECT + 31 DIV col2 FROM tab0 AS cor0
----
0
0
31

skipif mysql # not compatible
query I rowsort label-4101
SELECT + 31 / col2 FROM tab0 AS cor0
----
0
0
31

query I rowsort
SELECT ALL 75 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

query I rowsort
SELECT DISTINCT + ( + 46 ) AS col0 FROM tab1 AS cor0
----
46

query I rowsort
SELECT - - 55 AS col1 FROM tab0 AS cor0
----
55
55
55

query I rowsort
SELECT - cor0.col1 * + cor0.col1 AS col1 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 0c15ce053d5d7b134ad52c973e726cba

onlyif mysql # use DIV operator for integer division
query I rowsort label-4106
SELECT + 33 + + col2 DIV - col1 col0 FROM tab1
----
26
28
31

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4106
SELECT + 33 + + col2 / - col1 col0 FROM tab1
----
26
28
31

query I rowsort
SELECT col1 * 87 FROM tab1
----
1131
2262
870

query I rowsort
SELECT + tab2.col0 * - col1 AS col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT ALL - - 55 + + col0 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
-1170
-521
-7866

query I rowsort
SELECT ( - col2 ) + cor0.col2 * 85 FROM tab1 AS cor0
----
4536
4788
8064

query I rowsort
SELECT + 48 * + cor0.col2 + cor0.col2 FROM tab0 AS cor0
----
1617
4018
49

query I rowsort
SELECT ALL + - col0 * 7 FROM tab0 AS cor0
----
-168
-245
-623

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 AS cor0, tab2, tab0 cor1
----
972 values hashing to 9a5ab925af18e11f7748f3b2e722ff3d

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0, tab1, tab1 cor1
----
972 values hashing to a8481bfbfcb330825976c5896e54bc19

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col2 * - tab1.col0 AS REAL ) AS col0 FROM tab1
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 88 + + col1 col2 FROM tab1
----
-62
-75
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4117
SELECT DISTINCT - CAST( + 25 AS SIGNED ) * tab0.col0 AS col2 FROM tab0
----
-2225
-600
-875

skipif mysql # not compatible
query I rowsort label-4117
SELECT DISTINCT - CAST ( + 25 AS INTEGER ) * tab0.col0 AS col2 FROM tab0
----
-2225
-600
-875

query I rowsort
SELECT ALL ( - 32 ) * tab1.col0 FROM tab1
----
-2048
-2560
-96

query I rowsort
SELECT DISTINCT - 4 AS col1 FROM tab2
----
-4

query I rowsort
SELECT + 49 * col2 FROM tab1 AS cor0
----
2646
2793
4704

query I rowsort
SELECT ALL ( cor0.col1 ) FROM tab2, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT + col1 * + tab2.col0 AS col0 FROM tab2
----
1343
217
4602

query I rowsort
SELECT ALL - tab1.col0 + 65 FROM tab1, tab0 AS cor0
----
9 values hashing to 72fb061ee53acc50c4115841c2bb1241

query I rowsort
SELECT + 80 + - tab2.col2 + + col0 FROM tab2
----
121
132
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col0 col2 FROM tab2, tab1 cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT + cor0.col0 + col1 AS col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT - ( 7 ) AS col2 FROM tab1, tab2 cor0, tab1 AS cor1
----
27 values hashing to 82db7c0390abae7ccf4512b1302a6466

query I rowsort
SELECT ALL 38 AS col1 FROM tab0
----
38
38
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-4129
SELECT cor0.col1 + - col1 * + col2 + cor0.col1 DIV - ( col2 ) AS col0 FROM tab0 AS cor0
----
-2754
-7372
-97

skipif mysql # not compatible
query I rowsort label-4129
SELECT cor0.col1 + - col1 * + col2 + cor0.col1 / - ( col2 ) AS col0 FROM tab0 AS cor0
----
-2754
-7372
-97

query I rowsort
SELECT col0 + + 93 + col0 * col2 FROM tab0 AS cor0
----
163
7480
909

query I rowsort
SELECT + cor0.col0 * + 80 * - col1 FROM tab2 cor0
----
-107440
-17360
-368160

query I rowsort
SELECT + col2 + cor0.col1 + col1 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT ALL - cor0.col0 FROM tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT - col1 + + ( + 86 ) AS col1 FROM tab2 cor0
----
27
55
69

query I rowsort
SELECT - + cor0.col2 * 95 + 5 FROM tab2 AS cor0
----
-2465
-2560
-3605

query I rowsort
SELECT DISTINCT + col0 * ( col0 ) + - cor0.col0 FROM tab2 cor0
----
42
6006
6162

query I rowsort
SELECT col1 * - col0 + ( col0 ) FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT col2 + 92 * - ( col2 ) FROM tab0 AS cor0
----
-3003
-7462
-91

query I rowsort
SELECT DISTINCT + col2 + - col0 AS col0 FROM tab0
----
-34
-7
9

query I rowsort
SELECT - col1 * - ( + 55 ) + - col0 - - tab1.col0 FROM tab1
----
1430
550
715

query I rowsort
SELECT + 32 AS col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to cf4f01ac97eb83445b1721f3ae28961a

query I rowsort
SELECT ALL col2 + - 79 * + col2 AS col2 FROM tab0
----
-2574
-6396
-78

query I rowsort
SELECT ALL - col1 * col2 * - col0 FROM tab1 AS cor0
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + cor0.col2 * - col0 col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - col0 * col1 * + col0 AS col0 FROM tab2
----
-106097
-1519
-358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab0.col1 + 58 col0 FROM tab0
----
-28
-33
-39

query I rowsort
SELECT + col1 + ( col2 ) AS col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL + 94 + + 81 FROM tab1 AS cor0
----
175
175
175

query I rowsort
SELECT DISTINCT + cor0.col1 + 18 FROM tab0 cor0
----
104
109
115

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4150
SELECT DISTINCT CAST( NULL AS SIGNED ) + - col2 + + col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4150
SELECT DISTINCT CAST ( NULL AS INTEGER ) + - col2 + + col1 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 80 col1 FROM tab2 AS cor0
----
80
80
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4152
SELECT - 20 * ( cor0.col2 ) + - ( + col0 ) DIV + col2 FROM tab1 AS cor0
----
-1080
-1141
-1920

skipif mysql # not compatible
query I rowsort label-4152
SELECT - 20 * ( cor0.col2 ) + - ( + col0 ) / + col2 FROM tab1 AS cor0
----
-1080
-1141
-1920

query I rowsort
SELECT DISTINCT - 51 * + 56 * col1 + cor0.col0 FROM tab0 cor0
----
-245592
-259807
-276997

query I rowsort
SELECT ALL - ( + col1 ) + - col2 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT 94 + - col2 AS col1 FROM tab0 AS cor0
----
12
61
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 * + col2 col1 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-4157
SELECT col1 DIV + 96 col1 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4157
SELECT col1 / + 96 col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + ( col2 ) + cor0.col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT ALL - col1 + - col1 * + col1 AS col1 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT DISTINCT + + col2 + col1 + + col2 AS col0 FROM tab0 cor0
----
152
255
99

query I rowsort
SELECT ALL col1 * - col0 + col2 FROM tab2 AS cor0
----
-1305
-190
-4576

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4162
SELECT DISTINCT CAST( NULL AS DECIMAL ) + - 2 * + col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4162
SELECT DISTINCT CAST ( NULL AS REAL ) + - 2 * + col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + col1 * 28 + - col1 * col2 * - col1 FROM tab2 AS cor0
----
11458
26815
92158

query I rowsort
SELECT - 71 FROM tab1 cor0
----
-71
-71
-71

onlyif mysql # use DIV operator for integer division
query I rowsort label-4165
SELECT col2 + - col0 DIV col1 AS col1 FROM tab2
----
25
27
34

skipif mysql # not compatible
query I rowsort label-4165
SELECT col2 + - col0 / col1 AS col1 FROM tab2
----
25
27
34

query I rowsort
SELECT ALL - cor0.col2 - + col1 * - col0 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT - - col1 * - col1 + col0 AS col0 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT DISTINCT + col2 * col0 + col2 FROM tab2 cor0
----
2054
216
3040

query I rowsort
SELECT ALL - - col2 * col2 + + col0 AS col1 FROM tab2 AS cor0
----
1523
736
754

query I rowsort
SELECT DISTINCT + ( + 94 ) + + col2 FROM tab0 AS cor0
----
127
176
95

query I rowsort
SELECT ALL + col2 + col2 * - col0 - - col0 * + 55 FROM tab1 AS cor0
----
-3184
-71
57

query I rowsort
SELECT - ( 27 ) FROM tab2 AS cor0
----
-27
-27
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-4173
SELECT DISTINCT 24 DIV - col0 AS col0 FROM tab0 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-4173
SELECT DISTINCT 24 / - col0 AS col0 FROM tab0 AS cor0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col0 + - ( ( col1 ) ) col0 FROM tab1
----
136
3638
7667

query I rowsort
SELECT ( cor0.col2 ) AS col2 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT 55 + - col2 * + cor0.col2 FROM tab2 AS cor0
----
-1389
-621
-674

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 * - cor0.col2 col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + 80 * cor0.col0 FROM tab2 AS cor0
----
560
6240
6320

query I rowsort
SELECT DISTINCT - 68 + + col1 AS col1 FROM tab0 AS cor0
----
18
23
29

query I rowsort
SELECT + + 19 * + col0 FROM tab1 AS cor0
----
1216
1520
57

query I rowsort
SELECT DISTINCT - 56 * col2 FROM tab0
----
-1848
-4592
-56

query I rowsort
SELECT ALL col0 + col0 * + ( + cor0.col0 ) AS col2 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT + cor0.col1 + col0 * ( 52 ) * - col1 AS col0 FROM tab0 AS cor0
----
-107242
-176443
-421057

query I rowsort
SELECT ALL + ( - col0 ) + - col0 AS col1 FROM tab0 cor0
----
-178
-48
-70

query I rowsort
SELECT 19 * col2 FROM tab2 AS cor0
----
494
513
722

query I rowsort
SELECT ALL - 51 FROM tab2 cor0
----
-51
-51
-51

onlyif mysql # use DIV operator for integer division
query I rowsort label-4187
SELECT DISTINCT col1 DIV + col2 AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-4187
SELECT DISTINCT col1 / + col2 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT col2 * col1 - - 5 AS col1 FROM tab0 AS cor0
----
102
2843
7467

query I rowsort
SELECT DISTINCT col1 + - 30 * col2 * - col0 + + col1 * col1 AS col0 FROM tab1 AS cor0
----
109550
230582
5562

query I rowsort
SELECT ALL + 50 + - 81 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to f4b05206ee2fc0cf8007d9c3514885fa

onlyif mysql # use DIV operator for integer division
query I rowsort label-4191
SELECT col1 DIV ( + col1 ) + + cor0.col1 + cor0.col2 AS col2 FROM tab0 AS cor0
----
120
174
99

skipif mysql # not compatible
query I rowsort label-4191
SELECT col1 / ( + col1 ) + + cor0.col1 + cor0.col2 AS col2 FROM tab0 AS cor0
----
120
174
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-4192
SELECT DISTINCT - + col2 DIV ( cor0.col2 ) - col2 FROM tab1 AS cor0
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-4192
SELECT DISTINCT - + col2 / ( cor0.col2 ) - col2 FROM tab1 AS cor0
----
-55
-58
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4193
SELECT DISTINCT - 74 DIV - col1 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-4193
SELECT DISTINCT - 74 / - col1 FROM tab1
----
2
5
7

query I rowsort
SELECT col2 + + tab1.col1 FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT ( - col0 + - ( + col1 ) ) * - col1 FROM tab2
----
1178
1632
8083

query I rowsort
SELECT - + col0 * col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT + 32 FROM tab0 AS cor0
----
32

query I rowsort
SELECT 95 + 82 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to c22e7014d7b3bdb046013086e48ff1f6

query I rowsort
SELECT DISTINCT - col0 - col2 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

onlyif mysql # use DIV operator for integer division
query I rowsort label-4200
SELECT ALL + + col0 DIV - col2 AS col1 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-4200
SELECT ALL + + col0 / - col2 AS col1 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT DISTINCT + 24 AS col1 FROM tab0 AS cor0
----
24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 22 col1 FROM tab1 AS cor0
----
-22
-22
-22

query I rowsort
SELECT col2 * - cor0.col2 * + ( col2 ) AS col1 FROM tab2 AS cor0
----
-17576
-19683
-54872

query I rowsort
SELECT col0 + col0 * tab0.col2 * 9 FROM tab0
----
350
65771
7152

query I rowsort
SELECT - 49 + col2 FROM tab1
----
47
5
8

query I rowsort
SELECT ALL - + 59 * col0 AS col2 FROM tab0 AS cor0
----
-1416
-2065
-5251

query I rowsort
SELECT ALL - 42 AS col1 FROM tab0 cor0
----
-42
-42
-42

query I rowsort
SELECT + col0 + col1 * + ( col0 ) + + col2 AS col1 FROM tab0 AS cor0
----
2121
3431
8270

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col0 + + 4 col2 FROM tab1 AS cor0
----
-1036
-636
-74

query I rowsort
SELECT DISTINCT 86 + + col0 * - 12 AS col0 FROM tab2 AS cor0
----
-850
-862
2

query I rowsort
SELECT - 19 * col1 FROM tab2 AS cor0
----
-1121
-323
-589

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0 cor0, tab2 AS cor1, tab0, tab0 AS cor2
----
3645 values hashing to 38896d3a4bd953cc78f93d73ae064cbd

query I rowsort
SELECT - 40 FROM tab2
----
-40
-40
-40

query I rowsort
SELECT + cor0.col1 AS col0 FROM tab1, tab2 cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT ALL - 19 * + col2 + cor0.col2 * 0 FROM tab2 AS cor0
----
-494
-513
-722

query I rowsort
SELECT - - ( 19 ) FROM tab2 AS cor0
----
19
19
19

query I rowsort
SELECT - + col1 + 3 FROM tab0 cor0
----
-83
-88
-94

query I rowsort
SELECT - ( - 99 ) + - cor0.col1 + - 66 * col2 AS col2 FROM tab2 AS cor0
----
-1676
-1714
-2426

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col0 col0 FROM tab2 cor0
----
7
78
79

query I rowsort
SELECT DISTINCT col1 + + col0 * + col0 FROM tab1 cor0
----
35
4106
6413

query I rowsort
SELECT DISTINCT + 91 AS col0 FROM tab0 AS cor0
----
91

query I rowsort
SELECT col0 + 14 + + col2 FROM tab0 AS cor0
----
185
50
71

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab1, tab1 AS cor2
----
3645 values hashing to 76903cfa3a27727fd541d9dcdf362a4c

query I rowsort
SELECT ALL + 2 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4225
SELECT - CAST( col0 AS SIGNED ) - col0 * col2 FROM tab1
----
-165
-3712
-7760

skipif mysql # not compatible
query I rowsort label-4225
SELECT - CAST ( col0 AS INTEGER ) - col0 * col2 FROM tab1
----
-165
-3712
-7760

query I rowsort
SELECT DISTINCT 51 * - tab1.col2 + col1 + + ( + 63 ) AS col0 FROM tab1
----
-2665
-2834
-4820

query I rowsort
SELECT ALL + + 26 FROM tab1, tab2, tab0 cor0
----
27 values hashing to ede8226bb7e602e221f9d98345b4da37

query I rowsort
SELECT DISTINCT 3 + cor0.col1 FROM tab2 AS cor0
----
20
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-4229
SELECT - + cor0.col2 * + col1 + col0 DIV - CAST( + col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-132
-2838
-7463

skipif mysql # not compatible
query I rowsort label-4229
SELECT - + cor0.col2 * + col1 + col0 / - CAST ( + col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-132
-2838
-7463

query I rowsort
SELECT + 48 + 9 FROM tab2 AS cor0
----
57
57
57

query I rowsort
SELECT DISTINCT - + 13 + + 0 AS col0 FROM tab0 AS cor0
----
-13

onlyif mysql # use DIV operator for integer division
query I rowsort label-4232
SELECT ALL 54 DIV + col0 FROM tab2
----
0
0
7

skipif mysql # not compatible
query I rowsort label-4232
SELECT ALL 54 / + col0 FROM tab2
----
0
0
7

query I rowsort
SELECT DISTINCT + 83 AS col2 FROM tab1, tab0 cor0
----
83

query I rowsort
SELECT + col2 + col1 + 67 FROM tab0 AS cor0
----
165
186
240

query I rowsort
SELECT ALL 39 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT ( col0 ) * col1 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT ALL 2 * - col1 AS col1 FROM tab0
----
-172
-182
-194

query I rowsort
SELECT col2 * tab0.col0 * - col2 AS col1 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT ALL col2 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ( col2 ) * ( col0 + - col2 ) FROM tab2
----
-540
1352
1558

query I rowsort
SELECT + - cor0.col0 * + cor0.col0 + col1 FROM tab2 AS cor0
----
-18
-6025
-6224

onlyif mysql # use DIV operator for integer division
query I rowsort label-4242
SELECT + col0 DIV col0 + + ( 36 ) FROM tab1 AS cor0
----
37
37
37

skipif mysql # not compatible
query I rowsort label-4242
SELECT + col0 / col0 + + ( 36 ) FROM tab1 AS cor0
----
37
37
37

query I rowsort
SELECT ALL col1 + col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT col2 + + cor0.col2 * col2 FROM tab1 AS cor0
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-4245
SELECT ALL col1 DIV - col2 + 55 AS col1 FROM tab1
----
55
55
55

skipif mysql # not compatible
query I rowsort label-4245
SELECT ALL col1 / - col2 + 55 AS col1 FROM tab1
----
55
55
55

query I rowsort
SELECT DISTINCT + col0 + 52 FROM tab0
----
141
76
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-4247
SELECT + col2 DIV - ( 8 ) FROM tab1
----
-12
-6
-7

skipif mysql # not compatible
query I rowsort label-4247
SELECT + col2 / - ( 8 ) FROM tab1
----
-12
-6
-7

query I rowsort
SELECT - tab2.col1 + col0 * - col1 AS col1 FROM tab2
----
-1360
-248
-4661

query I rowsort
SELECT col0 + + col0 + + 84 AS col1 FROM tab1
----
212
244
90

query I rowsort
SELECT + 38 + cor0.col2 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 4e0294e26cea364043a62097491b45a2

query I rowsort
SELECT DISTINCT - - col1 * 7 AS col1 FROM tab2 AS cor0
----
119
217
413

onlyif mysql # use DIV operator for integer division
query I rowsort label-4252
SELECT ALL col2 + + 72 DIV cor0.col0 col1 FROM tab1 AS cor0
----
58
78
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4252
SELECT ALL col2 + + 72 / cor0.col0 col1 FROM tab1 AS cor0
----
58
78
96

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 col1 * cor0.col2 col2 FROM tab1 cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 col0 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT + col0 * col2 * cor0.col1 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT - 2 + col1 FROM tab1 AS cor0
----
11
24
8

query I rowsort
SELECT - ( - 57 ) * - cor0.col0 + col1 AS col1 FROM tab1 AS cor0
----
-145
-3638
-4547

query I rowsort
SELECT + - 13 * col1 - - col1 FROM tab1 AS cor0
----
-120
-156
-312

query I rowsort
SELECT ALL + 10 * ( - col2 * col2 ) + col1 * + col2 + col2 FROM tab2 AS cor0
----
-13756
-5200
-6426

query I rowsort
SELECT + 67 * cor0.col0 + col2 FROM tab2 AS cor0
----
496
5252
5331

query I rowsort
SELECT DISTINCT + cor0.col1 + col2 * + col1 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT + - 65 AS col1 FROM tab2 cor0
----
-65
-65
-65

query I rowsort
SELECT DISTINCT - ( cor0.col1 ) + col0 * col1 * 84 FROM tab1 AS cor0
----
53750
6526
87347

query I rowsort
SELECT - - cor0.col2 + col0 AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT - ( 65 ) - - col1 FROM tab2 AS cor0
----
-34
-48
-6

query IIIIII rowsort
SELECT * FROM tab2, tab0 AS cor0 WHERE NULL IN ( cor0.col0 )
----

query I rowsort
SELECT - col1 - col2 * + col0 AS col0 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT col2 AS col2 FROM tab2 WHERE NOT NULL <= + col1 + + col0 * - col2
----

query I rowsort
SELECT DISTINCT col2 * + col1 / col1 AS col2 FROM tab1 WHERE ( col0 * col0 ) BETWEEN ( NULL ) AND col2 * col0
----

query I rowsort
SELECT + col0 * tab1.col2 * - tab1.col2 FROM tab1 WHERE NOT NULL NOT BETWEEN tab1.col0 AND col1
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4272
SELECT DISTINCT col2 + col1 DIV - tab2.col1 + col0 FROM tab2
----
103
116
33

skipif mysql # not compatible
query I rowsort label-4272
SELECT DISTINCT col2 + col1 / - tab2.col1 + col0 FROM tab2
----
103
116
33

query I rowsort
SELECT DISTINCT + col1 + - col1 + col1 FROM tab0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-4274
SELECT + col1 + + col0 DIV - col1 - col0 AS col1 FROM tab2
----
-20
-66
24

skipif mysql # not compatible
query I rowsort label-4274
SELECT + col1 + + col0 / - col1 - col0 AS col1 FROM tab2
----
-20
-66
24

query I rowsort
SELECT ALL col0 * - tab0.col2 AS col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ALL - col2 + tab0.col2 + tab0.col2 FROM tab0
----
1
33
82

query I rowsort
SELECT tab1.col0 * - col1 AS col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT + col1 * col2 + - col2 FROM tab0
----
2805
7380
96

query I rowsort
SELECT - col0 * col2 + col2 AS col0 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT - + cor0.col0 * + col2 + col1 AS col0 FROM tab2 AS cor0
----
-158
-1969
-2985

onlyif mysql # use DIV operator for integer division
query I rowsort label-4281
SELECT - + col1 + col2 DIV + col2 - - col0 * cor0.col0 FROM tab1 AS cor0
----
-16
4087
6388

skipif mysql # not compatible
query I rowsort label-4281
SELECT - + col1 + col2 / + col2 - - col0 * cor0.col0 FROM tab1 AS cor0
----
-16
4087
6388

query I rowsort
SELECT + col2 + col1 AS col1 FROM tab2 cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col1 - + col0 col2 FROM tab1
----
-1120
-704
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( cor0.col0 ) col2 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT col1 - + col1 * col1 FROM tab2 AS cor0
----
-272
-3422
-930

query I rowsort
SELECT - col1 * col1 + col0 FROM tab1
----
-36
-673
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4287
SELECT + col2 DIV ( + col1 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4287
SELECT + col2 / ( + col1 ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col0 * + cor0.col0 * - col0 FROM tab1 AS cor0
----
262144
27
512000

query I rowsort
SELECT + col2 * col1 + + cor0.col2 * + col1 FROM tab2 cor0
----
1292
1674
3068

query I rowsort
SELECT DISTINCT + col2 * col0 + 83 FROM tab1 AS cor0
----
245
3731
7763

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4291
SELECT DISTINCT + col1 * CAST( NULL AS SIGNED ) - cor0.col0 * - cor0.col1 AS col0 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4291
SELECT DISTINCT + col1 * CAST ( NULL AS INTEGER ) - cor0.col0 * - cor0.col1 AS col0 FROM tab0 cor0
----
NULL

query I rowsort
SELECT - col1 + ( col0 * col0 ) FROM tab2 AS cor0
----
18
6025
6224

query I rowsort
SELECT ALL - - col0 + - col2 * col1 AS col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT + col0 - col1 AS col1 FROM tab2 AS cor0
----
-24
19
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4295
SELECT col1 * CAST( NULL AS SIGNED ) + - col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4295
SELECT col1 * CAST ( NULL AS INTEGER ) + - col0 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 * - ( col2 ) * + col1 + - cor0.col2 FROM tab2 AS cor0
----
-11020
-25974
-90532

onlyif mysql # use DIV operator for integer division
query I rowsort label-4297
SELECT ALL + - col2 * col2 - - col2 DIV col2 AS col1 FROM tab0 AS cor0
----
-1088
-6723
0

skipif mysql # not compatible
query I rowsort label-4297
SELECT ALL + - col2 * col2 - - col2 / col2 AS col1 FROM tab0 AS cor0
----
-1088
-6723
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4298
SELECT DISTINCT + col1 * CAST( - col1 AS SIGNED ) FROM tab2 AS cor0
----
-289
-3481
-961

skipif mysql # not compatible
query I rowsort label-4298
SELECT DISTINCT + col1 * CAST ( - col1 AS INTEGER ) FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT + 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-4300
SELECT DISTINCT col0 + + CAST( NULL AS SIGNED ) * - ( - cor0.col2 ) FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4300
SELECT DISTINCT col0 + + CAST ( NULL AS INTEGER ) * - ( - cor0.col2 ) FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL col1 * col2 + + col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT DISTINCT col0 FROM tab2 WHERE ( col1 ) NOT BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4303
SELECT col1 + col2 DIV - col1 + - tab1.col1 DIV + col1 AS col0 FROM tab1
----
23
4
5

skipif mysql # not compatible
query I rowsort label-4303
SELECT col1 + col2 / - col1 + - tab1.col1 / + col1 AS col0 FROM tab1
----
23
4
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-4304
SELECT + col0 DIV - col1 AS col2 FROM tab1
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-4304
SELECT + col0 / - col1 AS col2 FROM tab1
----
-6
-6
0

query I rowsort
SELECT col2 * + col0 + - col0 + tab0.col1 * - col1 FROM tab0
----
-1072
-6628
-9409

query I rowsort
SELECT col1 * col2 * col1 AS col1 FROM tab1 WHERE NULL IN ( - col2 / - col0 - col0 * col2 )
----

query I rowsort
SELECT - tab0.col2 * col0 + col1 + - col0 AS col0 FROM tab0
----
-7296
-730
27

query I rowsort
SELECT - col2 FROM tab2 WHERE NOT ( NULL ) NOT IN ( col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4309
SELECT ALL + col1 DIV - col1 + + col2 * col2 * col1 FROM tab2
----
22598
24547
39883

skipif mysql # not compatible
query I rowsort label-4309
SELECT ALL + col1 / - col1 + + col2 * col2 * col1 FROM tab2
----
22598
24547
39883

query I rowsort
SELECT tab2.col0 * tab2.col2 + + tab2.col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT + ( + col0 ) * col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + ( cor0.col1 ) + col2 col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - + col2 * col2 + - 50 FROM tab1 AS cor0
----
-2966
-3299
-9266

query I rowsort
SELECT col0 - col0 * col1 * - col2 FROM tab0
----
3430
664207
68136

query I rowsort
SELECT tab2.col1 + col0 AS col2 FROM tab2
----
137
38
96

query I rowsort
SELECT - col1 + + col0 * col0 AS col0 FROM tab1
----
-17
4086
6387

query I rowsort
SELECT DISTINCT + - col2 + col1 * + ( col2 ) FROM tab0 cor0
----
2805
7380
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4318
SELECT ALL + col1 DIV col1 - - col1 AS col2 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-4318
SELECT ALL + col1 / col1 - - col1 AS col2 FROM tab0
----
87
92
98

query I rowsort
SELECT DISTINCT - col0 + + col1 * ( tab2.col0 ) AS col2 FROM tab2
----
1264
210
4524

query I rowsort
SELECT col0 + ( - col0 * + col0 ) AS col1 FROM tab0
----
-1190
-552
-7832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 9 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

query I rowsort
SELECT ALL - + col1 + - col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT + col2 + 67 FROM tab2 AS cor0
----
105
93
94

query I rowsort
SELECT DISTINCT - + cor0.col0 - col2 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT - + col1 * - ( col1 + col2 ) FROM tab0 AS cor0
----
10234
15743
9506

query I rowsort
SELECT ALL - + 27 * + col0 AS col0 FROM tab2 AS cor0
----
-189
-2106
-2133

query I rowsort
SELECT DISTINCT - - col2 + cor0.col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT cor0.col0 * col2 + - col0 AS col0 FROM tab0 AS cor0
----
0
7209
768

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4329
SELECT - CAST( NULL AS SIGNED ) / 92 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4329
SELECT - CAST ( NULL AS INTEGER ) / 92 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - 43 * + col0 FROM tab0 AS cor0
----
1032
1505
3827

query I rowsort
SELECT ALL - 92 * 12 FROM tab1 AS cor0
----
-1104
-1104
-1104

query I rowsort
SELECT + - 65 + col2 FROM tab2 AS cor0
----
-27
-38
-39

query I rowsort
SELECT - ( col0 ) + col0 AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4334
SELECT CAST( + col1 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-4334
SELECT 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 + + col0 * + col2 col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + cor0.col0 + col1 * + col2 * col0 + col2 FROM tab1 AS cor0
----
100016
36601
4269

query I rowsort
SELECT col0 + + col0 * 81 FROM tab2 AS cor0
----
574
6396
6478

query I rowsort
SELECT ALL + - 12 - col1 AS col0 FROM tab2 AS cor0
----
-29
-43
-71

query I rowsort
SELECT ALL + tab1.col1 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT + + col0 * col1 - + ( col2 ) AS col1 FROM tab1 cor0
----
24
583
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-4341
SELECT DISTINCT + - col2 DIV + col0 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-4341
SELECT DISTINCT + - col2 / + col0 FROM tab1 AS cor0
----
-1
-18
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * cor0.col0 col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL - - 48 AS col2 FROM tab2 AS cor0
----
48
48
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-4344
SELECT - - col2 DIV col1 + - ( 23 ) AS col1 FROM tab2 AS cor0
----
-21
-23
-23

skipif mysql # not compatible
query I rowsort label-4344
SELECT - - col2 / col1 + - ( 23 ) AS col1 FROM tab2 AS cor0
----
-21
-23
-23

query I rowsort
SELECT DISTINCT - col1 + cor0.col2 * + col2 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT - col0 + col2 * - cor0.col2 FROM tab1 AS cor0
----
-2919
-3313
-9296

query I rowsort
SELECT DISTINCT - - 22 * + col1 AS col2 FROM tab2 cor0
----
1298
374
682

query I rowsort
SELECT col0 + 15 AS col2 FROM tab0 AS cor0
----
104
39
50

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col0 + col0 col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT col2 * col1 + - 92 FROM tab1 AS cor0
----
1156
1312
478

query I rowsort
SELECT ALL col1 + + col2 + + col0 AS col2 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT - col0 - + col2 AS col1 FROM tab0 AS cor0
----
-171
-36
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4353
SELECT DISTINCT - col0 + + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4353
SELECT DISTINCT - col0 + + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL col2 + tab1.col0 * 55 FROM tab1
----
219
3577
4496

query I rowsort
SELECT ALL - tab2.col1 + col0 AS col2 FROM tab2
----
-24
19
62

query I rowsort
SELECT + 69 + col2 AS col2 FROM tab2
----
107
95
96

query I rowsort
SELECT - - cor0.col1 * - col1 + - col1 * col2 FROM tab2 AS cor0
----
-1798
-5015
-935

query I rowsort
SELECT - cor0.col2 - - ( - col2 ) AS col2 FROM tab1 AS cor0
----
-108
-114
-192

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4359
SELECT - col1 * - col1 + + col1 * col1 + CAST( 84 AS SIGNED ) FROM tab2 AS cor0
----
2006
662
7046

skipif mysql # not compatible
query I rowsort label-4359
SELECT - col1 * - col1 + + col1 * col1 + CAST ( 84 AS INTEGER ) FROM tab2 AS cor0
----
2006
662
7046

query I rowsort
SELECT ALL + cor0.col2 * 6 * - 19 FROM tab1 AS cor0
----
-10944
-6156
-6498

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - col1 col1 FROM tab2
----
-55
-58
-85

query I rowsort
SELECT DISTINCT 20 + col0 FROM tab1
----
100
23
84

query I rowsort
SELECT - col2 + - col2 AS col2 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT - 14 + 1 FROM tab1 AS cor0
----
-13
-13
-13

query I rowsort
SELECT 49 FROM tab1, tab0 cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

query I rowsort
SELECT + - ( + cor0.col0 ) FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 25 * - col0 col2 FROM tab1 AS cor0
----
1600
2000
75

query I rowsort
SELECT ALL + tab0.col2 * + col2 * + col2 FROM tab0
----
1
35937
551368

onlyif mysql # use DIV operator for integer division
query I rowsort label-4369
SELECT 64 DIV col1 FROM tab2
----
1
2
3

skipif mysql # not compatible
query I rowsort label-4369
SELECT 64 / col1 FROM tab2
----
1
2
3

query I rowsort
SELECT DISTINCT tab0.col1 * tab0.col1 AS col0 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT - tab0.col1 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT ( col2 ) AS col0 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT + 13 FROM tab0 AS cor0
----
13

query I rowsort
SELECT 41 AS col2 FROM tab1 AS cor0
----
41
41
41

query I rowsort
SELECT 22 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT - + 88 + col1 * col1 AS col0 FROM tab0 AS cor0
----
7308
8193
9321

query I rowsort
SELECT DISTINCT - + col0 * - col1 FROM tab2 cor0
----
1343
217
4602

query I rowsort
SELECT col0 - - col0 * col0 AS col0 FROM tab2
----
56
6162
6320

query I rowsort
SELECT DISTINCT - col2 - - col1 AS col1 FROM tab2
----
-21
33
4

query I rowsort
SELECT - col1 - 27 FROM tab2
----
-44
-58
-86

query I rowsort
SELECT + col0 * col1 + + 81 + col0 FROM tab2 AS cor0
----
1503
305
4761

query I rowsort
SELECT DISTINCT + - col1 * + col2 * - col1 + + cor0.col1 + + col0 AS col1 FROM tab1 AS cor0
----
16317
36533
5774

query I rowsort
SELECT ALL + ( + col2 ) * + 60 + col1 FROM tab0 AS cor0
----
157
2066
5011

query I rowsort
SELECT + tab0.col1 * col2 + + ( - 79 ) * - col1 FROM tab0
----
14651
7760
9632

query I rowsort
SELECT + 96 * col2 + 5 AS col1 FROM tab0 AS cor0
----
101
3173
7877

query I rowsort
SELECT + cor0.col2 + + col2 + col1 * col1 * + col1 AS col1 FROM tab0 AS cor0
----
636122
753735
912675

query I rowsort
SELECT DISTINCT + cor0.col0 - - col0 * col1 AS col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL - + 11 * - col2 + ( 90 ) * col2 * - cor0.col1 FROM tab2 AS cor0
----
-137774
-57722
-75033

query I rowsort
SELECT ALL + cor0.col2 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4390
SELECT ALL - 6 DIV col2 + col2 * col2 AS col0 FROM tab0 AS cor0
----
-5
1089
6724

skipif mysql # not compatible
query I rowsort label-4390
SELECT ALL - 6 / col2 + col2 * col2 AS col0 FROM tab0 AS cor0
----
-5
1089
6724

query I rowsort
SELECT col1 - col0 AS col1 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT - col2 * + ( col0 ) + - col1 AS col2 FROM tab2 AS cor0
----
-2087
-220
-3019

query I rowsort
SELECT tab2.col1 * - cor0.col0 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 737dbb26f65dd374aa3c71dabdd3903c

query I rowsort
SELECT DISTINCT 47 AS col1 FROM tab0, tab1 AS cor0, tab2 cor1, tab1, tab1 AS cor2
----
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 21 col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4396
SELECT cor0.col1 * - CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4396
SELECT cor0.col1 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col1 + - col2 * + col2 FROM tab2 AS cor0
----
-1427
-617
-698

query I rowsort
SELECT ALL + ( + 66 ) * col0 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
1617
2311
5956

query I rowsort
SELECT DISTINCT + - col2 + + col2 * col1 AS col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT ALL - + 73 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
-6278
-6643
-7081

query I rowsort
SELECT ALL - - 8 * + col1 FROM tab0 cor0
----
688
728
776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 35 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT col0 * + ( col1 ) - - col1 AS col2 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT ALL - cor0.col0 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT DISTINCT + col2 * + 17 FROM tab1
----
1632
918
969

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4406
SELECT - - CAST( ( cor0.col2 ) AS SIGNED ) * col2 * 94 FROM tab1 AS cor0
----
274104
305406
866304

skipif mysql # not compatible
query I rowsort label-4406
SELECT - - CAST ( ( cor0.col2 ) AS INTEGER ) * col2 * 94 FROM tab1 AS cor0
----
274104
305406
866304

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0, tab1 cor1, tab0 AS cor2
----
972 values hashing to 95920403df268a272c4e933cd0bbe0be

query I rowsort
SELECT - cor0.col0 + cor0.col1 FROM tab0 AS cor0
----
2
62
62

query I rowsort
SELECT ALL 80 + + 89 * - col0 FROM tab1 AS cor0
----
-187
-5616
-7040

query I rowsort
SELECT ALL + - col0 * + 27 AS col0 FROM tab1 AS cor0
----
-1728
-2160
-81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4411
SELECT ALL - + CAST( NULL AS DECIMAL ) + - col0 * - col1 * - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4411
SELECT ALL - + CAST ( NULL AS REAL ) + - col0 * - col1 * - col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 * col2 col0 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4413
SELECT DISTINCT + CAST( NULL AS SIGNED ) * cor0.col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4413
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * cor0.col2 FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4414
SELECT ALL CAST( col0 AS SIGNED ) * col0 AS col2 FROM tab0 cor0
----
1225
576
7921

skipif mysql # not compatible
query I rowsort label-4414
SELECT ALL CAST ( col0 AS INTEGER ) * col0 AS col2 FROM tab0 cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT - 8 AS col2 FROM tab2 AS cor0
----
-8

query I rowsort
SELECT + + 83 * - cor0.col1 FROM tab1 AS cor0
----
-1079
-2158
-830

query I rowsort
SELECT ALL + 84 FROM tab0
----
84
84
84

query I rowsort
SELECT 30 * - col1 * col0 FROM tab2 AS cor0
----
-138060
-40290
-6510

query I rowsort
SELECT ALL + 50 AS col1 FROM tab2
----
50
50
50

query I rowsort
SELECT 94 + tab0.col2 FROM tab0
----
127
176
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4421
SELECT ALL CAST( NULL AS SIGNED ) * + ( - tab2.col2 ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4421
SELECT ALL CAST ( NULL AS INTEGER ) * + ( - tab2.col2 ) AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ( tab1.col0 ) + + col1 AS col2 FROM tab1
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col1 col0 FROM tab1
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-4424
SELECT ALL - 72 DIV col1 FROM tab2
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-4424
SELECT ALL - 72 / col1 FROM tab2
----
-1
-2
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 1 * col1 + - 59 col0 FROM tab1
----
-33
-46
-49

query I rowsort
SELECT DISTINCT col1 + 11 * col0 AS col1 FROM tab0 AS cor0
----
1070
350
482

query I rowsort
SELECT + col1 * - col0 + - col2 * col2 FROM tab0 AS cor0
----
-14823
-3153
-3396

query I rowsort
SELECT ALL + cor0.col0 * - col2 + col0 FROM tab0 AS cor0
----
-7209
-768
0

query I rowsort
SELECT DISTINCT col1 * + ( - col2 ) FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + cor0.col2 * col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT + cor0.col2 * ( - col2 * cor0.col2 ) + + ( col0 ) + + col1 AS col2 FROM tab0 AS cor0
----
-35827
-551188
131

onlyif mysql # use DIV operator for integer division
query I rowsort label-4432
SELECT ALL - col0 DIV + col1 + 40 FROM tab1
----
34
34
40

skipif mysql # not compatible
query I rowsort label-4432
SELECT ALL - col0 / + col1 + 40 FROM tab1
----
34
34
40

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4433
SELECT DISTINCT CAST( NULL AS SIGNED ) FROM tab0, tab1 AS cor0, tab2 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-4433
SELECT DISTINCT CAST ( NULL AS INTEGER ) FROM tab0, tab1 AS cor0, tab2 AS cor1
----
NULL

query I rowsort
SELECT DISTINCT 0 + - col2 AS col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + col0 * 12 * - col1 FROM tab1
----
-12480
-7680
-936

query I rowsort
SELECT DISTINCT col2 + + col1 * col1 AS col0 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT + - col1 + 87 + - col0 * col1 AS col0 FROM tab0 AS cor0
----
-2063
-3405
-8103

onlyif mysql # use DIV operator for integer division
query I rowsort label-4438
SELECT - col1 DIV 76 + col2 * col0 AS col0 FROM tab1 AS cor0
----
162
3648
7680

skipif mysql # not compatible
query I rowsort label-4438
SELECT - col1 / 76 + col2 * col0 AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT + - cor0.col2 + ( col0 ) FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT + - cor0.col0 + col1 + 70 AS col0 FROM tab1 AS cor0
----
16
3
93

query I rowsort
SELECT - col1 + + 37 FROM tab0 AS cor0
----
-49
-54
-60

onlyif mysql # use DIV operator for integer division
query I rowsort label-4442
SELECT - col1 * col1 DIV - 11 AS col2 FROM tab0 AS cor0
----
672
752
855

skipif mysql # not compatible
query I rowsort label-4442
SELECT - col1 * col1 / - 11 AS col2 FROM tab0 AS cor0
----
672
752
855

query I rowsort
SELECT DISTINCT + col0 * - 7 FROM tab1 AS cor0
----
-21
-448
-560

query I rowsort
SELECT DISTINCT + col2 + col2 * - 62 + col0 * - col0 * + 96 FROM tab0 AS cor0
----
-117661
-57309
-765418

onlyif mysql # use DIV operator for integer division
query I rowsort label-4445
SELECT - + 97 DIV col1 + + col2 AS col2 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-4445
SELECT - + 97 / col1 + + col2 AS col2 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT + 81 + + cor0.col2 + + col0 FROM tab2 AS cor0
----
115
185
198

query I rowsort
SELECT + col1 * 90 AS col0 FROM tab0
----
7740
8190
8730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + tab1.col0 col2 FROM tab1
----
29
74
93

query I rowsort
SELECT DISTINCT col0 + + 87 FROM tab2
----
165
166
94

query I rowsort
SELECT 17 + - tab0.col1 + + col1 * + ( + col1 ) FROM tab0
----
7327
8207
9329

query I rowsort
SELECT ALL + col2 + 1 FROM tab1
----
55
58
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 45 + ( - tab0.col2 ) col0 FROM tab0
----
-127
-46
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4453
SELECT + 26 + col2 + - col1 DIV tab0.col1 FROM tab0
----
107
26
58

skipif mysql # not compatible
query I rowsort label-4453
SELECT + 26 + col2 + - col1 / tab0.col1 FROM tab0
----
107
26
58

query I rowsort
SELECT ALL col2 * col1 * - col1 FROM tab0
----
-244068
-679042
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + col1 col2 FROM tab2
----
1343
217
4602

skipif mysql # not compatible
query I rowsort
SELECT tab0.col0 + - col0 * - CAST ( + col1 AS REAL ) AS col2 FROM tab0
----
2088
3430
8188

onlyif mysql # use DIV operator for integer division
query I rowsort label-4457
SELECT ALL + - col1 DIV col0 AS col2 FROM tab0 cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-4457
SELECT ALL + - col1 / col0 AS col2 FROM tab0 cor0
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * + col2 + col2 * - col1 col2 FROM tab0 AS cor0
----
-14924
-194
-5676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col1 + ( + 46 ) col2 FROM tab1 AS cor0
----
1086
124
686

query I rowsort
SELECT + col1 * col2 + 14 AS col1 FROM tab0 AS cor0
----
111
2852
7476

onlyif mysql # use DIV operator for integer division
query I rowsort label-4461
SELECT ALL + col0 DIV + col1 + 40 AS col0 FROM tab0 AS cor0
----
40
40
40

skipif mysql # not compatible
query I rowsort label-4461
SELECT ALL + col0 / + col1 + 40 AS col0 FROM tab0 AS cor0
----
40
40
40

query I rowsort
SELECT ALL ( col0 ) + ( + col0 ) * col0 * 14 AS col0 FROM tab0 AS cor0
----
110983
17185
8088

onlyif mysql # use DIV operator for integer division
query I rowsort label-4463
SELECT DISTINCT 45 + - col2 + ( 35 ) DIV - col0 AS col2 FROM tab0 AS cor0
----
-37
11
43

skipif mysql # not compatible
query I rowsort label-4463
SELECT DISTINCT 45 + - col2 + ( 35 ) / - col0 AS col2 FROM tab0 AS cor0
----
-37
11
43

query I rowsort
SELECT - - cor0.col1 * - col0 AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + col1 * col2 * + col0 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT + 97 + col1 * col0 AS col1 FROM tab0 AS cor0
----
2161
3492
8196

query I rowsort
SELECT DISTINCT + + col0 + - col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT col2 + - col1 * + col0 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT - 12 FROM tab2, tab1 AS cor0
----
9 values hashing to e698dd57d3aac30af14ce35da434bb45

onlyif mysql # use DIV operator for integer division
query I rowsort label-4470
SELECT DISTINCT col2 DIV tab1.col0 AS col2 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-4470
SELECT DISTINCT col2 / tab1.col0 AS col2 FROM tab1
----
0
1
18

query I rowsort
SELECT DISTINCT + col1 + ( + cor0.col1 ) FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL + col0 * + cor0.col2 * + 46 + - col0 - + col0 FROM tab1 AS cor0
----
167680
353120
7446

query I rowsort
SELECT ALL + - col1 * + ( col0 ) AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT ALL 33 AS col2 FROM tab0, tab0 AS cor0, tab2, tab2 cor1
----
81 values hashing to 5b9acd68f8a2078394b8b32da4e0a18f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4475
SELECT DISTINCT - + col0 - - CAST( col2 AS SIGNED ) FROM tab2 cor0
----
-41
-52
20

skipif mysql # not compatible
query I rowsort label-4475
SELECT DISTINCT - + col0 - - CAST ( col2 AS INTEGER ) FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT ALL - + col0 * + col1 * + 28 + + col0 * - col1 FROM tab2 AS cor0
----
-133458
-38947
-6293

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col2 * + col0 col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT col1 + 48 * cor0.col0 FROM tab0 AS cor0
----
1238
1777
4363

query I rowsort
SELECT + cor0.col0 + + 61 FROM tab2, tab2 AS cor0, tab1 cor1, tab1, tab1 AS cor2
----
243 values hashing to 743f986d80b0bbfb1ce4d1be19bee240

onlyif mysql # use DIV operator for integer division
query I rowsort label-4480
SELECT ALL - - 85 * - col1 + col2 DIV + ( + col2 ) AS col1 FROM tab0 AS cor0
----
-7309
-7734
-8244

skipif mysql # not compatible
query I rowsort label-4480
SELECT ALL - - 85 * - col1 + col2 / + ( + col2 ) AS col1 FROM tab0 AS cor0
----
-7309
-7734
-8244

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4481
SELECT - - CAST( NULL AS DECIMAL ) + col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4481
SELECT - - CAST ( NULL AS REAL ) + col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - cor0.col0 - col1 * col0 AS col1 FROM tab1 AS cor0
----
-1120
-704
-81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4483
SELECT DISTINCT + CAST( col0 AS SIGNED ) + col1 col1 FROM tab1 AS cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4483
SELECT DISTINCT + CAST ( col0 AS INTEGER ) + col1 col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL ( 42 ) + - col0 FROM tab2 AS cor0
----
-36
-37
35

query I rowsort
SELECT + + ( - 44 ) AS col1 FROM tab0 AS cor0
----
-44
-44
-44

query I rowsort
SELECT + ( cor0.col2 ) AS col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - col1 + - col1 * col2 AS col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT - 61 * col0 FROM tab1 AS cor0
----
-183
-3904
-4880

query I rowsort
SELECT ALL 26 - + col1 * + col0 FROM tab2 AS cor0
----
-1317
-191
-4576

query I rowsort
SELECT 28 + cor0.col1 * col2 FROM tab1 cor0
----
1276
1432
598

query I rowsort
SELECT - + 29 * 66 FROM tab1 AS cor0
----
-1914
-1914
-1914

query I rowsort
SELECT + 62 + col1 AS col1 FROM tab1 AS cor0
----
72
75
88

query I rowsort
SELECT DISTINCT - cor1.col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
-10
-13
-26

query I rowsort
SELECT ALL + cor0.col1 FROM tab2, tab2 AS cor0, tab0 cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

onlyif mysql # use DIV operator for integer division
query I rowsort label-4495
SELECT ALL col2 + col1 * 8 DIV - col2 FROM tab0 AS cor0
----
-775
13
74

skipif mysql # not compatible
query I rowsort label-4495
SELECT ALL col2 + col1 * 8 / - col2 FROM tab0 AS cor0
----
-775
13
74

query I rowsort
SELECT + col0 * 30 AS col0 FROM tab1 AS cor0
----
1920
2400
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4497
SELECT DISTINCT cor0.col0 DIV 72 - col0 * - col1 FROM tab0 cor0
----
2064
3395
8100

skipif mysql # not compatible
query I rowsort label-4497
SELECT DISTINCT cor0.col0 / 72 - col0 * - col1 FROM tab0 cor0
----
2064
3395
8100

query I rowsort
SELECT DISTINCT + + col1 * + cor0.col1 AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - cor0.col0 * - col1 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT col2 + + col1 AS col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL 34 + + tab1.col2 * - 16 FROM tab1
----
-1502
-830
-878

query I rowsort
SELECT - + col1 * + 79 * col0 + col2 AS col0 FROM tab0 AS cor0
----
-163023
-268204
-639739

onlyif mysql # use DIV operator for integer division
query I rowsort label-4503
SELECT + + col2 * 26 DIV col2 FROM tab1 AS cor0
----
26
26
26

skipif mysql # not compatible
query I rowsort label-4503
SELECT + + col2 * 26 / col2 FROM tab1 AS cor0
----
26
26
26

query I rowsort
SELECT - - 29 FROM tab1 AS cor0
----
29
29
29

query I rowsort
SELECT col1 * ( + col2 ) + col2 * - 79 AS col0 FROM tab1
----
-2862
-3933
-6336

query I rowsort
SELECT + col1 * + col0 * - col1 FROM tab0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL - 35 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to c12e8bdd687c9040a5600dab3b6adf5b

query I rowsort
SELECT DISTINCT + 5 - + 76 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-71

query I rowsort
SELECT DISTINCT - cor0.col1 + + 81 FROM tab0, tab1 AS cor0
----
55
68
71

query I rowsort
SELECT ALL - - 54 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT DISTINCT - cor0.col0 AS col2 FROM tab0, tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT col1 + tab2.col0 * - col2 + + tab2.col0 FROM tab2
----
-151
-1891
-2906

query I rowsort
SELECT ALL + tab1.col0 + 66 - + ( + col1 ) FROM tab1
----
120
133
43

query I rowsort
SELECT ALL + col2 + ( cor0.col0 ) FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + + cor0.col1 + col2 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - col2 * + 80 + 39 * col1 FROM tab2 cor0
----
-2377
-951
221

query I rowsort
SELECT DISTINCT col2 * 11 AS col1 FROM tab0 AS cor0
----
11
363
902

query I rowsort
SELECT - - 13 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT ALL 59 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to e29fef8cdec1ee45a71d213f16d2f1d3

query I rowsort
SELECT DISTINCT - ( col0 ) * col1 + + tab1.col1 FROM tab1
----
-1027
-52
-630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col0 * col0 ) col2 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT col0 * + 22 AS col1 FROM tab2
----
154
1716
1738

query I rowsort
SELECT 26 * - 56 FROM tab1 AS cor0
----
-1456
-1456
-1456

query I rowsort
SELECT 33 * + col0 + + col0 AS col1 FROM tab0 AS cor0
----
1190
3026
816

query I rowsort
SELECT 40 * - col2 FROM tab0
----
-1320
-3280
-40

query I rowsort
SELECT ALL 28 * + col1 FROM tab2 AS cor0
----
1652
476
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-4527
SELECT col1 DIV col1 + - col1 AS col0 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-4527
SELECT col1 / col1 + - col1 AS col0 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT DISTINCT + + col0 * col2 + col2 * + 80 * col0 AS col1 FROM tab2 cor0
----
15309
164268
243162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 - - col2 col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + 63 AS col0 FROM tab2 AS cor0
----
63
63
63

query I rowsort
SELECT DISTINCT 39 + - col0 FROM tab1 AS cor0
----
-25
-41
36

query I rowsort
SELECT ALL cor0.col2 + + cor0.col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + cor0.col1 AS col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT 47 + cor0.col0 FROM tab2 AS cor0
----
125
126
54

query I rowsort
SELECT ALL - col1 + - col2 + ( col2 ) AS col2 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + 54 - + col0 FROM tab1 AS cor0
----
-10
-26
51

query I rowsort
SELECT - ( cor0.col2 ) + 88 FROM tab1 cor0
----
-8
31
34

query I rowsort
SELECT cor2.col2 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT ALL + col2 + col2 * col1 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL - 6 FROM tab0 cor0
----
-6
-6
-6

query I rowsort
SELECT ALL 35 FROM tab1 AS cor0
----
35
35
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-4542
SELECT DISTINCT + col1 DIV + col0 FROM tab2 AS cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-4542
SELECT DISTINCT + col1 / + col0 FROM tab2 AS cor0
----
0
4

query I rowsort
SELECT DISTINCT - + ( + col1 ) AS col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - ( - col0 ) + - col0 * - 68 AS col1 FROM tab0 AS cor0
----
1656
2415
6141

query I rowsort
SELECT ALL cor0.col0 + - ( col1 ) AS col1 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT ALL + col0 * col0 * + col0 + + col0 * ( ( col1 ) ) AS col1 FROM tab0 AS cor0
----
15888
46270
713068

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 + col2 - col0 * - col0 col2 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT cor0.col1 * + col1 + col1 * + col2 AS col0 FROM tab2 AS cor0
----
1798
5015
935

query I rowsort
SELECT DISTINCT - col0 * + ( - col0 * col1 ) + col1 AS col1 FROM tab2 AS cor0
----
106114
1550
359015

query I rowsort
SELECT DISTINCT + 50 * + 93 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
4650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col1 * col1 col2 FROM tab2
----
3559
368
968

query I rowsort
SELECT tab2.col2 + + col2 * tab2.col1 FROM tab2
----
1560
684
864

query I rowsort
SELECT - ( + col1 ) + col2 AS col2 FROM tab1
----
28
47
83

query I rowsort
SELECT 5 + + col2 AS col1 FROM tab2
----
31
32
43

query I rowsort
SELECT + 16 - + col0 * - col2 FROM tab0
----
51
7314
808

onlyif mysql # use DIV operator for integer division
query I rowsort label-4556
SELECT col0 DIV - col0 - col0 FROM tab1
----
-4
-65
-81

skipif mysql # not compatible
query I rowsort label-4556
SELECT col0 / - col0 - col0 FROM tab1
----
-4
-65
-81

query I rowsort
SELECT DISTINCT - tab0.col0 + - col0 AS col1 FROM tab0
----
-178
-48
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4558
SELECT ALL CAST( NULL AS SIGNED ) * + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4558
SELECT ALL CAST ( NULL AS INTEGER ) * + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4559
SELECT DISTINCT - + col0 DIV 1 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-4559
SELECT DISTINCT - + col0 / 1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT cor0.col1 + - 61 - - col0 * cor0.col2 FROM tab2 AS cor0
----
159
2026
2958

onlyif mysql # use DIV operator for integer division
query I rowsort label-4561
SELECT ( col2 ) DIV col2 FROM tab1 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4561
SELECT ( col2 ) / col2 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + 79 + ( + col1 ) * + ( 13 ) FROM tab1 AS cor0
----
209
248
417

query I rowsort
SELECT + 67 + col1 FROM tab0 AS cor0
----
153
158
164

query I rowsort
SELECT DISTINCT - - cor0.col0 + - col1 * - col1 AS col2 FROM tab1 cor0
----
164
249
679

query I rowsort
SELECT DISTINCT 54 * - col1 * - col1 AS col1 FROM tab2 AS cor0
----
15606
187974
51894

query I rowsort
SELECT + 76 + - col1 * + col0 FROM tab0 AS cor0
----
-1988
-3319
-8023

query I rowsort
SELECT DISTINCT + col2 * + 7 + col1 AS col1 FROM tab0 cor0
----
104
317
665

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4568
SELECT CAST( NULL AS DECIMAL ) * cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4568
SELECT CAST ( NULL AS REAL ) * cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + 61 FROM tab2 AS cor0
----
61
61
61

query I rowsort
SELECT ALL + - 7 + 94 * col1 AS col1 FROM tab0 AS cor0
----
8077
8547
9111

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4571
SELECT ALL col2 - - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4571
SELECT ALL col2 - - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * ( 20 * col2 ) + - col2 + - col1 AS col1 FROM tab0
----
-118
-134653
-21899

onlyif mysql # use DIV operator for integer division
query I rowsort label-4573
SELECT ALL + col1 + ( - col0 ) DIV + col2 col1 FROM tab0 AS cor0
----
62
86
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4573
SELECT ALL + col1 + ( - col0 ) / + col2 col1 FROM tab0 AS cor0
----
62
86
90

query I rowsort
SELECT + col2 * + ( - col1 + - col0 ) FROM tab0
----
-132
-14760
-3630

query I rowsort
SELECT tab0.col0 * 73 AS col2 FROM tab0
----
1752
2555
6497

query I rowsort
SELECT + 65 AS col0 FROM tab2
----
65
65
65

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab2 AS cor2
----
3645 values hashing to b34c9987c389223e07378cde8a36e94f

onlyif mysql # use DIV operator for integer division
query I rowsort label-4578
SELECT - - col0 + + col2 DIV col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-4578
SELECT - - col0 + + col2 / col1 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4579
SELECT + col2 DIV ( - col2 ) AS col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4579
SELECT + col2 / ( - col2 ) AS col1 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT ALL + 76 + + tab1.col2 FROM tab1
----
130
133
172

query I rowsort
SELECT DISTINCT + col0 + col1 * + col1 + + col1 FROM tab2 AS cor0
----
3618
385
999

query I rowsort
SELECT ALL + col2 * 85 FROM tab2 AS cor0
----
2210
2295
3230

query I rowsort
SELECT - 81 AS col1 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to d0bfe8494f52235d9fcafb5ac5de3f81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4584
SELECT DISTINCT + + CAST( - 3 AS SIGNED ) FROM tab0 AS cor0
----
-3

skipif mysql # not compatible
query I rowsort label-4584
SELECT DISTINCT + + CAST ( - 3 AS INTEGER ) FROM tab0 AS cor0
----
-3

query I rowsort
SELECT ALL - col1 * - ( + 30 ) FROM tab2
----
1770
510
930

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4586
SELECT CAST( NULL AS DECIMAL ) * - 64 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4586
SELECT CAST ( NULL AS REAL ) * - 64 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * - col1 * col2 + - 32 * col0 * col2 col1 FROM tab2 AS cor0
----
-104780
-120612
-28647

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4588
SELECT ALL CAST( ( + col0 ) AS SIGNED ) + 13 AS col2 FROM tab1
----
16
77
93

skipif mysql # not compatible
query I rowsort label-4588
SELECT ALL CAST ( ( + col0 ) AS INTEGER ) + 13 AS col2 FROM tab1
----
16
77
93

query I rowsort
SELECT DISTINCT + col0 + 52 FROM tab1
----
116
132
55

query I rowsort
SELECT + 95 + cor0.col1 AS col2 FROM tab1 AS cor0
----
105
108
121

query I rowsort
SELECT - + cor0.col0 + col0 + - ( col1 ) AS col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT - - 88 - col2 * + 54 * col0 AS col0 FROM tab0 AS cor0
----
-1802
-394004
-42680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4593
SELECT + 32 DIV + cor0.col1 AS col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 3daf191600c64328f2c60722189235c6

skipif mysql # not compatible
query I rowsort label-4593
SELECT + 32 / + cor0.col1 AS col2 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 3daf191600c64328f2c60722189235c6

query I rowsort
SELECT DISTINCT + 34 * - 66 FROM tab1
----
-2244

query I rowsort
SELECT DISTINCT - col2 + + ( + tab2.col1 + 6 ) * - 18 * - col1 FROM tab2
----
20619
69004
7000

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 16 * - tab0.col0 * col0 col2 FROM tab0
----
126736
19600
9216

query I rowsort
SELECT DISTINCT ( - 74 * tab0.col2 ) + col0 * col0 AS col0 FROM tab0
----
-1866
1151
1853

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col1 col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL + col1 + + col1 * - cor0.col2 AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT + cor0.col0 * - ( + col1 ) AS col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT + - cor0.col2 * - ( col1 ) AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT col0 * + tab0.col2 AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL 14 * + tab0.col2 AS col0 FROM tab0
----
1148
14
462

query I rowsort
SELECT DISTINCT 37 + cor0.col2 FROM tab1, tab2, tab1 AS cor0
----
133
91
94

query I rowsort
SELECT 0 + col0 FROM tab2
----
7
78
79

query I rowsort
SELECT + col1 + col2 AS col0 FROM tab1
----
109
67
80

query I rowsort
SELECT DISTINCT - 56 + col2 AS col2 FROM tab2
----
-18
-29
-30

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col2 + - col1 + 50 col1 FROM tab0
----
-3
-46
41

query I rowsort
SELECT 65 + col2 FROM tab2
----
103
91
92

query IIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab1 AS cor2
----
972 values hashing to cee640567b2a4ba7d97109d5025bf4d9

query I rowsort
SELECT + 56 AS col0 FROM tab2, tab2 cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT cor0.col2 + 52 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1
----
27 values hashing to 8271568f17bc1939e419fb65a4f1c44f

query I rowsort
SELECT - - col0 * - ( 62 ) FROM tab2 AS cor0
----
-434
-4836
-4898

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * 59 col0 FROM tab0 cor0
----
1947
4838
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-4615
SELECT ALL col1 DIV 37 FROM tab0 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-4615
SELECT ALL col1 / 37 FROM tab0 AS cor0
----
2
2
2

query I rowsort
SELECT cor0.col1 + 2 * - cor0.col2 FROM tab2 AS cor0
----
-23
-59
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4617
SELECT ALL - cor0.col2 + + col0 DIV 51 FROM tab0 AS cor0
----
-1
-33
-81

skipif mysql # not compatible
query I rowsort label-4617
SELECT ALL - cor0.col2 + + col0 / 51 FROM tab0 AS cor0
----
-1
-33
-81

query I rowsort
SELECT DISTINCT col0 * + 4 AS col0 FROM tab1 AS cor0
----
12
256
320

query I rowsort
SELECT ALL col2 * ( + 44 ) AS col2 FROM tab2
----
1144
1188
1672

query I rowsort
SELECT - ( + col0 ) * - col1 AS col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + 29 + 79 AS col2 FROM tab0 AS cor0
----
108
108
108

query I rowsort
SELECT + 17 FROM tab1, tab0 AS cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT ALL col0 * 15 FROM tab0
----
1335
360
525

query I rowsort
SELECT DISTINCT 94 * + tab0.col0 FROM tab0, tab2 AS cor0
----
2256
3290
8366

query I rowsort
SELECT - 6 FROM tab1 AS cor0
----
-6
-6
-6

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab2, tab0 AS cor1
----
3645 values hashing to ca4c79a162f92454e0544707b897521a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 56 * - tab2.col1 col1 FROM tab2
----
-1736
-3304
-952

query I rowsort
SELECT - 8 * + col2 FROM tab1 cor0
----
-432
-456
-768

query I rowsort
SELECT + + col0 * col2 * cor0.col0 FROM tab1 AS cor0
----
233472
486
614400

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-4631
SELECT + col0 DIV + col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4631
SELECT + col0 / + col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - 57 AS col2 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

query I rowsort
SELECT - col1 - - col0 * ( - col0 ) AS col0 FROM tab0 AS cor0
----
-1322
-662
-8012

query I rowsort
SELECT + col1 + col1 * - ( col0 ) AS col2 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT + + ( col0 ) * - cor0.col0 AS col1 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT - col0 + + cor0.col2 * - col1 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT - - 28 AS col2 FROM tab0 AS cor0
----
28
28
28

onlyif mysql # use DIV operator for integer division
query I rowsort label-4638
SELECT ALL - col0 DIV col1 + + col2 FROM tab2 cor0
----
25
27
34

skipif mysql # not compatible
query I rowsort label-4638
SELECT ALL - col0 / col1 + + col2 FROM tab2 cor0
----
25
27
34

query I rowsort
SELECT - col2 * + col1 * - ( col2 ) + col0 FROM tab0 AS cor0
----
132
611973
93678

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 AS cor0, tab2 cor1, tab0 cor2
----
972 values hashing to 9a5ab925af18e11f7748f3b2e722ff3d

query I rowsort
SELECT ALL 93 FROM tab2, tab0 cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT col2 * col1 + 3 + - col1 AS col2 FROM tab1 AS cor0
----
1238
1381
563

query I rowsort
SELECT - - col2 + col1 * + col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL - 85 * 63 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 6f19abc14f7720732d3e05b14903d8e3

query I rowsort
SELECT DISTINCT 8 AS col2 FROM tab1
----
8

query I rowsort
SELECT ALL - col2 + + col2 * col0 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT DISTINCT col1 + - col1 * cor0.col0 * + col2 FROM tab2 AS cor0
----
-119593
-51017
-5828

query I rowsort
SELECT ALL + col0 - col2 AS col1 FROM tab2 cor0
----
-20
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-4649
SELECT ALL col1 DIV - col0 + cor0.col1 + col2 FROM tab0 AS cor0
----
116
172
96

skipif mysql # not compatible
query I rowsort label-4649
SELECT ALL col1 / - col0 + cor0.col1 + col2 FROM tab0 AS cor0
----
116
172
96

query I rowsort
SELECT DISTINCT - + col2 - col1 AS col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ALL col0 * cor0.col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col0 * col2 + col0 FROM tab2 cor0
----
-182
-1950
-2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col2 * + col2 col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL - col1 + cor0.col0 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ALL + tab0.col2 * + col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + - cor0.col2 * col0 + col2 * + col1 FROM tab2 AS cor0
----
-2356
-494
648

query I rowsort
SELECT + col1 * col1 + + col1 AS col1 FROM tab2 AS cor0
----
306
3540
992

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL + col1 * col1 + col0 AS col0 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT DISTINCT - col1 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT col1 * tab2.col2 - - col0 AS col2 FROM tab2
----
1612
725
844

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * col1 col0 FROM tab0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * + col1 - + col1 * - col1 col1 FROM tab1 AS cor0
----
1209
740
754

query I rowsort
SELECT DISTINCT - col0 + + col0 * cor0.col2 AS col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT + cor0.col2 + col2 AS col1 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT DISTINCT + 47 FROM tab0
----
47

query I rowsort
SELECT col0 + tab2.col0 AS col1 FROM tab2
----
14
156
158

query I rowsort
SELECT DISTINCT + col1 + - col0 + + col0 FROM tab1
----
10
13
26

query I rowsort
SELECT ALL col0 + tab0.col2 * - col2 + - col1 * col0 * col0 FROM tab0
----
-118791
-50601
-727446

onlyif mysql # use DIV operator for integer division
query I rowsort label-4670
SELECT ALL col2 * col1 * - col2 + + col1 * + col0 + col2 DIV - col0 FROM tab2
----
-22385
-23205
-35282

skipif mysql # not compatible
query I rowsort label-4670
SELECT ALL col2 * col1 * - col2 + + col1 * + col0 + col2 / - col0 FROM tab2
----
-22385
-23205
-35282

query I rowsort
SELECT DISTINCT col2 * tab0.col1 + + col2 AS col1 FROM tab0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-4672
SELECT DISTINCT + tab0.col2 * - col2 + col2 * col0 DIV - col1 FROM tab0
----
-1
-1098
-6804

skipif mysql # not compatible
query I rowsort label-4672
SELECT DISTINCT + tab0.col2 * - col2 + col2 * col0 / - col1 FROM tab0
----
-1
-1098
-6804

query I rowsort
SELECT ALL col0 + tab0.col2 + col1 AS col2 FROM tab0
----
133
143
262

query I rowsort
SELECT + - col0 * col0 + + col0 FROM tab1 AS cor0
----
-4032
-6
-6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-4675
SELECT - cor0.col0 + col2 DIV col1 AS col1 FROM tab2 AS cor0
----
-7
-77
-78

skipif mysql # not compatible
query I rowsort label-4675
SELECT - cor0.col0 + col2 / col1 AS col1 FROM tab2 AS cor0
----
-7
-77
-78

query I rowsort
SELECT DISTINCT - col1 * col1 + - col2 AS col2 FROM tab1
----
-157
-265
-730

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE ( NULL ) <> - col0 AND NOT col1 < - col1 OR col0 * col0 + col2 NOT IN ( col2 * col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT col1 + col2 * + col2 * - col2 AS col0 FROM tab2 AS cor0
----
-17517
-19652
-54855

query I rowsort
SELECT ALL col2 * - tab1.col2 AS col0 FROM tab1
----
-2916
-3249
-9216

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL IN ( col0 )
----

query I rowsort
SELECT DISTINCT - tab2.col0 * col2 * - col2 FROM tab2
----
114076
5103
52728

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT NULL <= ( NULL )
----

query I rowsort
SELECT + col0 + col2 + + col1 AS col0 FROM tab2
----
134
163
65

query I rowsort
SELECT ALL - col1 * + col1 * col0 AS col0 FROM tab1
----
-13520
-2028
-6400

query III rowsort
SELECT * FROM tab1 WHERE NULL NOT IN ( + col0 )
----

query I rowsort
SELECT DISTINCT + col0 * - col1 * - col0 AS col0 FROM tab2
----
106097
1519
358956

query I rowsort
SELECT DISTINCT col1 / col0 FROM tab1 WHERE NOT NULL NOT IN ( col2 * col2 )
----

query I rowsort
SELECT col1 * col1 - col2 AS col0 FROM tab0
----
7363
8199
9408

query I rowsort
SELECT DISTINCT - col2 + + col2 - - col0 FROM tab0
----
24
35
89

query I rowsort
SELECT + col2 * tab1.col1 * + col0 AS col2 FROM tab1
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col1 col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT - col0 * + tab0.col0 - - col0 AS col0 FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT - col1 * + col0 * col0 AS col0 FROM tab1
----
-234
-40960
-83200

query I rowsort
SELECT ALL col2 * col2 AS col2 FROM tab2
----
1444
676
729

query I rowsort
SELECT - + col0 + col0 * - cor0.col2 + + 18 FROM tab1 AS cor0
----
-147
-3694
-7742

query I rowsort
SELECT - - tab2.col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + tab2.col1 * col2 AS col2 FROM tab2
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col0 * col0 ) col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT col1 + - cor0.col0 * col1 AS col1 FROM tab1 AS cor0
----
-1027
-52
-630

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 AS cor0, tab2 cor1, tab0, tab2 AS cor2
----
3645 values hashing to 624c4b72c6f348b0f702418bfe39bd29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + col2 col1 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - col1 * - col2 + - col2 FROM tab0 AS cor0
----
2805
7380
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4703
SELECT ALL - + 19 DIV + col1 AS col2 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-4703
SELECT ALL - + 19 / + col1 AS col2 FROM tab1 AS cor0
----
-1
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 54 col0 FROM tab1 AS cor0
----
-54

query I rowsort
SELECT DISTINCT 22 + col0 * + 9 AS col2 FROM tab1 cor0
----
49
598
742

query I rowsort
SELECT + col1 AS col2 FROM tab2 WHERE NULL >= NULL
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL < col2 / col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4708
SELECT ALL col1 + + col1 DIV col0 AS col1 FROM tab1
----
10
13
34

skipif mysql # not compatible
query I rowsort label-4708
SELECT ALL col1 + + col1 / col0 AS col1 FROM tab1
----
10
13
34

query I rowsort
SELECT ALL col1 + cor0.col2 * + col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT - cor0.col1 * col2 + + col0 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-4711
SELECT ALL + cor0.col2 DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4711
SELECT ALL + cor0.col2 / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query III rowsort
SELECT * FROM tab1 AS cor0 WHERE - col2 = col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4713
SELECT DISTINCT - col2 DIV - col1 FROM tab1 cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-4713
SELECT DISTINCT - col2 / - col1 FROM tab1 cor0
----
2
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * - col2 col2 FROM tab1 AS cor0
----
2916
3249
9216

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT ( NULL ) >= + col2 + col2 * - col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4716
SELECT col0 DIV + col1 + col0 FROM tab2
----
7
79
83

skipif mysql # not compatible
query I rowsort label-4716
SELECT col0 / + col1 + col0 FROM tab2
----
7
79
83

query III rowsort
SELECT * FROM tab0 WHERE NOT + col2 BETWEEN NULL AND ( col2 / col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT col1 + - col1 * col0 AS col0 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT - col1 + col2 FROM tab0 WHERE NOT NULL <= NULL
----

query III rowsort
SELECT ALL * FROM tab0 WHERE + col2 = NULL
----

query I rowsort
SELECT + col1 + tab0.col1 * col1 + - col2 FROM tab0
----
7449
8290
9505

onlyif mysql # use DIV operator for integer division
query I rowsort label-4722
SELECT - tab1.col2 DIV - tab1.col1 + col2 AS col0 FROM tab1
----
103
56
62

skipif mysql # not compatible
query I rowsort label-4722
SELECT - tab1.col2 / - tab1.col1 + col2 AS col0 FROM tab1
----
103
56
62

query I rowsort
SELECT DISTINCT + col0 * col2 + + col0 AS col1 FROM tab1 WHERE NOT col1 - col0 IN ( col2 )
----
165
3712
7760

query I rowsort
SELECT DISTINCT - + col0 * - col0 + - 55 FROM tab2 AS cor0
----
-6
6029
6186

query I rowsort
SELECT tab0.col2 FROM tab0, tab1 cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL col1 - col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 * - col0 * col0 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT DISTINCT - + 72 * + cor0.col0 - col1 * col2 FROM tab0 AS cor0
----
-13870
-2617
-4566

query I rowsort
SELECT col0 * - col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + - col0 * ( - ( + col0 ) ) * ( + 93 ) - - col0 AS col2 FROM tab2 cor0
----
4564
565890
580492

query I rowsort
SELECT col2 * col2 * col0 FROM tab2 AS cor0
----
114076
5103
52728

query I rowsort
SELECT + col2 + - tab1.col2 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT + - col0 * + col2 FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4734
SELECT ( 47 ) * col2 + - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4734
SELECT ( 47 ) * col2 + - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - cor0.col0 + col1 AS col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - ( - col0 ) - col1 * 66 FROM tab0 AS cor0
----
-5652
-5917
-6367

query I rowsort
SELECT DISTINCT - 76 AS col2 FROM tab2 cor0
----
-76

query I rowsort
SELECT ALL 2 + + col2 + + col2 AS col0 FROM tab2 AS cor0
----
54
56
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( cor0.col1 ) col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + col2 + 70 AS col1 FROM tab0 AS cor0
----
103
152
71

query I rowsort
SELECT DISTINCT - col0 * cor0.col1 * col0 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT DISTINCT 30 * - 1 * cor0.col2 FROM tab1 AS cor0
----
-1620
-1710
-2880

query I rowsort
SELECT ALL 28 + - col2 FROM tab0 AS cor0
----
-5
-54
27

query I rowsort
SELECT 91 * - col0 FROM tab2 AS cor0
----
-637
-7098
-7189

query I rowsort
SELECT DISTINCT + ( cor0.col2 ) FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT DISTINCT + - 96 * col2 FROM tab2 AS cor0
----
-2496
-2592
-3648

query I rowsort
SELECT + ( - col2 ) AS col1 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT - col0 * + ( col0 + 50 ) * 77 FROM tab2 cor0
----
-30723
-768768
-784707

query I rowsort
SELECT DISTINCT - - col1 * ( col2 ) + + col2 * col0 AS col2 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT ALL - col1 + ( - 71 ) AS col2 FROM tab2
----
-102
-130
-88

query I rowsort
SELECT col0 + 99 * 75 * - tab0.col0 + col2 FROM tab0
----
-178143
-259839
-660654

query I rowsort
SELECT DISTINCT col2 + 36 + + col0 FROM tab2
----
140
153
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-4753
SELECT + ( - cor0.col0 ) * col1 + - cor0.col1 DIV col2 AS col1 FROM tab1 cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-4753
SELECT + ( - cor0.col0 ) * col1 + - cor0.col1 / col2 AS col1 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT - cor0.col0 + - col0 AS col1 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT DISTINCT col1 + col2 AS col2 FROM tab0 cor0
----
119
173
98

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 AS cor0, tab1 AS cor1, tab1, tab2 cor2
----
3645 values hashing to 85e6cb74738e0d8388af8fb625b2bd38

query I rowsort
SELECT - + 52 * + cor0.col0 * + 46 FROM tab0 AS cor0
----
-212888
-57408
-83720

query I rowsort
SELECT + col0 + + col1 + - 88 * + col0 AS col2 FROM tab2 AS cor0
----
-578
-6727
-6856

query I rowsort
SELECT + col2 * col1 + + 34 FROM tab1 cor0
----
1282
1438
604

query I rowsort
SELECT - tab2.col2 * - 65 * col0 FROM tab2
----
12285
131820
195130

query I rowsort
SELECT DISTINCT col2 * 81 FROM tab0
----
2673
6642
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col2 col0 FROM tab2
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-4763
SELECT - + 68 + col0 DIV 42 FROM tab1 cor0
----
-67
-67
-68

skipif mysql # not compatible
query I rowsort label-4763
SELECT - + 68 + col0 / 42 FROM tab1 cor0
----
-67
-67
-68

query I rowsort
SELECT col2 + tab1.col1 + tab1.col0 FROM tab1
----
131
189
83

query I rowsort
SELECT - col0 + col1 * 80 AS col1 FROM tab2 AS cor0
----
1281
2473
4642

query I rowsort
SELECT ( + col1 ) * + 19 + col1 * + col2 + col0 * + 30 AS col0 FROM tab1 AS cor0
----
1988
2680
3895

query I rowsort
SELECT ( cor0.col2 ) * 29 AS col2 FROM tab2 AS cor0
----
1102
754
783

query I rowsort
SELECT - 13 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 1c6aaa07ba8d3dc01ee616e16bef60f2

onlyif mysql # use DIV operator for integer division
query I rowsort label-4769
SELECT ALL + tab1.col2 + col1 DIV - col2 + + 92 FROM tab1
----
146
149
188

skipif mysql # not compatible
query I rowsort label-4769
SELECT ALL + tab1.col2 + col1 / - col2 + + 92 FROM tab1
----
146
149
188

onlyif mysql # use DIV operator for integer division
query I rowsort label-4770
SELECT DISTINCT tab0.col2 + col0 DIV + col0 + + col1 AS col1 FROM tab0
----
120
174
99

skipif mysql # not compatible
query I rowsort label-4770
SELECT DISTINCT tab0.col2 + col0 / + col0 + + col1 AS col1 FROM tab0
----
120
174
99

query I rowsort
SELECT ALL col0 * - col2 + col2 * - col2 AS col2 FROM tab2 AS cor0
----
-2704
-4446
-918

query I rowsort
SELECT col1 + - col1 * 17 AS col2 FROM tab0 AS cor0
----
-1376
-1456
-1552

query I rowsort
SELECT + col2 * 98 FROM tab2 AS cor0
----
2548
2646
3724

query I rowsort
SELECT ALL col1 + ( col2 ) + col0 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT DISTINCT + col1 + + ( col0 + col1 ) FROM tab0 AS cor0
----
196
229
271

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4776
SELECT ALL - CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-4776
SELECT ALL - CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT ALL + 3 * - 39 AS col1 FROM tab1
----
-117
-117
-117

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 71 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to c1aace5d5fe27721cc925552513c85c0

query I rowsort
SELECT - + 47 + col2 * + col2 * + 60 FROM tab1 AS cor0
----
174913
194893
552913

onlyif mysql # use DIV operator for integer division
query I rowsort label-4780
SELECT + - col0 DIV - col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4780
SELECT + - col0 / - col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL 62 * + col0 FROM tab2
----
434
4836
4898

query I rowsort
SELECT + + ( + col0 ) * - col1 * - cor0.col2 - col0 AS col0 FROM tab1 AS cor0
----
36416
4209
99760

onlyif mysql # use DIV operator for integer division
query I rowsort label-4783
SELECT + 97 DIV + col0 + - col0 AS col0 FROM tab2 cor0
----
-77
-78
6

skipif mysql # not compatible
query I rowsort label-4783
SELECT + 97 / + col0 + - col0 AS col0 FROM tab2 cor0
----
-77
-78
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-4784
SELECT - col2 * col2 + - col1 DIV cor0.col1 FROM tab0 AS cor0
----
-1090
-2
-6725

skipif mysql # not compatible
query I rowsort label-4784
SELECT - col2 * col2 + - col1 / cor0.col1 FROM tab0 AS cor0
----
-1090
-2
-6725

skipif mysql # not compatible
query I rowsort
SELECT + + cor0.col0 + CAST ( - ( + col2 ) * - col1 AS REAL ) FROM tab1 cor0
----
1328
1407
634

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4786
SELECT cor0.col2 * + CAST( - col2 AS SIGNED ) + col0 * + col0 FROM tab0 AS cor0
----
-513
1197
1224

skipif mysql # not compatible
query I rowsort label-4786
SELECT cor0.col2 * + CAST ( - col2 AS INTEGER ) + col0 * + col0 FROM tab0 AS cor0
----
-513
1197
1224

query I rowsort
SELECT DISTINCT col1 + - col1 * + col2 * + tab2.col1 FROM tab2
----
-10965
-25916
-90447

query I rowsort
SELECT - col0 + - ( + ( + cor0.col1 ) ) FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL + cor0.col2 * + 64 AS col2 FROM tab0 AS cor0
----
2112
5248
64

query I rowsort
SELECT - - cor0.col1 * col0 - col1 FROM tab0 cor0
----
1978
3298
8008

query I rowsort
SELECT - col1 + 40 FROM tab2 AS cor0
----
-19
23
9

query I rowsort
SELECT cor0.col1 + + 89 FROM tab1 AS cor0
----
102
115
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4793
SELECT ALL + col1 - CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4793
SELECT ALL + col1 - CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 + col1 * - 37 FROM tab2 AS cor0
----
-1116
-2124
-612

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4795
SELECT - col0 + CAST( NULL AS SIGNED ) 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-4795
SELECT - col0 + CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 4 AS col0 FROM tab2 cor0
----
4

query I rowsort
SELECT 3 + col0 FROM tab0 AS cor0
----
27
38
92

query I rowsort
SELECT DISTINCT col2 * ( - cor0.col2 ) FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + 16 FROM tab1, tab1 AS cor0
----
9 values hashing to 3fdb08ec2e3d4b642dd4594778cca8b3

query I rowsort
SELECT ALL + + 64 * col2 + + col0 AS col1 FROM tab0 cor0
----
2136
5337
99

query I rowsort
SELECT DISTINCT - - 7 AS col2 FROM tab0 AS cor0
----
7

query I rowsort
SELECT + 25 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4803
SELECT CAST( NULL AS SIGNED ) col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4803
SELECT CAST ( NULL AS INTEGER ) col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + + ( col1 ) * + col0 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-4805
SELECT DISTINCT ( col0 ) DIV col1 AS col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-4805
SELECT DISTINCT ( col0 ) / col1 AS col1 FROM tab2 AS cor0
----
0
1
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-4806
SELECT - col1 + cor0.col0 DIV - 87 + + 61 * + col1 AS col2 FROM tab1 AS cor0
----
1560
600
780

skipif mysql # not compatible
query I rowsort label-4806
SELECT - col1 + cor0.col0 / - 87 + + 61 * + col1 AS col2 FROM tab1 AS cor0
----
1560
600
780

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 8 * - col2 col2 FROM tab2
----
-208
-216
-304

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 cor0 CROSS JOIN tab1, tab1 AS cor1
----
972 values hashing to 7864aada86bf5bf5e1621c7905de8dcd

query I rowsort
SELECT - + 55 + col1 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
-1095
-133
-695

query I rowsort
SELECT ALL + 22 * col1 AS col0 FROM tab1 AS cor0
----
220
286
572

query I rowsort
SELECT - 31 * tab0.col0 AS col0 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to a56d70b297a243b33b9ed20b841771b0

query I rowsort
SELECT DISTINCT 20 AS col2 FROM tab1
----
20

query I rowsort
SELECT DISTINCT + cor0.col1 * col1 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT - cor0.col2 * col0 * - col0 + col2 - + cor0.col2 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT ALL + col1 + - col2 * col1 * col1 FROM tab0 cor0
----
-243982
-678951
-9312

query I rowsort
SELECT 6 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 5d1cb90ed58fa7573895d2f95b211821

query I rowsort
SELECT - col1 - cor0.col0 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT ALL cor0.col2 * 48 * - col2 FROM tab1 AS cor0
----
-139968
-155952
-442368

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 23 - col1 col1 FROM tab1
----
-3
10
13

onlyif mysql # use DIV operator for integer division
query I rowsort label-4820
SELECT col0 * ( - col0 ) DIV - col0 + CAST( + col1 AS SIGNED ) * tab1.col1 DIV col2 + col1 * tab1.col0 AS col2 FROM tab1
----
1121
705
93

skipif mysql # not compatible
query I rowsort label-4820
SELECT col0 * ( - col0 ) / - col0 + CAST ( + col1 AS INTEGER ) * tab1.col1 / col2 + col1 * tab1.col0 AS col2 FROM tab1
----
1121
705
93

query I rowsort
SELECT col0 + + col2 * + col1 AS col2 FROM tab2
----
1612
725
844

query I rowsort
SELECT DISTINCT + col0 * 66 + - 77 FROM tab2
----
385
5071
5137

query I rowsort
SELECT DISTINCT col0 + col1 * - 99 * + col0 + - ( + 85 ) FROM tab0
----
-204397
-336155
-801797

query I rowsort
SELECT + - col2 + - cor0.col2 * col0 * + col1 FROM tab1 AS cor0
----
-36537
-4266
-99936

query I rowsort
SELECT DISTINCT + col2 * + 0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT - 73 FROM tab1, tab1 AS cor0, tab0 cor1
----
-73

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 cor0.col0 col1 FROM tab2 cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * + col0 * + col0 col1 FROM tab2
----
343
474552
493039

onlyif mysql # use DIV operator for integer division
query I rowsort label-4830
SELECT DISTINCT - 79 DIV 27 AS col1 FROM tab0
----
-2

skipif mysql # not compatible
query I rowsort label-4830
SELECT DISTINCT - 79 / 27 AS col1 FROM tab0
----
-2

query I rowsort
SELECT ALL + col1 * - col1 * tab0.col1 FROM tab0
----
-636056
-753571
-912673

query I rowsort
SELECT ( 78 ) - col2 * - 40 FROM tab0
----
118
1398
3358

query I rowsort
SELECT - col0 + 63 FROM tab1
----
-1
-17
60

query I rowsort
SELECT + ( + col0 ) + + col0 FROM tab0
----
178
48
70

query I rowsort
SELECT + - 41 + - col1 FROM tab2 AS cor0
----
-100
-58
-72

query I rowsort
SELECT ALL + 44 FROM tab2
----
44
44
44

query I rowsort
SELECT DISTINCT 94 * col0 * col0 FROM tab0 cor0
----
115150
54144
744574

query I rowsort
SELECT + + 35 + col2 FROM tab0 AS cor0
----
117
36
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 72 col2 FROM tab2 cor0
----
72
72
72

query I rowsort
SELECT ALL - 6 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e92b2679faac7be63701967e3f0c0934

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 43 col2 FROM tab1 AS cor0
----
-43
-43
-43

query I rowsort
SELECT ALL - col1 + col2 + + 79 AS col0 FROM tab0 AS cor0
----
-17
26
70

query I rowsort
SELECT DISTINCT + 29 AS col0 FROM tab1 AS cor0
----
29

query I rowsort
SELECT ALL + col0 * + col2 + + cor0.col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL col1 * + col2 + - cor0.col2 * - col2 FROM tab2 cor0
----
1566
2090
2210

onlyif mysql # use DIV operator for integer division
query I rowsort label-4846
SELECT 43 DIV - cor0.col0 FROM tab2 AS cor0
----
-6
0
0

skipif mysql # not compatible
query I rowsort label-4846
SELECT 43 / - cor0.col0 FROM tab2 AS cor0
----
-6
0
0

query I rowsort
SELECT ALL + + col0 * col0 * - 88 AS col1 FROM tab1 AS cor0
----
-360448
-563200
-792

query I rowsort
SELECT ALL + col1 + cor0.col2 AS col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT ALL - + col1 * col0 + 54 * - col0 FROM tab1 AS cor0
----
-240
-4096
-5360

query I rowsort
SELECT - cor1.col2 FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT DISTINCT col0 * col1 * col0 AS col2 FROM tab1
----
234
40960
83200

query I rowsort
SELECT DISTINCT col0 * 15 FROM tab0
----
1335
360
525

query I rowsort
SELECT ALL - tab1.col0 * - ( col1 ) * col2 AS col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT DISTINCT + ( + col1 ) * - col1 AS col0 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT - col1 + - col2 + col1 * 12 AS col1 FROM tab1 AS cor0
----
232
47
53

query I rowsort
SELECT DISTINCT + cor0.col0 + + 6 * 15 AS col1 FROM tab0, tab2 AS cor0
----
168
169
97

query I rowsort
SELECT DISTINCT 66 FROM tab1, tab0 AS cor0
----
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4858
SELECT - col1 * col2 + cor0.col2 + CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4858
SELECT - col1 * col2 + cor0.col2 + CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( ( col1 ) ) * + col2 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-4860
SELECT - - ( + 4 ) DIV col0 AS col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4860
SELECT - - ( + 4 ) / col0 AS col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4861
SELECT tab2.col1 + tab2.col2 DIV tab2.col1 FROM tab2
----
19
31
59

skipif mysql # not compatible
query I rowsort label-4861
SELECT tab2.col1 + tab2.col2 / tab2.col1 FROM tab2
----
19
31
59

query I rowsort
SELECT DISTINCT col0 + + col2 + - col2 FROM tab1
----
3
64
80

query I rowsort
SELECT + tab0.col2 * - col2 * col0 FROM tab0
----
-26136
-35
-598436

onlyif mysql # use DIV operator for integer division
query I rowsort label-4864
SELECT ALL + + 4 DIV + tab1.col1 + + ( + 81 ) FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

skipif mysql # not compatible
query I rowsort label-4864
SELECT ALL + + 4 / + tab1.col1 + + ( + 81 ) FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4865
SELECT DISTINCT - ( + col2 ) + + CAST( NULL AS SIGNED ) * tab0.col1 AS col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-4865
SELECT DISTINCT - ( + col2 ) + + CAST ( NULL AS INTEGER ) * tab0.col1 AS col0 FROM tab0
----
NULL

query I rowsort
SELECT DISTINCT + 34 + col0 AS col2 FROM tab2
----
112
113
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-4867
SELECT + 83 DIV + col0 FROM tab1
----
1
1
27

skipif mysql # not compatible
query I rowsort label-4867
SELECT + 83 / + col0 FROM tab1
----
1
1
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-4868
SELECT ( tab1.col1 ) DIV col2 + + 4 + col1 FROM tab1
----
14
17
30

skipif mysql # not compatible
query I rowsort label-4868
SELECT ( tab1.col1 ) / col2 + + 4 + col1 FROM tab1
----
14
17
30

query I rowsort
SELECT + 96 + col2 FROM tab1 AS cor0
----
150
153
192

query I rowsort
SELECT DISTINCT - - 41 AS col0 FROM tab1 AS cor0
----
41

query I rowsort
SELECT 99 AS col0 FROM tab1 AS cor0
----
99
99
99

query I rowsort
SELECT ALL - col0 + col0 * - ( col1 ) * col0 FROM tab1 AS cor0
----
-237
-41024
-83280

query I rowsort
SELECT ALL + - cor0.col1 * col0 FROM tab1 cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-4874
SELECT + - col1 DIV 48 + + col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-4874
SELECT + - col1 / 48 + + col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT col2 + - 18 * - col0 * col2 FROM tab1 AS cor0
----
138336
2970
65721

query I rowsort
SELECT - col0 * - col1 + + 85 + - col0 FROM tab0 AS cor0
----
2125
3445
8095

query I rowsort
SELECT - col0 * 11 * - ( - col0 ) FROM tab0 AS cor0
----
-13475
-6336
-87131

query I rowsort
SELECT DISTINCT - col2 * + col0 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + + col2 * - ( col1 * - col0 + + CAST ( col2 AS REAL ) ) AS col2 FROM tab1 AS cor0
----
1296
33231
90624

query I rowsort
SELECT ALL col1 * + col1 + - 88 + - col0 AS col2 FROM tab0 AS cor0
----
7284
8104
9286

query I rowsort
SELECT ALL - col1 * - col0 + + 8 * cor0.col0 * col2 FROM tab2 AS cor0
----
1729
20826
25359

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4882
SELECT + col2 + CAST( 81 AS SIGNED ) * + col2 FROM tab2 cor0
----
2132
2214
3116

skipif mysql # not compatible
query I rowsort label-4882
SELECT + col2 + CAST ( 81 AS INTEGER ) * + col2 FROM tab2 cor0
----
2132
2214
3116

query I rowsort
SELECT ALL cor0.col2 AS col0 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT cor0.col0 * + col0 AS col1 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4885
SELECT col1 DIV - 43 - col1 col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4885
SELECT col1 / - 43 - col1 col0 FROM tab1 AS cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - - ( + col2 ) col2 FROM tab0
----
171
36
57

query I rowsort
SELECT + + col1 * ( + 18 ) + col1 FROM tab0 cor0
----
1634
1729
1843

query I rowsort
SELECT col2 * col1 + + col0 AS col0 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL col0 - - tab1.col1 FROM tab1
----
29
74
93

query I rowsort
SELECT col0 - 75 AS col2 FROM tab0 cor0
----
-40
-51
14

query I rowsort
SELECT + cor0.col1 - ( col1 ) * col1 FROM tab2 cor0
----
-272
-3422
-930

query I rowsort
SELECT + col2 * col0 AS col0 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT + col2 - - col2 AS col0 FROM tab1 AS cor0
----
108
114
192

skipif mysql # not compatible
query I rowsort
SELECT + col0 + - CAST ( + col2 * col1 AS REAL ) AS col1 FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4895
SELECT ALL + CAST( NULL AS SIGNED ) * + cor0.col2 - - cor0.col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4895
SELECT ALL + CAST ( NULL AS INTEGER ) * + cor0.col2 - - cor0.col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 44 + col0 AS col1 FROM tab0 AS cor0
----
-20
-9
45

query I rowsort
SELECT + 1 + + col1 + - col0 FROM tab1 AS cor0
----
-53
-66
24

query I rowsort
SELECT ALL 49 + - cor0.col1 FROM tab1 AS cor0
----
23
36
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4899
SELECT + - CAST( NULL AS SIGNED ) + + col0 * + col0 + 14 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4899
SELECT + - CAST ( NULL AS INTEGER ) + + col0 * + col0 + 14 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( + 46 ) * cor0.col2 * + col2 FROM tab1 AS cor0
----
134136
149454
423936

query I rowsort
SELECT DISTINCT 3 * - col0 + + cor0.col1 + ( + col0 ) FROM tab1 cor0
----
-118
-147
20

query I rowsort
SELECT - 84 * - col2 FROM tab0 cor0
----
2772
6888
84

query I rowsort
SELECT DISTINCT - - 69 AS col2 FROM tab2 AS cor0
----
69

query I rowsort
SELECT 29 + - col2 FROM tab1 AS cor0
----
-25
-28
-67

query I rowsort
SELECT + cor0.col2 * - 59 + + col0 AS col1 FROM tab1 AS cor0
----
-3183
-3299
-5584

skipif mysql # not compatible
query I rowsort
SELECT - - CAST ( col2 AS REAL ) AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT col2 * - ( tab0.col1 ) * - col1 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT DISTINCT + col2 * - ( - col0 ) AS col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT ( + col1 ) * col2 AS col2 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT 83 FROM tab0 cor0
----
83
83
83

query I rowsort
SELECT + ( + col2 ) + - col0 * col0 AS col1 FROM tab2 cor0
----
-22
-6058
-6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-4912
SELECT + + col2 DIV - col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-4912
SELECT + + col2 / - col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT - tab2.col0 AS col2 FROM tab2, tab0 cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT ALL 76 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

query I rowsort
SELECT col2 * - col0 * col2 AS col2 FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT col2 * col1 * + col1 AS col0 FROM tab2 AS cor0
----
10982
25947
90506

query I rowsort
SELECT DISTINCT + col0 * col2 AS col1 FROM tab1
----
162
3648
7680

query I rowsort
SELECT + 85 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to aafa8e5cfb9e02cea8717833e7581f7b

query I rowsort
SELECT - - col2 + cor0.col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - 74 + + col2 - + tab1.col2 AS col0 FROM tab1
----
-74
-74
-74

query I rowsort
SELECT + 20 FROM tab2, tab0 AS cor0
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col1 ) - ( - 85 ) col0 FROM tab0 AS cor0
----
171
176
182

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4923
SELECT DISTINCT - + ( col0 ) / + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4923
SELECT DISTINCT - + ( col0 ) / + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + cor0.col2 * - col2 + - ( + col1 + col2 ) FROM tab2 AS cor0
----
-1499
-761
-787

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4925
SELECT CAST( col0 * + col2 AS SIGNED ) FROM tab2
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-4925
SELECT CAST ( col0 * + col2 AS INTEGER ) FROM tab2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-4926
SELECT col0 DIV - 40 AS col1 FROM tab0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-4926
SELECT col0 / - 40 AS col1 FROM tab0
----
-2
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4927
SELECT ALL col2 * col1 DIV col1 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-4927
SELECT ALL col2 * col1 / col1 FROM tab2
----
26
27
38

query I rowsort
SELECT col0 + 43 AS col0 FROM tab1
----
107
123
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-4929
SELECT ALL - col0 DIV + col1 - + col0 FROM tab1
----
-3
-70
-86

skipif mysql # not compatible
query I rowsort label-4929
SELECT ALL - col0 / + col1 - + col0 FROM tab1
----
-3
-70
-86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * + col2 col1 FROM tab2
----
-1444
-676
-729

onlyif mysql # use DIV operator for integer division
query I rowsort label-4931
SELECT ALL col2 DIV - 47 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4931
SELECT ALL col2 / - 47 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4932
SELECT DISTINCT + + 23 DIV col0 FROM tab1 AS cor0
----
0
7

skipif mysql # not compatible
query I rowsort label-4932
SELECT DISTINCT + + 23 / col0 FROM tab1 AS cor0
----
0
7

query I rowsort
SELECT - col1 - col2 * + col0 FROM tab2 cor0
----
-2087
-220
-3019

query I rowsort
SELECT ALL + 50 * - col0 + 41 FROM tab1 AS cor0
----
-109
-3159
-3959

query I rowsort
SELECT - + 13 * + col0 + 83 * - col1 FROM tab2 AS cor0
----
-2438
-2664
-5911

query I rowsort
SELECT ALL + cor0.col1 + col0 * + col1 AS col2 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT - col1 * col2 + col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-4938
SELECT + - 48 DIV col1 FROM tab2 cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-4938
SELECT + - 48 / col1 FROM tab2 cor0
----
-1
-2
0

query I rowsort
SELECT ALL + + 36 + cor0.col1 AS col2 FROM tab1 AS cor0
----
46
49
62

query I rowsort
SELECT col2 * + col0 + col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT col0 + col0 * col1 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL col1 * col0 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT ALL - cor0.col1 * + col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - + col1 + - col2 * - col0 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT + - ( + col0 ) + - col0 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT DISTINCT ( col1 ) + 9 FROM tab2 AS cor0
----
26
40
68

query I rowsort
SELECT ALL - 91 + + cor1.col0 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab0 AS cor2, tab1 AS cor3
----
243 values hashing to 0492c11c589f835dc59e50c52ad0980b

query I rowsort
SELECT tab1.col0 - + 37 AS col0 FROM tab1
----
-34
27
43

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 cor0 CROSS JOIN tab2, tab1 AS cor1, tab0 AS cor2
----
972 values hashing to 67c5300bc5cba0be4f54a444dc6f05b9

query I rowsort
SELECT ALL - col1 + - ( - col1 ) AS col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4951
SELECT DISTINCT col1 + + CAST( NULL AS SIGNED ) * + 26 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4951
SELECT DISTINCT col1 + + CAST ( NULL AS INTEGER ) * + 26 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - col0 * col0 * - col2 + cor0.col1 AS col2 FROM tab1 AS cor0
----
233482
512
614413

query I rowsort
SELECT - - col1 + col0 AS col0 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-4954
SELECT ALL - + cor0.col2 - ( - ( col1 ) ) DIV 11 FROM tab2 AS cor0
----
-21
-25
-37

skipif mysql # not compatible
query I rowsort label-4954
SELECT ALL - + cor0.col2 - ( - ( col1 ) ) / 11 FROM tab2 AS cor0
----
-21
-25
-37

query I rowsort
SELECT - cor0.col2 * ( col1 ) AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 30 col0 FROM tab0 AS cor0
----
30
30
30

query I rowsort
SELECT DISTINCT 4 + - col2 AS col2 FROM tab1 AS cor0
----
-50
-53
-92

query I rowsort
SELECT ALL + - ( - col2 ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL 24 + 33 * cor0.col1 * 77 FROM tab2 AS cor0
----
149943
43221
78795

query I rowsort
SELECT ALL - 36 FROM tab0, tab0 AS cor0
----
9 values hashing to afecaf209e79e23b6674a73fffa3e837

query I rowsort
SELECT col0 * - col2 AS col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - cor0.col1 FROM tab1, tab0 cor0, tab1 AS cor1, tab2, tab1 cor2
----
243 values hashing to 7f0405f8197238fbd342972ef0bcee12

query I rowsort
SELECT ALL - cor0.col1 AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT DISTINCT - 10 * 55 * col1 AS col0 FROM tab1 AS cor0
----
-14300
-5500
-7150

query I rowsort
SELECT DISTINCT - 16 AS col0 FROM tab0 AS cor0
----
-16

query I rowsort
SELECT cor0.col2 + - 90 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 8f4b416e6d940eb19658362c34408b74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4967
SELECT - + CAST( NULL AS SIGNED ) + col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4967
SELECT - + CAST ( NULL AS INTEGER ) + col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + ( ( - col1 ) ) AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + col2 * - col1 * col1 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT col2 + + 35 AS col1 FROM tab0 AS cor0
----
117
36
68

onlyif mysql # use DIV operator for integer division
query I rowsort label-4971
SELECT ALL + - col1 DIV - 70 + cor0.col0 AS col1 FROM tab1 AS cor0
----
3
64
80

skipif mysql # not compatible
query I rowsort label-4971
SELECT ALL + - col1 / - 70 + cor0.col0 AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + 66 * 61 FROM tab0 AS cor0
----
4026
4026
4026

query I rowsort
SELECT ALL - 64 * + 59 AS col1 FROM tab1 AS cor0
----
-3776
-3776
-3776

query I rowsort
SELECT 28 + col1 AS col1 FROM tab0 AS cor0
----
114
119
125

onlyif mysql # use DIV operator for integer division
query I rowsort label-4975
SELECT DISTINCT + col2 DIV col2 - col0 FROM tab0 AS cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-4975
SELECT DISTINCT + col2 / col2 - col0 FROM tab0 AS cor0
----
-23
-34
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 88 * col0 col2 FROM tab1 AS cor0
----
-264
-5632
-7040

query I rowsort
SELECT col2 * 76 AS col1 FROM tab2 AS cor0
----
1976
2052
2888

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - col2 ) col0 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT ALL col0 + 54 FROM tab0 AS cor0
----
143
78
89

query I rowsort
SELECT ALL + 2 * + col1 + col0 FROM tab0 AS cor0
----
196
229
271

query I rowsort
SELECT DISTINCT - col1 * - col2 + - ( + col1 ) AS col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT + + 37 AS col2 FROM tab1 AS cor0
----
37
37
37

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0, tab1, tab2 cor1
----
972 values hashing to 01a5931cccc3dad8792a1bc6df09c614

query I rowsort
SELECT ( cor0.col1 ) FROM tab1, tab0 AS cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT - cor0.col1 + + 11 FROM tab2 AS cor0
----
-20
-48
-6

query I rowsort
SELECT DISTINCT - cor1.col0 * + cor0.col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 778568a0294a40217171bb2f1bbf2149

query I rowsort
SELECT DISTINCT tab0.col2 + col2 AS col1 FROM tab0
----
164
2
66

query I rowsort
SELECT col1 + 17 * 68 FROM tab1
----
1166
1169
1182

query I rowsort
SELECT col1 * - tab1.col2 + 39 AS col0 FROM tab1
----
-1209
-1365
-531

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4990
SELECT DISTINCT - tab2.col0 * - CAST( NULL AS SIGNED ) col0 FROM tab2
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4990
SELECT DISTINCT - tab2.col0 * - CAST ( NULL AS INTEGER ) col0 FROM tab2
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - col0 * - cor0.col1 col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL 17 * + 67 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to d2642328a21cabda9527d8706a60a38c

query I rowsort
SELECT DISTINCT - 51 FROM tab1, tab1 AS cor0, tab1 cor1
----
-51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 81 * col0 - + col1 col1 FROM tab0 cor0
----
-2030
-2932
-7300

query I rowsort
SELECT cor0.col2 + cor0.col0 * cor0.col2 * cor0.col2 AS col2 FROM tab2 AS cor0
----
114114
5130
52754

query I rowsort
SELECT ( col1 ) * - cor0.col2 * col1 + col1 FROM tab0 AS cor0
----
-243982
-678951
-9312

query I rowsort
SELECT + 36 + col2 - ( + col0 ) * col2 AS col2 FROM tab1 AS cor0
----
-3555
-72
-7548

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 44 + - tab0.col1 col1 FROM tab0
----
-42
-47
-53

query I rowsort
SELECT DISTINCT cor1.col0 * 56 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
168
3584
4480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 64 * + col0 + ( col2 ) col2 FROM tab2 AS cor0
----
-421
-4966
-5018

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5001
SELECT ( - cor0.col2 ) - - CAST( NULL AS SIGNED ) * cor0.col2 * col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5001
SELECT ( - cor0.col2 ) - - CAST ( NULL AS INTEGER ) * cor0.col2 * col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 42 + + tab2.col2 * col2 AS col0 FROM tab2
----
1486
718
771

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - tab0.col1 col2 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT ALL 87 * tab2.col2 AS col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 36dcd02dc5b81910bca290f034031f6a

query I rowsort
SELECT DISTINCT tab0.col1 FROM tab0, tab2, tab1 AS cor0
----
86
91
97

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 cor0, tab0 cor1, tab2 AS cor2
----
972 values hashing to 42e69ecdafb3c81046bc5cb4c98b1666

query I rowsort
SELECT + - ( 54 ) AS col2 FROM tab1 AS cor0
----
-54
-54
-54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5008
SELECT CAST( + 9 AS SIGNED ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

skipif mysql # not compatible
query I rowsort label-5008
SELECT CAST ( + 9 AS INTEGER ) AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 03b93b53107e36cf7d524e48c509b17b

query I rowsort
SELECT 56 FROM tab1, tab0 AS cor0
----
9 values hashing to 9c4523312174730bbc525b9977aa99fa

query I rowsort
SELECT DISTINCT + 56 FROM tab2, tab0 AS cor0, tab2 AS cor1, tab1, tab2 AS cor2
----
56

query I rowsort
SELECT DISTINCT col0 * 24 AS col1 FROM tab2
----
168
1872
1896

query I rowsort
SELECT DISTINCT + cor1.col1 FROM tab2, tab2 AS cor0 CROSS JOIN tab0, tab1 cor1
----
10
13
26

query I rowsort
SELECT - 55 FROM tab0, tab1 AS cor0
----
9 values hashing to ac76841ceecd2311e80c621d15bacdd3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5014
SELECT DISTINCT - - CAST( - col1 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-5014
SELECT DISTINCT - - CAST ( - col1 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT ALL - 71 + col1 FROM tab0
----
15
20
26

query I rowsort
SELECT + + cor0.col1 * + 54 FROM tab1 AS cor0
----
1404
540
702

query I rowsort
SELECT cor0.col0 + - col1 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL + - 5 + 60 * col2 * col2 FROM tab2 AS cor0
----
40555
43735
86635

query I rowsort
SELECT + + col1 * col2 * + col1 AS col2 FROM tab1 AS cor0
----
16224
36504
5700

onlyif mysql # use DIV operator for integer division
query I rowsort label-5020
SELECT col1 DIV cor0.col2 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5020
SELECT col1 / cor0.col2 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - ( col1 ) * col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT col0 * - col0 AS col0 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL - ( cor0.col2 ) AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT 64 * + col2 FROM tab0
----
2112
5248
64

onlyif mysql # use DIV operator for integer division
query I rowsort label-5025
SELECT DISTINCT - 96 * - col2 DIV col2 FROM tab1
----
96

skipif mysql # not compatible
query I rowsort label-5025
SELECT DISTINCT - 96 * - col2 / col2 FROM tab1
----
96

query I rowsort
SELECT ( + 3 * - col1 + col2 * col0 ) FROM tab1
----
3618
7641
84

query I rowsort
SELECT ( + col2 + - col0 ) FROM tab2
----
-41
-52
20

query I rowsort
SELECT ALL + 26 AS col2 FROM tab1
----
26
26
26

query I rowsort
SELECT ( col1 ) AS col1 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT + 57 FROM tab2
----
57
57
57

query I rowsort
SELECT col0 * col0 + + col1 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT + col0 * - cor0.col2 * col1 FROM tab1 cor0
----
-36480
-4212
-99840

query I rowsort
SELECT + cor0.col2 * cor0.col0 + cor0.col2 * col1 FROM tab1 AS cor0
----
1566
4218
8928

onlyif mysql # use DIV operator for integer division
query I rowsort label-5034
SELECT DISTINCT 20 DIV + tab2.col0 - tab2.col1 FROM tab2
----
-17
-29
-59

skipif mysql # not compatible
query I rowsort label-5034
SELECT DISTINCT 20 / + tab2.col0 - tab2.col1 FROM tab2
----
-17
-29
-59

query I rowsort
SELECT + col1 * + col1 * col1 - - col1 AS col0 FROM tab2 AS cor0
----
205438
29822
4930

query I rowsort
SELECT DISTINCT + 30 FROM tab1 AS cor0
----
30

query I rowsort
SELECT DISTINCT + 36 FROM tab2
----
36

query I rowsort
SELECT DISTINCT + + 1 * col1 AS col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + cor0.col1 + col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT - col2 * 37 FROM tab0 AS cor0
----
-1221
-3034
-37

query I rowsort
SELECT DISTINCT - col0 * + col2 AS col0 FROM tab2
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 + ( 7 ) col2 FROM tab2 AS cor0
----
24
38
66

query I rowsort
SELECT - + col2 * cor0.col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT col2 + ( + col0 ) FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + cor0.col2 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 5911bac51441f4ff640b2a2b721ea8e3

query I rowsort
SELECT ALL - 75 FROM tab0, tab1 AS cor0
----
9 values hashing to 258bc565c64924d905a55eaaa6e57547

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5047
SELECT ALL + + col0 * - CAST( NULL AS SIGNED ) * + cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5047
SELECT ALL + + col0 * - CAST ( NULL AS INTEGER ) * + cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT cor0.col0 + cor0.col2 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + - col0 + - col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT + col1 * - 69 AS col1 FROM tab2 AS cor0
----
-1173
-2139
-4071

query I rowsort
SELECT ALL - col2 * - col0 + ( + col0 ) FROM tab0 AS cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-5052
SELECT + col2 DIV - cor0.col0 FROM tab2 cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-5052
SELECT + col2 / - cor0.col0 FROM tab2 cor0
----
-3
0
0

query I rowsort
SELECT 82 + - col1 FROM tab1
----
56
69
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-5054
SELECT + tab0.col1 - col0 DIV + tab0.col2 AS col2 FROM tab0
----
62
86
90

skipif mysql # not compatible
query I rowsort label-5054
SELECT + tab0.col1 - col0 / + tab0.col2 AS col2 FROM tab0
----
62
86
90

query I rowsort
SELECT DISTINCT + 30 * tab0.col1 FROM tab0
----
2580
2730
2910

query I rowsort
SELECT DISTINCT + 46 * col2 FROM tab1
----
2484
2622
4416

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5057
SELECT col0 + CAST( col0 AS SIGNED ) AS col1 FROM tab2
----
14
156
158

skipif mysql # not compatible
query I rowsort label-5057
SELECT col0 + CAST ( col0 AS INTEGER ) AS col1 FROM tab2
----
14
156
158

query I rowsort
SELECT ALL + tab0.col1 - + 56 FROM tab0
----
30
35
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-5059
SELECT ALL - - cor0.col2 DIV - ( ( + col1 ) ) AS col0 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-5059
SELECT ALL - - cor0.col2 / - ( ( + col1 ) ) AS col0 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT + - col1 * cor0.col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 col0 FROM tab2 AS cor0
----
7
78
79

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 AS cor2, tab1 AS cor3
----
3645 values hashing to 80b3ced88f886d6e15182ebf21c93987

query I rowsort
SELECT + cor1.col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

query I rowsort
SELECT ALL + cor0.col1 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

onlyif mysql # use DIV operator for integer division
query I rowsort label-5065
SELECT - + col1 DIV ( col2 ) + col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-5065
SELECT - + col1 / ( col2 ) + col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - col2 * 39 + col1 FROM tab2 AS cor0
----
-1022
-1465
-955

query I rowsort
SELECT DISTINCT + cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
17
31
59

query I rowsort
SELECT + col2 + - col0 AS col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT DISTINCT + 50 AS col1 FROM tab1
----
50

query I rowsort
SELECT ALL + 73 AS col2 FROM tab1 AS cor0
----
73
73
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-5071
SELECT - col1 + + cor0.col2 DIV col1 + cor0.col0 * col1 AS col0 FROM tab2 AS cor0
----
1328
186
4543

skipif mysql # not compatible
query I rowsort label-5071
SELECT - col1 + + cor0.col2 / col1 + cor0.col0 * col1 AS col0 FROM tab2 AS cor0
----
1328
186
4543

query I rowsort
SELECT ALL - cor0.col1 * col0 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT - 44 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 38f05fdaaf15e64b62f27cd96f73fb79

query I rowsort
SELECT DISTINCT + cor0.col1 + - cor0.col1 FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5075
SELECT + 98 DIV col1 AS col0 FROM tab1 AS cor0
----
3
7
9

skipif mysql # not compatible
query I rowsort label-5075
SELECT + 98 / col1 AS col0 FROM tab1 AS cor0
----
3
7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5076
SELECT + ( + col0 ) + + col2 * col2 DIV col2 col0 FROM tab1
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5076
SELECT + ( + col0 ) + + col2 * col2 / col2 col0 FROM tab1
----
121
176
57

query I rowsort
SELECT DISTINCT 87 FROM tab1
----
87

query I rowsort
SELECT - col0 * col0 + col0 AS col2 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT + 43 AS col1 FROM tab0 AS cor0
----
43

query I rowsort
SELECT ALL + col0 * - col0 + - 17 * + col0 AS col2 FROM tab0 AS cor0
----
-1820
-9434
-984

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 42 + + cor0.col0 - + cor0.col0 col1 FROM tab0 AS cor0
----
42
42
42

query I rowsort
SELECT ALL + 64 * col1 + + 58 FROM tab1 AS cor0
----
1722
698
890

query I rowsort
SELECT DISTINCT + 88 * col0 - + 77 FROM tab2 AS cor0
----
539
6787
6875

query I rowsort
SELECT ALL + + 0 + cor0.col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT DISTINCT - + col2 + cor0.col0 AS col0 FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-5086
SELECT ALL col1 * col2 DIV - CAST( - cor0.col0 AS SIGNED ) + col2 + col1 * col1 AS col1 FROM tab1 cor0
----
1198
165
280

skipif mysql # not compatible
query I rowsort label-5086
SELECT ALL col1 * col2 / - CAST ( - cor0.col0 AS INTEGER ) + col2 + col1 * col1 AS col1 FROM tab1 cor0
----
1198
165
280

query I rowsort
SELECT DISTINCT col2 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5088
SELECT DISTINCT + col2 * col2 + - CAST( - 96 AS SIGNED ) * cor0.col1 * - ( col2 ) col1 FROM tab0 AS cor0
----
-271359
-709628
-9311

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5088
SELECT DISTINCT + col2 * col2 + - CAST ( - 96 AS INTEGER ) * cor0.col1 * - ( col2 ) col1 FROM tab0 AS cor0
----
-271359
-709628
-9311

query I rowsort
SELECT ALL - 59 + col0 FROM tab1 cor0
----
-56
21
5

query I rowsort
SELECT DISTINCT - cor0.col2 + col1 AS col1 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + col0 + 75 AS col0 FROM tab0 AS cor0
----
110
164
99

query I rowsort
SELECT ALL + col0 + col0 * col1 AS col2 FROM tab1 AS cor0
----
1120
704
81

skipif mysql # not compatible
query I rowsort
SELECT ALL + 97 * col2 + + CAST ( col0 AS REAL ) FROM tab1
----
5241
5593
9392

onlyif mysql # use DIV operator for integer division
query I rowsort label-5094
SELECT DISTINCT 98 DIV - cor0.col2 AS col1 FROM tab2, tab0 AS cor0
----
-1
-2
-98

skipif mysql # not compatible
query I rowsort label-5094
SELECT DISTINCT 98 / - cor0.col2 AS col1 FROM tab2, tab0 AS cor0
----
-1
-2
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5095
SELECT DISTINCT - cor0.col0 DIV col0 + + col1 AS col1 FROM tab2 cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-5095
SELECT DISTINCT - cor0.col0 / col0 + + col1 AS col1 FROM tab2 cor0
----
16
30
58

query I rowsort
SELECT col1 * + col1 + cor0.col0 * + col0 FROM tab2 AS cor0
----
1010
6530
9565

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5097
SELECT + CAST( col0 AS SIGNED ) + + col2 AS col2 FROM tab0 cor0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-5097
SELECT + CAST ( col0 AS INTEGER ) + + col2 AS col2 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT ALL - - 99 AS col2 FROM tab2 AS cor0
----
99
99
99

query I rowsort
SELECT ALL + 59 + 18 FROM tab0 AS cor0
----
77
77
77

query I rowsort
SELECT DISTINCT + - 70 AS col1 FROM tab1 AS cor0
----
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5101
SELECT CAST( col0 AS SIGNED ) + cor0.col0 FROM tab0 AS cor0
----
178
48
70

skipif mysql # not compatible
query I rowsort label-5101
SELECT CAST ( col0 AS INTEGER ) + cor0.col0 FROM tab0 AS cor0
----
178
48
70

onlyif mysql # use DIV operator for integer division
query I rowsort label-5102
SELECT col2 DIV ( ( - col1 ) * 69 ) FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5102
SELECT col2 / ( ( - col1 ) * 69 ) FROM tab0
----
0
0
0

query I rowsort
SELECT + + cor0.col2 - - col2 AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT ALL + - 52 * - ( col1 ) - - col0 FROM tab0 AS cor0
----
4496
4821
5079

query I rowsort
SELECT ALL ( 73 ) * col2 + 92 * + cor0.col2 + col0 * col1 FROM tab1 AS cor0
----
10045
16880
8988

query I rowsort
SELECT + - col1 + col0 AS col2 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ALL - col2 * + 72 + - col2 AS col0 FROM tab0
----
-2409
-5986
-73

query I rowsort
SELECT ALL + tab1.col0 + 94 FROM tab1
----
158
174
97

query I rowsort
SELECT DISTINCT - col0 - + col1 FROM tab0 AS cor0
----
-110
-132
-180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5110
SELECT DISTINCT - col1 * col1 + + CAST( NULL AS SIGNED ) - 23 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5110
SELECT DISTINCT - col1 * col1 + + CAST ( NULL AS INTEGER ) - 23 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT 21 + col0 AS col2 FROM tab0 AS cor0
----
110
45
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-5112
SELECT ALL - 32 DIV col1 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-55
-60
-98

skipif mysql # not compatible
query I rowsort label-5112
SELECT ALL - 32 / col1 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-55
-60
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + ( col2 ) * col1 * col2 col2 FROM tab2
----
22630
24565
39943

query I rowsort
SELECT + 99 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to 4b77467dd5f346109d29f6364a7bb8db

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5115
SELECT - CAST( col2 + + col0 AS DECIMAL ) * + CAST( NULL AS SIGNED ) * - 21 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5115
SELECT - CAST ( col2 + + col0 AS REAL ) * + CAST ( NULL AS INTEGER ) * - 21 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 + + col0 + + col0 FROM tab0
----
134
167
269

query I rowsort
SELECT DISTINCT ( - col0 * col0 ) + - col1 FROM tab1
----
-35
-4106
-6413

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5118
SELECT - CAST( NULL AS SIGNED ) + + 95 AS col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5118
SELECT - CAST ( NULL AS INTEGER ) + + 95 AS col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ( col0 ) - - col2 AS col0 FROM tab0
----
171
36
57

query I rowsort
SELECT DISTINCT - ( col1 ) + col0 - - 43 * col2 FROM tab1 AS cor0
----
2299
2505
4195

query I rowsort
SELECT ALL + 59 FROM tab0, tab0 AS cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

query I rowsort
SELECT ( + col0 ) * + col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT + ( col1 ) * + col2 AS col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT - cor0.col0 * + col2 + col1 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT + - cor0.col2 + + col2 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - col1 col1 FROM tab2 AS cor0
----
-118
-34
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5127
SELECT - 26 DIV + 17 FROM tab0, tab0 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

skipif mysql # not compatible
query I rowsort label-5127
SELECT - 26 / + 17 FROM tab0, tab0 AS cor0
----
9 values hashing to 60fdd6924bb763d6aca00ba74935ef4b

query I rowsort
SELECT DISTINCT ( + col2 ) + + col1 AS col2 FROM tab1
----
109
67
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5129
SELECT ALL + CAST( NULL AS DECIMAL ) AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5129
SELECT ALL + CAST ( NULL AS REAL ) AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - 28 * - col1 * 36 + col0 * - col2 FROM tab2 AS cor0
----
-20138
-31437
-61500

query I rowsort
SELECT - - 93 - col1 * + ( col1 ) FROM tab0 AS cor0
----
-7303
-8188
-9316

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * cor0.col1 col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - - col2 + + col2 - col0 FROM tab0 AS cor0
----
-33
42
75

query I rowsort
SELECT - + col1 + - col2 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT - - col1 + - 53 FROM tab1 AS cor0
----
-27
-40
-43

query I rowsort
SELECT + 16 * + col1 AS col1 FROM tab1 AS cor0
----
160
208
416

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5137
SELECT - CAST( 41 AS SIGNED ) + col0 FROM tab2 AS cor0
----
-34
37
38

skipif mysql # not compatible
query I rowsort label-5137
SELECT - CAST ( 41 AS INTEGER ) + col0 FROM tab2 AS cor0
----
-34
37
38

query I rowsort
SELECT DISTINCT - - tab0.col2 AS col0 FROM tab0, tab1, tab2 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT 96 AS col2 FROM tab1, tab0 AS cor0, tab0 cor1
----
96

query I rowsort
SELECT DISTINCT ( cor0.col0 ) + cor0.col1 FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) + - col1 * 29 AS col2 FROM tab0 AS cor0
----
-2527
-2721
-2814

query I rowsort
SELECT DISTINCT 84 AS col1 FROM tab1, tab1 AS cor0
----
84

query I rowsort
SELECT DISTINCT - cor0.col2 AS col0 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
-1
-33
-82

query I rowsort
SELECT + col0 + 19 AS col1 FROM tab0 AS cor0
----
108
43
54

query I rowsort
SELECT - 44 * + cor0.col2 FROM tab1 AS cor0
----
-2376
-2508
-4224

query I rowsort
SELECT DISTINCT - col0 * + 31 FROM tab0 AS cor0
----
-1085
-2759
-744

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5148
SELECT + CAST( NULL AS SIGNED ) col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5148
SELECT + CAST ( NULL AS INTEGER ) col0 FROM tab0
----
NULL
NULL
NULL

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2, tab1 AS cor0, tab2 AS cor1
----
972 values hashing to 2507aa9f48c3db94de9fec065edf3731

query I rowsort
SELECT DISTINCT 40 * col0 FROM tab2
----
280
3120
3160

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5151
SELECT ALL - CAST( + 51 AS SIGNED ) AS col1 FROM tab0
----
-51
-51
-51

skipif mysql # not compatible
query I rowsort label-5151
SELECT ALL - CAST ( + 51 AS INTEGER ) AS col1 FROM tab0
----
-51
-51
-51

query I rowsort
SELECT DISTINCT 57 * - col2 AS col2 FROM tab1
----
-3078
-3249
-5472

query I rowsort
SELECT + col0 * - 97 FROM tab0 AS cor0
----
-2328
-3395
-8633

query I rowsort
SELECT col1 * - 79 FROM tab2 AS cor0
----
-1343
-2449
-4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col1 ) col2 FROM tab2
----
17
31
59

query I rowsort
SELECT - - col0 + ( - col1 ) * + col2 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5157
SELECT ALL - col1 * + CAST( 48 AS SIGNED ) * col1 AS col1 FROM tab2 AS cor0
----
-13872
-167088
-46128

skipif mysql # not compatible
query I rowsort label-5157
SELECT ALL - col1 * + CAST ( 48 AS INTEGER ) * col1 AS col1 FROM tab2 AS cor0
----
-13872
-167088
-46128

onlyif mysql # use DIV operator for integer division
query I rowsort label-5158
SELECT col1 * col2 DIV col0 + col2 FROM tab2
----
146
45
46

skipif mysql # not compatible
query I rowsort label-5158
SELECT col1 * col2 / col0 + col2 FROM tab2
----
146
45
46

query I rowsort
SELECT 95 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT + 25 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2c77240b60ac01c717a5ed5d0165f450

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1, tab1 AS cor0, tab1 cor1
----
972 values hashing to a8481bfbfcb330825976c5896e54bc19

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5162
SELECT - - col2 * CAST( col1 + col2 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
1566
2090
2210

skipif mysql # not compatible
query I rowsort label-5162
SELECT - - col2 * CAST ( col1 + col2 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
1566
2090
2210

query I rowsort
SELECT - + cor0.col1 + ( + col2 ) FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL cor0.col2 FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT col0 + - ( col2 ) AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + col2 * col2 * col0 + cor0.col0 + col2 AS col1 FROM tab2 AS cor0
----
114193
5137
52832

query I rowsort
SELECT DISTINCT - col0 * 95 FROM tab0 AS cor0
----
-2280
-3325
-8455

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - col2 + + col0 col2 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT + col1 * 70 + + col2 * cor0.col0 * - 63 + + col1 AS col1 FROM tab0 AS cor0
----
-43790
-453313
4682

query I rowsort
SELECT DISTINCT col0 * col1 + ( + col1 ) * col2 AS col1 FROM tab1 AS cor0
----
1210
1482
2288

query I rowsort
SELECT ALL - - 90 - col0 * col0 * cor0.col2 AS col2 FROM tab1 AS cor0
----
-233382
-396
-614310

query I rowsort
SELECT ALL + 16 * + cor0.col2 * col2 AS col1 FROM tab2 cor0
----
10816
11664
23104

query I rowsort
SELECT DISTINCT + 16 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
16

query I rowsort
SELECT col1 + col2 * + ( - 52 ) FROM tab2
----
-1293
-1373
-1959

query I rowsort
SELECT - 75 AS col1 FROM tab2 AS cor0
----
-75
-75
-75

query I rowsort
SELECT ALL - - col0 - + col2 * - 58 FROM tab0 AS cor0
----
1938
4845
93

query I rowsort
SELECT - 29 * col1 + ( + col2 * - col0 ) FROM tab2 AS cor0
----
-1088
-3495
-3739

query I rowsort
SELECT ( - col2 ) + + col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT + ( + 71 ) AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
71

query I rowsort
SELECT DISTINCT - + col2 + col0 AS col2 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT - + col1 + + 72 + col1 FROM tab2 cor0
----
72

query I rowsort
SELECT ALL - col0 - col1 FROM tab0 AS cor0
----
-110
-132
-180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + col2 + col1 * - col2 AS col0 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT + + col0 * - 30 + col1 FROM tab2 AS cor0
----
-179
-2281
-2353

query I rowsort
SELECT ALL cor0.col0 * + col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + col2 * + cor0.col2 AS col0 FROM tab1 cor0
----
2916
3249
9216

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5188
SELECT DISTINCT - + cor0.col0 + CAST( NULL AS SIGNED ) + + 67 * + col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5188
SELECT DISTINCT - + cor0.col0 + CAST ( NULL AS INTEGER ) + + 67 * + col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT ( ( - tab1.col0 ) ) FROM tab1, tab1 AS cor0, tab2 AS cor1
----
-3
-64
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5190
SELECT tab1.col2 + + col1 * - ( col0 + - col1 * - CAST( col0 AS SIGNED ) ) FROM tab1
----
-14464
-2052
-6983

skipif mysql # not compatible
query I rowsort label-5190
SELECT tab1.col2 + + col1 * - ( col0 + - col1 * - CAST ( col0 AS INTEGER ) ) FROM tab1
----
-14464
-2052
-6983

query I rowsort
SELECT DISTINCT 50 FROM tab1
----
50

query I rowsort
SELECT + col0 - + col2 AS col1 FROM tab1
----
-16
-51
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 56 * col0 - + col0 col1 FROM tab2
----
-399
-4446
-4503

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5194
SELECT + col1 * tab1.col1 * - CAST( NULL AS SIGNED ) - + col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5194
SELECT + col1 * tab1.col1 * - CAST ( NULL AS INTEGER ) - + col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT 35 AS col0 FROM tab0
----
35
35
35

query I rowsort
SELECT ALL + col0 + col2 * - col1 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( ( + col2 ) AS REAL ) + 25 AS col2 FROM tab0 AS cor0
----
107
26
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col1 * col1 col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT + ( 71 ) + + col1 * col0 * + col0 AS col2 FROM tab0 AS cor0
----
118896
49607
720882

query I rowsort
SELECT DISTINCT + - 90 FROM tab1 AS cor0
----
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5201
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + cor0.col1 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5201
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + cor0.col1 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - ( - col2 ) + - col1 FROM tab1 AS cor0
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col1 * - col0 col1 FROM tab1 cor0
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT - - col2 + col1 * col1 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT + 45 + col0 * - col1 AS col0 FROM tab1 AS cor0
----
-33
-595
-995

query I rowsort
SELECT - tab2.col1 * 17 AS col1 FROM tab2
----
-1003
-289
-527

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5207
SELECT ALL col1 * CAST( NULL AS DECIMAL ) - col2 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5207
SELECT ALL col1 * CAST ( NULL AS REAL ) - col2 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * + col1 + - col2 * + cor0.col1 * + 40 FROM tab0 AS cor0
----
-106124
-290199
5529

query I rowsort
SELECT ALL - + cor0.col2 AS col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT + ( 73 ) - cor0.col0 FROM tab0 AS cor0
----
-16
38
49

query I rowsort
SELECT DISTINCT + 85 - - col2 FROM tab1 AS cor0
----
139
142
181

onlyif mysql # use DIV operator for integer division
query I rowsort label-5212
SELECT - col2 * col2 DIV + col2 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-5212
SELECT - col2 * col2 / + col2 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT col1 * - col2 * + col1 AS col0 FROM tab2
----
-10982
-25947
-90506

onlyif mysql # use DIV operator for integer division
query I rowsort label-5214
SELECT tab2.col1 DIV ( 18 * col0 ) AS col1 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5214
SELECT tab2.col1 / ( 18 * col0 ) AS col1 FROM tab2
----
0
0
0

query I rowsort
SELECT col2 * 67 * - col2 FROM tab1
----
-195372
-217683
-617472

query I rowsort
SELECT ( col1 ) + col1 AS col0 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT + 64 * + 75 FROM tab0 AS cor0
----
4800
4800
4800

query I rowsort
SELECT + + cor0.col0 + cor0.col1 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - ( + col0 ) + - col2 AS col0 FROM tab1
----
-121
-176
-57

query I rowsort
SELECT + col2 * - col0 + 38 - col0 AS col1 FROM tab1 AS cor0
----
-127
-3674
-7722

onlyif mysql # use DIV operator for integer division
query I rowsort label-5221
SELECT 14 DIV + tab0.col0 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-5221
SELECT 14 / + tab0.col0 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - + col2 * cor0.col1 * - col2 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT + col1 + col0 * + 30 AS col1 FROM tab1 AS cor0
----
116
1930
2413

onlyif mysql # use DIV operator for integer division
query I rowsort label-5224
SELECT - ( col2 ) + - col0 DIV 47 + ( - col2 ) * - ( col1 ) FROM tab2
----
1507
607
810

skipif mysql # not compatible
query I rowsort label-5224
SELECT - ( col2 ) + - col0 / 47 + ( - col2 ) * - ( col1 ) FROM tab2
----
1507
607
810

query I rowsort
SELECT DISTINCT - 84 AS col2 FROM tab0, tab2 AS cor0
----
-84

query I rowsort
SELECT DISTINCT - col1 * + col1 + - col0 FROM tab0
----
-7420
-8370
-9444

query I rowsort
SELECT ALL - 55 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to ac76841ceecd2311e80c621d15bacdd3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 21 col1 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 631fbd1fd929405aba54a22c2a06c757

query I rowsort
SELECT ALL + 96 AS col1 FROM tab1
----
96
96
96

query I rowsort
SELECT DISTINCT + + col1 * col2 AS col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT ALL col0 + - col0 * + 20 AS col1 FROM tab0 AS cor0
----
-1691
-456
-665

query I rowsort
SELECT - 11 + + col2 FROM tab2 cor0
----
15
16
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col2 * - col1 col1 FROM tab0 AS cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - ( col1 ) col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + cor0.col2 * col2 AS col1 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL + 85 + - col2 FROM tab2 AS cor0
----
47
58
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + cor0.col1 - - cor0.col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT ALL - col1 + col0 * col1 FROM tab0 cor0
----
1978
3298
8008

query I rowsort
SELECT + col1 + cor0.col1 * col0 AS col0 FROM tab2 AS cor0
----
1360
248
4661

query I rowsort
SELECT DISTINCT - cor0.col1 + + col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + + col0 + col0 * cor0.col1 FROM tab0 AS cor0
----
2088
3430
8188

query I rowsort
SELECT ALL + ( - 10 ) AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

query I rowsort
SELECT ALL + col0 + 60 * + col1 AS col0 FROM tab2 AS cor0
----
1099
1867
3618

query I rowsort
SELECT ALL - col1 * + col1 + - ( cor0.col2 ) AS col0 FROM tab0 AS cor0
----
-7429
-8363
-9410

query I rowsort
SELECT DISTINCT + col1 * - col0 + col1 * + col2 AS col1 FROM tab2 AS cor0
----
-3068
-697
620

query I rowsort
SELECT DISTINCT col2 * + 93 FROM tab2 AS cor0
----
2418
2511
3534

query I rowsort
SELECT - + ( cor0.col1 ) + - 0 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ccaa5dd3388d9ee0fea676fa35299fe5

query I rowsort
SELECT + 87 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to fa0cdd86483844cda3bb806e032d5c64

query I rowsort
SELECT DISTINCT col1 * 4 FROM tab0 cor0
----
344
364
388

query I rowsort
SELECT DISTINCT - ( + ( col0 ) ) + - 5 FROM tab1 AS cor0
----
-69
-8
-85

query I rowsort
SELECT + 82 + - col2 AS col2 FROM tab0 AS cor0
----
0
49
81

query I rowsort
SELECT ALL - + 28 * col0 FROM tab2 AS cor0
----
-196
-2184
-2212

onlyif mysql # use DIV operator for integer division
query I rowsort label-5254
SELECT + CAST( + ( col2 ) + 96 AS SIGNED ) DIV - col0 AS col1 FROM tab0
----
-2
-2
-5

skipif mysql # not compatible
query I rowsort label-5254
SELECT + CAST ( + ( col2 ) + 96 AS INTEGER ) / - col0 AS col1 FROM tab0
----
-2
-2
-5

query I rowsort
SELECT ALL + - 36 AS col0 FROM tab0 AS cor0
----
-36
-36
-36

query I rowsort
SELECT - - col1 * + ( - col2 ) - - col0 AS col2 FROM tab2 cor0
----
-1456
-567
-830

query I rowsort
SELECT ALL + - 13 AS col0 FROM tab0 AS cor0
----
-13
-13
-13

query I rowsort
SELECT 10 + col1 - + col1 * 11 FROM tab0 AS cor0
----
-850
-900
-960

query I rowsort
SELECT DISTINCT + + 27 + - col1 AS col0 FROM tab2 AS cor0
----
-32
-4
10

query I rowsort
SELECT + cor0.col0 - 43 FROM tab1, tab1 AS cor0
----
9 values hashing to 135f51c2372d0915375575587c52dcbc

onlyif mysql # use DIV operator for integer division
query I rowsort label-5261
SELECT DISTINCT col0 + col1 DIV col1 AS col1 FROM tab1 cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-5261
SELECT DISTINCT col0 + col1 / col1 AS col1 FROM tab1 cor0
----
4
65
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-5262
SELECT cor0.col2 DIV - cor0.col1 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-5262
SELECT cor0.col2 / - cor0.col1 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col1 * + 32 col1 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 5b30c97a52b49fbc31a7469da807e0b1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5264
SELECT - col1 DIV ( - col1 ) FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5264
SELECT - col1 / ( - col1 ) FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT - col0 * ( col1 ) AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + 22 + col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
119
2860
7484

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5267
SELECT - ( + col1 ) * cor0.col0 + - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5267
SELECT - ( + col1 ) * cor0.col0 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - ( 64 ) * col1 + + col0 * 15 FROM tab2 AS cor0
----
-1879
-2606
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5269
SELECT DISTINCT + col2 + - ( cor0.col0 + - col2 ) DIV 27 AS col2 FROM tab1 AS cor0
----
55
57
96

skipif mysql # not compatible
query I rowsort label-5269
SELECT DISTINCT + col2 + - ( cor0.col0 + - col2 ) / 27 AS col2 FROM tab1 AS cor0
----
55
57
96

query I rowsort
SELECT DISTINCT + + col1 + + 22 FROM tab1 AS cor0
----
32
35
48

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5271
SELECT ALL + CAST( - tab0.col1 * - col2 AS SIGNED ) FROM tab0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-5271
SELECT ALL + CAST ( - tab0.col1 * - col2 AS INTEGER ) FROM tab0
----
2838
7462
97

query I rowsort
SELECT ALL 65 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT - 25 * + 42 - + col2 AS col1 FROM tab0 AS cor0
----
-1051
-1083
-1132

query I rowsort
SELECT ( - col1 ) + col0 * + 11 FROM tab1 cor0
----
694
7
867

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5275
SELECT DISTINCT CAST( + cor0.col1 AS SIGNED ) + col2 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-5275
SELECT DISTINCT CAST ( + cor0.col1 AS INTEGER ) + col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + col2 * cor0.col0 AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - + 86 + col2 FROM tab1 AS cor0
----
-29
-32
10

query I rowsort
SELECT - col0 * + col1 + col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT - 48 + col1 FROM tab1 cor0
----
-22
-35
-38

query I rowsort
SELECT col1 * col2 + col0 AS col0 FROM tab2
----
1612
725
844

query I rowsort
SELECT - 12 * col1 + tab1.col1 * + tab1.col0 AS col0 FROM tab1
----
-234
520
884

query I rowsort
SELECT - ( + 88 ) * - col0 AS col1 FROM tab2
----
616
6864
6952

query I rowsort
SELECT 92 + 50 FROM tab1
----
142
142
142

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5284
SELECT - CAST( 71 AS SIGNED ) * + col0 FROM tab0
----
-1704
-2485
-6319

skipif mysql # not compatible
query I rowsort label-5284
SELECT - CAST ( 71 AS INTEGER ) * + col0 FROM tab0
----
-1704
-2485
-6319

query I rowsort
SELECT - + col2 + col1 * + cor0.col1 AS col2 FROM tab1 cor0
----
43
622
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-5286
SELECT - col0 + - col1 DIV col1 FROM tab0 AS cor0
----
-25
-36
-90

skipif mysql # not compatible
query I rowsort label-5286
SELECT - col0 + - col1 / col1 FROM tab0 AS cor0
----
-25
-36
-90

query I rowsort
SELECT - col2 + - col2 AS col0 FROM tab1
----
-108
-114
-192

query I rowsort
SELECT ALL + 65 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 1c9d0bf96cd3361942fadad668138b9c

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT DISTINCT - cor0.col2 AS col2 FROM tab0, tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT + col2 * col2 + + cor0.col0 FROM tab1 cor0
----
2919
3313
9296

query I rowsort
SELECT col2 + + col0 AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL + 97 FROM tab2, tab0 cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

query I rowsort
SELECT ALL - 73 AS col2 FROM tab2
----
-73
-73
-73

query I rowsort
SELECT ALL - col2 * + cor0.col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT 73 + - col0 AS col1 FROM tab0 AS cor0
----
-16
38
49

query I rowsort
SELECT - 12 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 3983bffe2adf88cb2efc3be93ee620c0

query I rowsort
SELECT DISTINCT - col0 * - cor0.col0 - + col1 FROM tab2 AS cor0
----
18
6025
6224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 - + cor0.col1 col0 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5300
SELECT DISTINCT col1 * - col2 - cor0.col0 DIV - col1 FROM tab2 AS cor0
----
-1533
-642
-837

skipif mysql # not compatible
query I rowsort label-5300
SELECT DISTINCT col1 * - col2 - cor0.col0 / - col1 FROM tab2 AS cor0
----
-1533
-642
-837

query I rowsort
SELECT col0 + + 59 FROM tab1 AS cor0
----
123
139
62

query I rowsort
SELECT ALL - cor0.col2 + col1 * 81 AS col2 FROM tab0 AS cor0
----
6933
7289
7856

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - 0 * + col2 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + cor0.col2 * cor0.col1 AS col1 FROM tab1 AS cor0
----
1248
1404
570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5305
SELECT - col0 + - CAST( NULL AS SIGNED ) / ( - col0 ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5305
SELECT - col0 + - CAST ( NULL AS INTEGER ) / ( - col0 ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 20 * - col1 FROM tab0
----
-1720
-1820
-1940

query I rowsort
SELECT ALL + cor0.col0 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT ALL col0 + col1 * 28 AS col2 FROM tab1
----
344
444
731

query I rowsort
SELECT + 90 * col0 * col2 + - col1 - + col1 AS col1 FROM tab0 AS cor0
----
2956
656638
71108

query I rowsort
SELECT - cor0.col0 AS col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

onlyif mysql # use DIV operator for integer division
query I rowsort label-5311
SELECT + col1 DIV + 68 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5311
SELECT + col1 / + 68 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - 53 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to fee5c00ad71c23e23683a32c71fe6e7d

query I rowsort
SELECT + ( + col0 ) * col2 + + col0 * col1 - + col0 FROM tab2 cor0
----
399
4266
6552

query I rowsort
SELECT - 12 + 29 FROM tab2 AS cor0
----
17
17
17

query I rowsort
SELECT - ( + col0 ) + - col0 - col0 FROM tab0 AS cor0
----
-105
-267
-72

query I rowsort
SELECT DISTINCT ( cor0.col0 ) AS col1 FROM tab2, tab2 AS cor0
----
7
78
79

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab0, tab1, tab0 AS cor0
----
1
33
82

query I rowsort
SELECT 97 FROM tab2, tab2 AS cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

query I rowsort
SELECT + ( - col0 ) * - col1 AS col0 FROM tab0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + 85 col0 FROM tab0 AS cor0
----
118
167
86

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 - tab0.col1 col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 58ed467a9a332e4d7bfaa9abdbbd063f

query I rowsort
SELECT + tab1.col2 * - 41 + + col2 AS col1 FROM tab1
----
-2160
-2280
-3840

query I rowsort
SELECT - col1 + - 91 AS col1 FROM tab0
----
-177
-182
-188

query I rowsort
SELECT 42 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 325aada2239b6fe1fe2d843515ae8c5e

onlyif mysql # use DIV operator for integer division
query I rowsort label-5326
SELECT ALL + col0 DIV 98 + - ( col1 ) FROM tab2
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-5326
SELECT ALL + col0 / 98 + - ( col1 ) FROM tab2
----
-17
-31
-59

query I rowsort
SELECT - cor0.col1 * + 61 + - col2 * cor0.col1 FROM tab1 AS cor0
----
-1180
-2041
-2990

query I rowsort
SELECT ALL - + col0 * 69 AS col2 FROM tab2 AS cor0
----
-483
-5382
-5451

query I rowsort
SELECT DISTINCT - - col2 * - col1 + - col0 + cor0.col2 AS col0 FROM tab2 AS cor0
----
-1586
-687
-817

query I rowsort
SELECT - col0 * col2 - - col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT - col1 + + col0 * col2 * + col1 AS col2 FROM tab1 AS cor0
----
36470
4186
99827

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5332
SELECT DISTINCT + col1 * + CAST( NULL AS SIGNED ) * + col0 + col2 AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5332
SELECT DISTINCT + col1 * + CAST ( NULL AS INTEGER ) * + col0 + col2 AS col1 FROM tab2 AS cor0
----
NULL

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 DISTINCT col0 + ( - 18 * col2 ) + col1 col2 FROM tab0
----
-1296
-484
114

query I rowsort
SELECT ALL col0 * 88 AS col2 FROM tab1 cor0
----
264
5632
7040

query I rowsort
SELECT + - 41 FROM tab2 AS cor0
----
-41
-41
-41

query I rowsort
SELECT ALL - + col1 * - col1 + col0 AS col2 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT DISTINCT - col1 + + col1 * col0 AS col0 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT ALL col1 * col0 * col1 + + col1 AS col0 FROM tab2 AS cor0
----
22848
271577
6758

query I rowsort
SELECT ALL - - ( col1 ) + + col2 * 17 FROM tab1 cor0
----
1645
944
979

query I rowsort
SELECT ALL - ( 85 ) * - cor0.col1 * col2 FROM tab2 AS cor0
----
130390
54910
71145

query I rowsort
SELECT - col0 + 95 AS col2 FROM tab1 AS cor0
----
15
31
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col0 ) col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - + col2 * + 88 + col1 FROM tab2 AS cor0
----
-2229
-2345
-3327

query I rowsort
SELECT col0 * - 3 + + col1 FROM tab0 AS cor0
----
-176
-8
14

query I rowsort
SELECT DISTINCT ( cor0.col0 ) * + cor0.col0 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5347
SELECT ALL + col0 / cor0.col2 + - col0 / CAST( NULL AS SIGNED ) + 35 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5347
SELECT ALL + col0 / cor0.col2 + - col0 / CAST ( NULL AS INTEGER ) + 35 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 57 FROM tab0 AS cor0
----
57
57
57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5349
SELECT ALL - CAST( 88 AS SIGNED ) + col1 col2 FROM tab2 AS cor0
----
-29
-57
-71

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5349
SELECT ALL - CAST ( 88 AS INTEGER ) + col1 col2 FROM tab2 AS cor0
----
-29
-57
-71

onlyif mysql # use DIV operator for integer division
query I rowsort label-5350
SELECT ALL col0 DIV ( - 3 ) + - col2 DIV - col1 FROM tab0
----
-11
-29
-8

skipif mysql # not compatible
query I rowsort label-5350
SELECT ALL col0 / ( - 3 ) + - col2 / - col1 FROM tab0
----
-11
-29
-8

query I rowsort
SELECT ALL - - ( + col0 ) * col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT col0 + ( col2 ) FROM tab2 AS cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5353
SELECT ALL + col2 DIV col0 AS col2 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-5353
SELECT ALL + col2 / col0 AS col2 FROM tab1 AS cor0
----
0
1
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5354
SELECT - CAST( col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-5354
SELECT - CAST ( col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL 12 * + col0 AS col0 FROM tab0 cor0
----
1068
288
420

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 34 col0 FROM tab2 AS cor0
----
34
34
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5357
SELECT DISTINCT - col2 * + col1 + col0 DIV col1 FROM tab1 AS cor0
----
-1242
-1404
-564

skipif mysql # not compatible
query I rowsort label-5357
SELECT DISTINCT - col2 * + col1 + col0 / col1 FROM tab1 AS cor0
----
-1242
-1404
-564

query I rowsort
SELECT col1 + col2 + - col0 AS col2 FROM tab2 cor0
----
-24
51
7

query I rowsort
SELECT - col2 * - col2 * cor0.col2 FROM tab0 AS cor0
----
1
35937
551368

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5360
SELECT - + ( cor0.col0 ) + + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5360
SELECT - + ( cor0.col0 ) + + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 9 + col0 * + col2 FROM tab1 AS cor0
----
171
3657
7689

query I rowsort
SELECT + + col1 + col0 * - 27 FROM tab0 AS cor0
----
-2312
-562
-848

query I rowsort
SELECT DISTINCT + 43 AS col1 FROM tab2
----
43

query I rowsort
SELECT ALL - ( - col1 ) + - 16 FROM tab1 AS cor0
----
-3
-6
10

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * - col0 col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL + col0 + + col2 * 43 AS col0 FROM tab2 AS cor0
----
1168
1196
1713

query I rowsort
SELECT - + 62 * + col1 AS col0 FROM tab1 AS cor0
----
-1612
-620
-806

query I rowsort
SELECT DISTINCT - 79 AS col1 FROM tab0 AS cor0
----
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 + cor0.col0 * + 16 col0 FROM tab1 AS cor0
----
-6
1184
967

query I rowsort
SELECT DISTINCT - + cor0.col2 * - col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5371
SELECT ALL col0 + + col1 DIV ( 78 ) AS col2 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-5371
SELECT ALL col0 + + col1 / ( 78 ) AS col2 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT ALL + 16 + cor0.col1 AS col1 FROM tab2 AS cor0
----
33
47
75

query I rowsort
SELECT - + col2 AS col0 FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT ALL col1 + + cor0.col2 AS col0 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ALL + - col2 - + cor0.col2 AS col2 FROM tab2 cor0
----
-52
-54
-76

query I rowsort
SELECT DISTINCT - cor0.col0 * cor0.col2 * + col1 AS col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-5377
SELECT ALL - col0 - col1 * col1 DIV + col0 FROM tab1 AS cor0
----
-228
-65
-82

skipif mysql # not compatible
query I rowsort label-5377
SELECT ALL - col0 - col1 * col1 / + col0 FROM tab1 AS cor0
----
-228
-65
-82

query I rowsort
SELECT ALL + - cor0.col1 + ( - col2 + + col2 * 44 ) FROM tab1 AS cor0
----
2296
2441
4115

query I rowsort
SELECT + col2 * col2 + col2 AS col2 FROM tab0
----
1122
2
6806

query I rowsort
SELECT - tab2.col0 - col2 AS col0 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT DISTINCT 19 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
19

query I rowsort
SELECT ALL - 33 - + col1 AS col1 FROM tab2
----
-50
-64
-92

query I rowsort
SELECT DISTINCT - col0 * 26 * col0 FROM tab0 AS cor0
----
-14976
-205946
-31850

onlyif mysql # use DIV operator for integer division
query I rowsort label-5384
SELECT + + col0 DIV - 71 + 41 - col0 FROM tab1 AS cor0
----
-23
-40
38

skipif mysql # not compatible
query I rowsort label-5384
SELECT + + col0 / - 71 + 41 - col0 FROM tab1 AS cor0
----
-23
-40
38

query I rowsort
SELECT ALL + col1 + - ( + col1 ) * col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT + + col1 + + 16 AS col1 FROM tab0 AS cor0
----
102
107
113

query I rowsort
SELECT + cor0.col2 - - 29 FROM tab0 AS cor0
----
111
30
62

query I rowsort
SELECT ALL + 78 * - col1 FROM tab2
----
-1326
-2418
-4602

query I rowsort
SELECT + - col0 + - col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT - 70 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 35707a5d99c98b2657c084a50ff1b073

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5391
SELECT - CAST( col1 AS SIGNED ) * col0 + 16 AS col0 FROM tab0 AS cor0
----
-2048
-3379
-8083

skipif mysql # not compatible
query I rowsort label-5391
SELECT - CAST ( col1 AS INTEGER ) * col0 + 16 AS col0 FROM tab0 AS cor0
----
-2048
-3379
-8083

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5392
SELECT ALL col2 + CAST( NULL AS SIGNED ) * col2 col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5392
SELECT ALL col2 + CAST ( NULL AS INTEGER ) * col2 col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5393
SELECT col0 * + 20 + + 92 * col0 DIV + 98 + - tab0.col1 FROM tab0
----
1772
416
635

skipif mysql # not compatible
query I rowsort label-5393
SELECT col0 * + 20 + + 92 * col0 / + 98 + - tab0.col1 FROM tab0
----
1772
416
635

query I rowsort
SELECT DISTINCT cor0.col0 AS col0 FROM tab1 cor0 CROSS JOIN tab2, tab0 AS cor1
----
3
64
80

query I rowsort
SELECT DISTINCT - col0 + - col1 AS col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT + cor0.col1 - col0 AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT cor0.col1 - col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT cor0.col0 * - cor0.col1 * 15 FROM tab2 AS cor0
----
-20145
-3255
-69030

query I rowsort
SELECT 67 AS col1 FROM tab1 AS cor0
----
67
67
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col1 * 27 col1 FROM tab2
----
1593
459
837

query I rowsort
SELECT ALL 10 FROM tab0 AS cor0
----
10
10
10

query I rowsort
SELECT ALL - 61 FROM tab0 AS cor0
----
-61
-61
-61

query I rowsort
SELECT - + 69 + + cor0.col2 * col0 FROM tab2 cor0
----
120
1959
2933

query I rowsort
SELECT DISTINCT + + col1 * - col0 * + col0 AS col0 FROM tab1 AS cor0
----
-234
-40960
-83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-5405
SELECT ALL - col2 + - cor0.col2 DIV + 14 FROM tab0 AS cor0
----
-1
-35
-87

skipif mysql # not compatible
query I rowsort label-5405
SELECT ALL - col2 + - cor0.col2 / + 14 FROM tab0 AS cor0
----
-1
-35
-87

query I rowsort
SELECT ALL cor0.col1 * - col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT 52 * - col1 AS col0 FROM tab2 cor0
----
-1612
-3068
-884

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5408
SELECT + col2 + cor0.col2 * CAST( 43 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
1452
3608
44

skipif mysql # not compatible
query I rowsort label-5408
SELECT + col2 + cor0.col2 * CAST ( 43 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
1452
3608
44

query I rowsort
SELECT DISTINCT - ( + col2 ) + 5 FROM tab2 AS cor0
----
-21
-22
-33

onlyif mysql # use DIV operator for integer division
query I rowsort label-5410
SELECT DISTINCT + cor0.col1 DIV col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-5410
SELECT DISTINCT + cor0.col1 / col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT + - 66 + col0 FROM tab1 AS cor0
----
-2
-63
14

query I rowsort
SELECT 71 * + 85 * + col1 AS col1 FROM tab1 AS cor0
----
156910
60350
78455

onlyif mysql # use DIV operator for integer division
query I rowsort label-5413
SELECT - + col2 * + col1 + col2 DIV col2 AS col0 FROM tab1 AS cor0
----
-1247
-1403
-569

skipif mysql # not compatible
query I rowsort label-5413
SELECT - + col2 * + col1 + col2 / col2 AS col0 FROM tab1 AS cor0
----
-1247
-1403
-569

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5414
SELECT CAST( NULL AS SIGNED ) + ( - cor0.col0 + col1 ) * col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5414
SELECT CAST ( NULL AS INTEGER ) + ( - cor0.col0 + col1 ) * col2 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5415
SELECT ( col0 ) * + col2 + 38 DIV col0 AS col2 FROM tab0 AS cor0
----
36
7298
793

skipif mysql # not compatible
query I rowsort label-5415
SELECT ( col0 ) * + col2 + 38 / col0 AS col2 FROM tab0 AS cor0
----
36
7298
793

query I rowsort
SELECT DISTINCT + ( 96 ) AS col0 FROM tab2
----
96

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0, tab2, tab1 AS cor1
----
972 values hashing to dd771e0c15d524f62127686e9bd43f9a

query I rowsort
SELECT - col2 + + 20 AS col2 FROM tab1 cor0
----
-34
-37
-76

query I rowsort
SELECT - ( - col1 ) * col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL + tab2.col1 + col1 * col2 FROM tab2
----
1593
663
868

query IIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0 WHERE NULL > NULL
----

query I rowsort
SELECT ALL 85 FROM tab0
----
85
85
85

query I rowsort
SELECT - col2 + 85 FROM tab1 AS cor0
----
-11
28
31

onlyif mysql # use DIV operator for integer division
query I rowsort label-5424
SELECT col2 - col2 DIV + col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-5424
SELECT col2 - col2 / + col1 FROM tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-5425
SELECT DISTINCT - col2 * 44 DIV + col0 - col0 * + col2 * col0 FROM tab0
----
-1226
-19068
-649562

skipif mysql # not compatible
query I rowsort label-5425
SELECT DISTINCT - col2 * 44 / + col0 - col0 * + col2 * col0 FROM tab0
----
-1226
-19068
-649562

onlyif mysql # use DIV operator for integer division
query I rowsort label-5426
SELECT DISTINCT col0 - col0 DIV col0 AS col1 FROM tab2
----
6
77
78

skipif mysql # not compatible
query I rowsort label-5426
SELECT DISTINCT col0 - col0 / col0 AS col1 FROM tab2
----
6
77
78

query I rowsort
SELECT col2 * - 77 + col1 * col1 FROM tab2 AS cor0
----
-1118
-2637
1479

query I rowsort
SELECT + + col1 * 33 - - col2 * col2 AS col0 FROM tab2 AS cor0
----
1752
2005
2623

query I rowsort
SELECT col1 * - col0 + col1 * + col0 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 + 81 FROM tab0
----
-10
-16
-5

query I rowsort
SELECT 22 + - col2 FROM tab0 AS cor0
----
-11
-60
21

query I rowsort
SELECT DISTINCT + cor0.col1 + cor0.col0 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + col1 + - 43 * + col0 AS col0 FROM tab1 AS cor0
----
-103
-2742
-3427

query I rowsort
SELECT DISTINCT + col1 + + col2 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT 9 * col0 * col0 + + col1 FROM tab0 AS cor0
----
11122
5270
71380

query I rowsort
SELECT DISTINCT 99 + + col2 + - col0 * col0 FROM tab0
----
-1125
-444
-7740

onlyif mysql # use DIV operator for integer division
query I rowsort label-5437
SELECT - col2 DIV + col1 col0 FROM tab2 AS cor0
----
-2
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5437
SELECT - col2 / + col1 col0 FROM tab2 AS cor0
----
-2
0
0

query I rowsort
SELECT ALL 96 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - 85 * cor0.col2 - col2 col1 FROM tab0 AS cor0
----
-241263
-634352
-8246

query I rowsort
SELECT + col1 * 23 * col1 FROM tab1 AS cor0
----
15548
2300
3887

query I rowsort
SELECT - 59 - - col2 FROM tab0 AS cor0
----
-26
-58
23

query I rowsort
SELECT ALL - + col0 + col1 AS col1 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT - cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT DISTINCT - cor0.col0 + col0 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - - col2 * 35 FROM tab2 AS cor0
----
1330
910
945

onlyif mysql # use DIV operator for integer division
query I rowsort label-5446
SELECT ALL - col1 DIV ( - col1 ) + + col1 AS col2 FROM tab2 cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-5446
SELECT ALL - col1 / ( - col1 ) + + col1 AS col2 FROM tab2 cor0
----
18
32
60

query I rowsort
SELECT DISTINCT - col0 * 37 * 37 + - col0 AS col1 FROM tab0 AS cor0
----
-121930
-32880
-47950

query I rowsort
SELECT DISTINCT ( + col0 ) AS col1 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 73 col2 FROM tab2
----
73
73
73

query I rowsort
SELECT + + 62 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

query I rowsort
SELECT DISTINCT + 16 * col1 AS col1 FROM tab1
----
160
208
416

query I rowsort
SELECT + 81 FROM tab0, tab2, tab0 cor0
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

query I rowsort
SELECT - 22 * col0 + cor0.col2 FROM tab0 AS cor0
----
-1876
-495
-769

query I rowsort
SELECT DISTINCT tab2.col1 * - ( col1 ) AS col0 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT ( tab1.col0 ) + - col0 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 + + col0 * - tab0.col1 AS col0 FROM tab0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL - tab2.col0 + tab2.col2 * + col1 * - col1 + tab2.col2 * ( - col2 ) AS col0 FROM tab2
----
-12505
-26683
-91260

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - col1 col1 FROM tab0
----
-172
-182
-194

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + + col2 col0 FROM tab1
----
121
176
57

query I rowsort
SELECT col2 + + tab2.col0 + col0 * col0 AS col0 FROM tab2
----
6188
6358
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5461
SELECT ALL - 85 * col0 + CAST( NULL AS SIGNED ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5461
SELECT ALL - 85 * col0 + CAST ( NULL AS INTEGER ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 85 + col1 FROM tab1 AS cor0
----
111
95
98

query I rowsort
SELECT ALL + cor0.col2 + + col0 FROM tab1 AS cor0
----
121
176
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 66 col1 FROM tab1 AS cor0
----
66
66
66

query I rowsort
SELECT DISTINCT + 26 + - col1 + - ( - 72 ) AS col1 FROM tab1
----
72
85
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-5466
SELECT DISTINCT 40 * - cor0.col0 + cor0.col0 DIV - col2 AS col2 FROM tab1 AS cor0
----
-120
-2561
-3200

skipif mysql # not compatible
query I rowsort label-5466
SELECT DISTINCT 40 * - cor0.col0 + cor0.col0 / - col2 AS col2 FROM tab1 AS cor0
----
-120
-2561
-3200

onlyif mysql # use DIV operator for integer division
query I rowsort label-5467
SELECT - col1 + cor0.col0 DIV + col1 FROM tab2 AS cor0
----
-13
-31
-58

skipif mysql # not compatible
query I rowsort label-5467
SELECT - col1 + cor0.col0 / + col1 FROM tab2 AS cor0
----
-13
-31
-58

query I rowsort
SELECT DISTINCT col0 + + col1 AS col1 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT - + 49 FROM tab1 AS cor0
----
-49
-49
-49

query I rowsort
SELECT + col0 - - col0 * + col0 AS col0 FROM tab1
----
12
4160
6480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5471
SELECT - tab0.col0 * + CAST( col2 AS SIGNED ) + + col1 * col2 * col2 FROM tab0
----
604586
62
92862

skipif mysql # not compatible
query I rowsort label-5471
SELECT - tab0.col0 * + CAST ( col2 AS INTEGER ) + + col1 * col2 * col2 FROM tab0
----
604586
62
92862

query I rowsort
SELECT DISTINCT - 93 AS col1 FROM tab1, tab2, tab1 AS cor0, tab0
----
-93

query I rowsort
SELECT DISTINCT col1 * 6 AS col0 FROM tab2
----
102
186
354

query I rowsort
SELECT col0 * - col1 * col1 - - tab0.col1 FROM tab0
----
-177418
-329218
-736918

onlyif mysql # use DIV operator for integer division
query I rowsort label-5475
SELECT DISTINCT + tab2.col1 DIV col0 FROM tab2
----
0
4

skipif mysql # not compatible
query I rowsort label-5475
SELECT DISTINCT + tab2.col1 / col0 FROM tab2
----
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 97 col2 FROM tab0, tab0 AS cor0
----
-97

query I rowsort
SELECT col2 * col0 - - col0 FROM tab0
----
70
7387
816

query I rowsort
SELECT 37 FROM tab1, tab1 cor0
----
9 values hashing to a10b03e72860b949bdff53827700a9a8

query I rowsort
SELECT ( - 71 ) AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

onlyif mysql # use DIV operator for integer division
query I rowsort label-5480
SELECT - col0 + ( + 79 + - col0 ) DIV ( + 80 * col1 ) FROM tab0 cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-5480
SELECT - col0 + ( + 79 + - col0 ) / ( + 80 * col1 ) FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT - col0 + - col2 * - cor0.col0 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT DISTINCT col1 * col2 + - col1 + + col0 AS col1 FROM tab0 AS cor0
----
2776
35
7460

query I rowsort
SELECT DISTINCT + 23 FROM tab1, tab1 AS cor0
----
23

skipif mysql # not compatible
query I rowsort
SELECT tab0.col1 + - CAST ( col2 + col2 AS REAL ) AS col2 FROM tab0
----
-73
20
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-5485
SELECT ALL 29 + col2 DIV cor0.col0 FROM tab0 AS cor0
----
29
29
30

skipif mysql # not compatible
query I rowsort label-5485
SELECT ALL 29 + col2 / cor0.col0 FROM tab0 AS cor0
----
29
29
30

query I rowsort
SELECT ALL + cor0.col1 * + col1 FROM tab1 cor0
----
100
169
676

query I rowsort
SELECT DISTINCT + col1 + 81 AS col1 FROM tab1 AS cor0
----
107
91
94

query I rowsort
SELECT - - 75 * col0 * col2 FROM tab1 AS cor0
----
12150
273600
576000

query I rowsort
SELECT ALL + 85 + col0 AS col2 FROM tab0 AS cor0
----
109
120
174

onlyif mysql # use DIV operator for integer division
query I rowsort label-5490
SELECT + CAST( col1 AS SIGNED ) DIV + col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5490
SELECT + CAST ( col1 AS INTEGER ) / + col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + col0 * col1 * col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT DISTINCT - + col1 + ( col1 ) * - col1 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT ALL + ( col2 ) * col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL + ( - col1 ) FROM tab0 AS cor0
----
-86
-91
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - ( + col2 ) * + col2 col2 FROM tab2 AS cor0
----
-17576
-19683
-54872

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 65 col2 FROM tab0 AS cor0
----
65
65
65

query I rowsort
SELECT - - 6 * col1 AS col2 FROM tab1 AS cor0
----
156
60
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5498
SELECT + CAST( - col0 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-5498
SELECT + CAST ( - col0 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL col2 * + 43 AS col0 FROM tab2 AS cor0
----
1118
1161
1634

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5500
SELECT cor0.col0 * ( - col2 ) * CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5500
SELECT cor0.col0 * ( - col2 ) * CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 15 AS col1 FROM tab2 AS cor0
----
-15
-15
-15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5502
SELECT ALL - CAST( - 45 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
45
45
45

skipif mysql # not compatible
query I rowsort label-5502
SELECT ALL - CAST ( - 45 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
45
45
45

query I rowsort
SELECT DISTINCT col2 * - col2 AS col0 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * 67 col0 FROM tab2 cor0
----
1742
1809
2546

query I rowsort
SELECT ALL - col2 + - 60 FROM tab1 AS cor0
----
-114
-117
-156

query I rowsort
SELECT DISTINCT + + 19 FROM tab1, tab0, tab1 AS cor0
----
19

query I rowsort
SELECT ALL - 13 FROM tab2
----
-13
-13
-13

query I rowsort
SELECT 22 FROM tab0, tab1 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT ALL - 23 AS col0 FROM tab0
----
-23
-23
-23

query I rowsort
SELECT ALL 78 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

query I rowsort
SELECT ALL + 25 + col0 AS col2 FROM tab0 AS cor0
----
114
49
60

query I rowsort
SELECT + 47 + - col2 FROM tab0 cor0
----
-35
14
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5513
SELECT ALL + CAST( col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-5513
SELECT ALL + CAST ( col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + ( 63 ) + - col2 FROM tab2 AS cor0
----
25
36
37

query I rowsort
SELECT + col2 * cor0.col0 + + 79 FROM tab0 AS cor0
----
114
7377
871

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col1 col1 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT - - col0 + + cor0.col1 AS col1 FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 + col1 col0 FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5519
SELECT + - cor0.col0 * col2 DIV + col1 AS col2 FROM tab1 AS cor0
----
-364
-590
-6

skipif mysql # not compatible
query I rowsort label-5519
SELECT + - cor0.col0 * col2 / + col1 AS col2 FROM tab1 AS cor0
----
-364
-590
-6

query I rowsort
SELECT DISTINCT + + col2 + - col0 + col0 AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ( col0 ) + tab1.col0 FROM tab1
----
128
160
6

query I rowsort
SELECT ALL 1 AS col2 FROM tab0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5523
SELECT ALL - - col2 + + CAST( 4 AS SIGNED ) - col1 AS col0 FROM tab1 AS cor0
----
32
51
87

skipif mysql # not compatible
query I rowsort label-5523
SELECT ALL - - col2 + + CAST ( 4 AS INTEGER ) - col1 AS col0 FROM tab1 AS cor0
----
32
51
87

query I rowsort
SELECT cor0.col2 * col2 + - 24 FROM tab2 cor0
----
1420
652
705

query I rowsort
SELECT ALL col0 * 99 AS col1 FROM tab2 AS cor0
----
693
7722
7821

query I rowsort
SELECT + cor0.col0 * - col2 + + col0 * col0 FROM tab0 AS cor0
----
-216
1190
623

query I rowsort
SELECT ALL + col0 * + col1 * + cor0.col1 AS col0 FROM tab0 AS cor0
----
177504
329315
737009

query I rowsort
SELECT col0 * + ( - 62 ) AS col0 FROM tab1
----
-186
-3968
-4960

query I rowsort
SELECT DISTINCT + - col1 + - col2 AS col2 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT ALL + col1 * + cor0.col2 + col1 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5531
SELECT DISTINCT - col0 - + CAST( NULL AS SIGNED ) * col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5531
SELECT DISTINCT - col0 - + CAST ( NULL AS INTEGER ) * col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - cor0.col0 + col1 * + cor0.col0 AS col2 FROM tab0 cor0
----
2040
3360
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-5533
SELECT ALL - - col1 DIV col1 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5533
SELECT ALL - - col1 / col1 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + - col1 + - col0 AS col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL col0 + + col0 * 51 AS col0 FROM tab2
----
364
4056
4108

query I rowsort
SELECT ALL + + cor0.col1 * col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-5537
SELECT DISTINCT + + col1 DIV + col0 FROM tab2 AS cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-5537
SELECT DISTINCT + + col1 / + col0 FROM tab2 AS cor0
----
0
4

query I rowsort
SELECT ALL col0 + 79 FROM tab2 AS cor0
----
157
158
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 + col1 * - col1 col0 FROM tab1 AS cor0
----
-43
-622
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-5540
SELECT + - col2 + 15 DIV + col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-5540
SELECT + - col2 + 15 / + col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + 84 FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1
----
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 52 col2 FROM tab0 cor0
----
134
53
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5543
SELECT DISTINCT - cor0.col1 * + CAST( NULL AS SIGNED ) AS col0 FROM tab1, tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5543
SELECT DISTINCT - cor0.col1 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab1, tab1 cor0
----
NULL

query I rowsort
SELECT + cor0.col2 + - cor0.col1 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to ae0eeb942db3f01544a81804e95e971a

query I rowsort
SELECT + 25 * cor0.col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 4eb0abec54c1f4b900ce137796f96cee

query I rowsort
SELECT DISTINCT 58 FROM tab1, tab1 AS cor0
----
58

query I rowsort
SELECT cor0.col1 + + col0 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT ( - col0 ) + + ( + col1 + + col2 ) FROM tab0
----
63
84
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-5549
SELECT + - col2 * + 58 + - col2 DIV - col1 FROM tab0 AS cor0
----
-1914
-4756
-58

skipif mysql # not compatible
query I rowsort label-5549
SELECT + - col2 * + 58 + - col2 / - col1 FROM tab0 AS cor0
----
-1914
-4756
-58

query I rowsort
SELECT DISTINCT + 55 * cor0.col0 AS col0 FROM tab2 AS cor0
----
385
4290
4345

query I rowsort
SELECT DISTINCT + 47 FROM tab0, tab1 cor0
----
47

query I rowsort
SELECT col2 + 14 FROM tab2 AS cor0
----
40
41
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab1.col1 col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT cor0.col0 * cor0.col2 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + - 62 * - col2 FROM tab0 cor0
----
2046
5084
62

query I rowsort
SELECT col1 * - col2 FROM tab2 WHERE ( - col1 ) NOT IN ( - col0 )
----
-1534
-646
-837

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT ( NULL ) > - col1 * col1 - col1
----

query I rowsort
SELECT tab2.col0 - col2 AS col2 FROM tab2 WHERE col0 * - col2 IN ( - col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5559
SELECT + col1 + col1 DIV col0 + col2 FROM tab0
----
100
122
174

skipif mysql # not compatible
query I rowsort label-5559
SELECT + col1 + col1 / col0 + col2 FROM tab0
----
100
122
174

query I rowsort
SELECT - 33 * - col2 FROM tab1
----
1782
1881
3168

query I rowsort
SELECT DISTINCT tab0.col2 + + col0 * tab0.col1 FROM tab0
----
2097
3396
8181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 10 * col0 col1 FROM tab2
----
70
780
790

query I rowsort
SELECT ALL + col1 * - col1 + + cor0.col1 + + col0 FROM tab0 AS cor0
----
-7286
-8101
-9277

query I rowsort
SELECT ALL - ( - col0 ) AS col0 FROM tab0
----
24
35
89

query I rowsort
SELECT DISTINCT 24 * + col2 + + 46 FROM tab1 AS cor0
----
1342
1414
2350

query I rowsort
SELECT - 23 AS col1 FROM tab0 AS cor0
----
-23
-23
-23

query I rowsort
SELECT ALL 6 AS col0 FROM tab0
----
6
6
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5568
SELECT - - CAST( NULL AS SIGNED ) / 96 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5568
SELECT - - CAST ( NULL AS INTEGER ) / 96 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5569
SELECT ALL + 77 DIV + tab0.col1 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5569
SELECT ALL + 77 / + tab0.col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT + col0 + col1 * + col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT - - col2 + col1 * col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT col0 + 38 + - col1 AS col0 FROM tab0 cor0
----
-24
-24
36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5573
SELECT - - col1 * - CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5573
SELECT - - col1 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + - 13 * - 53 - col2 AS col0 FROM tab0
----
689

query I rowsort
SELECT ALL tab2.col0 * col2 - + tab2.col2 FROM tab2
----
162
2002
2964

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5576
SELECT ALL + col2 + + CAST( NULL AS SIGNED ) - - col0 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5576
SELECT ALL + col2 + + CAST ( NULL AS INTEGER ) - - col0 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - 42 col0 FROM tab2 AS cor0
----
1092
1134
1596

query I rowsort
SELECT DISTINCT cor0.col1 * ( - 76 ) FROM tab0 AS cor0
----
-6536
-6916
-7372

query I rowsort
SELECT + col0 * 28 FROM tab0 AS cor0
----
2492
672
980

query I rowsort
SELECT DISTINCT + 0 AS col1 FROM tab0, tab2, tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT tab0.col0 * col0 + col0 AS col2 FROM tab0
----
1260
600
8010

query I rowsort
SELECT + 93 + col0 AS col0 FROM tab2
----
100
171
172

query I rowsort
SELECT - ( + col2 ) + + col2 FROM tab1
----
0
0
0

query I rowsort
SELECT tab2.col0 + col2 AS col1 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL - ( - col1 * + col1 ) FROM tab0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 92 col0 FROM tab2 AS cor0
----
-92
-92
-92

query I rowsort
SELECT + col2 * + 36 + col0 AS col2 FROM tab1 AS cor0
----
1947
2116
3536

query I rowsort
SELECT - - ( - col2 ) * - col1 + col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT - ( cor0.col1 ) * - col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT + col1 + col2 AS col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT + - 25 * col2 AS col0 FROM tab1 AS cor0
----
-1350
-1425
-2400

query I rowsort
SELECT - 50 * col2 FROM tab1 AS cor0
----
-2700
-2850
-4800

query I rowsort
SELECT DISTINCT - 17 FROM tab2, tab0, tab1 AS cor0
----
-17

query I rowsort
SELECT + ( col0 ) AS col1 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT - 45 + + col1 FROM tab2 AS cor0
----
-14
-28
14

query I rowsort
SELECT ALL - - 35 * col1 * col2 AS col0 FROM tab2 AS cor0
----
22610
29295
53690

query I rowsort
SELECT DISTINCT 72 * col1 FROM tab1 AS cor0
----
1872
720
936

onlyif mysql # use DIV operator for integer division
query I rowsort label-5598
SELECT DISTINCT + col2 DIV + cor0.col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-5598
SELECT DISTINCT + col2 / + cor0.col1 FROM tab1 AS cor0
----
2
5
7

query I rowsort
SELECT ALL col1 * + cor0.col2 AS col2 FROM tab1 cor0
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-5600
SELECT ALL + col1 DIV + col0 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-5600
SELECT ALL + col1 / + col0 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT DISTINCT - col2 * + col0 * col1 + + cor0.col1 * col0 FROM tab1 AS cor0
----
-35840
-4134
-98800

query I rowsort
SELECT ALL - - col2 * col0 - + col1 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT DISTINCT col1 * cor0.col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT + col2 * col1 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT ALL - + cor0.col2 * + col1 + + col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL - tab1.col1 * col1 AS col2 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT col2 + - col1 * col0 AS col2 FROM tab1 cor0
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-5608
SELECT - col0 DIV cor0.col2 + - col1 AS col2 FROM tab1 AS cor0
----
-11
-13
-26

skipif mysql # not compatible
query I rowsort label-5608
SELECT - col0 / cor0.col2 + - col1 AS col2 FROM tab1 AS cor0
----
-11
-13
-26

query I rowsort
SELECT ALL 34 * col2 AS col2 FROM tab0
----
1122
2788
34

query I rowsort
SELECT DISTINCT tab2.col0 FROM tab2, tab1 cor0
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 53 col2 FROM tab1 AS cor0
----
-53

query I rowsort
SELECT DISTINCT col1 + + col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL - + 24 * - col0 * col2 AS col2 FROM tab0 AS cor0
----
175152
19008
840

onlyif mysql # use DIV operator for integer division
query I rowsort label-5614
SELECT ALL + 7 + cor0.col0 DIV col1 AS col2 FROM tab2 AS cor0
----
11
7
8

skipif mysql # not compatible
query I rowsort label-5614
SELECT ALL + 7 + cor0.col0 / col1 AS col2 FROM tab2 AS cor0
----
11
7
8

query I rowsort
SELECT + col0 * + col0 + + col0 + - col2 * col1 FROM tab2
----
-781
4628
5674

query I rowsort
SELECT 86 * tab1.col0 * col0 + col2 - - col2 * - col1 FROM tab1
----
-576
351743
549248

query I rowsort
SELECT 64 + - col2 FROM tab0
----
-18
31
63

query I rowsort
SELECT col1 * col0 - col1 AS col0 FROM tab2
----
1326
186
4543

query I rowsort
SELECT - 1 + + col1 FROM tab0
----
85
90
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-5620
SELECT DISTINCT + col2 * col2 + - tab2.col0 DIV col1 FROM tab2
----
1440
675
729

skipif mysql # not compatible
query I rowsort label-5620
SELECT DISTINCT + col2 * col2 + - tab2.col0 / col1 FROM tab2
----
1440
675
729

query I rowsort
SELECT DISTINCT ( - 84 ) * col1 + + col1 FROM tab1
----
-1079
-2158
-830

query I rowsort
SELECT DISTINCT + 80 + - col2 * col0 AS col0 FROM tab0 AS cor0
----
-712
-7218
45

query I rowsort
SELECT DISTINCT + - col0 * + col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - + col2 * - cor0.col1 * - cor0.col2 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT + 62 * col1 FROM tab2 AS cor0
----
1054
1922
3658

query I rowsort
SELECT ALL + 48 AS col1 FROM tab2 AS cor0
----
48
48
48

query I rowsort
SELECT col2 * + col2 + col1 + + col1 FROM tab1 cor0
----
2968
3269
9242

query I rowsort
SELECT ALL - 77 + + col1 AS col2 FROM tab1 AS cor0
----
-51
-64
-67

query I rowsort
SELECT DISTINCT + cor0.col0 - + col1 * col2 AS col2 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT col1 + col2 * - col1 + col1 AS col2 FROM tab1 cor0
----
-1222
-1352
-550

query I rowsort
SELECT + col2 * tab1.col0 * tab1.col2 + - col0 FROM tab1
----
207872
737200
8745

query III rowsort
SELECT ALL * FROM tab1 WHERE ( col2 * - col1 + - col2 + + col0 ) > col0 + - col2
----

query I rowsort
SELECT DISTINCT tab2.col1 AS col1 FROM tab2 WHERE ( + col1 ) NOT IN ( + col2 + col1 )
----
17
31
59

query I rowsort
SELECT col1 * - tab1.col2 AS col0 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + col1 + tab0.col2 FROM tab0
----
119
173
98

query I rowsort
SELECT col2 FROM tab1 WHERE ( NULL ) = NULL
----

query I rowsort
SELECT col0 * col2 + + col2 FROM tab2
----
2054
216
3040

query I rowsort
SELECT + col0 * col2 + - col1 * - col0 * + col1 + col1 FROM tab2 AS cor0
----
25850
273605
6947

query I rowsort
SELECT DISTINCT + col1 + col1 * col2 + col2 * - col1 AS col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT col0 + col2 + col0 FROM tab1 cor0
----
185
256
60

query I rowsort
SELECT - col0 * + col1 + col0 AS col0 FROM tab2
----
-1264
-210
-4524

query I rowsort
SELECT DISTINCT + col0 + - col0 FROM tab1 WHERE NOT NULL BETWEEN NULL AND col1 + - col0
----

query I rowsort
SELECT DISTINCT + col0 - - tab0.col2 FROM tab0
----
171
36
57

query I rowsort
SELECT col1 - + tab1.col2 AS col2 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT col2 * col2 + + col2 FROM tab0
----
1122
2
6806

query I rowsort
SELECT col1 + col2 * col0 + col2 AS col0 FROM tab1
----
242
3715
7789

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * - col1 col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + col0 * - col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT col2 + col2 * col2 AS col0 FROM tab2
----
1482
702
756

query I rowsort
SELECT col1 * - col1 AS col1 FROM tab1 WHERE col0 + col1 >= col1
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - + col0 - - col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL + col0 * + col2 + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT + + col0 * + col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT col2 * col2 * col0 AS col1 FROM tab1 WHERE NULL <= NULL
----

query III rowsort
SELECT * FROM tab0 WHERE NULL NOT BETWEEN NULL AND + col0 * - col1 + + col1 + col0
----

query I rowsort
SELECT ALL + col0 * - col0 + col1 * + col2 AS col0 FROM tab2
----
-4550
-5595
788

query I rowsort
SELECT DISTINCT col2 * col0 + - cor0.col1 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT + col0 + + col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT DISTINCT + col1 * cor0.col1 + col1 * col1 FROM tab0 AS cor0
----
14792
16562
18818

query I rowsort
SELECT - - col2 * col0 - col1 * cor0.col1 FROM tab1 AS cor0
----
-514
3548
7511

query I rowsort
SELECT + - cor0.col0 - col2 AS col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT + - col1 * - cor0.col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT cor0.col0 * - cor0.col1 AS col0 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5664
SELECT ALL col0 DIV col0 AS col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5664
SELECT ALL col0 / col0 AS col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT - + col2 - + col2 FROM tab2 AS cor0
----
-52
-54
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-5666
SELECT ALL + col1 * col1 + col2 DIV col1 col0 FROM tab1 AS cor0
----
105
176
678

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5666
SELECT ALL + col1 * col1 + col2 / col1 col0 FROM tab1 AS cor0
----
105
176
678

query I rowsort
SELECT DISTINCT col0 * + col2 + - col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT + col2 - cor0.col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col0 * - cor0.col2 + col2 FROM tab2 AS cor0
----
2054
216
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-5670
SELECT col1 + + col0 * col1 DIV col0 AS col2 FROM tab1 cor0
----
20
26
52

skipif mysql # not compatible
query I rowsort label-5670
SELECT col1 + + col0 * col1 / col0 AS col2 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT + col0 * col0 AS col2 FROM tab2 AS cor0 WHERE NOT col2 IN ( cor0.col1 )
----
49
6084
6241

query I rowsort
SELECT ALL + col0 * cor0.col2 + cor0.col1 * - col1 + + col0 FROM tab0 AS cor0
----
-6580
-894
-9339

query I rowsort
SELECT + col0 + tab2.col2 AS col0 FROM tab2
----
104
117
34

query I rowsort
SELECT - col0 * + tab0.col1 * - tab0.col1 - + col1 AS col0 FROM tab0
----
177418
329218
736918

query I rowsort
SELECT DISTINCT + 58 FROM tab2
----
58

query I rowsort
SELECT - 81 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 205b3ff2d7b1817c98d7980b8c17e6c1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5677
SELECT - CAST( NULL AS SIGNED ) + 42 * col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5677
SELECT - CAST ( NULL AS INTEGER ) + 42 * col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( col0 ) * col0 col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL - cor0.col1 FROM tab2, tab2 cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to b7a1b38fe8e4f34388e3be1f52601ae5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5680
SELECT + CAST( NULL AS SIGNED ) + - col1 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5680
SELECT + CAST ( NULL AS INTEGER ) + - col1 AS col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 75 AS col0 FROM tab2
----
75

query I rowsort
SELECT + col1 - - col0 AS col2 FROM tab1
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5683
SELECT + CAST( NULL AS SIGNED ) + 24 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5683
SELECT + CAST ( NULL AS INTEGER ) + 24 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT ( + 88 ) * - col2 AS col0 FROM tab0
----
-2904
-7216
-88

query I rowsort
SELECT + 13 + col2 FROM tab2 AS cor0
----
39
40
51

query I rowsort
SELECT - col2 + col0 - - 71 AS col1 FROM tab2 cor0
----
112
123
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-5687
SELECT - + col0 * - col1 + ( - col0 ) DIV + col2 AS col1 FROM tab1 AS cor0
----
1040
639
78

skipif mysql # not compatible
query I rowsort label-5687
SELECT - + col0 * - col1 + ( - col0 ) / + col2 AS col1 FROM tab1 AS cor0
----
1040
639
78

query I rowsort
SELECT - col1 * + col0 + 0 * - col0 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT + + 95 FROM tab1 AS cor0
----
95
95
95

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5690
SELECT + - col0 - + col1 * - CAST( col2 AS SIGNED ) * + col2 AS col2 FROM tab2 AS cor0
----
22592
24469
39806

skipif mysql # not compatible
query I rowsort label-5690
SELECT + - col0 - + col1 * - CAST ( col2 AS INTEGER ) * + col2 AS col2 FROM tab2 AS cor0
----
22592
24469
39806

query I rowsort
SELECT - col0 * col1 + 80 FROM tab1 AS cor0
----
-560
-960
2

query I rowsort
SELECT ALL + + 15 FROM tab1 AS cor0
----
15
15
15

query I rowsort
SELECT ALL + - cor0.col0 * col1 * + ( col1 ) FROM tab1 AS cor0
----
-13520
-2028
-6400

query I rowsort
SELECT col2 + + col2 * + 2 AS col2 FROM tab0 AS cor0
----
246
3
99

query I rowsort
SELECT + - col0 * ( col0 ) FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT 99 + 91 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 2d37350b255ef21d1c45b9bd894205c8

query I rowsort
SELECT - col1 * + ( ( + col0 ) ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT col2 * col0 + - col0 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT - cor0.col1 FROM tab1, tab2 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to b7a1b38fe8e4f34388e3be1f52601ae5

query I rowsort
SELECT - col1 * - col1 + col1 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT 51 + 64 FROM tab2 AS cor0
----
115
115
115

query I rowsort
SELECT DISTINCT col1 * - ( - col0 * + col1 + - col1 ) FROM tab0 AS cor0
----
184900
338724
745290

query I rowsort
SELECT ( cor0.col1 ) AS col1 FROM tab1, tab0 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT - ( + 81 ) FROM tab0 AS cor0
----
-81
-81
-81

query I rowsort
SELECT DISTINCT - col2 - - col1 AS col0 FROM tab2 AS cor0
----
-21
33
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5706
SELECT - CAST( col2 AS SIGNED ) * - cor0.col1 AS col2 FROM tab0 AS cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-5706
SELECT - CAST ( col2 AS INTEGER ) * - cor0.col1 AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT + ( 3 ) * + col2 * col1 + cor0.col1 FROM tab1 AS cor0
----
1720
3757
4238

onlyif mysql # use DIV operator for integer division
query I rowsort label-5708
SELECT DISTINCT - - col1 * col0 + - col0 DIV 18 FROM tab2 AS cor0
----
1339
217
4598

skipif mysql # not compatible
query I rowsort label-5708
SELECT DISTINCT - - col1 * col0 + - col0 / 18 FROM tab2 AS cor0
----
1339
217
4598

query I rowsort
SELECT ALL 83 - col2 FROM tab0 AS cor0
----
1
50
82

query I rowsort
SELECT - - 71 * + col0 FROM tab2 cor0
----
497
5538
5609

query I rowsort
SELECT ALL - 24 + col1 FROM tab2 AS cor0
----
-7
35
7

query I rowsort
SELECT DISTINCT - col1 + 53 * + col2 AS col2 FROM tab2 AS cor0
----
1319
1400
1997

query I rowsort
SELECT - + 39 * - col1 + col0 FROM tab2 AS cor0
----
1216
2379
742

query I rowsort
SELECT 61 + 76 FROM tab1 AS cor0
----
137
137
137

onlyif mysql # use DIV operator for integer division
query I rowsort label-5715
SELECT ALL + col0 * + col0 + col2 + ( + 93 ) DIV col2 col0 FROM tab1 AS cor0
----
4154
64
6496

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5715
SELECT ALL + col0 * + col0 + col2 + ( + 93 ) / col2 col0 FROM tab1 AS cor0
----
4154
64
6496

query I rowsort
SELECT DISTINCT - col1 + - col0 * col2 FROM tab0 AS cor0
----
-132
-7389
-878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + cor0.col1 * col2 col1 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-5718
SELECT DISTINCT + col1 DIV + col1 AS col2 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-5718
SELECT DISTINCT + col1 / + col1 AS col2 FROM tab0 AS cor0
----
1

query I rowsort
SELECT - 16 AS col2 FROM tab2 cor0
----
-16
-16
-16

query I rowsort
SELECT - cor0.col1 * ( + col2 * col2 ) FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT + + col0 * - 15 AS col2 FROM tab1 cor0
----
-1200
-45
-960

query I rowsort
SELECT ALL + ( + col1 ) + col1 * 15 FROM tab0 AS cor0
----
1376
1456
1552

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5723
SELECT CAST( col1 AS SIGNED ) + + col0 * 86 FROM tab2 AS cor0
----
633
6767
6811

skipif mysql # not compatible
query I rowsort label-5723
SELECT CAST ( col1 AS INTEGER ) + + col0 * 86 FROM tab2 AS cor0
----
633
6767
6811

query I rowsort
SELECT DISTINCT + + 13 + - cor0.col2 * cor0.col2 + col0 AS col1 FROM tab1 AS cor0
----
-2900
-3172
-9123

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5725
SELECT ALL + + CAST( 30 AS SIGNED ) - + col0 * - col2 AS col1 FROM tab2 cor0
----
2058
219
3032

skipif mysql # not compatible
query I rowsort label-5725
SELECT ALL + + CAST ( 30 AS INTEGER ) - + col0 * - col2 AS col1 FROM tab2 cor0
----
2058
219
3032

query I rowsort
SELECT ALL + 19 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 3dac30dc82c9e5acbbd3a5c5d1aeee11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5727
SELECT + cor0.col2 * - CAST( NULL AS SIGNED ) + 35 AS col0 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5727
SELECT + cor0.col2 * - CAST ( NULL AS INTEGER ) + 35 AS col0 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL ( - col2 ) + + col1 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5729
SELECT ALL - cor0.col1 * + CAST( NULL AS SIGNED ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5729
SELECT ALL - cor0.col1 * + CAST ( NULL AS INTEGER ) AS col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + col1 + + ( + 99 ) AS col1 FROM tab1 AS cor0
----
73
86
89

query I rowsort
SELECT + - col0 - - col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT - + col1 * - ( cor0.col1 * cor0.col0 ) + - 82 * col0 FROM tab1 AS cor0
----
1152
1782
6960

query I rowsort
SELECT DISTINCT col2 - col0 * - 73 AS col1 FROM tab0
----
1785
2556
6579

query I rowsort
SELECT + 73 * + col0 FROM tab1
----
219
4672
5840

query I rowsort
SELECT col2 + + col2 * + tab1.col2 * tab1.col1 AS col2 FROM tab1
----
119904
32547
75870

query I rowsort
SELECT DISTINCT 21 - - col2 AS col0 FROM tab0
----
103
22
54

query I rowsort
SELECT + tab2.col1 * - col0 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT 14 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
14

query I rowsort
SELECT DISTINCT + col2 + + col1 AS col1 FROM tab1
----
109
67
80

query I rowsort
SELECT - 81 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to d0bfe8494f52235d9fcafb5ac5de3f81

query I rowsort
SELECT ALL col2 * + col0 + col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT - col0 * col1 + - col1 AS col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT ALL - - col1 - - ( col0 ) * cor0.col1 FROM tab1 AS cor0
----
104
1053
650

query IIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0 WHERE NULL < NULL
----

query I rowsort
SELECT 81 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 0a85639e0dddbffdab2cb16b027cb360

onlyif mysql # use DIV operator for integer division
query I rowsort label-5746
SELECT + - col2 DIV col0 + col1 AS col2 FROM tab0 cor0
----
85
91
97

skipif mysql # not compatible
query I rowsort label-5746
SELECT + - col2 / col0 + col1 AS col2 FROM tab0 cor0
----
85
91
97

query I rowsort
SELECT + 5 * - col1 FROM tab1
----
-130
-50
-65

onlyif mysql # use DIV operator for integer division
query I rowsort label-5748
SELECT - col2 * + col1 DIV - col1 + - col2 + col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-5748
SELECT - col2 * + col1 / - col1 + - col2 + col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL + + col1 + + col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT + ( - col0 ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT 51 * col1 + + col0 + col2 AS col2 FROM tab1 AS cor0
----
1383
631
839

query I rowsort
SELECT DISTINCT + col1 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5753
SELECT DISTINCT + col1 + col0 * + ( + col0 * + col2 ) + + 31 * col1 DIV + col0 AS col2 FROM tab1 cor0
----
233486
614418
780

skipif mysql # not compatible
query I rowsort label-5753
SELECT DISTINCT + col1 + col0 * + ( + col0 * + col2 ) + + 31 * col1 / + col0 AS col2 FROM tab1 cor0
----
233486
614418
780

query I rowsort
SELECT - + 73 + - col0 + 77 * - col2 FROM tab0 AS cor0
----
-185
-2638
-6476

onlyif mysql # use DIV operator for integer division
query I rowsort label-5755
SELECT DISTINCT - col0 + - cor0.col2 DIV + 62 - ( + col1 ) AS col2 FROM tab0 AS cor0
----
-110
-132
-181

skipif mysql # not compatible
query I rowsort label-5755
SELECT DISTINCT - col0 + - cor0.col2 / + 62 - ( + col1 ) AS col2 FROM tab0 AS cor0
----
-110
-132
-181

query I rowsort
SELECT - col1 * - col1 + + col2 AS col1 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT DISTINCT + col2 + cor0.col2 * cor0.col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL - - col1 * col2 * 72 AS col0 FROM tab0 AS cor0
----
204336
537264
6984

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * ( + col1 ) col0 FROM tab2 AS cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-5760
SELECT DISTINCT + + cor0.col0 DIV - col1 col2 FROM tab1 AS cor0
----
-6
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5760
SELECT DISTINCT + + cor0.col0 / - col1 col2 FROM tab1 AS cor0
----
-6
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5761
SELECT ALL col1 DIV - col1 AS col1 FROM tab2 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-5761
SELECT ALL col1 / - col1 AS col1 FROM tab2 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5762
SELECT col1 + ( 30 ) DIV col1 col0 FROM tab2 AS cor0
----
18
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5762
SELECT col1 + ( 30 ) / col1 col0 FROM tab2 AS cor0
----
18
31
59

query I rowsort
SELECT ALL 5 FROM tab0
----
5
5
5

query I rowsort
SELECT ALL col2 * + tab2.col0 FROM tab2
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5765
SELECT col0 + + CAST( NULL AS SIGNED ) * col0 * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5765
SELECT col0 + + CAST ( NULL AS INTEGER ) * col0 * - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor1.col1 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab0, tab1 AS cor2
----
243 values hashing to c6425afc100dd55de8d45dec18c469ea

query I rowsort
SELECT ALL + col1 + + cor0.col1 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5768
SELECT DISTINCT - CAST( ( col2 ) AS SIGNED ) * 93 DIV col1 + - col0 * - col1 - - col2 * cor0.col2 DIV ( 57 ) col0 FROM tab2 AS cor0
----
1161
148
4573

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5768
SELECT DISTINCT - CAST ( ( col2 ) AS INTEGER ) * 93 / col1 + - col0 * - col1 - - col2 * cor0.col2 / ( 57 ) col0 FROM tab2 AS cor0
----
1161
148
4573

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5769
SELECT ALL col0 * col0 + + col1 * + CAST( col2 AS SIGNED ) * + col0 + - col0 AS col1 FROM tab2 AS cor0
----
125658
57196
5901

skipif mysql # not compatible
query I rowsort label-5769
SELECT ALL col0 * col0 + + col1 * + CAST ( col2 AS INTEGER ) * + col0 + - col0 AS col1 FROM tab2 AS cor0
----
125658
57196
5901

query I rowsort
SELECT DISTINCT - col2 + 7 AS col1 FROM tab2 AS cor0
----
-19
-20
-31

query I rowsort
SELECT - col1 + ( + col2 * + col2 ) AS col1 FROM tab2 cor0
----
1427
617
698

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * col1 + col2 col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT cor0.col2 - 73 FROM tab2 AS cor0
----
-35
-46
-47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5774
SELECT + + CAST( NULL AS SIGNED ) - 11 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5774
SELECT + + CAST ( NULL AS INTEGER ) - 11 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col2 - ( 62 ) FROM tab1
----
-5
-8
34

query I rowsort
SELECT 33 - + 71 * - col1 AS col1 FROM tab2 cor0
----
1240
2234
4222

query I rowsort
SELECT ALL - 28 + col2 * + cor0.col0 FROM tab0 AS cor0
----
7
7270
764

query I rowsort
SELECT DISTINCT + col2 * ( col1 + col2 ) * - cor0.col1 FROM tab2 AS cor0
----
-130390
-35530
-48546

query I rowsort
SELECT cor1.col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 + 41 col0 FROM tab2 cor0
----
14
15
3

query I rowsort
SELECT ALL + ( - col1 ) + + col0 * 85 FROM tab0
----
1954
2878
7474

query I rowsort
SELECT + 19 * cor0.col1 + - ( + cor0.col1 + col0 ) FROM tab1 AS cor0
----
116
154
465

query I rowsort
SELECT - + 78 + - col2 FROM tab0 AS cor0
----
-111
-160
-79

query I rowsort
SELECT ALL - col0 * + cor0.col0 + 15 FROM tab2 AS cor0
----
-34
-6069
-6226

onlyif mysql # use DIV operator for integer division
query I rowsort label-5785
SELECT - col1 DIV + col2 + col1 AS col2 FROM tab0 cor0
----
0
84
90

skipif mysql # not compatible
query I rowsort label-5785
SELECT - col1 / + col2 + col1 AS col2 FROM tab0 cor0
----
0
84
90

query I rowsort
SELECT DISTINCT col1 * - col2 + 12 * cor0.col2 FROM tab1 cor0
----
-756
-96
114

query I rowsort
SELECT DISTINCT 38 * col1 + + col1 * + col0 AS col2 FROM tab1
----
1020
1066
1534

query I rowsort
SELECT + 99 + + tab0.col1 * - tab0.col2 AS col1 FROM tab0
----
-2739
-7363
2

query I rowsort
SELECT 32 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5790
SELECT CAST( NULL AS DECIMAL ) * + col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5790
SELECT CAST ( NULL AS REAL ) * + col1 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5791
SELECT + CAST( NULL AS DECIMAL ) FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5791
SELECT + CAST ( NULL AS REAL ) FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 col1 FROM tab0, tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - 82 * + col2 + col0 * 45 AS col0 FROM tab2
----
-1899
1378
439

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5794
SELECT ALL + + CAST( NULL AS SIGNED ) + 0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5794
SELECT ALL + + CAST ( NULL AS INTEGER ) + 0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT 82 + + tab1.col1 FROM tab1, tab2 AS cor0
----
9 values hashing to d88509c45faba61ac429014690d9a955

query I rowsort
SELECT ALL - 62 + - col2 + + col0 AS col2 FROM tab0
----
-28
-55
-71

query I rowsort
SELECT + col0 + 97 FROM tab0
----
121
132
186

query I rowsort
SELECT - 97 + - col1 AS col0 FROM tab1 AS cor0
----
-107
-110
-123

query I rowsort
SELECT + 66 + col2 FROM tab1 AS cor0
----
120
123
162

query I rowsort
SELECT + - col1 + - cor0.col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT - 77 + col2 AS col2 FROM tab0
----
-44
-76
5

query I rowsort
SELECT DISTINCT ( col0 ) * col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT + 20 FROM tab2
----
20

query I rowsort
SELECT ALL + ( + col2 ) * col2 + - ( col2 + - 72 ) * col1 FROM tab0 AS cor0
----
4443
5814
6888

query I rowsort
SELECT col1 + - col1 * + 18 AS col1 FROM tab2 AS cor0
----
-1003
-289
-527

query I rowsort
SELECT ALL + 39 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT DISTINCT 78 AS col0 FROM tab0, tab2 AS cor0
----
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5808
SELECT ALL + col1 * - CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5808
SELECT ALL + col1 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 97 + - 49 FROM tab2 AS cor0
----
48
48
48

query I rowsort
SELECT - - 21 * + col2 FROM tab1 AS cor0
----
1134
1197
2016

query I rowsort
SELECT DISTINCT + col1 * + 23 FROM tab1
----
230
299
598

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - ( - tab0.col2 ) col2 FROM tab0
----
164
2
66

query I rowsort
SELECT DISTINCT 72 FROM tab1, tab2 AS cor0
----
72

query I rowsort
SELECT + - col2 * ( + cor0.col2 ) FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-5815
SELECT ALL tab1.col2 DIV + ( 54 ) AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5815
SELECT ALL tab1.col2 / + ( 54 ) AS col1 FROM tab1
----
1
1
1

query I rowsort
SELECT ALL 71 * - col2 FROM tab1 AS cor0
----
-3834
-4047
-6816

query I rowsort
SELECT ALL - 65 + col2 * + col2 FROM tab0 AS cor0
----
-64
1024
6659

query I rowsort
SELECT DISTINCT col1 + ( col1 + - col0 ) AS col1 FROM tab1
----
-44
-54
49

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 2 col0 FROM tab2 AS cor0
----
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5820
SELECT - ( col2 ) * + col0 - - CAST( NULL AS DECIMAL ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5820
SELECT - ( col2 ) * + col0 - - CAST ( NULL AS REAL ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - 10 * col0 + + col0 + 85 FROM tab2 AS cor0
----
-617
-626
22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 * - col2 * col0 col1 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT tab0.col1 * + cor0.col1 FROM tab0, tab2 cor0
----
9 values hashing to 73681df8216070e2d6c1ade2e7109825

onlyif mysql # use DIV operator for integer division
query I rowsort label-5824
SELECT + + col0 + - col0 DIV cor0.col1 AS col0 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-5824
SELECT + + col0 + - col0 / cor0.col1 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + + cor0.col2 * 42 FROM tab1 AS cor0
----
2268
2394
4032

query I rowsort
SELECT col2 * col1 * + col0 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT + 33 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 76da8bc7cae18ecf856438f872430c80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5828
SELECT DISTINCT + 62 * - col2 + CAST( NULL AS DECIMAL ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-5828
SELECT DISTINCT + 62 * - col2 + CAST ( NULL AS REAL ) FROM tab1
----
NULL

query I rowsort
SELECT ALL tab2.col1 + cor0.col0 AS col1 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to fb2b158ca696b002ae715f5398137fc3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - cor0.col0 col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT - col2 + - ( - col2 ) FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL tab1.col1 * + col2 * - col1 AS col1 FROM tab1
----
-16224
-36504
-5700

query I rowsort
SELECT DISTINCT + 35 FROM tab2
----
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5834
SELECT + CAST( NULL AS SIGNED ) * - col2 - - col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5834
SELECT + CAST ( NULL AS INTEGER ) * - col2 - - col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5835
SELECT 79 + col1 + col0 DIV + 57 AS col2 FROM tab0 AS cor0
----
165
171
176

skipif mysql # not compatible
query I rowsort label-5835
SELECT 79 + col1 + col0 / + 57 AS col2 FROM tab0 AS cor0
----
165
171
176

query I rowsort
SELECT - + col0 * col2 + - col0 + cor0.col2 FROM tab1 AS cor0
----
-111
-3655
-7664

query I rowsort
SELECT + - 83 + 61 FROM tab2 AS cor0
----
-22
-22
-22

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 94 col0 FROM tab2 AS cor0
----
94
94
94

query I rowsort
SELECT ALL col1 + + 4 * col1 AS col2 FROM tab0 AS cor0
----
430
455
485

query I rowsort
SELECT DISTINCT + col0 + + col2 * + col0 + - 39 * + col1 FROM tab1 AS cor0
----
-849
3322
7253

query I rowsort
SELECT + col2 + - ( + cor0.col1 ) AS col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT + - ( + col0 ) * + cor0.col2 FROM tab0 cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5843
SELECT + cor0.col0 + + col2 * ( - col2 ) + col2 DIV cor0.col2 FROM tab1 AS cor0
----
-2912
-3184
-9135

skipif mysql # not compatible
query I rowsort label-5843
SELECT + cor0.col0 + + col2 * ( - col2 ) + col2 / cor0.col2 FROM tab1 AS cor0
----
-2912
-3184
-9135

query I rowsort
SELECT + + 29 + - col1 AS col2 FROM tab0 AS cor0
----
-57
-62
-68

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0, tab2 AS cor1, tab0, tab2 cor2
----
3645 values hashing to 59ca7c96f3955e014bebd08b5442edff

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 39 col2 FROM tab2
----
39

query I rowsort
SELECT - col1 * col0 + 86 AS col1 FROM tab1 AS cor0
----
-554
-954
8

query I rowsort
SELECT - 22 + cor0.col0 + col1 AS col1 FROM tab2 AS cor0
----
115
16
74

onlyif mysql # use DIV operator for integer division
query I rowsort label-5849
SELECT ALL col1 DIV tab2.col1 + tab2.col2 * + ( + col0 ) FROM tab2
----
190
2029
3003

skipif mysql # not compatible
query I rowsort label-5849
SELECT ALL col1 / tab2.col1 + tab2.col2 * + ( + col0 ) FROM tab2
----
190
2029
3003

query I rowsort
SELECT + + 1 * - col1 FROM tab2 cor0
----
-17
-31
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab0.col2 * - col0 + 67 col1 FROM tab0
----
-7231
-725
32

query I rowsort
SELECT ALL - + col1 * + col0 AS col2 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + + col1 * cor0.col1 * + 40 + 94 * + cor0.col1 + ( + col0 + cor0.col1 ) AS col1 FROM tab2 AS cor0
----
13254
144923
41392

query I rowsort
SELECT DISTINCT - - col2 * col2 + cor0.col2 AS col1 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT ALL ( col0 ) + col2 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL col1 * - col2 AS col0 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT + 77 - cor0.col2 * cor0.col0 AS col1 FROM tab0 AS cor0
----
-715
-7221
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-5858
SELECT DISTINCT - col2 DIV - col0 + col2 AS col0 FROM tab2 AS cor0
----
26
30
38

skipif mysql # not compatible
query I rowsort label-5858
SELECT DISTINCT - col2 / - col0 + col2 AS col0 FROM tab2 AS cor0
----
26
30
38

query I rowsort
SELECT - 30 * col1 + 72 AS col2 FROM tab2 AS cor0
----
-1698
-438
-858

query I rowsort
SELECT ALL + - cor0.col1 + - cor0.col1 AS col1 FROM tab2 cor0
----
-118
-34
-62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col1 + cor0.col1 col0 FROM tab0 AS cor0
----
7482
8372
9506

query I rowsort
SELECT DISTINCT + 19 AS col2 FROM tab0, tab2 AS cor0, tab1 cor1
----
19

query I rowsort
SELECT + + col1 * - 1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT - col1 * col2 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - cor0.col2 + + ( + cor0.col0 ) + col1 FROM tab1 AS cor0
----
-25
-3
17

query I rowsort
SELECT + ( cor0.col0 ) * cor1.col1 FROM tab2 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 7bf5e0e3ec1be8bea20f7ba84b6c99c3

query I rowsort
SELECT ALL col2 * + col1 AS col0 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT - ( - cor0.col2 ) + - col1 * - cor0.col1 AS col0 FROM tab0 AS cor0
----
7429
8363
9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col0 + col1 col1 FROM tab2 AS cor0
----
-18
-6025
-6224

onlyif mysql # use DIV operator for integer division
query I rowsort label-5870
SELECT ALL + col0 DIV col1 FROM tab1 cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-5870
SELECT ALL + col0 / col1 FROM tab1 cor0
----
0
6
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5871
SELECT ALL - CAST( NULL AS SIGNED ) * - ( - cor0.col2 ) + 41 + + col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5871
SELECT ALL - CAST ( NULL AS INTEGER ) * - ( - cor0.col2 ) + 41 + + col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + 73 - - col2 AS col2 FROM tab1 AS cor0
----
-16
-19
23

query I rowsort
SELECT DISTINCT - ( col0 ) * + tab1.col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL - 66 AS col0 FROM tab0 AS cor0
----
-66
-66
-66

query I rowsort
SELECT ALL col2 - - col0 * cor0.col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT + - cor0.col1 + col0 * + 73 AS col2 FROM tab2 AS cor0
----
480
5635
5750

onlyif mysql # use DIV operator for integer division
query I rowsort label-5877
SELECT DISTINCT - + col1 * col0 DIV col2 + col2 * col1 + 35 AS col1 FROM tab1 AS cor0
----
1273
1438
594

skipif mysql # not compatible
query I rowsort label-5877
SELECT DISTINCT - + col1 * col0 / col2 + col2 * col1 + 35 AS col1 FROM tab1 AS cor0
----
1273
1438
594

query I rowsort
SELECT DISTINCT - cor0.col2 AS col2 FROM tab1, tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT ALL + tab2.col1 - + 67 AS col2 FROM tab2
----
-36
-50
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5880
SELECT CAST( NULL AS SIGNED ) * - 88 + - col2 * - col0 * col0 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5880
SELECT CAST ( NULL AS INTEGER ) * - 88 + - col2 * - col0 * col0 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 - + 37 * - col1 * col2 AS col1 FROM tab2
----
23940
30996
56784

query I rowsort
SELECT - col0 + - col0 + + col2 * col2 AS col2 FROM tab0
----
-69
1041
6546

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab0 cor2
----
972 values hashing to 86dbd337f00ab84c613ad03d6fc06e28

query I rowsort
SELECT ALL col1 + - col0 AS col1 FROM tab0
----
2
62
62

query I rowsort
SELECT + + 14 * col0 FROM tab1 AS cor0
----
1120
42
896

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col1 col2 FROM tab2
----
-21
33
4

query I rowsort
SELECT + col0 + + col2 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT DISTINCT - 96 * - 32 FROM tab1 AS cor0
----
3072

query I rowsort
SELECT ALL - cor0.col0 + cor0.col2 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5890
SELECT + CAST( NULL AS SIGNED ) * - col1 * - col1 + + 58 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5890
SELECT + CAST ( NULL AS INTEGER ) * - col1 * - col1 + + 58 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 55 FROM tab1, tab2 cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT ALL + - 66 AS col2 FROM tab0 AS cor0
----
-66
-66
-66

query I rowsort
SELECT - cor0.col1 * - cor0.col2 + + col0 AS col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL 60 * - col1 AS col2 FROM tab2 AS cor0
----
-1020
-1860
-3540

query I rowsort
SELECT + - col2 + col1 * cor0.col2 AS col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT ALL + + 60 + - ( col1 ) * + col1 AS col0 FROM tab0 AS cor0
----
-7336
-8221
-9349

query I rowsort
SELECT + - 79 AS col2 FROM tab2 AS cor0
----
-79
-79
-79

query I rowsort
SELECT ALL + col2 * + tab0.col1 AS col2 FROM tab0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + + col0 col1 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + cor0.col0 * - col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT ( + col1 ) * - 61 AS col0 FROM tab2 AS cor0
----
-1037
-1891
-3599

query I rowsort
SELECT ALL col1 * col2 + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL - - col1 * - col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-5904
SELECT col0 DIV + 55 + - col0 FROM tab1 AS cor0
----
-3
-63
-79

skipif mysql # not compatible
query I rowsort label-5904
SELECT col0 / + 55 + - col0 FROM tab1 AS cor0
----
-3
-63
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 col2 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5906
SELECT - col0 / CAST( NULL AS SIGNED ) + + cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5906
SELECT - col0 / CAST ( NULL AS INTEGER ) + + cor0.col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col0 + 88 * + col0 FROM tab0 AS cor0
----
2136
3115
7921

query I rowsort
SELECT DISTINCT + + col0 + col0 * + cor0.col1 AS col2 FROM tab1 cor0
----
1120
704
81

query I rowsort
SELECT + col0 - - cor0.col0 * col2 FROM tab0 cor0
----
70
7387
816

query I rowsort
SELECT + col2 * 23 * cor0.col1 FROM tab0 AS cor0
----
171626
2231
65274

onlyif mysql # use DIV operator for integer division
query I rowsort label-5911
SELECT DISTINCT + col2 * col2 DIV + 47 AS col0 FROM tab0 AS cor0
----
0
143
23

skipif mysql # not compatible
query I rowsort label-5911
SELECT DISTINCT + col2 * col2 / + 47 AS col0 FROM tab0 AS cor0
----
0
143
23

query I rowsort
SELECT ALL + - cor0.col1 + 8 FROM tab0 AS cor0
----
-78
-83
-89

query I rowsort
SELECT DISTINCT + col0 + col2 AS col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - col2 * 2 AS col2 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT ALL col0 * col0 + + col2 - col1 * col1 FROM tab2
----
-885
2629
5990

onlyif mysql # use DIV operator for integer division
query I rowsort label-5916
SELECT col2 * col2 - 77 DIV + col1 AS col0 FROM tab0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-5916
SELECT col2 * col2 - 77 / + col1 AS col0 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL + col1 * col0 + - cor0.col2 FROM tab0 AS cor0
----
2031
3394
8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-5918
SELECT col2 DIV 33 + + col2 AS col0 FROM tab0 AS cor0
----
1
34
84

skipif mysql # not compatible
query I rowsort label-5918
SELECT col2 / 33 + + col2 AS col0 FROM tab0 AS cor0
----
1
34
84

query I rowsort
SELECT ALL + col0 + 55 AS col2 FROM tab1 AS cor0
----
119
135
58

query I rowsort
SELECT DISTINCT + col1 + + tab2.col2 - - col1 FROM tab2
----
144
72
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-5921
SELECT + col1 * col0 - 4 * col0 DIV + tab0.col2 FROM tab0
----
2062
3255
8095

skipif mysql # not compatible
query I rowsort label-5921
SELECT + col1 * col0 - 4 * col0 / + tab0.col2 FROM tab0
----
2062
3255
8095

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5922
SELECT DISTINCT + col2 / + col2 - CAST( NULL AS SIGNED ) FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-5922
SELECT DISTINCT + col2 / + col2 - CAST ( NULL AS INTEGER ) FROM tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5923
SELECT ALL + + col2 + + cor0.col0 DIV ( - col0 + - 65 ) FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5923
SELECT ALL + + col2 + + cor0.col0 / ( - col0 + - 65 ) FROM tab2 AS cor0
----
26
27
38

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab2 cor0, tab2 AS cor1, tab1 AS cor2
----
972 values hashing to 263f0eb7d5dfd4076c74918bc141bd9b

query I rowsort
SELECT DISTINCT col2 * + 6 AS col0 FROM tab2 AS cor0
----
156
162
228

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5926
SELECT - - col2 + - CAST( NULL AS DECIMAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5926
SELECT - - col2 + - CAST ( NULL AS REAL ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5927
SELECT - col2 DIV - col2 AS col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5927
SELECT - col2 / - col2 AS col0 FROM tab1
----
1
1
1

query I rowsort
SELECT ALL tab1.col1 + 15 * 74 FROM tab1
----
1120
1123
1136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5929
SELECT - CAST( NULL AS SIGNED ) * 52 + cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5929
SELECT - CAST ( NULL AS INTEGER ) * 52 + cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 29 * - cor0.col2 FROM tab1 AS cor0
----
1566
1653
2784

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 + 17 col0 FROM tab2
----
24
95
96

query I rowsort
SELECT - tab0.col2 * ( - tab0.col2 * + col2 ) AS col1 FROM tab0
----
1
35937
551368

query I rowsort
SELECT + 76 FROM tab0, tab1 AS cor0
----
9 values hashing to 30b8941a700cffd5b983116383bd42d5

query I rowsort
SELECT DISTINCT col1 * + 73 + 59 FROM tab1
----
1008
1957
789

query I rowsort
SELECT + + col0 * col1 + 89 + - 96 * - col1 FROM tab1 AS cor0
----
1689
2377
2663

query I rowsort
SELECT - 96 * - col1 AS col1 FROM tab1 AS cor0
----
1248
2496
960

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-5938
SELECT ALL 40 DIV - col1 AS col0 FROM tab2 cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-5938
SELECT ALL 40 / - col1 AS col0 FROM tab2 cor0
----
-1
-2
0

query I rowsort
SELECT DISTINCT - + 11 * col2 + col2 * col0 FROM tab2 AS cor0
----
-108
1742
2584

query I rowsort
SELECT 7 * - tab1.col0 * - col2 + - 63 AS col0 FROM tab1
----
1071
25473
53697

query I rowsort
SELECT 37 + + col1 * col0 AS col2 FROM tab2
----
1380
254
4639

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5942
SELECT ALL CAST( NULL AS SIGNED ) * col2 * col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5942
SELECT ALL CAST ( NULL AS INTEGER ) * col2 * col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5943
SELECT - col0 DIV 61 - col1 FROM tab2
----
-18
-31
-60

skipif mysql # not compatible
query I rowsort label-5943
SELECT - col0 / 61 - col1 FROM tab2
----
-18
-31
-60

query I rowsort
SELECT - ( + tab2.col0 * col0 ) + - col1 FROM tab2
----
-6143
-6258
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col0 * - col2 col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - + col2 * col2 + + 16 * col1 * col2 FROM tab1 AS cor0
----
10752
19548
5871

query I rowsort
SELECT DISTINCT - - 4 + - col1 AS col2 FROM tab2 AS cor0
----
-13
-27
-55

query I rowsort
SELECT ALL + 89 - col1 FROM tab2 AS cor0
----
30
58
72

query I rowsort
SELECT ALL - 83 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

query I rowsort
SELECT DISTINCT 54 AS col1 FROM tab1
----
54

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - cor0.col1 ) + - ( + cor0.col1 ) col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + 18 AS col1 FROM tab2, tab2 AS cor0, tab1 cor1
----
27 values hashing to 903ac227935c1532300db45a8537c595

onlyif mysql # use DIV operator for integer division
query I rowsort label-5953
SELECT + - 52 + + col0 DIV + ( + col2 ) AS col2 FROM tab1 AS cor0
----
-51
-52
-52

skipif mysql # not compatible
query I rowsort label-5953
SELECT + - 52 + + col0 / + ( + col2 ) AS col2 FROM tab1 AS cor0
----
-51
-52
-52

query I rowsort
SELECT + - 22 * col1 + + col0 AS col0 FROM tab0 AS cor0
----
-1868
-1913
-2099

query I rowsort
SELECT tab0.col2 * + col2 * + col1 + + col1 FROM tab0
----
194
611975
93740

query I rowsort
SELECT col1 + - cor0.col1 * ( + col2 ) AS col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT + col0 * col0 - - col0 * + col1 FROM tab1 AS cor0
----
4736
7440
87

query I rowsort
SELECT ALL - 73 + col2 FROM tab0 AS cor0
----
-40
-72
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 * + cor0.col2 col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + cor0.col0 * ( 71 ) + col0 FROM tab1 AS cor0
----
216
4608
5760

query I rowsort
SELECT DISTINCT - col2 + 21 * - cor0.col2 FROM tab0 AS cor0
----
-1804
-22
-726

onlyif mysql # use DIV operator for integer division
query I rowsort label-5962
SELECT ALL + col0 DIV ( col1 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5962
SELECT ALL + col0 / ( col1 ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + - col1 * - cor0.col2 * col1 AS col0 FROM tab2 AS cor0
----
10982
25947
90506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + col1 col2 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5965
SELECT DISTINCT + cor0.col0 * col2 + col2 * + cor0.col1 * + CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5965
SELECT DISTINCT + cor0.col0 * col2 + col2 * + cor0.col1 * + CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5966
SELECT ALL tab1.col2 + col0 + + CAST( + 68 * col1 AS SIGNED ) FROM tab1
----
1060
1825
801

skipif mysql # not compatible
query I rowsort label-5966
SELECT ALL tab1.col2 + col0 + + CAST ( + 68 * col1 AS INTEGER ) FROM tab1
----
1060
1825
801

query I rowsort
SELECT ALL col0 + + tab1.col0 * col1 * col2 FROM tab1
----
36544
4215
99920

query I rowsort
SELECT ALL 28 + tab1.col0 * + col1 FROM tab1
----
106
1068
668

query I rowsort
SELECT DISTINCT - col1 * + col0 AS col2 FROM tab1
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-5970
SELECT col2 + - tab2.col1 DIV + col0 AS col0 FROM tab2
----
23
26
38

skipif mysql # not compatible
query I rowsort label-5970
SELECT col2 + - tab2.col1 / + col0 AS col0 FROM tab2
----
23
26
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5971
SELECT col1 DIV + col2 - col0 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-5971
SELECT col1 / + col2 - col0 FROM tab1
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5972
SELECT col0 * + col2 DIV - col2 + - col2 AS col0 FROM tab0
----
-171
-36
-57

skipif mysql # not compatible
query I rowsort label-5972
SELECT col0 * + col2 / - col2 + - col2 AS col0 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT ALL col1 * tab0.col1 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT - col1 * col2 * col0 AS col2 FROM tab1
----
-36480
-4212
-99840

query I rowsort
SELECT ALL col2 * col2 * - col1 AS col1 FROM tab2
----
-22599
-24548
-39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-5976
SELECT ALL col0 DIV + col0 + - col0 FROM tab2
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-5976
SELECT ALL col0 / + col0 + - col0 FROM tab2
----
-6
-77
-78

query I rowsort
SELECT - col0 FROM tab1 WHERE NOT ( - col1 ) BETWEEN col1 AND NULL
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5978
SELECT - col1 DIV tab0.col2 + col0 FROM tab0
----
-62
22
88

skipif mysql # not compatible
query I rowsort label-5978
SELECT - col1 / tab0.col2 + col0 FROM tab0
----
-62
22
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - + col1 col2 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT col2 FROM tab1 WHERE ( NULL ) NOT IN ( col1 + col2 )
----

query III rowsort
SELECT * FROM tab0 WHERE col1 = ( NULL )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT + col0 NOT IN ( + col1 - + col2 )
----

query III rowsort
SELECT * FROM tab2 WHERE NOT ( - col1 ) NOT IN ( col2 + col0 )
----

query I rowsort
SELECT - col1 * - col2 * col1 - col1 * - col0 FROM tab0
----
12804
246132
687141

query I rowsort
SELECT tab2.col0 * - col2 * - col2 - col2 AS col2 FROM tab2
----
114038
5076
52702

query I rowsort
SELECT - col2 + - tab0.col2 AS col1 FROM tab0 WHERE NOT + col2 < NULL
----

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL NOT BETWEEN ( + col1 ) AND NULL
----

query I rowsort
SELECT col1 * + col0 * + col0 FROM tab0
----
118825
49536
720811

query I rowsort
SELECT ALL + col2 * col0 AS col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT - col0 * tab2.col1 * - col2 AS col1 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT col2 * - col1 * col0 AS col1 FROM tab0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-5992
SELECT ALL + tab0.col0 DIV + col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5992
SELECT ALL + tab0.col0 / + col1 FROM tab0
----
0
0
0

query I rowsort
SELECT col1 + col2 * tab0.col1 FROM tab0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-5994
SELECT ALL col1 DIV + col0 AS col2 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-5994
SELECT ALL col1 / + col0 AS col2 FROM tab0
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5995
SELECT DISTINCT col1 DIV - col0 FROM tab1
----
-8
0

skipif mysql # not compatible
query I rowsort label-5995
SELECT DISTINCT col1 / - col0 FROM tab1
----
-8
0

query I rowsort
SELECT ALL - col0 * col1 - col2 AS col0 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT - tab2.col1 + ( - tab2.col2 ) + - ( + col2 ) FROM tab2
----
-111
-85
-93

query I rowsort
SELECT 26 + - col0 - col0 FROM tab0
----
-152
-22
-44

query I rowsort
SELECT ALL - 97 AS col2 FROM tab0 cor0
----
-97
-97
-97

query I rowsort
SELECT col0 * - col1 - col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT - + col2 + col1 * - col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-6002
SELECT 70 DIV - 26 AS col0 FROM tab2
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-6002
SELECT 70 / - 26 AS col0 FROM tab2
----
-2
-2
-2

query I rowsort
SELECT - tab0.col2 * 96 + + col1 FROM tab0
----
-3082
-7781
1

query I rowsort
SELECT DISTINCT - 57 AS col1 FROM tab0, tab1, tab1 AS cor0
----
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6005
SELECT DISTINCT CAST( 19 AS SIGNED ) * - col0 * col2 + col1 - - col0 * + col1 * 17 AS col2 FROM tab1
----
-128227
-1726
-58422

skipif mysql # not compatible
query I rowsort label-6005
SELECT DISTINCT CAST ( 19 AS INTEGER ) * - col0 * col2 + col1 - - col0 * + col1 * 17 AS col2 FROM tab1
----
-128227
-1726
-58422

query I rowsort
SELECT ALL + col1 - - col0 * + tab0.col0 AS col0 FROM tab0
----
1322
662
8012

query I rowsort
SELECT + ( cor0.col2 ) + - col2 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 * + col1 - + 23 col2 FROM tab2 AS cor0
----
-1366
-240
-4625

query I rowsort
SELECT + + col1 + col1 * + 23 AS col0 FROM tab0 AS cor0
----
2064
2184
2328

query I rowsort
SELECT ALL 48 - col0 FROM tab0 AS cor0
----
-41
13
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-6011
SELECT DISTINCT col0 DIV col1 FROM tab1 AS cor0
----
0
6

skipif mysql # not compatible
query I rowsort label-6011
SELECT DISTINCT col0 / col1 FROM tab1 AS cor0
----
0
6

query I rowsort
SELECT ALL + + col1 * + col0 + - 2 AS col2 FROM tab2 cor0
----
1341
215
4600

query I rowsort
SELECT - col0 + col2 * 62 AS col0 FROM tab0 AS cor0
----
2022
27
4995

query I rowsort
SELECT ALL - col1 * cor0.col0 + col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL - - 42 * col0 AS col1 FROM tab2 AS cor0
----
294
3276
3318

query I rowsort
SELECT DISTINCT 52 * + col2 AS col1 FROM tab2 AS cor0
----
1352
1404
1976

query I rowsort
SELECT - col2 + - col0 - - col1 FROM tab0 AS cor0
----
-80
29
61

query I rowsort
SELECT ALL 40 FROM tab2 AS cor0
----
40
40
40

onlyif mysql # use DIV operator for integer division
query I rowsort label-6019
SELECT - + 43 DIV cor0.col1 FROM tab1 AS cor0
----
-1
-3
-4

skipif mysql # not compatible
query I rowsort label-6019
SELECT - + 43 / cor0.col1 FROM tab1 AS cor0
----
-1
-3
-4

onlyif mysql # use DIV operator for integer division
query I rowsort label-6020
SELECT + + col2 + + ( - col0 ) DIV col0 col0 FROM tab1 AS cor0
----
53
56
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6020
SELECT + + col2 + + ( - col0 ) / col0 col0 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT DISTINCT + - cor0.col2 * - col1 + col2 AS col2 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT ALL + col0 * + col1 + 16 AS col0 FROM tab2 AS cor0
----
1359
233
4618

query I rowsort
SELECT - + col2 + 45 * + 86 FROM tab0 cor0
----
3788
3837
3869

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6024
SELECT + col2 * CAST( + col0 AS SIGNED ) AS col1 FROM tab2 cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-6024
SELECT + col2 * CAST ( + col0 AS INTEGER ) AS col1 FROM tab2 cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6025
SELECT + + col2 * + ( - col2 + - CAST( NULL AS SIGNED ) ) / - col2 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6025
SELECT + + col2 * + ( - col2 + - CAST ( NULL AS INTEGER ) ) / - col2 col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 95 AS col1 FROM tab2 AS cor0
----
-95

query I rowsort
SELECT col0 * 44 AS col1 FROM tab2 AS cor0
----
308
3432
3476

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + 49 col1 FROM tab1 AS cor0
----
-15
-31
46

query I rowsort
SELECT + ( col2 ) * - col0 FROM tab0 AS cor0
----
-35
-7298
-792

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 cor0 CROSS JOIN tab2, tab1 AS cor1, tab1 AS cor2, tab0 AS cor3
----
3645 values hashing to 3b4587ab6c08d2179c6df094d2f76ad7

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab1 AS cor2, tab2 AS cor3
----
3645 values hashing to cc4f069e61d0cc52f433f9e8c0058808

query I rowsort
SELECT ALL + - ( 48 ) * - col1 FROM tab1 AS cor0
----
1248
480
624

query I rowsort
SELECT ALL - col1 * cor0.col2 + col1 * - col1 + - col2 * + col2 AS col2 FROM tab2 cor0
----
-2379
-2527
-5691

query I rowsort
SELECT DISTINCT col1 - cor0.col2 AS col2 FROM tab0 AS cor0
----
53
9
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 23 col0 FROM tab0 cor0
----
23

query I rowsort
SELECT - 70 FROM tab1 cor0
----
-70
-70
-70

query I rowsort
SELECT DISTINCT - 97 + col2 + col1 FROM tab1 cor0
----
-17
-30
12

query I rowsort
SELECT ALL + 68 * - cor0.col1 + + col0 FROM tab0 AS cor0
----
-5824
-6099
-6561

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - cor0.col1 + - col0 * - col1 col1 FROM tab1 cor0
----
1107
55
694

query I rowsort
SELECT DISTINCT - + cor0.col2 + col2 * col1 FROM tab2 AS cor0
----
1508
608
810

query I rowsort
SELECT DISTINCT + + 40 + + cor0.col0 AS col1 FROM tab0 AS cor0
----
129
64
75

query I rowsort
SELECT ALL + - ( col1 ) * cor0.col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT + col0 - col1 * - col2 FROM tab2 cor0
----
1612
725
844

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6044
SELECT - + CAST( NULL AS SIGNED ) + col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6044
SELECT - + CAST ( NULL AS INTEGER ) + col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * 80 col1 FROM tab0 AS cor0
----
6880
7280
7760

query I rowsort
SELECT DISTINCT - ( + col0 ) FROM tab2
----
-7
-78
-79

query I rowsort
SELECT ALL col1 + - 30 AS col2 FROM tab2 AS cor0
----
-13
1
29

query I rowsort
SELECT ALL 49 * 93 FROM tab0 AS cor0
----
4557
4557
4557

query I rowsort
SELECT ALL - 49 + col2 AS col0 FROM tab0 cor0
----
-16
-48
33

query I rowsort
SELECT + - 2 + - col0 AS col2 FROM tab0 AS cor0
----
-26
-37
-91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6051
SELECT ALL + CAST( - col0 AS SIGNED ) AS col0 FROM tab2 cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-6051
SELECT ALL + CAST ( - col0 AS INTEGER ) AS col0 FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT - + 21 * col0 + col0 FROM tab2 AS cor0
----
-140
-1560
-1580

query I rowsort
SELECT ALL + - 96 * - col0 FROM tab0 AS cor0
----
2304
3360
8544

query I rowsort
SELECT + - cor0.col1 * - col2 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col0 col2 FROM tab1, tab0 AS cor0 CROSS JOIN tab2 WHERE NOT NULL <> NULL
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col1 col1 FROM tab1 AS cor0
----
1040
640
78

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT + col0 <= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6058
SELECT col0 + tab0.col2 * + col0 + - col1 DIV - tab0.col0 AS col0 FROM tab0
----
72
7388
819

skipif mysql # not compatible
query I rowsort label-6058
SELECT col0 + tab0.col2 * + col0 + - col1 / - tab0.col0 AS col0 FROM tab0
----
72
7388
819

query I rowsort
SELECT + col0 * - col0 FROM tab1 WHERE NOT ( col0 ) NOT BETWEEN NULL AND ( - col2 + col2 )
----

query I rowsort
SELECT ALL - col0 FROM tab1 AS cor0 WHERE NULL BETWEEN NULL AND ( col2 + - col1 )
----

query I rowsort
SELECT - col0 * + col0 AS col1 FROM tab0 AS cor0 WHERE NULL < NULL
----

query I rowsort
SELECT ALL col2 * - col1 + col0 * col2 + cor0.col2 FROM tab0 cor0
----
-2013
-61
-82

query I rowsort
SELECT cor0.col1 * - col0 * col0 + - col0 FROM tab2 AS cor0
----
-106176
-1526
-359034

query I rowsort
SELECT + col1 * + tab1.col1 * tab1.col2 AS col1 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT + - col2 * col0 - col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT - col0 + col2 + - col1 FROM tab0 AS cor0
----
-131
-77
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-6067
SELECT + col2 DIV + col2 + col2 + col2 AS col0 FROM tab1 AS cor0
----
109
115
193

skipif mysql # not compatible
query I rowsort label-6067
SELECT + col2 / + col2 + col2 + col2 AS col0 FROM tab1 AS cor0
----
109
115
193

query I rowsort
SELECT col0 * col0 * cor0.col0 + col0 FROM tab1 AS cor0
----
262208
30
512080

query I rowsort
SELECT - col2 + col2 + + col1 AS col0 FROM tab1 AS cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + col0 col1 FROM tab2
----
14
156
158

query I rowsort
SELECT - col0 * col1 * - col2 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT + ( tab2.col0 ) AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT ALL + col1 - - 87 * col0 FROM tab0
----
2174
3142
7834

onlyif mysql # use DIV operator for integer division
query I rowsort label-6074
SELECT ALL - col2 DIV - ( - col2 * col0 ) col0 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6074
SELECT ALL - col2 / - ( - col2 * col0 ) col0 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6075
SELECT DISTINCT tab0.col0 DIV ( tab0.col1 + col0 ) FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-6075
SELECT DISTINCT tab0.col0 / ( tab0.col1 + col0 ) FROM tab0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 35 col2 FROM tab1, tab1 AS cor0
----
35

query I rowsort
SELECT cor0.col2 * col0 + + col2 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-6078
SELECT cor0.col1 DIV col0 + col0 * 0 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-6078
SELECT cor0.col1 / col0 + col0 * 0 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT DISTINCT col1 * + cor0.col2 + - col0 FROM tab1 cor0
----
1168
1401
506

onlyif mysql # use DIV operator for integer division
query I rowsort label-6080
SELECT ALL + ( ( - col0 DIV + col2 ) ) * ( + cor0.col2 ) * 32 FROM tab1 AS cor0
----
-1824
0
0

skipif mysql # not compatible
query I rowsort label-6080
SELECT ALL + ( ( - col0 / + col2 ) ) * ( + cor0.col2 ) * 32 FROM tab1 AS cor0
----
-1824
0
0

query I rowsort
SELECT ALL + 99 * 67 + + col2 AS col2 FROM tab1 AS cor0
----
6687
6690
6729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col0 ) + col1 col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL - - cor0.col1 * + col1 AS col0 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT ( col2 ) * + col0 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
108
3591
7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-6085
SELECT ALL - 94 * + col1 DIV col1 col0 FROM tab0 AS cor0
----
-94
-94
-94

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6085
SELECT ALL - 94 * + col1 / col1 col0 FROM tab0 AS cor0
----
-94
-94
-94

query I rowsort
SELECT - ( - cor0.col2 ) + col0 * + ( + col2 ) AS col1 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT + col2 * + 44 FROM tab1
----
2376
2508
4224

query I rowsort
SELECT + col1 * + 42 * col2 FROM tab1
----
23940
52416
58968

query I rowsort
SELECT DISTINCT - cor1.col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
-24
-35
-89

query I rowsort
SELECT - ( - col0 ) + col1 * + 88 FROM tab0 AS cor0
----
7592
8097
8571

query I rowsort
SELECT ALL - - 98 AS col1 FROM tab1 AS cor0
----
98
98
98

query I rowsort
SELECT DISTINCT col0 + + cor0.col1 * col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT col1 * - tab2.col1 AS col1 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT - 12 * cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 552c64f5a72adfb916a7cf2a9a6a7614

query I rowsort
SELECT + 79 * - col1 * + col0 AS col0 FROM tab2 AS cor0
----
-106097
-17143
-363558

query I rowsort
SELECT 40 AS col1 FROM tab2 AS cor0
----
40
40
40

query I rowsort
SELECT ALL ( + col0 ) AS col2 FROM tab2
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 78 + - col1 * ( - col1 + - cor0.col0 ) col0 FROM tab0 AS cor0
----
12882
16458
9538

query I rowsort
SELECT ALL + + 57 * + col0 + col1 FROM tab2 AS cor0
----
430
4505
4520

onlyif mysql # use DIV operator for integer division
query I rowsort label-6100
SELECT + - col1 + 60 DIV col1 FROM tab1 AS cor0
----
-24
-4
-9

skipif mysql # not compatible
query I rowsort label-6100
SELECT + - col1 + 60 / col1 FROM tab1 AS cor0
----
-24
-4
-9

query I rowsort
SELECT DISTINCT - - col2 + col1 * - ( - col0 ) FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL + col2 + + 85 AS col0 FROM tab2 cor0
----
111
112
123

query I rowsort
SELECT ALL cor0.col1 + - 33 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 90219267fd9ac3ddd5688066a7a2c873

query I rowsort
SELECT ALL 57 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT ALL col0 * - tab0.col1 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT + col2 * - col1 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - col2 * col0 - - col0 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 * 88 + + col2 col2 FROM tab2 AS cor0
----
-589
-6838
-6914

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 + - ( + col0 ) col1 FROM tab0 AS cor0
----
2
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - ( - col2 ) col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT cor0.col2 * - col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT - tab1.col1 FROM tab0, tab2, tab1 AS cor0, tab1
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 43 col0 FROM tab2
----
-43
-43
-43

query I rowsort
SELECT - col1 * + col1 - - 21 AS col0 FROM tab0
----
-7375
-8260
-9388

query I rowsort
SELECT DISTINCT + col1 - 7 AS col0 FROM tab0
----
79
84
90

query I rowsort
SELECT DISTINCT - 33 FROM tab1, tab2 AS cor0
----
-33

query I rowsort
SELECT ALL + col0 - 58 FROM tab0
----
-23
-34
31

query I rowsort
SELECT ALL + cor0.col1 * 74 FROM tab1 AS cor0
----
1924
740
962

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * + ( - cor0.col1 ) - col2 col2 FROM tab0 AS cor0
----
-7429
-8363
-9410

query I rowsort
SELECT DISTINCT - col2 + + col2 AS col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT - cor0.col1 * + col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT col0 + 4 AS col1 FROM tab0 AS cor0
----
28
39
93

query I rowsort
SELECT DISTINCT + col1 - - 26 FROM tab0 AS cor0
----
112
117
123

query I rowsort
SELECT - col1 + col2 * cor0.col0 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT - - col2 * col0 + col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT - tab2.col1 * - 78 + + col0 FROM tab2
----
1405
2425
4680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6127
SELECT - col1 + CAST( - 70 AS SIGNED ) FROM tab1 AS cor0
----
-80
-83
-96

skipif mysql # not compatible
query I rowsort label-6127
SELECT - col1 + CAST ( - 70 AS INTEGER ) FROM tab1 AS cor0
----
-80
-83
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( - col0 ) col0 FROM tab2
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6129
SELECT - + CAST( - cor0.col0 AS SIGNED ) + + cor0.col2 + - 57 * - col1 AS col0 FROM tab2 cor0
----
1086
1801
3467

skipif mysql # not compatible
query I rowsort label-6129
SELECT - + CAST ( - cor0.col0 AS INTEGER ) + + cor0.col2 + - 57 * - col1 AS col0 FROM tab2 cor0
----
1086
1801
3467

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6130
SELECT + - CAST( col1 AS SIGNED ) + col2 * - col0 AS col1 FROM tab1 AS cor0
----
-188
-3658
-7693

skipif mysql # not compatible
query I rowsort label-6130
SELECT + - CAST ( col1 AS INTEGER ) + col2 * - col0 AS col1 FROM tab1 AS cor0
----
-188
-3658
-7693

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 CROSS JOIN tab2, tab0 cor1, tab0 AS cor2
----
3645 values hashing to f655b6f4c5b9ff73813030f2822ea1fd

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 cor0 CROSS JOIN tab2, tab2 AS cor1, tab2 AS cor2
----
3645 values hashing to f1fc3f16747aca82b54b2b759d1f5ea2

query I rowsort
SELECT + ( + col1 ) * + col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL - 15 FROM tab1
----
-15
-15
-15

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 * col0 col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT cor0.col2 AS col0 FROM tab0, tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col0 col1 FROM tab0 AS cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 97 col2 FROM tab2 AS cor0
----
97
97
97

query I rowsort
SELECT DISTINCT + cor0.col2 * - col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL 94 AS col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to a4d239626cf0546ac1b2f57bb8407089

query I rowsort
SELECT ALL + + col0 * col1 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT + + 48 + 55 AS col2 FROM tab2 AS cor0
----
103

onlyif mysql # use DIV operator for integer division
query I rowsort label-6143
SELECT DISTINCT + - col2 + - col1 DIV col0 FROM tab1 cor0
----
-57
-62
-96

skipif mysql # not compatible
query I rowsort label-6143
SELECT DISTINCT + - col2 + - col1 / col0 FROM tab1 cor0
----
-57
-62
-96

query I rowsort
SELECT DISTINCT - ( 43 ) + - col2 FROM tab2 AS cor0
----
-69
-70
-81

query I rowsort
SELECT 69 + col0 * col0 FROM tab1 AS cor0
----
4165
6469
78

query I rowsort
SELECT DISTINCT col0 + + cor0.col2 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL - + col0 * + col2 + - cor0.col0 + cor0.col2 FROM tab1 cor0
----
-111
-3655
-7664

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6148
SELECT CAST( ( col0 ) AS SIGNED ) AS col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6148
SELECT CAST ( ( col0 ) AS INTEGER ) AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL - 24 FROM tab0, tab0 AS cor0
----
9 values hashing to 797d0f7c145f8ac623924448c714bbcc

query I rowsort
SELECT + 96 AS col1 FROM tab2 AS cor0
----
96
96
96

query I rowsort
SELECT - 67 * col1 FROM tab0 AS cor0
----
-5762
-6097
-6499

query I rowsort
SELECT ALL - col2 * 46 - - col1 FROM tab0 cor0
----
-1432
-3681
51

query I rowsort
SELECT DISTINCT + - 23 * col2 FROM tab0 AS cor0
----
-1886
-23
-759

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col0 * - col1 col0 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT + col1 + + cor0.col1 * + col1 AS col0 FROM tab0 cor0
----
7482
8372
9506

query I rowsort
SELECT ALL + 44 + - 50 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 8be8910507908e6353d02a545b748252

query I rowsort
SELECT DISTINCT + ( + col2 ) FROM tab1
----
54
57
96

query I rowsort
SELECT 12 - + col2 FROM tab0
----
-21
-70
11

query I rowsort
SELECT ALL - cor0.col1 - col1 * col2 AS col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT DISTINCT - cor0.col0 + cor0.col0 FROM tab0 AS cor0
----
0

query I rowsort
SELECT - col1 + + ( col2 ) FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT DISTINCT + + col2 + col0 * + col0 FROM tab0 cor0
----
1226
609
8003

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 - cor0.col0 col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT tab0.col2 * + col1 + col0 FROM tab0
----
132
2862
7551

query I rowsort
SELECT ALL + + col0 * 43 + col1 AS col1 FROM tab0 AS cor0
----
1118
1602
3918

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2, tab1 AS cor0, tab0 cor1
----
972 values hashing to 67c5300bc5cba0be4f54a444dc6f05b9

query I rowsort
SELECT ALL col1 + + col2 * + col0 AS col1 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-6168
SELECT ALL + 36 DIV + cor2.col1 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab1, tab2 cor2
----
243 values hashing to ddf31312b92d682347b790f1d859a4e7

skipif mysql # not compatible
query I rowsort label-6168
SELECT ALL + 36 / + cor2.col1 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab1, tab2 cor2
----
243 values hashing to ddf31312b92d682347b790f1d859a4e7

query I rowsort
SELECT DISTINCT - 53 FROM tab1, tab1 AS cor0
----
-53

query I rowsort
SELECT DISTINCT - 15 FROM tab2, tab0 cor0
----
-15

query I rowsort
SELECT - col2 * + 87 * col0 + + col2 AS col2 FROM tab2 cor0
----
-16416
-176410
-261136

query I rowsort
SELECT ALL 48 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT + col2 * + 12 AS col0 FROM tab2
----
312
324
456

query I rowsort
SELECT 69 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6175
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col2 FROM tab0, tab2, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6175
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col2 FROM tab0, tab2, tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - 10 * 79 FROM tab0
----
-790
-790
-790

query I rowsort
SELECT ALL 18 * + col2 FROM tab0
----
1476
18
594

query I rowsort
SELECT ALL 7 FROM tab0
----
7
7
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6179
SELECT + - CAST( col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-6179
SELECT + - CAST ( col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT - 99 AS col1 FROM tab1 AS cor0
----
-99
-99
-99

query I rowsort
SELECT ALL + col2 + - col0 AS col0 FROM tab1
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-6182
SELECT + col2 DIV tab2.col0 AS col2 FROM tab2
----
0
0
3

skipif mysql # not compatible
query I rowsort label-6182
SELECT + col2 / tab2.col0 AS col2 FROM tab2
----
0
0
3

query I rowsort
SELECT DISTINCT - col2 + col2 + + 6 FROM tab2
----
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 col2 FROM tab1, tab1 cor0
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

onlyif mysql # use DIV operator for integer division
query I rowsort label-6185
SELECT ALL + col0 + - col2 DIV col0 FROM tab2
----
4
78
79

skipif mysql # not compatible
query I rowsort label-6185
SELECT ALL + col0 + - col2 / col0 FROM tab2
----
4
78
79

query I rowsort
SELECT ALL - col1 * col0 + col2 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT tab0.col1 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT + col0 * + col0 * - col0 + + col0 AS col1 FROM tab2 AS cor0
----
-336
-474474
-492960

onlyif mysql # use DIV operator for integer division
query I rowsort label-6189
SELECT - col2 DIV - tab1.col2 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6189
SELECT - col2 / - tab1.col2 AS col1 FROM tab1
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col1 + - col2 * ( + col2 * - col1 + - 8 * - col1 ) col0 FROM tab0 AS cor0
----
-776
552097
70864

query I rowsort
SELECT + col1 * - col0 + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-6192
SELECT col1 * col0 DIV - col1 AS col0 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-6192
SELECT col1 * col0 / - col1 AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT cor0.col0 + + col1 * ( - col1 * col0 ) AS col2 FROM tab0 AS cor0
----
-177480
-329280
-736920

query I rowsort
SELECT cor0.col2 * - ( + col2 ) FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + col2 * col0 AS col1 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT cor0.col0 * + col0 + 0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT + col1 + ( + 2 ) AS col2 FROM tab1 AS cor0
----
12
15
28

query I rowsort
SELECT + col2 + - cor0.col0 AS col1 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-6199
SELECT DISTINCT - - col1 + + col2 + ( - 12 ) DIV col2 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-6199
SELECT DISTINCT - - col1 + + col2 + ( - 12 ) / col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - - col1 * col2 + col1 AS col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT cor0.col1 * 72 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to 962689d97ca10e44b2c7bdc3a637332e

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0 CROSS JOIN tab0 AS cor1
----
243 values hashing to 74e36edda45186a5c45856859d8e21f0

query IIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
243 values hashing to 566180e0144350a78b0ef3318e8f4c00

query I rowsort
SELECT ALL col0 - - col2 * + ( + ( tab0.col0 ) ) FROM tab0
----
70
7387
816

query I rowsort
SELECT ALL - 99 - + col0 * ( 26 ) FROM tab0
----
-1009
-2413
-723

query I rowsort
SELECT - + ( col1 ) * col2 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + col1 col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - - col0 + col1 * + col0 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT DISTINCT + col2 - col1 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6210
SELECT DISTINCT - - 18 + - col1 * + col2 DIV + col2 FROM tab0 AS cor0
----
-68
-73
-79

skipif mysql # not compatible
query I rowsort label-6210
SELECT DISTINCT - - 18 + - col1 * + col2 / + col2 FROM tab0 AS cor0
----
-68
-73
-79

query I rowsort
SELECT ALL tab0.col1 * - 7 + col0 AS col0 FROM tab0
----
-548
-578
-644

query I rowsort
SELECT ALL + col2 * ( col1 ) AS col2 FROM tab1
----
1248
1404
570

query I rowsort
SELECT - cor0.col1 * + 46 AS col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to e1e1a54c64c2015d8d53651e259e896f

query I rowsort
SELECT - col1 + + 39 FROM tab2 AS cor0
----
-20
22
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-6215
SELECT - col1 DIV + col1 + col2 + col1 * + col1 * 61 AS col2 FROM tab1 AS cor0
----
10404
41289
6156

skipif mysql # not compatible
query I rowsort label-6215
SELECT - col1 / + col1 + col2 + col1 * + col1 * 61 AS col2 FROM tab1 AS cor0
----
10404
41289
6156

query I rowsort
SELECT + tab2.col1 * col2 * col0 + col2 AS col0 FROM tab2
----
119678
51072
5886

query I rowsort
SELECT - col2 + - col2 + + col2 AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT - - ( - cor0.col1 ) * col1 AS col0 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT - - 95 * - ( - cor0.col0 ) AS col1 FROM tab2 AS cor0
----
665
7410
7505

query I rowsort
SELECT DISTINCT + 45 * + 41 FROM tab0 AS cor0
----
1845

query I rowsort
SELECT + + cor0.col0 * + col0 * + cor0.col1 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT + + 87 * + col2 * - col0 FROM tab0 AS cor0
----
-3045
-634926
-68904

query I rowsort
SELECT ALL + - 69 + col1 * cor0.col0 FROM tab2 AS cor0
----
1274
148
4533

query I rowsort
SELECT + + 98 * - col1 FROM tab0 AS cor0
----
-8428
-8918
-9506

query I rowsort
SELECT DISTINCT - + 59 + col2 FROM tab2 AS cor0
----
-21
-32
-33

query I rowsort
SELECT DISTINCT col0 + 97 FROM tab2 AS cor0
----
104
175
176

query I rowsort
SELECT ALL - 67 FROM tab2 cor0
----
-67
-67
-67

query I rowsort
SELECT ALL - 43 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to ab0c314d2b589ccedb9a875beeb1f86a

query I rowsort
SELECT ALL + col2 * + 59 + col0 FROM tab2 AS cor0
----
1600
1612
2321

query I rowsort
SELECT DISTINCT + 14 * 86 FROM tab0
----
1204

query I rowsort
SELECT ALL - 13 * col0 FROM tab1 AS cor0
----
-1040
-39
-832

query I rowsort
SELECT ALL + - col0 + + 66 AS col0 FROM tab2 cor0
----
-12
-13
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 col2 FROM tab0, tab2 cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT DISTINCT + 39 FROM tab0, tab1 AS cor0
----
39

query I rowsort
SELECT ALL + 82 * - 13 AS col1 FROM tab2 AS cor0
----
-1066
-1066
-1066

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6236
SELECT DISTINCT - CAST( - col2 AS SIGNED ) + col2 * - CAST( col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-2862
-3192
-9120

skipif mysql # not compatible
query I rowsort label-6236
SELECT DISTINCT - CAST ( - col2 AS INTEGER ) + col2 * - CAST ( col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-2862
-3192
-9120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 94 col2 FROM tab2 AS cor0
----
94
94
94

query I rowsort
SELECT - + col0 + + ( + col2 ) * col2 AS col1 FROM tab0 AS cor0
----
-34
1065
6635

query I rowsort
SELECT - 25 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 40ac8fd000b2e49317aed2411077839e

query I rowsort
SELECT - - 83 * - col0 * + 52 AS col1 FROM tab2 AS cor0
----
-30212
-336648
-340964

onlyif mysql # use DIV operator for integer division
query I rowsort label-6241
SELECT + 13 DIV + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6241
SELECT + 13 / + col2 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + ( col2 ) + + col1 * cor0.col0 AS col1 FROM tab2 cor0
----
1381
244
4628

query I rowsort
SELECT - - 78 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
2028
2106
2964

query I rowsort
SELECT DISTINCT - - col0 * col0 AS col0 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6245
SELECT - cor0.col1 DIV cor0.col1 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6245
SELECT - cor0.col1 / cor0.col1 FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6246
SELECT DISTINCT col2 * - col0 + - CAST( NULL AS SIGNED ) * ( + col0 ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6246
SELECT DISTINCT col2 * - col0 + - CAST ( NULL AS INTEGER ) * ( + col0 ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ( col2 ) + col0 AS col2 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL + cor0.col2 - 42 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
-2631
-3264
-72

query I rowsort
SELECT + col2 * + 4 + - col0 * col1 * col0 FROM tab2 AS cor0
----
-105945
-1411
-358852

onlyif mysql # use DIV operator for integer division
query I rowsort label-6250
SELECT ALL + col0 + ( 21 ) DIV + cor0.col2 + - 80 AS col1 FROM tab0 AS cor0
----
-24
-56
9

skipif mysql # not compatible
query I rowsort label-6250
SELECT ALL + col0 + ( 21 ) / + cor0.col2 + - 80 AS col1 FROM tab0 AS cor0
----
-24
-56
9

query I rowsort
SELECT DISTINCT + col1 * 92 + + col2 AS col2 FROM tab1 AS cor0
----
1292
2446
977

query I rowsort
SELECT + col2 + + 58 * + col1 AS col1 FROM tab1 AS cor0
----
1562
637
850

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 + - 0 col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + col1 * - ( + col2 ) + + col1 AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-6255
SELECT DISTINCT + col1 + col1 DIV ( col2 + col2 ) FROM tab0 cor0
----
145
87
91

skipif mysql # not compatible
query I rowsort label-6255
SELECT DISTINCT + col1 + col1 / ( col2 + col2 ) FROM tab0 cor0
----
145
87
91

query I rowsort
SELECT col0 * ( + 22 ) FROM tab1 cor0
----
1408
1760
66

query I rowsort
SELECT 87 * col1 FROM tab1
----
1131
2262
870

query I rowsort
SELECT DISTINCT - 84 - col1 * + 9 FROM tab2
----
-237
-363
-615

query I rowsort
SELECT - 5 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to 4f346dd2f65047c836c6957f80f0ef9e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6260
SELECT DISTINCT col1 * - col0 * + CAST( NULL AS SIGNED ) - - ( - tab0.col1 ) * CAST( NULL AS SIGNED ) AS col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-6260
SELECT DISTINCT col1 * - col0 * + CAST ( NULL AS INTEGER ) - - ( - tab0.col1 ) * CAST ( NULL AS INTEGER ) AS col0 FROM tab0
----
NULL

query I rowsort
SELECT ALL + col2 * col0 + col0 AS col1 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT ALL + col0 + - ( - col2 ) FROM tab0 AS cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-6263
SELECT DISTINCT + col2 DIV - ( + col1 ) - col0 AS col2 FROM tab2 AS cor0
----
-7
-78
-81

skipif mysql # not compatible
query I rowsort label-6263
SELECT DISTINCT + col2 / - ( + col1 ) - col0 AS col2 FROM tab2 AS cor0
----
-7
-78
-81

query I rowsort
SELECT + col0 - - 58 AS col2 FROM tab1 cor0
----
122
138
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6265
SELECT DISTINCT col0 + CAST( NULL AS DECIMAL ) AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-6265
SELECT DISTINCT col0 + CAST ( NULL AS REAL ) AS col0 FROM tab1
----
NULL

query IIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 cor0 CROSS JOIN tab0, tab0 AS cor1 WHERE NOT NULL >= NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6267
SELECT DISTINCT col2 + - col0 DIV + col2 AS col2 FROM tab0
----
-34
33
81

skipif mysql # not compatible
query I rowsort label-6267
SELECT DISTINCT col2 + - col0 / + col2 AS col2 FROM tab0
----
-34
33
81

query I rowsort
SELECT col1 * col1 + - col1 * col2 * col2 FROM tab2
----
-21638
-24259
-36403

onlyif mysql # use DIV operator for integer division
query I rowsort label-6269
SELECT DISTINCT col1 + col2 * 89 + + col2 DIV - col2 FROM tab0
----
185
3022
7388

skipif mysql # not compatible
query I rowsort label-6269
SELECT DISTINCT col1 + col2 * 89 + + col2 / - col2 FROM tab0
----
185
3022
7388

query I rowsort
SELECT + col2 * + col0 + 86 FROM tab1 AS cor0
----
248
3734
7766

query I rowsort
SELECT ALL - col0 * + 63 AS col1 FROM tab1 AS cor0
----
-189
-4032
-5040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6272
SELECT - col2 + - CAST( NULL AS SIGNED ) * 66 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6272
SELECT - col2 + - CAST ( NULL AS INTEGER ) * 66 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT tab2.col2 * col0 * + 22 FROM tab2
----
4158
44616
66044

query I rowsort
SELECT ALL + cor1.col2 FROM tab2, tab1, tab1 AS cor0, tab2 AS cor1
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT DISTINCT 29 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
29

query I rowsort
SELECT col1 * + col1 * - tab0.col1 FROM tab0
----
-636056
-753571
-912673

query I rowsort
SELECT DISTINCT col1 * col2 * col2 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT DISTINCT 31 * col0 AS col2 FROM tab2
----
217
2418
2449

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 - + cor0.col1 col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT col0 * 16 AS col2 FROM tab0 AS cor0
----
1424
384
560

query I rowsort
SELECT ALL col2 + + ( col2 ) AS col1 FROM tab1 AS cor0
----
108
114
192

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6282
SELECT DISTINCT - cor0.col1 * CAST( cor0.col2 AS SIGNED ) + col1 FROM tab2 AS cor0
----
-1475
-629
-806

skipif mysql # not compatible
query I rowsort label-6282
SELECT DISTINCT - cor0.col1 * CAST ( cor0.col2 AS INTEGER ) + col1 FROM tab2 AS cor0
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * 0 col2 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 63 - + tab1.col0 * cor0.col0 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 20a643175ac25791033bafec35e2d099

query I rowsort
SELECT + col2 * + ( col2 ) AS col2 FROM tab1 AS cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-6286
SELECT DISTINCT + cor0.col1 DIV col1 + col2 AS col2 FROM tab2 AS cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-6286
SELECT DISTINCT + cor0.col1 / col1 + col2 AS col2 FROM tab2 AS cor0
----
27
28
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-6287
SELECT - col1 DIV - ( col1 ) + 11 FROM tab1 AS cor0
----
12
12
12

skipif mysql # not compatible
query I rowsort label-6287
SELECT - col1 / - ( col1 ) + 11 FROM tab1 AS cor0
----
12
12
12

query I rowsort
SELECT ALL + ( 89 ) FROM tab2 AS cor0
----
89
89
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6289
SELECT ALL col2 DIV cor0.col2 + + col2 AS col1 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-6289
SELECT ALL col2 / cor0.col2 + + col2 AS col1 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT DISTINCT - col2 * col2 - col1 AS col2 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT - ( col0 ) * col1 AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6292
SELECT + col1 - col1 * col1 * CAST( NULL AS DECIMAL ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6292
SELECT + col1 - col1 * col1 * CAST ( NULL AS REAL ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - 58 * - col0 + col1 * ( 93 ) AS col0 FROM tab2 AS cor0
----
10011
3289
6163

query I rowsort
SELECT ( 23 ) AS col0 FROM tab1 AS cor0
----
23
23
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-6295
SELECT - ( cor0.col0 ) DIV - col2 AS col2 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6295
SELECT - ( cor0.col0 ) / - col2 AS col2 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT ALL + 14 * + col2 * - col1 FROM tab2 AS cor0
----
-11718
-21476
-9044

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + col2 * cor0.col2 col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT DISTINCT + + 93 * ( col1 ) FROM tab2 AS cor0
----
1581
2883
5487

query I rowsort
SELECT ALL 58 * ( - col0 ) AS col0 FROM tab0 AS cor0
----
-1392
-2030
-5162

query I rowsort
SELECT DISTINCT + col0 + + 15 AS col0 FROM tab1 AS cor0
----
18
79
95

query I rowsort
SELECT ALL - col2 * - 28 + - col0 AS col1 FROM tab1 AS cor0
----
1509
1532
2608

query I rowsort
SELECT - 56 * col2 + col0 FROM tab1 AS cor0
----
-3021
-3128
-5296

query I rowsort
SELECT DISTINCT + 47 FROM tab1 AS cor0
----
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 94 + col2 col1 FROM tab2 AS cor0
----
120
121
132

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab0 cor0, tab0 AS cor1, tab2, tab1 AS cor2
----
3645 values hashing to b2cff03af5bc7306c5e3322cc78563c1

query I rowsort
SELECT + 73 * col1 + col2 AS col1 FROM tab0
----
6311
6725
7082

query I rowsort
SELECT + 6 AS col0 FROM tab0
----
6
6
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-6308
SELECT + col2 + col0 DIV - col1 AS col2 FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6308
SELECT + col2 + col0 / - col1 AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT 21 * + col1 * - ( + tab1.col1 ) AS col2 FROM tab1
----
-14196
-2100
-3549

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 64 + + col2 col1 FROM tab2 AS cor0
----
102
90
91

query I rowsort
SELECT ALL 13 * + cor0.col1 FROM tab0 AS cor0
----
1118
1183
1261

query I rowsort
SELECT + 39 FROM tab1, tab1 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT - - 55 + - cor0.col2 FROM tab0 AS cor0
----
-27
22
54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6314
SELECT + col1 * + col2 * + CAST( - col0 AS SIGNED ) - col1 AS col2 FROM tab2 AS cor0
----
-119711
-51051
-5890

skipif mysql # not compatible
query I rowsort label-6314
SELECT + col1 * + col2 * + CAST ( - col0 AS INTEGER ) - col1 AS col2 FROM tab2 AS cor0
----
-119711
-51051
-5890

query I rowsort
SELECT + col2 * - col0 + col2 AS col2 FROM tab1 cor0
----
-108
-3591
-7584

query I rowsort
SELECT + - cor0.col0 * cor0.col0 - cor0.col0 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT DISTINCT + col0 + + cor0.col0 AS col1 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT 13 * - cor0.col2 AS col1 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 548f1ff58c195dfdfe416b7dc8e34ea2

query I rowsort
SELECT DISTINCT - col2 + + ( col1 ) FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6320
SELECT ( col0 ) DIV col0 AS col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6320
SELECT ( col0 ) / col0 AS col0 FROM tab0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6321
SELECT + col1 DIV 30 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6321
SELECT + col1 / 30 AS col1 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6322
SELECT ( col2 ) DIV col2 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6322
SELECT ( col2 ) / col2 FROM tab1
----
1
1
1

query I rowsort
SELECT + col0 * tab0.col0 AS col2 FROM tab0
----
1225
576
7921

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6324
SELECT DISTINCT CAST( col2 AS SIGNED ) AS col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6324
SELECT DISTINCT CAST ( col2 AS INTEGER ) AS col1 FROM tab0
----
1
33
82

query I rowsort
SELECT - cor0.col0 * - col2 * + col1 AS col2 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT - + ( - col1 ) + col1 * + col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT DISTINCT 3 AS col0 FROM tab0, tab1 AS cor0
----
3

query I rowsort
SELECT DISTINCT - 11 FROM tab1 AS cor0
----
-11

query I rowsort
SELECT ALL + 35 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab0, tab1 AS cor2
----
243 values hashing to a9053bbf61b7425d382ef55c8671ca7d

onlyif mysql # use DIV operator for integer division
query I rowsort label-6330
SELECT DISTINCT + + col2 DIV - col0 - - col0 * col1 FROM tab2 AS cor0
----
1343
214
4602

skipif mysql # not compatible
query I rowsort label-6330
SELECT DISTINCT + + col2 / - col0 - - col0 * col1 FROM tab2 AS cor0
----
1343
214
4602

query I rowsort
SELECT ALL + col1 + ( col2 ) * col1 AS col0 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT + col2 * + 76 * + ( - col1 * - col0 ) + col1 * col2 AS col2 FROM tab0
----
258117
50480430
5179350

query I rowsort
SELECT col1 * + col1 - + col1 FROM tab1
----
156
650
90

query I rowsort
SELECT DISTINCT + 63 + - cor0.col0 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
-1
-17
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-6335
SELECT col1 + col2 DIV 80 FROM tab0
----
86
92
97

skipif mysql # not compatible
query I rowsort label-6335
SELECT col1 + col2 / 80 FROM tab0
----
86
92
97

query I rowsort
SELECT tab1.col1 - 55 FROM tab1
----
-29
-42
-45

query I rowsort
SELECT ALL 56 * cor0.col0 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 0d790a5163f0d35b7282ff69ac5b8d2c

query I rowsort
SELECT ALL + col0 * - col1 AS col1 FROM tab0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6339
SELECT + tab2.col2 DIV col0 FROM tab2
----
0
0
3

skipif mysql # not compatible
query I rowsort label-6339
SELECT + tab2.col2 / col0 FROM tab2
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 26 * + col2 + ( - col1 ) col2 FROM tab1 cor0
----
-1430
-1492
-2509

query I rowsort
SELECT col0 + col1 * tab0.col2 + + col1 FROM tab0
----
229
2948
7642

query I rowsort
SELECT - col1 + 44 * cor0.col2 FROM tab2 cor0
----
1085
1157
1655

query I rowsort
SELECT 21 * - col1 FROM tab0
----
-1806
-1911
-2037

query I rowsort
SELECT - 67 + - col2 FROM tab2 AS cor0
----
-105
-93
-94

query I rowsort
SELECT DISTINCT - 38 * col2 FROM tab2 AS cor0
----
-1026
-1444
-988

query I rowsort
SELECT ALL col0 * col1 * col0 - - 24 AS col1 FROM tab2 AS cor0
----
106121
1543
358980

onlyif mysql # use DIV operator for integer division
query I rowsort label-6347
SELECT + 93 + col0 DIV + col0 AS col0 FROM tab0 AS cor0
----
94
94
94

skipif mysql # not compatible
query I rowsort label-6347
SELECT + 93 + col0 / + col0 AS col0 FROM tab0 AS cor0
----
94
94
94

query I rowsort
SELECT ALL + 40 - - col2 * + col1 FROM tab0 cor0
----
137
2878
7502

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 44 * + cor0.col0 col0 FROM tab2 cor0
----
-308
-3432
-3476

query I rowsort
SELECT - col1 + col1 + - col2 AS col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT + cor0.col1 + col0 * - col0 AS col1 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT col1 * tab0.col1 + + col0 * col2 FROM tab0
----
15579
8188
9444

query I rowsort
SELECT DISTINCT + col2 + - col1 + + 23 * col1 FROM tab1
----
277
382
626

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + tab2.col2 + ( col1 + col2 ) * - col0 col0 FROM tab2
----
-2901
-5954
323

query I rowsort
SELECT ALL ( col1 ) + + tab1.col1 + - col2 FROM tab1
----
-2
-37
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-6356
SELECT ALL - col2 * + col0 + + 14 DIV col0 FROM tab0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-6356
SELECT ALL - col2 * + col0 + + 14 / col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT 40 * - col1 + - col2 AS col1 FROM tab2
----
-1267
-2386
-718

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col2 + ( + 54 ) ) col1 FROM tab0
----
-28
21
53

query I rowsort
SELECT DISTINCT + - col0 + + col2 * - 31 * + cor0.col1 FROM tab2 AS cor0
----
-20105
-25954
-47632

query I rowsort
SELECT + col1 * col1 * - 30 + + cor0.col1 + col1 AS col2 FROM tab1 AS cor0
----
-20228
-2980
-5044

query I rowsort
SELECT - + col1 * - col2 + + ( - col2 ) AS col2 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT DISTINCT + cor0.col1 + col1 * 6 AS col2 FROM tab2 AS cor0
----
119
217
413

onlyif mysql # use DIV operator for integer division
query I rowsort label-6363
SELECT DISTINCT col0 DIV col1 FROM tab1 cor0
----
0
6

skipif mysql # not compatible
query I rowsort label-6363
SELECT DISTINCT col0 / col1 FROM tab1 cor0
----
0
6

query I rowsort
SELECT + 1 * + col1 + - col0 AS col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT + 74 + tab1.col2 * + 2 + 12 AS col0 FROM tab1
----
194
200
278

query I rowsort
SELECT DISTINCT - + 81 + - col1 FROM tab1 AS cor0
----
-107
-91
-94

onlyif mysql # use DIV operator for integer division
query I rowsort label-6367
SELECT - 94 + + col0 DIV - cor0.col1 FROM tab2 AS cor0
----
-94
-95
-98

skipif mysql # not compatible
query I rowsort label-6367
SELECT - 94 + + col0 / - cor0.col1 FROM tab2 AS cor0
----
-94
-95
-98

query I rowsort
SELECT ALL + 72 * + col1 + + 33 AS col2 FROM tab2 AS cor0
----
1257
2265
4281

query I rowsort
SELECT ALL + col1 * - col2 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + col1 + col1 + col0 FROM tab2 AS cor0
----
113
196
69

query I rowsort
SELECT ALL - col2 * + col1 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + - col0 * col0 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL + - col1 + ( col0 ) AS col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT - col1 + - col2 + col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT col2 + 73 AS col0 FROM tab2 cor0
----
100
111
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6376
SELECT DISTINCT col2 * - CAST( ( - col0 ) * col1 AS SIGNED ) FROM tab2 AS cor0
----
119652
51034
5859

skipif mysql # not compatible
query I rowsort label-6376
SELECT DISTINCT col2 * - CAST ( ( - col0 ) * col1 AS INTEGER ) FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT - col2 * + cor0.col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT - col1 * - 91 + + col0 * col1 FROM tab2 cor0
----
2890
3038
9971

query I rowsort
SELECT ALL 69 + col1 * - 44 AS col1 FROM tab2
----
-1295
-2527
-679

query I rowsort
SELECT + + col0 + - ( - col2 ) + col2 AS col2 FROM tab2 AS cor0
----
130
155
61

query I rowsort
SELECT + col2 * 59 AS col1 FROM tab0 AS cor0
----
1947
4838
59

query I rowsort
SELECT ALL - + col1 + ( col0 ) AS col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT + col1 * col0 + col0 * cor0.col2 + + col1 * col1 FROM tab1 AS cor0
----
4388
8889
916

onlyif mysql # use DIV operator for integer division
query I rowsort label-6384
SELECT DISTINCT - + col1 DIV col1 FROM tab2 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-6384
SELECT DISTINCT - + col1 / col1 FROM tab2 AS cor0
----
-1

query I rowsort
SELECT ALL + col2 * 39 + col2 FROM tab0 AS cor0
----
1320
3280
40

query I rowsort
SELECT + col1 * + 2 AS col2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT DISTINCT col2 * 13 + col1 FROM tab1 AS cor0
----
1261
728
751

query I rowsort
SELECT + - ( cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - col2 * - col0 + col1 FROM tab1 AS cor0
----
188
3658
7693

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6390
SELECT ALL + - CAST( NULL AS DECIMAL ) * + 30 / + cor0.col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6390
SELECT ALL + - CAST ( NULL AS REAL ) * + 30 / + cor0.col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( - cor0.col1 ) * - cor0.col0 FROM tab1 cor0
----
1040
640
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6392
SELECT + CAST( - cor0.col0 AS SIGNED ) * col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-6392
SELECT + CAST ( - cor0.col0 AS INTEGER ) * col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - col2 - - col0 * + col1 FROM tab1 AS cor0
----
24
583
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-6394
SELECT ALL col2 DIV + 89 col2 FROM tab1 cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6394
SELECT ALL col2 / + 89 col2 FROM tab1 cor0
----
0
0
1

query I rowsort
SELECT DISTINCT + 31 + col0 + col0 * + col1 AS col1 FROM tab1 AS cor0
----
112
1151
735

query I rowsort
SELECT DISTINCT + - ( - col0 ) FROM tab2 AS cor0
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6397
SELECT - ( col2 ) * + col2 + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6397
SELECT - ( col2 ) * + col2 + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 + 14 * + col2 FROM tab0 cor0
----
-83
1057
376

query I rowsort
SELECT ALL 86 - cor0.col0 AS col2 FROM tab1 AS cor0
----
22
6
83

query I rowsort
SELECT DISTINCT + + col1 * - col1 AS col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT + col0 * + col0 * - col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 + - col0 col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL - 12 AS col0 FROM tab0
----
-12
-12
-12

query I rowsort
SELECT ALL - - cor0.col1 + + col2 AS col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT cor0.col1 * 74 FROM tab0, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to b18358795bfbf3992286a3ddb0617de3

query I rowsort
SELECT DISTINCT col0 * + col1 + + 51 * col2 FROM tab0 AS cor0
----
12281
3446
3747

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * col2 * + col1 + + col1 col1 FROM tab1
----
-16211
-36478
-5690

query I rowsort
SELECT cor0.col0 + 53 * col1 AS col0 FROM tab1 cor0
----
1381
594
769

query I rowsort
SELECT col2 * col1 + - col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT col2 + - col2 * col2 FROM tab0
----
-1056
-6642
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6411
SELECT ALL - col2 DIV + col0 + - col1 FROM tab0
----
-87
-91
-97

skipif mysql # not compatible
query I rowsort label-6411
SELECT ALL - col2 / + col0 + - col1 FROM tab0
----
-87
-91
-97

query I rowsort
SELECT DISTINCT + - 27 FROM tab1, tab0, tab2 AS cor0, tab2
----
-27

query I rowsort
SELECT DISTINCT + col2 + + 18 * 95 * + col0 FROM tab1
----
109497
136896
5184

query I rowsort
SELECT ALL col2 + col0 * + col1 + col1 FROM tab1
----
1149
158
707

query I rowsort
SELECT cor1.col2 AS col0 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab0 AS cor0 CROSS JOIN tab2, tab1, tab2 AS cor1
----
3645 values hashing to 6193516da5556fc054f35e0d2f4e5372

query I rowsort
SELECT 40 FROM tab2, tab0 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT 37 + col2 AS col1 FROM tab1 AS cor0
----
133
91
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 17 col1 FROM tab0 AS cor0
----
17
17
17

query I rowsort
SELECT ( col1 ) + col2 * + ( - cor0.col0 ) * + col1 AS col1 FROM tab2 AS cor0
----
-119593
-51017
-5828

query I rowsort
SELECT ALL - 50 + col1 * col0 AS col2 FROM tab0 AS cor0
----
2014
3345
8049

query I rowsort
SELECT DISTINCT - 10 FROM tab0 cor0
----
-10

query I rowsort
SELECT - + 14 AS col1 FROM tab0 AS cor0
----
-14
-14
-14

query I rowsort
SELECT - ( + cor0.col1 ) * col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT 4 * - ( + col0 ) AS col0 FROM tab0 AS cor0
----
-140
-356
-96

query I rowsort
SELECT ALL - cor0.col0 * - cor0.col1 FROM tab0 cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6427
SELECT DISTINCT + ( col2 ) DIV + col0 FROM tab1 AS cor0
----
0
1
18

skipif mysql # not compatible
query I rowsort label-6427
SELECT DISTINCT + ( col2 ) / + col0 FROM tab1 AS cor0
----
0
1
18

query I rowsort
SELECT ALL - - col0 * - col2 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( + col1 ) col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL + + cor0.col0 * cor0.col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT + 13 + + col2 AS col2 FROM tab2 AS cor0
----
39
40
51

query I rowsort
SELECT DISTINCT + - col2 + - col0 AS col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT - 64 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
-64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6434
SELECT col0 * - tab2.col2 * CAST( NULL AS SIGNED ) + - 81 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6434
SELECT col0 * - tab2.col2 * CAST ( NULL AS INTEGER ) + - 81 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6435
SELECT DISTINCT col2 + + cor0.col1 DIV 29 FROM tab2 cor0
----
28
38

skipif mysql # not compatible
query I rowsort label-6435
SELECT DISTINCT col2 + + cor0.col1 / 29 FROM tab2 cor0
----
28
38

query I rowsort
SELECT 42 AS col0 FROM tab0 cor0
----
42
42
42

query I rowsort
SELECT col0 + + col0 * - col2 FROM tab0 AS cor0
----
-7209
-768
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + 70 col0 FROM tab2 AS cor0
----
101
129
87

query I rowsort
SELECT DISTINCT - + col2 * col0 + col1 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT - col0 * + 55 AS col1 FROM tab0
----
-1320
-1925
-4895

query I rowsort
SELECT + col2 + - 59 AS col2 FROM tab2 cor0
----
-21
-32
-33

onlyif mysql # use DIV operator for integer division
query I rowsort label-6442
SELECT - - col1 + col0 DIV + 18 + + col1 AS col0 FROM tab0 AS cor0
----
173
186
195

skipif mysql # not compatible
query I rowsort label-6442
SELECT - - col1 + col0 / + 18 + + col1 AS col0 FROM tab0 AS cor0
----
173
186
195

query I rowsort
SELECT - - col2 + col2 AS col2 FROM tab2 AS cor0
----
52
54
76

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6444
SELECT ALL col1 * CAST( NULL AS SIGNED ) + cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6444
SELECT ALL col1 * CAST ( NULL AS INTEGER ) + cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col1 * - col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT - cor0.col0 * - ( - 93 ) * col0 + - 13 * - cor0.col0 - - col0 * ( col2 ) FROM tab2 cor0
----
-4277
-562770
-576384

query I rowsort
SELECT DISTINCT - cor0.col1 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - col1 col2 FROM tab1 AS cor0
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + - col2 * + col2 * col1 col1 FROM tab0 AS cor0
----
-194
-611975
-93740

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6450
SELECT + col1 + - 83 * - cor0.col1 * CAST( + col0 AS SIGNED ) FROM tab2 AS cor0
----
111486
18042
382025

skipif mysql # not compatible
query I rowsort label-6450
SELECT + col1 + - 83 * - cor0.col1 * CAST ( + col0 AS INTEGER ) FROM tab2 AS cor0
----
111486
18042
382025

query I rowsort
SELECT + col1 * 45 + cor0.col0 - - 27 * col0 AS col2 FROM tab2 AS cor0
----
1591
2977
4839

query I rowsort
SELECT + - col2 + col2 * + col1 * 9 FROM tab1 AS cor0
----
11136
12582
5073

query I rowsort
SELECT 44 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT - + 31 * - 11 - col1 FROM tab1 AS cor0
----
315
328
331

query I rowsort
SELECT + 12 FROM tab0, tab2 cor0, tab1 AS cor1, tab1 cor2
----
81 values hashing to c60b9398e29d6382e0d15363f9325811

query I rowsort
SELECT ALL + ( - col0 ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + 19 AS col2 FROM tab1 AS cor0
----
19
19
19

query I rowsort
SELECT + col2 + col2 * - 53 FROM tab1 AS cor0
----
-2808
-2964
-4992

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6459
SELECT DISTINCT col0 + col1 * - CAST( NULL AS SIGNED ) * 23 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6459
SELECT DISTINCT col0 + col1 * - CAST ( NULL AS INTEGER ) * 23 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT 12 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

query I rowsort
SELECT ALL - 45 FROM tab0
----
-45
-45
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-6462
SELECT cor0.col2 DIV 23 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 2635d85a67d05f98f4214769051408cf

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6462
SELECT cor0.col2 / 23 col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 2635d85a67d05f98f4214769051408cf

query I rowsort
SELECT - + col1 * - col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT tab1.col1 * tab1.col1 + - col1 FROM tab1
----
156
650
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 + + col2 col0 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT DISTINCT - col2 + col0 * - col2 FROM tab1 AS cor0
----
-216
-3705
-7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-6467
SELECT - + 88 + - col0 DIV - col1 + 18 AS col0 FROM tab2 AS cor0
----
-66
-69
-70

skipif mysql # not compatible
query I rowsort label-6467
SELECT - + 88 + - col0 / - col1 + 18 AS col0 FROM tab2 AS cor0
----
-66
-69
-70

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6468
SELECT DISTINCT + col2 + + col2 + CAST( NULL AS SIGNED ) * col1 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6468
SELECT DISTINCT + col2 + + col2 + CAST ( NULL AS INTEGER ) * col1 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - ( - col1 ) + - cor0.col2 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6470
SELECT DISTINCT + col1 + + col2 * + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6470
SELECT DISTINCT + col1 + + col2 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + col2 * col2 + col2 * - col0 AS col2 FROM tab2 AS cor0
----
-1352
-1558
540

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6472
SELECT DISTINCT - col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6472
SELECT DISTINCT - col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab2 cor0
----
NULL

query I rowsort
SELECT ALL + + cor0.col1 + cor0.col1 AS col2 FROM tab2 AS cor0
----
118
34
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 * cor0.col1 col2 FROM tab0 cor0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor1.col2 col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
1
33
82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6476
SELECT ALL - - col1 + + CAST( - col0 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
2
62
62

skipif mysql # not compatible
query I rowsort label-6476
SELECT ALL - - col1 + + CAST ( - col0 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
2
62
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6477
SELECT DISTINCT + col1 + - CAST( col1 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6477
SELECT DISTINCT + col1 + - CAST ( col1 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT ALL - col0 + + 25 AS col0 FROM tab2 AS cor0
----
-53
-54
18

query I rowsort
SELECT 7 + col2 AS col1 FROM tab2 AS cor0
----
33
34
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-6480
SELECT DISTINCT 17 DIV + col0 + col2 FROM tab1 AS cor0
----
57
59
96

skipif mysql # not compatible
query I rowsort label-6480
SELECT DISTINCT 17 / + col0 + col2 FROM tab1 AS cor0
----
57
59
96

query I rowsort
SELECT - col0 * + col0 + - col1 + + col1 * col0 FROM tab2 AS cor0
----
-1541
-4915
137

query I rowsort
SELECT - col2 - col1 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT DISTINCT col0 * + col0 + col0 * + col2 AS col0 FROM tab0 AS cor0
----
1260
1368
15219

onlyif mysql # use DIV operator for integer division
query I rowsort label-6484
SELECT DISTINCT 76 + col1 DIV - col0 col0 FROM tab1 AS cor0
----
68
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6484
SELECT DISTINCT 76 + col1 / - col0 col0 FROM tab1 AS cor0
----
68
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-6485
SELECT + col2 DIV col2 col0 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6485
SELECT + col2 / col2 col0 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + col0 col2 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6487
SELECT col2 * - col2 + - 86 + - col0 DIV col0 FROM tab0 AS cor0
----
-1176
-6811
-88

skipif mysql # not compatible
query I rowsort label-6487
SELECT col2 * - col2 + - 86 + - col0 / col0 FROM tab0 AS cor0
----
-1176
-6811
-88

query I rowsort
SELECT DISTINCT 6 * + cor0.col1 FROM tab2 cor0
----
102
186
354

query I rowsort
SELECT - 77 * col0 + col0 + + 62 FROM tab2 cor0
----
-470
-5866
-5942

query I rowsort
SELECT DISTINCT + 60 * + col0 * tab2.col1 FROM tab2
----
13020
276120
80580

onlyif mysql # use DIV operator for integer division
query I rowsort label-6491
SELECT DISTINCT + ( + col1 ) DIV col0 FROM tab0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-6491
SELECT DISTINCT + ( + col1 ) / col0 FROM tab0
----
1
2
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-6492
SELECT col0 DIV - tab1.col2 FROM tab1
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6492
SELECT col0 / - tab1.col2 FROM tab1
----
-1
0
0

query I rowsort
SELECT - 44 * + 66 FROM tab2
----
-2904
-2904
-2904

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 94 * + col0 col1 FROM tab0 AS cor0
----
2256
3290
8366

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6495
SELECT CAST( + col2 AS SIGNED ) + + tab0.col1 AS col1 FROM tab0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-6495
SELECT CAST ( + col2 AS INTEGER ) + + tab0.col1 AS col1 FROM tab0
----
119
173
98

query I rowsort
SELECT DISTINCT - col2 - - 64 FROM tab2
----
26
37
38

query I rowsort
SELECT - ( col1 * - col1 ) + 58 + col0 FROM tab0
----
7478
8428
9502

onlyif mysql # use DIV operator for integer division
query I rowsort label-6498
SELECT DISTINCT + col0 + - col1 + + ( + col2 ) DIV col0 FROM tab1 AS cor0
----
-5
54
68

skipif mysql # not compatible
query I rowsort label-6498
SELECT DISTINCT + col0 + - col1 + + ( + col2 ) / col0 FROM tab1 AS cor0
----
-5
54
68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col2 col1 FROM tab0 AS cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col0 + col0 * - col1 col2 FROM tab2 cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL + + col1 * col2 + - col0 * col1 AS col2 FROM tab1 AS cor0
----
-70
1326
208

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col0 AS REAL ) FROM tab0
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-6503
SELECT - col2 DIV + 84 + col1 + - tab1.col0 AS col2 FROM tab1
----
-54
-68
23

skipif mysql # not compatible
query I rowsort label-6503
SELECT - col2 / + 84 + col1 + - tab1.col0 AS col2 FROM tab1
----
-54
-68
23

query I rowsort
SELECT ALL 18 - col0 FROM tab1
----
-46
-62
15

query I rowsort
SELECT DISTINCT + col2 * col2 + + col0 FROM tab2
----
1523
736
754

onlyif mysql # use DIV operator for integer division
query I rowsort label-6506
SELECT col0 DIV col1 + - col2 FROM tab2 AS cor0
----
-25
-27
-34

skipif mysql # not compatible
query I rowsort label-6506
SELECT col0 / col1 + - col2 FROM tab2 AS cor0
----
-25
-27
-34

query I rowsort
SELECT DISTINCT - col2 + + cor0.col2 * + ( col0 ) AS col2 FROM tab1 cor0
----
108
3591
7584

query I rowsort
SELECT DISTINCT - cor0.col1 - col0 FROM tab1 AS cor0
----
-29
-74
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 * + col0 col0 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-6510
SELECT ALL + ( col1 ) DIV + col1 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6510
SELECT ALL + ( col1 ) / + col1 FROM tab0 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 + - col2 col1 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT + + col2 * - cor0.col0 - + col2 AS col0 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT ALL + - col1 * - cor0.col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - 78 * - col0 * 93 FROM tab1
----
21762
464256
580320

query I rowsort
SELECT - 31 + - col0 AS col0 FROM tab1 AS cor0
----
-111
-34
-95

query I rowsort
SELECT DISTINCT + col2 * + col1 * + cor0.col2 + col1 * + col0 FROM tab0 AS cor0
----
3492
619983
95718

onlyif mysql # use DIV operator for integer division
query I rowsort label-6517
SELECT col0 - - ( + 90 ) DIV col2 AS col0 FROM tab1
----
4
65
80

skipif mysql # not compatible
query I rowsort label-6517
SELECT col0 - - ( + 90 ) / col2 AS col0 FROM tab1
----
4
65
80

query I rowsort
SELECT DISTINCT col0 * - 5 AS col2 FROM tab1
----
-15
-320
-400

query I rowsort
SELECT 13 AS col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to a90d0f37cec603ae1bc0a60dc7fbaeed

query I rowsort
SELECT + col0 + 66 * col0 FROM tab0
----
1608
2345
5963

onlyif mysql # use DIV operator for integer division
query I rowsort label-6521
SELECT - - cor0.col0 DIV + col0 AS col1 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6521
SELECT - - cor0.col0 / + col0 AS col1 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - + cor0.col0 - col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT col1 * tab1.col2 FROM tab1
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6524
SELECT DISTINCT + col2 * col1 DIV tab2.col1 AS col2 FROM tab2
----
26
27
38

skipif mysql # not compatible
query I rowsort label-6524
SELECT DISTINCT + col2 * col1 / tab2.col1 AS col2 FROM tab2
----
26
27
38

query I rowsort
SELECT - + 71 + col0 * - col0 FROM tab1 AS cor0
----
-4167
-6471
-80

query I rowsort
SELECT ALL col2 * - 82 + + col2 * cor0.col2 FROM tab0 AS cor0
----
-1617
-81
0

query I rowsort
SELECT ALL - + 3 + - col2 AS col0 FROM tab1 AS cor0
----
-57
-60
-99

query I rowsort
SELECT col2 * - 84 AS col2 FROM tab1 AS cor0
----
-4536
-4788
-8064

query I rowsort
SELECT DISTINCT + + 92 FROM tab0 AS cor0
----
92

query I rowsort
SELECT 14 + ( col2 ) FROM tab2
----
40
41
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-6531
SELECT ALL - + 93 - - col0 DIV + col2 col1 FROM tab1 AS cor0
----
-92
-93
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6531
SELECT ALL - + 93 - - col0 / + col2 col1 FROM tab1 AS cor0
----
-92
-93
-93

query I rowsort
SELECT ( 73 ) FROM tab0 AS cor0
----
73
73
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + cor0.col1 col2 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6534
SELECT DISTINCT + + col2 DIV col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6534
SELECT DISTINCT + + col2 / col1 FROM tab0 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6535
SELECT ALL - CAST( 17 AS SIGNED ) * + col1 FROM tab1 AS cor0
----
-170
-221
-442

skipif mysql # not compatible
query I rowsort label-6535
SELECT ALL - CAST ( 17 AS INTEGER ) * + col1 FROM tab1 AS cor0
----
-170
-221
-442

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - 62 ) col0 FROM tab0 AS cor0
----
-62
-62
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6537
SELECT - CAST( NULL AS DECIMAL ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6537
SELECT - CAST ( NULL AS REAL ) FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + 34 AS col0 FROM tab1 AS cor0
----
-34
-34
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-6539
SELECT DISTINCT col2 * + 22 - cor0.col1 DIV - col0 FROM tab1 AS cor0
----
1196
1254
2112

skipif mysql # not compatible
query I rowsort label-6539
SELECT DISTINCT col2 * + 22 - cor0.col1 / - col0 FROM tab1 AS cor0
----
1196
1254
2112

query I rowsort
SELECT + - ( col1 ) * col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + ( - 49 ) * col0 AS col1 FROM tab0 AS cor0
----
-1176
-1715
-4361

query I rowsort
SELECT DISTINCT 32 AS col1 FROM tab1 AS cor0
----
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-6543
SELECT ALL - col2 DIV - 5 AS col2 FROM tab1 AS cor0
----
10
11
19

skipif mysql # not compatible
query I rowsort label-6543
SELECT ALL - col2 / - 5 AS col2 FROM tab1 AS cor0
----
10
11
19

query I rowsort
SELECT - 33 AS col0 FROM tab1 cor0
----
-33
-33
-33

query I rowsort
SELECT ALL + col1 + - col1 * + col0 AS col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT - - ( 62 ) AS col2 FROM tab0 AS cor0
----
62

query I rowsort
SELECT ALL col1 * + col1 AS col2 FROM tab1 AS cor0
----
100
169
676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6548
SELECT ALL CAST( NULL AS SIGNED ) AS col0 FROM tab1, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6548
SELECT ALL CAST ( NULL AS INTEGER ) AS col0 FROM tab1, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + cor0.col0 col0 FROM tab1 AS cor0
----
3
64
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6550
SELECT col0 / CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6550
SELECT col0 / CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6551
SELECT + ( - col2 ) * col2 DIV + ( 81 * col2 ) - - col0 FROM tab1 AS cor0
----
3
64
79

skipif mysql # not compatible
query I rowsort label-6551
SELECT + ( - col2 ) * col2 / + ( 81 * col2 ) - - col0 FROM tab1 AS cor0
----
3
64
79

query I rowsort
SELECT + col1 * + col2 * - col0 AS col1 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT 44 + col2 * - col0 AS col1 FROM tab1 cor0
----
-118
-3604
-7636

query I rowsort
SELECT col1 * - 12 FROM tab0 cor0
----
-1032
-1092
-1164

onlyif mysql # use DIV operator for integer division
query I rowsort label-6555
SELECT tab0.col1 DIV 96 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6555
SELECT tab0.col1 / 96 FROM tab0
----
0
0
1

query I rowsort
SELECT + col0 * + 75 AS col0 FROM tab2
----
525
5850
5925

onlyif mysql # use DIV operator for integer division
query I rowsort label-6557
SELECT + col0 DIV - col0 FROM tab2
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6557
SELECT + col0 / - col0 FROM tab2
----
-1
-1
-1

query I rowsort
SELECT ALL col2 * - 17 + + col1 FROM tab2
----
-383
-428
-629

query I rowsort
SELECT - col2 * col2 + + col1 AS col2 FROM tab2
----
-1427
-617
-698

query I rowsort
SELECT - + col2 * col1 + col0 AS col1 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT + - cor0.col0 * cor0.col0 AS col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT - ( + col2 ) * col2 AS col2 FROM tab0
----
-1
-1089
-6724

query I rowsort
SELECT + ( col2 ) AS col1 FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT col1 * col2 * col1 AS col2 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT - col0 - tab2.col1 * + col2 AS col1 FROM tab2
----
-1612
-725
-844

query I rowsort
SELECT DISTINCT - 69 * + col2 + col0 FROM tab1 cor0
----
-3723
-3869
-6544

query I rowsort
SELECT ALL + + 34 * - col2 + cor0.col2 AS col2 FROM tab0 AS cor0
----
-1089
-2706
-33

query I rowsort
SELECT ALL - ( + col2 ) * + ( col2 * cor0.col1 ) + - col1 AS col0 FROM tab2 AS cor0
----
-22630
-24565
-39943

query I rowsort
SELECT DISTINCT + + 44 + + cor0.col2 - 81 FROM tab2 AS cor0
----
-10
-11
1

query I rowsort
SELECT ALL + col0 * + col1 FROM tab2 cor0
----
1343
217
4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * - col1 col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT - col0 * col0 * - 59 FROM tab2 cor0
----
2891
358956
368219

query I rowsort
SELECT DISTINCT + cor0.col1 + col1 * col2 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT + col0 + col1 * cor0.col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT ALL + - col0 * col1 + 92 - col2 AS col0 FROM tab0 cor0
----
-2005
-3304
-8089

query I rowsort
SELECT ALL - - col0 * col0 + col2 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT - 97 AS col0 FROM tab0
----
-97
-97
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 * - col2 col1 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + 22 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
22

query I rowsort
SELECT ALL - col0 * + col0 AS col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT - col1 * ( + 36 ) FROM tab0 cor0
----
-3096
-3276
-3492

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + ( col0 * - col1 ) col1 FROM tab0 cor0
----
-118825
-49536
-720811

query I rowsort
SELECT ALL - 60 FROM tab0, tab2 AS cor0
----
9 values hashing to 067a4b5daf8747042e3b07ca8459859f

query I rowsort
SELECT ALL + cor1.col0 AS col0 FROM tab1, tab1 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to e28bf7f922650ca423ade3642ce0285b

query I rowsort
SELECT DISTINCT - 39 FROM tab2, tab0 cor0
----
-39

onlyif mysql # use DIV operator for integer division
query I rowsort label-6586
SELECT DISTINCT - tab0.col1 DIV tab0.col2 FROM tab0, tab2 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-6586
SELECT DISTINCT - tab0.col1 / tab0.col2 FROM tab0, tab2 AS cor0
----
-1
-2
-97

query I rowsort
SELECT - ( 94 ) * col0 - + 3 FROM tab0 AS cor0
----
-2259
-3293
-8369

onlyif mysql # use DIV operator for integer division
query I rowsort label-6588
SELECT - ( + ( - col2 ) ) DIV - col2 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6588
SELECT - ( + ( - col2 ) ) / - col2 AS col0 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - col2 + 34 FROM tab2 AS cor0
----
-4
7
8

query I rowsort
SELECT col0 * col2 * col0 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT - + col0 + col1 + cor0.col0 AS col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT 19 * - 81 AS col0 FROM tab1
----
-1539

query I rowsort
SELECT DISTINCT - - col1 + cor0.col1 * + col0 FROM tab1 AS cor0
----
104
1053
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-6594
SELECT - 66 DIV + 59 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6594
SELECT - 66 / + 59 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6595
SELECT + - CAST( - col0 AS SIGNED ) + - col1 * - col0 FROM tab2 AS cor0
----
1422
224
4680

skipif mysql # not compatible
query I rowsort label-6595
SELECT + - CAST ( - col0 AS INTEGER ) + - col1 * - col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT + + cor0.col0 + col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT DISTINCT col0 + col1 * + 98 * col1 FROM tab0
----
724832
811627
922117

query I rowsort
SELECT 92 * col0 * 48 AS col1 FROM tab0 AS cor0
----
105984
154560
393024

query I rowsort
SELECT + col2 - col2 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 - + 88 * - col2 FROM tab1
----
4778
5026
8461

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - ( col0 ) col1 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT cor0.col1 * 50 - + 36 FROM tab0 AS cor0
----
4264
4514
4814

query I rowsort
SELECT DISTINCT tab1.col2 - + col0 * + tab1.col1 FROM tab1
----
-24
-583
-944

query I rowsort
SELECT col1 + 21 FROM tab0
----
107
112
118

query I rowsort
SELECT - + cor0.col2 + - cor0.col1 AS col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT + cor0.col0 + + 51 - - 76 AS col2 FROM tab0 AS cor0
----
151
162
216

onlyif mysql # use DIV operator for integer division
query I rowsort label-6607
SELECT cor0.col2 + + col1 DIV - cor0.col1 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-6607
SELECT cor0.col2 + + col1 / - cor0.col1 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT DISTINCT + + 61 FROM tab0 AS cor0
----
61

query I rowsort
SELECT + - ( - col2 ) + cor0.col1 * col2 AS col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL + 46 * ( col0 ) FROM tab0 AS cor0
----
1104
1610
4094

query I rowsort
SELECT + 15 + col2 * - col1 * + col1 AS col1 FROM tab0 AS cor0
----
-244053
-679027
-9394

query I rowsort
SELECT col2 * - col0 * + cor0.col0 + 62 - col0 * col0 * 34 FROM tab2 AS cor0
----
-2927
-364978
-449290

query I rowsort
SELECT ALL - - col2 * + 88 FROM tab1 AS cor0
----
4752
5016
8448

query I rowsort
SELECT DISTINCT ( + col1 ) AS col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT col1 * - col1 * + col0 AS col2 FROM tab0 cor0
----
-177504
-329315
-737009

query I rowsort
SELECT ALL + col0 * + col1 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT + + col2 + + col2 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL + col0 * + col0 + - col2 + + col2 AS col0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT - - 24 AS col0 FROM tab1 AS cor0
----
24

query I rowsort
SELECT cor0.col0 * ( col2 ) * col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT - col1 + 86 * + cor0.col2 FROM tab2 cor0
----
2177
2291
3251

query I rowsort
SELECT DISTINCT col1 + - col0 * 72 AS col2 FROM tab1 AS cor0
----
-190
-4598
-5747

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6623
SELECT - col0 * + CAST( NULL AS SIGNED ) * - col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6623
SELECT - col0 * + CAST ( NULL AS INTEGER ) * - col1 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 * + col0 AS col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT - col0 - col2 AS col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT + col0 + + col2 * + col0 AS col1 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT + col2 * - 3 AS col2 FROM tab2 AS cor0
----
-114
-78
-81

query I rowsort
SELECT ALL + col1 + + col2 AS col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT 16 FROM tab0
----
16

query I rowsort
SELECT + 89 + + col2 FROM tab0
----
122
171
90

query I rowsort
SELECT 29 * + col1 * 74 + - col2 AS col1 FROM tab2
----
126588
36444
66499

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6632
SELECT ALL - + col2 + CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6632
SELECT ALL - + col2 + CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col1 * + 91 * col2 + + col0 AS col0 FROM tab1 AS cor0
----
-113488
-127761
-51806

query I rowsort
SELECT DISTINCT - col1 * 58 AS col0 FROM tab0 cor0
----
-4988
-5278
-5626

query I rowsort
SELECT DISTINCT + - col2 * + col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + - col2 + col2 * - 77 FROM tab2 AS cor0
----
-2028
-2106
-2964

query I rowsort
SELECT - - col0 + ( - 20 ) FROM tab1 AS cor0
----
-17
44
60

query I rowsort
SELECT ALL col0 + + 79 AS col0 FROM tab1 AS cor0
----
143
159
82

query I rowsort
SELECT DISTINCT 7 * + cor0.col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
231
574
7

query I rowsort
SELECT DISTINCT 12 AS col0 FROM tab2, tab0 AS cor0
----
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 99 * + 15 + col1 col1 FROM tab2 AS cor0
----
-1426
-1454
-1468

onlyif mysql # use DIV operator for integer division
query I rowsort label-6642
SELECT + - 39 DIV - cor0.col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6642
SELECT + - 39 / - cor0.col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 + + 60 - col0 FROM tab2 AS cor0
----
-2
41
84

query I rowsort
SELECT DISTINCT cor0.col0 * + col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT 83 * - ( cor0.col1 * 7 ) AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to f502496bd3cfedea7162dc60308fa135

query I rowsort
SELECT ALL col1 * - col2 AS col0 FROM tab2
----
-1534
-646
-837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 71 * + col1 * col1 col1 FROM tab1
----
11999
47996
7100

query I rowsort
SELECT ALL + ( + col1 ) FROM tab0
----
86
91
97

query I rowsort
SELECT ALL 91 - - col1 FROM tab1 AS cor0
----
101
104
117

query I rowsort
SELECT DISTINCT - col2 * + col0 AS col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - + 96 + - col0 FROM tab0 AS cor0
----
-120
-131
-185

query I rowsort
SELECT ALL - - 16 * col2 + + col1 + col1 FROM tab2 AS cor0
----
494
534
642

query I rowsort
SELECT DISTINCT - + 27 + col2 FROM tab0 cor0
----
-26
55
6

query I rowsort
SELECT - 72 + col0 AS col1 FROM tab0
----
-37
-48
17

query I rowsort
SELECT ALL - col0 + 76 FROM tab1
----
-4
12
73

query I rowsort
SELECT col1 + - tab0.col1 + - col2 * + ( 19 * col1 ) AS col1 FROM tab0
----
-141778
-1843
-53922

query I rowsort
SELECT ALL + tab0.col1 + col1 AS col2 FROM tab0
----
172
182
194

query I rowsort
SELECT ALL - col0 * 55 * col0 + + ( col0 ) FROM tab1
----
-225216
-351920
-492

query I rowsort
SELECT DISTINCT col0 + col1 * col1 FROM tab2
----
3559
368
968

query I rowsort
SELECT 9 + col0 AS col2 FROM tab2 AS cor0
----
16
87
88

query I rowsort
SELECT ALL - ( + col2 ) * + col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL cor0.col0 * col2 + col0 FROM tab1 cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT + col1 + col2 AS col1 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - - col0 * + col2 + + cor0.col2 AS col0 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT + col1 * col1 AS col0 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT - + 85 AS col2 FROM tab1 AS cor0
----
-85
-85
-85

query I rowsort
SELECT col2 * col0 * col2 FROM tab1 AS cor0
----
207936
737280
8748

query I rowsort
SELECT DISTINCT + col1 * col2 * - 66 + 72 FROM tab0 AS cor0
----
-187236
-492420
-6330

query I rowsort
SELECT DISTINCT cor0.col0 + cor0.col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL col0 + - col2 - 19 AS col1 FROM tab1 AS cor0
----
-12
-35
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 34 + col1 col1 FROM tab0 AS cor0
----
120
125
131

query I rowsort
SELECT - 57 FROM tab1, tab1 AS cor0
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

query I rowsort
SELECT ALL + 11 AS col1 FROM tab0
----
11
11
11

query I rowsort
SELECT + cor1.col0 FROM tab1, tab2 cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT + + col2 + col0 * - col2 AS col0 FROM tab0 AS cor0
----
-34
-7216
-759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6676
SELECT - CAST( NULL AS SIGNED ) + col1 * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6676
SELECT - CAST ( NULL AS INTEGER ) + col1 * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col1 * cor0.col0 AS col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT - 80 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 4dde3bd5652d30396b9cadd0e2cfb680

query I rowsort
SELECT - - ( - col1 ) * ( col2 + + col0 * col1 ) AS col0 FROM tab1 cor0
----
-14768
-3432
-6970

query I rowsort
SELECT + - ( + cor0.col1 ) AS col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + cor0.col1 * - col2 - - ( col0 ) * col0 FROM tab0 cor0
----
-2262
1128
459

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 64 * - col0 col2 FROM tab2 AS cor0
----
-448
-4992
-5056

onlyif mysql # use DIV operator for integer division
query I rowsort label-6683
SELECT ALL + 46 DIV + ( col0 ) FROM tab2
----
0
0
6

skipif mysql # not compatible
query I rowsort label-6683
SELECT ALL + 46 / + ( col0 ) FROM tab2
----
0
0
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6684
SELECT + tab2.col2 * ( col2 ) + CAST( NULL AS SIGNED ) * - 41 * - col1 col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6684
SELECT + tab2.col2 * ( col2 ) + CAST ( NULL AS INTEGER ) * - 41 * - col1 col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * - col2 + - tab0.col1 FROM tab0
----
-194
-2924
-7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-6686
SELECT + col0 + + col2 DIV col2 FROM tab1
----
4
65
81

skipif mysql # not compatible
query I rowsort label-6686
SELECT + col0 + + col2 / col2 FROM tab1
----
4
65
81

query I rowsort
SELECT DISTINCT + 7 FROM tab2, tab0 AS cor0
----
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - col0 ) col2 FROM tab0
----
24
35
89

query I rowsort
SELECT ALL + cor0.col0 * col2 + col1 AS col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT - cor0.col2 + + col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT + + col2 + 10 AS col2 FROM tab2 AS cor0
----
36
37
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-6692
SELECT ALL + + col0 DIV - 59 + - 68 AS col1 FROM tab2 cor0
----
-68
-69
-69

skipif mysql # not compatible
query I rowsort label-6692
SELECT ALL + + col0 / - 59 + - 68 AS col1 FROM tab2 cor0
----
-68
-69
-69

query I rowsort
SELECT DISTINCT col2 * col2 AS col1 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT col1 * - cor0.col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - + col1 * + col1 + + col0 FROM tab2 AS cor0
----
-210
-3403
-954

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 * col2 + col2 + col1 col2 FROM tab2 AS cor0
----
-1449
-591
-779

query I rowsort
SELECT DISTINCT col0 * ( - ( - col0 ) ) FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT - cor0.col0 + 74 * + col2 * col0 FROM tab1 AS cor0
----
11985
269888
568240

query I rowsort
SELECT ALL - col1 * - col0 + + col2 * - col0 * cor0.col2 FROM tab2 cor0
----
-112733
-48126
-4886

skipif mysql # not compatible
query I rowsort
SELECT CAST ( col0 AS REAL ) AS col2 FROM tab0 AS cor0
----
24
35
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6701
SELECT DISTINCT CAST( + 16 AS SIGNED ) AS col0 FROM tab0, tab1 AS cor0
----
16

skipif mysql # not compatible
query I rowsort label-6701
SELECT DISTINCT CAST ( + 16 AS INTEGER ) AS col0 FROM tab0, tab1 AS cor0
----
16

query I rowsort
SELECT - tab2.col1 + - 47 AS col0 FROM tab2
----
-106
-64
-78

query I rowsort
SELECT + col1 * - col2 + + col2 AS col0 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT - 13 AS col0 FROM tab1 AS cor0
----
-13
-13
-13

query I rowsort
SELECT 96 * - col1 AS col1 FROM tab0 AS cor0
----
-8256
-8736
-9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6706
SELECT ALL - + CAST( NULL AS SIGNED ) * col0 + col0 * 68 / 85 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6706
SELECT ALL - + CAST ( NULL AS INTEGER ) * col0 + col0 * 68 / 85 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 78 * col2 FROM tab0 AS cor0
----
-2574
-6396
-78

query I rowsort
SELECT tab0.col0 * 84 * 21 AS col0 FROM tab0
----
156996
42336
61740

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col0 * - col1 col2 FROM tab1
----
-1040
-640
-78

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab0 AS cor2
----
3645 values hashing to 35998cdc87c8b13ea047f14c9f5dc8d6

query I rowsort
SELECT + col0 + - 69 AS col2 FROM tab2 AS cor0
----
-62
10
9

query I rowsort
SELECT 34 + 48 AS col0 FROM tab2 AS cor0
----
82
82
82

query I rowsort
SELECT DISTINCT + col0 + + col2 * - tab2.col0 * col2 AS col0 FROM tab2
----
-113997
-5096
-52650

onlyif mysql # use DIV operator for integer division
query I rowsort label-6714
SELECT - cor0.col2 DIV - 19 + cor0.col1 AS col1 FROM tab0 AS cor0
----
87
95
97

skipif mysql # not compatible
query I rowsort label-6714
SELECT - cor0.col2 / - 19 + cor0.col1 AS col1 FROM tab0 AS cor0
----
87
95
97

query I rowsort
SELECT ALL ( - col0 ) + - ( - col2 ) AS col1 FROM tab2 AS cor0
----
-41
-52
20

onlyif mysql # use DIV operator for integer division
query I rowsort label-6716
SELECT DISTINCT - - col1 DIV col1 - col1 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-6716
SELECT DISTINCT - - col1 / col1 - col1 FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT + col1 * col0 AS col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT + col2 * ( + 62 * - cor0.col0 ) + - 72 AS col2 FROM tab2 AS cor0
----
-11790
-125808
-186196

query I rowsort
SELECT col0 + + col1 * 49 * col0 - + ( + col2 ) * - cor0.col2 AS col1 FROM tab1 AS cor0
----
34673
60256
6741

query I rowsort
SELECT - + col1 * ( + col0 ) * - col2 - col0 AS col0 FROM tab2 AS cor0
----
119574
50955
5852

query I rowsort
SELECT + - col2 * 4 + + cor0.col0 * col0 FROM tab1 AS cor0
----
-207
3868
6016

query I rowsort
SELECT 5 AS col2 FROM tab0 cor0
----
5
5
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 0 + col1 + col0 col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL + - cor0.col0 + - cor0.col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL + ( + col2 ) FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT ALL + - col0 * col2 AS col1 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL - col2 + cor0.col0 * col0 * - col0 AS col1 FROM tab2 AS cor0
----
-370
-474578
-493077

query I rowsort
SELECT DISTINCT - 15 FROM tab2 AS cor0
----
-15

onlyif mysql # use DIV operator for integer division
query I rowsort label-6729
SELECT - cor0.col0 DIV + cor0.col0 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6729
SELECT - cor0.col0 / + cor0.col0 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT + + col0 * col2 AS col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT + col0 + - 2 AS col1 FROM tab2
----
5
76
77

query I rowsort
SELECT + ( 88 ) FROM tab2
----
88
88
88

query I rowsort
SELECT DISTINCT - col0 * + col0 * - col2 AS col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT 41 - + 64 FROM tab1
----
-23
-23
-23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6735
SELECT + CAST( - col1 AS SIGNED ) col1 FROM tab1
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6735
SELECT + CAST ( - col1 AS INTEGER ) col1 FROM tab1
----
-10
-13
-26

query IIIIIIIII rowsort
SELECT * FROM tab1, tab0, tab2 AS cor0 WHERE NULL <= ( NULL )
----

query I rowsort
SELECT - 51 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 08d3853e39924d3c636260a6dd856837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 - - col1 col0 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ALL - col0 * - cor0.col2 + ( cor0.col1 ) FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL - 81 + + cor0.col0 FROM tab1 AS cor0
----
-1
-17
-78

query I rowsort
SELECT ALL - + col2 * + col0 * col2 - + col0 AS col1 FROM tab1 cor0
----
-208000
-737360
-8751

query I rowsort
SELECT DISTINCT + + cor0.col0 * col2 - - col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT + col2 + + col2 * - col2 AS col0 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT DISTINCT - ( 29 ) FROM tab2, tab0 AS cor0
----
-29

query I rowsort
SELECT ALL + - ( ( - col2 ) ) * - col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + + col1 + + col2 AS col2 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT col2 + 53 FROM tab2
----
79
80
91

query IIIIIIIIIIII rowsort
SELECT * FROM tab0 cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 AS cor2
----
972 values hashing to 88213a0de4c0a44aaefe8bbffbcaf44a

query I rowsort
SELECT + - 81 + cor0.col2 AS col2 FROM tab2 AS cor0
----
-43
-54
-55

query I rowsort
SELECT DISTINCT 79 * tab1.col1 AS col0 FROM tab1, tab2 AS cor0
----
1027
2054
790

query I rowsort
SELECT - ( + col2 ) + tab0.col2 * + col2 AS col2 FROM tab0
----
0
1056
6642

query I rowsort
SELECT DISTINCT + cor1.col1 FROM tab1, tab2 AS cor0, tab1 cor1
----
10
13
26

query I rowsort
SELECT - ( 15 ) AS col0 FROM tab2 cor0
----
-15
-15
-15

query I rowsort
SELECT 48 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 8b09cc2c99c2102036162d063e0e5a4b

query I rowsort
SELECT ALL + col2 * 96 + col1 AS col0 FROM tab0 AS cor0
----
193
3254
7963

query I rowsort
SELECT DISTINCT col2 + + col2 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT DISTINCT + - 92 + ( col0 ) AS col2 FROM tab2 AS cor0
----
-13
-14
-85

query I rowsort
SELECT tab0.col0 * 55 FROM tab0
----
1320
1925
4895

query I rowsort
SELECT DISTINCT col0 * + col2 * col0 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT ALL col2 + + col2 * + col2 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT ALL 57 AS col0 FROM tab1 AS cor0
----
57
57
57

query I rowsort
SELECT DISTINCT + 22 + 97 FROM tab0 AS cor0
----
119

query I rowsort
SELECT DISTINCT - 21 + col0 * + col1 FROM tab2 AS cor0
----
1322
196
4581

query I rowsort
SELECT + ( + 53 ) + col2 * - col2 FROM tab1 AS cor0
----
-2863
-3196
-9163

query I rowsort
SELECT ALL - 24 * col0 AS col0 FROM tab1 AS cor0
----
-1536
-1920
-72

query I rowsort
SELECT - + 75 * + col0 FROM tab0 cor0
----
-1800
-2625
-6675

query I rowsort
SELECT + 86 FROM tab0, tab1 AS cor0 CROSS JOIN tab1
----
27 values hashing to ed1a39c2752ca3723602e4a92c54bbc4

query I rowsort
SELECT ALL + ( + cor0.col1 ) AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - 66 * - 86 FROM tab0 AS cor0
----
5676
5676
5676

onlyif mysql # use DIV operator for integer division
query I rowsort label-6770
SELECT CAST( col2 AS SIGNED ) * col1 + 32 + col0 DIV col2 col2 FROM tab1 AS cor0
----
1280
1436
603

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6770
SELECT CAST ( col2 AS INTEGER ) * col1 + 32 + col0 / col2 col2 FROM tab1 AS cor0
----
1280
1436
603

query I rowsort
SELECT ALL - ( col2 ) + col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT - - 89 AS col2 FROM tab1 AS cor0
----
89
89
89

query I rowsort
SELECT DISTINCT + - ( col2 ) AS col1 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT + + col1 * - col2 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + cor0.col0 AS col1 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 50 * cor1.col0 col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
-150
-3200
-4000

query I rowsort
SELECT - + col2 * - 53 + - ( col0 ) AS col2 FROM tab1 AS cor0
----
2859
2957
5008

query I rowsort
SELECT DISTINCT cor0.col2 + - col0 * - 15 FROM tab0 AS cor0
----
1417
393
526

query I rowsort
SELECT - col2 + + 90 FROM tab0
----
57
8
89

query I rowsort
SELECT col1 + + ( col0 ) + - col2 AS col2 FROM tab0 AS cor0
----
131
77
98

query I rowsort
SELECT ALL + cor0.col0 + - 44 * cor0.col2 AS col0 FROM tab0 AS cor0
----
-1428
-3519
-9

query I rowsort
SELECT ALL cor0.col0 + - cor0.col2 AS col0 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT + col1 * + 88 - + col0 AS col0 FROM tab0 AS cor0
----
7544
7919
8501

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + 35 col0 FROM tab0 AS cor0
----
124
59
70

query I rowsort
SELECT - col1 + + 48 AS col1 FROM tab1 AS cor0
----
22
35
38

query I rowsort
SELECT ALL + col0 * - col2 * - col1 AS col0 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6787
SELECT ALL cor0.col0 + CAST( NULL AS SIGNED ) * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6787
SELECT ALL cor0.col0 + CAST ( NULL AS INTEGER ) * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 79 * + col2 FROM tab2 AS cor0
----
-2054
-2133
-3002

query I rowsort
SELECT ALL - cor0.col1 + - col1 + col0 AS col2 FROM tab0 AS cor0
----
-148
-159
-93

query I rowsort
SELECT cor0.col0 * + 52 AS col1 FROM tab1 AS cor0
----
156
3328
4160

query I rowsort
SELECT DISTINCT + tab1.col0 + ( col0 ) FROM tab1
----
128
160
6

query I rowsort
SELECT ALL + col1 * 53 + + col2 FROM tab1
----
1432
587
785

query I rowsort
SELECT + tab0.col1 + col2 + - col0 AS col2 FROM tab0
----
63
84
95

query I rowsort
SELECT col0 + - tab2.col0 FROM tab2
----
0
0
0

query I rowsort
SELECT ALL - col0 * - tab0.col1 + - col1 * col2 AS col1 FROM tab0
----
-774
3298
637

query I rowsort
SELECT + col2 + - col2 * col2 * col0 FROM tab0
----
-26103
-34
-598354

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 34 + 79 col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col0 + - col0 col2 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT ALL col0 * + col2 AS col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + col2 + - col1 AS col2 FROM tab2 cor0
----
-33
-4
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6801
SELECT CAST( + 32 AS SIGNED ) FROM tab1
----
32
32
32

skipif mysql # not compatible
query I rowsort label-6801
SELECT CAST ( + 32 AS INTEGER ) FROM tab1
----
32
32
32

query I rowsort
SELECT ALL + 88 * + col1 AS col0 FROM tab2
----
1496
2728
5192

query I rowsort
SELECT DISTINCT + 11 AS col0 FROM tab0, tab1, tab2 AS cor0
----
11

query I rowsort
SELECT ALL - ( - col2 ) * - col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # use DIV operator for integer division
query I rowsort label-6805
SELECT - - CAST( col0 AS SIGNED ) * - col0 + + col1 DIV col0 AS col0 FROM tab1 AS cor0
----
-1
-4096
-6400

skipif mysql # not compatible
query I rowsort label-6805
SELECT - - CAST ( col0 AS INTEGER ) * - col0 + + col1 / col0 AS col0 FROM tab1 AS cor0
----
-1
-4096
-6400

query I rowsort
SELECT ALL col2 * - col1 + col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT + 56 + + ( cor0.col1 ) * col1 * col2 - + col1 AS col0 FROM tab2 AS cor0
----
11021
25972
90503

query I rowsort
SELECT ALL col2 * 16 AS col2 FROM tab1 AS cor0
----
1536
864
912

query I rowsort
SELECT 77 * + col2 + - cor0.col2 FROM tab0 AS cor0
----
2508
6232
76

query I rowsort
SELECT DISTINCT - 54 * col1 AS col1 FROM tab2
----
-1674
-3186
-918

query I rowsort
SELECT DISTINCT + 36 AS col1 FROM tab0
----
36

query I rowsort
SELECT col1 * - 41 FROM tab1
----
-1066
-410
-533

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col0 * col0 col2 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT DISTINCT - col0 * col0 - + cor0.col0 AS col2 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT ALL - - col0 * col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT col2 * col2 + col1 * cor0.col0 FROM tab1 AS cor0
----
10256
2994
3889

query I rowsort
SELECT DISTINCT + col0 + + col1 * 71 FROM tab2 AS cor0
----
1286
2208
4267

query I rowsort
SELECT - cor0.col0 + col1 AS col2 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT - 29 * + cor0.col1 FROM tab2 AS cor0
----
-1711
-493
-899

query I rowsort
SELECT - ( + col2 ) * cor0.col0 + + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT + + 76 + + col2 AS col0 FROM tab1 AS cor0
----
130
133
172

query I rowsort
SELECT + - cor0.col2 * col0 - col0 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
-240
-4288
-8720

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT DISTINCT tab2.col0 - col0 * + CAST ( + col2 AS REAL ) col2 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT 92 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to c64cb7a81da51f4be0b6906a223e8817

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( col2 ) * 70 * - col0 + tab1.col0 - + col1 col1 FROM tab1
----
-11363
-255306
-537533

query I rowsort
SELECT - + col1 * cor0.col1 - + 38 FROM tab0 AS cor0
----
-7434
-8319
-9447

query I rowsort
SELECT DISTINCT - 13 + col1 FROM tab0 AS cor0
----
73
78
84

query I rowsort
SELECT - + col2 + - cor0.col0 * - 22 AS col2 FROM tab2 cor0
----
127
1690
1700

onlyif mysql # use DIV operator for integer division
query I rowsort label-6829
SELECT + - col2 * col1 DIV col1 - - col0 DIV col0 FROM tab1 AS cor0
----
-53
-56
-95

skipif mysql # not compatible
query I rowsort label-6829
SELECT + - col2 * col1 / col1 - - col0 / col0 FROM tab1 AS cor0
----
-53
-56
-95

query I rowsort
SELECT - col1 + + 95 AS col2 FROM tab1 AS cor0
----
69
82
85

query I rowsort
SELECT ALL + cor0.col1 + - 15 * col1 FROM tab0 AS cor0
----
-1204
-1274
-1358

onlyif mysql # use DIV operator for integer division
query I rowsort label-6832
SELECT - - col0 * - ( + col0 ) * col2 + - 48 DIV - col1 AS col1 FROM tab0 AS cor0
----
-1225
-19008
-649522

skipif mysql # not compatible
query I rowsort label-6832
SELECT - - col0 * - ( + col0 ) * col2 + - 48 / - col1 AS col1 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT DISTINCT - col2 + - col2 * - 78 AS col2 FROM tab2 AS cor0
----
2002
2079
2926

query I rowsort
SELECT - + col2 + 10 + ( col2 + + 65 ) AS col0 FROM tab1 AS cor0
----
75
75
75

query I rowsort
SELECT ALL - col0 + col2 * - col2 AS col0 FROM tab1 AS cor0
----
-2919
-3313
-9296

onlyif mysql # use DIV operator for integer division
query I rowsort label-6836
SELECT DISTINCT 78 DIV + tab0.col2 FROM tab0
----
0
2
78

skipif mysql # not compatible
query I rowsort label-6836
SELECT DISTINCT 78 / + tab0.col2 FROM tab0
----
0
2
78

query I rowsort
SELECT ALL tab1.col0 * - col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT + 81 * + col0 FROM tab0
----
1944
2835
7209

query I rowsort
SELECT + - col0 * col2 + + col0 + cor0.col1 * + col1 AS col1 FROM tab1 AS cor0
----
-3484
-7431
517

query I rowsort
SELECT cor0.col2 + 73 AS col2 FROM tab0 AS cor0
----
106
155
74

query I rowsort
SELECT ALL + - col2 * + col0 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 61 col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

onlyif mysql # use DIV operator for integer division
query I rowsort label-6843
SELECT - col1 * col2 DIV - col0 AS col1 FROM tab0 cor0
----
118
2
83

skipif mysql # not compatible
query I rowsort label-6843
SELECT - col1 * col2 / - col0 AS col1 FROM tab0 cor0
----
118
2
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6844
SELECT - - col1 DIV + col1 AS col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6844
SELECT - - col1 / + col1 AS col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT + cor0.col0 * col2 + col0 FROM tab0 cor0
----
70
7387
816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + cor0.col2 col2 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6847
SELECT - - col1 DIV + col1 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6847
SELECT - - col1 / + col1 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT col0 + + col1 * - col1 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT - 81 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 205b3ff2d7b1817c98d7980b8c17e6c1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6850
SELECT ALL CAST( cor0.col0 AS SIGNED ) + - col1 col2 FROM tab2 AS cor0
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6850
SELECT ALL CAST ( cor0.col0 AS INTEGER ) + - col1 col2 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT + ( 21 ) + col1 FROM tab0 AS cor0
----
107
112
118

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 44 * col2 + col2 + + col1 col0 FROM tab0 AS cor0
----
142
1571
3781

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 col0 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + tab1.col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT + cor0.col0 + + col1 * + 18 FROM tab2 AS cor0
----
1140
385
565

onlyif mysql # use DIV operator for integer division
query I rowsort label-6856
SELECT + CAST( 55 AS SIGNED ) DIV col0 FROM tab0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-6856
SELECT + CAST ( 55 AS INTEGER ) / col0 FROM tab0
----
0
1
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6857
SELECT col0 + col2 DIV + col1 FROM tab1
----
5
69
87

skipif mysql # not compatible
query I rowsort label-6857
SELECT col0 + col2 / + col1 FROM tab1
----
5
69
87

query I rowsort
SELECT DISTINCT tab0.col2 * tab0.col0 + - tab0.col0 FROM tab0
----
0
7209
768

query I rowsort
SELECT + tab2.col1 * tab2.col2 FROM tab2
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col1 + - col0 col0 FROM tab2
----
-1422
-224
-4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col2 * col0 col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT col1 * col2 + col0 AS col0 FROM tab1
----
1328
1407
634

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL BETWEEN NULL AND + col1
----

query I rowsort
SELECT tab2.col1 * col0 + col0 AS col0 FROM tab2 WHERE col2 NOT BETWEEN NULL AND ( NULL )
----

query III rowsort
SELECT * FROM tab0 WHERE col1 NOT BETWEEN NULL AND col0
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query III rowsort
SELECT * FROM tab1 WHERE NOT col1 * col1 = ( + col2 + - col1 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 - - col2 * + col2 col2 FROM tab0
----
1113
36
6813

query I rowsort
SELECT ALL 47 + col2 FROM tab1 AS cor0
----
101
104
143

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 2 * col1 col1 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT col1 + + tab2.col1 AS col2 FROM tab2
----
118
34
62

query I rowsort
SELECT DISTINCT - col0 * - col0 AS col1 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT col1 * col0 - + col1 * + col2 * - col0 FROM tab1
----
100880
37120
4290

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col1 col1 FROM tab1
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-6874
SELECT DISTINCT col0 * col0 - col2 DIV tab0.col0 FROM tab0
----
1225
575
7921

skipif mysql # not compatible
query I rowsort label-6874
SELECT DISTINCT col0 * col0 - col2 / tab0.col0 FROM tab0
----
1225
575
7921

query I rowsort
SELECT col1 + col2 * col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT - col1 + + col2 * - col0 FROM tab1
----
-188
-3658
-7693

query I rowsort
SELECT ALL - cor0.col1 - col1 FROM tab1 AS cor0
----
-20
-26
-52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col1 col2 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT col1 * col2 * - col0 + - col2 FROM tab2 cor0
----
-119678
-51072
-5886

query I rowsort
SELECT DISTINCT tab2.col1 - - col2 FROM tab2
----
55
58
85

query I rowsort
SELECT ALL - col1 * col0 + col1 * col1 AS col0 FROM tab0
----
182
5332
6014

query I rowsort
SELECT DISTINCT + col0 * + col0 * col1 FROM tab1
----
234
40960
83200

query I rowsort
SELECT DISTINCT + col1 + - col0 AS col1 FROM tab0 WHERE NOT NULL IN ( col0 )
----

query I rowsort
SELECT DISTINCT + col1 * + col1 * col0 AS col2 FROM tab0
----
177504
329315
737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-6885
SELECT - col0 + col0 DIV col2 + col1 FROM tab1
----
-53
-67
23

skipif mysql # not compatible
query I rowsort label-6885
SELECT - col0 + col0 / col2 + col1 FROM tab1
----
-53
-67
23

query I rowsort
SELECT col1 * tab1.col2 FROM tab1 WHERE NULL NOT IN ( + col0 * col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6887
SELECT DISTINCT + col1 * tab0.col2 + col1 DIV col1 FROM tab0
----
2839
7463
98

skipif mysql # not compatible
query I rowsort label-6887
SELECT DISTINCT + col1 * tab0.col2 + col1 / col1 FROM tab0
----
2839
7463
98

query I rowsort
SELECT tab0.col1 * - col2 FROM tab0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6889
SELECT ALL - col1 DIV + cor0.col0 AS col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-6889
SELECT ALL - col1 / + cor0.col0 AS col0 FROM tab1 AS cor0
----
-8
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6890
SELECT - col1 DIV col1 + - col0 * col0 FROM tab2 AS cor0
----
-50
-6085
-6242

skipif mysql # not compatible
query I rowsort label-6890
SELECT - col1 / col1 + - col0 * col0 FROM tab2 AS cor0
----
-50
-6085
-6242

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 AS cor2, tab1 AS cor3
----
3645 values hashing to 0a3bf4d9642f43f11aad64de0d046e6b

query I rowsort
SELECT DISTINCT - col2 + + ( 43 ) * col0 FROM tab2
----
274
3328
3359

query I rowsort
SELECT DISTINCT - col1 * - 30 + col0 * col1 FROM tab0
----
10829
4644
6305

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + - cor0.col0 * + col1 + + col1 col2 FROM tab0 AS cor0
----
-1954
-3263
-7919

query I rowsort
SELECT + ( 42 ) FROM tab1, tab1 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor1.col0 col0 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - - CAST ( col0 AS REAL ) * - col0 - col1 FROM tab1 AS cor0
----
-35
-4106
-6413

query I rowsort
SELECT ALL ( 17 ) - col0 FROM tab2 AS cor0
----
-61
-62
10

query I rowsort
SELECT + col2 + + cor0.col2 * - cor0.col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

query I rowsort
SELECT ALL - tab2.col2 AS col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6901
SELECT - CAST( - ( - col2 ) AS SIGNED ) + ( - 96 ) FROM tab1
----
-150
-153
-192

skipif mysql # not compatible
query I rowsort label-6901
SELECT - CAST ( - ( - col2 ) AS INTEGER ) + ( - 96 ) FROM tab1
----
-150
-153
-192

query I rowsort
SELECT - col1 * + ( col0 ) FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT cor0.col1 AS col0 FROM tab0, tab1 AS cor0
----
10
13
26

query I rowsort
SELECT ALL + ( - col1 ) * col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL + 67 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to b56f8a4f1fcebc9802481256df61e97c

query I rowsort
SELECT ALL + col0 * col1 * col2 FROM tab0
----
3395
664118
68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6907
SELECT DISTINCT ( + col1 ) * CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6907
SELECT DISTINCT ( + col1 ) * CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL tab0.col0 * + tab0.col2 - - col2 FROM tab0
----
36
7380
825

query I rowsort
SELECT ALL + col2 * + col2 AS col2 FROM tab2 AS cor0
----
1444
676
729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT + - col0 * - col1 + + col2 FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-6912
SELECT ALL col1 DIV col0 AS col0 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-6912
SELECT ALL col1 / col0 AS col0 FROM tab0 AS cor0
----
1
2
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6913
SELECT - col2 - - CAST( - col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-121
-176
-57

skipif mysql # not compatible
query I rowsort label-6913
SELECT - col2 - - CAST ( - col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT + col0 + - 4 FROM tab0 cor0
----
20
31
85

query I rowsort
SELECT ALL - col0 * - ( cor0.col2 ) FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT - + col0 * + col1 + col2 AS col0 FROM tab0 cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT - + col1 + + col2 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT DISTINCT col1 * col0 * 51 AS col0 FROM tab0 AS cor0
----
105264
173145
413049

query I rowsort
SELECT ALL + + col1 - col0 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT - + col2 - - ( col2 ) FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 + 96 AS col1 FROM tab1 AS cor0
----
150
153
192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * cor0.col2 - + col0 col0 FROM tab1 AS cor0
----
-2919
-3313
-9296

query I rowsort
SELECT ALL col2 * - ( col1 ) AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - col0 + - tab2.col2 - - col2 * col2 AS col0 FROM tab2
----
1327
572
695

onlyif mysql # use DIV operator for integer division
query I rowsort label-6925
SELECT + col1 * + col1 + + 67 DIV + 36 AS col1 FROM tab0
----
7397
8282
9410

skipif mysql # not compatible
query I rowsort label-6925
SELECT + col1 * + col1 + + 67 / + 36 AS col1 FROM tab0
----
7397
8282
9410

query I rowsort
SELECT col1 + col1 + 41 AS col1 FROM tab1
----
61
67
93

query I rowsort
SELECT DISTINCT col2 * 21 AS col0 FROM tab0 AS cor0
----
1722
21
693

query I rowsort
SELECT ALL + col2 * col2 * - ( col0 ) FROM tab0 AS cor0
----
-26136
-35
-598436

query I rowsort
SELECT + col1 + col1 AS col2 FROM tab2 cor0
----
118
34
62

query I rowsort
SELECT + - cor0.col2 + ( col0 ) AS col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL + ( col2 ) - + ( col2 ) * col0 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT - 75 * - col0 + - col0 + - col0 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-312
-395
469

query I rowsort
SELECT - + 83 FROM tab2 AS cor0
----
-83
-83
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-6934
SELECT DISTINCT - col0 DIV 12 FROM tab2
----
-6
0

skipif mysql # not compatible
query I rowsort label-6934
SELECT DISTINCT - col0 / 12 FROM tab2
----
-6
0

query I rowsort
SELECT col0 * 2 * col2 FROM tab0
----
14596
1584
70

query I rowsort
SELECT ( + col1 ) * col2 AS col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT DISTINCT - 31 AS col1 FROM tab2
----
-31

query I rowsort
SELECT - 42 AS col1 FROM tab2
----
-42
-42
-42

query I rowsort
SELECT DISTINCT + col0 * 41 FROM tab0
----
1435
3649
984

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 52 col2 FROM tab1
----
-52

query I rowsort
SELECT DISTINCT 15 AS col2 FROM tab2
----
15

query I rowsort
SELECT + col2 * 12 AS col2 FROM tab0
----
12
396
984

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab2 AS cor1, tab2, tab1 AS cor2
----
3645 values hashing to 97b2ae21242e1e40418ee2ad06544f7a

query I rowsort
SELECT 57 FROM tab1, tab0 AS cor0
----
9 values hashing to 61da70c624ad60604a668f7f8f29392a

query I rowsort
SELECT - cor0.col1 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT DISTINCT - 92 AS col1 FROM tab0
----
-92

query I rowsort
SELECT col0 * + tab1.col0 + + col0 FROM tab1
----
12
4160
6480

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col2 * tab2.col2 col0 FROM tab2
----
1406
650
702

query I rowsort
SELECT - cor0.col2 * 19 FROM tab1 AS cor0
----
-1026
-1083
-1824

query I rowsort
SELECT DISTINCT - 88 * col2 FROM tab2
----
-2288
-2376
-3344

query I rowsort
SELECT ALL + 46 * - col2 FROM tab1
----
-2484
-2622
-4416

query I rowsort
SELECT + tab1.col1 + + col1 AS col1 FROM tab1
----
20
26
52

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to 2566f3fa788816c8bfc482e730aaed74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col0 - + col0 * col2 col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + - col0 + 12 + col2 AS col2 FROM tab2 AS cor0
----
-29
-40
32

query I rowsort
SELECT tab0.col0 + cor0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to fdd2f547b28e02db29f913671a199b7b

query I rowsort
SELECT + col1 * col0 * - 40 - - col1 FROM tab0 AS cor0
----
-135703
-323869
-82474

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6958
SELECT DISTINCT - col2 + - CAST( NULL AS DECIMAL ) * + 88 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6958
SELECT DISTINCT - col2 + - CAST ( NULL AS REAL ) * + 88 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + + col0 - col2 * + col2 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT ALL - + col0 + col2 * - col0 FROM tab0 AS cor0
----
-70
-7387
-816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col1 col1 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6962
SELECT - col1 + + col1 DIV col1 AS col0 FROM tab1 AS cor0
----
-12
-25
-9

skipif mysql # not compatible
query I rowsort label-6962
SELECT - col1 + + col1 / col1 AS col0 FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT col1 - col2 * col1 * col2 FROM tab0
----
-611793
-93568
0

query I rowsort
SELECT - col2 + + col0 * col1 FROM tab1
----
24
583
944

query I rowsort
SELECT - col2 * + col0 * + col2 - tab1.col2 AS col0 FROM tab1
----
-207993
-737376
-8802

query I rowsort
SELECT cor0.col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * col2 + - col0 col2 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT ALL col2 - col1 AS col1 FROM tab1
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * + col1 col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT cor0.col1 + col2 - - col1 FROM tab1 AS cor0
----
106
122
77

query I rowsort
SELECT ALL tab0.col1 * tab0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 9708a433b981d9b5fd095bfe2ea45aea

onlyif mysql # use DIV operator for integer division
query I rowsort label-6972
SELECT + col1 + - col1 DIV - col2 - col2 FROM tab0 cor0
----
10
193
55

skipif mysql # not compatible
query I rowsort label-6972
SELECT + col1 + - col1 / - col2 - col2 FROM tab0 cor0
----
10
193
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-6973
SELECT DISTINCT + + col0 DIV + col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-6973
SELECT DISTINCT + + col0 / + col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT DISTINCT - - cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col0 + + col2 col2 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT - - 43 * col1 + col0 FROM tab2 AS cor0
----
1340
2615
810

query I rowsort
SELECT ALL + col1 + + col1 AS col0 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT - - col2 * + col2 AS col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT - + cor0.col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT ALL 61 * col0 FROM tab0
----
1464
2135
5429

onlyif mysql # use DIV operator for integer division
query I rowsort label-6981
SELECT DISTINCT 54 DIV col0 FROM tab2
----
0
7

skipif mysql # not compatible
query I rowsort label-6981
SELECT DISTINCT 54 / col0 FROM tab2
----
0
7

query I rowsort
SELECT - col1 * tab2.col0 * 57 FROM tab2
----
-12369
-262314
-76551

query I rowsort
SELECT col1 - - col1 AS col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT 4 * col2 AS col0 FROM tab2 cor0
----
104
108
152

query I rowsort
SELECT - - col2 - - col2 FROM tab0 AS cor0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 11 * - col1 + + 57 + - col0 * col1 * + col1 col1 FROM tab2
----
-22961
-272110
-7011

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6987
SELECT ALL - col2 * - col1 + CAST( NULL AS SIGNED ) / + 16 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6987
SELECT ALL - col2 * - col1 + CAST ( NULL AS INTEGER ) / + 16 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6988
SELECT - 74 DIV - col1 + 29 FROM tab1 AS cor0
----
31
34
36

skipif mysql # not compatible
query I rowsort label-6988
SELECT - 74 / - col1 + 29 FROM tab1 AS cor0
----
31
34
36

query I rowsort
SELECT 80 FROM tab1, tab0 cor0, tab1 cor1, tab2 AS cor2
----
81 values hashing to 2815a2e064e1815ac3a10bcd8b0ab19c

query I rowsort
SELECT ALL + 50 AS col0 FROM tab0 AS cor0
----
50
50
50

query I rowsort
SELECT DISTINCT cor0.col0 * + 53 + + col0 FROM tab2 AS cor0
----
378
4212
4266

query I rowsort
SELECT col1 + - col2 * + cor0.col1 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-6993
SELECT ALL col0 * - col1 + col1 DIV + col1 AS col0 FROM tab2 AS cor0
----
-1342
-216
-4601

skipif mysql # not compatible
query I rowsort label-6993
SELECT ALL col0 * - col1 + col1 / + col1 AS col0 FROM tab2 AS cor0
----
-1342
-216
-4601

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6994
SELECT - + col0 + + CAST( NULL AS SIGNED ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6994
SELECT - + col0 + + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6995
SELECT DISTINCT - col0 - 85 DIV - col0 FROM tab0 AS cor0
----
-21
-33
-89

skipif mysql # not compatible
query I rowsort label-6995
SELECT DISTINCT - col0 - 85 / - col0 FROM tab0 AS cor0
----
-21
-33
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6996
SELECT - col2 + CAST( NULL AS SIGNED ) * col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6996
SELECT - col2 + CAST ( NULL AS INTEGER ) * col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - col2 - + col2 * col1 * + col2 FROM tab2 AS cor0
----
-22626
-24586
-39910

query I rowsort
SELECT ALL - col0 * ( + col0 ) AS col2 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT - - col2 + col0 + 11 AS col1 FROM tab2 AS cor0
----
115
128
45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - 8 col2 FROM tab2 AS cor0
----
136
248
472

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7001
SELECT ALL col2 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7001
SELECT ALL col2 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col0 + - col0 * 54 AS col1 FROM tab2 AS cor0
----
-371
-4134
-4187

query I rowsort
SELECT ALL + col2 * + col0 AS col2 FROM tab1 cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-7004
SELECT DISTINCT - - cor0.col0 * CAST( col0 AS SIGNED ) - col0 DIV - 37 AS col1 FROM tab0 AS cor0
----
1225
576
7923

skipif mysql # not compatible
query I rowsort label-7004
SELECT DISTINCT - - cor0.col0 * CAST ( col0 AS INTEGER ) - col0 / - 37 AS col1 FROM tab0 AS cor0
----
1225
576
7923

query I rowsort
SELECT cor0.col1 * + 54 FROM tab0 AS cor0
----
4644
4914
5238

query I rowsort
SELECT DISTINCT - col0 * + 66 - col2 AS col2 FROM tab0 cor0
----
-1617
-2311
-5956

onlyif mysql # use DIV operator for integer division
query I rowsort label-7007
SELECT DISTINCT + col1 DIV + 91 + col1 * col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-7007
SELECT DISTINCT + col1 / + 91 + col1 * col2 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT + cor0.col0 * - ( + 67 ) FROM tab1 AS cor0
----
-201
-4288
-5360

query I rowsort
SELECT DISTINCT - - col0 * 29 + + col2 FROM tab2 AS cor0
----
2288
230
2329

query I rowsort
SELECT - col1 - + 85 FROM tab2 AS cor0
----
-102
-116
-144

query I rowsort
SELECT - 14 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
-11
50
66

query I rowsort
SELECT ALL - cor0.col1 + col1 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + cor0.col0 * ( col2 ) * col1 - ( col1 ) FROM tab2 AS cor0
----
119593
51017
5828

query I rowsort
SELECT - col2 * col0 * - col1 - + 37 AS col2 FROM tab1 AS cor0
----
36443
4175
99803

query I rowsort
SELECT + + col0 * - 13 FROM tab1 AS cor0
----
-1040
-39
-832

query I rowsort
SELECT ALL - + 61 * 72 + col0 AS col0 FROM tab1 cor0
----
-4312
-4328
-4389

query I rowsort
SELECT - 16 + col1 FROM tab0 AS cor0
----
70
75
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7018
SELECT DISTINCT CAST( col0 AS SIGNED ) + col0 + + col0 AS col1 FROM tab2 cor0
----
21
234
237

skipif mysql # not compatible
query I rowsort label-7018
SELECT DISTINCT CAST ( col0 AS INTEGER ) + col0 + + col0 AS col1 FROM tab2 cor0
----
21
234
237

query I rowsort
SELECT ALL 1 + + col1 FROM tab0 AS cor0
----
87
92
98

query I rowsort
SELECT ALL col1 * 94 AS col1 FROM tab2 AS cor0
----
1598
2914
5546

query I rowsort
SELECT 96 FROM tab1 AS cor0
----
96
96
96

query I rowsort
SELECT ALL - - col2 * cor0.col0 + + col2 + + col0 AS col2 FROM tab1 AS cor0
----
219
3769
7856

query I rowsort
SELECT + 19 FROM tab1 AS cor0
----
19
19
19

query I rowsort
SELECT DISTINCT - + 17 + - 30 * col2 AS col0 FROM tab2 AS cor0
----
-1157
-797
-827

query I rowsort
SELECT ALL col0 * - cor0.col1 * - 82 AS col2 FROM tab1 AS cor0
----
52480
6396
85280

onlyif mysql # use DIV operator for integer division
query I rowsort label-7026
SELECT col0 + - cor0.col0 DIV col1 FROM tab2 cor0
----
7
75
77

skipif mysql # not compatible
query I rowsort label-7026
SELECT col0 + - cor0.col0 / col1 FROM tab2 cor0
----
7
75
77

query I rowsort
SELECT DISTINCT + 85 * - col2 + col2 AS col2 FROM tab1 AS cor0
----
-4536
-4788
-8064

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col0 * col1 col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + col1 + - col1 * - 31 FROM tab0 AS cor0
----
2752
2912
3104

query I rowsort
SELECT + col1 * col1 - - ( col0 ) * col0 AS col2 FROM tab2 cor0
----
1010
6530
9565

query I rowsort
SELECT + col0 - + col2 AS col0 FROM tab2 cor0
----
-20
41
52

query I rowsort
SELECT - col2 * col0 - 15 AS col0 FROM tab1 AS cor0
----
-177
-3663
-7695

query I rowsort
SELECT DISTINCT - cor0.col2 * col1 AS col0 FROM tab0 cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-7034
SELECT DISTINCT - 90 + cor0.col0 DIV - col1 FROM tab0 AS cor0
----
-90

skipif mysql # not compatible
query I rowsort label-7034
SELECT DISTINCT - 90 + cor0.col0 / - col1 FROM tab0 AS cor0
----
-90

query I rowsort
SELECT ALL - 43 + - col1 FROM tab0 AS cor0
----
-129
-134
-140

query I rowsort
SELECT DISTINCT - 44 * cor0.col2 FROM tab0 AS cor0
----
-1452
-3608
-44

onlyif mysql # use DIV operator for integer division
query I rowsort label-7037
SELECT col2 DIV - cor0.col0 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-7037
SELECT col2 / - cor0.col0 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT - 52 * + tab1.col2 + col0 * + col0 FROM tab1
----
-2799
1132
1408

query I rowsort
SELECT ( col1 ) + - col2 FROM tab1
----
-28
-47
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7040
SELECT + - CAST( NULL AS SIGNED ) FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7040
SELECT + - CAST ( NULL AS INTEGER ) FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL + 24 FROM tab2, tab2 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT col1 * col1 + - 53 FROM tab2 cor0
----
236
3428
908

query I rowsort
SELECT 0 * - col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col2 * + col0 + + col1 FROM tab1
----
188
3658
7693

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7045
SELECT + col2 * - CAST( + col1 AS SIGNED ) - col0 * - col1 AS col0 FROM tab1 AS cor0
----
-1326
-208
70

skipif mysql # not compatible
query I rowsort label-7045
SELECT + col2 * - CAST ( + col1 AS INTEGER ) - col0 * - col1 AS col0 FROM tab1 AS cor0
----
-1326
-208
70

query I rowsort
SELECT DISTINCT col0 * col1 + + cor0.col1 * col0 * col0 FROM tab0 AS cor0
----
122220
51600
728910

query I rowsort
SELECT ALL - - 59 * col1 FROM tab1 AS cor0
----
1534
590
767

query I rowsort
SELECT + - col2 - + col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT col2 + - cor0.col1 * col0 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT DISTINCT + + 22 AS col1 FROM tab2 cor0 CROSS JOIN tab1 cor1
----
22

query I rowsort
SELECT ALL + 9 FROM tab0
----
9
9
9

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 cor0, tab2, tab0 AS cor1
----
972 values hashing to e4c748f267e8d2a0e6d563281e1fb975

query I rowsort
SELECT ALL 17 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT DISTINCT - cor1.col0 AS col0 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0 AS cor2
----
-24
-35
-89

query I rowsort
SELECT 66 * 37 AS col1 FROM tab0, tab1 cor0
----
9 values hashing to be8aa4206b1cb8d63e25bab1a720fe03

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7056
SELECT - CAST( NULL AS DECIMAL ) col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7056
SELECT - CAST ( NULL AS REAL ) col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7057
SELECT DISTINCT + col2 DIV col0 AS col1 FROM tab2
----
0
3

skipif mysql # not compatible
query I rowsort label-7057
SELECT DISTINCT + col2 / col0 AS col1 FROM tab2
----
0
3

onlyif mysql # use DIV operator for integer division
query I rowsort label-7058
SELECT ALL + tab0.col1 DIV + ( - col2 ) FROM tab0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-7058
SELECT ALL + tab0.col1 / + ( - col2 ) FROM tab0
----
-1
-2
-97

query I rowsort
SELECT ALL col2 * tab0.col1 AS col0 FROM tab0
----
2838
7462
97

query I rowsort
SELECT DISTINCT ( - 83 ) FROM tab0 AS cor0
----
-83

query I rowsort
SELECT + cor1.col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 * col0 col1 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - col0 * + col0 + - col2 AS col0 FROM tab0 cor0
----
-1226
-609
-8003

query I rowsort
SELECT DISTINCT + 42 + col1 FROM tab1 AS cor0
----
52
55
68

query I rowsort
SELECT - 52 * + col1 FROM tab0 AS cor0
----
-4472
-4732
-5044

query I rowsort
SELECT ALL - 99 * - col2 * + col0 AS col0 FROM tab2 AS cor0
----
18711
200772
297198

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7067
SELECT + - CAST( - col0 AS SIGNED ) * col0 col2 FROM tab0 AS cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7067
SELECT + - CAST ( - col0 AS INTEGER ) * col0 col2 FROM tab0 AS cor0
----
1225
576
7921

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab1, tab2 cor1, tab0 AS cor2
----
972 values hashing to 9a5ab925af18e11f7748f3b2e722ff3d

query I rowsort
SELECT - col1 * 47 AS col0 FROM tab2 AS cor0
----
-1457
-2773
-799

onlyif mysql # use DIV operator for integer division
query I rowsort label-7070
SELECT + col0 DIV ( - cor0.col0 ) AS col2 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-7070
SELECT + col0 / ( - cor0.col0 ) AS col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + col2 * col2 * 49 FROM tab1 cor0
----
142884
159201
451584

query I rowsort
SELECT + - col2 * 40 AS col2 FROM tab1 AS cor0
----
-2160
-2280
-3840

onlyif mysql # use DIV operator for integer division
query I rowsort label-7073
SELECT + col1 DIV + 39 FROM tab0 AS cor0
----
2
2
2

skipif mysql # not compatible
query I rowsort label-7073
SELECT + col1 / + 39 FROM tab0 AS cor0
----
2
2
2

query I rowsort
SELECT - + col0 + - col2 FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT cor0.col2 + 79 AS col1 FROM tab2 AS cor0
----
105
106
117

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 cor0, tab2 AS cor1, tab2, tab1 AS cor2
----
3645 values hashing to 9b60cb1db2fb2fa5700b0e572b4b6546

query I rowsort
SELECT + + 84 + + ( col2 ) FROM tab2 AS cor0
----
110
111
122

query I rowsort
SELECT 29 + col1 AS col2 FROM tab2 AS cor0
----
46
60
88

query I rowsort
SELECT DISTINCT + 3 + 64 AS col2 FROM tab2 AS cor0
----
67

query I rowsort
SELECT ALL + cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT col0 + + cor0.col0 * col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT + 82 + + col0 * 76 * - col1 FROM tab1 AS cor0
----
-48558
-5846
-78958

query I rowsort
SELECT ALL 0 AS col2 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT DISTINCT tab0.col1 AS col2 FROM tab2, tab2 AS cor0 CROSS JOIN tab0
----
86
91
97

query I rowsort
SELECT + col0 * + 35 AS col0 FROM tab2 AS cor0
----
245
2730
2765

onlyif mysql # use DIV operator for integer division
query I rowsort label-7086
SELECT - col2 DIV + 92 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7086
SELECT - col2 / + 92 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT ALL 43 * + col2 * ( 54 ) AS col0 FROM tab1
----
125388
132354
222912

query I rowsort
SELECT DISTINCT + - cor0.col0 AS col1 FROM tab1, tab0, tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT + ( + col1 + + 38 ) AS col0 FROM tab2
----
55
69
97

query I rowsort
SELECT DISTINCT 1 FROM tab2, tab1, tab1 AS cor0
----
1

query I rowsort
SELECT - - 53 FROM tab0, tab2, tab0 cor0
----
27 values hashing to 866ae1b4ab9e5b4043ac1bcfd413aaa6

onlyif mysql # use DIV operator for integer division
query I rowsort label-7093
SELECT - + cor0.col1 DIV 23 FROM tab2 AS cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-7093
SELECT - + cor0.col1 / 23 FROM tab2 AS cor0
----
-1
-2
0

query I rowsort
SELECT DISTINCT + - col0 + - col2 * - 35 FROM tab1 AS cor0
----
1887
1931
3280

query I rowsort
SELECT DISTINCT - col0 * 76 AS col2 FROM tab0 AS cor0
----
-1824
-2660
-6764

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0, tab1 AS cor1, tab1, tab2 cor2
----
3645 values hashing to dd5ce24448edb4b3ab62c251475d6548

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0, tab2 AS cor1, tab2 AS cor2
----
972 values hashing to 64ce0e736818e884f0a9ecd075da5eb7

query I rowsort
SELECT - cor1.col0 - + cor1.col2 * + cor0.col1 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to dfb9e652ba0b2549f81eac00a450abbb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 9 col1 FROM tab0
----
9
9
9

query I rowsort
SELECT + col0 - 0 AS col1 FROM tab1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * + col1 col0 FROM tab2
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-7102
SELECT DISTINCT col2 DIV tab0.col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-7102
SELECT DISTINCT col2 / tab0.col1 FROM tab0
----
0

query I rowsort
SELECT col0 * cor0.col1 + - col2 FROM tab0 AS cor0
----
2031
3394
8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-7104
SELECT DISTINCT - tab2.col0 DIV - col1 AS col2 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-7104
SELECT DISTINCT - tab2.col0 / - col1 AS col2 FROM tab2
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 42 col0 FROM tab2
----
42
42
42

query I rowsort
SELECT DISTINCT - - 7 FROM tab2 AS cor0
----
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 col2 FROM tab2 cor0
----
-26
-27
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( cor0.col1 ) col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + 8 AS col1 FROM tab2, tab2 AS cor0
----
8

query I rowsort
SELECT col1 + + col2 + col2 FROM tab0
----
152
255
99

query I rowsort
SELECT DISTINCT - 5 FROM tab2, tab2 AS cor0
----
-5

query I rowsort
SELECT + col0 + - cor0.col2 FROM tab2 AS cor0
----
-20
41
52

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7113
SELECT - + CAST( + col2 AS SIGNED ) * cor0.col0 + 34 FROM tab2 cor0
----
-155
-1994
-2968

skipif mysql # not compatible
query I rowsort label-7113
SELECT - + CAST ( + col2 AS INTEGER ) * cor0.col0 + 34 FROM tab2 cor0
----
-155
-1994
-2968

query I rowsort
SELECT 63 AS col1 FROM tab0, tab2, tab1 AS cor0, tab0 AS cor1
----
81 values hashing to 29cdb8d01f1c3eb072511674b1c6d5fd

query I rowsort
SELECT DISTINCT ( col1 ) * - tab1.col1 - - col0 AS col2 FROM tab1
----
-36
-673
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7116
SELECT + 2 DIV + col0 AS col2 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7116
SELECT + 2 / + col0 AS col2 FROM tab2
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7117
SELECT ALL + 47 - 83 DIV col0 AS col1 FROM tab2
----
36
46
46

skipif mysql # not compatible
query I rowsort label-7117
SELECT ALL + 47 - 83 / col0 AS col1 FROM tab2
----
36
46
46

query I rowsort
SELECT 81 AS col2 FROM tab2 cor0
----
81
81
81

query I rowsort
SELECT - col1 - col2 AS col0 FROM tab2
----
-55
-58
-85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7120
SELECT + - cor0.col1 + + col2 / CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7120
SELECT + - cor0.col1 + + col2 / CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( col1 ) * - 51 + + col2 * col0 FROM tab0 AS cor0
----
11939
4982
5178

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * col1 + + 9 * 89 col2 FROM tab2 AS cor0
----
1447
1638
2335

onlyif mysql # use DIV operator for integer division
query I rowsort label-7123
SELECT DISTINCT col0 - col0 DIV 86 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-7123
SELECT DISTINCT col0 - col0 / 86 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + cor0.col0 + cor0.col0 FROM tab2 AS cor0
----
14
156
158

onlyif mysql # use DIV operator for integer division
query I rowsort label-7125
SELECT ALL - cor0.col2 + + col2 DIV - col2 AS col0 FROM tab0 AS cor0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-7125
SELECT ALL - cor0.col2 + + col2 / - col2 AS col0 FROM tab0 AS cor0
----
-2
-34
-83

query I rowsort
SELECT - 95 * + col0 + - col1 AS col0 FROM tab0 AS cor0
----
-2366
-3422
-8546

query I rowsort
SELECT 49 * + col2 AS col2 FROM tab0 AS cor0
----
1617
4018
49

query I rowsort
SELECT DISTINCT col2 - col1 AS col2 FROM tab0
----
-53
-9
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7129
SELECT DISTINCT tab0.col2 - + CAST( - col0 AS SIGNED ) FROM tab0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-7129
SELECT DISTINCT tab0.col2 - + CAST ( - col0 AS INTEGER ) FROM tab0
----
171
36
57

query I rowsort
SELECT col2 + + ( 55 ) + col0 FROM tab1
----
112
176
231

onlyif mysql # use DIV operator for integer division
query I rowsort label-7131
SELECT - col0 DIV - col0 + + col2 + tab2.col1 AS col2 FROM tab2
----
56
59
86

skipif mysql # not compatible
query I rowsort label-7131
SELECT - col0 / - col0 + + col2 + tab2.col1 AS col2 FROM tab2
----
56
59
86

query I rowsort
SELECT ALL + tab1.col1 - ( - col1 ) * col1 FROM tab1
----
110
182
702

query I rowsort
SELECT 63 + col2 AS col2 FROM tab2 AS cor0
----
101
89
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7134
SELECT DISTINCT - 2 * - ( - col1 ) + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7134
SELECT DISTINCT - 2 * - ( - col1 ) + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col1 + 77 + - col0 FROM tab1 AS cor0
----
-16
3
48

query I rowsort
SELECT ( cor0.col1 ) - + col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col1 * - col1 + tab2.col1 * col0 FROM tab2
----
-744
1054
1121

query I rowsort
SELECT DISTINCT col0 - + ( - col2 ) * - col1 AS col0 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT - 29 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 0cc9ddad93fc783055518ae4b6be054b

query I rowsort
SELECT DISTINCT - 25 FROM tab1, tab2 AS cor0, tab2 cor1
----
-25

query I rowsort
SELECT ALL col2 - + 79 AS col2 FROM tab0
----
-46
-78
3

query I rowsort
SELECT tab2.col0 + - 93 FROM tab2
----
-14
-15
-86

query I rowsort
SELECT ALL 39 * col0 + col0 * ( + col1 ) FROM tab2 AS cor0
----
4424
490
7644

query I rowsort
SELECT DISTINCT + - ( + col2 ) AS col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT - - 39 * 30 + - col1 * col1 AS col1 FROM tab2 AS cor0
----
-2311
209
881

query I rowsort
SELECT ALL - 38 - col0 FROM tab0 AS cor0
----
-127
-62
-73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7147
SELECT 83 - - ( + col1 + + CAST( NULL AS SIGNED ) ) / 83 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7147
SELECT 83 - - ( + col1 + + CAST ( NULL AS INTEGER ) ) / 83 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 11 * + col2 + col1 * - 92 AS col0 FROM tab2 AS cor0
----
-1146
-2555
-5142

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + col1 col2 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-7150
SELECT ALL + ( - col2 ) + col1 DIV + 14 AS col1 FROM tab1 AS cor0
----
-53
-57
-96

skipif mysql # not compatible
query I rowsort label-7150
SELECT ALL + ( - col2 ) + col1 / + 14 AS col1 FROM tab1 AS cor0
----
-53
-57
-96

query I rowsort
SELECT + 82 + - col2 FROM tab0 AS cor0
----
0
49
81

query I rowsort
SELECT DISTINCT ( + col0 ) * - col1 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * 73 col1 FROM tab2 AS cor0
----
511
5694
5767

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 col1 FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT + + 92 + + 37 * col2 AS col1 FROM tab1 AS cor0
----
2090
2201
3644

onlyif mysql # use DIV operator for integer division
query I rowsort label-7156
SELECT ALL 98 DIV + col0 + + col0 AS col1 FROM tab1 cor0
----
35
65
81

skipif mysql # not compatible
query I rowsort label-7156
SELECT ALL 98 / + col0 + + col0 AS col1 FROM tab1 cor0
----
35
65
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7157
SELECT DISTINCT - CAST( NULL AS SIGNED ) - - col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7157
SELECT DISTINCT - CAST ( NULL AS INTEGER ) - - col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - 76 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

query I rowsort
SELECT ALL + - col1 + col2 * col1 FROM tab1 AS cor0
----
1235
1378
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-7160
SELECT + + col0 * col1 DIV + CAST( + col2 AS SIGNED ) FROM tab0 AS cor0
----
3395
62
98

skipif mysql # not compatible
query I rowsort label-7160
SELECT + + col0 * col1 / + CAST ( + col2 AS INTEGER ) FROM tab0 AS cor0
----
3395
62
98

query I rowsort
SELECT DISTINCT - 14 * + col1 FROM tab0 cor0
----
-1204
-1274
-1358

onlyif mysql # use DIV operator for integer division
query I rowsort label-7162
SELECT - 68 DIV + col1 FROM tab1 cor0
----
-2
-5
-6

skipif mysql # not compatible
query I rowsort label-7162
SELECT - 68 / + col1 FROM tab1 cor0
----
-2
-5
-6

query I rowsort
SELECT ALL col0 * - col2 * + col2 + cor0.col0 FROM tab2 AS cor0
----
-113997
-5096
-52650

onlyif mysql # use DIV operator for integer division
query I rowsort label-7164
SELECT ALL - col1 - 32 DIV col1 AS col0 FROM tab2 AS cor0
----
-18
-32
-59

skipif mysql # not compatible
query I rowsort label-7164
SELECT ALL - col1 - 32 / col1 AS col0 FROM tab2 AS cor0
----
-18
-32
-59

query I rowsort
SELECT ALL - cor0.col1 * col2 + + col2 AS col1 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL + - col2 + + 33 * ( col2 ) AS col2 FROM tab2 AS cor0
----
1216
832
864

query I rowsort
SELECT DISTINCT + col0 + - cor0.col0 + col0 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + col0 * + 74 FROM tab2 cor0
----
518
5772
5846

onlyif mysql # use DIV operator for integer division
query I rowsort label-7169
SELECT DISTINCT + + col2 * 14 DIV + col0 FROM tab1 cor0
----
12
16
252

skipif mysql # not compatible
query I rowsort label-7169
SELECT DISTINCT + + col2 * 14 / + col0 FROM tab1 cor0
----
12
16
252

onlyif mysql # use DIV operator for integer division
query I rowsort label-7170
SELECT - col1 + - col1 DIV 30 FROM tab0 AS cor0
----
-100
-88
-94

skipif mysql # not compatible
query I rowsort label-7170
SELECT - col1 + - col1 / 30 FROM tab0 AS cor0
----
-100
-88
-94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - 67 col0 FROM tab1 AS cor0
----
201
4288
5360

query I rowsort
SELECT ALL cor0.col1 * - 15 AS col2 FROM tab0 AS cor0
----
-1290
-1365
-1455

query I rowsort
SELECT - col0 * 2 * + col0 FROM tab0 cor0
----
-1152
-15842
-2450

query I rowsort
SELECT + col1 * 1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT col1 * - col2 + + col1 * - col0 AS col2 FROM tab0 AS cor0
----
-15561
-3492
-4902

onlyif mysql # use DIV operator for integer division
query I rowsort label-7176
SELECT ALL + + col0 * col1 DIV col2 AS col1 FROM tab0 AS cor0
----
3395
62
98

skipif mysql # not compatible
query I rowsort label-7176
SELECT ALL + + col0 * col1 / col2 AS col1 FROM tab0 AS cor0
----
3395
62
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7177
SELECT + col2 * - CAST( col1 AS SIGNED ) col1 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7177
SELECT + col2 * - CAST ( col1 AS INTEGER ) col1 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * - 79 col1 FROM tab0 cor0
----
-2607
-6478
-79

query I rowsort
SELECT ALL cor0.col1 + 61 FROM tab1 AS cor0
----
71
74
87

query I rowsort
SELECT + ( 15 ) * + col0 AS col1 FROM tab1 AS cor0
----
1200
45
960

query I rowsort
SELECT - col0 * - col1 - + col0 FROM tab0 cor0
----
2040
3360
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-7182
SELECT ALL col2 DIV - 16 col2 FROM tab1
----
-3
-3
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7182
SELECT ALL col2 / - 16 col2 FROM tab1
----
-3
-3
-6

query I rowsort
SELECT DISTINCT + + 71 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
71

query I rowsort
SELECT ALL - 74 AS col1 FROM tab1, tab1 cor0, tab0 cor1
----
27 values hashing to 5a477330c946251f814fbbfd08e77c28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 95 col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7186
SELECT DISTINCT - - col1 * - col0 * + CAST( + col0 * col0 AS SIGNED ) FROM tab0 AS cor0
----
-1188864
-4158875
-64152179

skipif mysql # not compatible
query I rowsort label-7186
SELECT DISTINCT - - col1 * - col0 * + CAST ( + col0 * col0 AS INTEGER ) FROM tab0 AS cor0
----
-1188864
-4158875
-64152179

query I rowsort
SELECT DISTINCT + - col2 * + col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - - col1 + col1 * - col0 * col1 FROM tab0 AS cor0
----
-177418
-329218
-736918

query I rowsort
SELECT ALL - + col2 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT ALL col0 + + col1 * - 79 AS col0 FROM tab1 AS cor0
----
-2051
-726
-947

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7191
SELECT DISTINCT + CAST( NULL AS DECIMAL ) + col1 AS col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-7191
SELECT DISTINCT + CAST ( NULL AS REAL ) + col1 AS col0 FROM tab1
----
NULL

query I rowsort
SELECT tab2.col1 + 58 AS col2 FROM tab2
----
117
75
89

query I rowsort
SELECT col1 - + col2 * - col0 FROM tab2
----
2087
220
3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 27 col1 FROM tab2, tab2 AS cor0 CROSS JOIN tab0
----
27 values hashing to 0259a67676b131a4843853be4811b775

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 8 col2 FROM tab1
----
8
8
8

query I rowsort
SELECT DISTINCT 89 + + col2 FROM tab1 AS cor0
----
143
146
185

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7197
SELECT + ( col0 ) + + CAST( NULL AS SIGNED ) * col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7197
SELECT + ( col0 ) + + CAST ( NULL AS INTEGER ) * col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + ( col1 ) + col0 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT - + col0 * - col1 + col2 AS col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ( - 55 * col0 ) FROM tab1
----
-165
-3520
-4400

query I rowsort
SELECT DISTINCT + 47 AS col1 FROM tab1, tab1 AS cor0
----
47

query I rowsort
SELECT - ( cor0.col0 ) + + col0 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( ( col2 ) ) col0 FROM tab2 AS cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-7204
SELECT - col1 DIV + 92 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7204
SELECT - col1 / + 92 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + col2 AS REAL ) AS col1 FROM tab2
----
26
27
38

query I rowsort
SELECT DISTINCT - - col1 * col1 + - 92 FROM tab1 AS cor0
----
584
77
8

query I rowsort
SELECT - + col0 * - col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT + col1 + - col1 + col2 * col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT col1 + - cor0.col0 + + 7 FROM tab2 AS cor0
----
-12
-55
31

query I rowsort
SELECT cor0.col1 + col1 * - col1 FROM tab0 cor0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT + col0 * + ( - col1 ) AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT - col1 * - col2 - col2 * cor0.col1 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - cor0.col2 * + 1 * 84 + - col1 + + ( - col0 ) FROM tab1 AS cor0
----
-4565
-4862
-8157

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7214
SELECT + + CAST( NULL AS SIGNED ) + - cor0.col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7214
SELECT + + CAST ( NULL AS INTEGER ) + - cor0.col2 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 * col1 * col0 FROM tab1 AS cor0
----
-234
-40960
-83200

query I rowsort
SELECT - ( 21 ) + - col2 * 53 FROM tab1 cor0
----
-2883
-3042
-5109

query I rowsort
SELECT - - col0 + - 77 * cor0.col2 * - 55 AS col1 FROM tab2 AS cor0
----
110188
114352
161009

query I rowsort
SELECT - - 99 * col2 * + col0 FROM tab2 AS cor0
----
18711
200772
297198

query I rowsort
SELECT DISTINCT + tab0.col2 * 78 * + col0 AS col2 FROM tab0
----
2730
569244
61776

query I rowsort
SELECT - 15 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

query I rowsort
SELECT 91 AS col1 FROM tab0, tab1 cor0, tab2 cor1
----
27 values hashing to deebbcfb9c7803a34dca6bd860849afe

query I rowsort
SELECT col1 * - 92 AS col1 FROM tab2
----
-1564
-2852
-5428

query I rowsort
SELECT 49 + col0 + col2 FROM tab2 AS cor0
----
153
166
83

query I rowsort
SELECT + col0 * - ( + col0 ) + col2 AS col0 FROM tab1
----
-4039
-6304
45

query I rowsort
SELECT - tab0.col0 + - col0 AS col1 FROM tab0
----
-178
-48
-70

query I rowsort
SELECT + + 23 FROM tab0 AS cor0
----
23
23
23

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab1 AS cor0, tab0 cor1, tab1 AS cor2
----
972 values hashing to 7942394eb7766dfb9ea95b7805ff595d

query I rowsort
SELECT ( 39 ) + col1 + + ( + col2 ) * + col0 AS col1 FROM tab0 AS cor0
----
171
7428
917

query I rowsort
SELECT ALL - 42 + col2 FROM tab0
----
-41
-9
40

query I rowsort
SELECT + + 20 * 56 AS col2 FROM tab1 AS cor0
----
1120
1120
1120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + + ( + col0 ) col0 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT + col0 + 74 AS col1 FROM tab0 AS cor0
----
109
163
98

query I rowsort
SELECT DISTINCT col0 * + 31 AS col1 FROM tab0 AS cor0
----
1085
2759
744

query I rowsort
SELECT ALL - 77 FROM tab2 AS cor0
----
-77
-77
-77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7235
SELECT DISTINCT CAST( NULL AS DECIMAL ) + col2 + col0 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7235
SELECT DISTINCT CAST ( NULL AS REAL ) + col2 + col0 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + - ( + ( col2 ) ) + + ( - col0 ) AS col1 FROM tab0 cor0
----
-171
-36
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7237
SELECT ALL - CAST( NULL AS DECIMAL ) AS col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7237
SELECT ALL - CAST ( NULL AS REAL ) AS col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL - col2 * 44 FROM tab1
----
-2376
-2508
-4224

query I rowsort
SELECT DISTINCT 49 * - 84 FROM tab2
----
-4116

query I rowsort
SELECT DISTINCT + - col0 * cor0.col1 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT 26 * col0 AS col1 FROM tab0 AS cor0
----
2314
624
910

query I rowsort
SELECT ALL + - cor0.col0 * col0 + col1 FROM tab1 AS cor0
----
-4086
-6387
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-7243
SELECT ALL + col2 + col1 * col1 DIV ( col1 ) FROM tab1 cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-7243
SELECT ALL + col2 + col1 * col1 / ( col1 ) FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT ALL + ( col2 ) + 17 * ( col0 + ( col0 ) ) FROM tab1 AS cor0
----
156
2233
2816

query I rowsort
SELECT DISTINCT - 1 FROM tab2 AS cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - cor0.col2 col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - + 65 * - col1 AS col0 FROM tab0 AS cor0
----
5590
5915
6305

query I rowsort
SELECT ALL - col2 + col2 * + col0 + + col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT - col0 * 6 FROM tab0
----
-144
-210
-534

query I rowsort
SELECT - 39 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to a08a82dc9276c0173448e9a1c89dba93

query I rowsort
SELECT + col0 * ( col2 ) + + col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL col1 * ( cor0.col1 ) FROM tab1 cor0
----
100
169
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-7253
SELECT col2 DIV col0 AS col1 FROM tab2
----
0
0
3

skipif mysql # not compatible
query I rowsort label-7253
SELECT col2 / col0 AS col1 FROM tab2
----
0
0
3

query I rowsort
SELECT + col1 * - ( - cor0.col2 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT - + col2 + + ( - 30 * - col2 ) + col0 FROM tab2 AS cor0
----
1181
790
832

query I rowsort
SELECT - 58 AS col1 FROM tab0
----
-58
-58
-58

query I rowsort
SELECT col0 + 48 * col1 AS col1 FROM tab0 AS cor0
----
4152
4457
4691

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7258
SELECT col0 + - CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7258
SELECT col0 + - CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 * col2 * + cor0.col1 FROM tab1 cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT - cor0.col1 * col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + col1 * col1 AS col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT col1 * + col2 AS col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT + col0 + col0 FROM tab1 WHERE NOT ( NULL ) IN ( - col2 )
----

query I rowsort
SELECT col1 AS col0 FROM tab2 WHERE NULL NOT IN ( col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7265
SELECT DISTINCT - col1 * - col0 DIV + col0 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-7265
SELECT DISTINCT - col1 * - col0 / + col0 FROM tab2
----
17
31
59

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL IN ( - col0 * col0 - + tab1.col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7267
SELECT col1 DIV col1 col0 FROM tab2
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7267
SELECT col1 / col1 col0 FROM tab2
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7268
SELECT DISTINCT - col0 DIV + tab1.col1 AS col2 FROM tab1
----
-6
0

skipif mysql # not compatible
query I rowsort label-7268
SELECT DISTINCT - col0 / + tab1.col1 AS col2 FROM tab1
----
-6
0

query I rowsort
SELECT + col1 * tab0.col2 + col1 FROM tab0
----
194
2924
7553

onlyif mysql # use DIV operator for integer division
query I rowsort label-7270
SELECT ALL - col2 DIV col0 col2 FROM tab0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7270
SELECT ALL - col2 / col0 col2 FROM tab0
----
-1
0
0

query I rowsort
SELECT DISTINCT col0 * col2 + col1 + + col2 FROM tab2
----
2113
247
3057

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + col0 col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT col1 + col0 + - col1 * col1 FROM tab2
----
-193
-3344
-923

query I rowsort
SELECT col1 - col2 * - col0 FROM tab1
----
188
3658
7693

query III rowsort
SELECT * FROM tab0 WHERE - col1 * - col2 >= NULL
----

query I rowsort
SELECT col0 + col0 * col0 AS col0 FROM tab0
----
1260
600
8010

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * col1 col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - col2 * + col2 * col0 AS col2 FROM tab2
----
-114076
-5103
-52728

onlyif mysql # use DIV operator for integer division
query I rowsort label-7279
SELECT ALL + - col0 DIV + col2 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-7279
SELECT ALL + - col0 / + col2 FROM tab1 AS cor0
----
-1
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7280
SELECT DISTINCT - - col2 * - col0 DIV col0 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-7280
SELECT DISTINCT - - col2 * - col0 / col0 FROM tab1 AS cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - col0 col2 FROM tab0
----
-34
-7
9

query I rowsort
SELECT ALL + col2 - - cor0.col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT - col2 + + col1 AS col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT col2 * + col0 FROM tab0 cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-7285
SELECT ALL + col0 + cor0.col2 * cor0.col1 DIV col0 FROM tab0 AS cor0
----
142
172
37

skipif mysql # not compatible
query I rowsort label-7285
SELECT ALL + col0 + cor0.col2 * cor0.col1 / col0 FROM tab0 AS cor0
----
142
172
37

query I rowsort
SELECT DISTINCT + col0 + col0 * - col1 AS col2 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT DISTINCT + + col0 * - col2 + + col1 FROM tab1 cor0
----
-136
-3638
-7667

query I rowsort
SELECT ALL + + col0 - + col0 * + col2 AS col2 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT col2 + + col2 + - col1 FROM tab0
----
-20
-95
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-7290
SELECT DISTINCT col1 DIV - col1 + col0 FROM tab2
----
6
77
78

skipif mysql # not compatible
query I rowsort label-7290
SELECT DISTINCT col1 / - col1 + col0 FROM tab2
----
6
77
78

query I rowsort
SELECT ALL - tab0.col2 * col0 + col0 * - col2 AS col1 FROM tab0
----
-14596
-1584
-70

query I rowsort
SELECT ALL + col1 + + col1 * tab1.col2 FROM tab1
----
1261
1430
580

query I rowsort
SELECT - tab1.col2 FROM tab2, tab0 AS cor0 CROSS JOIN tab1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

onlyif mysql # use DIV operator for integer division
query I rowsort label-7294
SELECT ALL col0 DIV + tab1.col1 FROM tab1
----
0
6
6

skipif mysql # not compatible
query I rowsort label-7294
SELECT ALL col0 / + tab1.col1 FROM tab1
----
0
6
6

query I rowsort
SELECT col0 + col0 FROM tab0 WHERE NULL BETWEEN col0 * col0 AND col2
----

query I rowsort
SELECT DISTINCT - + col2 + col0 AS col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT col0 + - col2 AS col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL - col0 * cor0.col0 AS col2 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL - col2 * + col1 + - col0 AS col0 FROM tab2 AS cor0
----
-1612
-725
-844

onlyif mysql # use DIV operator for integer division
query I rowsort label-7300
SELECT DISTINCT + col0 * col0 * + col1 + col1 DIV col2 FROM tab0 cor0
----
118922
49538
720812

skipif mysql # not compatible
query I rowsort label-7300
SELECT DISTINCT + col0 * col0 * + col1 + col1 / col2 FROM tab0 cor0
----
118922
49538
720812

query I rowsort
SELECT DISTINCT + col1 + col2 * col2 AS col1 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT - cor0.col0 * col2 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + col0 * - col0 AS col1 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL col2 + + col2 * col0 * col1 FROM tab0 AS cor0
----
3396
664200
68145

query I rowsort
SELECT DISTINCT + - cor0.col0 * - col0 + + cor0.col2 AS col1 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT + tab0.col2 * col2 AS col2 FROM tab0
----
1
1089
6724

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 91 col0 FROM tab0
----
91
91
91

query I rowsort
SELECT ALL -