hash-threshold 8

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

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

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

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

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

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

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

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

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-0
SELECT ALL CAST ( ( + cor0.col1 ) AS INTEGER ) + + cor0.col2 FROM tab0, tab0 cor0
----
9 values hashing to 5484e660e65aa37f29a1eca3fc30f5cc

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-2
SELECT + col1 + CAST( - 56 AS SIGNED ) DIV + col1 AS col0 FROM tab1 AS cor0
----
24
5
9

skipif mysql # not compatible
query I rowsort label-2
SELECT + col1 + CAST ( - 56 AS INTEGER ) / + col1 AS col0 FROM tab1 AS cor0
----
24
5
9

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

query I rowsort
SELECT 54 * 0 FROM tab1, tab0 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - col0 * - 71 * - cor0.col1 FROM tab2 AS cor0
----
-15407
-326742
-95353

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

query I rowsort
SELECT ALL - + ( - col1 ) AS col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT ALL - ( + 57 ) FROM tab2
----
-57
-57
-57

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

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

query I rowsort
SELECT ALL - + 30 * - col1 - - col1 FROM tab2 AS cor0
----
1829
527
961

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

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

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

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

query I rowsort
SELECT + cor0.col2 + - 97 * col0 AS col2 FROM tab2 AS cor0
----
-652
-7540
-7625

query I rowsort
SELECT DISTINCT + col1 * 37 FROM tab0 AS cor0
----
3182
3367
3589

query I rowsort
SELECT ALL col2 + - 1 FROM tab1 AS cor0
----
53
56
95

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

query I rowsort
SELECT ALL col1 * 54 FROM tab1
----
1404
540
702

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-20
SELECT + tab2.col1 * col2 + col1 DIV + col1 AS col2 FROM tab2
----
1535
647
838

skipif mysql # not compatible
query I rowsort label-20
SELECT + tab2.col1 * col2 + col1 / + col1 AS col2 FROM tab2
----
1535
647
838

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

skipif mysql # not compatible
query I rowsort label-21
SELECT ALL + col1 / 38 AS col0 FROM tab2
----
0
0
1

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-23
SELECT DISTINCT - CAST( cor0.col1 AS SIGNED ) FROM tab2, tab1 AS cor0 CROSS JOIN tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-23
SELECT DISTINCT - CAST ( cor0.col1 AS INTEGER ) FROM tab2, tab1 AS cor0 CROSS JOIN tab1
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + ( + col0 ) ) + 92 col0 FROM tab0 AS cor0
----
116
127
181

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

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

skipif mysql # not compatible
query I rowsort label-26
SELECT CAST ( NULL AS REAL ) * + col0 + col2 / - 74 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 66 + - 21 AS col1 FROM tab0 AS cor0
----
45
45
45

query I rowsort
SELECT col2 + - 29 * - col1 FROM tab2 cor0
----
1737
531
926

query I rowsort
SELECT ALL - + 81 + 59 AS col1 FROM tab1 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to fae46f8148b02964f7145eb6ed5819f9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-30
SELECT DISTINCT + CAST( 47 AS SIGNED ) FROM tab0 cor0 CROSS JOIN tab1 cor1
----
47

skipif mysql # not compatible
query I rowsort label-30
SELECT DISTINCT + CAST ( 47 AS INTEGER ) FROM tab0 cor0 CROSS JOIN tab1 cor1
----
47

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-33
SELECT DISTINCT 85 * col2 DIV col2 + - col1 FROM tab1 AS cor0
----
59
72
75

skipif mysql # not compatible
query I rowsort label-33
SELECT DISTINCT 85 * col2 / col2 + - col1 FROM tab1 AS cor0
----
59
72
75

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

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

query I rowsort
SELECT - + 64 + + col0 * + 49 FROM tab1 AS cor0
----
3072
3856
83

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-40
SELECT ALL col1 * - CAST( + 63 AS SIGNED ) + + col1 DIV - 28 AS col0 FROM tab2 AS cor0
----
-1071
-1954
-3719

skipif mysql # not compatible
query I rowsort label-40
SELECT ALL col1 * - CAST ( + 63 AS INTEGER ) + + col1 / - 28 AS col0 FROM tab2 AS cor0
----
-1071
-1954
-3719

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

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

query I rowsort
SELECT ALL col0 * col1 + col1 * + col0 FROM tab2
----
2686
434
9204

query I rowsort
SELECT + col0 * - 14 FROM tab2 AS cor0
----
-1092
-1106
-98

query I rowsort
SELECT + col0 * 45 + col1 * - col2 FROM tab0 AS cor0
----
-1758
-3457
1478

onlyif mysql # use DIV operator for integer division
query I rowsort label-45
SELECT col0 DIV ( 79 ) - col2 * - 27 FROM tab0 AS cor0
----
2215
27
891

skipif mysql # not compatible
query I rowsort label-45
SELECT col0 / ( 79 ) - col2 * - 27 FROM tab0 AS cor0
----
2215
27
891

query I rowsort
SELECT ALL col1 * col1 + col2 AS col0 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT ALL + - col0 * 20 * + 47 AS col2 FROM tab0 cor0
----
-22560
-32900
-83660

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

query I rowsort
SELECT DISTINCT - - col2 + + 28 FROM tab1 AS cor0
----
124
82
85

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

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

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

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

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

query I rowsort
SELECT col2 + col1 * col0 - + ( col2 ) * cor0.col2 * ( col1 ) FROM tab0 AS cor0
----
-603703
-91557
3299

query I rowsort
SELECT + col1 * 86 FROM tab1
----
1118
2236
860

query I rowsort
SELECT DISTINCT + cor0.col2 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
26
27
38

query I rowsort
SELECT + col0 * - col2 * - col2 AS col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT DISTINCT + col2 * + 94 AS col0 FROM tab2
----
2444
2538
3572

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

query I rowsort
SELECT + - 80 + col0 AS col1 FROM tab1 AS cor0
----
-16
-77
0

query I rowsort
SELECT ALL - - 14 + col0 FROM tab0 AS cor0
----
103
38
49

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

skipif mysql # not compatible
query I rowsort label-61
SELECT DISTINCT CAST ( NULL AS INTEGER ) FROM tab1, tab0 AS cor0, tab2 AS cor1
----
NULL

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

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

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

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-66
SELECT DISTINCT col1 DIV tab2.col1 + col1 + - col0 FROM tab2
----
-18
-61
25

skipif mysql # not compatible
query I rowsort label-66
SELECT DISTINCT col1 / tab2.col1 + col1 + - col0 FROM tab2
----
-18
-61
25

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-68
SELECT ALL + col1 + + col0 DIV col1 FROM tab0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-68
SELECT ALL + col1 + + col0 / col1 FROM tab0
----
86
91
97

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

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

query I rowsort
SELECT col2 + + tab2.col0 + - col2 * - tab2.col1 * tab2.col1 FROM tab2
----
11099
25981
90610

query I rowsort
SELECT col1 FROM tab0 WHERE NULL NOT BETWEEN NULL AND + col1
----

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

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

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

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL BETWEEN - col2 + col1 AND ( + col2 + col0 )
----

query I rowsort
SELECT - col0 + col2 + + col2 AS col0 FROM tab0
----
-33
42
75

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

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

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

query I rowsort
SELECT DISTINCT 4 + col2 FROM tab0 AS cor0
----
37
5
86

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

query I rowsort
SELECT DISTINCT - col2 + col0 * col1 * + ( col0 ) AS col2 FROM tab1
----
180
40903
83104

onlyif mysql # use DIV operator for integer division
query I rowsort label-83
SELECT DISTINCT col1 + col1 DIV 16 col2 FROM tab1
----
10
13
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-83
SELECT DISTINCT col1 + col1 / 16 col2 FROM tab1
----
10
13
27

query I rowsort
SELECT + col0 + col0 + 44 * 96 FROM tab2
----
4238
4380
4382

query I rowsort
SELECT - 39 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to a08a82dc9276c0173448e9a1c89dba93

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

skipif mysql # not compatible
query I rowsort label-86
SELECT 5 / + col1 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT col2 + - col0 * col0 * col2 FROM tab1
----
-233415
-432
-614304

query I rowsort
SELECT ALL - + 57 * - col1 FROM tab2 AS cor0
----
1767
3363
969

onlyif mysql # use DIV operator for integer division
query I rowsort label-89
SELECT DISTINCT - cor0.col1 DIV 2 AS col0 FROM tab1, tab2 cor0
----
-15
-29
-8

skipif mysql # not compatible
query I rowsort label-89
SELECT DISTINCT - cor0.col1 / 2 AS col0 FROM tab1, tab2 cor0
----
-15
-29
-8

query I rowsort
SELECT + col0 * + col1 - - 14 * - 79 AS col1 FROM tab2 AS cor0
----
-889
237
3496

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

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

query III rowsort
SELECT DISTINCT * FROM tab0 AS cor0 WHERE - col0 * + col1 + + col2 >= ( - col1 + col0 )
----

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

query I rowsort
SELECT DISTINCT + col2 FROM tab0 WHERE col0 NOT BETWEEN ( NULL ) AND NULL
----

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

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

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

query I rowsort
SELECT DISTINCT + col0 AS col2 FROM tab2 WHERE NULL > NULL
----

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

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

query I rowsort
SELECT ALL + ( 17 ) * col2 + col1 FROM tab0 AS cor0
----
114
1485
647

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

query I rowsort
SELECT DISTINCT - 44 * - col2 FROM tab2 AS cor0
----
1144
1188
1672

query I rowsort
SELECT DISTINCT - 84 * col2 + + col1 AS col0 FROM tab2 cor0
----
-2125
-2237
-3175

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - 65 + col1 col2 FROM tab1
----
1716
660
858

query I rowsort
SELECT + col1 + - col1 * + 33 AS col0 FROM tab1 AS cor0
----
-320
-416
-832

onlyif mysql # use DIV operator for integer division
query I rowsort label-111
SELECT DISTINCT ( 91 + col1 ) DIV ( + col1 ) AS col1 FROM tab1
----
10
4
8

skipif mysql # not compatible
query I rowsort label-111
SELECT DISTINCT ( 91 + col1 ) / ( + col1 ) AS col1 FROM tab1
----
10
4
8

query I rowsort
SELECT DISTINCT - 46 * - 98 AS col0 FROM tab2
----
4508

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

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

skipif mysql # not compatible
query I rowsort label-114
SELECT - cor0.col2 + - 65 / - col0 + + col2 AS col1 FROM tab0 AS cor0
----
0
1
2

query I rowsort
SELECT + 11 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 69116737f3f57e2e3273f6dbb04d036c

query I rowsort
SELECT DISTINCT - col0 + col2 * ( ( col1 ) ) FROM tab2
----
1456
567
830

query I rowsort
SELECT ALL - tab1.col1 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT 97 + + col0 * 54 - + col0 FROM tab1
----
256
3489
4337

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-120
SELECT DISTINCT + 12 * col2 DIV 54 + col0 AS col2 FROM tab1
----
101
15
76

skipif mysql # not compatible
query I rowsort label-120
SELECT DISTINCT + 12 * col2 / 54 + col0 AS col2 FROM tab1
----
101
15
76

query I rowsort
SELECT - + 17 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 490d008f3fb5b70d3971cfc6d84503f4

query I rowsort
SELECT DISTINCT + col2 + 62 AS col2 FROM tab0 AS cor0
----
144
63
95

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-124
SELECT + cor0.col1 + - ( col2 ) DIV + col2 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-124
SELECT + cor0.col1 + - ( col2 ) / + col2 FROM tab0 AS cor0
----
85
90
96

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

query I rowsort
SELECT + - cor0.col1 * col2 * ( col0 ) + 44 * col2 AS col0 FROM tab0 AS cor0
----
-3351
-660510
-66660

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

query I rowsort
SELECT DISTINCT col1 * + cor0.col0 - col1 * + cor0.col2 FROM tab0 AS cor0
----
-774
3298
637

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

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

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

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

query I rowsort
SELECT DISTINCT cor1.col0 AS col1 FROM tab0, tab2 cor0 CROSS JOIN tab2, tab1, tab0 cor1
----
24
35
89

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

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

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

query I rowsort
SELECT DISTINCT cor0.col2 * cor0.col2 + - 57 + - col0 FROM tab1 AS cor0
----
2856
3128
9079

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

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

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

query I rowsort
SELECT col1 * col1 + 87 * col1 FROM tab2 AS cor0
----
1768
3658
8614

query I rowsort
SELECT ALL 64 - - col2 * - col2 FROM tab1
----
-2852
-3185
-9152

query I rowsort
SELECT - + 47 * 69 FROM tab0 AS cor0
----
-3243
-3243
-3243

query I rowsort
SELECT + col0 + 91 AS col0 FROM tab2 AS cor0
----
169
170
98

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

query I rowsort
SELECT ALL 17 * - 58 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 0041b9d75ee7cdf68153b36d64c39a4f

query I rowsort
SELECT DISTINCT col2 * - 62 AS col1 FROM tab1
----
-3348
-3534
-5952

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

query I rowsort
SELECT + - ( - col2 ) + + col1 * - col2 AS col1 FROM tab2 AS cor0
----
-1508
-608
-810

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

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

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

query I rowsort
SELECT ALL 28 AS col1 FROM tab1, tab0 cor0
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

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

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

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

query I rowsort
SELECT ALL - 73 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 84ab9db5468b4a1781bd8d5c8e0e77fc

query I rowsort
SELECT DISTINCT col2 * 26 * col0 AS col0 FROM tab1
----
199680
4212
94848

query I rowsort
SELECT ALL ( - col2 + + col2 ) * - col2 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT + ( - tab2.col2 ) - - 2 * col1 AS col1 FROM tab2
----
-4
35
92

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

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

query I rowsort
SELECT DISTINCT - col2 * col2 + 81 FROM tab1 AS cor0
----
-2835
-3168
-9135

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

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

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

query I rowsort
SELECT ALL ( col2 ) * 3 AS col0 FROM tab1 AS cor0
----
162
171
288

query I rowsort
SELECT ALL + - 56 * col1 + col2 - - 32 FROM tab2 AS cor0
----
-1677
-3246
-882

query I rowsort
SELECT DISTINCT 29 * + col1 + - col1 * + col0 AS col2 FROM tab1 AS cor0
----
-350
-663
676

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

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-171
SELECT + col2 + - col1 DIV + col1 AS col1 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-171
SELECT + col2 + - col1 / + col1 AS col1 FROM tab2 AS cor0
----
25
26
37

query I rowsort
SELECT DISTINCT + col2 * 75 * + col1 FROM tab2 AS cor0
----
115050
48450
62775

onlyif mysql # use DIV operator for integer division
query I rowsort label-173
SELECT ALL + ( col1 ) + col1 * 51 DIV col1 col1 FROM tab1 AS cor0
----
61
64
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-173
SELECT ALL + ( col1 ) + col1 * 51 / col1 col1 FROM tab1 AS cor0
----
61
64
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-174
SELECT DISTINCT cor0.col1 + - 62 DIV cor0.col2 col0 FROM tab0 AS cor0
----
35
85
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-174
SELECT DISTINCT cor0.col1 + - 62 / cor0.col2 col0 FROM tab0 AS cor0
----
35
85
91

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

query I rowsort
SELECT ALL - 77 + + 25 AS col2 FROM tab1 AS cor0
----
-52
-52
-52

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

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

query I rowsort
SELECT ALL col2 * - col0 + - ( col2 ) * + cor0.col0 - - 67 AS col1 FROM tab1 AS cor0
----
-15293
-257
-7229

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

query I rowsort
SELECT cor0.col1 + 13 * 32 FROM tab2 cor0
----
433
447
475

query I rowsort
SELECT DISTINCT col0 * - cor0.col0 * - 43 - col0 FROM tab1 AS cor0
----
176064
275120
384

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

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

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

query I rowsort
SELECT - col1 * + col1 - + ( 50 + col2 ) FROM tab2
----
-1038
-3557
-377

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

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

query I rowsort
SELECT 91 - - cor1.col0 AS col1 FROM tab1, tab0 cor0, tab2, tab1 AS cor1
----
81 values hashing to 6a3b86ef47d458be50e7391d74f840d5

query I rowsort
SELECT ALL col2 * - ( + col0 ) * col1 + col2 FROM tab1
----
-36423
-4158
-99744

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

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

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

query I rowsort
SELECT ALL 22 + col2 + col2 AS col1 FROM tab2
----
74
76
98

query I rowsort
SELECT DISTINCT - cor0.col1 + 7 FROM tab1, tab2 AS cor0
----
-10
-24
-52

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

skipif mysql # not compatible
query I rowsort label-193
SELECT ( tab1.col1 ) + CAST ( NULL AS REAL ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + col1 * 91 AS col2 FROM tab1
----
1196
2392
920

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

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

query I rowsort
SELECT - - 66 AS col1 FROM tab0 AS cor0
----
66
66
66

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

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

query I rowsort
SELECT DISTINCT + 13 + + col2 FROM tab0 AS cor0
----
14
46
95

query I rowsort
SELECT + ( col2 ) + - ( + cor0.col0 ) + col0 * ( - col1 ) FROM tab0 AS cor0
----
-2055
-3429
-8106

query I rowsort
SELECT DISTINCT - col2 * col0 * + ( - 81 ) FROM tab0 AS cor0
----
2835
591138
64152

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

query I rowsort
SELECT ALL - + 28 * col1 FROM tab2 cor0
----
-1652
-476
-868

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

query I rowsort
SELECT - col1 + - col0 * col0 FROM tab1 AS cor0
----
-35
-4106
-6413

onlyif mysql # use DIV operator for integer division
query I rowsort label-205
SELECT - col2 * col0 DIV 80 AS col1 FROM tab0 cor0
----
-9
-91
0

skipif mysql # not compatible
query I rowsort label-205
SELECT - col2 * col0 / 80 AS col1 FROM tab0 cor0
----
-9
-91
0

query I rowsort
SELECT ALL 8 * tab2.col2 FROM tab2
----
208
216
304

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-209
SELECT ALL + 96 + col0 DIV col1 + cor0.col1 * 44 FROM tab1 AS cor0
----
1240
542
674

skipif mysql # not compatible
query I rowsort label-209
SELECT ALL + 96 + col0 / col1 + cor0.col1 * 44 FROM tab1 AS cor0
----
1240
542
674

query I rowsort
SELECT - 36 - + col2 AS col2 FROM tab1 AS cor0
----
-132
-90
-93

query I rowsort
SELECT DISTINCT + ( ( tab0.col0 ) ) + + 19 AS col2 FROM tab0
----
108
43
54

query I rowsort
SELECT DISTINCT col1 * col2 + - col2 + 8 AS col0 FROM tab1
----
1160
1358
521

onlyif mysql # use DIV operator for integer division
query I rowsort label-213
SELECT + ( tab2.col1 ) DIV + col1 AS col1 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-213
SELECT + ( tab2.col1 ) / + col1 AS col1 FROM tab2
----
1
1
1

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

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

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

query I rowsort
SELECT ALL 41 AS col1 FROM tab1, tab1 cor0, tab1 AS cor1, tab0 AS cor2
----
81 values hashing to 0733f496a5445ffeac9d19797afe4831

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

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

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

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

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

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

query I rowsort
SELECT - + col2 * col2 + 75 FROM tab1 AS cor0
----
-2841
-3174
-9141

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

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

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

query I rowsort
SELECT col2 * - col0 + tab2.col1 * + col0 * - tab2.col2 FROM tab2
----
-121680
-54036
-6048

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

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

query I rowsort
SELECT 76 * + ( + tab2.col1 ) AS col1 FROM tab2
----
1292
2356
4484

onlyif mysql # use DIV operator for integer division
query I rowsort label-229
SELECT 97 DIV + col1 AS col2 FROM tab1
----
3
7
9

skipif mysql # not compatible
query I rowsort label-229
SELECT 97 / + col1 AS col2 FROM tab1
----
3
7
9

query I rowsort
SELECT 43 AS col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to ee5108f6248be48c54e069545f81c5d9

query I rowsort
SELECT + ( - tab0.col0 * cor0.col0 ) + + 92 FROM tab0, tab0 AS cor0
----
9 values hashing to 730aa60ea4157c6156c2a48c075a9315

onlyif mysql # use DIV operator for integer division
query I rowsort label-232
SELECT 44 DIV + tab1.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 8f17c7717daed768d3828a51d27471f0

skipif mysql # not compatible
query I rowsort label-232
SELECT 44 / + tab1.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 8f17c7717daed768d3828a51d27471f0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col1 * - 86 col1 FROM tab1 AS cor0
----
1118
2236
860

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

query I rowsort
SELECT ALL col0 * col1 * col0 AS col1 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT 43 - 66 AS col1 FROM tab2 AS cor0
----
-23
-23
-23

query I rowsort
SELECT DISTINCT - 74 + 83 FROM tab1 AS cor0
----
9

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

query I rowsort
SELECT - col0 + - col2 + + col1 FROM tab1 AS cor0
----
-111
-163
-31

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

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

query I rowsort
SELECT - 25 * col1 + - col0 * + cor0.col1 * - col1 FROM tab0 AS cor0
----
175354
326890
734734

onlyif mysql # use DIV operator for integer division
query I rowsort label-242
SELECT - cor0.col0 DIV + col1 + col1 AS col0 FROM tab1 AS cor0
----
26
4
7

skipif mysql # not compatible
query I rowsort label-242
SELECT - cor0.col0 / + col1 + col1 AS col0 FROM tab1 AS cor0
----
26
4
7

query I rowsort
SELECT ALL - - col1 + cor0.col1 + ( + col0 ) AS col2 FROM tab1 AS cor0
----
106
55
84

query I rowsort
SELECT + 71 + col0 FROM tab1 AS cor0
----
135
151
74

query I rowsort
SELECT + 42 * + col0 AS col0 FROM tab1 cor0
----
126
2688
3360

query I rowsort
SELECT + ( - col2 ) + col1 * 13 FROM tab0 AS cor0
----
1085
1101
1260

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

query I rowsort
SELECT + + col2 * - col0 + + col0 + + ( + col1 ) AS col0 FROM tab1 AS cor0
----
-133
-3574
-7587

onlyif mysql # use DIV operator for integer division
query I rowsort label-249
SELECT + 46 DIV col1 + - ( col0 ) AS col1 FROM tab1
----
-2
-60
-77

skipif mysql # not compatible
query I rowsort label-249
SELECT + 46 / col1 + - ( col0 ) AS col1 FROM tab1
----
-2
-60
-77

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

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

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

query I rowsort
SELECT ALL - 14 - - col1 FROM tab1 AS cor0
----
-1
-4
12

query I rowsort
SELECT ALL - cor0.col2 * 71 * ( - col2 ) FROM tab0 cor0
----
477404
71
77319

query I rowsort
SELECT ALL + col1 - - 96 AS col1 FROM tab0 cor0
----
182
187
193

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-256
SELECT DISTINCT + col1 * - 59 + ( col0 ) DIV col0 AS col2 FROM tab1 AS cor0
----
-1533
-589
-766

skipif mysql # not compatible
query I rowsort label-256
SELECT DISTINCT + col1 * - 59 + ( col0 ) / col0 AS col2 FROM tab1 AS cor0
----
-1533
-589
-766

query I rowsort
SELECT 75 * tab0.col2 AS col1 FROM tab0
----
2475
6150
75

query I rowsort
SELECT + 39 * - col0 FROM tab0
----
-1365
-3471
-936

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

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

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

skipif mysql # not compatible
query I rowsort label-260
SELECT DISTINCT + CAST ( NULL AS INTEGER ) - 98 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-261
SELECT DISTINCT + col1 DIV 58 FROM tab2
----
0
1

skipif mysql # not compatible
query I rowsort label-261
SELECT DISTINCT + col1 / 58 FROM tab2
----
0
1

query IIIIIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab0, tab1 AS cor2
----
13122 values hashing to 91914e1516bd74d1b537b3edd58ebcd3

query I rowsort
SELECT - 54 * 34 * col2 AS col2 FROM tab0
----
-150552
-1836
-60588

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - 93 AS REAL ) * - col0 * + col1 FROM tab2
----
124899
20181
427986

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

query I rowsort
SELECT 43 + - col1 AS col1 FROM tab1 AS cor0
----
17
30
33

query I rowsort
SELECT 5 + col1 * - cor0.col0 + + ( - col1 ) FROM tab2 AS cor0
----
-1355
-243
-4656

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-269
SELECT ALL - 17 * - col0 + 70 DIV 42 + + cor0.col0 col2 FROM tab2 AS cor0
----
127
1405
1423

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-269
SELECT ALL - 17 * - col0 + 70 / 42 + + cor0.col0 col2 FROM tab2 AS cor0
----
127
1405
1423

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col1 + - col1 col2 FROM tab2 cor0
----
1326
186
4543

query I rowsort
SELECT + 4 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
216
228
384

query I rowsort
SELECT DISTINCT - - 37 + 83 * + col1 AS col2 FROM tab1 AS cor0
----
1116
2195
867

query I rowsort
SELECT ALL - - col2 + + 59 AS col0 FROM tab1 AS cor0
----
113
116
155

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-276
SELECT DISTINCT + col1 DIV + col0 + col1 FROM tab2 AS cor0
----
17
35
59

skipif mysql # not compatible
query I rowsort label-276
SELECT DISTINCT + col1 / + col0 + col1 FROM tab2 AS cor0
----
17
35
59

query I rowsort
SELECT DISTINCT + col2 * 38 * - cor0.col0 FROM tab1 AS cor0
----
-138624
-291840
-6156

onlyif mysql # use DIV operator for integer division
query I rowsort label-278
SELECT DISTINCT 67 DIV col2 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
55
58
96

skipif mysql # not compatible
query I rowsort label-278
SELECT DISTINCT 67 / col2 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
55
58
96

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

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

skipif mysql # not compatible
query I rowsort label-280
SELECT DISTINCT - col1 / 69 AS col1 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-281
SELECT ALL col2 DIV - ( + col1 ) + + 23 FROM tab2 AS cor0
----
21
23
23

skipif mysql # not compatible
query I rowsort label-281
SELECT ALL col2 / - ( + col1 ) + + 23 FROM tab2 AS cor0
----
21
23
23

query I rowsort
SELECT DISTINCT col0 * - 55 + + col1 FROM tab2
----
-354
-4231
-4328

query I rowsort
SELECT DISTINCT + col1 + ( col2 + 26 ) * - col1 * col2 FROM tab1 AS cor0
----
-112294
-152243
-47300

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

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

query I rowsort
SELECT ALL + + col2 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
1444
676
729

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

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

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

query I rowsort
SELECT ( 82 ) - col2 * col2 AS col2 FROM tab1
----
-2834
-3167
-9134

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

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

query I rowsort
SELECT col1 + + 84 FROM tab1 AS cor0
----
110
94
97

query I rowsort
SELECT 76 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 7b2b08dd3f1adef028d3f40ef7c716da

query I rowsort
SELECT - + 12 FROM tab0 cor0 CROSS JOIN tab2 cor1
----
9 values hashing to e698dd57d3aac30af14ce35da434bb45

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 59 - + col0 * col0 col0 FROM tab2
----
-6025
-6182
10

query I rowsort
SELECT + 81 - + col1 * col2 FROM tab1
----
-1167
-1323
-489

onlyif mysql # use DIV operator for integer division
query I rowsort label-300
SELECT DISTINCT col0 DIV col0 + + col1 * col0 FROM tab2
----
1344
218
4603

skipif mysql # not compatible
query I rowsort label-300
SELECT DISTINCT col0 / col0 + + col1 * col0 FROM tab2
----
1344
218
4603

query I rowsort
SELECT + col2 + col2 * - col2 * - col0 + - ( + col2 ) * - col1 AS col0 FROM tab1
----
10206
208563
738624

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

query I rowsort
SELECT col1 + - 71 FROM tab0
----
15
20
26

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

query I rowsort
SELECT DISTINCT tab0.col2 + - 10 AS col0 FROM tab0
----
-9
23
72

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

query I rowsort
SELECT ALL - col1 * - col1 * + 7 + col1 AS col0 FROM tab1 AS cor0
----
1196
4758
710

query I rowsort
SELECT DISTINCT col0 * - 12 + col0 FROM tab0
----
-264
-385
-979

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

query I rowsort
SELECT - - ( 65 ) FROM tab0 AS cor0 CROSS JOIN tab0, tab1 cor1
----
27 values hashing to 1c9d0bf96cd3361942fadad668138b9c

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

query I rowsort
SELECT + tab1.col0 * - 99 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to 0efdcd7c477bd4fb6c16e7f8362ec86b

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

query I rowsort
SELECT ALL - 82 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to f800b0aad28b82b2deb67f7045c9a45c

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

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

skipif mysql # not compatible
query I rowsort label-316
SELECT ALL - - CAST ( 43 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
43
43
43

query I rowsort
SELECT DISTINCT col2 - 95 AS col1 FROM tab0 AS cor0
----
-13
-62
-94

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

skipif mysql # not compatible
query I rowsort label-318
SELECT ALL - + CAST ( - 97 AS INTEGER ) * col0 FROM tab0 AS cor0
----
2328
3395
8633

query I rowsort
SELECT + col1 + 82 AS col2 FROM tab0 AS cor0
----
168
173
179

query I rowsort
SELECT + col0 * col1 + + 15 AS col0 FROM tab1
----
1055
655
93

query I rowsort
SELECT 93 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 85ef191bf1b307f300b3fd49992fcae7

query I rowsort
SELECT ALL + - ( cor0.col1 ) FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

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 + 84 * - col1 FROM tab1 AS cor0
----
-1092
-2184
-840

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

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

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

query I rowsort
SELECT DISTINCT 49 + col1 * + col2 * + col0 FROM tab1 AS cor0
----
36529
4261
99889

query I rowsort
SELECT ALL - + col1 * ( col1 * col2 ) AS col0 FROM tab0 AS cor0
----
-244068
-679042
-9409

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

query I rowsort
SELECT ALL - col0 + - ( col0 * - col1 + + cor0.col0 ) FROM tab0 AS cor0
----
2016
3325
7921

query I rowsort
SELECT + col1 - - 28 * - col2 FROM tab2 AS cor0
----
-1047
-669
-725

query I rowsort
SELECT ALL cor0.col2 * + 80 AS col1 FROM tab2 cor0
----
2080
2160
3040

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

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

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

query I rowsort
SELECT - - cor0.col2 * - ( 55 ) * + col0 AS col0 FROM tab0 cor0
----
-1925
-401390
-43560

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-340
SELECT DISTINCT cor0.col0 DIV 9 + - ( - col2 ) * + 60 AS col0 FROM tab0 AS cor0
----
1982
4929
63

skipif mysql # not compatible
query I rowsort label-340
SELECT DISTINCT cor0.col0 / 9 + - ( - col2 ) * + 60 AS col0 FROM tab0 AS cor0
----
1982
4929
63

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

query I rowsort
SELECT - - col0 * col2 * col2 + col2 * col1 AS col1 FROM tab0 AS cor0
----
132
28974
605898

query I rowsort
SELECT DISTINCT ( 71 ) FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-344
SELECT + col2 * CAST( col2 + + col1 * 12 AS SIGNED ) FROM tab2 AS cor0
----
10773
19084
9196

skipif mysql # not compatible
query I rowsort label-344
SELECT + col2 * CAST ( col2 + + col1 * 12 AS INTEGER ) FROM tab2 AS cor0
----
10773
19084
9196

query IIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 WHERE NOT NULL BETWEEN tab1.col1 AND NULL
----

query I rowsort
SELECT 45 AS col2 FROM tab1, tab1 AS cor0, tab2 cor1
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

query I rowsort
SELECT 99 * - cor0.col0 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 0efdcd7c477bd4fb6c16e7f8362ec86b

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

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

query I rowsort
SELECT - + col1 * 53 FROM tab2 AS cor0
----
-1643
-3127
-901

query I rowsort
SELECT - col2 * - 78 FROM tab1 AS cor0
----
4212
4446
7488

query I rowsort
SELECT ALL - ( 98 ) * + col0 AS col0 FROM tab0
----
-2352
-3430
-8722

onlyif mysql # use DIV operator for integer division
query I rowsort label-352
SELECT ALL + col1 * 22 DIV + col0 AS col0 FROM tab1
----
190
3
3

skipif mysql # not compatible
query I rowsort label-352
SELECT ALL + col1 * 22 / + col0 AS col0 FROM tab1
----
190
3
3

query I rowsort
SELECT ALL + cor0.col2 * 59 FROM tab2, tab0 AS cor0
----
9 values hashing to 030973826e326df3e93a125fc6619469

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

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

query I rowsort
SELECT - col1 + + col1 * - ( col2 ) + col0 AS col1 FROM tab0 AS cor0
----
-159
-2900
-7464

query I rowsort
SELECT - + col0 * col1 + 93 FROM tab0 cor0
----
-1971
-3302
-8006

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col0 * - ( + tab0.col2 ) * col2 col1 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT - col2 * col2 * + 4 + - col1 + col2 AS col2 FROM tab0 AS cor0
----
-100
-26905
-4409

query I rowsort
SELECT DISTINCT + 97 + col0 * 32 FROM tab2 AS cor0
----
2593
2625
321

query I rowsort
SELECT DISTINCT + 48 + + col2 + ( 58 ) * col0 FROM tab1 AS cor0
----
276
3817
4784

onlyif mysql # use DIV operator for integer division
query I rowsort label-362
SELECT DISTINCT 6 DIV + col2 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-362
SELECT DISTINCT 6 / + col2 FROM tab1
----
0

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

query I rowsort
SELECT ALL - ( - col2 ) + 9 + col1 FROM tab2
----
64
67
94

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

query I rowsort
SELECT ALL + 42 * + col1 AS col1 FROM tab0 AS cor0
----
3612
3822
4074

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 - - col0 col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT col0 + - col0 * - col1 - 90 AS col0 FROM tab1 AS cor0
----
-9
1030
614

onlyif mysql # use DIV operator for integer division
query I rowsort label-369
SELECT - col2 + 14 DIV col2 AS col2 FROM tab0 AS cor0
----
-33
-82
13

skipif mysql # not compatible
query I rowsort label-369
SELECT - col2 + 14 / col2 AS col2 FROM tab0 AS cor0
----
-33
-82
13

query I rowsort
SELECT + + cor0.col0 + - 6 FROM tab0 AS cor0
----
18
29
83

query I rowsort
SELECT DISTINCT col1 * + col2 + 22 FROM tab0 AS cor0
----
119
2860
7484

query I rowsort
SELECT col2 * - 82 AS col2 FROM tab1 AS cor0
----
-4428
-4674
-7872

query I rowsort
SELECT ALL col0 * + 62 AS col2 FROM tab1 cor0
----
186
3968
4960

query I rowsort
SELECT + col2 + 26 * cor0.col1 FROM tab1 AS cor0
----
317
434
730

query I rowsort
SELECT DISTINCT - col1 * + 26 FROM tab0 AS cor0
----
-2236
-2366
-2522

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

skipif mysql # not compatible
query I rowsort label-376
SELECT ALL - - col2 / - col1 AS col1 FROM tab0 AS cor0
----
0
0
0

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

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

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

query I rowsort
SELECT DISTINCT - 3 + + col2 AS col1 FROM tab0 AS cor0
----
-2
30
79

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

skipif mysql # not compatible
query I rowsort label-381
SELECT ALL col1 / col1 - cor0.col0 AS col2 FROM tab2 AS cor0
----
-6
-77
-78

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 63 * cor0.col0 - col0 col0 FROM tab1 AS cor0
----
186
3968
4960

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

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

query I rowsort
SELECT ALL 91 * ( + col1 ) + + ( + col2 ) + + cor0.col2 AS col2 FROM tab0 AS cor0
----
7892
8445
8829

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

query I rowsort
SELECT DISTINCT + ( + 92 ) - col1 * ( + col1 ) FROM tab1
----
-584
-77
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-389
SELECT DISTINCT ( + col1 ) DIV col0 - ( - col1 ) AS col2 FROM tab1
----
10
13
34

skipif mysql # not compatible
query I rowsort label-389
SELECT DISTINCT ( + col1 ) / col0 - ( - col1 ) AS col2 FROM tab1
----
10
13
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 5 * + col2 - col1 * + col2 col1 FROM tab1 cor0
----
-1674
-1728
-855

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

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

skipif mysql # not compatible
query I rowsort label-392
SELECT ALL - CAST ( NULL AS INTEGER ) AS col2 FROM tab2, tab0 cor0 CROSS JOIN tab1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query III rowsort
SELECT * FROM tab2 WHERE ( col2 * - col0 + + col1 / col0 ) > NULL
----

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

query I rowsort
SELECT col1 + col0 + + col2 FROM tab2
----
134
163
65

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

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

query I rowsort
SELECT ALL - col1 + + col2 + - col0 * col0 AS col0 FROM tab0
----
-1321
-629
-7930

query I rowsort
SELECT col1 * col0 + - col2 * col1 FROM tab1
----
-1326
-208
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * + tab1.col0 col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT col2 * col1 + - col0 + - col1 AS col1 FROM tab1
----
1155
1375
496

query I rowsort
SELECT DISTINCT + tab0.col0 * col2 + col0 + col2 * + col0 FROM tab0
----
105
14685
1608

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

query I rowsort
SELECT - col2 - - col2 * col2 * cor0.col1 AS col1 FROM tab1 AS cor0
----
119712
32433
75762

query I rowsort
SELECT DISTINCT + col1 * - col0 * col1 AS col1 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT DISTINCT - col0 - + col2 * - col1 * - col1 FROM tab2
----
-11061
-25954
-90584

query I rowsort
SELECT DISTINCT col1 FROM tab1 WHERE NOT NULL <= ( - col0 + col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col2 * col0 * - tab2.col1 col0 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT DISTINCT col2 + tab0.col1 * tab0.col2 * col2 AS col0 FROM tab0
----
611966
93687
98

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

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

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

query I rowsort
SELECT DISTINCT + col0 * col1 * tab0.col1 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT - col2 * + col2 + - col0 FROM tab2
----
-1523
-736
-754

onlyif mysql # use DIV operator for integer division
query I rowsort label-415
SELECT - col2 + - col2 DIV col1 AS col1 FROM tab2
----
-26
-27
-40

skipif mysql # not compatible
query I rowsort label-415
SELECT - col2 + - col2 / col1 AS col1 FROM tab2
----
-26
-27
-40

query I rowsort
SELECT ALL + col0 + + tab0.col2 + - col1 * - col2 FROM tab0
----
133
2895
7633

query I rowsort
SELECT ALL col1 * - col2 + - col2 + col1 FROM tab2
----
-1501
-667
-833

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

query I rowsort
SELECT tab2.col1 + + col1 AS col1 FROM tab2 WHERE NULL BETWEEN col1 AND NULL
----

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-422
SELECT DISTINCT + col0 * col1 + col0 * col0 DIV + col1 col2 FROM tab2 AS cor0
----
1710
218
4705

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-422
SELECT DISTINCT + col0 * col1 + col0 * col0 / + col1 col2 FROM tab2 AS cor0
----
1710
218
4705

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

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

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

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

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

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

query I rowsort
SELECT - col1 * + cor0.col2 FROM tab0 AS cor0 WHERE col2 / - col2 < NULL
----

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

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

query I rowsort
SELECT DISTINCT col2 * col0 * - col1 - + col1 * col0 AS col1 FROM tab2
----
-124254
-52377
-6076

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col0 * col0 col2 FROM tab1
----
-4032
-6
-6320

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

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

query I rowsort
SELECT ALL - col1 * - 3 + col2 FROM tab0 AS cor0
----
291
292
355

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

skipif mysql # not compatible
query I rowsort label-437
SELECT + col1 + - col1 / + col0 FROM tab2 AS cor0
----
17
27
59

query I rowsort
SELECT ALL + col2 * 73 AS col2 FROM tab1 AS cor0
----
3942
4161
7008

query I rowsort
SELECT col2 + - 97 AS col1 FROM tab2 cor0
----
-59
-70
-71

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

query I rowsort
SELECT + - cor0.col1 + 89 * - col0 * 80 AS col0 FROM tab2 AS cor0
----
-49871
-555419
-562497

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

query I rowsort
SELECT DISTINCT col0 * - ( 9 + col1 * + col2 ) AS col2 FROM tab0
----
-3710
-664919
-68328

query I rowsort
SELECT - 63 AS col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to fc0b533c2773a0a802e1fc8317dcebf2

onlyif mysql # use DIV operator for integer division
query I rowsort label-445
SELECT col0 DIV - tab1.col1 + col0 + + col2 AS col1 FROM tab1
----
115
170
57

skipif mysql # not compatible
query I rowsort label-445
SELECT col0 / - tab1.col1 + col0 + + col2 AS col1 FROM tab1
----
115
170
57

query I rowsort
SELECT - + 72 * col1 + + col1 FROM tab2 AS cor0
----
-1207
-2201
-4189

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

query I rowsort
SELECT DISTINCT tab0.col1 * col1 * col0 + - tab0.col0 FROM tab0
----
177480
329280
736920

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT + 44 + + tab1.col1 AS col2 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
54
57
70

query I rowsort
SELECT 13 + + col1 * 82 * + ( col2 ) AS col2 FROM tab1
----
102349
115141
46753

query I rowsort
SELECT + ( + col1 ) * - 86 FROM tab2 AS cor0
----
-1462
-2666
-5074

query I rowsort
SELECT DISTINCT + 18 * + col2 AS col1 FROM tab0 AS cor0
----
1476
18
594

query I rowsort
SELECT ALL 15 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to 71dda9a71fc978ea7b0ac5d8cd2ef1f0

query I rowsort
SELECT ALL - 15 + - col1 FROM tab2 AS cor0
----
-32
-46
-74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 15 + + cor0.col1 * + 49 col2 FROM tab2 AS cor0
----
1504
2876
818

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * 46 col2 FROM tab2
----
322
3588
3634

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 44 col2 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 0cc3e52e781e46962291c3060c6ae73b

query I rowsort
SELECT - 45 * - ( col0 * + 79 ) AS col0 FROM tab2
----
24885
277290
280845

query I rowsort
SELECT ALL + ( - col0 + + col0 * col1 ) AS col2 FROM tab0
----
2040
3360
8010

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

query I rowsort
SELECT ALL + 35 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

onlyif mysql # use DIV operator for integer division
query I rowsort label-470
SELECT ALL + col2 + - 94 DIV - tab0.col0 FROM tab0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-470
SELECT ALL + col2 + - 94 / - tab0.col0 FROM tab0
----
3
36
83

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

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

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

query I rowsort
SELECT DISTINCT - 88 * - col2 * - 93 FROM tab0
----
-270072
-671088
-8184

query I rowsort
SELECT ( + 74 ) FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to dc22979e6d261795bd3ce2990fdbbf82

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

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

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

query I rowsort
SELECT 42 * col1 AS col0 FROM tab0
----
3612
3822
4074

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

query I rowsort
SELECT DISTINCT col1 * col2 + 13 * - ( + tab0.col0 ) + + 86 * - col2 FROM tab0
----
-312
-444
-747

query I rowsort
SELECT + - 29 FROM tab0 cor0
----
-29
-29
-29

query I rowsort
SELECT - - col1 - - ( col2 * + col2 ) AS col0 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT + col2 * - col2 + - 55 * - col2 FROM tab2 AS cor0
----
646
754
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-484
SELECT + col0 * ( col0 ) + cor0.col2 * 45 DIV col1 AS col1 FROM tab1 AS cor0
----
102
4352
6732

skipif mysql # not compatible
query I rowsort label-484
SELECT + col0 * ( col0 ) + cor0.col2 * 45 / col1 AS col1 FROM tab1 AS cor0
----
102
4352
6732

onlyif mysql # use DIV operator for integer division
query I rowsort label-485
SELECT col0 + ( + col2 ) DIV + col1 col1 FROM tab1 AS cor0
----
5
69
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-485
SELECT col0 + ( + col2 ) / + col1 col1 FROM tab1 AS cor0
----
5
69
87

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + col1 + - 59 * col2 col0 FROM tab0
----
-1894
-4829
37

query I rowsort
SELECT ALL - col0 + - col0 - + col1 * col2 AS col0 FROM tab2
----
-1690
-804
-851

query I rowsort
SELECT ALL col2 + col2 * col1 - col0 AS col2 FROM tab0
----
2847
63
7455

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * 15 * col0 - col1 * + 54 col2 FROM tab1
----
-115902
-3834
-55260

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

query I rowsort
SELECT - - col1 * 1 + col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + col2 + ( - 73 + cor0.col2 ) * 72 AS col1 FROM tab0 AS cor0
----
-2847
-5183
730

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - ( 47 ) * - col2 col2 FROM tab0 AS cor0
----
-1551
-3854
-47

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col1 + col0 col1 FROM tab0 AS cor0
----
7420
8370
9444

onlyif mysql # use DIV operator for integer division
query I rowsort label-498
SELECT col2 * - cor0.col1 + + cor0.col0 + col2 DIV col2 AS col0 FROM tab0 AS cor0
----
-2813
-61
-7372

skipif mysql # not compatible
query I rowsort label-498
SELECT col2 * - cor0.col1 + + cor0.col0 + col2 / col2 AS col0 FROM tab0 AS cor0
----
-2813
-61
-7372

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

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

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

query I rowsort
SELECT DISTINCT + + ( + col2 ) + col2 * 85 AS col1 FROM tab1 AS cor0
----
4644
4902
8256

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

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

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

query I rowsort
SELECT + + 33 + 91 AS col1 FROM tab2 AS cor0
----
124
124
124

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

query I rowsort
SELECT ALL - col0 * + 11 + + cor0.col2 FROM tab2 AS cor0
----
-50
-831
-832

query I rowsort
SELECT 61 + col1 * - cor0.col2 * - col2 FROM tab2 AS cor0
----
22660
24609
39945

query I rowsort
SELECT + 10 * col1 * col0 + + col2 FROM tab2 AS cor0
----
13468
2197
46046

query I rowsort
SELECT DISTINCT col0 + col1 * col2 + col0 * + cor0.col2 FROM tab2 AS cor0
----
1033
3640
3727

query I rowsort
SELECT DISTINCT - 39 + col1 FROM tab2 AS cor0
----
-22
-8
20

query I rowsort
SELECT + + 88 + + cor0.col2 AS col1 FROM tab0 cor0
----
121
170
89

query I rowsort
SELECT ALL col2 * col1 + cor0.col1 - col1 * col2 * cor0.col2 AS col2 FROM tab0 AS cor0
----
-604331
-90730
97

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-515
SELECT DISTINCT - col0 + + col0 DIV + 46 + - cor0.col2 FROM tab2 AS cor0
----
-103
-116
-34

skipif mysql # not compatible
query I rowsort label-515
SELECT DISTINCT - col0 + + col0 / + 46 + - cor0.col2 FROM tab2 AS cor0
----
-103
-116
-34

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

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

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

query I rowsort
SELECT + 1 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT ALL - 91 * + col0 + + cor0.col2 AS col0 FROM tab1 AS cor0
----
-219
-5767
-7184

query I rowsort
SELECT + - col1 - col1 * + 15 FROM tab1 cor0
----
-160
-208
-416

query I rowsort
SELECT DISTINCT 30 + col0 - col0 AS col0 FROM tab1 cor0
----
30

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

query I rowsort
SELECT ALL - col1 * 22 FROM tab1
----
-220
-286
-572

onlyif mysql # use DIV operator for integer division
query I rowsort label-524
SELECT 89 + - col0 + + col1 DIV col0 FROM tab1
----
25
9
94

skipif mysql # not compatible
query I rowsort label-524
SELECT 89 + - col0 + + col1 / col0 FROM tab1
----
25
9
94

query I rowsort
SELECT DISTINCT - col2 + - col2 * - 15 AS col1 FROM tab2 AS cor0
----
364
378
532

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-527
SELECT - col1 * - col2 + 60 DIV - col0 AS col2 FROM tab1 AS cor0
----
1248
1384
570

skipif mysql # not compatible
query I rowsort label-527
SELECT - col1 * - col2 + 60 / - col0 AS col2 FROM tab1 AS cor0
----
1248
1384
570

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 + + col2 + 41 col1 FROM tab1 AS cor0
----
149
155
233

onlyif mysql # use DIV operator for integer division
query I rowsort label-530
SELECT - col0 + + col0 DIV cor0.col0 AS col1 FROM tab0 AS cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-530
SELECT - col0 + + col0 / cor0.col0 AS col1 FROM tab0 AS cor0
----
-23
-34
-88

onlyif mysql # use DIV operator for integer division
query I rowsort label-531
SELECT ALL + - 64 - col2 DIV col0 FROM tab0 AS cor0
----
-64
-64
-65

skipif mysql # not compatible
query I rowsort label-531
SELECT ALL + - 64 - col2 / col0 FROM tab0 AS cor0
----
-64
-64
-65

query I rowsort
SELECT DISTINCT 17 AS col1 FROM tab2 cor0
----
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-533
SELECT ALL - col1 + - col0 DIV - col0 FROM tab2 AS cor0
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-533
SELECT ALL - col1 + - col0 / - col0 FROM tab2 AS cor0
----
-16
-30
-58

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

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

query I rowsort
SELECT DISTINCT + 14 * col1 AS col2 FROM tab2 AS cor0
----
238
434
826

query I rowsort
SELECT - 54 - + col1 FROM tab1 AS cor0
----
-64
-67
-80

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

query I rowsort
SELECT DISTINCT 86 FROM tab1 AS cor0 CROSS JOIN tab2, tab1 AS cor1, tab1 AS cor2
----
86

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

query I rowsort
SELECT ALL - - col1 * - 73 AS col0 FROM tab0 AS cor0
----
-6278
-6643
-7081

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

query I rowsort
SELECT - cor0.col1 * - 83 FROM tab1 AS cor0
----
1079
2158
830

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

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

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

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

query I rowsort
SELECT ALL - 71 * + tab1.col2 FROM tab1, tab2 cor0
----
9 values hashing to 68d2de039a9324060ea47276d4b8723f

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

query I rowsort
SELECT DISTINCT + - ( 64 ) * col1 AS col2 FROM tab1 cor0
----
-1664
-640
-832

query I rowsort
SELECT ALL ( + 89 ) + + col0 * 42 FROM tab1 AS cor0
----
215
2777
3449

query I rowsort
SELECT - col0 * 44 * - col0 FROM tab1 AS cor0
----
180224
281600
396

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

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

query I rowsort
SELECT ALL - 39 + 55 FROM tab1 AS cor0
----
16
16
16

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

query I rowsort
SELECT ALL - col2 * - 40 FROM tab2 cor0
----
1040
1080
1520

query I rowsort
SELECT DISTINCT + ( + 23 ) FROM tab1 cor0
----
23

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

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

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

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

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

query I rowsort
SELECT + 67 + + cor0.col1 FROM tab0 cor0
----
153
158
164

query I rowsort
SELECT ALL - col0 + + cor0.col0 * col1 + - col1 * col1 AS col0 FROM tab2 AS cor0
----
-751
1043
975

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

query I rowsort
SELECT DISTINCT - 55 + - col2 FROM tab2 AS cor0
----
-81
-82
-93

query I rowsort
SELECT - 18 * cor0.col1 AS col0 FROM tab2 AS cor0
----
-1062
-306
-558

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 * 30 col0 FROM tab1, tab1 AS cor0
----
9 values hashing to b5f554ee515f23b41b7389be6a6ab3cb

query I rowsort
SELECT col2 * + 81 AS col1 FROM tab2 AS cor0
----
2106
2187
3078

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

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

query I rowsort
SELECT ALL 54 + col0 FROM tab0
----
143
78
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-573
SELECT 42 DIV cor0.col1 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-573
SELECT 42 / cor0.col1 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

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

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

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

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

query I rowsort
SELECT ALL + 77 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 051bf10c50e061d74ad0a4d205a1c622

query I rowsort
SELECT + 97 * + col1 AS col1 FROM tab0 AS cor0
----
8342
8827
9409

query I rowsort
SELECT DISTINCT - 49 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
-49

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-582
SELECT + - 93 * cor0.col0 + + CAST( col0 AS SIGNED ) * + col0 FROM tab1 AS cor0
----
-1040
-1856
-270

skipif mysql # not compatible
query I rowsort label-582
SELECT + - 93 * cor0.col0 + + CAST ( col0 AS INTEGER ) * + col0 FROM tab1 AS cor0
----
-1040
-1856
-270

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

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col1 + col1 * + CAST ( + 96 AS REAL ) AS col1 FROM tab1 AS cor0
----
1261
2522
970

query I rowsort
SELECT + 2 * cor0.col1 - - ( col0 ) FROM tab2 AS cor0
----
113
196
69

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-587
SELECT + + 81 + + col0 DIV 99 AS col1 FROM tab2 AS cor0
----
81
81
81

skipif mysql # not compatible
query I rowsort label-587
SELECT + + 81 + + col0 / 99 AS col1 FROM tab2 AS cor0
----
81
81
81

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * 40 col0 FROM tab1 AS cor0
----
-120
-2560
-3200

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 80 + cor0.col1 * + cor0.col0 col2 FROM tab1, tab0 AS cor0
----
2144
3475
8179

query I rowsort
SELECT DISTINCT + ( + col1 ) - - 37 AS col0 FROM tab2
----
54
68
96

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

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

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

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

query I rowsort
SELECT DISTINCT + 99 + - cor0.col2 FROM tab0 cor0
----
17
66
98

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

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

query I rowsort
SELECT 58 + - ( col2 ) AS col2 FROM tab1 cor0
----
-38
1
4

query I rowsort
SELECT ALL + - cor0.col1 + - cor0.col1 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 711cfaed69449ce6d49b98e40b1b4381

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col0 ) col1 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT ALL - - 43 * col1 AS col1 FROM tab0 AS cor0
----
3698
3913
4171

query I rowsort
SELECT ALL - 88 AS col0 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to eb8cbefa7d831e1a0183e919e2caef32

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

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

query I rowsort
SELECT DISTINCT tab2.col1 AS col1 FROM tab2, tab2 cor0, tab1 AS cor1
----
17
31
59

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

query I rowsort
SELECT DISTINCT + - col0 + col0 * 26 AS col2 FROM tab2 AS cor0
----
175
1950
1975

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-609
SELECT DISTINCT - 52 * col2 + CAST( - 82 AS SIGNED ) AS col0 FROM tab1 cor0
----
-2890
-3046
-5074

skipif mysql # not compatible
query I rowsort label-609
SELECT DISTINCT - 52 * col2 + CAST ( - 82 AS INTEGER ) AS col0 FROM tab1 cor0
----
-2890
-3046
-5074

query I rowsort
SELECT ALL + 70 * - col0 AS col2 FROM tab0 AS cor0
----
-1680
-2450
-6230

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

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

skipif mysql # not compatible
query I rowsort label-612
SELECT CAST ( NULL AS INTEGER ) * - 66 * - tab1.col2 + - ( 55 ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( - 40 * col1 ) AS col0 FROM tab2
----
1240
2360
680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 47 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

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

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

query I rowsort
SELECT + col0 * - col0 + ( col2 + + col2 ) FROM tab2
----
-6032
-6165
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-618
SELECT ALL col0 + - tab2.col1 - - CAST( - 34 + - col1 AS SIGNED ) AS col1 FROM tab2
----
-74
-89
11

skipif mysql # not compatible
query I rowsort label-618
SELECT ALL col0 + - tab2.col1 - - CAST ( - 34 + - col1 AS INTEGER ) AS col1 FROM tab2
----
-74
-89
11

query I rowsort
SELECT + col1 + col0 + + 13 AS col1 FROM tab0
----
123
145
193

onlyif mysql # use DIV operator for integer division
query I rowsort label-620
SELECT DISTINCT - col0 + + col0 DIV cor0.col1 FROM tab2 AS cor0
----
-7
-75
-77

skipif mysql # not compatible
query I rowsort label-620
SELECT DISTINCT - col0 + + col0 / cor0.col1 FROM tab2 AS cor0
----
-7
-75
-77

query I rowsort
SELECT DISTINCT + + 46 + col0 AS col2 FROM tab2 cor0
----
124
125
53

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

skipif mysql # not compatible
query I rowsort label-622
SELECT DISTINCT - + CAST ( NULL AS REAL ) AS col1 FROM tab0, tab0 AS cor0
----
NULL

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

query I rowsort
SELECT DISTINCT - col1 - - cor0.col0 * ( cor0.col1 ) * col0 FROM tab2 AS cor0
----
106080
1488
358897

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

query I rowsort
SELECT ALL + - 24 + col2 + + 64 FROM tab2 AS cor0
----
66
67
78

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

query I rowsort
SELECT DISTINCT + - ( col1 ) * 23 - - cor0.col1 FROM tab0 AS cor0
----
-1892
-2002
-2134

query I rowsort
SELECT + col0 * - 35 FROM tab1
----
-105
-2240
-2800

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * ( 44 ) col1 FROM tab1
----
132
2816
3520

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

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

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

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

query I rowsort
SELECT DISTINCT - 68 * 40 AS col0 FROM tab1 AS cor0
----
-2720

query I rowsort
SELECT DISTINCT + + 14 * 12 FROM tab1 AS cor0
----
168

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

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

query I rowsort
SELECT + cor0.col0 * + 55 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 6be1b8c1696f971d9450ab3d191e63e7

query I rowsort
SELECT 42 * cor0.col2 AS col2 FROM tab1 AS cor0
----
2268
2394
4032

query I rowsort
SELECT ALL cor0.col1 * - 25 FROM tab0 AS cor0
----
-2150
-2275
-2425

query I rowsort
SELECT ALL - 68 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 5febf382d36d6e0191889c41b928786f

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

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

query I rowsort
SELECT 21 * col0 + col1 AS col1 FROM tab1 AS cor0
----
1354
1693
89

query I rowsort
SELECT DISTINCT + + 41 * + col1 FROM tab2 AS cor0
----
1271
2419
697

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

query I rowsort
SELECT DISTINCT + + col1 * 87 + col2 FROM tab2 AS cor0
----
1517
2724
5159

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

skipif mysql # not compatible
query I rowsort label-648
SELECT ALL + col0 * + CAST ( + 69 AS INTEGER ) FROM tab1 AS cor0
----
207
4416
5520

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

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

query I rowsort
SELECT DISTINCT - col2 * 81 + cor0.col0 + + col0 AS col1 FROM tab0 cor0
----
-11
-2625
-6464

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

skipif mysql # not compatible
query I rowsort label-651
SELECT + col1 / + 38 AS col1 FROM tab1 AS cor0
----
0
0
0

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-656
SELECT - 87 + col1 DIV + col1 AS col1 FROM tab1 AS cor0
----
-86
-86
-86

skipif mysql # not compatible
query I rowsort label-656
SELECT - 87 + col1 / + col1 AS col1 FROM tab1 AS cor0
----
-86
-86
-86

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

query I rowsort
SELECT - 67 * - col2 FROM tab2 cor0
----
1742
1809
2546

query I rowsort
SELECT + - cor0.col0 AS col0 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

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

query I rowsort
SELECT - + 25 + cor0.col1 AS col0 FROM tab0 AS cor0
----
61
66
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-662
SELECT - col2 * cor0.col1 DIV + col1 + 65 FROM tab0 AS cor0
----
-17
32
64

skipif mysql # not compatible
query I rowsort label-662
SELECT - col2 * cor0.col1 / + col1 + 65 FROM tab0 AS cor0
----
-17
32
64

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

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

query I rowsort
SELECT ALL + + col0 + col2 + col2 * cor0.col0 AS col1 FROM tab1 AS cor0
----
219
3769
7856

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

query I rowsort
SELECT ALL + col0 * col2 * - 7 AS col0 FROM tab1 AS cor0
----
-1134
-25536
-53760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 95 * - tab2.col0 col1 FROM tab2, tab1 cor0
----
-665
-7410
-7505

query I rowsort
SELECT DISTINCT 2 + 31 FROM tab1
----
33

onlyif mysql # use DIV operator for integer division
query I rowsort label-669
SELECT - col2 * col0 DIV col1 + - 38 + + ( - col0 ) FROM tab0
----
-207
-71
-73

skipif mysql # not compatible
query I rowsort label-669
SELECT - col2 * col0 / col1 + - 38 + + ( - col0 ) FROM tab0
----
-207
-71
-73

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

query I rowsort
SELECT DISTINCT 12 + 99 FROM tab2, tab0, tab1 AS cor0
----
111

query I rowsort
SELECT - col2 + - col2 - + col2 AS col1 FROM tab2
----
-114
-78
-81

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

query I rowsort
SELECT ALL col0 + ( col0 ) FROM tab0
----
178
48
70

query I rowsort
SELECT ALL tab2.col2 * col0 + + tab2.col1 * + tab2.col2 FROM tab2
----
1026
3562
3648

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-677
SELECT DISTINCT + col0 DIV + 49 + col2 col0 FROM tab0
----
1
33
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-677
SELECT DISTINCT + col0 / + 49 + col2 col0 FROM tab0
----
1
33
83

query I rowsort
SELECT ( col1 ) + 16 * - tab1.col2 AS col0 FROM tab1
----
-1523
-838
-902

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

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

query I rowsort
SELECT DISTINCT + - 28 * + col1 - 46 * ( col2 ) FROM tab0 AS cor0
----
-2762
-3926
-6320

query I rowsort
SELECT ALL col0 * + col0 + cor0.col0 AS col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT + 82 * col1 AS col2 FROM tab1 AS cor0
----
1066
2132
820

query I rowsort
SELECT - cor1.col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

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

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

query I rowsort
SELECT 83 * col1 AS col0 FROM tab0
----
7138
7553
8051

query I rowsort
SELECT ALL 48 * + col0 FROM tab1
----
144
3072
3840

query I rowsort
SELECT + col1 + + 83 FROM tab2 AS cor0
----
100
114
142

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

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

query I rowsort
SELECT ALL + + col0 + + 95 + - col1 FROM tab2 AS cor0
----
114
157
71

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

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

query I rowsort
SELECT ALL + - ( cor0.col2 ) + + col2 * - 45 AS col2 FROM tab1 AS cor0
----
-2484
-2622
-4416

query I rowsort
SELECT 93 * cor0.col0 + - col2 FROM tab2 AS cor0
----
624
7228
7309

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

skipif mysql # not compatible
query I rowsort label-696
SELECT - col0 / + col2 AS col0 FROM tab0
----
-1
-35
0

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

skipif mysql # not compatible
query I rowsort label-697
SELECT ALL - - 18 + + col0 / col2 FROM tab1 AS cor0
----
18
18
19

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

skipif mysql # not compatible
query I rowsort label-698
SELECT - cor0.col2 / col2 AS col2 FROM tab0 AS cor0
----
-1
-1
-1

query I rowsort
SELECT - cor0.col1 + 71 FROM tab1 AS cor0
----
45
58
61

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-704
SELECT ALL + col2 DIV - col1 - ( ( + col0 ) * cor0.col1 ) AS col2 FROM tab2 AS cor0
----
-1345
-217
-4602

skipif mysql # not compatible
query I rowsort label-704
SELECT ALL + col2 / - col1 - ( ( + col0 ) * cor0.col1 ) AS col2 FROM tab2 AS cor0
----
-1345
-217
-4602

query I rowsort
SELECT ALL - col2 * + col0 - 49 * col1 AS col0 FROM tab1 AS cor0
----
-1436
-4138
-8317

query I rowsort
SELECT - - col1 * + cor0.col0 + - 12 * 1 FROM tab1 AS cor0
----
1028
628
66

query I rowsort
SELECT + 82 * cor0.col0 FROM tab0 AS cor0
----
1968
2870
7298

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 68 col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
68

query I rowsort
SELECT col1 * ( 85 ) AS col2 FROM tab2 cor0
----
1445
2635
5015

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

query I rowsort
SELECT + col1 * - 36 + col2 AS col0 FROM tab0 AS cor0
----
-3063
-3194
-3491

onlyif mysql # use DIV operator for integer division
query I rowsort label-713
SELECT + col2 * col2 - col0 DIV - cor0.col2 FROM tab1 AS cor0
----
2916
3250
9216

skipif mysql # not compatible
query I rowsort label-713
SELECT + col2 * col2 - col0 / - cor0.col2 FROM tab1 AS cor0
----
2916
3250
9216

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

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

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

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

query I rowsort
SELECT ALL 16 * + col1 FROM tab0 AS cor0
----
1376
1456
1552

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

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

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

query I rowsort
SELECT ALL 75 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

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

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

query I rowsort
SELECT DISTINCT - col0 + + col1 + col1 * tab2.col2 AS col0 FROM tab2
----
1515
584
861

onlyif mysql # use DIV operator for integer division
query I rowsort label-724
SELECT - + ( + cor0.col0 ) DIV + 11 FROM tab2 AS cor0
----
-7
-7
0

skipif mysql # not compatible
query I rowsort label-724
SELECT - + ( + cor0.col0 ) / + 11 FROM tab2 AS cor0
----
-7
-7
0

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

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

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

skipif mysql # not compatible
query I rowsort label-726
SELECT + cor0.col0 / ( 96 ) FROM tab1 AS cor0
----
0
0
0

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

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

query I rowsort
SELECT 69 * - col2 AS col1 FROM tab0
----
-2277
-5658
-69

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-730
SELECT DISTINCT - + col2 + col2 DIV - col0 FROM tab0 AS cor0
----
-1
-34
-82

skipif mysql # not compatible
query I rowsort label-730
SELECT DISTINCT - + col2 + col2 / - col0 FROM tab0 AS cor0
----
-1
-34
-82

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

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

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

query I rowsort
SELECT DISTINCT + + cor0.col2 * - col1 + + col2 * - col0 + cor0.col0 AS col0 FROM tab2 AS cor0
----
-1019
-3484
-3569

query I rowsort
SELECT DISTINCT - tab1.col2 + cor0.col0 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 433ab71ade4f9ca647cd1e5cae4a1a44

onlyif mysql # use DIV operator for integer division
query I rowsort label-736
SELECT DISTINCT + col1 DIV + col2 AS col2 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-736
SELECT DISTINCT + col1 / + col2 AS col2 FROM tab1
----
0

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-737
SELECT col2 / col2 + tab0.col0 col0 FROM tab0
----
25
36
90

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

query I rowsort
SELECT col0 + - col2 * col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT 17 * - col2 - col1 AS col0 FROM tab1 AS cor0
----
-1645
-944
-979

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-743
SELECT ALL - 46 * col1 + col2 DIV + col1 FROM tab1 AS cor0
----
-1194
-455
-591

skipif mysql # not compatible
query I rowsort label-743
SELECT ALL - 46 * col1 + col2 / + col1 FROM tab1 AS cor0
----
-1194
-455
-591

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col0 col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT col0 - - col0 * col2 * col2 AS col1 FROM tab2 AS cor0
----
114155
5110
52806

query I rowsort
SELECT ALL + cor0.col2 + - col2 * cor0.col2 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT ALL 70 - col1 FROM tab0
----
-16
-21
-27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 - + 95 col2 FROM tab0
----
-4
-9
2

query I rowsort
SELECT + col1 + + col0 * - tab1.col2 - - tab1.col2 FROM tab1
----
-3581
-7571
-82

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-751
SELECT - col2 DIV col1 + col2 FROM tab1
----
52
52
89

skipif mysql # not compatible
query I rowsort label-751
SELECT - col2 / col1 + col2 FROM tab1
----
52
52
89

query I rowsort
SELECT ALL + 89 AS col1 FROM tab2
----
89
89
89

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-754
SELECT ALL + col0 * col2 + + tab2.col1 - + col1 DIV col0 FROM tab2
----
2087
216
3019

skipif mysql # not compatible
query I rowsort label-754
SELECT ALL + col0 * col2 + + tab2.col1 - + col1 / col0 FROM tab2
----
2087
216
3019

query I rowsort
SELECT - ( col2 ) - + col2 * + col2 FROM tab0
----
-1122
-2
-6806

query I rowsort
SELECT ALL 57 * col1 - tab2.col0 AS col1 FROM tab2
----
1760
3285
890

query I rowsort
SELECT ALL 63 + col1 FROM tab2
----
122
80
94

query I rowsort
SELECT + 50 AS col0 FROM tab1
----
50
50
50

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-760
SELECT + + col2 DIV + cor0.col1 + col0 AS col1 FROM tab1 AS cor0
----
5
69
87

skipif mysql # not compatible
query I rowsort label-760
SELECT + + col2 / + cor0.col1 + col0 AS col1 FROM tab1 AS cor0
----
5
69
87

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-762
SELECT ALL + col0 DIV - col1 + col1 * col2 FROM tab1 AS cor0
----
1242
1404
564

skipif mysql # not compatible
query I rowsort label-762
SELECT ALL + col0 / - col1 + col1 * col2 FROM tab1 AS cor0
----
1242
1404
564

onlyif mysql # use DIV operator for integer division
query I rowsort label-763
SELECT 13 DIV col0 + cor0.col0 AS col0 FROM tab2 AS cor0
----
78
79
8

skipif mysql # not compatible
query I rowsort label-763
SELECT 13 / col0 + cor0.col0 AS col0 FROM tab2 AS cor0
----
78
79
8

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

query I rowsort
SELECT + 4 * - 73 AS col0 FROM tab0
----
-292
-292
-292

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

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

query I rowsort
SELECT ALL + 33 * - tab0.col2 FROM tab0
----
-1089
-2706
-33

query I rowsort
SELECT col0 + + 29 AS col2 FROM tab1
----
109
32
93

query I rowsort
SELECT DISTINCT - col0 + + 64 * col2 FROM tab0 cor0
----
2088
29
5159

query I rowsort
SELECT DISTINCT + 35 + col2 + col1 FROM tab1 AS cor0
----
102
115
144

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

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

query I rowsort
SELECT - 88 + + col1 AS col2 FROM tab1 AS cor0
----
-62
-75
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 59 + col2 col1 FROM tab1 AS cor0
----
113
116
155

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

skipif mysql # not compatible
query I rowsort label-776
SELECT DISTINCT - 87 / - col0 AS col1 FROM tab0
----
0
2
3

query I rowsort
SELECT col1 + col0 * + col0 * - col0 FROM tab1
----
-1
-262134
-511987

query I rowsort
SELECT ALL - 1 * col0 AS col0 FROM tab0
----
-24
-35
-89

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

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

query I rowsort
SELECT 11 * col2 AS col1 FROM tab0 AS cor0
----
11
363
902

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

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

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

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

query I rowsort
SELECT - - col0 + - col2 * 86 FROM tab0 AS cor0
----
-2814
-51
-6963

query I rowsort
SELECT ALL col0 * + col2 * + col2 + + col2 FROM tab0 AS cor0
----
26169
36
598518

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

query I rowsort
SELECT ALL col1 + cor0.col0 + + cor0.col0 FROM tab1 AS cor0
----
138
173
32

query I rowsort
SELECT DISTINCT - col2 * col1 + - col2 AS col2 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT + col2 - + 70 FROM tab2 AS cor0
----
-32
-43
-44

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

query I rowsort
SELECT + + col0 * ( 6 ) + col2 + 45 FROM tab1 AS cor0
----
117
486
621

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

query I rowsort
SELECT DISTINCT col0 + col0 - ( 74 ) FROM tab2
----
-60
82
84

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

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

query I rowsort
SELECT ALL - cor0.col2 * col2 + 24 FROM tab2 AS cor0
----
-1420
-652
-705

query I rowsort
SELECT DISTINCT col2 * - 59 + 39 AS col1 FROM tab2 AS cor0
----
-1495
-1554
-2203

query I rowsort
SELECT cor0.col1 + + col0 * + 32 AS col2 FROM tab0 AS cor0
----
1217
2939
854

query I rowsort
SELECT ALL cor0.col1 + ( - col1 ) * col2 * col2 FROM tab2 AS cor0
----
-22568
-24531
-39825

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

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

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

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

query I rowsort
SELECT + 66 + - 78 FROM tab0 AS cor0
----
-12
-12
-12

onlyif mysql # use DIV operator for integer division
query I rowsort label-803
SELECT ( - col0 ) DIV col1 + + col2 * + 61 FROM tab0 AS cor0
----
2013
5002
61

skipif mysql # not compatible
query I rowsort label-803
SELECT ( - col0 ) / col1 + + col2 * + 61 FROM tab0 AS cor0
----
2013
5002
61

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

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( 17 AS REAL ) * cor0.col1 * 83 + 76 * col1 FROM tab0 AS cor0
----
127882
135317
144239

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

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

query I rowsort
SELECT col1 * + col0 - col0 * - col1 FROM tab2 AS cor0
----
2686
434
9204

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

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

query I rowsort
SELECT ALL - col2 + - ( col1 * col2 + 29 * + col1 ) AS col2 FROM tab0
----
-10183
-2911
-5365

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

query I rowsort
SELECT DISTINCT col1 + - ( col1 ) FROM tab1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( 44 + col1 ) col1 FROM tab1
----
-54
-57
-70

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

query I rowsort
SELECT - 69 * col2 + + col0 FROM tab2 cor0
----
-1716
-1856
-2543

onlyif mysql # use DIV operator for integer division
query I rowsort label-816
SELECT - - ( 87 ) DIV col0 FROM tab2 AS cor0
----
1
1
12

skipif mysql # not compatible
query I rowsort label-816
SELECT - - ( 87 ) / col0 FROM tab2 AS cor0
----
1
1
12

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

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

query I rowsort
SELECT 26 * 76 AS col0 FROM tab2
----
1976
1976
1976

query I rowsort
SELECT + 78 + col1 FROM tab2 AS cor0
----
109
137
95

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

query I rowsort
SELECT ALL + col1 + - cor0.col2 * ( + col0 + col1 * cor0.col0 ) FROM tab1 AS cor0
----
-107507
-40118
-4348

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

query I rowsort
SELECT DISTINCT - - 64 - - col0 AS col0 FROM tab2 AS cor0
----
142
143
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-824
SELECT ALL + - col2 * 33 DIV 39 - col0 AS col2 FROM tab1 cor0
----
-112
-161
-48

skipif mysql # not compatible
query I rowsort label-824
SELECT ALL + - col2 * 33 / 39 - col0 AS col2 FROM tab1 cor0
----
-112
-161
-48

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

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

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

query I rowsort
SELECT - 39 FROM tab2, tab1 AS cor0
----
9 values hashing to 504d14939d58aeb4a14f31c80de5b53e

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-831
SELECT DISTINCT + col0 + 58 DIV - col2 + col0 * 10 col0 FROM tab0 AS cor0
----
263
327
979

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-831
SELECT DISTINCT + col0 + 58 / - col2 + col0 * 10 col0 FROM tab0 AS cor0
----
263
327
979

query I rowsort
SELECT DISTINCT - cor0.col1 + + col0 * + 23 FROM tab1 AS cor0
----
1462
1827
43

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col1 col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT + cor0.col2 * + ( - 17 ) + col0 AS col2 FROM tab0 AS cor0
----
-1305
-537
18

query I rowsort
SELECT ALL + col1 * ( - col1 ) + - col1 FROM tab2 AS cor0
----
-306
-3540
-992

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

query I rowsort
SELECT ALL - + col1 + 97 AS col2 FROM tab1 AS cor0
----
71
84
87

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

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

query I rowsort
SELECT DISTINCT col0 * 2 FROM tab1 AS cor0
----
128
160
6

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

query I rowsort
SELECT 19 - + col1 * - col0 FROM tab2
----
1362
236
4621

query I rowsort
SELECT col2 * col1 + + 82 FROM tab0
----
179
2920
7544

query I rowsort
SELECT DISTINCT + 6 + col0 AS col0 FROM tab1
----
70
86
9

query I rowsort
SELECT - col0 + 80 AS col1 FROM tab0
----
-9
45
56

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

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

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

query I rowsort
SELECT + - 71 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-851
SELECT - 33 DIV col0 FROM tab1 AS cor0
----
-11
0
0

skipif mysql # not compatible
query I rowsort label-851
SELECT - 33 / col0 FROM tab1 AS cor0
----
-11
0
0

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col1 + ( - 48 ) * col2 col2 FROM tab0 AS cor0
----
-11398
-145
-4422

query I rowsort
SELECT DISTINCT + col2 + + tab1.col2 * 61 FROM tab1
----
3348
3534
5952

query I rowsort
SELECT - 54 + col2 AS col2 FROM tab0
----
-21
-53
28

query I rowsort
SELECT cor0.col2 * col2 + + col0 FROM tab2 cor0
----
1523
736
754

query I rowsort
SELECT - 94 * col2 AS col0 FROM tab1 AS cor0
----
-5076
-5358
-9024

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

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

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

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

skipif mysql # not compatible
query I rowsort label-861
SELECT DISTINCT + + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
NULL

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

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

query I rowsort
SELECT DISTINCT - + 5 * col1 FROM tab0 AS cor0
----
-430
-455
-485

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

skipif mysql # not compatible
query I rowsort label-865
SELECT DISTINCT 36 * + col0 / - col0 AS col2 FROM tab1 AS cor0
----
-36

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col1 * - 82 - - col1 col0 FROM tab1 AS cor0
----
-13845
-55406
-8190

query I rowsort
SELECT ALL - col2 + + cor0.col2 * 22 * - 53 FROM tab2 AS cor0
----
-30342
-31509
-44346

query I rowsort
SELECT - - col0 * cor0.col2 + ( col2 ) * col1 + col0 * - col0 FROM tab1 cor0
----
122
1557
2528

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

query I rowsort
SELECT DISTINCT + 35 * col0 FROM tab1 AS cor0
----
105
2240
2800

query I rowsort
SELECT ALL 86 * col0 AS col1 FROM tab1 AS cor0
----
258
5504
6880

query I rowsort
SELECT 86 + - col1 * + col1 * col0 + - col2 AS col0 FROM tab0 AS cor0
----
-177451
-329230
-737005

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

query I rowsort
SELECT ALL - + col0 * 69 FROM tab0 AS cor0
----
-1656
-2415
-6141

query I rowsort
SELECT DISTINCT col2 * 26 AS col0 FROM tab1 AS cor0
----
1404
1482
2496

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

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

query I rowsort
SELECT + tab0.col0 * col0 * + 22 FROM tab0
----
12672
174262
26950

query I rowsort
SELECT ALL col2 * col0 + 58 * col0 AS col0 FROM tab2
----
595
6552
7584

query I rowsort
SELECT ALL 88 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

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

query I rowsort
SELECT + cor0.col1 * 70 AS col1 FROM tab1 AS cor0
----
1820
700
910

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

query I rowsort
SELECT DISTINCT + cor0.col2 + 15 * + col0 * + 25 FROM tab2 AS cor0
----
2652
29276
29663

query I rowsort
SELECT - + col1 * 5 FROM tab1 AS cor0
----
-130
-50
-65

query I rowsort
SELECT DISTINCT - - 38 * col1 AS col0 FROM tab1 AS cor0
----
380
494
988

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

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

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

query I rowsort
SELECT ALL - - 8 * - col1 + + cor0.col0 FROM tab1 AS cor0
----
-16
-205
-24

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

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

skipif mysql # not compatible
query I rowsort label-892
SELECT DISTINCT - ( + col1 ) + - col2 * CAST ( - 82 AS INTEGER ) FROM tab2 AS cor0
----
2073
2183
3099

query I rowsort
SELECT ALL col0 * + col1 + col1 * 7 + col1 * col2 AS col2 FROM tab0 cor0
----
16198
4171
5504

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

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

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

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

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

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

query I rowsort
SELECT col2 + col0 * ( - 43 + + col2 ) AS col0 FROM tab1 AS cor0
----
4336
87
953

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( 31 AS REAL ) - - tab1.col1 AS col2 FROM tab1
----
41
44
57

query I rowsort
SELECT + ( + tab0.col0 ) * + col1 * - 67 - 98 AS col1 FROM tab0
----
-138386
-227563
-542731

query I rowsort
SELECT ALL col2 - ( tab2.col0 + col0 ) * + col0 FROM tab2
----
-12142
-12444
-71

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-903
SELECT DISTINCT + CAST( + col2 AS SIGNED ) + - col1 FROM tab1
----
28
47
83

skipif mysql # not compatible
query I rowsort label-903
SELECT DISTINCT + CAST ( + col2 AS INTEGER ) + - col1 FROM tab1
----
28
47
83

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

skipif mysql # not compatible
query I rowsort label-904
SELECT ALL - CAST ( NULL AS INTEGER ) + + 59 - - col1 / col0 FROM tab1
----
NULL
NULL
NULL

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

query I rowsort
SELECT + 83 * - cor0.col2 FROM tab0 AS cor0
----
-2739
-6806
-83

query I rowsort
SELECT ALL + - cor0.col0 AS col1 FROM tab1, tab1 cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT DISTINCT + tab0.col2 * - 39 AS col0 FROM tab0
----
-1287
-3198
-39

query I rowsort
SELECT - 79 FROM tab1, tab0 AS cor0
----
9 values hashing to 1b7b0b34fe3431fb409719624d12791f

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-910
SELECT + CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-910
SELECT + CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT ALL 32 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to d30a2acbf33c88274474306936d3227b

query I rowsort
SELECT + ( + col0 ) * + tab0.col1 + col0 + col0 FROM tab0
----
2112
3465
8277

query I rowsort
SELECT + + ( 20 ) + tab0.col0 * 85 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 3104fc44fd89f4801506436f8e0215f8

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

query I rowsort
SELECT DISTINCT - 77 * col2 FROM tab0 AS cor0
----
-2541
-6314
-77

query I rowsort
SELECT DISTINCT - - col2 - + 80 FROM tab1 AS cor0
----
-23
-26
16

query I rowsort
SELECT DISTINCT - 44 * - col2 FROM tab1 AS cor0
----
2376
2508
4224

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

query I rowsort
SELECT - + 65 * col0 * + col2 FROM tab2 AS cor0
----
-12285
-131820
-195130

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

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

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

skipif mysql # not compatible
query I rowsort label-922
SELECT DISTINCT + - col2 * CAST ( col0 AS INTEGER ) + + col0 - col1 AS col1 FROM tab2 AS cor0
----
-2009
-213
-2940

onlyif mysql # use DIV operator for integer division
query I rowsort label-923
SELECT ALL - col0 * CAST( - col0 AS SIGNED ) DIV col1 AS col0 FROM tab1 AS cor0
----
0
409
492

skipif mysql # not compatible
query I rowsort label-923
SELECT ALL - col0 * CAST ( - col0 AS INTEGER ) / col1 AS col0 FROM tab1 AS cor0
----
0
409
492

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

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

query I rowsort
SELECT DISTINCT + + col1 * - col0 * col0 + col0 * col0 FROM tab0 AS cor0
----
-117600
-48960
-712890

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

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

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

skipif mysql # not compatible
query I rowsort label-928
SELECT ALL + - col1 + + CAST ( + 68 AS INTEGER ) + col0 FROM tab0 AS cor0
----
6
6
66

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

query I rowsort
SELECT ALL - col0 * - 18 + - col0 AS col1 FROM tab2 AS cor0
----
119
1326
1343

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + 69 col1 FROM tab2 AS cor0
----
107
95
96

query I rowsort
SELECT DISTINCT - col2 + - ( + col2 + - col1 ) AS col1 FROM tab0 AS cor0
----
-73
20
95

query I rowsort
SELECT + col1 * - ( - 62 ) FROM tab0 AS cor0
----
5332
5642
6014

query I rowsort
SELECT ALL - 95 * col1 FROM tab2
----
-1615
-2945
-5605

query I rowsort
SELECT - 54 AS col1 FROM tab1, tab0, tab0 AS cor0, tab2
----
81 values hashing to 440ee4bea4c39df49899f4a4d88059fe

query I rowsort
SELECT ALL - 86 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 9d2e1e8eda15b3b83dd7136dfc4f19af

query I rowsort
SELECT + ( + 45 ) AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

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

query I rowsort
SELECT + col1 + - col1 * col1 * 17 AS col0 FROM tab1 AS cor0
----
-11466
-1690
-2860

onlyif mysql # use DIV operator for integer division
query I rowsort label-940
SELECT 4 + col0 * col0 DIV - ( 20 ) AS col2 FROM tab2 AS cor0
----
-300
-308
2

skipif mysql # not compatible
query I rowsort label-940
SELECT 4 + col0 * col0 / - ( 20 ) AS col2 FROM tab2 AS cor0
----
-300
-308
2

query I rowsort
SELECT ( col0 ) - col0 * 17 FROM tab2 AS cor0
----
-112
-1248
-1264

query I rowsort
SELECT ALL col2 + + 40 FROM tab0 cor0
----
122
41
73

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

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

query I rowsort
SELECT - 50 - + cor0.col0 * col1 AS col2 FROM tab0 AS cor0
----
-2114
-3445
-8149

query I rowsort
SELECT DISTINCT 62 AS col2 FROM tab0, tab2 cor0
----
62

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

query I rowsort
SELECT col0 * cor0.col0 - - col2 * col2 FROM tab2 AS cor0
----
6760
7685
778

query I rowsort
SELECT DISTINCT + col0 + + 16 FROM tab0
----
105
40
51

query I rowsort
SELECT DISTINCT col0 * ( col0 * + tab1.col2 ) + 96 + col1 FROM tab1
----
233578
608
614509

onlyif mysql # use DIV operator for integer division
query I rowsort label-950
SELECT + col1 DIV + 86 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-950
SELECT + col1 / + 86 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-951
SELECT + 36 DIV col1 FROM tab1 cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-951
SELECT + 36 / col1 FROM tab1 cor0
----
1
2
3

query I rowsort
SELECT - 86 + + col0 FROM tab0 AS cor0
----
-51
-62
3

query I rowsort
SELECT 15 + + tab0.col0 AS col1 FROM tab0
----
104
39
50

onlyif mysql # use DIV operator for integer division
query I rowsort label-954
SELECT col1 * 41 DIV col0 FROM tab0 AS cor0
----
113
146
41

skipif mysql # not compatible
query I rowsort label-954
SELECT col1 * 41 / col0 FROM tab0 AS cor0
----
113
146
41

query I rowsort
SELECT DISTINCT - - col1 * + col2 * 34 - 43 AS col0 FROM tab1 AS cor0
----
19337
42389
47693

query I rowsort
SELECT DISTINCT + col2 * cor0.col2 + + 31 AS col0 FROM tab1 AS cor0
----
2947
3280
9247

query I rowsort
SELECT - cor1.col1 * 62 FROM tab1, tab2 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to 58f8ce00a025779cccb0dda0ece1bf1d

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-959
SELECT - + col1 + col0 DIV col0 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-959
SELECT - + col1 + col0 / col0 FROM tab0 AS cor0
----
-85
-90
-96

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-962
SELECT DISTINCT + ( + ( cor0.col0 ) ) DIV + ( 15 ) FROM tab1 AS cor0
----
0
4
5

skipif mysql # not compatible
query I rowsort label-962
SELECT DISTINCT + ( + ( cor0.col0 ) ) / + ( 15 ) FROM tab1 AS cor0
----
0
4
5

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

query I rowsort
SELECT 34 * col0 + col2 FROM tab0 AS cor0
----
1191
3108
849

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-968
SELECT ALL col2 * col0 DIV + col0 + col1 FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-968
SELECT ALL col2 * col0 / + col0 + col1 FROM tab1 AS cor0
----
109
67
80

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

query I rowsort
SELECT + 67 + col1 AS col2 FROM tab1 AS cor0
----
77
80
93

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

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

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

query I rowsort
SELECT 50 * + col2 + col0 * cor0.col1 AS col2 FROM tab2 AS cor0
----
1567
3243
5902

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

query I rowsort
SELECT ALL 74 * - col0 + tab0.col0 FROM tab0
----
-1752
-2555
-6497

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

query I rowsort
SELECT DISTINCT - col2 + 30 * + 0 + col0 FROM tab0 cor0
----
-9
34
7

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

query I rowsort
SELECT DISTINCT + ( col1 * 9 ) FROM tab0
----
774
819
873

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

query I rowsort
SELECT ALL - 4 FROM tab2, tab0 AS cor0
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

query I rowsort
SELECT col0 * 19 * - cor0.col0 - col1 AS col1 FROM tab0 AS cor0
----
-11030
-150590
-23372

onlyif mysql # use DIV operator for integer division
query I rowsort label-983
SELECT + col1 * - col0 - col2 DIV cor0.col1 AS col0 FROM tab2 AS cor0
----
-1345
-217
-4602

skipif mysql # not compatible
query I rowsort label-983
SELECT + col1 * - col0 - col2 / cor0.col1 AS col0 FROM tab2 AS cor0
----
-1345
-217
-4602

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

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

query I rowsort
SELECT + col0 * - ( col0 * col0 ) FROM tab2 cor0
----
-343
-474552
-493039

query I rowsort
SELECT - ( - 57 ) AS col0 FROM tab1 AS cor0
----
57
57
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-987
SELECT ALL + - col2 DIV col0 - + cor0.col1 * + col2 AS col1 FROM tab2 AS cor0
----
-1534
-646
-840

skipif mysql # not compatible
query I rowsort label-987
SELECT ALL + - col2 / col0 - + cor0.col1 * + col2 AS col1 FROM tab2 AS cor0
----
-1534
-646
-840

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

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

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

query I rowsort
SELECT DISTINCT - + col1 + - 4 FROM tab0 AS cor0
----
-101
-90
-95

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

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

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

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

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

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

query I rowsort
SELECT DISTINCT 50 + ( tab1.col0 + 67 ) * + ( + col1 ) FROM tab1
----
1360
1870
1961

query I rowsort
SELECT col2 + 92 FROM tab0
----
125
174
93

query I rowsort
SELECT col0 + 27 + + col1 * 42 FROM tab2
----
1336
2583
820

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 col0 FROM tab1, tab1 AS cor0, tab1 AS cor1, tab1 AS cor2
----
81 values hashing to 96e9ef2950805bca93a295eeea43ef5b

query I rowsort
SELECT 17 - + col0 AS col2 FROM tab2 AS cor0
----
-61
-62
10

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

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

query I rowsort
SELECT DISTINCT 41 * col1 AS col1 FROM tab1
----
1066
410
533

query I rowsort
SELECT ALL + col0 + col1 * + 16 AS col1 FROM tab0 AS cor0
----
1400
1545
1587

query I rowsort
SELECT ALL - - col1 + + col0 * + col2 * 77 FROM tab2 cor0
----
14584
156215
231171

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

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

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

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

query I rowsort
SELECT DISTINCT col0 * - col1 * col1 FROM tab1 AS cor0
----
-13520
-2028
-6400

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1011
SELECT ALL + + col0 + ( col2 ) * col0 DIV + col1 col2 FROM tab2 AS cor0
----
112
13
255

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1011
SELECT ALL + + col0 + ( col2 ) * col0 / + col1 col2 FROM tab2 AS cor0
----
112
13
255

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

skipif mysql # not compatible
query I rowsort label-1012
SELECT + - col2 * ( - cor0.col1 + - col0 * - CAST ( - col1 AS INTEGER ) ) AS col1 FROM tab2 AS cor0
----
121186
51680
6696

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

skipif mysql # not compatible
query I rowsort label-1013
SELECT ALL + col1 / - col2 AS col0 FROM tab1
----
0
0
0

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

query I rowsort
SELECT + 75 + tab1.col1 FROM tab1
----
101
85
88

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

query I rowsort
SELECT - 4 * col0 + ( ( col0 ) ) + col0 * col0 AS col1 FROM tab0 AS cor0
----
1120
504
7654

query I rowsort
SELECT ALL + + 98 * col0 FROM tab0 AS cor0
----
2352
3430
8722

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor1.col2 * cor0.col1 col2 FROM tab2, tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1
----
9 values hashing to 2dce99ccc9ab3f12533423eaad01995c

onlyif mysql # use DIV operator for integer division
query I rowsort label-1020
SELECT 97 DIV tab2.col0 + - col0 FROM tab2
----
-77
-78
6

skipif mysql # not compatible
query I rowsort label-1020
SELECT 97 / tab2.col0 + - col0 FROM tab2
----
-77
-78
6

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

query I rowsort
SELECT DISTINCT - 72 + - col0 + - tab0.col2 AS col0 FROM tab0
----
-108
-129
-243

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - col2 + - col2 + col0 col2 FROM tab1 AS cor0
----
2865
3256
9200

query I rowsort
SELECT 55 - col2 FROM tab0 AS cor0
----
-27
22
54

query I rowsort
SELECT ALL 12 AS col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 702478c53caf2f7ebb9fff96d800f5a6

onlyif mysql # use DIV operator for integer division
query I rowsort label-1026
SELECT DISTINCT + 96 + - col1 DIV + col1 FROM tab0 AS cor0
----
95

skipif mysql # not compatible
query I rowsort label-1026
SELECT DISTINCT + 96 + - col1 / + col1 FROM tab0 AS cor0
----
95

query I rowsort
SELECT 15 * tab1.col1 FROM tab1
----
150
195
390

query I rowsort
SELECT + col0 + + 69 * - 90 FROM tab1
----
-6130
-6146
-6207

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

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

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

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

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

query I rowsort
SELECT DISTINCT 73 + + 22 - cor0.col0 AS col2 FROM tab0 AS cor0
----
6
60
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-1035
SELECT DISTINCT + + cor0.col1 + + col0 * - col1 DIV cor0.col1 FROM tab0 AS cor0
----
2
62

skipif mysql # not compatible
query I rowsort label-1035
SELECT DISTINCT + + cor0.col1 + + col0 * - col1 / cor0.col1 FROM tab0 AS cor0
----
2
62

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

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

query I rowsort
SELECT ALL - + 93 * + 11 FROM tab0 cor0
----
-1023
-1023
-1023

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

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1041
SELECT DISTINCT 60 - + col0 * col0 * - CAST( - 67 * - col2 AS SIGNED ) FROM tab0 AS cor0
----
1273596
43518034
82135

skipif mysql # not compatible
query I rowsort label-1041
SELECT DISTINCT 60 - + col0 * col0 * - CAST ( - 67 * - col2 AS INTEGER ) FROM tab0 AS cor0
----
1273596
43518034
82135

query I rowsort
SELECT DISTINCT - + col2 + - 44 AS col1 FROM tab2 AS cor0
----
-70
-71
-82

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

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

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

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

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

query I rowsort
SELECT + - 95 * + col0 AS col2 FROM tab1 AS cor0
----
-285
-6080
-7600

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

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

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

query I rowsort
SELECT DISTINCT + col2 + 99 AS col2 FROM tab0 cor0
----
100
132
181

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

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

query I rowsort
SELECT col2 * + 23 FROM tab1 AS cor0
----
1242
1311
2208

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 + - col2 * - col2 col2 FROM tab0 AS cor0
----
1122
2
6806

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

query I rowsort
SELECT - + 69 + ( - col0 ) AS col1 FROM tab1 AS cor0
----
-133
-149
-72

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

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

skipif mysql # not compatible
query I rowsort label-1058
SELECT ALL CAST ( NULL AS REAL ) AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-1059
SELECT ALL col0 DIV tab0.col2 - - col1 AS col2 FROM tab0
----
132
86
92

skipif mysql # not compatible
query I rowsort label-1059
SELECT ALL col0 / tab0.col2 - - col1 AS col2 FROM tab0
----
132
86
92

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

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

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

query I rowsort
SELECT + 13 * + col0 FROM tab2 AS cor0
----
1014
1027
91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 81 * col2 + - col1 col1 FROM tab2 AS cor0
----
2047
2156
3061

query I rowsort
SELECT ALL + col1 * - 41 AS col0 FROM tab2 cor0
----
-1271
-2419
-697

query I rowsort
SELECT DISTINCT col0 * + 54 * col2 + + col2 AS col1 FROM tab0 AS cor0
----
1891
394174
42801

query I rowsort
SELECT DISTINCT col1 + 61 * col0 AS col2 FROM tab0 AS cor0
----
1550
2232
5520

query I rowsort
SELECT DISTINCT - cor0.col0 * 23 - - col1 AS col1 FROM tab2 AS cor0
----
-130
-1735
-1800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + + 20 * ( - col1 ) * - col2 col2 FROM tab0 AS cor0
----
149322
1941
56793

onlyif mysql # use DIV operator for integer division
query I rowsort label-1069
SELECT cor0.col1 DIV CAST( 19 AS SIGNED ) + - col1 FROM tab0 AS cor0
----
-82
-87
-92

skipif mysql # not compatible
query I rowsort label-1069
SELECT cor0.col1 / CAST ( 19 AS INTEGER ) + - col1 FROM tab0 AS cor0
----
-82
-87
-92

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

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

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

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

query I rowsort
SELECT ALL - - col1 + 10 FROM tab0 AS cor0
----
101
107
96

query I rowsort
SELECT DISTINCT + col0 - + 85 FROM tab2 AS cor0
----
-6
-7
-78

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

query I rowsort
SELECT ALL - col1 - 47 AS col0 FROM tab0 AS cor0
----
-133
-138
-144

query I rowsort
SELECT - col2 * + col2 + cor0.col0 * - col2 * + col0 FROM tab2 AS cor0
----
-158860
-2052
-238602

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

query I rowsort
SELECT ALL + col2 * + 21 AS col1 FROM tab2 AS cor0
----
546
567
798

query I rowsort
SELECT DISTINCT - col1 * - col0 - + 56 * + col0 FROM tab2 cor0
----
-175
-3081
234

query I rowsort
SELECT - col2 * 19 FROM tab2 AS cor0
----
-494
-513
-722

query I rowsort
SELECT + + cor0.col0 + - col0 + 28 AS col2 FROM tab2 AS cor0
----
28
28
28

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1084
SELECT ( + 20 ) + col1 DIV + 47 AS col1 FROM tab2 AS cor0
----
20
20
21

skipif mysql # not compatible
query I rowsort label-1084
SELECT ( + 20 ) + col1 / + 47 AS col1 FROM tab2 AS cor0
----
20
20
21

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

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

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

query I rowsort
SELECT ALL col1 * 80 AS col2 FROM tab0 AS cor0
----
6880
7280
7760

query I rowsort
SELECT + ( - 70 ) * col2 FROM tab2 AS cor0
----
-1820
-1890
-2660

query I rowsort
SELECT ALL - ( + 26 ) * col0 * + col1 + col0 + + cor0.col1 FROM tab2 cor0
----
-119515
-34822
-5604

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + 19 col1 FROM tab1 AS cor0
----
22
83
99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 23 * + col0 + cor0.col2 col0 FROM tab1 AS cor0
----
-1415
-15
-1744

query I rowsort
SELECT ALL 77 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d7b027bca5d37c67e29013904def8125

onlyif mysql # use DIV operator for integer division
query I rowsort label-1095
SELECT DISTINCT col0 + col1 + ( + cor0.col2 ) DIV - col2 AS col0 FROM tab1 AS cor0
----
28
73
92

skipif mysql # not compatible
query I rowsort label-1095
SELECT DISTINCT col0 + col1 + ( + cor0.col2 ) / - col2 AS col0 FROM tab1 AS cor0
----
28
73
92

query I rowsort
SELECT DISTINCT - 84 AS col1 FROM tab2 cor0
----
-84

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

skipif mysql # not compatible
query I rowsort label-1097
SELECT DISTINCT - + ( - col1 ) / 41 AS col0 FROM tab2 AS cor0
----
0
1

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

query I rowsort
SELECT + - 41 * col1 AS col2 FROM tab0 AS cor0
----
-3526
-3731
-3977

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - 14 ) * col2 + 17 col1 FROM tab2
----
-347
-361
-515

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

query I rowsort
SELECT + 36 * col1 FROM tab1 cor0
----
360
468
936

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

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

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

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

query I rowsort
SELECT ALL - 7 * + cor0.col1 AS col2 FROM tab2 AS cor0
----
-119
-217
-413

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

query I rowsort
SELECT DISTINCT - 9 + col0 FROM tab1 AS cor0
----
-6
55
71

query I rowsort
SELECT DISTINCT - 60 + + col1 FROM tab2 cor0
----
-1
-29
-43

query I rowsort
SELECT ALL + 3 + + col1 * col1 FROM tab1 AS cor0
----
103
172
679

query I rowsort
SELECT - 24 + - col0 AS col0 FROM tab1
----
-104
-27
-88

query I rowsort
SELECT 31 + 94 FROM tab1
----
125
125
125

query I rowsort
SELECT ALL - 19 FROM tab1, tab1 AS cor0
----
9 values hashing to 339c9d62143bf2f7566b89a1b56eeeb4

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 30 + col0 * col2 col1 FROM tab2
----
159
1998
2972

query I rowsort
SELECT cor1.col0 * cor0.col1 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ae10dfda2508149d338269366c35c584

query I rowsort
SELECT DISTINCT col2 + + 61 * + col0 FROM tab0
----
1497
2136
5511

query I rowsort
SELECT - 22 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 647e567609c5ada1d3454d2102819bfe

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

query I rowsort
SELECT ALL + col0 + + 45 + - col2 FROM tab1 AS cor0
----
-6
29
52

query I rowsort
SELECT ALL - 93 + cor0.col0 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 4aaa54e31c29cf3023ce85f168ddcc97

query I rowsort
SELECT ALL + + 75 + 28 FROM tab0 AS cor0
----
103
103
103

query I rowsort
SELECT ( tab0.col0 ) * - tab0.col0 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 4734c38591591662f77999e8d1e5daf1

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

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

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

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

query I rowsort
SELECT ALL 2 + col2 * col0 FROM tab1 cor0
----
164
3650
7682

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

query I rowsort
SELECT + 46 + + 94 FROM tab2 AS cor0
----
140
140
140

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

query I rowsort
SELECT DISTINCT + 52 + - 17 AS col0 FROM tab2, tab1 AS cor0
----
35

query I rowsort
SELECT ALL + 0 FROM tab1, tab0 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

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

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

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

query I rowsort
SELECT - col0 * + 18 FROM tab0 cor0
----
-1602
-432
-630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + col2 * - 62 * col2 col0 FROM tab2 AS cor0
----
-41834
-45191
-89449

query I rowsort
SELECT ALL + 12 + + col0 * - cor0.col0 FROM tab1 AS cor0
----
-4084
-6388
3

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

skipif mysql # not compatible
query I rowsort label-1142
SELECT ALL - 64 / + cor0.col0 AS col0 FROM tab1 AS cor0
----
-1
-21
0

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

query I rowsort
SELECT ALL + col1 + col0 * col0 FROM tab2
----
6143
6258
80

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

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

query I rowsort
SELECT 47 AS col0 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 3f991632e9c7c5142e1d80857cd10a2d

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

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

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

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

query I rowsort
SELECT ALL ( - 2 ) AS col2 FROM tab0, tab1 AS cor0, tab2 cor1
----
27 values hashing to 20c9213316527d507e26425041e08387

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col0 * 37 col0 FROM tab0, tab1 AS cor0
----
111
2368
2960

query I rowsort
SELECT - 6 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e92b2679faac7be63701967e3f0c0934

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1153
SELECT ALL CAST( - 58 AS SIGNED ) AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to a38440572743ed8a3d8af7b49a5388c9

skipif mysql # not compatible
query I rowsort label-1153
SELECT ALL CAST ( - 58 AS INTEGER ) AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to a38440572743ed8a3d8af7b49a5388c9

query I rowsort
SELECT 57 * col2 FROM tab1
----
3078
3249
5472

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

query I rowsort
SELECT 32 * - 82 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 15818e8b7aa8f21e5ea692c5c82a47af

query I rowsort
SELECT DISTINCT + col2 * ( + 38 ) FROM tab0
----
1254
3116
38

query I rowsort
SELECT ( 93 ) FROM tab1, tab0 cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT + col1 - col1 * + 23 FROM tab1
----
-220
-286
-572

query I rowsort
SELECT DISTINCT - col0 + col2 * + col0 AS col0 FROM tab0
----
0
7209
768

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

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

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

query I rowsort
SELECT DISTINCT - - 23 * - col2 FROM tab2 AS cor0
----
-598
-621
-874

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

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

query I rowsort
SELECT ALL - col2 * col2 * + col0 FROM tab0
----
-26136
-35
-598436

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

query I rowsort
SELECT ( col0 ) * + col0 * + col1 FROM tab1 AS cor0
----
234
40960
83200

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

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

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

query I rowsort
SELECT - - col1 * + col2 + col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT col0 * cor0.col2 + + ( - col0 ) FROM tab1 cor0
----
159
3584
7600

query I rowsort
SELECT - 36 - col0 AS col0 FROM tab0 AS cor0
----
-125
-60
-71

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

skipif mysql # not compatible
query I rowsort label-1173
SELECT + - col0 / + col2 - + cor0.col2 FROM tab1 AS cor0
----
-54
-58
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1174
SELECT - 95 + col0 DIV - 80 FROM tab1 AS cor0
----
-95
-95
-96

skipif mysql # not compatible
query I rowsort label-1174
SELECT - 95 + col0 / - 80 FROM tab1 AS cor0
----
-95
-95
-96

query I rowsort
SELECT - 25 + - col1 AS col0 FROM tab1 AS cor0
----
-35
-38
-51

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

query I rowsort
SELECT DISTINCT 24 + col1 * 92 FROM tab1 AS cor0
----
1220
2416
944

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

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

query I rowsort
SELECT ALL + tab1.col0 * tab1.col2 + + col1 * + col1 AS col2 FROM tab1
----
3748
7849
838

query I rowsort
SELECT DISTINCT + + 48 - - col2 FROM tab0 AS cor0
----
130
49
81

query I rowsort
SELECT col1 * col1 * 34 FROM tab0 AS cor0
----
251464
281554
319906

query I rowsort
SELECT ALL - 75 + col2 FROM tab0 AS cor0
----
-42
-74
7

query I rowsort
SELECT ALL - 58 * col0 * col2 + - 9 * col2 AS col1 FROM tab1 AS cor0
----
-212097
-446304
-9882

query I rowsort
SELECT ALL - - col2 * col2 + col0 + col2 AS col2 FROM tab0 AS cor0
----
1146
37
6895

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - 70 + - 63 * + col1 col0 FROM tab0 AS cor0
----
-3108
-6041
7

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

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

query I rowsort
SELECT col1 * + 52 + - col1 AS col2 FROM tab0 cor0
----
4386
4641
4947

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1190
SELECT ALL cor0.col0 / + CAST( NULL AS DECIMAL ) AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-1190
SELECT ALL cor0.col0 / + CAST ( NULL AS REAL ) AS col0 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL - - col2 * col1 - + col1 * - 94 AS col1 FROM tab1 AS cor0
----
1510
2470
3848

query I rowsort
SELECT ( col1 ) * col1 + - col2 AS col0 FROM tab0 AS cor0
----
7363
8199
9408

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

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + - 53 col0 FROM tab0 AS cor0
----
-135
-54
-86

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

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

query I rowsort
SELECT + col1 * cor0.col1 FROM tab1 cor0
----
100
169
676

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

skipif mysql # not compatible
query I rowsort label-1200
SELECT ALL CAST ( NULL AS REAL ) * - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-1201
SELECT ALL + ( ( - col0 DIV + 2 ) ) * + cor0.col2 * col2 FROM tab2 AS cor0
----
-2187
-26364
-56316

skipif mysql # not compatible
query I rowsort label-1201
SELECT ALL + ( ( - col0 / + 2 ) ) * + cor0.col2 * col2 FROM tab2 AS cor0
----
-2187
-26364
-56316

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1203
SELECT 53 DIV col0 AS col0 FROM tab0 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-1203
SELECT 53 / col0 AS col0 FROM tab0 AS cor0
----
0
1
2

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

skipif mysql # not compatible
query I rowsort label-1204
SELECT + - col1 / - col0 + col1 AS col0 FROM tab2 AS cor0
----
17
35
59

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

skipif mysql # not compatible
query I rowsort label-1205
SELECT - - CAST ( col1 AS INTEGER ) * col0 + - col0 AS col1 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT DISTINCT - col2 + 61 * + cor0.col1 AS col0 FROM tab0 AS cor0
----
5213
5469
5916

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1208
SELECT - - CAST( 54 AS SIGNED ) * - col0 AS col2 FROM tab1 cor0
----
-162
-3456
-4320

skipif mysql # not compatible
query I rowsort label-1208
SELECT - - CAST ( 54 AS INTEGER ) * - col0 AS col2 FROM tab1 cor0
----
-162
-3456
-4320

query I rowsort
SELECT DISTINCT 99 + col1 * col1 * - ( col1 + col1 ) FROM tab1 AS cor0
----
-1901
-35053
-4295

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

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

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

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

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

query I rowsort
SELECT DISTINCT - col0 * col1 - 68 FROM tab2 AS cor0
----
-1411
-285
-4670

query I rowsort
SELECT DISTINCT col0 * - col1 + 97 + col2 AS col1 FROM tab0 AS cor0
----
-1934
-3297
-7920

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 41 col0 FROM tab2
----
-41

query I rowsort
SELECT DISTINCT cor0.col0 * - 13 FROM tab1 AS cor0
----
-1040
-39
-832

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1222
SELECT ALL col0 * CAST( + 85 * + col2 AS SIGNED ) col0 FROM tab1 AS cor0
----
13770
310080
652800

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1222
SELECT ALL col0 * CAST ( + 85 * + col2 AS INTEGER ) col0 FROM tab1 AS cor0
----
13770
310080
652800

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + - col0 * tab0.col1 + col1 col0 FROM tab0
----
-1892
-3201
-7917

query I rowsort
SELECT - 71 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

onlyif mysql # use DIV operator for integer division
query I rowsort label-1226
SELECT 28 * 40 DIV cor0.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to e5d1c824ca90d4caf458db2171d0f4a4

skipif mysql # not compatible
query I rowsort label-1226
SELECT 28 * 40 / cor0.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to e5d1c824ca90d4caf458db2171d0f4a4

query I rowsort
SELECT + col2 * 85 - - 58 FROM tab1
----
4648
4903
8218

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

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

query I rowsort
SELECT + col0 + col2 + col0 FROM tab2
----
182
196
41

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1232
SELECT ALL + - col2 DIV 88 AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1232
SELECT ALL + - col2 / 88 AS col2 FROM tab0 AS cor0
----
0
0
0

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + - 57 col0 FROM tab2
----
-26
-40
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + 1 col1 FROM tab0
----
87
92
98

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

query I rowsort
SELECT + col2 + + ( + 18 * col2 ) + + col0 FROM tab0
----
1647
54
651

query I rowsort
SELECT ALL - tab1.col0 + col1 * 36 AS col2 FROM tab1
----
296
388
933

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

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

query I rowsort
SELECT DISTINCT + col2 AS col0 FROM tab1 cor0 WHERE NOT - cor0.col1 * col0 + col1 BETWEEN NULL AND col1 + - col0 * + cor0.col2
----
54
57
96

query IIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 WHERE NOT NULL NOT IN ( - cor0.col0 )
----

query III rowsort
SELECT * FROM tab0 WHERE NOT col0 < ( NULL )
----

query I rowsort
SELECT ALL + col0 AS col2 FROM tab2 WHERE NULL >= col2
----

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 * - cor0.col1 * col2 col2 FROM tab2 AS cor0
----
22599
24548
39884

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

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

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

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

query I rowsort
SELECT cor0.col1 * - cor0.col0 + cor0.col0 + - col1 * col2 FROM tab2 AS cor0
----
-1047
-1910
-6058

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

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

query I rowsort
SELECT DISTINCT col2 + col0 + col0 FROM tab1
----
185
256
60

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

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

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

query I rowsort
SELECT DISTINCT + col1 + - col1 * col1 AS col1 FROM tab1
----
-156
-650
-90

query I rowsort
SELECT DISTINCT - col1 + - col2 + - col2 FROM tab1
----
-124
-134
-205

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

query I rowsort
SELECT + col1 * + tab1.col0 * col0 FROM tab1
----
234
40960
83200

query I rowsort
SELECT ALL col1 FROM tab2 WHERE ( NULL ) NOT IN ( col1 / tab2.col2 ) AND NOT ( col1 ) NOT IN ( - col1 )
----

query I rowsort
SELECT 47 - - col2 AS col1 FROM tab1 AS cor0
----
101
104
143

query I rowsort
SELECT ALL - col1 * - col2 + + col2 AS col2 FROM tab0
----
2871
7544
98

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1265
SELECT - col0 + - 46 DIV + 76 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-1265
SELECT - col0 + - 46 / + 76 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - 86 col2 FROM tab2 AS cor0
----
-103
-117
-145

query I rowsort
SELECT ALL col0 * 90 * ( col2 ) AS col0 FROM tab2 AS cor0
----
17010
182520
270180

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

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

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

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

query III rowsort
SELECT * FROM tab1 WHERE - col0 IN ( - col2 )
----

query I rowsort
SELECT col2 - col1 AS col0 FROM tab2 WHERE NULL >= + col1 + + col1
----

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

query I rowsort
SELECT - col0 * col0 FROM tab0 WHERE NULL <> NULL
----

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1277
SELECT ALL col1 DIV - col1 + col1 * col0 AS col1 FROM tab2
----
1342
216
4601

skipif mysql # not compatible
query I rowsort label-1277
SELECT ALL col1 / - col1 + col1 * col0 AS col1 FROM tab2
----
1342
216
4601

query I rowsort
SELECT tab2.col1 AS col1 FROM tab2 WHERE + col1 NOT IN ( col1 - + col1 )
----
17
31
59

query III rowsort
SELECT ALL * FROM tab1 WHERE NOT - col0 >= col1
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

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

query I rowsort
SELECT DISTINCT - tab1.col1 + col0 AS col0 FROM tab1 WHERE NULL <> NULL
----

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

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

query I rowsort
SELECT + col2 - col1 * col1 AS col0 FROM tab0
----
-7363
-8199
-9408

query I rowsort
SELECT DISTINCT - col1 AS col0 FROM tab2 WHERE NULL <= NULL
----

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT col0 BETWEEN NULL AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1287
SELECT ALL + col0 * + col2 + + col0 DIV + col1 AS col1 FROM tab0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-1287
SELECT ALL + col0 * + col2 + + col0 / + col1 AS col1 FROM tab0
----
35
7298
792

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

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

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

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

query I rowsort
SELECT col1 * col0 + + tab2.col0 - tab2.col1 AS col0 FROM tab2
----
1405
193
4621

onlyif mysql # use DIV operator for integer division
query I rowsort label-1293
SELECT DISTINCT + col1 + + col2 DIV - col2 FROM tab0 AS cor0
----
85
90
96

skipif mysql # not compatible
query I rowsort label-1293
SELECT DISTINCT + col1 + + col2 / - col2 FROM tab0 AS cor0
----
85
90
96

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1296
SELECT ALL col0 DIV 14 col0 FROM tab1 AS cor0
----
0
4
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1296
SELECT ALL col0 / 14 col0 FROM tab1 AS cor0
----
0
4
5

query I rowsort
SELECT ALL - col1 * 14 + col0 * + col2 FROM tab0 AS cor0
----
-1323
-412
6024

query I rowsort
SELECT - col2 - 23 FROM tab2
----
-49
-50
-61

query I rowsort
SELECT DISTINCT 41 * - col2 * col0 + 98 * col2 + col2 * + col0 FROM tab0 AS cor0
----
-1302
-283884
-28446

query I rowsort
SELECT + + col2 * + 68 FROM tab2 AS cor0
----
1768
1836
2584

query I rowsort
SELECT DISTINCT + ( - tab1.col0 ) + cor0.col2 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 2689e3ba6de7ff1daca62260a4832077

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

query I rowsort
SELECT ALL 90 * - 65 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to 9d00498a6fbd842c534ddf46c24c813a

query I rowsort
SELECT col2 * 10 - + 90 FROM tab2
----
170
180
290

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

query I rowsort
SELECT + col0 * - 60 FROM tab2
----
-420
-4680
-4740

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

skipif mysql # not compatible
query I rowsort label-1307
SELECT DISTINCT - CAST ( NULL AS REAL ) AS col2 FROM tab1
----
NULL

query I rowsort
SELECT - col1 * cor0.col1 + + col2 FROM tab0 AS cor0
----
-7363
-8199
-9408

query I rowsort
SELECT ALL + + 14 AS col1 FROM tab2 AS cor0
----
14
14
14

query I rowsort
SELECT ALL + + col0 * - col1 * col2 - 82 * + col0 AS col1 FROM tab2 AS cor0
----
-126048
-57512
-6433

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1312
SELECT + cor0.col0 * col1 + col1 DIV + 15 FROM tab2 AS cor0
----
1344
219
4605

skipif mysql # not compatible
query I rowsort label-1312
SELECT + cor0.col0 * col1 + col1 / + 15 FROM tab2 AS cor0
----
1344
219
4605

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

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

query I rowsort
SELECT ALL - 82 * - col0 + - ( + col1 ) FROM tab1 AS cor0
----
220
5238
6547

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

query I rowsort
SELECT DISTINCT + 85 - - col1 * col2 * col1 AS col1 FROM tab0
----
244153
679127
9494

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1319
SELECT ALL + tab2.col2 DIV col1 + 45 * - 29 * col2 + 88 FROM tab2
----
-33842
-35147
-49500

skipif mysql # not compatible
query I rowsort label-1319
SELECT ALL + tab2.col2 / col1 + 45 * - 29 * col2 + 88 FROM tab2
----
-33842
-35147
-49500

query I rowsort
SELECT ALL tab1.col1 * col1 + - ( col0 ) FROM tab1
----
36
673
89

query I rowsort
SELECT - + col2 * col0 + 20 * col0 AS col2 FROM tab2 cor0
----
-1422
-468
-49

query I rowsort
SELECT ALL - col1 * + col2 + - col0 * col2 AS col2 FROM tab1 cor0
----
-1566
-4218
-8928

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

query I rowsort
SELECT + 18 + - cor0.col2 FROM tab1 AS cor0
----
-36
-39
-78

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

skipif mysql # not compatible
query I rowsort label-1325
SELECT DISTINCT + cor0.col2 + col0 / ( - col1 ) FROM tab1 AS cor0
----
51
54
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-1326
SELECT ALL - 65 * col0 DIV + 15 FROM tab1 AS cor0
----
-13
-277
-346

skipif mysql # not compatible
query I rowsort label-1326
SELECT ALL - 65 * col0 / + 15 FROM tab1 AS cor0
----
-13
-277
-346

query I rowsort
SELECT + ( col1 ) + - 51 * col0 FROM tab2 AS cor0
----
-326
-3919
-4012

query I rowsort
SELECT DISTINCT 16 * + cor0.col1 + col2 FROM tab1 cor0
----
217
304
470

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

skipif mysql # not compatible
query I rowsort label-1329
SELECT DISTINCT col1 * - col0 + + CAST ( col0 AS INTEGER ) * + col1 AS col2 FROM tab2
----
0

query I rowsort
SELECT 73 * col1 + tab0.col1 + - col0 * - col1 FROM tab0
----
10573
14833
8428

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1332
SELECT DISTINCT - ( col1 ) * 92 + 52 * col1 DIV col0 AS col0 FROM tab0
----
-7726
-8319
-8780

skipif mysql # not compatible
query I rowsort label-1332
SELECT DISTINCT - ( col1 ) * 92 + 52 * col1 / col0 AS col0 FROM tab0
----
-7726
-8319
-8780

query I rowsort
SELECT DISTINCT 10 + col0 FROM tab0 AS cor0
----
34
45
99

query I rowsort
SELECT + col1 * cor0.col0 + 43 FROM tab2 cor0
----
1386
260
4645

query I rowsort
SELECT - 85 * col0 FROM tab0
----
-2040
-2975
-7565

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 + ( 96 ) col0 FROM tab2 AS cor0
----
37
65
79

query I rowsort
SELECT - + cor0.col0 * + 34 + + col0 AS col2 FROM tab1 AS cor0
----
-2112
-2640
-99

query I rowsort
SELECT DISTINCT - col2 * 17 + + col2 FROM tab1 AS cor0
----
-1536
-864
-912

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

skipif mysql # not compatible
query I rowsort label-1340
SELECT DISTINCT col1 + CAST ( + col0 AS INTEGER ) + + cor0.col0 * + 63 AS col1 FROM tab2 AS cor0
----
479
5051
5073

query I rowsort
SELECT DISTINCT - col1 * + 47 FROM tab1 AS cor0
----
-1222
-470
-611

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

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1345
SELECT ALL col1 * - col2 DIV + col2 + col0 * col2 * cor0.col0 FROM tab1 AS cor0
----
233462
460
614387

skipif mysql # not compatible
query I rowsort label-1345
SELECT ALL col1 * - col2 / + col2 + col0 * col2 * cor0.col0 FROM tab1 AS cor0
----
233462
460
614387

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

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

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1347
SELECT ALL - + CAST( 33 AS SIGNED ) - + cor0.col1 AS col0 FROM tab0 AS cor0
----
-119
-124
-130

skipif mysql # not compatible
query I rowsort label-1347
SELECT ALL - + CAST ( 33 AS INTEGER ) - + cor0.col1 AS col0 FROM tab0 AS cor0
----
-119
-124
-130

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - 83 col2 FROM tab1 AS cor0
----
-4482
-4731
-7968

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

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

query I rowsort
SELECT ALL - ( 37 ) * col0 FROM tab1 AS cor0
----
-111
-2368
-2960

query I rowsort
SELECT + col1 * 68 FROM tab0 cor0
----
5848
6188
6596

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

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

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

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

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

query I rowsort
SELECT DISTINCT + ( + col0 ) + + col1 * 38 AS col0 FROM tab0 AS cor0
----
3292
3547
3721

query I rowsort
SELECT DISTINCT + 98 + + col2 FROM tab2 AS cor0
----
124
125
136

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

query I rowsort
SELECT + + 48 + col1 AS col2 FROM tab2 AS cor0
----
107
65
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + cor0.col0 * col2 + + ( + col2 ) col0 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT DISTINCT - 41 * + col1 AS col1 FROM tab1 AS cor0
----
-1066
-410
-533

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 * col1 * 95 col2 FROM tab2 AS cor0
----
145730
61370
79515

query I rowsort
SELECT col1 + 45 * col2 AS col1 FROM tab0
----
142
1571
3781

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1368
SELECT DISTINCT 48 DIV col1 - col0 DIV + ( + col2 ) FROM tab0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-1368
SELECT DISTINCT 48 / col1 - col0 / + ( + col2 ) FROM tab0
----
-1
-35
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1369
SELECT 9 + col2 DIV col0 col2 FROM tab2 AS cor0
----
12
9
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1369
SELECT 9 + col2 / col0 col2 FROM tab2 AS cor0
----
12
9
9

query I rowsort
SELECT - 81 + - col2 * cor0.col0 AS col2 FROM tab0 AS cor0
----
-116
-7379
-873

query I rowsort
SELECT - + 38 + col0 FROM tab2 AS cor0
----
-31
40
41

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

query I rowsort
SELECT - col0 * col1 + col2 * - ( cor0.col2 ) - - col1 AS col2 FROM tab1 AS cor0
----
-10243
-2968
-3879

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col2 * 2 col2 FROM tab2
----
-1352
-1458
-2888

query I rowsort
SELECT DISTINCT - col0 + - col1 * col1 * + tab0.col0 FROM tab0
----
-177528
-329350
-737098

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

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

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

query I rowsort
SELECT ( tab0.col0 ) * + col0 * + 37 FROM tab0
----
21312
293077
45325

query I rowsort
SELECT + ( - col0 ) * + col0 + - tab2.col2 FROM tab2
----
-6110
-6279
-76

query I rowsort
SELECT tab2.col0 * tab2.col2 + - ( 92 ) FROM tab2
----
1936
2910
97

query I rowsort
SELECT + ( 82 ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

query I rowsort
SELECT DISTINCT 73 * - col0 + + col0 AS col2 FROM tab1 AS cor0
----
-216
-4608
-5760

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

skipif mysql # not compatible
query I rowsort label-1384
SELECT ALL + col1 + CAST ( col2 AS INTEGER ) FROM tab0 AS cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - cor0.col0 + col0 * + col1 col0 FROM tab1 cor0
----
576
75
960

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

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

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

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

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

query I rowsort
SELECT + + col1 * - 57 AS col1 FROM tab2 AS cor0
----
-1767
-3363
-969

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col1 * - 58 - + col2 col2 FROM tab0
----
-5021
-5360
-5627

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

query I rowsort
SELECT col1 + + col0 + tab1.col2 AS col2 FROM tab1
----
131
189
83

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

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

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

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

query I rowsort
SELECT - + col0 * + 84 FROM tab0 cor0
----
-2016
-2940
-7476

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

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

query I rowsort
SELECT ALL - col2 - 9 FROM tab1 AS cor0
----
-105
-63
-66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col2 * + col1 * + cor0.col0 + col0 col0 FROM tab0 AS cor0
----
3430
664207
68136

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

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

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

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

query I rowsort
SELECT + - col0 * + col1 + + col0 FROM tab2 AS cor0
----
-1264
-210
-4524

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 82 col0 FROM tab0 cor0
----
-1968
-2870
-7298

query I rowsort
SELECT 25 + col1 FROM tab2
----
42
56
84

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col0 AS REAL ) + tab0.col2 + + 2 AS col0 FROM tab0
----
173
38
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1410
SELECT DISTINCT 79 * tab1.col2 + col2 * CAST( 43 AS SIGNED ) * col1 AS col0 FROM tab1
----
29013
61248
64638

skipif mysql # not compatible
query I rowsort label-1410
SELECT DISTINCT 79 * tab1.col2 + col2 * CAST ( 43 AS INTEGER ) * col1 AS col0 FROM tab1
----
29013
61248
64638

onlyif mysql # use DIV operator for integer division
query I rowsort label-1411
SELECT + - cor0.col2 DIV - 52 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-1411
SELECT + - cor0.col2 / - 52 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT - col2 + ( - cor0.col0 ) * + 23 FROM tab2 cor0
----
-1820
-1855
-188

query I rowsort
SELECT ALL cor0.col0 * 7 AS col2 FROM tab1, tab1 cor0, tab0 AS cor1
----
27 values hashing to 93b3730ddbb426562985f8f38ee23148

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

query I rowsort
SELECT + - 98 + - col1 + + col1 * - col0 AS col1 FROM tab2 AS cor0
----
-1458
-346
-4759

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

query I rowsort
SELECT DISTINCT col1 + + cor0.col1 AS col2 FROM tab1 cor0
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-1418
SELECT DISTINCT col2 * col1 DIV + col1 AS col0 FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-1418
SELECT DISTINCT col2 * col1 / + col1 AS col0 FROM tab0 cor0
----
1
33
82

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

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

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

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

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

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

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

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

query I rowsort
SELECT + 50 + 65 * - col2 FROM tab2
----
-1640
-1705
-2420

query I rowsort
SELECT tab2.col0 * - col0 - col0 * 91 * - 14 FROM tab2
----
8869
93288
94405

query I rowsort
SELECT col0 - 77 FROM tab0
----
-42
-53
12

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

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

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

skipif mysql # not compatible
query I rowsort label-1429
SELECT DISTINCT + CAST ( col1 AS INTEGER ) + tab0.col2 FROM tab0
----
119
173
98

query I rowsort
SELECT DISTINCT col0 + - 40 FROM tab1
----
-37
24
40

query I rowsort
SELECT ALL - 26 AS col0 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to 4e49eac022daeae6f88f610644ba3754

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1433
SELECT + 92 DIV tab0.col2 - + tab0.col0 AS col0 FROM tab0
----
-22
-88
57

skipif mysql # not compatible
query I rowsort label-1433
SELECT + 92 / tab0.col2 - + tab0.col0 AS col0 FROM tab0
----
-22
-88
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-1434
SELECT + col2 DIV cor0.col1 - + 6 col1 FROM tab0 AS cor0
----
-6
-6
-6

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

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

query I rowsort
SELECT + col2 * 97 * + col2 AS col2 FROM tab1 AS cor0
----
282852
315153
893952

query I rowsort
SELECT DISTINCT col1 + ( + 98 ) AS col2 FROM tab2 AS cor0
----
115
129
157

query I rowsort
SELECT + col1 + 54 FROM tab2 cor0
----
113
71
85

query I rowsort
SELECT col1 - - 11 FROM tab1 AS cor0
----
21
24
37

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

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

query I rowsort
SELECT DISTINCT + 70 AS col1 FROM tab0
----
70

query I rowsort
SELECT DISTINCT col0 * col0 + - cor0.col0 * - col2 FROM tab2 AS cor0
----
238
8112
9243

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

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

query I rowsort
SELECT DISTINCT + cor1.col2 FROM tab1, tab1 cor0, tab0, tab1 AS cor1
----
54
57
96

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

query I rowsort
SELECT - col0 * - 80 AS col0 FROM tab2 cor0
----
560
6240
6320

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

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

query I rowsort
SELECT DISTINCT + col1 - ( 38 ) AS col0 FROM tab1
----
-12
-25
-28

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

query I rowsort
SELECT - 53 * col2 + col2 FROM tab0 AS cor0
----
-1716
-4264
-52

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

query I rowsort
SELECT col1 + 35 * cor0.col2 AS col2 FROM tab1 AS cor0
----
1916
2005
3373

query I rowsort
SELECT ALL - + col2 * 99 + cor0.col1 * - 57 * 6 FROM tab2 AS cor0
----
-13275
-22752
-9576

query I rowsort
SELECT 86 + col2 + + col2 * - cor0.col0 AS col2 FROM tab1 cor0
----
-22
-3505
-7498

onlyif mysql # use DIV operator for integer division
query I rowsort label-1457
SELECT + + col1 * ( - col2 ) + - 43 * col1 * + col0 - ( col2 ) * col2 DIV ( col1 ) AS col1 FROM tab1 AS cor0
----
-28414
-46676
-4870

skipif mysql # not compatible
query I rowsort label-1457
SELECT + + col1 * ( - col2 ) + - 43 * col1 * + col0 - ( col2 ) * col2 / ( col1 ) AS col1 FROM tab1 AS cor0
----
-28414
-46676
-4870

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

query I rowsort
SELECT + - ( 35 ) AS col2 FROM tab1, tab0, tab0 AS cor0, tab2
----
81 values hashing to 7fbbc209618bf287c81172ef2c617496

query I rowsort
SELECT DISTINCT 5 * + tab1.col0 FROM tab1, tab2 AS cor0
----
15
320
400

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

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

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

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

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

skipif mysql # not compatible
query I rowsort label-1464
SELECT + CAST ( + col1 AS INTEGER ) + + col0 FROM tab0 cor0
----
110
132
180

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

query I rowsort
SELECT ALL + col2 * - 65 + col2 + ( col1 ) FROM tab2 AS cor0
----
-1605
-1697
-2415

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

query I rowsort
SELECT DISTINCT - col2 * 39 FROM tab2 AS cor0
----
-1014
-1053
-1482

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - ( + 21 ) * col2 col1 FROM tab1 cor0
----
1134
1197
2016

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

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + cor0.col0 * - col0 + - col2 col2 FROM tab2 AS cor0
----
-6110
-6279
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-1473
SELECT DISTINCT - CAST( col0 AS SIGNED ) * - col0 + 47 DIV col1 AS col0 FROM tab2 AS cor0
----
50
6084
6243

skipif mysql # not compatible
query I rowsort label-1473
SELECT DISTINCT - CAST ( col0 AS INTEGER ) * - col0 + 47 / col1 AS col0 FROM tab2 AS cor0
----
50
6084
6243

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

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

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

query I rowsort
SELECT DISTINCT - col0 + cor0.col2 * + cor0.col1 AS col2 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT ALL + cor0.col1 * + col0 * - 90 FROM tab0 AS cor0
----
-185760
-305550
-728910

onlyif mysql # use DIV operator for integer division
query I rowsort label-1479
SELECT + 0 DIV col0 + + col1 * - col0 AS col0 FROM tab1
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-1479
SELECT + 0 / col0 + + col1 * - col0 AS col0 FROM tab1
----
-1040
-640
-78

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

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

query I rowsort
SELECT ALL + cor0.col0 * + 74 + - col0 AS col2 FROM tab1 AS cor0
----
219
4672
5840

query I rowsort
SELECT ALL + - col0 * ( col1 ) + col2 * - col1 * + col2 AS col1 FROM tab1 AS cor0
----
-120848
-33130
-75894

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1486
SELECT DISTINCT col2 DIV 94 + - cor0.col2 FROM tab1 AS cor0
----
-54
-57
-95

skipif mysql # not compatible
query I rowsort label-1486
SELECT DISTINCT col2 / 94 + - cor0.col2 FROM tab1 AS cor0
----
-54
-57
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-1487
SELECT ALL - col2 DIV col2 + 57 FROM tab0 AS cor0
----
56
56
56

skipif mysql # not compatible
query I rowsort label-1487
SELECT ALL - col2 / col2 + 57 FROM tab0 AS cor0
----
56
56
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-1488
SELECT DISTINCT + col1 * - col2 - col0 DIV col0 AS col2 FROM tab2 AS cor0
----
-1535
-647
-838

skipif mysql # not compatible
query I rowsort label-1488
SELECT DISTINCT + col1 * - col2 - col0 / col0 AS col2 FROM tab2 AS cor0
----
-1535
-647
-838

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 - + ( + 39 ) col1 FROM tab1 AS cor0
----
-135
-93
-96

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

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

query I rowsort
SELECT ALL - 13 + - col1 FROM tab0 AS cor0
----
-104
-110
-99

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

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

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

query I rowsort
SELECT 14 * col1 * col1 FROM tab1
----
1400
2366
9464

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

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

query I rowsort
SELECT 17 * col0 FROM tab2 AS cor0
----
119
1326
1343

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1499
SELECT ALL + CAST ( col1 AS INTEGER ) col1 FROM tab2
----
17
31
59

query I rowsort
SELECT ALL - col1 * + col0 * col0 + + col1 AS col1 FROM tab2 AS cor0
----
-106080
-1488
-358897

query I rowsort
SELECT - ( - 19 ) * + col2 FROM tab2 AS cor0
----
494
513
722

query I rowsort
SELECT ALL + + col2 * 66 + + col2 * + ( - col2 ) FROM tab2 AS cor0
----
1040
1053
1064

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

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

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

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

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

query I rowsort
SELECT ALL 62 * + col0 - ( cor0.col0 ) FROM tab0 AS cor0
----
1464
2135
5429

query I rowsort
SELECT ALL 32 + - col1 * - col1 AS col0 FROM tab1 cor0
----
132
201
708

query I rowsort
SELECT + col0 + 32 * col2 FROM tab0 AS cor0
----
1080
2713
67

query I rowsort
SELECT + - col2 - - 68 AS col0 FROM tab0 AS cor0
----
-14
35
67

query I rowsort
SELECT - cor0.col1 * 78 AS col0 FROM tab1 AS cor0
----
-1014
-2028
-780

onlyif mysql # use DIV operator for integer division
query I rowsort label-1513
SELECT - col2 + 21 DIV cor0.col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-1513
SELECT - col2 + 21 / cor0.col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT + + 6 + col2 AS col0 FROM tab0 AS cor0
----
39
7
88

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 - - col1 col2 FROM tab0 AS cor0
----
194
2924
7553

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1518
SELECT + - cor0.col0 * - col1 DIV col1 + col2 AS col1 FROM tab0 AS cor0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-1518
SELECT + - cor0.col0 * - col1 / col1 + col2 AS col1 FROM tab0 AS cor0
----
171
36
57

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

query I rowsort
SELECT - - 77 + 64 * cor0.col0 FROM tab0 AS cor0
----
1613
2317
5773

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

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

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1523
SELECT ALL - + col1 - cor0.col0 DIV 63 FROM tab2 AS cor0
----
-18
-31
-60

skipif mysql # not compatible
query I rowsort label-1523
SELECT ALL - + col1 - cor0.col0 / 63 FROM tab2 AS cor0
----
-18
-31
-60

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

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

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

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

query I rowsort
SELECT ALL col0 + - col1 * col2 + - cor0.col1 AS col0 FROM tab2 AS cor0
----
-1515
-584
-861

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

skipif mysql # not compatible
query I rowsort label-1529
SELECT + cor0.col2 * + CAST ( NULL AS REAL ) FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT 91 + col0 AS col1 FROM tab2
----
169
170
98

query I rowsort
SELECT + 66 * ( col2 ) FROM tab0
----
2178
5412
66

query I rowsort
SELECT - 55 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to ac76841ceecd2311e80c621d15bacdd3

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

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col0 + - 87 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 5c37eea26af132f3dbafff4c0b065c54

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

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( 49 ) * - col2 + - 58 * - ( - col0 * col0 ) col2 FROM tab1 AS cor0
----
-240361
-3168
-375904

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

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

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

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

query I rowsort
SELECT 99 * col1 + col2 * col2 * - tab1.col2 AS col2 FROM tab1
----
-154890
-184203
-883449

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

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

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

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

query I rowsort
SELECT DISTINCT + - 47 + + cor0.col0 AS col1 FROM tab1 AS cor0
----
-44
17
33

query I rowsort
SELECT DISTINCT - col0 + col1 * col0 * col2 + + 11 * - 42 AS col2 FROM tab2 AS cor0
----
119112
50493
5390

query I rowsort
SELECT ALL + cor0.col1 + 87 * - 5 FROM tab1 cor0
----
-409
-422
-425

query I rowsort
SELECT ALL - + col1 * + 75 FROM tab1 AS cor0
----
-1950
-750
-975

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

query I rowsort
SELECT ALL - - col1 + 41 AS col2 FROM tab1 AS cor0
----
51
54
67

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

onlyif mysql # use DIV operator for integer division
query I rowsort label-1552
SELECT - 74 DIV + col2 - 15 AS col0 FROM tab1
----
-15
-16
-16

skipif mysql # not compatible
query I rowsort label-1552
SELECT - 74 / + col2 - 15 AS col0 FROM tab1
----
-15
-16
-16

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col2 * CAST ( + col1 + col0 AS REAL ) AS col2 FROM tab0 AS cor0
----
132
14760
3630

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

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

query I rowsort
SELECT cor0.col2 * - 87 AS col1 FROM tab2 AS cor0
----
-2262
-2349
-3306

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

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

query I rowsort
SELECT + col0 * ( cor0.col0 ) AS col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL + col0 * - col0 * + col1 FROM tab1 AS cor0
----
-234
-40960
-83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-1560
SELECT DISTINCT - col0 DIV 57 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-1560
SELECT DISTINCT - col0 / 57 FROM tab1 AS cor0
----
-1
0

query I rowsort
SELECT DISTINCT + + col2 * col2 + - col2 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT DISTINCT col2 * 61 FROM tab0 AS cor0
----
2013
5002
61

onlyif mysql # use DIV operator for integer division
query I rowsort label-1563
SELECT - - col1 DIV col2 AS col1 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-1563
SELECT - - col1 / col2 AS col1 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT DISTINCT - + col2 + - 48 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
-1302
-537
-720

query I rowsort
SELECT - + col0 * + 55 AS col0 FROM tab0 AS cor0
----
-1320
-1925
-4895

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 81 * 77 col2 FROM tab1 AS cor0
----
-6237
-6237
-6237

query I rowsort
SELECT - 35 + + ( - col0 ) * - 54 FROM tab1 cor0
----
127
3421
4285

query I rowsort
SELECT - 20 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to eb3a66728062963cccbd15bd2f5c9eee

onlyif mysql # use DIV operator for integer division
query I rowsort label-1569
SELECT DISTINCT + col0 DIV + 48 AS col0 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-1569
SELECT DISTINCT + col0 / + 48 AS col0 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + CAST ( 33 AS REAL ) FROM tab2, tab1 AS cor0
----
33

query I rowsort
SELECT - + 88 * + cor0.col1 + - col2 * col0 AS col0 FROM tab0 AS cor0
----
-15306
-8360
-8571

onlyif mysql # use DIV operator for integer division
query I rowsort label-1572
SELECT + + col1 * + col1 + - 10 DIV col1 FROM tab2 cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-1572
SELECT + + col1 * + col1 + - 10 / col1 FROM tab2 cor0
----
289
3481
961

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * + col0 col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL - + ( col1 ) * ( col2 ) FROM tab0 cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1575
SELECT DISTINCT - + col1 DIV cor0.col1 col1 FROM tab0 AS cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1575
SELECT DISTINCT - + col1 / cor0.col1 col1 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT ALL + col0 * col1 * + ( + cor0.col2 ) + col1 FROM tab0 cor0
----
3492
664209
68198

query I rowsort
SELECT - 12 * col0 AS col0 FROM tab0 AS cor0
----
-1068
-288
-420

query I rowsort
SELECT DISTINCT - ( col0 ) * + 44 + col1 FROM tab2 AS cor0
----
-277
-3373
-3459

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1579
SELECT DISTINCT + CAST( col2 AS SIGNED ) + col1 FROM tab1
----
109
67
80

skipif mysql # not compatible
query I rowsort label-1579
SELECT DISTINCT + CAST ( col2 AS INTEGER ) + col1 FROM tab1
----
109
67
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-1580
SELECT - col0 - + tab2.col0 DIV tab2.col1 AS col2 FROM tab2
----
-7
-79
-83

skipif mysql # not compatible
query I rowsort label-1580
SELECT - col0 - + tab2.col0 / tab2.col1 AS col2 FROM tab2
----
-7
-79
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab2.col0 - col2 col2 FROM tab2
----
-20
41
52

query I rowsort
SELECT - tab0.col0 + - col0 * 37 AS col1 FROM tab0
----
-1330
-3382
-912

query I rowsort
SELECT ALL 28 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

onlyif mysql # use DIV operator for integer division
query I rowsort label-1584
SELECT ALL col0 DIV + col1 AS col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1584
SELECT ALL col0 / + col1 AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT + col1 + cor0.col1 * cor0.col0 AS col0 FROM tab2 AS cor0
----
1360
248
4661

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 15 + col2 col0 FROM tab0 AS cor0
----
16
48
97

query I rowsort
SELECT DISTINCT + col2 * - col0 + 13 AS col1 FROM tab2 AS cor0
----
-176
-2015
-2989

query I rowsort
SELECT ALL 66 + - col1 * col2 AS col2 FROM tab0 cor0
----
-2772
-31
-7396

query I rowsort
SELECT col1 * + col0 + - col0 * col2 FROM tab2 AS cor0
----
-1659
2574
28

query I rowsort
SELECT - - 23 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to d94fadcc1c8cc4fc51b78b83e04795f2

query I rowsort
SELECT DISTINCT + 63 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
63

query I rowsort
SELECT ALL - col0 * - col1 * + col1 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT + col0 * - col0 * cor0.col0 FROM tab0 AS cor0
----
-13824
-42875
-704969

query I rowsort
SELECT DISTINCT + col1 * col0 + cor0.col1 AS col2 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT ALL + col2 - col1 * col1 AS col1 FROM tab1 cor0
----
-43
-622
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col1 + - col2 * col1 col2 FROM tab2 AS cor0
----
-620
3068
697

query I rowsort
SELECT 8 * - col0 + col0 * - col2 + col0 AS col1 FROM tab2 AS cor0
----
-238
-2574
-3555

query I rowsort
SELECT col1 * col2 * - col2 + col0 AS col2 FROM tab2 AS cor0
----
-22592
-24469
-39806

query I rowsort
SELECT ALL - + cor0.col2 * - col0 + col2 FROM tab1 cor0
----
216
3705
7776

query I rowsort
SELECT + + col1 + + col0 * col0 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT ALL + - 73 + col0 AS col0 FROM tab1 AS cor0
----
-70
-9
7

query I rowsort
SELECT - + 17 + cor0.col2 FROM tab1 AS cor0
----
37
40
79

query I rowsort
SELECT col0 * col0 + + cor0.col1 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT col0 + col1 * col1 AS col2 FROM tab1 cor0
----
164
249
679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 52 + - col1 col2 FROM tab0 AS cor0
----
-34
-39
-45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col1 col2 FROM tab2
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT col1 FROM tab2 WHERE col1 <> + col2
----
17
31
59

query I rowsort
SELECT + tab2.col0 + - col1 AS col1 FROM tab2
----
-24
19
62

query I rowsort
SELECT DISTINCT col2 + col0 * - col2 AS col1 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT - col1 * - col2 * col0 FROM tab1
----
36480
4212
99840

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * col1 col2 FROM tab0
----
7396
8281
9409

query I rowsort
SELECT ALL + col0 + + col1 * + col1 AS col2 FROM tab1
----
164
249
679

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col2 - col2 * col0 col1 FROM tab1
----
-15360
-324
-7296

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * col1 + col0 col0 FROM tab2
----
-210
-3403
-954

query I rowsort
SELECT DISTINCT - col2 + col0 * - col0 AS col0 FROM tab2
----
-6110
-6279
-76

query I rowsort
SELECT - tab0.col2 * col1 + tab0.col2 * - col1 AS col2 FROM tab0
----
-14924
-194
-5676

query I rowsort
SELECT ALL col0 * - col2 FROM tab1 WHERE col1 * - col0 + - col1 > NULL
----

query I rowsort
SELECT DISTINCT + col2 * col2 * + col1 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT ALL + tab2.col1 * col0 * - tab2.col1 FROM tab2
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT - col0 + col2 AS col1 FROM tab0
----
-34
-7
9

query I rowsort
SELECT + col2 - - col2 AS col2 FROM tab2 WHERE NOT - col0 + + col0 NOT IN ( col0 * col2 * + col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1622
SELECT - col0 + + col1 DIV col1 + + col0 DIV - col0 AS col0 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-1622
SELECT - col0 + + col1 / col1 + + col0 / - col0 AS col0 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT + col1 * - col2 - col2 * - col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 - - col0 * col2 AS col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT col2 / - col0 + col2 FROM tab0 AS cor0 WHERE ( NULL ) NOT IN ( col1 - + col2 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE + col2 * - col1 NOT IN ( tab0.col2 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE + col1 * + col0 >= ( NULL )
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE col1 - + col1 = ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-1629
SELECT tab1.col1 * col2 DIV + col1 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-1629
SELECT tab1.col1 * col2 / + col1 FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT + col2 + + col0 + - col1 FROM tab2
----
100
3
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-1631
SELECT DISTINCT col2 * col2 DIV - col1 FROM tab1
----
-112
-324
-708

skipif mysql # not compatible
query I rowsort label-1631
SELECT DISTINCT col2 * col2 / - col1 FROM tab1
----
-112
-324
-708

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT col0 + + col0 - col2 / col0 = ( col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NULL IN ( col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * - col1 col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT col2 AS col2 FROM tab2 WHERE NOT NULL NOT IN ( - col2 )
----

query I rowsort
SELECT DISTINCT - col2 + - tab1.col1 AS col1 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT ALL col1 + + col2 AS col2 FROM tab2
----
55
58
85

query I rowsort
SELECT + col1 * - col0 + + tab2.col2 - col1 FROM tab2
----
-1322
-221
-4635

query I rowsort
SELECT col1 + + col0 * cor0.col1 - col2 FROM tab2 cor0
----
1322
221
4635

query I rowsort
SELECT ALL tab1.col1 * + col2 * col1 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT + col2 * col2 + + col0 * col0 + + col2 * cor0.col1 * col2 AS col2 FROM tab0 AS cor0
----
1323
626529
95319

onlyif mysql # use DIV operator for integer division
query I rowsort label-1642
SELECT + col0 + - col2 DIV + col1 + cor0.col0 AS col2 FROM tab2 cor0
----
14
156
156

skipif mysql # not compatible
query I rowsort label-1642
SELECT + col0 + - col2 / + col1 + cor0.col0 AS col2 FROM tab2 cor0
----
14
156
156

query I rowsort
SELECT ALL - - col1 + col2 * 6 FROM tab2 cor0
----
193
215
245

query I rowsort
SELECT 49 FROM tab2 cor0
----
49
49
49

query I rowsort
SELECT ALL + col0 * col0 * ( - 24 ) + col2 FROM tab0 AS cor0
----
-13791
-190022
-29399

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + col2 + + col1 * col2 col1 FROM tab2 AS cor0
----
1026
3562
3648

query I rowsort
SELECT - cor1.col2 * 77 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 59f212ec0972cd20e5806c61108d7bb4

query I rowsort
SELECT + 65 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 8bef2ea1f05f3514633f851312bdd805

query I rowsort
SELECT ALL 71 * - col2 - ( col2 ) AS col1 FROM tab0
----
-2376
-5904
-72

query I rowsort
SELECT 50 AS col0 FROM tab2 cor0
----
50
50
50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1651
SELECT ALL col1 + + col0 * CAST( + col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
132
7389
878

skipif mysql # not compatible
query I rowsort label-1651
SELECT ALL col1 + + col0 * CAST ( + col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT ALL + + 42 * - col0 + - col1 * - col0 AS col1 FROM tab2 AS cor0
----
-1975
-77
1326

query I rowsort
SELECT DISTINCT + + col1 + cor0.col2 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT + 42 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1655
SELECT ALL + col1 + CAST( NULL AS DECIMAL ) * col1 / - tab2.col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1655
SELECT ALL + col1 + CAST ( NULL AS REAL ) * col1 / - tab2.col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 90 FROM tab1, tab2 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT + col1 + + 48 * col0 FROM tab0 AS cor0
----
1238
1777
4363

query I rowsort
SELECT - tab0.col0 * col1 - col0 AS col2 FROM tab0
----
-2088
-3430
-8188

query I rowsort
SELECT - tab2.col0 + + 79 FROM tab2, tab2 AS cor0
----
9 values hashing to 5491f80a8823981de774171ebfcac8d2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1660
SELECT DISTINCT col2 + + ( + 17 * col1 + CAST( 30 AS SIGNED ) ) FROM tab0
----
1525
1659
1680

skipif mysql # not compatible
query I rowsort label-1660
SELECT DISTINCT col2 + + ( + 17 * col1 + CAST ( 30 AS INTEGER ) ) FROM tab0
----
1525
1659
1680

onlyif mysql # use DIV operator for integer division
query I rowsort label-1661
SELECT - 54 DIV + col1 AS col2 FROM tab1 AS cor0
----
-2
-4
-5

skipif mysql # not compatible
query I rowsort label-1661
SELECT - 54 / + col1 AS col2 FROM tab1 AS cor0
----
-2
-4
-5

query I rowsort
SELECT ALL + col2 * + 37 + col0 AS col2 FROM tab1 cor0
----
2001
2173
3632

query I rowsort
SELECT DISTINCT 40 * col2 AS col0 FROM tab0 AS cor0
----
1320
3280
40

query I rowsort
SELECT DISTINCT - ( + ( col1 ) ) FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT - 46 FROM tab2
----
-46
-46
-46

query I rowsort
SELECT DISTINCT ( + 49 ) FROM tab0
----
49

query I rowsort
SELECT ALL - 34 + col0 AS col2 FROM tab0 AS cor0
----
-10
1
55

query I rowsort
SELECT ALL - col2 * - col0 + cor0.col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT + + 62 FROM tab1 cor0
----
62

query I rowsort
SELECT ALL col2 * + col1 * col2 - - col0 FROM tab2 AS cor0
----
22606
24627
39962

query I rowsort
SELECT + ( col2 ) + col0 * col2 AS col0 FROM tab2 AS cor0
----
2054
216
3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1672
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + 8 + + col1 + col0 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1672
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + 8 + + col1 + col0 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + + col2 * col0 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + ( - 0 ) AS col0 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1675
SELECT ALL + col1 + + ( col0 ) * - CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1675
SELECT ALL + col1 + + ( col0 ) * - CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1676
SELECT 68 + - ( - col0 ) * CAST( - cor0.col0 AS SIGNED ) AS col0 FROM tab2 AS cor0
----
-6016
-6173
19

skipif mysql # not compatible
query I rowsort label-1676
SELECT 68 + - ( - col0 ) * CAST ( - cor0.col0 AS INTEGER ) AS col0 FROM tab2 AS cor0
----
-6016
-6173
19

query I rowsort
SELECT cor0.col1 * 86 FROM tab1, tab1 AS cor0, tab1 cor1
----
27 values hashing to 4f21fc32bb8f8c72c1140bd6292aac09

query I rowsort
SELECT DISTINCT ( ( col2 ) + - 54 ) * - col1 FROM tab0
----
-2548
1806
5141

query I rowsort
SELECT ALL + - ( ( - col0 ) ) AS col0 FROM tab1 cor0
----
3
64
80

query I rowsort
SELECT DISTINCT + 5 * 32 AS col0 FROM tab1 AS cor0
----
160

query I rowsort
SELECT - + 43 AS col1 FROM tab0 AS cor0
----
-43
-43
-43

query I rowsort
SELECT DISTINCT - - 89 FROM tab1 AS cor0
----
89

query I rowsort
SELECT DISTINCT ( cor0.col1 ) + + col1 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT - + ( col0 ) * + 37 FROM tab1 AS cor0
----
-111
-2368
-2960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * col0 col0 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL + + ( + cor0.col0 ) + + cor0.col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL col1 * - col2 * col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT 26 * + col1 AS col2 FROM tab1
----
260
338
676

onlyif mysql # use DIV operator for integer division
query I rowsort label-1689
SELECT ALL + col0 DIV - ( cor0.col2 ) FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-1689
SELECT ALL + col0 / - ( cor0.col2 ) FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT - - col2 * 27 FROM tab0 cor0
----
2214
27
891

query I rowsort
SELECT ALL col1 * - ( - col1 + cor0.col0 ) AS col2 FROM tab2 AS cor0
----
-1054
-1121
744

query I rowsort
SELECT col1 * col1 + - col0 AS col1 FROM tab2 AS cor0
----
210
3403
954

query I rowsort
SELECT + + col0 * 52 AS col2 FROM tab2 AS cor0
----
364
4056
4108

query I rowsort
SELECT DISTINCT + cor0.col0 + + cor0.col2 * col0 FROM tab0 AS cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-1695
SELECT ALL cor0.col1 DIV - 27 + + col0 FROM tab2 AS cor0
----
6
76
79

skipif mysql # not compatible
query I rowsort label-1695
SELECT ALL cor0.col1 / - 27 + + col0 FROM tab2 AS cor0
----
6
76
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col0 col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - col0 * + 3 + - 62 AS col2 FROM tab0 AS cor0
----
-134
-167
-329

query I rowsort
SELECT DISTINCT + 15 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
15

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 - 19 * col1 col1 FROM tab1 AS cor0
----
-133
-151
-440

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1700
SELECT DISTINCT col0 + CAST( NULL AS SIGNED ) / - ( col0 ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1700
SELECT DISTINCT col0 + CAST ( NULL AS INTEGER ) / - ( col0 ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col2 * col1 + - 16 + + col2 AS col2 FROM tab0 AS cor0
----
2855
7528
82

query I rowsort
SELECT + col1 * + col2 - 19 * col0 AS col2 FROM tab0 AS cor0
----
-568
2382
5771

onlyif mysql # use DIV operator for integer division
query I rowsort label-1703
SELECT col2 DIV - 59 + - col1 AS col0 FROM tab2 AS cor0
----
-17
-31
-59

skipif mysql # not compatible
query I rowsort label-1703
SELECT col2 / - 59 + - col1 AS col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT + col2 + + 24 FROM tab1 AS cor0
----
120
78
81

query I rowsort
SELECT cor0.col1 * + ( cor0.col1 ) FROM tab2, tab1 AS cor0
----
9 values hashing to ae5946db6904798b8afac35f5777bb79

query I rowsort
SELECT 27 FROM tab2, tab0, tab1 cor0
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

query I rowsort
SELECT col2 * col2 * + ( col1 + - tab0.col0 ) FROM tab0
----
13448
62
67518

query I rowsort
SELECT - 89 * col0 AS col0 FROM tab2
----
-623
-6942
-7031

query I rowsort
SELECT DISTINCT - 69 * + 6 - cor0.col1 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
-424
-427
-440

query I rowsort
SELECT - cor0.col1 * - 47 AS col2 FROM tab0 AS cor0
----
4042
4277
4559

onlyif mysql # use DIV operator for integer division
query I rowsort label-1711
SELECT col2 DIV CAST( ( - col0 ) AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-1711
SELECT col2 / CAST ( ( - col0 ) AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-1
-18
0

query I rowsort
SELECT DISTINCT 20 AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
20

query I rowsort
SELECT + + col2 + cor0.col0 * - col0 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT ALL ( + 25 * col0 ) FROM tab1
----
1600
2000
75

onlyif mysql # use DIV operator for integer division
query I rowsort label-1715
SELECT ALL col1 + + col0 DIV + col0 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-1715
SELECT ALL col1 + + col0 / + col0 FROM tab0
----
87
92
98

query I rowsort
SELECT - ( 35 ) FROM tab2, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 6d967b3bac2e01a0318865f682f9a97b

query I rowsort
SELECT 53 - - ( - col2 ) AS col1 FROM tab0 AS cor0
----
-29
20
52

query I rowsort
SELECT + - cor0.col2 + + cor0.col1 AS col1 FROM tab1 AS cor0
----
-28
-47
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1719
SELECT - + CAST( - col1 AS SIGNED ) + + col2 * cor0.col2 * + col0 AS col1 FROM tab1 cor0
----
207946
737293
8774

skipif mysql # not compatible
query I rowsort label-1719
SELECT - + CAST ( - col1 AS INTEGER ) + + col2 * cor0.col2 * + col0 AS col1 FROM tab1 cor0
----
207946
737293
8774

query I rowsort
SELECT ( col1 ) * + col2 + 73 AS col2 FROM tab2 cor0
----
1607
719
910

query I rowsort
SELECT ALL 32 * + 18 * + col0 AS col0 FROM tab1 AS cor0
----
1728
36864
46080

query I rowsort
SELECT DISTINCT + ( col2 ) + col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + + col1 * + 61 AS col0 FROM tab0 cor0
----
5246
5551
5917

query I rowsort
SELECT col2 + + col2 * col2 AS col2 FROM tab1 cor0
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-1725
SELECT DISTINCT + col0 DIV + 48 FROM tab2 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-1725
SELECT DISTINCT + col0 / + 48 FROM tab2 AS cor0
----
0
1

query I rowsort
SELECT DISTINCT - col2 * col1 - col1 FROM tab1 AS cor0
----
-1261
-1430
-580

onlyif mysql # use DIV operator for integer division
query I rowsort label-1727
SELECT - + col1 + col0 DIV ( col0 ) AS col0 FROM tab2 AS cor0
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-1727
SELECT - + col1 + col0 / ( col0 ) AS col0 FROM tab2 AS cor0
----
-16
-30
-58

query I rowsort
SELECT - 42 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 9894093f29c0defae91347934f060329

query I rowsort
SELECT + tab1.col2 + - 57 FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to d44dd80189718172f9bf9e6f1e84a324

query I rowsort
SELECT - 51 - + col0 AS col2 FROM tab1 AS cor0
----
-115
-131
-54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1731
SELECT col0 / + cor0.col0 - CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1731
SELECT col0 / + cor0.col0 - CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1732
SELECT + col1 * col1 + - CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1732
SELECT + col1 * col1 + - CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + - col2 - - 15 col0 FROM tab0
----
-104
-158
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 52 * col2 col2 FROM tab0 AS cor0
----
-1716
-4264
-52

query I rowsort
SELECT ALL + + 12 + + col1 * - 6 AS col2 FROM tab0 AS cor0
----
-504
-534
-570

query I rowsort
SELECT DISTINCT + 27 * - col0 * col2 FROM tab0 AS cor0
----
-197046
-21384
-945

query I rowsort
SELECT 46 * - col1 - - ( 51 ) AS col1 FROM tab0 AS cor0
----
-3905
-4135
-4411

skipif mysql # not compatible
query I rowsort
SELECT - col2 * cor0.col1 - - CAST ( - col1 AS REAL ) AS col2 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT ALL - col2 * 3 FROM tab2 AS cor0
----
-114
-78
-81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1740
SELECT ALL + + col1 + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1740
SELECT ALL + + col1 + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * cor0.col2 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL - - col1 * - 51 FROM tab0 cor0
----
-4386
-4641
-4947

query I rowsort
SELECT ALL - col1 + - ( + cor0.col2 ) * + cor0.col2 AS col1 FROM tab1 AS cor0
----
-2942
-3259
-9229

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col2 ) * - col1 col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT ALL - ( + cor0.col1 ) AS col0 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT DISTINCT 3 AS col2 FROM tab2 AS cor0
----
3

query I rowsort
SELECT ALL - - 52 * + 90 FROM tab2 AS cor0
----
4680
4680
4680

query I rowsort
SELECT + 19 * col0 AS col2 FROM tab0 AS cor0
----
1691
456
665

query I rowsort
SELECT DISTINCT - 75 AS col0 FROM tab0, tab1 AS cor0
----
-75

query I rowsort
SELECT DISTINCT - + 38 AS col2 FROM tab0 AS cor0
----
-38

onlyif mysql # use DIV operator for integer division
query I rowsort label-1751
SELECT - col1 DIV - cor0.col1 + - col2 - - 10 FROM tab1 cor0
----
-43
-46
-85

skipif mysql # not compatible
query I rowsort label-1751
SELECT - col1 / - cor0.col1 + - col2 - - 10 FROM tab1 cor0
----
-43
-46
-85

query I rowsort
SELECT ALL - col0 * 34 AS col2 FROM tab1
----
-102
-2176
-2720

onlyif mysql # use DIV operator for integer division
query I rowsort label-1753
SELECT - tab1.col0 DIV + tab1.col0 AS col0 FROM tab1
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-1753
SELECT - tab1.col0 / + tab1.col0 AS col0 FROM tab1
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + 71 ) * col1 col2 FROM tab1 AS cor0
----
1846
710
923

query I rowsort
SELECT ALL - 82 AS col2 FROM tab0
----
-82
-82
-82

query I rowsort
SELECT ALL + col1 * - ( - 97 ) FROM tab2 AS cor0
----
1649
3007
5723

query I rowsort
SELECT ALL - col1 + 16 FROM tab2 AS cor0
----
-1
-15
-43

query I rowsort
SELECT DISTINCT + + col2 * - ( col2 ) * - col1 AS col2 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT ALL + - col1 + + col2 * + col0 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT + col0 * 97 FROM tab2 AS cor0
----
679
7566
7663

query I rowsort
SELECT ALL - 10 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to f68f33032846e21ee6b2c668fc10355e

query I rowsort
SELECT DISTINCT tab2.col0 + + 74 FROM tab2, tab2 cor0
----
152
153
81

query I rowsort
SELECT + col0 * + 19 AS col2 FROM tab2 AS cor0
----
133
1482
1501

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 col0 FROM tab2 cor0
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-1765
SELECT ALL col0 DIV + cor0.col1 AS col1 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-1765
SELECT ALL col0 / + cor0.col1 AS col1 FROM tab1 AS cor0
----
0
6
6

query I rowsort
SELECT ALL - + col2 - - ( + 79 ) FROM tab1 AS cor0
----
-17
22
25

query I rowsort
SELECT DISTINCT + col2 + - col0 - col2 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-1768
SELECT DISTINCT - col1 + - col0 DIV + col0 FROM tab2 AS cor0
----
-18
-32
-60

skipif mysql # not compatible
query I rowsort label-1768
SELECT DISTINCT - col1 + - col0 / + col0 FROM tab2 AS cor0
----
-18
-32
-60

query I rowsort
SELECT col0 + - 9 FROM tab1 AS cor0
----
-6
55
71

query I rowsort
SELECT ALL - col0 + - col0 * + cor0.col1 AS col2 FROM tab2 cor0
----
-1422
-224
-4680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 21 col0 FROM tab1 AS cor0
----
-21
-21
-21

query I rowsort
SELECT 56 * col2 * col1 FROM tab2 AS cor0
----
36176
46872
85904

query I rowsort
SELECT ALL - 8 * + col0 AS col1 FROM tab2 AS cor0
----
-56
-624
-632

query I rowsort
SELECT col0 * - 34 + + col2 FROM tab2
----
-211
-2626
-2648

query I rowsort
SELECT ALL - - 69 AS col0 FROM tab1 AS cor0
----
69
69
69

query I rowsort
SELECT ALL - - cor0.col0 * col1 * - col0 + + col0 + - col0 * + 37 FROM tab2 cor0
----
-108941
-1771
-361764

query I rowsort
SELECT DISTINCT + - 6 + col1 * 59 FROM tab0 AS cor0
----
5068
5363
5717

query I rowsort
SELECT 10 * col1 AS col0 FROM tab2 AS cor0
----
170
310
590

query I rowsort
SELECT DISTINCT + - 8 AS col2 FROM tab1 AS cor0
----
-8

query I rowsort
SELECT - 33 * 11 + col2 * col0 FROM tab0
----
-328
429
6935

query I rowsort
SELECT DISTINCT - 98 AS col1 FROM tab0 cor0
----
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + col0 col0 FROM tab1
----
121
176
57

query I rowsort
SELECT - col1 * - col2 + + col1 AS col0 FROM tab1
----
1261
1430
580

query I rowsort
SELECT ALL 56 + + col1 + - col0 AS col1 FROM tab2
----
-6
37
80

query I rowsort
SELECT DISTINCT - 38 + col1 FROM tab0
----
48
53
59

query I rowsort
SELECT ALL - col1 + col1 + col0 AS col1 FROM tab2
----
7
78
79

query I rowsort
SELECT DISTINCT cor0.col0 * - 45 AS col0 FROM tab0, tab0 cor0
----
-1080
-1575
-4005

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 78 * - tab1.col2 col2 FROM tab1
----
-4212
-4446
-7488

query I rowsort
SELECT ALL + ( - col0 ) * col0 AS col2 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT tab0.col2 + - col2 * col2 * + tab0.col0 + + col1 * + col0 FROM tab0
----
-24039
-590255
3361

query I rowsort
SELECT DISTINCT - 56 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
-56

query I rowsort
SELECT ALL - col2 + - tab0.col0 * col0 + 69 FROM tab0
----
-1157
-540
-7934

query I rowsort
SELECT ALL - cor1.col1 + - cor1.col1 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 4a21fff066040168fa2a1bf702533e5d

onlyif mysql # use DIV operator for integer division
query I rowsort label-1794
SELECT DISTINCT + col2 DIV + col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-1794
SELECT DISTINCT + col2 / + col1 FROM tab0
----
0

query I rowsort
SELECT DISTINCT col0 * 47 * + col1 FROM tab0 AS cor0
----
159565
380653
97008

onlyif mysql # use DIV operator for integer division
query I rowsort label-1796
SELECT DISTINCT + col2 DIV CAST( - 54 AS SIGNED ) col2 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1796
SELECT DISTINCT + col2 / CAST ( - 54 AS INTEGER ) col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT + - col2 * ( + col0 ) AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT + + col0 + + col0 + col0 AS col2 FROM tab1 AS cor0
----
192
240
9

query I rowsort
SELECT ALL 13 AS col1 FROM tab0
----
13
13
13

query I rowsort
SELECT ALL col0 + - cor0.col0 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + col1 * cor0.col0 * - col1 + col2 * col1 FROM tab2 cor0
----
23477
273052
7564

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1802
SELECT DISTINCT + - CAST( col2 AS SIGNED ) - col0 FROM tab2 AS cor0
----
-104
-117
-34

skipif mysql # not compatible
query I rowsort label-1802
SELECT DISTINCT + - CAST ( col2 AS INTEGER ) - col0 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1803
SELECT DISTINCT 55 + col2 * + col2 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1803
SELECT DISTINCT 55 + col2 * + col2 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + col0 - + col1 AS col1 FROM tab2 cor0
----
-24
19
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1805
SELECT ALL + - CAST( NULL AS SIGNED ) * - 22 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1805
SELECT ALL + - CAST ( NULL AS INTEGER ) * - 22 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 40 + + col2 FROM tab2 cor0
----
-13
-14
-2

query I rowsort
SELECT DISTINCT col1 * + col2 + - col1 - - col0 FROM tab0 AS cor0
----
2776
35
7460

query I rowsort
SELECT ALL + col2 * col1 + 7 * col2 + col0 AS col0 FROM tab0 AS cor0
----
139
3093
8125

query I rowsort
SELECT ALL col1 + col1 - 63 * + col1 FROM tab2 cor0
----
-1037
-1891
-3599

query I rowsort
SELECT + col0 + + col2 * + 17 FROM tab0 AS cor0
----
1483
52
585

query I rowsort
SELECT ALL + - 50 * cor0.col1 + col2 AS col0 FROM tab0 AS cor0
----
-4267
-4468
-4849

query I rowsort
SELECT - 50 + cor0.col2 FROM tab2 AS cor0
----
-12
-23
-24

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + col2 * 89 col0 FROM tab0 AS cor0
----
186
3023
7389

query I rowsort
SELECT ALL - col0 * - col0 - + col2 * col0 FROM tab0
----
-216
1190
623

query I rowsort
SELECT col1 - col1 * - ( col1 ) AS col1 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT + col2 * col1 - + ( + 19 + col2 ) * - col1 FROM tab1 AS cor0
----
1330
2743
3302

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 - col2 * col1 col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT - + 29 + - col2 AS col2 FROM tab1 AS cor0
----
-125
-83
-86

query I rowsort
SELECT DISTINCT - 53 * 25 AS col2 FROM tab1 AS cor0
----
-1325

query I rowsort
SELECT - col2 * col0 * col2 AS col1 FROM tab2 AS cor0
----
-114076
-5103
-52728

query I rowsort
SELECT ( ( col1 ) ) FROM tab1 cor0
----
10
13
26

query I rowsort
SELECT 35 * - col1 * col0 FROM tab0
----
-118825
-283465
-72240

query I rowsort
SELECT DISTINCT - cor0.col1 * + col2 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - col1 + + col2 + - 24 * cor0.col1 FROM tab1 AS cor0
----
-193
-229
-596

query I rowsort
SELECT DISTINCT - cor0.col1 * - cor0.col2 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL + 97 + - cor0.col2 FROM tab1 AS cor0
----
1
40
43

query I rowsort
SELECT - col0 * - ( - 21 ) FROM tab0 cor0
----
-1869
-504
-735

query I rowsort
SELECT cor0.col0 + 6 AS col2 FROM tab1 AS cor0
----
70
86
9

query I rowsort
SELECT 31 AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

query I rowsort
SELECT ALL + tab2.col0 * + tab2.col2 AS col2 FROM tab2
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-1831
SELECT + + cor0.col1 DIV + col0 FROM tab1 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-1831
SELECT + + cor0.col1 / + col0 FROM tab1 AS cor0
----
0
0
8

query I rowsort
SELECT - cor0.col0 * ( - col2 + + col2 ) AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1833
SELECT + cor0.col0 DIV + ( + 69 ) FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-1833
SELECT + cor0.col0 / + ( + 69 ) FROM tab2 AS cor0
----
0
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-1834
SELECT - cor0.col1 DIV 90 AS col0 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1834
SELECT - cor0.col1 / 90 AS col0 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT 89 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 860d55eb6785972467218a9c3badb5ad

query I rowsort
SELECT DISTINCT col2 * - ( + col2 ) * + col0 AS col1 FROM tab2
----
-114076
-5103
-52728

query I rowsort
SELECT DISTINCT - ( 0 ) FROM tab1 AS cor0
----
0

query I rowsort
SELECT + col0 + 62 AS col0 FROM tab2 AS cor0
----
140
141
69

query I rowsort
SELECT + ( + col0 ) AS col1 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - ( - col2 ) + col2 * col2 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL 35 FROM tab0, tab2 cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

onlyif mysql # use DIV operator for integer division
query I rowsort label-1842
SELECT - col0 DIV col2 - 94 FROM tab0
----
-129
-94
-95

skipif mysql # not compatible
query I rowsort label-1842
SELECT - col0 / col2 - 94 FROM tab0
----
-129
-94
-95

onlyif mysql # use DIV operator for integer division
query I rowsort label-1843
SELECT ALL col0 DIV + 7 AS col2 FROM tab0
----
12
3
5

skipif mysql # not compatible
query I rowsort label-1843
SELECT ALL col0 / + 7 AS col2 FROM tab0
----
12
3
5

query I rowsort
SELECT 59 * + 43 FROM tab0
----
2537
2537
2537

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 - - ( col1 ) col1 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + cor0.col2 * col1 AS col1 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT ( - tab1.col2 ) + + col1 * col2 * - col1 AS col1 FROM tab1
----
-16320
-36558
-5757

query I rowsort
SELECT DISTINCT + - 42 * col1 FROM tab1 AS cor0
----
-1092
-420
-546

query I rowsort
SELECT + + col0 + 65 AS col0 FROM tab2 AS cor0
----
143
144
72

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1850
SELECT ALL + CAST( NULL AS DECIMAL ) + 66 * col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1850
SELECT ALL + CAST ( NULL AS REAL ) + 66 * col1 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - ( col0 ) * - col1 - cor0.col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

query I rowsort
SELECT ALL + 18 * col0 FROM tab0 AS cor0
----
1602
432
630

query I rowsort
SELECT DISTINCT col2 * 88 AS col0 FROM tab0 cor0
----
2904
7216
88

query I rowsort
SELECT DISTINCT + - col1 + + col0 * + col2 FROM tab2 AS cor0
----
158
1969
2985

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1855
SELECT ( ( + col1 ) ) / CAST( NULL AS SIGNED ) + col2 + cor0.col1 * - ( col2 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1855
SELECT ( ( + col1 ) ) / CAST ( NULL AS INTEGER ) + col2 + cor0.col1 * - ( col2 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + col2 + + col0 * col1 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT ALL 1 + + col1 FROM tab0
----
87
92
98

query I rowsort
SELECT - 42 * col1 * col2 + + col2 FROM tab1 AS cor0
----
-23883
-52320
-58914

query I rowsort
SELECT + - 23 + col1 FROM tab2 cor0
----
-6
36
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-1860
SELECT - col1 DIV col2 + + 13 AS col2 FROM tab1 AS cor0
----
13
13
13

skipif mysql # not compatible
query I rowsort label-1860
SELECT - col1 / col2 + + 13 AS col2 FROM tab1 AS cor0
----
13
13
13

query I rowsort
SELECT DISTINCT - col2 + 86 FROM tab0 AS cor0
----
4
53
85

query I rowsort
SELECT ALL - 70 AS col1 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to c2a2994a4e94583683ccda2cc098c58f

query I rowsort
SELECT DISTINCT + col2 * 17 + col1 + col0 * + col0 FROM tab0 AS cor0
----
1223
1339
9406

query I rowsort
SELECT DISTINCT col2 + + col0 * - col1 AS col1 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT 46 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT ALL - ( col2 ) * - col1 - 54 AS col1 FROM tab1 AS cor0
----
1194
1350
516

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1867
SELECT - CAST( - col0 AS SIGNED ) * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-1867
SELECT - CAST ( - col0 AS INTEGER ) * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - - ( - ( col1 ) ) AS col1 FROM tab2 cor0
----
-17
-31
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1869
SELECT ALL + + CAST( + col0 AS SIGNED ) + + cor0.col0 * ( ( col2 ) * - col2 ) FROM tab2 AS cor0
----
-113997
-5096
-52650

skipif mysql # not compatible
query I rowsort label-1869
SELECT ALL + + CAST ( + col0 AS INTEGER ) + + cor0.col0 * ( ( col2 ) * - col2 ) FROM tab2 AS cor0
----
-113997
-5096
-52650

query I rowsort
SELECT DISTINCT col2 * 81 FROM tab1 AS cor0
----
4374
4617
7776

query I rowsort
SELECT - ( col2 ) - + col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT DISTINCT + ( - col0 ) * + col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-1873
SELECT + 95 * 68 + - col1 DIV - col0 col2 FROM tab2 AS cor0
----
6460
6460
6464

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-1873
SELECT + 95 * 68 + - col1 / - col0 col2 FROM tab2 AS cor0
----
6460
6460
6464

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( - col0 ) + + col0 col1 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1875
SELECT ALL + - CAST( - cor0.col2 AS SIGNED ) - cor0.col1 FROM tab1 AS cor0
----
28
47
83

skipif mysql # not compatible
query I rowsort label-1875
SELECT ALL + - CAST ( - cor0.col2 AS INTEGER ) - cor0.col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - col1 * col2 * col0 + - 21 * ( col2 ) AS col2 FROM tab0 AS cor0
----
-3416
-665840
-68805

query I rowsort
SELECT DISTINCT 92 * col2 + + col0 * col0 FROM tab2 AS cor0
----
2533
8476
9737

query I rowsort
SELECT DISTINCT - col2 * + cor0.col1 AS col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - 38 * col1 + + col0 FROM tab2 AS cor0
----
-1171
-2164
-567

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1880
SELECT ALL - col2 * cor0.col0 + - CAST( NULL AS SIGNED ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1880
SELECT ALL - col2 * cor0.col0 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * col0 * 84 + + col0 AS col0 FROM tab1 AS cor0
----
13611
306496
645200

query I rowsort
SELECT ALL ( cor0.col2 ) + + col1 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1883
SELECT CAST( 75 AS SIGNED ) * - col2 + col1 FROM tab0
----
-2389
-6059
22

skipif mysql # not compatible
query I rowsort label-1883
SELECT CAST ( 75 AS INTEGER ) * - col2 + col1 FROM tab0
----
-2389
-6059
22

query I rowsort
SELECT DISTINCT + col2 + 64 FROM tab1
----
118
121
160

query I rowsort
SELECT ALL + ( + col2 ) * ( col1 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT + col0 * cor0.col1 + ( + cor0.col2 ) + col2 FROM tab2 AS cor0
----
1419
271
4654

query I rowsort
SELECT ALL col1 + - col2 * col2 AS col0 FROM tab0 cor0
----
-1003
-6633
96

query I rowsort
SELECT DISTINCT + - col1 - - ( col0 ) FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT DISTINCT + + col1 * col0 + + 28 FROM tab2 AS cor0
----
1371
245
4630

query I rowsort
SELECT DISTINCT col1 * - 98 + - 96 * + col0 AS col1 FROM tab2
----
-13270
-3710
-9250

onlyif mysql # use DIV operator for integer division
query I rowsort label-1891
SELECT + col2 DIV col0 + - col1 FROM tab0
----
-85
-91
-97

skipif mysql # not compatible
query I rowsort label-1891
SELECT + col2 / col0 + - col1 FROM tab0
----
-85
-91
-97

query I rowsort
SELECT + col0 * col1 + 33 * - col2 FROM tab1 AS cor0
----
-1241
-1704
-2128

query I rowsort
SELECT - - col0 * col2 - - col1 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT ALL + + col1 * 75 FROM tab1 AS cor0
----
1950
750
975

query I rowsort
SELECT ALL col0 * ( col1 ) AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - + cor0.col2 * 25 FROM tab1 AS cor0
----
-1350
-1425
-2400

query I rowsort
SELECT ( 29 ) FROM tab1, tab2 AS cor0
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT ALL + col0 * - 60 FROM tab1 AS cor0
----
-180
-3840
-4800

query I rowsort
SELECT ALL + cor0.col1 * + col0 AS col2 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT - - col0 * + 38 * + col2 AS col1 FROM tab1 AS cor0
----
138624
291840
6156

onlyif mysql # use DIV operator for integer division
query I rowsort label-1901
SELECT + col1 DIV - cor0.col2 FROM tab0 AS cor0
----
-1
-2
-97

skipif mysql # not compatible
query I rowsort label-1901
SELECT + col1 / - cor0.col2 FROM tab0 AS cor0
----
-1
-2
-97

query I rowsort
SELECT ALL + - col1 + - col0 * col2 AS col2 FROM tab1 AS cor0
----
-188
-3658
-7693

query I rowsort
SELECT 47 + cor0.col1 AS col2 FROM tab2 AS cor0
----
106
64
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-1904
SELECT DISTINCT + col1 * col2 DIV col0 FROM tab1 AS cor0
----
15
468
8

skipif mysql # not compatible
query I rowsort label-1904
SELECT DISTINCT + col1 * col2 / col0 FROM tab1 AS cor0
----
15
468
8

query I rowsort
SELECT - tab1.col2 * + 33 * - col0 AS col1 FROM tab1
----
120384
253440
5346

query I rowsort
SELECT DISTINCT tab1.col1 - - col0 FROM tab1
----
29
74
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-1907
SELECT ALL + - col0 DIV 72 AS col1 FROM tab2 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-1907
SELECT ALL + - col0 / 72 AS col1 FROM tab2 AS cor0
----
-1
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-1908
SELECT + col0 * + col0 + col2 DIV ( - 87 ) AS col2 FROM tab2 AS cor0
----
49
6084
6241

skipif mysql # not compatible
query I rowsort label-1908
SELECT + col0 * + col0 + col2 / ( - 87 ) AS col2 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1909
SELECT - col2 + col0 * col0 * + CAST( + col1 * - col0 AS SIGNED ) FROM tab1 cor0
----
-2621497
-6656096
-756

skipif mysql # not compatible
query I rowsort label-1909
SELECT - col2 + col0 * col0 * + CAST ( + col1 * - col0 AS INTEGER ) FROM tab1 cor0
----
-2621497
-6656096
-756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 31 * col0 col2 FROM tab2 AS cor0
----
217
2418
2449

query I rowsort
SELECT + col2 + - col0 + + col1 AS col0 FROM tab1
----
29
3
77

query I rowsort
SELECT ALL - col0 + col1 * - col1 AS col1 FROM tab2
----
-3559
-368
-968

query I rowsort
SELECT DISTINCT col0 + 23 * + ( + col1 ) FROM tab0
----
2002
2182
2266

query I rowsort
SELECT - ( - col2 ) - + col0 * - col1 AS col1 FROM tab1 AS cor0
----
1136
132
697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * + cor0.col0 col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - - 22 - 34 FROM tab2 AS cor0
----
-12
-12
-12

query I rowsort
SELECT DISTINCT 77 * - col2 FROM tab1 AS cor0
----
-4158
-4389
-7392

query I rowsort
SELECT - cor0.col1 + - 62 * + col2 FROM tab1 AS cor0
----
-3374
-3544
-5965

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 76 + - col0 col1 FROM tab0 cor0
----
-13
41
52

query I rowsort
SELECT - - col2 * + col0 - col2 * - col2 AS col2 FROM tab2 AS cor0
----
2704
4446
918

query I rowsort
SELECT - - 92 * + 1 FROM tab2 AS cor0
----
92
92
92

query I rowsort
SELECT - 64 FROM tab2, tab0 cor0
----
9 values hashing to 601ec439a72fb4786a9cb7a6547ace5e

query I rowsort
SELECT ALL 12 + - col2 * col1 + - col1 AS col2 FROM tab1
----
-1249
-1418
-568

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 43 + col1 col1 FROM tab0
----
129
134
140

onlyif mysql # use DIV operator for integer division
query I rowsort label-1925
SELECT DISTINCT - col2 DIV + col2 + tab0.col2 DIV - col0 AS col0 FROM tab0
----
-1
-2

skipif mysql # not compatible
query I rowsort label-1925
SELECT DISTINCT - col2 / + col2 + tab0.col2 / - col0 AS col0 FROM tab0
----
-1
-2

query I rowsort
SELECT + 26 * - 40 * col1 AS col1 FROM tab1
----
-10400
-13520
-27040

onlyif mysql # use DIV operator for integer division
query I rowsort label-1927
SELECT col0 DIV 47 FROM tab1
----
0
1
1

skipif mysql # not compatible
query I rowsort label-1927
SELECT col0 / 47 FROM tab1
----
0
1
1

query I rowsort
SELECT 94 * 25 + col0 * + col1 + col1 AS col2 FROM tab1
----
2454
3000
3403

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + col2 * + col1 col1 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT tab1.col1 * + 92 + col1 AS col2 FROM tab1
----
1209
2418
930

query I rowsort
SELECT ALL col2 + ( - col2 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + 56 * - col2 + + col0 * col1 AS col0 FROM tab0 cor0
----
216
3339
3507

onlyif mysql # use DIV operator for integer division
query I rowsort label-1933
SELECT col2 DIV + tab1.col0 AS col1 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-1933
SELECT col2 / + tab1.col0 AS col1 FROM tab1
----
0
1
18

query I rowsort
SELECT DISTINCT col1 * col1 * + col0 FROM tab2
----
22831
271518
6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-1935
SELECT ALL - ( + col2 ) DIV + tab0.col1 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-1935
SELECT ALL - ( + col2 ) / + tab0.col1 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT col2 * col2 + ( col0 * col1 ) FROM tab1
----
10256
2994
3889

query I rowsort
SELECT - col1 * col2 + - col0 AS col0 FROM tab0
----
-132
-2862
-7551

query I rowsort
SELECT + - col1 * col2 + col1 AS col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT 8 - - col1 FROM tab1
----
18
21
34

query I rowsort
SELECT ALL + 89 AS col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 860d55eb6785972467218a9c3badb5ad

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 52 col2 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to e8a5cb10c0973a78554f344d4f6e7e74

query I rowsort
SELECT + 90 * + col1 * col0 FROM tab0
----
185760
305550
728910

query I rowsort
SELECT ALL + + cor0.col1 + 8 AS col0 FROM tab2 AS cor0
----
25
39
67

query I rowsort
SELECT ALL - - col2 * + 59 + - col0 FROM tab0 cor0
----
1923
24
4749

query I rowsort
SELECT + - cor0.col2 * col0 AS col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL col2 + + col0 + col1 * - col2 * + col2 AS col0 FROM tab0 cor0
----
-61
-611713
-93597

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1947
SELECT ALL - ( + col1 ) * - CAST( NULL AS SIGNED ) * col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1947
SELECT ALL - ( + col1 ) * - CAST ( NULL AS INTEGER ) * col1 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT col0 - - col1 * 15 * + col0 FROM tab1
----
1173
15680
9664

query I rowsort
SELECT DISTINCT - 50 * col0 AS col1 FROM tab0
----
-1200
-1750
-4450

query I rowsort
SELECT 15 AS col0 FROM tab1 cor0
----
15
15
15

query I rowsort
SELECT 66 + col2 AS col2 FROM tab2 AS cor0
----
104
92
93

query I rowsort
SELECT + col0 * col2 + + col1 AS col0 FROM tab2 AS cor0
----
2087
220
3019

query I rowsort
SELECT DISTINCT - col0 * col2 + + 26 FROM tab2 AS cor0
----
-163
-2002
-2976

query I rowsort
SELECT ALL - cor0.col0 + - col1 AS col2 FROM tab2 AS cor0
----
-137
-38
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-1955
SELECT - col2 DIV 97 + - col0 * + col0 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif mysql # not compatible
query I rowsort label-1955
SELECT - col2 / 97 + - col0 * + col0 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT + col2 * ( + col1 ) + cor0.col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL - + 83 FROM tab1, tab0, tab2 cor0
----
27 values hashing to 77a48ad722db122f51d5ef36604ad843

query I rowsort
SELECT col1 * + tab1.col0 * - ( ( col1 ) ) AS col0 FROM tab1
----
-13520
-2028
-6400

onlyif mysql # use DIV operator for integer division
query I rowsort label-1959
SELECT + col2 + cor0.col1 DIV + col1 FROM tab2 cor0
----
27
28
39

skipif mysql # not compatible
query I rowsort label-1959
SELECT + col2 + cor0.col1 / + col1 FROM tab2 cor0
----
27
28
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1960
SELECT DISTINCT - - col2 + CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-1960
SELECT DISTINCT - - col2 + CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - cor0.col0 + + col1 * col1 * col2 AS col0 FROM tab1 cor0
----
16144
36501
5636

query I rowsort
SELECT cor0.col0 * - 72 AS col1 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 560abd10eb262d1ae4d41a68a32a0e78

query I rowsort
SELECT col1 * + 98 FROM tab1 AS cor0
----
1274
2548
980

query I rowsort
SELECT + 73 * 87 FROM tab0 AS cor0
----
6351
6351
6351

onlyif mysql # use DIV operator for integer division
query I rowsort label-1965
SELECT + ( - col2 ) DIV col0 AS col1 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-1965
SELECT + ( - col2 ) / col0 AS col1 FROM tab2 AS cor0
----
-3
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + ( col2 ) * + col1 col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT ALL - col2 * + 3 AS col0 FROM tab0
----
-246
-3
-99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1968
SELECT ALL + col2 * + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1968
SELECT ALL + col2 * + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT + 50 * + col2 AS col1 FROM tab0 AS cor0
----
1650
4100
50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1970
SELECT - col0 / + CAST( NULL AS SIGNED ) + - col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1970
SELECT - col0 / + CAST ( NULL AS INTEGER ) + - col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * + col2 + col1 * - col1 AS col1 FROM tab1 cor0
----
-1417
-2080
-670

query I rowsort
SELECT - 34 FROM tab0, tab1 cor0
----
9 values hashing to 40442a74794ded4c78101eefe525a5bb

query I rowsort
SELECT col0 * + cor0.col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT + + 60 * col2 * + col0 + - ( - col0 ) AS col2 FROM tab1 AS cor0
----
218944
460880
9723

query I rowsort
SELECT ALL - + col1 * + col1 + col2 AS col2 FROM tab2 cor0
----
-251
-3455
-934

query I rowsort
SELECT DISTINCT + - 53 FROM tab1 AS cor0
----
-53

onlyif mysql # use DIV operator for integer division
query I rowsort label-1977
SELECT DISTINCT + col0 DIV col2 + + col1 * + col1 + - col0 FROM tab0 cor0
----
7372
8193
9409

skipif mysql # not compatible
query I rowsort label-1977
SELECT DISTINCT + col0 / col2 + + col1 * + col1 + - col0 FROM tab0 cor0
----
7372
8193
9409

query I rowsort
SELECT ALL 87 + cor0.col2 FROM tab0 AS cor0
----
120
169
88

query I rowsort
SELECT DISTINCT col2 * col2 + - col0 * + col2 AS col0 FROM tab1 AS cor0
----
-399
1536
2754

onlyif mysql # use DIV operator for integer division
query I rowsort label-1980
SELECT ALL 89 DIV - col0 + col0 * - col1 FROM tab0 AS cor0
----
-2067
-3397
-8100

skipif mysql # not compatible
query I rowsort label-1980
SELECT ALL 89 / - col0 + col0 * - col1 FROM tab0 AS cor0
----
-2067
-3397
-8100

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-1981
SELECT ALL + CAST( NULL AS SIGNED ) * - 86 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-1981
SELECT ALL + CAST ( NULL AS INTEGER ) * - 86 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( 90 ) + col2 FROM tab2
----
-52
-63
-64

query I rowsort
SELECT DISTINCT tab1.col1 * ( col1 * 73 ) + - col1 FROM tab1
----
12324
49322
7290

query I rowsort
SELECT ALL - col1 + + tab0.col2 * + col1 AS col1 FROM tab0
----
0
2752
7371

onlyif mysql # use DIV operator for integer division
query I rowsort label-1985
SELECT DISTINCT 52 + col1 DIV - col1 FROM tab1
----
51

skipif mysql # not compatible
query I rowsort label-1985
SELECT DISTINCT 52 + col1 / - col1 FROM tab1
----
51

query I rowsort
SELECT 13 + tab0.col2 FROM tab0
----
14
46
95

query I rowsort
SELECT - + col1 * + cor0.col0 AS col2 FROM tab1 cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-1988
SELECT DISTINCT + + col2 DIV + col1 + ( col1 * col0 ) FROM tab1 AS cor0
----
1047
645
80

skipif mysql # not compatible
query I rowsort label-1988
SELECT DISTINCT + + col2 / + col1 + ( col1 * col0 ) FROM tab1 AS cor0
----
1047
645
80

query I rowsort
SELECT + col2 * + col2 * ( - cor0.col2 ) FROM tab1 cor0
----
-157464
-185193
-884736

query I rowsort
SELECT - - ( + cor0.col0 ) AS col1 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + cor0.col1 * - 66 AS col2 FROM tab2 AS cor0
----
-1122
-2046
-3894

query I rowsort
SELECT col0 + 59 * 3 - + tab0.col2 FROM tab0
----
168
184
211

query I rowsort
SELECT + col1 + col0 * + col2 AS col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT + col2 * - 3 - 87 FROM tab2 AS cor0
----
-165
-168
-201

query I rowsort
SELECT DISTINCT col1 - col0 * col1 AS col0 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT - col1 * + 45 FROM tab0
----
-3870
-4095
-4365

query IIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab2 cor2
----
972 values hashing to 42e69ecdafb3c81046bc5cb4c98b1666

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 cor0, tab0, tab1 cor1
----
972 values hashing to 465d072d2d9eababbfc8e88b82707474

query I rowsort
SELECT tab0.col1 * 9 + col0 * col0 * col1 + col1 * col1 * ( 12 ) AS col1 FROM tab0
----
139062
232606
821002

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col2 ) col0 FROM tab0 cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2001
SELECT + + ( col2 ) DIV col1 FROM tab1 cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-2001
SELECT + + ( col2 ) / col1 FROM tab1 cor0
----
2
5
7

query I rowsort
SELECT ALL col2 * - col0 + col0 AS col2 FROM tab1 AS cor0
----
-159
-3584
-7600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2003
SELECT ALL CAST( NULL AS SIGNED ) * + col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2003
SELECT ALL CAST ( NULL AS INTEGER ) * + col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 39 * 22 + + col2 * cor0.col0 FROM tab1 AS cor0
----
1020
4506
8538

query I rowsort
SELECT DISTINCT + - cor0.col1 + col2 * col2 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT col1 * col1 * + col2 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT 12 * + ( + cor0.col0 ) AS col1 FROM tab1 AS cor0
----
36
768
960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2008
SELECT - CAST( col1 AS SIGNED ) * + col0 + - col1 AS col1 FROM tab1 AS cor0
----
-104
-1053
-650

skipif mysql # not compatible
query I rowsort label-2008
SELECT - CAST ( col1 AS INTEGER ) * + col0 + - col1 AS col1 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT - col1 * + 10 - - col0 FROM tab1 AS cor0
----
-257
-36
-50

query I rowsort
SELECT ALL tab0.col1 - + 56 * - 8 FROM tab0
----
534
539
545

query I rowsort
SELECT DISTINCT + col0 - col1 * col2 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT - - cor0.col1 - col2 AS col2 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT - ( - 99 ) * + col2 FROM tab1 AS cor0
----
5346
5643
9504

query I rowsort
SELECT - + 8 * col0 * + cor0.col0 - col0 * ( cor0.col0 + + col2 ) FROM tab2 cor0
----
-56784
-59171
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-2015
SELECT col2 + ( - 98 ) DIV - col2 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-2015
SELECT col2 + ( - 98 ) / - col2 FROM tab1
----
55
58
97

query I rowsort
SELECT - 65 FROM tab0, tab0 AS cor0
----
9 values hashing to 744531575c1b6461ed2916d4940e4d23

query I rowsort
SELECT + - cor0.col1 + - col2 * - col2 FROM tab1 AS cor0
----
2890
3239
9203

query I rowsort
SELECT ALL col1 * + ( - cor0.col0 ) FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2019
SELECT ALL CAST( NULL AS SIGNED ) * col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2019
SELECT ALL CAST ( NULL AS INTEGER ) * col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 * + col1 + - col0 + + ( col1 + + col0 ) FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT + - ( col0 ) + + col1 + ( - ( cor0.col0 ) ) FROM tab0 AS cor0
----
-87
27
38

query I rowsort
SELECT + + cor0.col1 * 68 AS col1 FROM tab1 AS cor0
----
1768
680
884

query I rowsort
SELECT - - ( - col2 ) * + col0 + col2 + - col2 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - 23 + ( - col2 ) AS col1 FROM tab1 AS cor0
----
-119
-77
-80

query I rowsort
SELECT ALL + 67 AS col0 FROM tab0
----
67
67
67

query I rowsort
SELECT + - 96 FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c89b545346f99713888a7934e4caa539

query I rowsort
SELECT DISTINCT - col0 * col1 + - ( + 2 + cor0.col0 ) FROM tab1 AS cor0
----
-1122
-706
-83

query I rowsort
SELECT + ( + col2 ) + + 23 FROM tab0 AS cor0
----
105
24
56

query I rowsort
SELECT ALL + ( - col0 ) * 55 + + col2 FROM tab0 AS cor0
----
-1287
-1924
-4813

query I rowsort
SELECT ALL - col0 * - col0 + + col1 FROM tab1 cor0
----
35
4106
6413

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( cor0.col1 ) * col2 col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + + 20 + cor0.col0 FROM tab0 AS cor0
----
109
44
55

query I rowsort
SELECT ALL - + col1 + - cor0.col2 - col2 FROM tab1 AS cor0
----
-124
-134
-205

query I rowsort
SELECT + - 56 AS col2 FROM tab0 AS cor0
----
-56
-56
-56

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col0 * - col0 + + col2 col0 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT + col2 + 62 AS col2 FROM tab0 AS cor0
----
144
63
95

query I rowsort
SELECT ALL col0 * col1 - + 67 FROM tab0 AS cor0
----
1997
3328
8032

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2038
SELECT DISTINCT cor0.col0 / + col0 + ( - cor0.col1 + CAST( NULL AS SIGNED ) ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2038
SELECT DISTINCT cor0.col0 / + col0 + ( - cor0.col1 + CAST ( NULL AS INTEGER ) ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + 63 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2040
SELECT ALL + 45 DIV + 2 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

skipif mysql # not compatible
query I rowsort label-2040
SELECT ALL + 45 / + 2 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT DISTINCT col2 * - 83 + 9 AS col0 FROM tab2 AS cor0
----
-2149
-2232
-3145

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 92 col0 FROM tab0, tab1 AS cor0
----
92

query I rowsort
SELECT DISTINCT - + col2 + 80 AS col0 FROM tab1 AS cor0
----
-16
23
26

query I rowsort
SELECT - cor0.col2 FROM tab1, tab0 cor0, tab0 AS cor1
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT ALL cor0.col1 + - 55 AS col2 FROM tab0 AS cor0
----
31
36
42

query I rowsort
SELECT ALL col1 * col0 + + cor0.col1 * + col2 AS col0 FROM tab2 AS cor0
----
1054
1989
6136

query I rowsort
SELECT DISTINCT - cor0.col1 * + cor0.col1 + - 35 * - cor0.col0 AS col1 FROM tab2 cor0
----
-716
-751
2476

query I rowsort
SELECT - ( cor0.col0 ) + + col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - cor0.col1 + 52 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to ac0be5c09155cd211c4d961d06e284ab

onlyif mysql # use DIV operator for integer division
query I rowsort label-2050
SELECT - col0 + - col1 DIV 85 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-2050
SELECT - col0 + - col1 / 85 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT DISTINCT - 71 * + col1 FROM tab1
----
-1846
-710
-923

query I rowsort
SELECT DISTINCT 76 * col1 FROM tab1
----
1976
760
988

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2053
SELECT + - col2 * + CAST( 77 AS SIGNED ) FROM tab2 AS cor0
----
-2002
-2079
-2926

skipif mysql # not compatible
query I rowsort label-2053
SELECT + - col2 * + CAST ( 77 AS INTEGER ) FROM tab2 AS cor0
----
-2002
-2079
-2926

skipif mysql # not compatible
query I rowsort
SELECT - col2 * CAST ( ( col1 ) AS REAL ) AS col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT col0 * - 39 FROM tab1 AS cor0
----
-117
-2496
-3120

query I rowsort
SELECT 30 + + col1 FROM tab0
----
116
121
127

query I rowsort
SELECT - 0 AS col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT - col2 * + col0 * col0 FROM tab2 AS cor0
----
-1323
-158184
-237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-2059
SELECT - cor0.col0 DIV 65 FROM tab0, tab1 AS cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

skipif mysql # not compatible
query I rowsort label-2059
SELECT - cor0.col0 / 65 FROM tab0, tab1 AS cor0
----
9 values hashing to 721682d0719de924079c33bd72eef789

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + cor0.col2 * col0 col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT + - 11 + col0 + ( - col2 * col2 ) FROM tab0 AS cor0
----
-1076
-6646
23

query I rowsort
SELECT + 58 + - 4 AS col2 FROM tab1
----
54
54
54

query I rowsort
SELECT ALL 38 * col2 * col2 + ( + 20 + col1 ) FROM tab1
----
110854
123492
350241

query I rowsort
SELECT ALL + - col2 + col0 + col0 FROM tab1 AS cor0
----
-48
64
71

onlyif mysql # use DIV operator for integer division
query I rowsort label-2065
SELECT 87 DIV + col1 FROM tab1 AS cor0
----
3
6
8

skipif mysql # not compatible
query I rowsort label-2065
SELECT 87 / + col1 FROM tab1 AS cor0
----
3
6
8

query I rowsort
SELECT ALL - col1 + col1 * + cor0.col2 AS col0 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT ( col1 ) * cor0.col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab2, tab0 AS cor0, tab0 cor1
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - 0 AS col2 FROM tab2, tab2 AS cor0
----
0

query I rowsort
SELECT ALL col2 + + 63 AS col0 FROM tab0
----
145
64
96

query I rowsort
SELECT - 43 + 18 FROM tab1, tab0 AS cor0
----
9 values hashing to 40ac8fd000b2e49317aed2411077839e

query I rowsort
SELECT ALL + + 99 AS col0 FROM tab0, tab2, tab1 AS cor0, tab1
----
81 values hashing to c841a8d826151b422ecdb71db0250739

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( 89 ) col1 FROM tab2 AS cor0
----
89
89
89

query I rowsort
SELECT + - 53 AS col2 FROM tab0 AS cor0
----
-53
-53
-53

query I rowsort
SELECT DISTINCT + tab0.col1 AS col0 FROM tab0, tab2, tab1 cor0
----
86
91
97

query I rowsort
SELECT - col1 * 90 * + col1 FROM tab1
----
-15210
-60840
-9000

onlyif mysql # use DIV operator for integer division
query I rowsort label-2077
SELECT - col1 * col2 DIV col1 AS col0 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-2077
SELECT - col1 * col2 / col1 AS col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - cor0.col1 + cor0.col1 FROM tab2 cor0
----
0

query I rowsort
SELECT ALL + col1 + 12 AS col0 FROM tab1 AS cor0
----
22
25
38

query I rowsort
SELECT ALL - + col1 + - ( + col1 ) + - col2 FROM tab0 AS cor0
----
-195
-205
-264

query I rowsort
SELECT DISTINCT col1 + - 60 * col1 AS col1 FROM tab0 AS cor0
----
-5074
-5369
-5723

query I rowsort
SELECT + - 26 * - col0 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
-189748
-20592
-910

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 1 col2 FROM tab2 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2084
SELECT CAST( NULL AS SIGNED ) * col2 * col2 + ( col0 ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2084
SELECT CAST ( NULL AS INTEGER ) * col2 * col2 + ( col0 ) AS col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 54 + + 32 FROM tab1
----
-22

query I rowsort
SELECT DISTINCT + col0 * col0 * tab0.col2 + 57 AS col2 FROM tab0
----
1282
19065
649579

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 89 col1 FROM tab1, tab2 cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

query I rowsort
SELECT DISTINCT + 87 + + ( - col1 * + col2 ) + - col1 FROM tab0 AS cor0
----
-107
-2837
-7466

query I rowsort
SELECT - ( 48 ) AS col0 FROM tab1 AS cor0
----
-48
-48
-48

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 23 + 59 col1 FROM tab0 AS cor0
----
82
82
82

query I rowsort
SELECT ALL + - ( col0 ) + col2 * - col0 AS col2 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT ALL - 62 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
-186
-3968
-4960

query I rowsort
SELECT - - 5 AS col1 FROM tab2 AS cor0
----
5
5
5

query I rowsort
SELECT ALL + - cor0.col0 + 23 + + cor0.col0 FROM tab2 cor0
----
23
23
23

query I rowsort
SELECT ALL + - 30 + cor0.col2 * - col2 AS col2 FROM tab0 AS cor0
----
-1119
-31
-6754

query I rowsort
SELECT ALL cor1.col1 FROM tab0, tab1 AS cor0, tab1 AS cor1, tab0 cor2
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

query I rowsort
SELECT DISTINCT 24 - col0 AS col2 FROM tab1 AS cor0
----
-40
-56
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-2098
SELECT ALL + 59 * col0 * - ( col0 ) + col1 DIV col2 FROM tab0 AS cor0
----
-33982
-467338
-72178

skipif mysql # not compatible
query I rowsort label-2098
SELECT ALL + 59 * col0 * - ( col0 ) + col1 / col2 FROM tab0 AS cor0
----
-33982
-467338
-72178

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col0 + + cor0.col2 col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT 23 * + col1 FROM tab2 cor0
----
1357
391
713

query I rowsort
SELECT ALL - 96 * col0 + col2 * - col1 AS col0 FROM tab0 AS cor0
----
-16006
-3457
-5142

query I rowsort
SELECT ALL tab2.col0 + tab2.col2 FROM tab2
----
104
117
34

query I rowsort
SELECT - col1 + - 83 + col1 AS col1 FROM tab2
----
-83
-83
-83

query I rowsort
SELECT DISTINCT - ( col1 * - col1 ) + ( col1 ) * + col0 AS col2 FROM tab0
----
12804
16380
9460

query I rowsort
SELECT ALL 16 + - 96 FROM tab0
----
-80
-80
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2106
SELECT ALL - CAST( NULL AS SIGNED ) + 45 * tab1.col0 col0 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2106
SELECT ALL - CAST ( NULL AS INTEGER ) + 45 * tab1.col0 col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + col1 - + tab0.col1 * - col1 * - col0 AS col1 FROM tab0
----
-177418
-329218
-736918

query I rowsort
SELECT + 3 * col2 + - col2 FROM tab2
----
52
54
76

query I rowsort
SELECT - - col0 + - col0 + col1 * - col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-2110
SELECT DISTINCT - col2 * + col0 DIV col0 AS col2 FROM tab1 cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-2110
SELECT DISTINCT - col2 * + col0 / col0 AS col2 FROM tab1 cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + cor0.col1 col0 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2112
SELECT col1 + ( - 94 ) DIV + col1 FROM tab2 cor0
----
12
28
58

skipif mysql # not compatible
query I rowsort label-2112
SELECT col1 + ( - 94 ) / + col1 FROM tab2 cor0
----
12
28
58

query I rowsort
SELECT ALL - cor0.col0 + col1 * - 7 AS col2 FROM tab0 cor0
----
-626
-714
-726

query I rowsort
SELECT ALL - col1 + 29 AS col2 FROM tab1 AS cor0
----
16
19
3

query I rowsort
SELECT - cor0.col1 * col0 + 34 AS col1 FROM tab1 AS cor0
----
-1006
-44
-606

query I rowsort
SELECT ALL - col0 * 37 AS col2 FROM tab2 AS cor0
----
-259
-2886
-2923

query I rowsort
SELECT col2 * col1 - col0 FROM tab0 cor0
----
2814
62
7373

query I rowsort
SELECT - cor0.col0 FROM tab1 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 08e380e50b0cb64601bc84e5254deef4

query I rowsort
SELECT - col0 * + 81 AS col0 FROM tab2
----
-567
-6318
-6399

query I rowsort
SELECT - col1 * + 48 * + col2 FROM tab1 AS cor0
----
-27360
-59904
-67392

query I rowsort
SELECT tab1.col0 + - 25 + + col2 * - col0 FROM tab1
----
-184
-3609
-7625

query I rowsort
SELECT DISTINCT + col0 + ( + col1 ) FROM tab1
----
29
74
93

query I rowsort
SELECT ALL + ( + col0 ) * 3 + + 35 FROM tab1 AS cor0
----
227
275
44

onlyif mysql # use DIV operator for integer division
query I rowsort label-2124
SELECT ALL 50 + + col2 DIV + 28 AS col2 FROM tab2 AS cor0
----
50
50
51

skipif mysql # not compatible
query I rowsort label-2124
SELECT ALL 50 + + col2 / + 28 AS col2 FROM tab2 AS cor0
----
50
50
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-2125
SELECT + 94 DIV col1 FROM tab0 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-2125
SELECT + 94 / col1 FROM tab0 AS cor0
----
0
1
1

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 - - 9 AS col2 FROM tab0 AS cor0
----
9
9
9

query I rowsort
SELECT ALL + 70 * - col1 FROM tab0 AS cor0
----
-6020
-6370
-6790

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2129
SELECT CAST( NULL AS SIGNED ) + 6 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2129
SELECT CAST ( NULL AS INTEGER ) + 6 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + + cor0.col0 * col2 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT - 4 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
-4

query I rowsort
SELECT DISTINCT col1 * - col0 - + 4 FROM tab1
----
-1044
-644
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2133
SELECT DISTINCT - col2 - col2 DIV col0 col0 FROM tab0
----
-1
-34
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2133
SELECT DISTINCT - col2 - col2 / col0 col0 FROM tab0
----
-1
-34
-82

query I rowsort
SELECT ALL + - 28 * + cor0.col2 FROM tab0 AS cor0
----
-2296
-28
-924

query I rowsort
SELECT DISTINCT 8 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
24
512
640

query I rowsort
SELECT - 97 + 26 FROM tab2, tab0 AS cor0
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

onlyif mysql # use DIV operator for integer division
query I rowsort label-2137
SELECT ALL 54 + - cor0.col0 DIV 86 col0 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2137
SELECT ALL 54 + - cor0.col0 / 86 col0 FROM tab1 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2138
SELECT - CAST( col1 AS SIGNED ) + - col0 AS col1 FROM tab1 AS cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort label-2138
SELECT - CAST ( col1 AS INTEGER ) + - col0 AS col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT - + 67 + col0 * col1 FROM tab2 AS cor0
----
1276
150
4535

query I rowsort
SELECT + + 20 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 2fdd942fe0307a6ff66b63004ef102c4

query I rowsort
SELECT ALL + 95 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 14faa6dda52e3dfe1f5db2579c274a7e

query I rowsort
SELECT ALL + 82 AS col2 FROM tab0
----
82
82
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-2143
SELECT ALL - tab0.col2 DIV + col1 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2143
SELECT ALL - tab0.col2 / + col1 FROM tab0
----
0
0
0

query I rowsort
SELECT - 14 + - 13 * + col1 * tab2.col1 FROM tab2
----
-12507
-3771
-45267

query I rowsort
SELECT col2 * col0 + + col0 AS col1 FROM tab2
----
196
2106
3081

query I rowsort
SELECT ALL - - cor0.col2 * col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT ALL + - 47 * cor0.col0 AS col0 FROM tab0 AS cor0
----
-1128
-1645
-4183

query I rowsort
SELECT + cor0.col1 + - 51 FROM tab0 AS cor0
----
35
40
46

onlyif mysql # use DIV operator for integer division
query I rowsort label-2149
SELECT ALL col1 + - 85 DIV + col0 col1 FROM tab1 AS cor0
----
-2
12
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2149
SELECT ALL col1 + - 85 / + col0 col1 FROM tab1 AS cor0
----
-2
12
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-2150
SELECT DISTINCT - col0 DIV + col1 AS col0 FROM tab0 cor0
----
0

skipif mysql # not compatible
query I rowsort label-2150
SELECT DISTINCT - col0 / + col1 AS col0 FROM tab0 cor0
----
0

query I rowsort
SELECT - + 73 * col1 AS col0 FROM tab0 AS cor0
----
-6278
-6643
-7081

query I rowsort
SELECT ALL - cor0.col0 + 61 * col2 * + col2 AS col0 FROM tab2 cor0
----
41158
44462
88005

query I rowsort
SELECT DISTINCT + cor0.col0 - cor0.col2 AS col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL + col1 + col2 + + cor0.col1 AS col2 FROM tab0 AS cor0
----
195
205
264

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( - col1 ) col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL col2 * 37 * - col1 AS col0 FROM tab0 AS cor0
----
-105006
-276094
-3589

query I rowsort
SELECT DISTINCT col0 * + 55 AS col1 FROM tab1 AS cor0
----
165
3520
4400

query I rowsort
SELECT - + 33 * - col0 + cor0.col1 * + 0 FROM tab0 AS cor0
----
1155
2937
792

query I rowsort
SELECT ALL + col2 * - col2 + + col2 AS col0 FROM tab2 cor0
----
-1406
-650
-702

query I rowsort
SELECT - - col2 * 79 FROM tab2 AS cor0
----
2054
2133
3002

query I rowsort
SELECT - col0 * + cor0.col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT + col2 + - col1 * col1 AS col0 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT - + ( + col1 ) * + col2 AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL tab1.col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL + col0 * col1 * + ( col2 + cor0.col1 ) FROM tab2 AS cor0
----
12586
391170
73865

query I rowsort
SELECT DISTINCT + - col1 + 3 AS col0 FROM tab0 AS cor0
----
-83
-88
-94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2167
SELECT ALL + col2 * CAST( NULL AS SIGNED ) * - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2167
SELECT ALL + col2 * CAST ( NULL AS INTEGER ) * - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * ( - col2 ) - cor0.col0 FROM tab2 AS cor0
----
1365
598
722

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 17 col2 FROM tab0, tab2 cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT - - 93 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to e64105dfaa9fbd201adbb1f3f6968bde

query I rowsort
SELECT - - col1 + ( 29 ) * - col2 AS col0 FROM tab2 AS cor0
----
-1085
-695
-752

query I rowsort
SELECT cor0.col1 - 43 FROM tab0 cor0
----
43
48
54

query I rowsort
SELECT col0 * + 58 FROM tab0 cor0
----
1392
2030
5162

onlyif mysql # use DIV operator for integer division
query I rowsort label-2174
SELECT 65 DIV + ( cor0.col0 ) + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-22
-34
-89

skipif mysql # not compatible
query I rowsort label-2174
SELECT 65 / + ( cor0.col0 ) + - cor0.col0 AS col1 FROM tab0 AS cor0
----
-22
-34
-89

query I rowsort
SELECT DISTINCT + ( + col0 ) - - col1 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT 59 * col1 + col1 AS col0 FROM tab0 AS cor0
----
5160
5460
5820

query I rowsort
SELECT - ( 18 ) * col0 + col0 AS col0 FROM tab2 AS cor0
----
-119
-1326
-1343

query I rowsort
SELECT + 31 + tab0.col1 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to b27a6ccb2bbf2549313538da156c1db8

onlyif mysql # use DIV operator for integer division
query I rowsort label-2179
SELECT - col0 + + ( 39 ) + col1 DIV + 25 FROM tab2
----
-37
-40
33

skipif mysql # not compatible
query I rowsort label-2179
SELECT - col0 + + ( 39 ) + col1 / + 25 FROM tab2
----
-37
-40
33

query I rowsort
SELECT ALL + + col1 + ( 46 ) FROM tab1 cor0
----
56
59
72

query I rowsort
SELECT + ( - cor0.col0 ) AS col1 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - ( col1 ) col0 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT + col2 + + col1 * col2 FROM tab1
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-2184
SELECT + col0 * col1 DIV + tab1.col1 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-2184
SELECT + col0 * col1 / + tab1.col1 FROM tab1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 79 * + 43 col2 FROM tab0
----
3397
3397
3397

query I rowsort
SELECT ALL 49 * - col0 AS col2 FROM tab1
----
-147
-3136
-3920

query I rowsort
SELECT ALL - 27 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 0259a67676b131a4843853be4811b775

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col0 col1 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT ALL col1 + + 43 AS col0 FROM tab1
----
53
56
69

query I rowsort
SELECT ALL - 92 + tab1.col0 AS col2 FROM tab1
----
-12
-28
-89

query I rowsort
SELECT DISTINCT + col2 + 87 AS col1 FROM tab2
----
113
114
125

query I rowsort
SELECT DISTINCT 8 + + col1 FROM tab2
----
25
39
67

query I rowsort
SELECT ( ( - col2 ) ) - col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT DISTINCT col0 + col2 * col2 FROM tab2
----
1523
736
754

query I rowsort
SELECT + col2 + col1 + + cor0.col2 FROM tab1 AS cor0
----
124
134
205

query I rowsort
SELECT 71 + - col2 * - col2 * - col1 AS col2 FROM tab0 AS cor0
----
-26
-611813
-93583

query I rowsort
SELECT + + 2 + + col1 - + ( + col1 ) FROM tab1 AS cor0
----
2
2
2

query I rowsort
SELECT ALL col0 * col0 - 99 AS col1 FROM tab0
----
1126
477
7822

query I rowsort
SELECT DISTINCT - cor0.col1 - - col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL + + col0 + - col2 - col1 * col0 AS col1 FROM tab2 AS cor0
----
-1302
-237
-4550

query I rowsort
SELECT - 86 - - col0 AS col2 FROM tab2 AS cor0
----
-7
-79
-8

query I rowsort
SELECT ALL + col1 * - ( ( cor0.col2 ) * - 52 ) + - col1 FROM tab0 AS cor0
----
147490
387933
4947

onlyif mysql # use DIV operator for integer division
query I rowsort label-2203
SELECT DISTINCT - - col2 DIV + col2 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-2203
SELECT DISTINCT - - col2 / + col2 FROM tab1 AS cor0
----
1

query I rowsort
SELECT ALL - - col1 * + 38 * col0 + - col2 FROM tab2 cor0
----
174850
50996
8219

onlyif mysql # use DIV operator for integer division
query I rowsort label-2205
SELECT ALL + col0 DIV col0 + 36 FROM tab2 AS cor0
----
37
37
37

skipif mysql # not compatible
query I rowsort label-2205
SELECT ALL + col0 / col0 + 36 FROM tab2 AS cor0
----
37
37
37

query I rowsort
SELECT - col2 + 0 * - col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT DISTINCT + col0 * - ( col2 ) - cor0.col2 * col1 * + col1 FROM tab0 AS cor0
----
-244860
-686340
-9444

query I rowsort
SELECT + col1 * 91 AS col2 FROM tab0 AS cor0
----
7826
8281
8827

query I rowsort
SELECT DISTINCT - + col0 + ( - col2 ) FROM tab2 cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-2210
SELECT ALL col2 - cor0.col0 DIV + col1 AS col1 FROM tab1 cor0
----
51
54
90

skipif mysql # not compatible
query I rowsort label-2210
SELECT ALL col2 - cor0.col0 / + col1 AS col1 FROM tab1 cor0
----
51
54
90

query I rowsort
SELECT + - col0 + col1 * + col1 FROM tab1 AS cor0
----
36
673
89

query I rowsort
SELECT DISTINCT cor0.col2 * - 83 FROM tab0 cor0
----
-2739
-6806
-83

query I rowsort
SELECT - col0 + + 57 AS col2 FROM tab0 AS cor0
----
-32
22
33

query I rowsort
SELECT ALL + cor0.col0 + - 37 FROM tab2 AS cor0
----
-30
41
42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2215
SELECT DISTINCT + col1 * - CAST( col0 AS SIGNED ) col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2215
SELECT DISTINCT + col1 * - CAST ( col0 AS INTEGER ) col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT 20 * - col2 AS col1 FROM tab2 AS cor0
----
-520
-540
-760

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 51 * + col1 col1 FROM tab0 AS cor0
----
-4386
-4641
-4947

query I rowsort
SELECT + 64 * 71 AS col0 FROM tab0 AS cor0
----
4544
4544
4544

onlyif mysql # use DIV operator for integer division
query I rowsort label-2219
SELECT ALL + 57 DIV col0 AS col2 FROM tab2 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-2219
SELECT ALL + 57 / col0 AS col2 FROM tab2 AS cor0
----
0
0
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - ( + col1 ) col0 FROM tab2 cor0
----
-55
-58
-85

query I rowsort
SELECT ALL col0 * + col0 * 90 FROM tab2
----
4410
547560
561690

query I rowsort
SELECT ( 58 ) AS col2 FROM tab1 AS cor0
----
58
58
58

query I rowsort
SELECT ALL col2 + - cor0.col2 + + col2 AS col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT - 83 + + col1 FROM tab2 AS cor0
----
-24
-52
-66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2225
SELECT ALL + ( - col0 ) - + col0 / - CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2225
SELECT ALL + ( - col0 ) - + col0 / - CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col1 + + ( col2 ) AS col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT - ( ( cor0.col2 ) ) FROM tab1 cor0
----
-54
-57
-96

query I rowsort
SELECT - + 51 * cor0.col0 FROM tab0 cor0
----
-1224
-1785
-4539

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 cor0, tab0 cor1, tab0 cor2
----
972 values hashing to 3406497351e4789c89a295ee9b64b201

query I rowsort
SELECT DISTINCT col2 + 13 FROM tab0 AS cor0
----
14
46
95

query I rowsort
SELECT ALL col0 * ( - col1 ) + - col0 FROM tab1 cor0
----
-1120
-704
-81

query I rowsort
SELECT DISTINCT - + cor0.col1 * + col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - + 50 + cor0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 18bb8cd8846049275ea0eeb11e3e6129

query I rowsort
SELECT + ( 61 ) FROM tab0 AS cor0
----
61
61
61

query I rowsort
SELECT ALL - col1 * + col1 + + col0 AS col1 FROM tab2 AS cor0
----
-210
-3403
-954

query I rowsort
SELECT DISTINCT + col1 * 18 + + col0 + ( 96 ) AS col2 FROM tab1 cor0
----
340
410
567

query I rowsort
SELECT ALL - + 36 FROM tab0 AS cor0
----
-36
-36
-36

query I rowsort
SELECT + col1 + + ( col0 ) AS col1 FROM tab0
----
110
132
180

query I rowsort
SELECT + - col0 * + col2 * col0 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT + col1 * - col2 + + 20 * col2 FROM tab2 cor0
----
-1014
-297
114

query I rowsort
SELECT DISTINCT + - 62 AS col1 FROM tab0 AS cor0
----
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2242
SELECT + cor0.col1 DIV - col0 + + col2 AS col1 FROM tab0 cor0
----
-1
30
81

skipif mysql # not compatible
query I rowsort label-2242
SELECT + cor0.col1 / - col0 + + col2 AS col1 FROM tab0 cor0
----
-1
30
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-2243
SELECT DISTINCT + ( col1 ) DIV - ( + 86 ) FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-2243
SELECT DISTINCT + ( col1 ) / - ( + 86 ) FROM tab0 AS cor0
----
-1

query I rowsort
SELECT ALL 23 * + col0 FROM tab0 AS cor0
----
2047
552
805

query I rowsort
SELECT DISTINCT - + col2 * - col2 - - cor0.col1 AS col2 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT ALL 52 * + col0 AS col1 FROM tab1 AS cor0
----
156
3328
4160

query I rowsort
SELECT + cor0.col1 + + col0 AS col1 FROM tab0 AS cor0
----
110
132
180

onlyif mysql # use DIV operator for integer division
query I rowsort label-2248
SELECT - col2 * col2 DIV - col0 - col0 * col0 AS col0 FROM tab0
----
-1225
-531
-7846

skipif mysql # not compatible
query I rowsort label-2248
SELECT - col2 * col2 / - col0 - col0 * col0 AS col0 FROM tab0
----
-1225
-531
-7846

query I rowsort
SELECT - col1 + 35 + col0 FROM tab1
----
102
12
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + 33 col0 FROM tab0
----
115
34
66

query I rowsort
SELECT - col2 * - col1 + + 6 + + col0 FROM tab0 AS cor0
----
138
2868
7557

query I rowsort
SELECT DISTINCT + cor0.col1 + cor0.col2 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT - col1 * + col2 AS col1 FROM tab0 cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2254
SELECT DISTINCT 99 * col1 DIV - ( col0 ) + tab2.col1 * + 13 col1 FROM tab2
----
-35
200
693

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2254
SELECT DISTINCT 99 * col1 / - ( col0 ) + tab2.col1 * + 13 col1 FROM tab2
----
-35
200
693

query I rowsort
SELECT - col1 * col1 - col2 AS col1 FROM tab1
----
-157
-265
-730

query I rowsort
SELECT ALL - ( col1 ) + - col2 * col1 + col2 * - 37 AS col1 FROM tab0
----
-10587
-231
-4145

query I rowsort
SELECT + col1 + + 88 + + col2 AS col1 FROM tab0 AS cor0
----
186
207
261

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2258
SELECT - + col1 + CAST( col0 AS SIGNED ) + col1 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-2258
SELECT - + col1 + CAST ( col0 AS INTEGER ) + col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + col2 * cor0.col1 + + col2 + col1 FROM tab2 AS cor0
----
1619
701
895

query I rowsort
SELECT - + col2 + - 84 + + 86 AS col0 FROM tab0 AS cor0
----
-31
-80
1

query I rowsort
SELECT - cor0.col2 - 70 * + col0 FROM tab2 AS cor0
----
-517
-5486
-5568

query I rowsort
SELECT ALL - col2 + - col2 * + ( col2 ) AS col2 FROM tab2
----
-1482
-702
-756

query I rowsort
SELECT DISTINCT 1 AS col0 FROM tab2, tab2 AS cor0
----
1

query I rowsort
SELECT - + col2 * ( 0 ) + col1 AS col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + - col0 * col0 * ( col0 ) + - col1 AS col0 FROM tab1 AS cor0
----
-262154
-512013
-53

onlyif mysql # use DIV operator for integer division
query I rowsort label-2266
SELECT + col2 DIV - col0 + + col1 * - col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-840

skipif mysql # not compatible
query I rowsort label-2266
SELECT + col2 / - col0 + + col1 * - col2 AS col2 FROM tab2 AS cor0
----
-1534
-646
-840

onlyif mysql # use DIV operator for integer division
query I rowsort label-2267
SELECT DISTINCT col0 DIV + ( col0 ) FROM tab1
----
1

skipif mysql # not compatible
query I rowsort label-2267
SELECT DISTINCT col0 / + ( col0 ) FROM tab1
----
1

query IIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab1, tab0 cor1, tab1 AS cor2
----
972 values hashing to 465d072d2d9eababbfc8e88b82707474

query I rowsort
SELECT - col2 * col0 * + col1 AS col0 FROM tab2
----
-119652
-51034
-5859

query I rowsort
SELECT ( + tab2.col0 * - col1 ) FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT + cor0.col1 + - col2 * 92 * + col0 FROM tab0 AS cor0
----
-3123
-671325
-72778

query I rowsort
SELECT - col0 + 44 * col1 FROM tab1
----
1141
376
492

query I rowsort
SELECT - ( - 32 ) AS col1 FROM tab2 AS cor0
----
32
32
32

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2274
SELECT - 33 * - cor0.col1 + - CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2274
SELECT - 33 * - cor0.col1 + - CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * + col2 + 53 FROM tab2 AS cor0
----
2081
242
3055

onlyif mysql # use DIV operator for integer division
query I rowsort label-2276
SELECT DISTINCT col1 DIV col2 AS col0 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-2276
SELECT DISTINCT col1 / col2 AS col0 FROM tab1
----
0

query I rowsort
SELECT + 34 * tab0.col0 FROM tab0
----
1190
3026
816

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + + col1 * col2 * + 11 col2 FROM tab0 cor0
----
1102
31242
82171

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 - cor0.col2 col1 FROM tab2 AS cor0
----
-21
33
4

query I rowsort
SELECT 97 + - 6 AS col1 FROM tab1
----
91
91
91

query I rowsort
SELECT - col1 * - col2 AS col0 FROM tab0 cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-2282
SELECT + col2 DIV - col1 - col0 FROM tab1 AS cor0
----
-5
-69
-87

skipif mysql # not compatible
query I rowsort label-2282
SELECT + col2 / - col1 - col0 FROM tab1 AS cor0
----
-5
-69
-87

query I rowsort
SELECT DISTINCT + - ( col2 ) * - col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT ALL 71 * col1 + - col2 * 61 AS col0 FROM tab2 cor0
----
-1111
2603
554

query I rowsort
SELECT + 36 - - col0 * - col2 AS col0 FROM tab1 AS cor0
----
-126
-3612
-7644

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col0 * - cor0.col2 - col2 * CAST ( - 58 AS REAL ) FROM tab1 AS cor0
----
-2112
-342
2970

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2287
SELECT CAST( NULL AS SIGNED ) * col2 + + col1 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2287
SELECT CAST ( NULL AS INTEGER ) * col2 + + col1 AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 55 * + 18 AS col1 FROM tab0 AS cor0
----
-990
-990
-990

query I rowsort
SELECT ( 13 ) - + col1 FROM tab1 AS cor0
----
-13
0
3

query I rowsort
SELECT ALL 85 * - col1 FROM tab1 AS cor0
----
-1105
-2210
-850

query I rowsort
SELECT ALL col2 + col1 * + col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT - 70 + + col0 FROM tab1 AS cor0
----
-6
-67
10

query I rowsort
SELECT DISTINCT ( col2 ) + - col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT ( 35 ) AS col2 FROM tab2
----
35

query I rowsort
SELECT cor0.col2 * col1 * + col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT + 62 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 51dd2771d516ceb935483eded78a5fa0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2297
SELECT - + col1 DIV - ( + col0 ) FROM tab2 cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-2297
SELECT - + col1 / - ( + col0 ) FROM tab2 cor0
----
0
0
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-2298
SELECT ALL col0 - col0 * + col1 DIV col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2298
SELECT ALL col0 - col0 * + col1 / col1 AS col0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col0 * + 13 col0 FROM tab2
----
1014
1027
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2300
SELECT DISTINCT - CAST( - col2 AS SIGNED ) + cor0.col0 * ( - col0 + col2 ) FROM tab2 AS cor0
----
-3201
-4030
167

skipif mysql # not compatible
query I rowsort label-2300
SELECT DISTINCT - CAST ( - col2 AS INTEGER ) + cor0.col0 * ( - col0 + col2 ) FROM tab2 AS cor0
----
-3201
-4030
167

query I rowsort
SELECT ALL - - col1 + 81 * - col1 FROM tab0 AS cor0
----
-6880
-7280
-7760

query I rowsort
SELECT tab1.col2 + - col2 * + col1 FROM tab1
----
-1152
-1350
-513

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2303
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col1 FROM tab2, tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2303
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col1 FROM tab2, tab2 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2304
SELECT - col1 DIV + 44 col1 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2304
SELECT - col1 / + 44 col1 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2305
SELECT col1 + - ( - ( col2 ) ) * + CAST( NULL AS SIGNED ) * - col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2305
SELECT col1 + - ( - ( col2 ) ) * + CAST ( NULL AS INTEGER ) * - col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2306
SELECT ALL - 57 DIV 75 + col1 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-2306
SELECT ALL - 57 / 75 + col1 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT + + col1 * col1 AS col0 FROM tab2 cor0
----
289
3481
961

query I rowsort
SELECT ALL - 3 * 17 + - cor0.col1 FROM tab1 AS cor0
----
-61
-64
-77

query I rowsort
SELECT DISTINCT col1 * + col2 AS col0 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT col0 * col2 * - col2 AS col1 FROM tab1 cor0
----
-207936
-737280
-8748

query I rowsort
SELECT - col0 * ( - col1 ) AS col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT + cor0.col0 * - cor0.col2 AS col2 FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT - 30 * col1 AS col2 FROM tab1 AS cor0
----
-300
-390
-780

query I rowsort
SELECT ALL - 32 * - col2 FROM tab2 AS cor0
----
1216
832
864

query I rowsort
SELECT ALL - col0 * - 52 FROM tab2
----
364
4056
4108

query I rowsort
SELECT DISTINCT + col1 * - col1 + - col1 AS col1 FROM tab0
----
-7482
-8372
-9506

query I rowsort
SELECT ALL col1 - + col0 * + col1 AS col2 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT - + cor0.col2 * - col1 AS col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT - ( 80 ) AS col1 FROM tab1 cor0
----
-80

query I rowsort
SELECT - - ( col0 ) * + col0 + 3 * - col1 * + col2 AS col2 FROM tab2 AS cor0
----
-2462
1482
4303

query I rowsort
SELECT DISTINCT + col0 * - cor0.col1 + + col2 AS col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT ALL col1 + + col0 * - col0 FROM tab0 AS cor0
----
-1128
-490
-7830

query I rowsort
SELECT ALL - + col2 * col2 AS col2 FROM tab2 cor0
----
-1444
-676
-729

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - col0 col0 FROM tab0
----
-34
-7
9

query I rowsort
SELECT ALL 79 + + col1 AS col0 FROM tab2
----
110
138
96

query I rowsort
SELECT + 48 * + cor0.col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 0bed7991f3f8ff9da76a4f2b1e9919e6

query I rowsort
SELECT + 46 * col1 AS col1 FROM tab1
----
1196
460
598

query I rowsort
SELECT DISTINCT tab0.col2 * + col2 + ( 55 * col0 ) FROM tab0
----
11619
1926
2409

query I rowsort
SELECT DISTINCT - col0 + col2 * - ( 12 ) + col2 FROM tab2
----
-304
-364
-497

query I rowsort
SELECT DISTINCT + col0 + ( - 68 ) AS col0 FROM tab0 AS cor0
----
-33
-44
21

query I rowsort
SELECT ALL col1 * - col1 + - 83 AS col1 FROM tab1 AS cor0
----
-183
-252
-759

query I rowsort
SELECT ALL - col2 + 19 FROM tab2 AS cor0
----
-19
-7
-8

query I rowsort
SELECT - + col1 * - 8 FROM tab1 AS cor0
----
104
208
80

query I rowsort
SELECT DISTINCT - + col0 * 45 FROM tab2 AS cor0
----
-315
-3510
-3555

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2335
SELECT DISTINCT - col2 + + CAST( - col0 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-171
-36
-57

skipif mysql # not compatible
query I rowsort label-2335
SELECT DISTINCT - col2 + + CAST ( - col0 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT ALL + col0 + + ( - col2 ) * + col0 FROM tab1 AS cor0
----
-159
-3584
-7600

query I rowsort
SELECT ALL - col2 * ( + ( + col2 ) ) AS col1 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT + - cor0.col2 + + cor0.col2 * col2 FROM tab2 AS cor0
----
1406
650
702

query I rowsort
SELECT ALL col1 + + col2 + col0 FROM tab1 AS cor0
----
131
189
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - cor0.col0 col1 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2341
SELECT ALL col0 * 31 DIV - col1 FROM tab2 AS cor0
----
-144
-40
-7

skipif mysql # not compatible
query I rowsort label-2341
SELECT ALL col0 * 31 / - col1 FROM tab2 AS cor0
----
-144
-40
-7

query I rowsort
SELECT ALL + - col1 + 89 FROM tab1 AS cor0
----
63
76
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 62 col0 FROM tab0, tab1, tab2 AS cor0
----
62

query I rowsort
SELECT ALL + col2 + + col0 * ( - 83 ) FROM tab1
----
-195
-5255
-6544

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab0, tab0 AS cor0, tab0 cor1
----
972 values hashing to 3406497351e4789c89a295ee9b64b201

query I rowsort
SELECT ALL + col2 * - col0 + ( - col1 ) FROM tab1
----
-188
-3658
-7693

query I rowsort
SELECT ALL + 33 + - col1 FROM tab2
----
-26
16
2

query I rowsort
SELECT DISTINCT 60 + + tab1.col1 AS col1 FROM tab1
----
70
73
86

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 2 * col1 + - 25 + + col1 col1 FROM tab0 AS cor0
----
-111
-116
-122

onlyif mysql # use DIV operator for integer division
query I rowsort label-2350
SELECT - 50 DIV - col0 AS col1 FROM tab1
----
0
0
16

skipif mysql # not compatible
query I rowsort label-2350
SELECT - 50 / - col0 AS col1 FROM tab1
----
0
0
16

onlyif mysql # use DIV operator for integer division
query I rowsort label-2351
SELECT DISTINCT col1 DIV - col1 AS col2 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-2351
SELECT DISTINCT col1 / - col1 AS col2 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT DISTINCT col0 + - col0 * 58 * - col0 AS col0 FROM tab2 AS cor0
----
2849
352950
362057

query I rowsort
SELECT ALL + - cor0.col2 + - col2 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT ALL + col1 * col0 + - cor0.col0 AS col2 FROM tab1 AS cor0
----
576
75
960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2355
SELECT DISTINCT - col1 - CAST( NULL AS SIGNED ) * cor0.col2 AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2355
SELECT DISTINCT - col1 - CAST ( NULL AS INTEGER ) * cor0.col2 AS col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL + col2 * ( 45 ) FROM tab0 AS cor0
----
1485
3690
45

query I rowsort
SELECT - col0 * cor0.col2 * - col0 AS col2 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT + - col0 * - col1 + + ( + col1 ) * - 54 FROM tab2 AS cor0
----
-1457
1416
425

query I rowsort
SELECT DISTINCT col0 * - 88 AS col1 FROM tab1 AS cor0
----
-264
-5632
-7040

query I rowsort
SELECT DISTINCT - + col2 + col1 FROM tab1 cor0
----
-28
-47
-83

query I rowsort
SELECT DISTINCT - + col2 * ( col2 ) AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-2362
SELECT DISTINCT + - col0 DIV 47 AS col1 FROM tab1 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-2362
SELECT DISTINCT + - col0 / 47 AS col1 FROM tab1 AS cor0
----
-1
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2363
SELECT + cor0.col1 * col2 + 33 * col2 DIV - col0 FROM tab1 AS cor0
----
1209
541
810

skipif mysql # not compatible
query I rowsort label-2363
SELECT + cor0.col1 * col2 + 33 * col2 / - col0 FROM tab1 AS cor0
----
1209
541
810

query I rowsort
SELECT + col1 * - col1 + col1 AS col0 FROM tab1
----
-156
-650
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + col1 col1 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL + tab1.col1 * tab1.col1 * + col2 AS col2 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT + col2 + + col1 * + col2 * + tab1.col1 FROM tab1
----
16320
36558
5757

onlyif mysql # use DIV operator for integer division
query I rowsort label-2368
SELECT DISTINCT col0 DIV col1 + tab2.col0 * - col0 AS col2 FROM tab2
----
-49
-6083
-6237

skipif mysql # not compatible
query I rowsort label-2368
SELECT DISTINCT col0 / col1 + tab2.col0 * - col0 AS col2 FROM tab2
----
-49
-6083
-6237

query I rowsort
SELECT + col1 + - col0 * col1 AS col1 FROM tab2
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-2370
SELECT DISTINCT + tab1.col0 DIV col1 + - col1 FROM tab1
----
-26
-4
-7

skipif mysql # not compatible
query I rowsort label-2370
SELECT DISTINCT + tab1.col0 / col1 + - col1 FROM tab1
----
-26
-4
-7

query I rowsort
SELECT ALL tab2.col2 + - col2 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT DISTINCT 5 * col0 AS col0 FROM tab0 AS cor0
----
120
175
445

onlyif mysql # use DIV operator for integer division
query I rowsort label-2373
SELECT ALL + col0 DIV cor0.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-2373
SELECT ALL + col0 / cor0.col0 col0 FROM tab1 cor0
----
1
1
1

query I rowsort
SELECT ALL 45 + col1 * + cor0.col0 - + col2 FROM tab2 cor0
----
1350
235
4621

query I rowsort
SELECT - col1 * col2 + col2 FROM tab2
----
-1508
-608
-810

onlyif mysql # use DIV operator for integer division
query I rowsort label-2376
SELECT ALL col2 DIV col0 + col2 + - tab0.col2 FROM tab0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-2376
SELECT ALL col2 / col0 + col2 + - tab0.col2 FROM tab0
----
0
0
1

query I rowsort
SELECT - col1 FROM tab0 WHERE NOT ( NULL ) IN ( tab0.col1 )
----

query I rowsort
SELECT DISTINCT - col0 * + tab0.col2 + - col1 + - col1 AS col2 FROM tab0
----
-229
-7480
-964

query I rowsort
SELECT ALL - tab0.col0 + col0 + + col2 * col1 AS col2 FROM tab0
----
2838
7462
97

query III rowsort
SELECT ALL * FROM tab2 WHERE ( - col1 * - col1 - - col0 ) <> col2 + col1
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2381
SELECT + + col0 DIV + col0 + cor0.col0 * - 49 FROM tab2 AS cor0
----
-342
-3821
-3870

skipif mysql # not compatible
query I rowsort label-2381
SELECT + + col0 / + col0 + cor0.col0 * - 49 FROM tab2 AS cor0
----
-342
-3821
-3870

onlyif mysql # use DIV operator for integer division
query I rowsort label-2382
SELECT + + col1 DIV cor0.col0 AS col1 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-2382
SELECT + + col1 / cor0.col0 AS col1 FROM tab0 AS cor0
----
1
2
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2383
SELECT - col0 * - cor0.col0 + + 40 - + 15 * - col2 / CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2383
SELECT - col0 * - cor0.col0 + + 40 - + 15 * - col2 / CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 88 * col2 FROM tab1
----
4752
5016
8448

query I rowsort
SELECT + col0 * cor0.col1 + ( - col1 ) * col1 FROM tab2 AS cor0
----
-744
1054
1121

onlyif mysql # use DIV operator for integer division
query I rowsort label-2386
SELECT ALL + + col0 DIV + col2 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-2386
SELECT ALL + + col0 / + col2 FROM tab0 AS cor0
----
0
1
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * - col1 + 6 * col1 col2 FROM tab0 AS cor0
----
2580
3977
8645

query I rowsort
SELECT + col1 + + col2 * + cor0.col1 FROM tab0 AS cor0
----
194
2924
7553

query I rowsort
SELECT + 59 AS col2 FROM tab2, tab1 cor0
----
9 values hashing to a9b9966d749d1b2ce5955ed12394f9bc

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2390
SELECT + col2 * CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2390
SELECT + col2 * CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + cor1.col2 AS col0 FROM tab2, tab0 AS cor0, tab0, tab1 cor1
----
81 values hashing to 2df272448a67587d4635afedff278dcc

onlyif mysql # use DIV operator for integer division
query I rowsort label-2392
SELECT ( + ( col0 ) ) DIV col1 AS col2 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-2392
SELECT ( + ( col0 ) ) / col1 AS col2 FROM tab2 AS cor0
----
0
1
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2393
SELECT - - CAST( - col0 AS SIGNED ) * col1 AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-2393
SELECT - - CAST ( - col0 AS INTEGER ) * col1 AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2394
SELECT ALL - CAST( - 37 AS SIGNED ) * col0 AS col2 FROM tab2
----
259
2886
2923

skipif mysql # not compatible
query I rowsort label-2394
SELECT ALL - CAST ( - 37 AS INTEGER ) * col0 AS col2 FROM tab2
----
259
2886
2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-2395
SELECT DISTINCT 69 DIV - 51 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-2395
SELECT DISTINCT 69 / - 51 FROM tab0
----
-1

query I rowsort
SELECT ALL + 28 * col2 AS col1 FROM tab2 AS cor0
----
1064
728
756

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2397
SELECT ALL CAST( - col0 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-2397
SELECT ALL CAST ( - col0 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + ( col1 ) + col2 * col2 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT ALL + ( + 60 + col2 ) FROM tab0
----
142
61
93

query I rowsort
SELECT DISTINCT + 48 * + 73 * col1 AS col0 FROM tab1
----
35040
45552
91104

query I rowsort
SELECT DISTINCT col1 * + cor0.col0 + col2 AS col2 FROM tab1 AS cor0
----
1136
132
697

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 + + col0 * col1 col0 FROM tab1 AS cor0
----
24
583
944

query I rowsort
SELECT 85 + + col2 FROM tab1 AS cor0
----
139
142
181

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col1 + - col2 col2 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT cor0.col1 * col2 - cor0.col1 * cor0.col1 AS col0 FROM tab1 AS cor0
----
1079
470
728

onlyif mysql # use DIV operator for integer division
query I rowsort label-2406
SELECT DISTINCT col1 * col1 DIV + col0 + + col2 * - col2 - - cor0.col0 * cor0.col2 * col0 FROM tab1 AS cor0
----
-2205
230224
605186

skipif mysql # not compatible
query I rowsort label-2406
SELECT DISTINCT col1 * col1 / + col0 + + col2 * - col2 - - cor0.col0 * cor0.col2 * col0 FROM tab1 AS cor0
----
-2205
230224
605186

onlyif mysql # use DIV operator for integer division
query I rowsort label-2407
SELECT ALL tab1.col2 + - col1 * + col0 DIV tab1.col0 AS col1 FROM tab1
----
28
47
83

skipif mysql # not compatible
query I rowsort label-2407
SELECT ALL tab1.col2 + - col1 * + col0 / tab1.col0 AS col1 FROM tab1
----
28
47
83

query I rowsort
SELECT ALL + tab1.col0 + + col1 * col2 FROM tab1
----
1328
1407
634

query I rowsort
SELECT - col0 - + col1 * col1 FROM tab1 AS cor0
----
-164
-249
-679

query I rowsort
SELECT ALL - - cor0.col1 AS col2 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 - + col1 col0 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT col1 * + col2 + - col1 FROM tab1 cor0
----
1235
1378
560

onlyif mysql # use DIV operator for integer division
query I rowsort label-2413
SELECT - col1 DIV + col1 - cor0.col0 AS col1 FROM tab2 AS cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-2413
SELECT - col1 / + col1 - cor0.col0 AS col1 FROM tab2 AS cor0
----
-79
-8
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2414
SELECT - CAST( 2 AS SIGNED ) AS col2 FROM tab0
----
-2
-2
-2

skipif mysql # not compatible
query I rowsort label-2414
SELECT - CAST ( 2 AS INTEGER ) AS col2 FROM tab0
----
-2
-2
-2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + col0 ) col2 FROM tab2
----
7
78
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2416
SELECT + - CAST( - col0 AS SIGNED ) + - col1 FROM tab0 AS cor0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort label-2416
SELECT + - CAST ( - col0 AS INTEGER ) + - col1 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ALL + col1 * + col0 - cor0.col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT + 42 * col1 + col1 * + col2 FROM tab0 AS cor0
----
11284
4171
6450

query I rowsort
SELECT DISTINCT - 50 AS col2 FROM tab1, tab1 cor0
----
-50

query I rowsort
SELECT - 24 * col1 * col1 FROM tab0 AS cor0
----
-177504
-198744
-225816

query I rowsort
SELECT ALL + ( + col2 ) * + col0 * col1 + - col1 * col2 FROM tab1 AS cor0
----
2808
35910
98592

query I rowsort
SELECT DISTINCT cor0.col0 + + col1 AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT col0 - + col1 * col2 AS col2 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL - - ( - col2 ) * col2 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - + 65 AS col1 FROM tab0 cor0
----
-65
-65
-65

onlyif mysql # use DIV operator for integer division
query I rowsort label-2426
SELECT ALL + col2 * col0 + - col2 + + col0 DIV col2 AS col2 FROM tab0 AS cor0
----
69
7217
759

skipif mysql # not compatible
query I rowsort label-2426
SELECT ALL + col2 * col0 + - col2 + + col0 / col2 AS col2 FROM tab0 AS cor0
----
69
7217
759

query I rowsort
SELECT ALL - 3 * col0 FROM tab1
----
-192
-240
-9

query I rowsort
SELECT ALL - 5 AS col1 FROM tab1
----
-5
-5
-5

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NULL <> col0 + - col1 / - col1
----

query I rowsort
SELECT - col1 * - col2 * - col0 AS col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-2431
SELECT DISTINCT + col1 * - col2 + + col2 DIV col1 + - col0 AS col1 FROM tab1
----
-1321
-1405
-629

skipif mysql # not compatible
query I rowsort label-2431
SELECT DISTINCT + col1 * - col2 + + col2 / col1 + - col0 AS col1 FROM tab1
----
-1321
-1405
-629

onlyif mysql # use DIV operator for integer division
query I rowsort label-2432
SELECT ALL col2 + col1 DIV col1 + tab2.col2 * - col2 col2 FROM tab2
----
-1405
-649
-701

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2432
SELECT ALL col2 + col1 / col1 + tab2.col2 * - col2 col2 FROM tab2
----
-1405
-649
-701

query I rowsort
SELECT ALL + col0 + + col0 * col1 AS col0 FROM tab2 cor0
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-2434
SELECT + col2 + + col2 + col0 DIV - tab0.col0 AS col2 FROM tab0
----
1
163
65

skipif mysql # not compatible
query I rowsort label-2434
SELECT + col2 + + col2 + col0 / - tab0.col0 AS col2 FROM tab0
----
1
163
65

query I rowsort
SELECT - col1 + col2 * col1 AS col0 FROM tab1 WHERE NOT ( NULL ) NOT IN ( + col0 * + tab1.col1 * col1 + + col0 * - col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col2 + col2 * + col2 col0 FROM tab1
----
2862
3192
9120

query I rowsort
SELECT + col1 FROM tab0 WHERE ( - col1 * col2 ) NOT IN ( col1 )
----
86
91
97

query I rowsort
SELECT ALL - col1 * - col0 + - col0 * col2 * - col0 AS col0 FROM tab2
----
1540
162786
238501

query III rowsort
SELECT * FROM tab1 WHERE NOT ( col0 ) NOT BETWEEN + col0 AND ( col1 + col2 )
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT DISTINCT + col0 + + col2 * - col0 * - col1 AS col0 FROM tab2
----
119730
51113
5866

onlyif mysql # use DIV operator for integer division
query I rowsort label-2441
SELECT DISTINCT - col0 DIV + col1 AS col1 FROM tab1 cor0
----
-6
0

skipif mysql # not compatible
query I rowsort label-2441
SELECT DISTINCT - col0 / + col1 AS col1 FROM tab1 cor0
----
-6
0

query I rowsort
SELECT ALL tab1.col1 + + col1 AS col2 FROM tab1
----
20
26
52

query III rowsort
SELECT * FROM tab2 WHERE col2 > ( col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2444
SELECT ALL col1 DIV - col0 + - col2 AS col0 FROM tab0
----
-3
-36
-83

skipif mysql # not compatible
query I rowsort label-2444
SELECT ALL col1 / - col0 + - col2 AS col0 FROM tab0
----
-3
-36
-83

query I rowsort
SELECT ALL col2 * + col2 + col2 AS col1 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL - cor0.col1 + col2 + col2 FROM tab2 AS cor0
----
-7
23
59

query I rowsort
SELECT ALL + col1 + + col0 - - col0 FROM tab2
----
175
215
45

onlyif mysql # use DIV operator for integer division
query I rowsort label-2448
SELECT + tab1.col1 + + col0 DIV - col0 AS col2 FROM tab1
----
12
25
9

skipif mysql # not compatible
query I rowsort label-2448
SELECT + tab1.col1 + + col0 / - col0 AS col2 FROM tab1
----
12
25
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + tab1.col0 col0 FROM tab1
----
162
3648
7680

query I rowsort
SELECT DISTINCT + col1 * col1 - - col1 FROM tab0
----
7482
8372
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-2451
SELECT ALL col2 DIV - col1 + col2 - col1 FROM tab1
----
26
42
76

skipif mysql # not compatible
query I rowsort label-2451
SELECT ALL col2 / - col1 + col2 - col1 FROM tab1
----
26
42
76

query I rowsort
SELECT ALL col1 * - col0 * col0 + - col1 AS col2 FROM tab0
----
-118922
-49622
-720902

query I rowsort
SELECT col1 * + tab2.col1 + col2 * col0 * + col1 FROM tab2
----
123133
51323
6820

query I rowsort
SELECT DISTINCT col1 * + col0 + + col0 AS col0 FROM tab1
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col2 + - col2 col2 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT DISTINCT + col0 * + col2 * + cor0.col0 FROM tab1 AS cor0
----
233472
486
614400

query I rowsort
SELECT + col2 * col0 + + col1 FROM tab2 AS cor0
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-2458
SELECT cor0.col2 + - col0 DIV col1 FROM tab1 AS cor0
----
51
54
90

skipif mysql # not compatible
query I rowsort label-2458
SELECT cor0.col2 + - col0 / col1 FROM tab1 AS cor0
----
51
54
90

query I rowsort
SELECT DISTINCT - col1 * + col0 + + col0 FROM tab2 AS cor0
----
-1264
-210
-4524

onlyif mysql # use DIV operator for integer division
query I rowsort label-2460
SELECT + cor0.col1 - ( + col0 ) DIV + ( - cor0.col1 ) AS col0 FROM tab1 AS cor0
----
16
19
26

skipif mysql # not compatible
query I rowsort label-2460
SELECT + cor0.col1 - ( + col0 ) / + ( - cor0.col1 ) AS col0 FROM tab1 AS cor0
----
16
19
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-2461
SELECT - col1 DIV - col1 + - 31 * - col1 FROM tab0
----
2667
2822
3008

skipif mysql # not compatible
query I rowsort label-2461
SELECT - col1 / - col1 + - 31 * - col1 FROM tab0
----
2667
2822
3008

query I rowsort
SELECT DISTINCT - 38 + - col0 FROM tab2
----
-116
-117
-45

query I rowsort
SELECT ALL 70 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT + 99 * + col0 AS col2 FROM tab1
----
297
6336
7920

onlyif mysql # use DIV operator for integer division
query I rowsort label-2465
SELECT + 37 * + 11 + col1 DIV + 23 + + col0 AS col0 FROM tab0
----
434
446
499

skipif mysql # not compatible
query I rowsort label-2465
SELECT + 37 * + 11 + col1 / + 23 + + col0 AS col0 FROM tab0
----
434
446
499

query I rowsort
SELECT col2 * col2 * + col2 FROM tab2
----
17576
19683
54872

query I rowsort
SELECT DISTINCT - + col0 - col1 * + col2 AS col0 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT - ( col0 ) * - col2 - ( 44 ) AS col0 FROM tab1 AS cor0
----
118
3604
7636

query I rowsort
SELECT DISTINCT cor0.col1 * + 69 - col2 FROM tab0 AS cor0
----
5901
6197
6692

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2470
SELECT DISTINCT + ( col2 + - col0 ) * CAST( col2 AS SIGNED ) FROM tab2
----
-1352
-1558
540

skipif mysql # not compatible
query I rowsort label-2470
SELECT DISTINCT + ( col2 + - col0 ) * CAST ( col2 AS INTEGER ) FROM tab2
----
-1352
-1558
540

query I rowsort
SELECT col0 + - col1 * col0 FROM tab0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-2472
SELECT - - col1 DIV 52 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2472
SELECT - - col1 / 52 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT col1 * + 79 * col0 FROM tab0 AS cor0
----
163056
268205
639821

onlyif mysql # use DIV operator for integer division
query I rowsort label-2474
SELECT - col1 DIV + 7 AS col2 FROM tab1 AS cor0
----
-1
-1
-3

skipif mysql # not compatible
query I rowsort label-2474
SELECT - col1 / + 7 AS col2 FROM tab1 AS cor0
----
-1
-1
-3

query I rowsort
SELECT ALL col2 * - col2 * - 78 AS col2 FROM tab2
----
112632
52728
56862

query I rowsort
SELECT - 27 AS col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 0259a67676b131a4843853be4811b775

query I rowsort
SELECT ALL cor0.col1 * 92 FROM tab1, tab0 AS cor0
----
9 values hashing to 844e514306f2f916b4219f43521d18e1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2478
SELECT - cor0.col2 / CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2478
SELECT - cor0.col2 / CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - tab0.col0 + 20 * + tab0.col1 AS col1 FROM tab0
----
1696
1731
1905

query I rowsort
SELECT ALL + cor0.col1 * 36 FROM tab1 AS cor0
----
360
468
936

query I rowsort
SELECT - - col1 * + 47 AS col0 FROM tab2 cor0
----
1457
2773
799

query I rowsort
SELECT ALL + col1 + + 17 FROM tab1 AS cor0
----
27
30
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-2483
SELECT cor0.col1 + - cor0.col0 DIV 75 FROM tab0 AS cor0
----
86
90
97

skipif mysql # not compatible
query I rowsort label-2483
SELECT cor0.col1 + - cor0.col0 / 75 FROM tab0 AS cor0
----
86
90
97

query I rowsort
SELECT ALL - + col1 + 30 FROM tab2 AS cor0
----
-1
-29
13

query I rowsort
SELECT - cor0.col2 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

query I rowsort
SELECT DISTINCT cor0.col0 AS col2 FROM tab0, tab2, tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + col1 * cor0.col1 AS col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT 42 * + 92 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 14d048cc4f4a3cf54fd223334326a463

query I rowsort
SELECT DISTINCT 77 AS col1 FROM tab0, tab2 AS cor0
----
77

query I rowsort
SELECT ( + col2 ) * col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT - 76 * - 17 FROM tab2 AS cor0
----
1292

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2492
SELECT ALL CAST( NULL AS SIGNED ) * + col0 * - col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2492
SELECT ALL CAST ( NULL AS INTEGER ) * + col0 * - col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 78 * - ( col0 * - col2 ) FROM tab0 cor0
----
2730
569244
61776

query I rowsort
SELECT ALL - - ( - 73 ) * col2 FROM tab1 AS cor0
----
-3942
-4161
-7008

onlyif mysql # use DIV operator for integer division
query I rowsort label-2495
SELECT - - col0 DIV 46 col0 FROM tab2 cor0
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2495
SELECT - - col0 / 46 col0 FROM tab2 cor0
----
0
1
1

query I rowsort
SELECT - - 34 FROM tab2 AS cor0
----
34
34
34

query I rowsort
SELECT + + ( col2 ) * - cor0.col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ( - col1 ) * col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - + col1 + col1 * 67 FROM tab1 AS cor0
----
1716
660
858

onlyif mysql # use DIV operator for integer division
query I rowsort label-2500
SELECT DISTINCT + 81 DIV - col0 + col1 - col0 * col0 AS col1 FROM tab1 AS cor0
----
-10
-4087
-6388

skipif mysql # not compatible
query I rowsort label-2500
SELECT DISTINCT + 81 / - col0 + col1 - col0 * col0 AS col1 FROM tab1 AS cor0
----
-10
-4087
-6388

query I rowsort
SELECT + + 18 AS col2 FROM tab1 cor0
----
18
18
18

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 30 * col2 col2 FROM tab1 cor0
----
1620
1710
2880

query I rowsort
SELECT 23 + col0 AS col1 FROM tab0 AS cor0
----
112
47
58

query I rowsort
SELECT - + ( col2 ) + col1 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT + col0 * 53 + + col1 * col0 FROM tab1 AS cor0
----
237
4032
5280

query I rowsort
SELECT + col2 + - 31 FROM tab2 AS cor0
----
-4
-5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 55 col2 FROM tab1 cor0
----
55
55
55

query I rowsort
SELECT DISTINCT - ( + col2 ) * - 24 FROM tab0 cor0
----
1968
24
792

query I rowsort
SELECT DISTINCT + + cor0.col0 * + cor0.col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL col1 * col0 + + 58 * - 45 AS col0 FROM tab1 AS cor0
----
-1570
-1970
-2532

query I rowsort
SELECT 77 + + col0 * ( - cor0.col0 * col0 ) FROM tab0 AS cor0
----
-13747
-42798
-704892

query I rowsort
SELECT DISTINCT + - col0 * col2 AS col2 FROM tab0 cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT col0 + + col2 * + col1 AS col0 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL - col1 * col0 * col0 + col2 + - col0 FROM tab0
----
-118859
-49527
-720818

query I rowsort
SELECT 97 FROM tab1, tab2, tab2 cor0, tab0 AS cor1
----
81 values hashing to f1d3319b9491f64621f2dbb0808458ca

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2516
SELECT DISTINCT + CAST( NULL AS SIGNED ) FROM tab1, tab0, tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2516
SELECT DISTINCT + CAST ( NULL AS INTEGER ) FROM tab1, tab0, tab1 cor0
----
NULL

query I rowsort
SELECT - + col0 + col0 * col0 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT ALL ( + col1 ) * - col0 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT 54 * + col2 FROM tab0 AS cor0
----
1782
4428
54

query I rowsort
SELECT DISTINCT + + col1 * col1 FROM tab0 cor0
----
7396
8281
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-2521
SELECT + col0 * col1 DIV col0 FROM tab1 cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2521
SELECT + col0 * col1 / col0 FROM tab1 cor0
----
10
13
26

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0 AS cor0 CROSS JOIN tab1, tab2 cor1, tab2 cor2
----
972 values hashing to f9adf26f20dc8fcc43c2de18a5fd4859

query I rowsort
SELECT - + col1 * 15 + 39 FROM tab0 AS cor0
----
-1251
-1326
-1416

query I rowsort
SELECT - cor0.col1 + col0 + 19 AS col0 FROM tab1 AS cor0
----
-4
73
86

query I rowsort
SELECT ALL + 69 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 85d9b90a03b9def161891b13085271f7

query I rowsort
SELECT ALL + tab2.col2 * + tab2.col0 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 41d4c126bfd4bfab59ba5e83427c98e0

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab0 AS cor2, tab0 AS cor3
----
3645 values hashing to 38896d3a4bd953cc78f93d73ae064cbd

query I rowsort
SELECT + + 58 * + 12 FROM tab2 AS cor0
----
696
696
696

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2529
SELECT - CAST( NULL AS SIGNED ) * + col0 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2529
SELECT - CAST ( NULL AS INTEGER ) * + col0 col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 52 + + 67 + - col2 AS col1 FROM tab1
----
23
62
65

query I rowsort
SELECT - 64 * col1 AS col2 FROM tab2
----
-1088
-1984
-3776

query I rowsort
SELECT - - col0 * + col0 + + cor0.col2 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT DISTINCT - ( + col0 ) * col1 FROM tab2 cor0
----
-1343
-217
-4602

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab2 AS cor0, tab0 cor1, tab0 cor2
----
972 values hashing to d522b52b67b20888d3544d25cb98f232

query I rowsort
SELECT ALL + 54 + + col2 * + col1 FROM tab2
----
1588
700
891

query I rowsort
SELECT DISTINCT - cor0.col0 FROM tab0, tab0 AS cor0 CROSS JOIN tab2
----
-24
-35
-89

query I rowsort
SELECT DISTINCT ( + cor0.col1 ) * - col2 + + 8 * 19 FROM tab1 AS cor0
----
-1096
-1252
-418

query I rowsort
SELECT ALL + 60 + - col0 * - col2 FROM tab2 AS cor0
----
2088
249
3062

query I rowsort
SELECT + 69 + col1 FROM tab1 AS cor0
----
79
82
95

query I rowsort
SELECT ALL - 52 + - col0 FROM tab2 AS cor0
----
-130
-131
-59

query I rowsort
SELECT DISTINCT + col0 + + cor0.col0 * - col1 AS col1 FROM tab1 AS cor0
----
-576
-75
-960

query I rowsort
SELECT - + 48 * 11 + col0 FROM tab2 AS cor0
----
-449
-450
-521

query I rowsort
SELECT ALL + - 84 + 6 AS col0 FROM tab2 cor0
----
-78
-78
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-2544
SELECT DISTINCT + ( 52 ) DIV col1 - ( - col2 + col1 ) FROM tab2 AS cor0
----
-3
-33
24

skipif mysql # not compatible
query I rowsort label-2544
SELECT DISTINCT + ( 52 ) / col1 - ( - col2 + col1 ) FROM tab2 AS cor0
----
-3
-33
24

query I rowsort
SELECT + cor0.col0 * ( cor0.col1 ) + 77 AS col2 FROM tab1 cor0
----
1117
155
717

query I rowsort
SELECT ALL + - 88 AS col1 FROM tab2 AS cor0
----
-88
-88
-88

onlyif mysql # use DIV operator for integer division
query I rowsort label-2547
SELECT + - 96 DIV + col2 FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-2547
SELECT + - 96 / + col2 FROM tab1 AS cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT col0 * + col2 - - cor0.col1 FROM tab1 AS cor0
----
188
3658
7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-2549
SELECT DISTINCT + col1 DIV cor0.col1 AS col1 FROM tab2 cor0
----
1

skipif mysql # not compatible
query I rowsort label-2549
SELECT DISTINCT + col1 / cor0.col1 AS col1 FROM tab2 cor0
----
1

query I rowsort
SELECT DISTINCT 28 AS col2 FROM tab2, tab0 cor0, tab0 AS cor1
----
28

query I rowsort
SELECT ALL - - col2 + col0 * - col0 FROM tab0 AS cor0
----
-1224
-543
-7839

query I rowsort
SELECT DISTINCT + cor0.col0 FROM tab2, tab2 AS cor0, tab1 cor1
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 23 col0 FROM tab0 AS cor0
----
23
23
23

query I rowsort
SELECT 52 FROM tab0, tab0 cor0, tab2 AS cor1
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

query I rowsort
SELECT ALL - cor0.col0 * col1 FROM tab1 cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT - - 47 * - col2 AS col2 FROM tab1 AS cor0
----
-2538
-2679
-4512

query I rowsort
SELECT DISTINCT - 91 + + col1 AS col2 FROM tab0 AS cor0
----
-5
0
6

query I rowsort
SELECT - 20 * - col0 + - 57 FROM tab2 AS cor0
----
1503
1523
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT cor0.col0 - - CAST ( col1 AS REAL ) col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT col1 * col0 * - 16 FROM tab0 AS cor0
----
-129584
-33024
-54320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - tab1.col2 * + col1 col2 FROM tab1
----
-1328
-1407
-634

query I rowsort
SELECT - 32 * - 90 FROM tab1, tab2 AS cor0
----
9 values hashing to 0d1ccfb52c0d769cb7224ff3b9ad3f66

onlyif mysql # use DIV operator for integer division
query I rowsort label-2563
SELECT ALL - col0 * col2 - 64 DIV + col0 AS col1 FROM tab0 cor0
----
-36
-7298
-794

skipif mysql # not compatible
query I rowsort label-2563
SELECT ALL - col0 * col2 - 64 / + col0 AS col1 FROM tab0 cor0
----
-36
-7298
-794

onlyif mysql # use DIV operator for integer division
query I rowsort label-2564
SELECT + + col2 - + 91 DIV + col2 AS col2 FROM tab1 AS cor0
----
53
56
96

skipif mysql # not compatible
query I rowsort label-2564
SELECT + + col2 - + 91 / + col2 AS col2 FROM tab1 AS cor0
----
53
56
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2565
SELECT DISTINCT + - col0 * CAST( - col2 + col0 AS SIGNED ) col2 FROM tab1 AS cor0
----
-448
1280
153

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2565
SELECT DISTINCT + - col0 * CAST ( - col2 + col0 AS INTEGER ) col2 FROM tab1 AS cor0
----
-448
1280
153

onlyif mysql # use DIV operator for integer division
query I rowsort label-2566
SELECT + col1 DIV - col2 + + col1 AS col1 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-2566
SELECT + col1 / - col2 + + col1 AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + - 49 + + col0 FROM tab1 AS cor0
----
-46
15
31

query I rowsort
SELECT ALL + col1 * col1 + - col0 FROM tab0 cor0
----
7372
8192
9374

query I rowsort
SELECT ALL 14 * + 64 FROM tab1 AS cor0
----
896
896
896

query I rowsort
SELECT ALL col2 - + 67 * col2 FROM tab2 AS cor0
----
-1716
-1782
-2508

query I rowsort
SELECT + 0 * col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col1 + + ( col0 + col2 ) AS col2 FROM tab1
----
131
189
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2573
SELECT DISTINCT + col1 + CAST( col0 * - col2 AS SIGNED ) col1 FROM tab2
----
-158
-1969
-2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2573
SELECT DISTINCT + col1 + CAST ( col0 * - col2 AS INTEGER ) col1 FROM tab2
----
-158
-1969
-2985

query I rowsort
SELECT DISTINCT + 82 + 83 AS col2 FROM tab0, tab1 AS cor0
----
165

query I rowsort
SELECT DISTINCT - tab0.col1 - - 90 * col1 AS col0 FROM tab0
----
7654
8099
8633

onlyif mysql # use DIV operator for integer division
query I rowsort label-2576
SELECT ALL + tab1.col0 DIV - ( + col0 ) - + col2 FROM tab1
----
-55
-58
-97

skipif mysql # not compatible
query I rowsort label-2576
SELECT ALL + tab1.col0 / - ( + col0 ) - + col2 FROM tab1
----
-55
-58
-97

query I rowsort
SELECT + col2 * col0 + col0 + col2 * - col1 * + 72 AS col1 FROM tab1
----
-100923
-37328
-82096

query I rowsort
SELECT ALL + + col0 * + cor0.col2 * - 12 FROM tab2 AS cor0
----
-2268
-24336
-36024

query I rowsort
SELECT + - 8 AS col0 FROM tab2 AS cor0
----
-8
-8
-8

query I rowsort
SELECT + 22 FROM tab1, tab1 AS cor0, tab2 cor1, tab2, tab2 AS cor2
----
243 values hashing to f10165a092a8197ed57ae9ede3983477

query I rowsort
SELECT col1 + + col2 * - 12 AS col0 FROM tab0 AS cor0
----
-310
-893
85

query I rowsort
SELECT - col1 + col1 * ( 47 ) FROM tab2 AS cor0
----
1426
2714
782

onlyif mysql # use DIV operator for integer division
query I rowsort label-2583
SELECT 91 DIV + cor1.col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 3daf191600c64328f2c60722189235c6

skipif mysql # not compatible
query I rowsort label-2583
SELECT 91 / + cor1.col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 3daf191600c64328f2c60722189235c6

query I rowsort
SELECT - col0 * + col2 + + 31 AS col2 FROM tab0 AS cor0
----
-4
-7267
-761

query I rowsort
SELECT DISTINCT col0 * col0 * + col2 AS col1 FROM tab0
----
1225
19008
649522

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 * cor0.col0 col0 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT - 81 * col0 + - cor0.col1 * ( 53 + col1 ) FROM tab0 AS cor0
----
-13898
-17385
-20313

query I rowsort
SELECT - col0 * + 7 FROM tab0 cor0
----
-168
-245
-623

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2589
SELECT - - CAST( NULL AS DECIMAL ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2589
SELECT - - CAST ( NULL AS REAL ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col1 * col0 * + col0 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT ALL - 32 + col0 * - col2 FROM tab0 cor0
----
-67
-7330
-824

query I rowsort
SELECT ALL - 30 * - 55 AS col1 FROM tab0 AS cor0
----
1650
1650
1650

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2593
SELECT - - CAST( NULL AS DECIMAL ) + + col2 / - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2593
SELECT - - CAST ( NULL AS REAL ) + + col2 / - col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 + 27 * + col0 AS col0 FROM tab1 AS cor0
----
135
1785
2256

query I rowsort
SELECT + ( + col2 ) + - col1 * + 98 AS col1 FROM tab2 cor0
----
-1628
-3011
-5756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col1 + col2 col0 FROM tab1
----
109
67
80

query I rowsort
SELECT col1 + - col0 * - 42 AS col1 FROM tab1
----
152
2698
3373

query I rowsort
SELECT col1 * + 41 AS col2 FROM tab2
----
1271
2419
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-2599
SELECT ALL + col1 DIV + cor0.col2 + col2 AS col0 FROM tab0 AS cor0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-2599
SELECT ALL + col1 / + cor0.col2 + col2 AS col0 FROM tab0 AS cor0
----
35
83
98

query I rowsort
SELECT - 14 + 37 FROM tab0 AS cor0
----
23
23
23

query I rowsort
SELECT DISTINCT col0 * 9 FROM tab1 AS cor0
----
27
576
720

query I rowsort
SELECT - + 85 AS col2 FROM tab0 AS cor0
----
-85
-85
-85

query I rowsort
SELECT ALL + col1 * + 72 AS col1 FROM tab1 AS cor0
----
1872
720
936

query I rowsort
SELECT ALL - ( col0 ) * - col0 AS col0 FROM tab0 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-2605
SELECT DISTINCT + cor0.col0 + col1 DIV + col0 AS col2 FROM tab0 AS cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-2605
SELECT DISTINCT + cor0.col0 + col1 / + col0 AS col2 FROM tab0 AS cor0
----
27
37
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2606
SELECT ALL - cor0.col1 + col1 DIV col0 FROM tab2 AS cor0
----
-17
-27
-59

skipif mysql # not compatible
query I rowsort label-2606
SELECT ALL - cor0.col1 + col1 / col0 FROM tab2 AS cor0
----
-17
-27
-59

query I rowsort
SELECT + cor0.col1 + col2 * col0 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT + col0 * ( cor0.col1 ) + - col0 * col0 FROM tab2 AS cor0
----
-1482
-4898
168

query I rowsort
SELECT - col1 + col1 * ( - 10 ) FROM tab2 AS cor0
----
-187
-341
-649

onlyif mysql # use DIV operator for integer division
query I rowsort label-2610
SELECT + col1 * col0 DIV 15 FROM tab1 AS cor0
----
42
5
69

skipif mysql # not compatible
query I rowsort label-2610
SELECT + col1 * col0 / 15 FROM tab1 AS cor0
----
42
5
69

query I rowsort
SELECT 38 AS col2 FROM tab2, tab1 cor0
----
9 values hashing to afaddad0a4e3a1683a1c8cbe6eb522a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-2612
SELECT col0 + col0 DIV col0 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-2612
SELECT col0 + col0 / col0 FROM tab1 AS cor0
----
4
65
81

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 AS cor2, tab1 AS cor3
----
3645 values hashing to f1666fadc663c90ea9374fcb108b4477

query I rowsort
SELECT DISTINCT - cor0.col2 + - 50 * col1 FROM tab2 AS cor0
----
-1577
-2976
-888

query I rowsort
SELECT - cor0.col2 * + 42 - col0 FROM tab1 AS cor0
----
-2271
-2458
-4112

query I rowsort
SELECT col2 * col1 + col0 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # use DIV operator for integer division
query I rowsort label-2617
SELECT + col0 * 19 - col2 DIV col0 AS col1 FROM tab1 AS cor0
----
1216
1519
39

skipif mysql # not compatible
query I rowsort label-2617
SELECT + col0 * 19 - col2 / col0 AS col1 FROM tab1 AS cor0
----
1216
1519
39

query I rowsort
SELECT DISTINCT ( + cor0.col2 ) FROM tab2, tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL col2 + - cor0.col0 + + col1 AS col1 FROM tab1 cor0
----
29
3
77

query I rowsort
SELECT ALL + col2 * col1 + col1 AS col0 FROM tab1 cor0
----
1261
1430
580

query I rowsort
SELECT col2 * 8 FROM tab1
----
432
456
768

query I rowsort
SELECT + ( - col0 ) * + col0 + col2 * + 76 AS col2 FROM tab2 AS cor0
----
-3353
-4108
2003

query I rowsort
SELECT ALL cor0.col1 * 3 FROM tab0, tab1 AS cor0
----
9 values hashing to cacf0ba35039da025097d1a815f2bb63

onlyif mysql # use DIV operator for integer division
query I rowsort label-2624
SELECT + col1 * - col1 + - col2 + col2 DIV + col2 FROM tab1 cor0
----
-156
-264
-729

skipif mysql # not compatible
query I rowsort label-2624
SELECT + col1 * - col1 + - col2 + col2 / + col2 FROM tab1 cor0
----
-156
-264
-729

query I rowsort
SELECT ALL cor0.col0 + - ( + cor0.col1 ) * - col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT - + col2 * 98 + - col0 FROM tab2 cor0
----
-2626
-2653
-3803

query I rowsort
SELECT - col1 * ( col1 ) * + col1 + + col1 AS col0 FROM tab0 AS cor0
----
-635970
-753480
-912576

query I rowsort
SELECT DISTINCT - cor0.col2 * - 61 FROM tab1 AS cor0
----
3294
3477
5856

query I rowsort
SELECT - - cor0.col1 + ( - col1 * col0 ) FROM tab2 cor0
----
-1326
-186
-4543

onlyif mysql # use DIV operator for integer division
query I rowsort label-2630
SELECT - cor0.col2 + ( + 42 ) * - cor0.col1 DIV col1 col2 FROM tab2 cor0
----
-68
-69
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2630
SELECT - cor0.col2 + ( + 42 ) * - cor0.col1 / col1 col2 FROM tab2 cor0
----
-68
-69
-80

query I rowsort
SELECT + col1 + col0 * col0 AS col2 FROM tab1 cor0
----
35
4106
6413

query I rowsort
SELECT DISTINCT + - col2 * 64 FROM tab0 cor0
----
-2112
-5248
-64

query I rowsort
SELECT ALL col1 * + 16 FROM tab1 AS cor0
----
160
208
416

query I rowsort
SELECT + cor0.col0 + - col2 * col1 AS col1 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT - col1 * 63 * + 17 FROM tab0
----
-103887
-92106
-97461

query I rowsort
SELECT cor0.col1 FROM tab1 cor0 CROSS JOIN tab2, tab2 cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL + - col1 + col2 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT + col0 - ( col0 * + 36 ) AS col1 FROM tab1 AS cor0
----
-105
-2240
-2800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2639
SELECT ALL + tab1.col2 + CAST( - ( - col2 ) AS SIGNED ) FROM tab1
----
108
114
192

skipif mysql # not compatible
query I rowsort label-2639
SELECT ALL + tab1.col2 + CAST ( - ( - col2 ) AS INTEGER ) FROM tab1
----
108
114
192

query I rowsort
SELECT DISTINCT + 5 AS col2 FROM tab1, tab1 AS cor0
----
5

query I rowsort
SELECT - col2 * - 56 * - 14 + col2 AS col2 FROM tab1
----
-42282
-44631
-75168

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - cor0.col2 * col1 col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT col0 * ( - col2 ) AS col0 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT ALL - 23 * - col2 * tab0.col2 AS col0 FROM tab0
----
154652
23
25047

query I rowsort
SELECT ALL + 0 FROM tab2, tab1 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + - ( + col1 ) * col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - col0 * 62 FROM tab2
----
-434
-4836
-4898

query I rowsort
SELECT ALL + ( - 89 * - col2 ) FROM tab2
----
2314
2403
3382

query I rowsort
SELECT col1 * col2 * col1 FROM tab0
----
244068
679042
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-2650
SELECT ALL col1 DIV - col0 - - 45 FROM tab0
----
42
43
44

skipif mysql # not compatible
query I rowsort label-2650
SELECT ALL col1 / - col0 - - 45 FROM tab0
----
42
43
44

query I rowsort
SELECT ALL col0 + + col1 + 66 * + ( tab2.col1 ) FROM tab2
----
1218
2084
4031

query I rowsort
SELECT ALL + ( - col2 ) + - col2 AS col1 FROM tab1
----
-108
-114
-192

onlyif mysql # use DIV operator for integer division
query I rowsort label-2653
SELECT ALL col2 + col1 * ( 46 ) DIV tab0.col0 FROM tab0
----
128
129
197

skipif mysql # not compatible
query I rowsort label-2653
SELECT ALL col2 + col1 * ( 46 ) / tab0.col0 FROM tab0
----
128
129
197

query I rowsort
SELECT ALL + cor1.col1 AS col1 FROM tab1, tab1 cor0, tab0 cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT ( col2 ) + + 52 FROM tab1
----
106
109
148

onlyif mysql # use DIV operator for integer division
query I rowsort label-2656
SELECT ALL + cor0.col1 DIV 43 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2656
SELECT ALL + cor0.col1 / 43 col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT col1 + + tab1.col1 + col1 FROM tab1
----
30
39
78

query I rowsort
SELECT + + 1 * + cor0.col2 FROM tab1 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT ALL + 54 * 51 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to cab9ea50f3a5e60c00b96e8154f91e68

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 25 col2 FROM tab1 AS cor0
----
-25

query I rowsort
SELECT ALL 56 * + col0 + col2 AS col0 FROM tab1 cor0
----
222
3641
4576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + col0 + - col0 col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2663
SELECT ALL - 0 + col0 * CAST( ( col1 ) AS SIGNED ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-2663
SELECT ALL - 0 + col0 * CAST ( ( col1 ) AS INTEGER ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + cor0.col0 + - col2 * col0 * 10 + + col1 AS col2 FROM tab1 AS cor0
----
-1591
-36406
-76707

query I rowsort
SELECT - cor0.col2 * + col0 * 14 + + col0 + - col0 FROM tab0 AS cor0
----
-102172
-11088
-490

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2666
SELECT 1 + col1 + CAST( NULL AS SIGNED ) AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2666
SELECT 1 + col1 + CAST ( NULL AS INTEGER ) AS col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2667
SELECT col0 * - CAST( col1 AS SIGNED ) FROM tab0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-2667
SELECT col0 * - CAST ( col1 AS INTEGER ) FROM tab0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-2668
SELECT + col1 DIV - 30 + 72 + col2 col1 FROM tab2 cor0
----
110
97
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2668
SELECT + col1 / - 30 + 72 + col2 col1 FROM tab2 cor0
----
110
97
98

query I rowsort
SELECT - - col0 * + col2 + - col0 * col2 + - ( 69 ) AS col1 FROM tab1 AS cor0
----
-69
-69
-69

query I rowsort
SELECT ALL - col1 + col2 + - cor0.col2 * - col1 FROM tab0 AS cor0
----
1
2785
7453

query I rowsort
SELECT DISTINCT + col0 * ( 42 ) + - col2 AS col0 FROM tab0
----
1469
3656
975

query I rowsort
SELECT + col1 * col1 + + 58 * col0 + col0 FROM tab2
----
1374
4950
8083

query I rowsort
SELECT ALL col2 + + ( + 76 ) FROM tab2 AS cor0
----
102
103
114

query I rowsort
SELECT col0 * col1 + 77 + col0 AS col2 FROM tab0 AS cor0
----
2165
3507
8265

query I rowsort
SELECT + ( 25 ) * - col0 AS col1 FROM tab1 AS cor0
----
-1600
-2000
-75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2676
SELECT CAST( NULL AS SIGNED ) * + col2 + + col0 * - ( + col1 ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2676
SELECT CAST ( NULL AS INTEGER ) * + col2 + + col0 * - ( + col1 ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 19 col2 FROM tab2
----
19

query I rowsort
SELECT DISTINCT - - ( col2 ) + + col2 * ( cor0.col2 ) FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT + + ( ( - col0 ) ) * 43 FROM tab1 AS cor0
----
-129
-2752
-3440

query I rowsort
SELECT DISTINCT 64 FROM tab0, tab0 AS cor0
----
64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2681
SELECT - col2 + + col1 * - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2681
SELECT - col2 + + col1 * - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 + col2 * + 60 AS col2 FROM tab2 AS cor0
----
1586
1647
2318

query I rowsort
SELECT DISTINCT cor0.col0 - + col1 AS col0 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT col1 + + cor0.col2 * + ( + col2 ) FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT DISTINCT ( - col0 ) + + col0 * + col0 AS col0 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT ALL + 90 * col0 AS col1 FROM tab1 AS cor0
----
270
5760
7200

query I rowsort
SELECT ALL col2 * col0 + col2 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT - 12 * col0 - col1 FROM tab1
----
-62
-778
-973

query I rowsort
SELECT + ( - tab0.col0 + col0 ) AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - col0 * col1 + col2 * col0 AS col2 FROM tab1 AS cor0
----
3008
6640
84

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT + col1 BETWEEN NULL AND NULL
----

query I rowsort
SELECT tab2.col2 * col2 - - col1 AS col2 FROM tab2
----
1461
735
760

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL <> col0
----

query I rowsort
SELECT col0 + - col2 * - col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT ALL - col2 + col1 * - col2 AS col2 FROM tab0
----
-2871
-7544
-98

query I rowsort
SELECT + col1 * col2 - + col2 AS col1 FROM tab2
----
1508
608
810

onlyif mysql # use DIV operator for integer division
query I rowsort label-2697
SELECT col2 * col0 - col1 DIV - col0 FROM tab1
----
170
3648
7680

skipif mysql # not compatible
query I rowsort label-2697
SELECT col2 * col0 - col1 / - col0 FROM tab1
----
170
3648
7680

query I rowsort
SELECT - - 47 * + col1 AS col1 FROM tab0 AS cor0
----
4042
4277
4559

query I rowsort
SELECT DISTINCT + ( col0 ) * ( - cor0.col1 ) FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT - col1 + col0 AS col0 FROM tab1 WHERE NOT col1 * - col0 * col1 = ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-2701
SELECT - col1 DIV col1 - col0 * col0 FROM tab1
----
-10
-4097
-6401

skipif mysql # not compatible
query I rowsort label-2701
SELECT - col1 / col1 - col0 * col0 FROM tab1
----
-10
-4097
-6401

query I rowsort
SELECT DISTINCT + tab0.col1 + + tab0.col0 * col2 FROM tab0
----
132
7389
878

query III rowsort
SELECT DISTINCT * FROM tab1 AS cor0 WHERE NOT col0 * + col0 + + cor0.col2 + col2 * col2 BETWEEN + col1 * col0 AND NULL
----

query I rowsort
SELECT DISTINCT col1 - + col1 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 - - col1 col0 FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT DISTINCT col2 - + col0 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT + tab1.col2 * - col0 + + col0 * col1 FROM tab1
----
-3008
-6640
-84

query I rowsort
SELECT DISTINCT + col1 + + col0 * + col0 + col0 FROM tab1
----
38
4170
6493

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * - col0 col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT tab1.col0 * - col0 + + col1 + col1 * - col2 * + col2 AS col0 FROM tab1
----
-126195
-36576
-75799

query I rowsort
SELECT DISTINCT + col0 * + col0 + col0 * tab1.col2 FROM tab1
----
14080
171
7744

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( NULL ) <> col2 + tab1.col0
----

query I rowsort
SELECT + col1 + + col2 * + tab1.col1 + col0 FROM tab1
----
1341
1433
644

onlyif mysql # use DIV operator for integer division
query I rowsort label-2714
SELECT DISTINCT - col2 + col0 DIV col2 AS col1 FROM tab1
----
-54
-56
-96

skipif mysql # not compatible
query I rowsort label-2714
SELECT DISTINCT - col2 + col0 / col2 AS col1 FROM tab1
----
-54
-56
-96

query I rowsort
SELECT col1 * col0 * - col1 FROM tab0 WHERE NOT NULL IN ( col0 )
----

query I rowsort
SELECT - col1 * - col1 + col1 AS col2 FROM tab0
----
7482
8372
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-2717
SELECT - 41 DIV cor0.col0 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to b2e225572af74ba853e10fb5414ea67f

skipif mysql # not compatible
query I rowsort label-2717
SELECT - 41 / cor0.col0 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to b2e225572af74ba853e10fb5414ea67f

skipif mysql # not compatible
query I rowsort
SELECT - + CAST ( 58 AS REAL ) * - col1 * col2 FROM tab1 cor0
----
33060
72384
81432

query I rowsort
SELECT DISTINCT ( + col0 + col0 ) AS col2 FROM tab0
----
178
48
70

query I rowsort
SELECT ALL + + col1 + + col1 AS col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT DISTINCT 53 * + col1 + + col1 * col1 FROM tab1 AS cor0
----
2054
630
858

query I rowsort
SELECT DISTINCT 77 * + col2 + - cor0.col0 * - 56 FROM tab2 AS cor0
----
2471
6370
7350

onlyif mysql # use DIV operator for integer division
query I rowsort label-2723
SELECT DISTINCT + 47 + - col1 DIV 21 FROM tab1 AS cor0
----
46
47

skipif mysql # not compatible
query I rowsort label-2723
SELECT DISTINCT + 47 + - col1 / 21 FROM tab1 AS cor0
----
46
47

onlyif mysql # use DIV operator for integer division
query I rowsort label-2724
SELECT DISTINCT 87 + + col2 + col0 DIV col0 AS col1 FROM tab2 AS cor0
----
114
115
126

skipif mysql # not compatible
query I rowsort label-2724
SELECT DISTINCT 87 + + col2 + col0 / col0 AS col1 FROM tab2 AS cor0
----
114
115
126

query I rowsort
SELECT ALL - 68 + - 10 * col2 FROM tab1
----
-1028
-608
-638

query I rowsort
SELECT ALL col1 * tab2.col0 + col2 FROM tab2
----
1381
244
4628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2727
SELECT DISTINCT CAST( NULL AS SIGNED ) * col0 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2727
SELECT DISTINCT CAST ( NULL AS INTEGER ) * col0 FROM tab1
----
NULL

query I rowsort
SELECT col1 + col0 * - 35 FROM tab1 AS cor0
----
-2230
-2787
-79

query I rowsort
SELECT ALL ( - 82 ) FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to ce62f59690969f4492d78eb57c3181f0

query I rowsort
SELECT + cor0.col1 - col2 AS col2 FROM tab1 AS cor0
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + 77 col2 FROM tab1 AS cor0
----
1001
2002
770

query I rowsort
SELECT cor0.col1 * col1 * - 68 AS col0 FROM tab2 AS cor0
----
-19652
-236708
-65348

query I rowsort
SELECT ALL ( 24 ) + col0 * + col1 FROM tab0
----
2088
3419
8123

query I rowsort
SELECT DISTINCT ( col0 ) + col2 - col0 AS col0 FROM tab1
----
54
57
96

query I rowsort
SELECT ALL ( col2 ) - - col2 FROM tab2
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - tab0.col2 ) + col1 * + col2 + col1 col2 FROM tab0
----
193
2891
7471

query I rowsort
SELECT ALL - col0 + 47 * - col0 AS col2 FROM tab0
----
-1152
-1680
-4272

onlyif mysql # use DIV operator for integer division
query I rowsort label-2738
SELECT DISTINCT - - ( 37 ) + cor0.col0 DIV col0 AS col1 FROM tab2 AS cor0
----
38

skipif mysql # not compatible
query I rowsort label-2738
SELECT DISTINCT - - ( 37 ) + cor0.col0 / col0 AS col1 FROM tab2 AS cor0
----
38

query I rowsort
SELECT + col1 * - 47 + + col1 AS col2 FROM tab2 AS cor0
----
-1426
-2714
-782

query I rowsort
SELECT ALL + + cor0.col1 - - col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL cor1.col2 AS col0 FROM tab2, tab0 AS cor0, tab2 cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT ALL - ( + 87 ) + - col0 AS col2 FROM tab1 AS cor0
----
-151
-167
-90

onlyif mysql # use DIV operator for integer division
query I rowsort label-2743
SELECT ALL + ( - col2 ) + col1 DIV col1 FROM tab0
----
-32
-81
0

skipif mysql # not compatible
query I rowsort label-2743
SELECT ALL + ( - col2 ) + col1 / col1 FROM tab0
----
-32
-81
0

query I rowsort
SELECT DISTINCT + col2 + + cor0.col1 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT - col1 * col2 + col2 * + col2 AS col1 FROM tab2 AS cor0
----
-108
-858
798

onlyif mysql # use DIV operator for integer division
query I rowsort label-2746
SELECT + - col1 DIV col0 AS col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-2746
SELECT + - col1 / col0 AS col0 FROM tab1 AS cor0
----
-8
0
0

query I rowsort
SELECT ALL + ( col1 ) * col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT - 59 * col1 + - cor0.col0 + col0 AS col1 FROM tab0 cor0
----
-5074
-5369
-5723

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 39 * col0 + col2 col1 FROM tab0 AS cor0
----
-1364
-3389
-903

query I rowsort
SELECT DISTINCT - col2 + col1 * cor0.col0 * col2 AS col1 FROM tab0 AS cor0
----
3394
664036
68079

query I rowsort
SELECT ALL + col2 + + col0 - + col0 * - col1 FROM tab2 AS cor0
----
1460
251
4706

query I rowsort
SELECT DISTINCT + col2 + col2 FROM tab1 cor0
----
108
114
192

query I rowsort
SELECT col1 * - col2 * + col1 AS col2 FROM tab2
----
-10982
-25947
-90506

query I rowsort
SELECT DISTINCT + 1 + col0 * col1 + + col1 * col2 AS col2 FROM tab0 AS cor0
----
15562
3493
4903

query I rowsort
SELECT DISTINCT - + ( cor0.col2 ) + - col1 FROM tab1 cor0
----
-109
-67
-80

query I rowsort
SELECT 45 * - col0 + + col0 * col0 AS col2 FROM tab0 cor0
----
-350
-504
3916

query I rowsort
SELECT ALL + + col0 * - cor0.col1 + + col2 * - cor0.col0 FROM tab0 AS cor0
----
-15397
-2856
-3430

query I rowsort
SELECT + col1 * - col0 + + col1 * col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - cor0.col2 + cor0.col1 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT + col2 + + 71 AS col2 FROM tab1 AS cor0
----
125
128
167

query I rowsort
SELECT + col1 + + 22 FROM tab2 AS cor0
----
39
53
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col1 * 51 col0 FROM tab1 AS cor0
----
1326
510
663

query I rowsort
SELECT ALL tab2.col2 * + 16 FROM tab2, tab2 AS cor0
----
9 values hashing to d059351c64af69b130200d54d42fcde1

query I rowsort
SELECT DISTINCT col1 + + ( col1 ) AS col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL - col0 * 26 FROM tab2 AS cor0
----
-182
-2028
-2054

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * col1 + 87 col1 FROM tab2 cor0
----
1430
304
4689

query I rowsort
SELECT ALL - - col1 + col2 AS col0 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT col1 - - 46 FROM tab0 AS cor0
----
132
137
143

query I rowsort
SELECT - col1 * - 36 FROM tab2 AS cor0
----
1116
2124
612

query I rowsort
SELECT ALL col0 + 60 * - col2 AS col1 FROM tab0 AS cor0
----
-1956
-25
-4831

query I rowsort
SELECT DISTINCT + col1 + + 16 * 10 + col2 * - col0 FROM tab1 AS cor0
----
-3478
-7507
24

query I rowsort
SELECT DISTINCT - 54 + - col0 FROM tab0 AS cor0
----
-143
-78
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-2773
SELECT + col0 DIV - ( col0 ) - cor0.col0 AS col1 FROM tab2 AS cor0
----
-79
-8
-80

skipif mysql # not compatible
query I rowsort label-2773
SELECT + col0 / - ( col0 ) - cor0.col0 AS col1 FROM tab2 AS cor0
----
-79
-8
-80

query I rowsort
SELECT ALL cor0.col2 * col1 AS col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT DISTINCT ( + ( + tab1.col0 ) ) FROM tab1, tab0 AS cor0
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col0 * col2 - + col1 col0 FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT DISTINCT - col2 * col1 + + col1 FROM tab2 AS cor0
----
-1475
-629
-806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 - col0 * col0 col0 FROM tab1 AS cor0
----
-4086
-6387
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-2779
SELECT DISTINCT - + col1 + + col1 DIV cor0.col1 FROM tab2 AS cor0
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-2779
SELECT DISTINCT - + col1 + + col1 / cor0.col1 FROM tab2 AS cor0
----
-16
-30
-58

query I rowsort
SELECT ALL - + col1 + + cor0.col0 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT + - col0 * + col0 + col0 FROM tab2 AS cor0
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT + col2 * - tab0.col0 * tab0.col1 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT col1 * - col2 + - col2 * col2 AS col1 FROM tab1
----
-10464
-3819
-4320

query I rowsort
SELECT - col0 + - tab2.col2 AS col1 FROM tab2
----
-104
-117
-34

query I rowsort
SELECT ALL - col2 * - tab2.col2 + + col2 AS col1 FROM tab2
----
1482
702
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-2786
SELECT DISTINCT + - col1 + - col2 DIV col0 + col0 FROM tab2 AS cor0
----
-27
19
62

skipif mysql # not compatible
query I rowsort label-2786
SELECT DISTINCT + - col1 + - col2 / col0 + col0 FROM tab2 AS cor0
----
-27
19
62

query I rowsort
SELECT DISTINCT - col2 + + col0 * + col0 FROM tab1
----
-45
4039
6304

query I rowsort
SELECT tab2.col0 FROM tab2 WHERE NOT NULL IN ( col1 )
----

query I rowsort
SELECT DISTINCT - ( col0 ) + col0 + + tab0.col0 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab2.col0 col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT DISTINCT col1 * - col1 + + col0 * col2 FROM tab2
----
-1453
-772
2713

query I rowsort
SELECT - tab1.col1 + + tab1.col1 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT - - col0 * col2 AS col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - cor0.col2 * - col2 FROM tab1 AS cor0
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col2 * col0 col2 FROM tab0 AS cor0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2796
SELECT DISTINCT + col1 * col0 DIV - col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-2796
SELECT DISTINCT + col1 * col0 / - col1 FROM tab1 AS cor0
----
-3
-64
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + col2 col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 + 99 * + col1 AS col1 FROM tab2 cor0
----
1666
3038
5782

query I rowsort
SELECT DISTINCT 60 * col0 + + col2 + + col0 FROM tab1
----
237
3961
4976

onlyif mysql # use DIV operator for integer division
query I rowsort label-2800
SELECT ALL + col1 DIV + ( 3 ) FROM tab0
----
28
30
32

skipif mysql # not compatible
query I rowsort label-2800
SELECT ALL + col1 / + ( 3 ) FROM tab0
----
28
30
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + - ( 43 ) col0 FROM tab0 AS cor0
----
-10
-42
39

query I rowsort
SELECT DISTINCT - - cor0.col1 * 70 FROM tab0 AS cor0
----
6020
6370
6790

onlyif mysql # use DIV operator for integer division
query I rowsort label-2803
SELECT - - cor0.col2 DIV + ( 37 ) FROM tab0 cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-2803
SELECT - - cor0.col2 / + ( 37 ) FROM tab0 cor0
----
0
0
2

query I rowsort
SELECT ALL - ( + 57 * col0 ) AS col2 FROM tab0
----
-1368
-1995
-5073

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2805
SELECT DISTINCT col1 * - col2 + + col1 * CAST( NULL AS SIGNED ) + 13 AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-2805
SELECT DISTINCT col1 * - col2 + + col1 * CAST ( NULL AS INTEGER ) + 13 AS col1 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * col1 + col2 col1 FROM tab0 AS cor0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-2807
SELECT - col1 DIV - 95 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2807
SELECT - col1 / - 95 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - + cor0.col1 * + col1 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL - 52 + col2 FROM tab2 AS cor0
----
-14
-25
-26

query I rowsort
SELECT ALL - + col2 * cor0.col0 + - col1 AS col1 FROM tab0 AS cor0
----
-132
-7389
-878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * + 96 col0 FROM tab2 AS cor0
----
1632
2976
5664

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + 53 * col0 + col2 * col0 col1 FROM tab1 AS cor0
----
256
3
3440

query I rowsort
SELECT DISTINCT col0 * - col2 + ( + cor0.col1 ) FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT - + col1 - cor0.col2 * cor0.col2 AS col0 FROM tab2 cor0
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT - 99 * col1 AS col0 FROM tab0 AS cor0
----
-8514
-9009
-9603

query I rowsort
SELECT col1 + - col1 * ( + 78 ) * - col0 AS col1 FROM tab0 AS cor0
----
161078
264907
631813

query I rowsort
SELECT ALL + tab0.col2 * + cor0.col2 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to a477aa402dcd904394a585dfd5cfe837

query I rowsort
SELECT + - col1 * + col2 - - col0 FROM tab0 AS cor0
----
-2814
-62
-7373

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col2 ) + - 5 col0 FROM tab2 AS cor0
----
-31
-32
-43

query I rowsort
SELECT ALL - - 35 * - col1 FROM tab0 AS cor0
----
-3010
-3185
-3395

query I rowsort
SELECT ALL + + col2 * - cor0.col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + 19 AS col0 FROM tab2 cor0
----
19
19
19

query I rowsort
SELECT col0 * - cor0.col1 + ( - cor0.col2 ) + + col0 * + cor0.col0 * col2 AS col2 FROM tab2 cor0
----
1079
153556
235777

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * + col1 * ( - col0 ) + - col1 * ( col1 ) col0 FROM tab0 AS cor0
----
-12804
-672399
-75508

onlyif mysql # use DIV operator for integer division
query I rowsort label-2825
SELECT 16 * col1 DIV + col1 col1 FROM tab1
----
16
16
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2825
SELECT 16 * col1 / + col1 col1 FROM tab1
----
16
16
16

onlyif mysql # use DIV operator for integer division
query I rowsort label-2826
SELECT col1 * col0 DIV col0 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-2826
SELECT col1 * col0 / col0 FROM tab2
----
17
31
59

query I rowsort
SELECT col0 - col2 AS col1 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ALL col1 * + ( col1 ) + col2 * + col1 FROM tab2 cor0
----
1798
5015
935

onlyif mysql # use DIV operator for integer division
query I rowsort label-2829
SELECT + col1 DIV col2 - + 21 AS col0 FROM tab1 AS cor0
----
-21
-21
-21

skipif mysql # not compatible
query I rowsort label-2829
SELECT + col1 / col2 - + 21 AS col0 FROM tab1 AS cor0
----
-21
-21
-21

query I rowsort
SELECT - + col0 * col0 + col1 * - col1 AS col1 FROM tab2 AS cor0
----
-1010
-6530
-9565

query I rowsort
SELECT DISTINCT - tab1.col0 * ( + 7 ) + + cor0.col1 * cor0.col0 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to f5e88ae481069d94a5160a8ec0b1301f

query I rowsort
SELECT DISTINCT - tab1.col1 FROM tab1, tab1 cor0, tab2 AS cor1
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2833
SELECT DISTINCT col1 - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2833
SELECT DISTINCT col1 - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT cor0.col1 + - 91 FROM tab2 AS cor0
----
-32
-60
-74

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2835
SELECT - CAST( NULL AS SIGNED ) * - 36 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2835
SELECT - CAST ( NULL AS INTEGER ) * - 36 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 54 * + ( col2 ) * col2 AS col0 FROM tab2 AS cor0
----
36504
39366
77976

query I rowsort
SELECT - + ( - col0 ) * col1 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - + ( col1 ) * col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + 95 + tab0.col1 FROM tab0, tab0 AS cor0
----
9 values hashing to 9076ec394c2c32931f8c8423ec9c6888

query I rowsort
SELECT - + 73 FROM tab1 AS cor0
----
-73
-73
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-2841
SELECT + - col0 DIV 90 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-2841
SELECT + - col0 / 90 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2842
SELECT + - CAST( + col0 AS SIGNED ) + - col1 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort label-2842
SELECT + - CAST ( + col0 AS INTEGER ) + - col1 AS col0 FROM tab1 AS cor0
----
-29
-74
-93

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col2 AS REAL ) AS col1 FROM tab2
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2844
SELECT DISTINCT + col1 / + CAST( NULL AS SIGNED ) FROM tab2
----
NULL

skipif mysql # not compatible
query I rowsort label-2844
SELECT DISTINCT + col1 / + CAST ( NULL AS INTEGER ) FROM tab2
----
NULL

query I rowsort
SELECT - col1 + tab0.col0 AS col0 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT 49 + - col0 AS col2 FROM tab0 AS cor0
----
-40
14
25

query I rowsort
SELECT DISTINCT - col1 * - 60 AS col2 FROM tab1 AS cor0
----
1560
600
780

onlyif mysql # use DIV operator for integer division
query I rowsort label-2848
SELECT ALL cor0.col2 DIV - cor0.col1 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-2848
SELECT ALL cor0.col2 / - cor0.col1 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT - 34 * 0 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 3 col0 FROM tab2 AS cor0
----
3

query I rowsort
SELECT ALL 88 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

query I rowsort
SELECT - col0 * col2 - - 93 FROM tab0
----
-699
-7205
58

query I rowsort
SELECT col1 + col1 + tab1.col2 AS col1 FROM tab1
----
106
122
77

query I rowsort
SELECT col2 + 48 + - col2 AS col2 FROM tab1 cor0
----
48
48
48

query I rowsort
SELECT ( + 39 ) * col0 FROM tab0 AS cor0
----
1365
3471
936

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab1 cor2
----
3645 values hashing to 97b2ae21242e1e40418ee2ad06544f7a

query I rowsort
SELECT col1 * - col2 + col2 + col1 AS col1 FROM tab1
----
-1139
-1324
-503

query I rowsort
SELECT DISTINCT + 59 + col0 + col2 FROM tab1
----
116
180
235

onlyif mysql # use DIV operator for integer division
query I rowsort label-2859
SELECT DISTINCT + ( col1 ) DIV col1 FROM tab0 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-2859
SELECT DISTINCT + ( col1 ) / col1 FROM tab0 AS cor0
----
1

query I rowsort
SELECT DISTINCT - col2 + + 83 * + col2 FROM tab1 AS cor0
----
4428
4674
7872

query I rowsort
SELECT + col1 * + cor0.col2 + + col1 + - col1 * - col0 FROM tab2 AS cor0
----
1085
2006
6195

query I rowsort
SELECT ALL - 85 * - col2 AS col1 FROM tab2 AS cor0
----
2210
2295
3230

query I rowsort
SELECT DISTINCT - - col2 + - 49 FROM tab1 AS cor0
----
47
5
8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 90 + + col1 * + col1 + col1 * + col0 * + col2 col1 FROM tab1 AS cor0
----
36490
4798
99919

query I rowsort
SELECT ALL - - col1 * + col1 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT ALL - 79 + col0 AS col0 FROM tab2
----
-1
-72
0

query I rowsort
SELECT DISTINCT + 30 + cor1.col2 AS col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
126
84
87

query I rowsort
SELECT + col2 * col2 + + ( + col2 ) AS col1 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT - 33 * col2 AS col2 FROM tab2 AS cor0
----
-1254
-858
-891

query I rowsort
SELECT DISTINCT - col0 * col0 + ( + col2 ) * + 66 * col0 FROM tab0 AS cor0
----
1085
473747
51696

query I rowsort
SELECT ALL + col1 * col0 * - col2 + - col2 FROM tab2 AS cor0
----
-119678
-51072
-5886

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2872
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-2872
SELECT + + col0 * CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 29 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 1e7120ba8e9191084172ddced17e5eb2

query I rowsort
SELECT ALL col1 * 61 + col2 * col2 FROM tab0 AS cor0
----
12275
5918
6335

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2875
SELECT ALL - + col2 * 52 + ( + col0 ) * + CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2875
SELECT ALL - + col2 * 52 + ( + col0 ) * + CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2876
SELECT DISTINCT + + col0 + col0 DIV col1 FROM tab2 cor0
----
7
79
83

skipif mysql # not compatible
query I rowsort label-2876
SELECT DISTINCT + + col0 + col0 / col1 FROM tab2 cor0
----
7
79
83

query I rowsort
SELECT ALL - cor0.col0 * col0 * 59 + col2 AS col2 FROM tab2 cor0
----
-2864
-358930
-368181

query I rowsort
SELECT ALL - - cor0.col2 + col1 * 10 FROM tab0 AS cor0
----
893
971
992

query I rowsort
SELECT DISTINCT + - col2 - 55 FROM tab1 AS cor0
----
-109
-112
-151

query I rowsort
SELECT DISTINCT - cor0.col2 * + col1 + - col1 AS col2 FROM tab2 AS cor0
----
-1593
-663
-868

skipif mysql # not compatible
query I rowsort
SELECT ALL col0 / CAST ( cor0.col0 AS REAL ) AS col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + col2 * 92 + + col1 * col0 FROM tab0 AS cor0
----
15643
3487
5100

query I rowsort
SELECT DISTINCT + + col2 - 93 FROM tab1 AS cor0
----
-36
-39
3

query I rowsort
SELECT + + col2 * cor0.col1 + ( - col0 ) * cor0.col2 AS col1 FROM tab2 AS cor0
----
-2356
-494
648

query I rowsort
SELECT + col1 * ( - col0 ) AS col2 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + cor0.col0 * + 42 * col1 FROM tab2 AS cor0
----
193284
56406
9114

query I rowsort
SELECT DISTINCT - col2 + - 91 * 66 AS col1 FROM tab2 AS cor0
----
-6032
-6033
-6044

query I rowsort
SELECT ALL col0 * ( + col1 ) AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + col1 * + ( cor0.col0 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + + ( cor0.col2 ) + - col0 * + cor0.col1 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT ALL - - 71 + + 7 AS col1 FROM tab2 AS cor0
----
78
78
78

query I rowsort
SELECT - col0 * col1 + + ( - col1 ) * + col0 AS col1 FROM tab1
----
-1280
-156
-2080

query I rowsort
SELECT + ( + cor1.col1 ) AS col1 FROM tab0, tab1 AS cor0, tab1, tab2 AS cor1
----
81 values hashing to a5b6acb471910ea4ad7f31cae3b818f7

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 AS cor0 CROSS JOIN tab1, tab0, tab2 AS cor1
----
3645 values hashing to d6a6e32c6adcc8525ed3eb7827781237

query I rowsort
SELECT ALL tab1.col1 - + col1 AS col0 FROM tab1
----
0
0
0

query I rowsort
SELECT + ( cor0.col2 ) + col2 + + col0 FROM tab0 AS cor0
----
253
37
90

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0 CROSS JOIN tab0, tab1 cor1
----
972 values hashing to 5621675b1bd32b061d284d0444c76601

query I rowsort
SELECT DISTINCT 42 AS col2 FROM tab1, tab2 AS cor0
----
42

onlyif mysql # use DIV operator for integer division
query I rowsort label-2899
SELECT DISTINCT ( - col2 ) + 60 DIV col1 AS col0 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-2899
SELECT DISTINCT ( - col2 ) + 60 / col1 AS col0 FROM tab0
----
-1
-33
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - tab0.col1 + + col2 col2 FROM tab0
----
-7363
-8199
-9408

query I rowsort
SELECT ALL - col0 + tab2.col2 FROM tab2
----
-41
-52
20

query I rowsort
SELECT col2 + + col0 + - ( col1 ) FROM tab1
----
111
163
31

query I rowsort
SELECT - col2 * col0 * col2 AS col1 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT + 51 * col0 AS col1 FROM tab0
----
1224
1785
4539

query I rowsort
SELECT - tab0.col0 + col0 * + col1 FROM tab0
----
2040
3360
8010

query I rowsort
SELECT DISTINCT + 22 FROM tab0, tab2, tab1 cor0
----
22

query I rowsort
SELECT DISTINCT - ( + tab1.col2 + + ( - col0 ) ) * col2 * col1 FROM tab1
----
-19968
-71604
3990

query I rowsort
SELECT - col2 + 28 FROM tab0 cor0
----
-5
-54
27

query I rowsort
SELECT - col1 * + col2 * col2 AS col2 FROM tab0 cor0
----
-611884
-93654
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2910
SELECT ( - 21 ) * + col0 - + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-2910
SELECT ( - 21 ) * + col0 - + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 43 + col0 FROM tab2 cor0
----
-36
35
36

query I rowsort
SELECT ALL 31 AS col1 FROM tab0
----
31
31
31

query I rowsort
SELECT ALL + 36 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab2 cor2
----
81 values hashing to e09b197365a04fabbaaf0718d2ae88c5

query I rowsort
SELECT + - col1 * - col2 + + col1 AS col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT cor1.col0 AS col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL col2 * - col0 * - col1 FROM tab0
----
3395
664118
68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2917
SELECT col0 * CAST( - 70 AS SIGNED ) * col2 AS col1 FROM tab1 AS cor0
----
-11340
-255360
-537600

skipif mysql # not compatible
query I rowsort label-2917
SELECT col0 * CAST ( - 70 AS INTEGER ) * col2 AS col1 FROM tab1 AS cor0
----
-11340
-255360
-537600

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2918
SELECT CAST( NULL AS SIGNED ) FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-2918
SELECT CAST ( NULL AS INTEGER ) FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + + col2 * - col1 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT cor0.col0 * - 68 AS col0 FROM tab1 AS cor0
----
-204
-4352
-5440

query I rowsort
SELECT DISTINCT col2 + + col2 * + col2 AS col0 FROM tab0 cor0
----
1122
2
6806

query I rowsort
SELECT ALL 41 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT 5 FROM tab1, tab0 AS cor0
----
9 values hashing to 6035628694bdea36f584f3649088551d

onlyif mysql # use DIV operator for integer division
query I rowsort label-2924
SELECT DISTINCT + ( ( col0 ) ) DIV col1 AS col1 FROM tab1 AS cor0
----
0
6

skipif mysql # not compatible
query I rowsort label-2924
SELECT DISTINCT + ( ( col0 ) ) / col1 AS col1 FROM tab1 AS cor0
----
0
6

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab2 AS cor1, tab0, tab2 AS cor2
----
3645 values hashing to 6a08afba67ce3272fad6d766e76c67f0

query I rowsort
SELECT ALL cor0.col1 FROM tab2 cor0 CROSS JOIN tab2, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT + 20 + - tab2.col1 * col0 * col2 AS col2 FROM tab2
----
-119632
-51014
-5839

query I rowsort
SELECT - 56 - col2 AS col1 FROM tab1
----
-110
-113
-152

query I rowsort
SELECT DISTINCT col1 * + tab2.col1 * col2 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT ALL cor0.col0 + - 75 AS col0 FROM tab1 AS cor0
----
-11
-72
5

query I rowsort
SELECT + col0 * - 8 AS col1 FROM tab1 cor0
----
-24
-512
-640

query I rowsort
SELECT DISTINCT + + col2 + 87 * col1 FROM tab0 AS cor0
----
7515
7999
8440

query I rowsort
SELECT - cor0.col2 * 33 FROM tab2 AS cor0
----
-1254
-858
-891

onlyif mysql # use DIV operator for integer division
query I rowsort label-2934
SELECT DISTINCT - cor1.col2 * 77 DIV 97 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
-42
-45
-76

skipif mysql # not compatible
query I rowsort label-2934
SELECT DISTINCT - cor1.col2 * 77 / 97 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
-42
-45
-76

query I rowsort
SELECT ALL 89 FROM tab2, tab0, tab2 AS cor0
----
27 values hashing to 860d55eb6785972467218a9c3badb5ad

query I rowsort
SELECT ALL + col2 + col1 * tab0.col1 AS col2 FROM tab0
----
7429
8363
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-2937
SELECT + col0 DIV - col1 AS col1 FROM tab1 AS cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-2937
SELECT + col0 / - col1 AS col1 FROM tab1 AS cor0
----
-6
-6
0

query I rowsort
SELECT col1 * + cor0.col2 + col2 AS col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT + + col2 + - col2 * - col0 AS col1 FROM tab0 AS cor0
----
36
7380
825

onlyif mysql # use DIV operator for integer division
query I rowsort label-2940
SELECT ALL + + col1 + cor0.col1 DIV - 14 FROM tab1 cor0
----
10
13
25

skipif mysql # not compatible
query I rowsort label-2940
SELECT ALL + + col1 + cor0.col1 / - 14 FROM tab1 cor0
----
10
13
25

query I rowsort
SELECT DISTINCT + cor0.col2 + + ( + col0 ) * + cor0.col1 AS col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT col1 * + 43 + + col0 FROM tab0 AS cor0
----
3722
4002
4206

query I rowsort
SELECT DISTINCT + col0 * - 98 FROM tab1 cor0
----
-294
-6272
-7840

query I rowsort
SELECT 51 AS col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 02a7de94365b8cb5b5cb92c4b1d1e7c5

query I rowsort
SELECT DISTINCT + col2 - col2 * 59 AS col1 FROM tab1 AS cor0
----
-3132
-3306
-5568

query I rowsort
SELECT ALL col1 * + col2 * - 17 + + ( col0 ) FROM tab2 AS cor0
----
-10903
-14222
-26000

onlyif mysql # use DIV operator for integer division
query I rowsort label-2947
SELECT DISTINCT col0 DIV col0 col2 FROM tab0 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2947
SELECT DISTINCT col0 / col0 col2 FROM tab0 AS cor0
----
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2948
SELECT DISTINCT col2 * + cor0.col2 + + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-2948
SELECT DISTINCT col2 * + cor0.col2 + + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2949
SELECT ALL + col1 DIV - cor0.col0 + + col1 AS col0 FROM tab2 cor0
----
17
27
59

skipif mysql # not compatible
query I rowsort label-2949
SELECT ALL + col1 / - cor0.col0 + + col1 AS col0 FROM tab2 cor0
----
17
27
59

query I rowsort
SELECT ALL ( col1 ) + ( + cor0.col0 ) AS col1 FROM tab2 AS cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 73 col0 FROM tab1
----
73

query I rowsort
SELECT tab0.col0 * + 45 FROM tab0, tab0 AS cor0
----
9 values hashing to 90ed87c3a78469bb23cf152a357665d6

query I rowsort
SELECT 62 + tab0.col2 FROM tab0
----
144
63
95

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col0 + col2 col0 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL - col0 + 29 AS col1 FROM tab0 AS cor0
----
-6
-60
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 * - col2 col0 FROM tab2 AS cor0
----
-1444
-676
-729

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2957
SELECT ( col0 ) + + CAST( NULL AS SIGNED ) col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2957
SELECT ( col0 ) + + CAST ( NULL AS INTEGER ) col1 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-2958
SELECT - col0 + + col0 * col1 DIV - 44 AS col1 FROM tab0
----
-112
-273
-70

skipif mysql # not compatible
query I rowsort label-2958
SELECT - col0 + + col0 * col1 / - 44 AS col1 FROM tab0
----
-112
-273
-70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 72 col2 FROM tab0
----
72

query I rowsort
SELECT ALL col0 + col2 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT DISTINCT + tab2.col0 * - 45 AS col2 FROM tab2
----
-315
-3510
-3555

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 43 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

query I rowsort
SELECT ALL - col1 * col1 + + col0 + + 49 FROM tab0 AS cor0
----
-7323
-8143
-9325

onlyif mysql # use DIV operator for integer division
query I rowsort label-2964
SELECT ALL 31 - - col1 DIV cor0.col1 AS col1 FROM tab1 AS cor0
----
32
32
32

skipif mysql # not compatible
query I rowsort label-2964
SELECT ALL 31 - - col1 / cor0.col1 AS col1 FROM tab1 AS cor0
----
32
32
32

query I rowsort
SELECT col0 * + col1 + col1 * col2 FROM tab0 AS cor0
----
15561
3492
4902

query I rowsort
SELECT - cor0.col1 * col0 + + col0 * + ( col1 + - col1 * 89 ) AS col2 FROM tab0 AS cor0
----
-183696
-302155
-720811

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( col2 AS REAL ) + + col2 / ( col0 * col0 ) col1 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + ( - col2 ) + col0 * + 76 AS col0 FROM tab2 AS cor0
----
505
5902
5966

query I rowsort
SELECT DISTINCT + + ( - 60 ) * col2 FROM tab1 AS cor0
----
-3240
-3420
-5760

query I rowsort
SELECT DISTINCT - + 92 AS col1 FROM tab1 cor0
----
-92

query I rowsort
SELECT ALL - tab1.col2 + + col2 * + 91 * col1 FROM tab1
----
113472
127710
51813

query I rowsort
SELECT DISTINCT - 10 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
-10

query I rowsort
SELECT - col1 + col0 * col2 AS col2 FROM tab1
----
136
3638
7667

query I rowsort
SELECT ALL - tab1.col2 + + ( col0 ) * col0 + col0 AS col0 FROM tab1
----
-42
4103
6384

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 26 col2 FROM tab2
----
182
2028
2054

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( + col0 ) + + cor0.col1 + + 56 col0 FROM tab2 AS cor0
----
-6
37
80

query I rowsort
SELECT DISTINCT + col1 + 47 * cor0.col2 AS col2 FROM tab1 AS cor0
----
2564
2689
4525

query I rowsort
SELECT ALL col1 * col0 * - cor0.col1 AS col0 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT DISTINCT + cor0.col1 + ( + col2 ) FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL - + col1 * + 23 AS col0 FROM tab2 AS cor0
----
-1357
-391
-713

query I rowsort
SELECT - - 66 + + col0 * - col2 FROM tab1 AS cor0
----
-3582
-7614
-96

query I rowsort
SELECT + col1 * 0 AS col1 FROM tab0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-2983
SELECT DISTINCT - col0 DIV col1 + + col2 + 20 col1 FROM tab0
----
102
21
53

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2983
SELECT DISTINCT - col0 / col1 + + col2 + 20 col1 FROM tab0
----
102
21
53

query I rowsort
SELECT - - 12 + + col2 AS col2 FROM tab2 AS cor0
----
38
39
50

query I rowsort
SELECT DISTINCT col0 * col2 + col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT ALL ( tab1.col1 ) * col1 * - col1 + + 43 * - col0 FROM tab1
----
-17705
-3752
-5637

query I rowsort
SELECT ALL col1 + ( + col1 ) FROM tab2
----
118
34
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-2988
SELECT DISTINCT - CAST( col2 AS SIGNED ) + - col2 DIV - 49 - col0 col0 FROM tab1 AS cor0
----
-120
-175
-56

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-2988
SELECT DISTINCT - CAST ( col2 AS INTEGER ) + - col2 / - 49 - col0 col0 FROM tab1 AS cor0
----
-120
-175
-56

query I rowsort
SELECT ALL + - col1 + + cor0.col0 * col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT - 20 - + 35 AS col2 FROM tab0, tab1, tab2 cor0
----
27 values hashing to b90e74bece5521b514096c5b6e105fde

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-2991
SELECT CAST( + col2 AS SIGNED ) * col1 FROM tab1
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-2991
SELECT CAST ( + col2 AS INTEGER ) * col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT + 14 + - col2 AS col0 FROM tab0
----
-19
-68
13

query I rowsort
SELECT DISTINCT - 69 + col2 * col1 FROM tab2 AS cor0
----
1465
577
768

query I rowsort
SELECT - col1 * + col1 + - ( + col2 * + col0 ) AS col0 FROM tab1 AS cor0
----
-3748
-7849
-838

onlyif mysql # use DIV operator for integer division
query I rowsort label-2995
SELECT ALL - col0 DIV + cor0.col2 AS col0 FROM tab1 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-2995
SELECT ALL - col0 / + cor0.col2 AS col0 FROM tab1 AS cor0
----
-1
0
0

query I rowsort
SELECT + + col2 + col1 * + 87 AS col1 FROM tab0 AS cor0
----
7515
7999
8440

query I rowsort
SELECT col1 * col1 * + col0 AS col2 FROM tab1 AS cor0
----
13520
2028
6400

query I rowsort
SELECT DISTINCT + + 47 * col0 FROM tab2 AS cor0
----
329
3666
3713

onlyif mysql # use DIV operator for integer division
query I rowsort label-2999
SELECT 38 DIV col1 AS col0 FROM tab2 AS cor0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-2999
SELECT 38 / col1 AS col0 FROM tab2 AS cor0
----
0
1
2

query I rowsort
SELECT ALL - 24 AS col1 FROM tab2 AS cor0
----
-24
-24
-24

query I rowsort
SELECT ALL cor0.col2 * - cor0.col0 AS col1 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT + col1 * - cor0.col2 + + ( col0 ) AS col1 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT - col2 * + col1 + 79 FROM tab1 AS cor0
----
-1169
-1325
-491

query I rowsort
SELECT DISTINCT - col0 * col1 + + col0 * - col1 AS col0 FROM tab0
----
-16198
-4128
-6790

query I rowsort
SELECT DISTINCT - + col1 * ( + col0 ) FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + 97 FROM tab1, tab2 AS cor0
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

onlyif mysql # use DIV operator for integer division
query I rowsort label-3007
SELECT col2 DIV ( + tab2.col0 + + col2 * - ( + col0 ) ) FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3007
SELECT col2 / ( + tab2.col0 + + col2 * - ( + col0 ) ) FROM tab2
----
0
0
0

query I rowsort
SELECT ALL + + col1 * - col1 - 68 * + col1 FROM tab1 AS cor0
----
-1053
-2444
-780

onlyif mysql # use DIV operator for integer division
query I rowsort label-3009
SELECT + - cor0.col1 DIV - 66 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3009
SELECT + - cor0.col1 / - 66 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL + + col2 * ( col2 ) + col2 * col2 * col2 AS col0 FROM tab0 AS cor0
----
2
37026
558092

query I rowsort
SELECT ALL - col1 * + col2 + 95 FROM tab2 AS cor0
----
-1439
-551
-742

query I rowsort
SELECT ALL - col0 * col1 - col1 AS col2 FROM tab1 AS cor0
----
-104
-1053
-650

query I rowsort
SELECT DISTINCT + - col1 + ( + 57 ) FROM tab0 cor0
----
-29
-34
-40

query I rowsort
SELECT + 73 + - col0 AS col2 FROM tab1 AS cor0
----
-7
70
9

query I rowsort
SELECT DISTINCT + ( col0 ) + col0 * 61 FROM tab0 AS cor0
----
1488
2170
5518

query I rowsort
SELECT DISTINCT + 8 AS col2 FROM tab2
----
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3017
SELECT tab0.col2 * + CAST( NULL AS SIGNED ) + 11 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-3017
SELECT tab0.col2 * + CAST ( NULL AS INTEGER ) + 11 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + ( - col2 ) * col0 + 88 FROM tab1 cor0
----
-3560
-74
-7592

onlyif mysql # use DIV operator for integer division
query I rowsort label-3019
SELECT DISTINCT - + col0 DIV + col0 + 76 DIV col1 FROM tab1 cor0
----
1
4
6

skipif mysql # not compatible
query I rowsort label-3019
SELECT DISTINCT - + col0 / + col0 + 76 / col1 FROM tab1 cor0
----
1
4
6

query I rowsort
SELECT - 83 + cor0.col2 AS col1 FROM tab0 AS cor0
----
-1
-50
-82

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3021
SELECT col0 - - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3021
SELECT col0 - - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * 91 AS col1 FROM tab0 AS cor0
----
2184
3185
8099

query I rowsort
SELECT DISTINCT - ( col0 + - col1 ) FROM tab1
----
-54
-67
23

query I rowsort
SELECT ALL - + col1 + + col1 * + col1 AS col0 FROM tab1 AS cor0
----
156
650
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-3025
SELECT DISTINCT - col2 DIV - 66 + - col1 FROM tab1
----
-10
-12
-26

skipif mysql # not compatible
query I rowsort label-3025
SELECT DISTINCT - col2 / - 66 + - col1 FROM tab1
----
-10
-12
-26

query I rowsort
SELECT col0 * - tab2.col2 * col1 FROM tab2
----
-119652
-51034
-5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3027
SELECT - 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-3027
SELECT - CAST ( NULL AS INTEGER ) col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ( - col0 ) * col0 * col1 FROM tab0
----
-118825
-49536
-720811

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 8 col0 FROM tab1 AS cor0
----
8
8
8

query I rowsort
SELECT ALL ( 65 + - col2 ) AS col1 FROM tab1
----
-31
11
8

query I rowsort
SELECT ALL 54 * + 62 * col2 AS col2 FROM tab2
----
127224
87048
90396

query I rowsort
SELECT ( - 79 ) AS col2 FROM tab0
----
-79
-79
-79

query I rowsort
SELECT + col2 + col1 * 19 * col0 AS col1 FROM tab2 AS cor0
----
25555
4150
87464

query I rowsort
SELECT ALL 58 AS col0 FROM tab1 AS cor0
----
58
58
58

query I rowsort
SELECT DISTINCT + 14 + col0 * - cor0.col2 FROM tab1 AS cor0
----
-148
-3634
-7666

query I rowsort
SELECT col2 + col0 * cor0.col2 FROM tab2 AS cor0
----
2054
216
3040

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3037
SELECT ALL + col0 * - 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-3037
SELECT ALL + col0 * - col0 * + CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col2 * col0 * col0 AS col2 FROM tab1 cor0
----
233472
486
614400

query I rowsort
SELECT 30 * tab1.col0 AS col1 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 11636d367200d6ff91265460f177a16e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col0 col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT - tab0.col2 * + tab0.col1 AS col1 FROM tab0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-3042
SELECT ALL + col0 DIV + col2 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-3042
SELECT ALL + col0 / + col2 FROM tab0
----
0
1
35

query I rowsort
SELECT DISTINCT col0 * 35 AS col1 FROM tab2
----
245
2730
2765

query I rowsort
SELECT - col0 + ( cor0.col1 ) AS col1 FROM tab0 AS cor0
----
2
62
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3045
SELECT ALL - ( col2 ) DIV - cor0.col2 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3045
SELECT ALL - ( col2 ) / - cor0.col2 AS col0 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3046
SELECT + tab1.col1 * + CAST( + 42 AS SIGNED ) FROM tab1
----
1092
420
546

skipif mysql # not compatible
query I rowsort label-3046
SELECT + tab1.col1 * + CAST ( + 42 AS INTEGER ) FROM tab1
----
1092
420
546

query I rowsort
SELECT + tab0.col1 - + col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT - - col2 + ( col0 ) * col0 AS col1 FROM tab1 cor0
----
4153
63
6496

query I rowsort
SELECT + ( col2 ) * col2 FROM tab0 cor0
----
1
1089
6724

query I rowsort
SELECT + + col1 + - col1 * + cor0.col1 + col0 FROM tab2 AS cor0
----
-193
-3344
-923

query I rowsort
SELECT + 70 FROM tab0, tab1 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
81 values hashing to c07fb58c935d7dd3a559c80465f90463

query I rowsort
SELECT + + 65 * + 53 AS col0 FROM tab2 AS cor0
----
3445
3445
3445

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3053
SELECT + col2 + + CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3053
SELECT + col2 + + CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 93 FROM tab0, tab1 AS cor0
----
93

query I rowsort
SELECT col0 * col0 + - ( + col1 ) AS col0 FROM tab0 AS cor0
----
1128
490
7830

onlyif mysql # use DIV operator for integer division
query I rowsort label-3056
SELECT ALL + col0 DIV col0 + + col2 AS col0 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-3056
SELECT ALL + col0 / col0 + + col2 AS col0 FROM tab0 AS cor0
----
2
34
83

query I rowsort
SELECT ALL cor0.col2 + col2 + + col0 AS col1 FROM tab0 AS cor0
----
253
37
90

query I rowsort
SELECT DISTINCT - col0 + cor0.col2 * cor0.col1 AS col1 FROM tab1 AS cor0
----
1168
1401
506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3059
SELECT ALL + col0 * CAST( 10 AS SIGNED ) + + col0 FROM tab1 AS cor0
----
33
704
880

skipif mysql # not compatible
query I rowsort label-3059
SELECT ALL + col0 * CAST ( 10 AS INTEGER ) + + col0 FROM tab1 AS cor0
----
33
704
880

onlyif mysql # use DIV operator for integer division
query I rowsort label-3060
SELECT DISTINCT + cor0.col2 + - col2 DIV col1 col2 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3060
SELECT DISTINCT + cor0.col2 + - col2 / col1 col2 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 + - 87 * col1 col2 FROM tab2 AS cor0
----
-1400
-2690
-5055

query I rowsort
SELECT ALL ( col2 ) + col2 + - col0 FROM tab2 AS cor0
----
-26
-3
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3063
SELECT - CAST( col0 AS SIGNED ) AS col1 FROM tab0 cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-3063
SELECT - CAST ( col0 AS INTEGER ) AS col1 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT ALL + col1 + - col0 AS col1 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT 58 * + col2 FROM tab1 cor0
----
3132
3306
5568

query I rowsort
SELECT - cor0.col1 * ( - col1 ) FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT ALL - 99 + - ( + cor0.col1 ) * col2 AS col1 FROM tab0 AS cor0
----
-196
-2937
-7561

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3068
SELECT DISTINCT - + CAST( - col0 AS SIGNED ) * - col0 + 98 FROM tab2 AS cor0
----
-5986
-6143
49

skipif mysql # not compatible
query I rowsort label-3068
SELECT DISTINCT - + CAST ( - col0 AS INTEGER ) * - col0 + 98 FROM tab2 AS cor0
----
-5986
-6143
49

query I rowsort
SELECT ALL - 55 + + cor0.col1 AS col2 FROM tab0 cor0
----
31
36
42

query I rowsort
SELECT + col2 + - 95 AS col0 FROM tab2
----
-57
-68
-69

onlyif mysql # use DIV operator for integer division
query I rowsort label-3071
SELECT ALL + ( tab0.col1 ) + 26 DIV cor0.col1 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif mysql # not compatible
query I rowsort label-3071
SELECT ALL + ( tab0.col1 ) + 26 / cor0.col1 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + 80 col2 FROM tab0
----
166
171
177

query I rowsort
SELECT 24 + + 4 FROM tab2, tab0 AS cor0
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 84 + + col0 * - col1 col2 FROM tab2 AS cor0
----
-1259
-133
-4518

query I rowsort
SELECT ALL + col0 * cor0.col2 - - col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT - 15 * - col1 AS col2 FROM tab1 AS cor0
----
150
195
390

query I rowsort
SELECT DISTINCT - 16 + col2 FROM tab1 AS cor0
----
38
41
80

query I rowsort
SELECT - col0 * + col2 - + col2 * - col1 * col0 FROM tab1 AS cor0
----
32832
4050
92160

query I rowsort
SELECT ALL - col2 * col2 * col1 FROM tab2 AS cor0
----
-22599
-24548
-39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-3080
SELECT col2 DIV - col0 - col1 FROM tab1 cor0
----
-10
-14
-44

skipif mysql # not compatible
query I rowsort label-3080
SELECT col2 / - col0 - col1 FROM tab1 cor0
----
-10
-14
-44

query I rowsort
SELECT ALL col1 - + cor0.col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT cor0.col2 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3083
SELECT ALL col2 * col2 DIV col0 FROM tab1 AS cor0
----
115
50
972

skipif mysql # not compatible
query I rowsort label-3083
SELECT ALL col2 * col2 / col0 FROM tab1 AS cor0
----
115
50
972

query I rowsort
SELECT - col1 * col0 + + cor0.col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT DISTINCT - + col1 + col0 FROM tab2 cor0
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-3086
SELECT - ( + 80 ) DIV col2 FROM tab0
----
-2
-80
0

skipif mysql # not compatible
query I rowsort label-3086
SELECT - ( + 80 ) / col2 FROM tab0
----
-2
-80
0

query I rowsort
SELECT DISTINCT col0 * - col1 * + col1 AS col1 FROM tab0
----
-177504
-329315
-737009

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col2 * - col0 - - ( col2 ) col2 FROM tab1 AS cor0
----
-233415
-432
-614304

query I rowsort
SELECT DISTINCT - - col1 + - col1 * - ( - col0 ) FROM tab2 cor0
----
-1326
-186
-4543

query I rowsort
SELECT 28 * ( col2 * 26 ) AS col1 FROM tab2
----
18928
19656
27664

query I rowsort
SELECT DISTINCT + tab0.col1 + col1 AS col1 FROM tab0
----
172
182
194

query I rowsort
SELECT DISTINCT col1 + tab1.col2 + col2 AS col1 FROM tab1
----
124
134
205

query I rowsort
SELECT + - col0 * col0 * ( 74 ) FROM tab2 cor0
----
-3626
-450216
-461834

query I rowsort
SELECT - - col1 * - col2 - - 93 FROM tab2 AS cor0
----
-1441
-553
-744

query I rowsort
SELECT tab1.col2 * + col2 * ( 17 ) + + col2 + - 65 AS col0 FROM tab1
----
156703
49561
55225

query I rowsort
SELECT col1 + - 68 AS col1 FROM tab1 AS cor0
----
-42
-55
-58

query I rowsort
SELECT DISTINCT col0 + col0 - - 19 AS col2 FROM tab2
----
175
177
33

query I rowsort
SELECT - - cor0.col0 * - col2 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
-158
-1969
-2985

query I rowsort
SELECT - tab0.col2 + col2 + + col1 AS col0 FROM tab0
----
86
91
97

query I rowsort
SELECT tab1.col1 + - tab1.col2 * - col0 - ( - tab1.col0 + - tab1.col0 ) AS col1 FROM tab1
----
194
3786
7853

onlyif mysql # use DIV operator for integer division
query I rowsort label-3101
SELECT ALL col2 DIV col2 + + tab1.col1 + - ( col2 ) FROM tab1
----
-27
-46
-82

skipif mysql # not compatible
query I rowsort label-3101
SELECT ALL col2 / col2 + + tab1.col1 + - ( col2 ) FROM tab1
----
-27
-46
-82

query I rowsort
SELECT - 8 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 47f43f23dcd23959d97d8e3b0aab692e

query I rowsort
SELECT ALL col0 * + tab1.col1 AS col1 FROM tab1
----
1040
640
78

query I rowsort
SELECT - 34 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 40442a74794ded4c78101eefe525a5bb

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3105
SELECT ALL col0 + CAST( + col1 AS SIGNED ) FROM tab2
----
137
38
96

skipif mysql # not compatible
query I rowsort label-3105
SELECT ALL col0 + CAST ( + col1 AS INTEGER ) FROM tab2
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + ( - 65 ) col2 FROM tab1 AS cor0
----
-3510
-3705
-6240

query I rowsort
SELECT col2 + 59 AS col2 FROM tab2 cor0
----
85
86
97

query I rowsort
SELECT ALL + cor0.col0 + + 83 * - ( - col0 ) * - cor0.col1 + - ( - col1 ) * + cor0.col2 FROM tab1 AS cor0
----
-5067
-52486
-84992

query I rowsort
SELECT ALL + cor0.col0 - cor0.col1 AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT cor0.col1 - 61 FROM tab0 cor0
----
25
30
36

query I rowsort
SELECT - col1 + col1 * + 16 FROM tab2 AS cor0
----
255
465
885

query I rowsort
SELECT ALL + - cor0.col2 * + 19 AS col1 FROM tab2 cor0
----
-494
-513
-722

query I rowsort
SELECT DISTINCT - + 13 + - col2 * + col2 AS col2 FROM tab0 AS cor0
----
-1102
-14
-6737

onlyif mysql # use DIV operator for integer division
query I rowsort label-3114
SELECT - col1 DIV + 12 FROM tab1 cor0
----
-1
-2
0

skipif mysql # not compatible
query I rowsort label-3114
SELECT - col1 / + 12 FROM tab1 cor0
----
-1
-2
0

query I rowsort
SELECT - - ( + 53 ) AS col2 FROM tab1 AS cor0
----
53
53
53

query I rowsort
SELECT ALL + ( col0 ) + - col2 AS col0 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL - 86 * col1 AS col1 FROM tab1 AS cor0
----
-1118
-2236
-860

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT - - CAST ( col0 AS REAL ) col2 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - + col0 * + col0 + col2 AS col0 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT - - col1 * - col1 * - 44 FROM tab1 AS cor0
----
29744
4400
7436

query I rowsort
SELECT DISTINCT + - ( cor0.col1 ) + 69 AS col1 FROM tab1 cor0
----
43
56
59

query I rowsort
SELECT DISTINCT + col0 + col1 * + col0 FROM tab2
----
1422
224
4680

query I rowsort
SELECT ALL col2 + col2 + - col0 AS col2 FROM tab2
----
-26
-3
47

query I rowsort
SELECT cor0.col2 * 24 FROM tab1, tab2 AS cor0
----
9 values hashing to 26deba019843ab42119abd63a57c33b4

query I rowsort
SELECT ALL 25 * - col2 + - col2 FROM tab0
----
-2132
-26
-858

query I rowsort
SELECT DISTINCT - + 80 AS col0 FROM tab0 AS cor0
----
-80

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab0 cor0, tab1 AS cor1, tab2 AS cor2
----
972 values hashing to 49c8bf3e931a898ba7af63d0e377eb79

query I rowsort
SELECT DISTINCT + + ( col0 ) * cor0.col2 AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - - 17 * - cor0.col1 FROM tab0 AS cor0
----
-1462
-1547
-1649

onlyif mysql # use DIV operator for integer division
query I rowsort label-3130
SELECT ALL 62 - col2 DIV + ( 78 ) AS col1 FROM tab0 AS cor0
----
61
62
62

skipif mysql # not compatible
query I rowsort label-3130
SELECT ALL 62 - col2 / + ( 78 ) AS col1 FROM tab0 AS cor0
----
61
62
62

query I rowsort
SELECT DISTINCT 59 * col1 * col1 FROM tab0 AS cor0
----
436364
488579
555131

query I rowsort
SELECT 42 * ( - col0 ) FROM tab0
----
-1008
-1470
-3738

onlyif mysql # use DIV operator for integer division
query I rowsort label-3133
SELECT ALL 2 DIV 65 col1 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3133
SELECT ALL 2 / 65 col1 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT cor1.col1 FROM tab2, tab2 cor0, tab0 cor1
----
86
91
97

query I rowsort
SELECT ( col0 + + col0 ) FROM tab0
----
178
48
70

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * + cor0.col0 col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL + cor1.col2 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT - + col2 + + cor0.col0 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT DISTINCT + tab1.col2 * ( - col1 ) * - col1 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT DISTINCT col1 * - tab1.col1 AS col2 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT + col1 * + ( col2 ) - - col0 AS col2 FROM tab0 AS cor0
----
132
2862
7551

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3142
SELECT + col1 * + CAST( + 25 AS SIGNED ) - - col2 FROM tab0 AS cor0
----
2183
2357
2426

skipif mysql # not compatible
query I rowsort label-3142
SELECT + col1 * + CAST ( + 25 AS INTEGER ) - - col2 FROM tab0 AS cor0
----
2183
2357
2426

query I rowsort
SELECT DISTINCT 12 AS col2 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
12

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3144
SELECT ALL - col0 + - CAST( NULL AS SIGNED ) + col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3144
SELECT ALL - col0 + - CAST ( NULL AS INTEGER ) + col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3145
SELECT DISTINCT - col2 * + CAST( - col2 + col1 * - col0 AS SIGNED ) FROM tab0 AS cor0
----
3396
670842
69201

skipif mysql # not compatible
query I rowsort label-3145
SELECT DISTINCT - col2 * + CAST ( - col2 + col1 * - col0 AS INTEGER ) FROM tab0 AS cor0
----
3396
670842
69201

query I rowsort
SELECT - + col1 + 81 AS col0 FROM tab1 cor0
----
55
68
71

query I rowsort
SELECT + + col0 + + 36 AS col1 FROM tab1 AS cor0
----
100
116
39

query I rowsort
SELECT ( 92 ) + + col1 * cor0.col1 AS col2 FROM tab2 AS cor0
----
1053
3573
381

query I rowsort
SELECT - cor0.col0 * + ( col0 ) + + 12 FROM tab1 AS cor0
----
-4084
-6388
3

query I rowsort
SELECT + ( 17 ) AS col2 FROM tab2 cor0
----
17
17
17

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3151
SELECT - CAST( NULL AS SIGNED ) * + col0 - + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3151
SELECT - CAST ( NULL AS INTEGER ) * + col0 - + col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * + tab0.col1 + col2 - ( tab0.col1 ) AS col2 FROM tab0
----
-7449
-8290
-9505

query I rowsort
SELECT 16 AS col0 FROM tab0
----
16
16
16

onlyif mysql # use DIV operator for integer division
query I rowsort label-3154
SELECT - tab2.col2 DIV + 96 + + col1 FROM tab2
----
17
31
59

skipif mysql # not compatible
query I rowsort label-3154
SELECT - tab2.col2 / + 96 + + col1 FROM tab2
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col2 ) col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT col1 + + 79 * col2 FROM tab1 AS cor0
----
4292
4513
7597

query I rowsort
SELECT DISTINCT - - ( - cor0.col0 ) + col1 AS col1 FROM tab0 cor0
----
2
62

query I rowsort
SELECT 3 * + 41 + col0 AS col2 FROM tab2 AS cor0
----
130
201
202

query I rowsort
SELECT ALL - 55 + - col0 AS col0 FROM tab1 AS cor0
----
-119
-135
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-3160
SELECT ALL col2 - + col2 DIV - col1 FROM tab2 AS cor0
----
26
27
40

skipif mysql # not compatible
query I rowsort label-3160
SELECT ALL col2 - + col2 / - col1 FROM tab2 AS cor0
----
26
27
40

query I rowsort
SELECT + - col1 + col0 * col1 FROM tab2 AS cor0
----
1326
186
4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( + col2 ) - + col2 col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + ( col0 ) + + col2 AS col1 FROM tab2 cor0
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-3164
SELECT + + ( col1 ) DIV + 53 AS col0 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3164
SELECT + + ( col1 ) / + 53 AS col0 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT ALL - + ( cor0.col0 ) AS col0 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT ALL + 52 + col1 FROM tab1 AS cor0
----
62
65
78

onlyif mysql # use DIV operator for integer division
query I rowsort label-3167
SELECT - - cor0.col0 DIV col1 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3167
SELECT - - cor0.col0 / col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL 18 * col0 FROM tab1 AS cor0
----
1152
1440
54

query I rowsort
SELECT col0 * col2 * col1 FROM tab1 AS cor0
----
36480
4212
99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3170
SELECT ALL CAST( NULL AS SIGNED ) * col1 + + col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3170
SELECT ALL CAST ( NULL AS INTEGER ) * col1 + + col2 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - - 78 * - cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 18c0c4f7115a498d3647b74f028370dc

query I rowsort
SELECT DISTINCT + col0 * col1 - col0 * cor0.col1 * 33 AS col2 FROM tab0 AS cor0
----
-108640
-259168
-66048

onlyif mysql # use DIV operator for integer division
query I rowsort label-3173
SELECT - col0 * col0 DIV - 84 FROM tab0
----
14
6
94

skipif mysql # not compatible
query I rowsort label-3173
SELECT - col0 * col0 / - 84 FROM tab0
----
14
6
94

query I rowsort
SELECT ALL col2 * cor0.col0 AS col0 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT ALL + + col1 + + 74 FROM tab0 AS cor0
----
160
165
171

query I rowsort
SELECT - tab0.col0 * 96 FROM tab0
----
-2304
-3360
-8544

query I rowsort
SELECT col0 * - tab1.col2 + col2 FROM tab1
----
-108
-3591
-7584

onlyif mysql # use DIV operator for integer division
query I rowsort label-3178
SELECT DISTINCT col1 DIV - ( 32 * + col0 ) - ( + tab1.col2 ) * col1 AS col1 FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-3178
SELECT DISTINCT col1 / - ( 32 * + col0 ) - ( + tab1.col2 ) * col1 AS col1 FROM tab1
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3179
SELECT tab0.col2 + - CAST( 89 * col1 + - col2 AS SIGNED ) AS col1 FROM tab0
----
-7588
-7935
-8631

skipif mysql # not compatible
query I rowsort label-3179
SELECT tab0.col2 + - CAST ( 89 * col1 + - col2 AS INTEGER ) AS col1 FROM tab0
----
-7588
-7935
-8631

onlyif mysql # use DIV operator for integer division
query I rowsort label-3180
SELECT ALL - ( col1 ) * 94 DIV + col2 - col0 FROM tab0
----
-193
-268
-9153

skipif mysql # not compatible
query I rowsort label-3180
SELECT ALL - ( col1 ) * 94 / + col2 - col0 FROM tab0
----
-193
-268
-9153

query I rowsort
SELECT 13 - col2 AS col0 FROM tab0 AS cor0
----
-20
-69
12

query I rowsort
SELECT DISTINCT + + 4 * col0 + 51 AS col0 FROM tab2 AS cor0
----
363
367
79

query I rowsort
SELECT DISTINCT col0 * - col1 + + col2 * - col1 FROM tab2 AS cor0
----
-1054
-1989
-6136

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3184
SELECT 35 * col2 + CAST( NULL AS SIGNED ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3184
SELECT 35 * col2 + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 81 AS col2 FROM tab2 cor0
----
81
81
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-3186
SELECT DISTINCT + tab1.col0 * tab1.col1 + col0 + col0 DIV + col2 col2 FROM tab1
----
1120
705
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3186
SELECT DISTINCT + tab1.col0 * tab1.col1 + col0 + col0 / + col2 col2 FROM tab1
----
1120
705
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3187
SELECT ALL + cor0.col2 + CAST( - col0 AS SIGNED ) FROM tab0 cor0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-3187
SELECT ALL + cor0.col2 + CAST ( - col0 AS INTEGER ) FROM tab0 cor0
----
-34
-7
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - cor0.col2 + + col0 col2 FROM tab2 AS cor0
----
-1365
-598
-722

query I rowsort
SELECT - col0 + tab2.col2 * 93 AS col1 FROM tab2
----
2340
2504
3455

query I rowsort
SELECT ALL - col1 + 24 * - cor0.col0 FROM tab0 AS cor0
----
-2227
-662
-937

query I rowsort
SELECT ( 31 ) FROM tab2, tab1 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query I rowsort
SELECT + + col0 + + 61 + - col1 AS col2 FROM tab1 AS cor0
----
115
128
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3193
SELECT - + col2 * + CAST( NULL AS SIGNED ) FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3193
SELECT - + col2 * + CAST ( NULL AS INTEGER ) FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3194
SELECT + ( - col1 ) * + col1 * + col2 + + col2 DIV col1 AS col0 FROM tab1
----
-16217
-36502
-5695

skipif mysql # not compatible
query I rowsort label-3194
SELECT + ( - col1 ) * + col1 * + col2 + + col2 / col1 AS col0 FROM tab1
----
-16217
-36502
-5695

query I rowsort
SELECT DISTINCT + 49 FROM tab1, tab0 AS cor0
----
49

query I rowsort
SELECT + cor1.col2 AS col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT DISTINCT 70 * + 92 FROM tab0
----
6440

query I rowsort
SELECT DISTINCT col1 * 48 AS col0 FROM tab1
----
1248
480
624

query I rowsort
SELECT ( - col0 ) + - col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT ALL - ( + 92 ) + col2 FROM tab0 AS cor0
----
-10
-59
-91

query I rowsort
SELECT DISTINCT - - ( + 32 ) + col2 FROM tab2 AS cor0
----
58
59
70

query I rowsort
SELECT DISTINCT - + cor0.col0 * col0 - + col1 AS col1 FROM tab1 AS cor0
----
-35
-4106
-6413

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 + col1 * col1 col0 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT 64 AS col0 FROM tab1, tab0 cor0
----
9 values hashing to 60ab040e931c5c85db7ba19364eacc8e

query I rowsort
SELECT ALL col2 * - 63 + col2 * - col2 FROM tab0 AS cor0
----
-11890
-3168
-64

query I rowsort
SELECT DISTINCT - col1 * + col2 * - col1 FROM tab0 cor0
----
244068
679042
9409

query I rowsort
SELECT + 85 - col0 * + cor0.col1 FROM tab2 AS cor0
----
-1258
-132
-4517

onlyif mysql # use DIV operator for integer division
query I rowsort label-3208
SELECT - col1 * cor0.col1 + cor0.col1 DIV col0 + col2 * + col2 AS col2 FROM tab0 AS cor0
----
-1556
-6304
-9406

skipif mysql # not compatible
query I rowsort label-3208
SELECT - col1 * cor0.col1 + cor0.col1 / col0 + col2 * + col2 AS col2 FROM tab0 AS cor0
----
-1556
-6304
-9406

query I rowsort
SELECT DISTINCT + - col1 + col0 AS col0 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT ALL - - col0 + col2 AS col2 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - 87 + col1 AS col1 FROM tab1 AS cor0
----
-61
-74
-77

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3212
SELECT - + ( + cor0.col0 ) * - CAST( NULL AS DECIMAL ) - 43 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3212
SELECT - + ( + cor0.col0 ) * - CAST ( NULL AS REAL ) - 43 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - 40 FROM tab2 AS cor0
----
40

query I rowsort
SELECT + - col0 - + col1 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3215
SELECT 79 DIV - col2 col0 FROM tab0 AS cor0
----
-2
-79
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3215
SELECT 79 / - col2 col0 FROM tab0 AS cor0
----
-2
-79
0

query I rowsort
SELECT ALL + col1 * - cor0.col2 * + col2 + + 47 * + col0 AS col1 FROM tab0 AS cor0
----
-607701
-92526
1548

onlyif mysql # use DIV operator for integer division
query I rowsort label-3217
SELECT - col2 DIV - col0 AS col0 FROM tab2 cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-3217
SELECT - col2 / - col0 AS col0 FROM tab2 cor0
----
0
0
3

query I rowsort
SELECT - col1 * col0 * + col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL + 18 + + col0 FROM tab0 AS cor0
----
107
42
53

query I rowsort
SELECT DISTINCT - - 92 * col2 + col1 FROM tab1 AS cor0
----
4994
5254
8845

query I rowsort
SELECT DISTINCT ( col1 ) + + 21 FROM tab0 AS cor0
----
107
112
118

query I rowsort
SELECT + + 74 * col1 AS col0 FROM tab1 AS cor0
----
1924
740
962

onlyif mysql # use DIV operator for integer division
query I rowsort label-3223
SELECT DISTINCT - col0 + col0 DIV - 32 FROM tab0 AS cor0
----
-24
-36
-91

skipif mysql # not compatible
query I rowsort label-3223
SELECT DISTINCT - col0 + col0 / - 32 FROM tab0 AS cor0
----
-24
-36
-91

query I rowsort
SELECT - 24 AS col0 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to f2e40f6e5cdbc2877843191cb261975f

onlyif mysql # use DIV operator for integer division
query I rowsort label-3225
SELECT + 29 DIV + col0 col1 FROM tab2
----
0
0
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3225
SELECT + 29 / + col0 col1 FROM tab2
----
0
0
4

query I rowsort
SELECT DISTINCT - 61 + + col2 * - tab0.col0 * 61 AS col1 FROM tab0
----
-2196
-445239
-48373

query I rowsort
SELECT - + col0 * + 79 FROM tab0 AS cor0
----
-1896
-2765
-7031

query I rowsort
SELECT + col0 + - col1 * + 86 FROM tab1 AS cor0
----
-1038
-2233
-796

query I rowsort
SELECT + - col1 * 28 FROM tab1 AS cor0
----
-280
-364
-728

query I rowsort
SELECT ALL - 32 AS col0 FROM tab2
----
-32
-32
-32

query I rowsort
SELECT - tab2.col2 AS col1 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT 20 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 0a35fe98f3e7d5fc8ff2ae815bd20ef4

query I rowsort
SELECT tab0.col1 * + 59 FROM tab0, tab2 AS cor0
----
9 values hashing to f6cb4a85ef6abd8c101dffc31c6c04dc

query I rowsort
SELECT - cor0.col1 * 82 + + col1 FROM tab2 cor0
----
-1377
-2511
-4779

onlyif mysql # use DIV operator for integer division
query I rowsort label-3235
SELECT DISTINCT + + 34 * col0 - + col2 DIV ( + 65 ) FROM tab0 AS cor0
----
1190
3025
816

skipif mysql # not compatible
query I rowsort label-3235
SELECT DISTINCT + + 34 * col0 - + col2 / ( + 65 ) FROM tab0 AS cor0
----
1190
3025
816

query I rowsort
SELECT DISTINCT ( + 26 ) FROM tab0 AS cor0
----
26

query I rowsort
SELECT ALL + col2 + 31 AS col1 FROM tab1 cor0
----
127
85
88

query I rowsort
SELECT DISTINCT - cor0.col1 * - col2 AS col2 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL 74 + col0 * + col1 AS col2 FROM tab2 AS cor0
----
1417
291
4676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3240
SELECT + - CAST( NULL AS SIGNED ) + - 72 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3240
SELECT + - CAST ( NULL AS INTEGER ) + - 72 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + - ( col2 ) + cor0.col1 FROM tab0 AS cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - col2 * 15 + col1 - CAST ( col1 AS REAL ) FROM tab0 AS cor0
----
-1230
-15
-495

query I rowsort
SELECT 19 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 86c53e8567a17c8d91fc5aff119e0498

onlyif mysql # use DIV operator for integer division
query I rowsort label-3244
SELECT DISTINCT - col0 + + col1 DIV + col2 AS col2 FROM tab0 AS cor0
----
-22
-88
62

skipif mysql # not compatible
query I rowsort label-3244
SELECT DISTINCT - col0 + + col1 / + col2 AS col2 FROM tab0 AS cor0
----
-22
-88
62

query I rowsort
SELECT DISTINCT + 46 AS col2 FROM tab0 cor0
----
46

query I rowsort
SELECT ALL - col1 * 48 FROM tab0 cor0
----
-4128
-4368
-4656

query I rowsort
SELECT col1 * - 33 + - col2 AS col0 FROM tab2 AS cor0
----
-1050
-1973
-599

onlyif mysql # use DIV operator for integer division
query I rowsort label-3248
SELECT - col0 DIV - cor0.col2 + col1 DIV - col0 FROM tab0 AS cor0
----
-3
0
33

skipif mysql # not compatible
query I rowsort label-3248
SELECT - col0 / - cor0.col2 + col1 / - col0 FROM tab0 AS cor0
----
-3
0
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 + + col0 col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT col1 + 79 * cor0.col1 AS col1 FROM tab1 AS cor0
----
1040
2080
800

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3251
SELECT - + col1 + CAST( ( - col1 ) AS SIGNED ) FROM tab0 AS cor0
----
-172
-182
-194

skipif mysql # not compatible
query I rowsort label-3251
SELECT - + col1 + CAST ( ( - col1 ) AS INTEGER ) FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT + col1 * 53 FROM tab1 AS cor0
----
1378
530
689

query I rowsort
SELECT ALL - ( + col1 ) * col2 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT - col0 * + cor0.col2 + - col0 * + cor0.col0 FROM tab2 AS cor0
----
-238
-8112
-9243

query I rowsort
SELECT + cor0.col1 + col2 + - col1 FROM tab0 AS cor0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-3256
SELECT DISTINCT col1 DIV ( - col2 ) AS col1 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3256
SELECT DISTINCT col1 / ( - col2 ) AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - 24 * + col0 FROM tab0 AS cor0
----
-2136
-576
-840

query I rowsort
SELECT ALL cor0.col1 + 38 * - col0 AS col2 FROM tab2 AS cor0
----
-235
-2905
-2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 49 col1 FROM tab1
----
-49
-49
-49

query I rowsort
SELECT DISTINCT + cor0.col1 AS col0 FROM tab2, tab0 AS cor0, tab0, tab1 AS cor1
----
86
91
97

query I rowsort
SELECT ALL + + 52 + col0 * - cor0.col1 FROM tab1 AS cor0
----
-26
-588
-988

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - col0 ) + 86 col2 FROM tab2 AS cor0
----
7
79
8

query I rowsort
SELECT ALL - cor0.col0 AS col0 FROM tab1, tab2, tab2 cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT col2 * - tab0.col0 * col2 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT + + col2 - + col1 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + col2 - - col0 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT - - 79 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT ALL 65 * ( - cor0.col1 ) FROM tab2, tab2 AS cor0
----
9 values hashing to af57aa04beefe7147e4e3e56411631d1

query I rowsort
SELECT DISTINCT - cor1.col1 AS col1 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
-86
-91
-97

query I rowsort
SELECT - - 87 FROM tab2 AS cor0
----
87
87
87

query I rowsort
SELECT - 22 * - col0 AS col2 FROM tab0 AS cor0
----
1958
528
770

query I rowsort
SELECT + 8 - col0 FROM tab0
----
-16
-27
-81

query I rowsort
SELECT ALL col2 + cor0.col2 * - col0 FROM tab0 AS cor0
----
-34
-7216
-759

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col1 + col0 * + col0 col2 FROM tab2
----
-788
4550
5595

query I rowsort
SELECT ALL 18 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to b95bafa733666df39c5d3f94760d010f

query I rowsort
SELECT + col0 - col0 * - cor0.col0 AS col2 FROM tab0 cor0
----
1260
600
8010

query I rowsort
SELECT ALL - tab0.col2 + ( - tab0.col0 ) FROM tab0, tab0 AS cor0
----
9 values hashing to aac9661904614ee295157ea355327523

query I rowsort
SELECT ALL + col2 * col0 + 11 FROM tab1 AS cor0
----
173
3659
7691

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col0 col1 FROM tab2 AS cor0
----
-7
-78
-79

query I rowsort
SELECT - + cor0.col0 + + col0 * - cor0.col1 + col1 FROM tab1 AS cor0
----
-1107
-55
-694

query I rowsort
SELECT DISTINCT col1 * 65 AS col2 FROM tab1 cor0
----
1690
650
845

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * - 97 col0 FROM tab2 cor0
----
-679
-7566
-7663

query I rowsort
SELECT 0 * 61 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT col1 * - col2 + + col0 * + col2 FROM tab0
----
-164
-2046
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3285
SELECT ALL CAST( - 21 * col1 + + 3 * + col0 AS SIGNED ) FROM tab1
----
-18
-33
-537

skipif mysql # not compatible
query I rowsort label-3285
SELECT ALL CAST ( - 21 * col1 + + 3 * + col0 AS INTEGER ) FROM tab1
----
-18
-33
-537

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 29 col2 FROM tab0
----
-29
-29
-29

query I rowsort
SELECT DISTINCT - col0 * 77 + - col2 - 86 FROM tab0 AS cor0
----
-1967
-2782
-7021

query I rowsort
SELECT 62 + col1 FROM tab2 AS cor0
----
121
79
93

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + col0 AS REAL ) AS col2 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT 68 FROM tab2, tab2 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

query I rowsort
SELECT DISTINCT + ( - col0 ) + col0 * + col2 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT ALL col0 * cor0.col2 * 17 FROM tab1 cor0
----
130560
2754
62016

query I rowsort
SELECT ALL + - 79 * - cor0.col0 AS col0 FROM tab1 cor0
----
237
5056
6320

query I rowsort
SELECT - - col0 * col0 * - ( cor0.col0 ) FROM tab1 AS cor0
----
-262144
-27
-512000

query I rowsort
SELECT DISTINCT col2 * 47 FROM tab1
----
2538
2679
4512

query I rowsort
SELECT 43 + + col2 * cor0.col1 AS col2 FROM tab2 AS cor0
----
1577
689
880

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3297
SELECT ALL + CAST( ( + col1 ) AS SIGNED ) - + CAST( ( - col1 ) AS SIGNED ) FROM tab1 AS cor0
----
20
26
52

skipif mysql # not compatible
query I rowsort label-3297
SELECT ALL + CAST ( ( + col1 ) AS INTEGER ) - + CAST ( ( - col1 ) AS INTEGER ) FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL 63 * + col1 AS col2 FROM tab0 AS cor0
----
5418
5733
6111

query I rowsort
SELECT ALL + ( tab2.col2 ) + - col1 FROM tab2
----
-33
-4
21

query I rowsort
SELECT ALL 42 + - col1 AS col1 FROM tab2
----
-17
11
25

query I rowsort
SELECT col2 + 6 FROM tab2 cor0
----
32
33
44

query I rowsort
SELECT DISTINCT - 23 * + col1 FROM tab2 AS cor0
----
-1357
-391
-713

query I rowsort
SELECT ALL - 24 * col2 FROM tab2 AS cor0
----
-624
-648
-912

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 AS cor0, tab2 cor1, tab2, tab0 AS cor2
----
3645 values hashing to 52c9380a39df7a744b9f2f2c5bf55dd5

query I rowsort
SELECT ALL - col0 * + 4 + col1 FROM tab0 AS cor0
----
-10
-265
-43

query I rowsort
SELECT ALL col0 * col1 * col0 + tab2.col0 AS col0 FROM tab2
----
106176
1526
359034

query IIIIII rowsort
SELECT ALL * FROM tab1, tab1 AS cor0 WHERE NULL < NULL
----

query I rowsort
SELECT + 31 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query I rowsort
SELECT DISTINCT - col2 + 96 AS col2 FROM tab2 AS cor0
----
58
69
70

query I rowsort
SELECT + col1 * col0 - + col0 FROM tab0 AS cor0
----
2040
3360
8010

query I rowsort
SELECT ALL 5 + col1 + + 88 * - col2 FROM tab1
----
-4721
-5001
-8430

query I rowsort
SELECT ALL 93 * tab2.col1 + - 19 AS col2 FROM tab2
----
1562
2864
5468

query I rowsort
SELECT - + 28 * - col2 AS col1 FROM tab1 AS cor0
----
1512
1596
2688

query I rowsort
SELECT - col2 + - tab0.col2 AS col2 FROM tab0
----
-164
-2
-66

onlyif mysql # use DIV operator for integer division
query I rowsort label-3315
SELECT - col0 DIV + col0 + col2 AS col0 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-3315
SELECT - col0 / + col0 + col2 AS col0 FROM tab0
----
0
32
81

query I rowsort
SELECT ALL + + col2 + col1 * col1 FROM tab1 AS cor0
----
157
265
730

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3317
SELECT ALL col0 / CAST( NULL AS SIGNED ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3317
SELECT ALL col0 / CAST ( NULL AS INTEGER ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - + cor0.col0 + cor0.col0 AS col0 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3319
SELECT + - col0 DIV + ( - col0 ) FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3319
SELECT + - col0 / + ( - col0 ) FROM tab1 AS cor0
----
1
1
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3320
SELECT - col1 * CAST( NULL AS SIGNED ) * cor0.col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3320
SELECT - col1 * CAST ( NULL AS INTEGER ) * cor0.col1 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + - col0 + CAST ( + col0 AS REAL ) FROM tab2 AS cor0
----
0

query I rowsort
SELECT ALL + - col0 + - 56 AS col0 FROM tab1 AS cor0
----
-120
-136
-59

query I rowsort
SELECT DISTINCT - col0 + 72 * - col0 AS col1 FROM tab1 AS cor0
----
-219
-4672
-5840

query I rowsort
SELECT ALL + col1 * col2 * - cor0.col1 + - cor0.col1 AS col0 FROM tab2 AS cor0
----
-10999
-25978
-90565

query I rowsort
SELECT DISTINCT - - col1 + - 68 AS col1 FROM tab0 AS cor0
----
18
23
29

query I rowsort
SELECT ALL + - col2 * 63 AS col2 FROM tab2 AS cor0
----
-1638
-1701
-2394

query I rowsort
SELECT DISTINCT - + col1 + + col1 * - col0 AS col2 FROM tab2 AS cor0
----
-1360
-248
-4661

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3328
SELECT DISTINCT - col1 / + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3328
SELECT DISTINCT - col1 / + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL cor0.col1 * + 4 AS col0 FROM tab1 cor0
----
104
40
52

query I rowsort
SELECT - col0 + col0 * - 77 * col2 FROM tab2 AS cor0
----
-14560
-156234
-231233

query I rowsort
SELECT DISTINCT + - 9 AS col2 FROM tab2 AS cor0
----
-9

query I rowsort
SELECT + 54 * 8 AS col0 FROM tab0 AS cor0
----
432
432
432

query I rowsort
SELECT - 94 * col0 FROM tab2 AS cor0
----
-658
-7332
-7426

query I rowsort
SELECT DISTINCT - ( - col2 ) * col1 AS col0 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 75 * col0 col1 FROM tab0 AS cor0
----
1800
2625
6675

query I rowsort
SELECT DISTINCT + 17 * cor0.col2 FROM tab0 AS cor0
----
1394
17
561

query I rowsort
SELECT ALL + col0 * col1 + col2 AS col0 FROM tab1 AS cor0
----
1136
132
697

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3338
SELECT DISTINCT ( col1 ) * CAST( NULL AS SIGNED ) AS col0 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3338
SELECT DISTINCT ( col1 ) * CAST ( NULL AS INTEGER ) AS col0 FROM tab1 cor0
----
NULL

query I rowsort
SELECT DISTINCT + 21 + + col1 FROM tab2 AS cor0
----
38
52
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3340
SELECT ALL + col1 DIV col0 + col2 * - 22 FROM tab0 AS cor0
----
-1803
-20
-723

skipif mysql # not compatible
query I rowsort label-3340
SELECT ALL + col1 / col0 + col2 * - 22 FROM tab0 AS cor0
----
-1803
-20
-723

query I rowsort
SELECT - col0 + - col2 * col2 FROM tab1 AS cor0
----
-2919
-3313
-9296

query I rowsort
SELECT + col0 * - col2 + + col2 * + col1 FROM tab0 AS cor0
----
164
2046
62

query I rowsort
SELECT + 56 * col2 + ( col0 ) AS col0 FROM tab2 cor0
----
1519
1534
2207

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3344
SELECT - CAST( NULL AS SIGNED ) * + col2 + col1 * - 36 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3344
SELECT - CAST ( NULL AS INTEGER ) * + col2 + col1 * - 36 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + + col1 - - col0 * - 33 FROM tab0
----
-2755
-620
-961

query I rowsort
SELECT DISTINCT + - 82 * - cor0.col2 - col2 * + col1 AS col2 FROM tab1 cor0
----
3024
4104
6624

query I rowsort
SELECT ALL - - col0 * - cor0.col0 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT + - cor0.col0 - - col0 * col2 AS col1 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT - + cor0.col0 + cor0.col1 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT + cor0.col2 * - col1 + col2 FROM tab0 AS cor0
----
-2805
-7380
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3351
SELECT 57 DIV cor0.col1 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

skipif mysql # not compatible
query I rowsort label-3351
SELECT 57 / cor0.col1 AS col0 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT - col1 * + col0 + + col0 AS col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT + 25 * 35 FROM tab2, tab0 cor0
----
9 values hashing to c08be4e0f66f6c7ef46c6771f773b224

query I rowsort
SELECT - cor0.col2 + - col0 + - col2 AS col0 FROM tab1 AS cor0
----
-111
-178
-272

query I rowsort
SELECT + ( - 24 ) FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 797d0f7c145f8ac623924448c714bbcc

query I rowsort
SELECT ALL + col0 + + col0 * - 6 * col1 FROM tab2
----
-1295
-27534
-7979

query I rowsort
SELECT col0 * ( - tab1.col1 ) - col1 AS col1 FROM tab1
----
-104
-1053
-650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab2.col1 + col2 - + tab2.col1 col1 FROM tab2
----
-35
-92
4

query I rowsort
SELECT - - col2 * + cor0.col2 + cor0.col1 + - ( + col2 ) AS col1 FROM tab1 cor0
----
2888
3202
9133

query I rowsort
SELECT - ( + 14 ) - col2 AS col2 FROM tab0 AS cor0
----
-15
-47
-96

query I rowsort
SELECT DISTINCT ( col1 ) - + col0 AS col2 FROM tab0
----
2
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3362
SELECT DISTINCT - ( - 61 ) - - col2 * CAST( col1 AS SIGNED ) AS col0 FROM tab0
----
158
2899
7523

skipif mysql # not compatible
query I rowsort label-3362
SELECT DISTINCT - ( - 61 ) - - col2 * CAST ( col1 AS INTEGER ) AS col0 FROM tab0
----
158
2899
7523

query I rowsort
SELECT ALL - cor0.col1 FROM tab1, tab2 AS cor0, tab2 cor1, tab2 AS cor2
----
81 values hashing to b7a1b38fe8e4f34388e3be1f52601ae5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 - col0 col2 FROM tab0 AS cor0
----
-110
-132
-180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 80 * cor0.col2 + - col0 + col0 col2 FROM tab2 cor0
----
2080
2160
3040

onlyif mysql # use DIV operator for integer division
query I rowsort label-3366
SELECT col0 + col1 + + 43 DIV + col0 FROM tab0 AS cor0
----
111
133
180

skipif mysql # not compatible
query I rowsort label-3366
SELECT col0 + col1 + + 43 / + col0 FROM tab0 AS cor0
----
111
133
180

query I rowsort
SELECT - - col2 * - col0 + col0 * - col0 AS col2 FROM tab0 AS cor0
----
-1260
-1368
-15219

query I rowsort
SELECT - cor0.col2 * + col2 + cor0.col2 AS col1 FROM tab0 AS cor0
----
-1056
-6642
0

query I rowsort
SELECT - + col1 * - col0 + 39 + col1 AS col0 FROM tab2 cor0
----
1399
287
4700

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3370
SELECT DISTINCT CAST( col0 AS SIGNED ) AS col0 FROM tab1
----
3
64
80

skipif mysql # not compatible
query I rowsort label-3370
SELECT DISTINCT CAST ( col0 AS INTEGER ) AS col0 FROM tab1
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3371
SELECT DISTINCT - col0 DIV - cor0.col1 FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-3371
SELECT DISTINCT - col0 / - cor0.col1 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT + - ( - col0 ) * cor0.col0 + - col2 * - cor0.col1 + - 20 AS col0 FROM tab1 AS cor0
----
1393
4646
7628

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3373
SELECT ALL 84 * + col1 + CAST( - col2 AS SIGNED ) col1 FROM tab1 AS cor0
----
2130
783
996

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3373
SELECT ALL 84 * + col1 + CAST ( - col2 AS INTEGER ) col1 FROM tab1 AS cor0
----
2130
783
996

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + col2 * + col1 col0 FROM tab0 AS cor0
----
194
2924
7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3375
SELECT + col0 * CAST( 97 AS SIGNED ) FROM tab1 AS cor0
----
291
6208
7760

skipif mysql # not compatible
query I rowsort label-3375
SELECT + col0 * CAST ( 97 AS INTEGER ) FROM tab1 AS cor0
----
291
6208
7760

query I rowsort
SELECT ALL ( cor0.col2 ) FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT - tab2.col2 * - col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT + + 64 AS col1 FROM tab2 AS cor0
----
64
64
64

query I rowsort
SELECT ALL ( ( + col0 ) ) * - 84 FROM tab1 AS cor0
----
-252
-5376
-6720

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3380
SELECT DISTINCT CAST( - col0 AS SIGNED ) * cor0.col2 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-3380
SELECT DISTINCT CAST ( - col0 AS INTEGER ) * cor0.col2 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT - + ( 55 ) * + cor0.col1 AS col0 FROM tab2 AS cor0
----
-1705
-3245
-935

query I rowsort
SELECT ALL + cor0.col2 + - cor0.col1 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to ae0eeb942db3f01544a81804e95e971a

query I rowsort
SELECT - 54 FROM tab1 cor0 CROSS JOIN tab2, tab2 cor1, tab0 AS cor2, tab2 AS cor3
----
243 values hashing to f06dd6157f7bd618232d2ea2147f8e19

query I rowsort
SELECT ALL - col2 + 38 * col1 FROM tab1 AS cor0
----
323
398
934

query I rowsort
SELECT - 69 * 89 FROM tab0 AS cor0
----
-6141
-6141
-6141

onlyif mysql # use DIV operator for integer division
query I rowsort label-3386
SELECT ALL - col2 DIV col0 + - col0 * col1 AS col0 FROM tab2 AS cor0
----
-1343
-220
-4602

skipif mysql # not compatible
query I rowsort label-3386
SELECT ALL - col2 / col0 + - col0 * col1 AS col0 FROM tab2 AS cor0
----
-1343
-220
-4602

query I rowsort
SELECT DISTINCT 5 - + cor0.col0 * - col2 FROM tab1 AS cor0
----
167
3653
7685

query I rowsort
SELECT DISTINCT - cor0.col2 + - col2 AS col1 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT ALL col2 * + col0 + + col0 * + 30 AS col2 FROM tab2 AS cor0
----
399
4368
5372

onlyif mysql # use DIV operator for integer division
query I rowsort label-3390
SELECT ALL - - col1 * 1 DIV + col2 AS col1 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-3390
SELECT ALL - - col1 * 1 / + col2 AS col1 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT DISTINCT + cor0.col2 * - 25 AS col0 FROM tab0 AS cor0
----
-2050
-25
-825

query I rowsort
SELECT ALL col2 * - 61 FROM tab0
----
-2013
-5002
-61

query I rowsort
SELECT + tab2.col1 + col0 AS col2 FROM tab2
----
137
38
96

query I rowsort
SELECT DISTINCT 78 * ( + cor0.col1 ) FROM tab0 cor0
----
6708
7098
7566

query I rowsort
SELECT ALL - col0 + + 37 * col0 FROM tab0 AS cor0
----
1260
3204
864

query I rowsort
SELECT + ( + col0 ) * + col1 AS col2 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - cor0.col2 + - cor1.col1 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to de524937768034b93329bf72a7ba496e

query I rowsort
SELECT col1 + col1 + 27 FROM tab1
----
47
53
79

query I rowsort
SELECT + col1 * - ( + 62 ) + - col0 + + col2 AS col1 FROM tab2 AS cor0
----
-1095
-1902
-3710

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3400
SELECT ALL col0 * - CAST( 2 AS SIGNED ) FROM tab0 AS cor0
----
-178
-48
-70

skipif mysql # not compatible
query I rowsort label-3400
SELECT ALL col0 * - CAST ( 2 AS INTEGER ) FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT + + 42 AS col0 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

onlyif mysql # use DIV operator for integer division
query I rowsort label-3402
SELECT - 58 * cor0.col0 + + ( + 53 ) * col0 DIV - col0 + - col1 FROM tab2 AS cor0
----
-4636
-4652
-490

skipif mysql # not compatible
query I rowsort label-3402
SELECT - 58 * cor0.col0 + + ( + 53 ) * col0 / - col0 + - col1 FROM tab2 AS cor0
----
-4636
-4652
-490

onlyif mysql # use DIV operator for integer division
query I rowsort label-3403
SELECT col1 DIV col1 - tab0.col1 * col0 AS col0 FROM tab0
----
-2063
-3394
-8098

skipif mysql # not compatible
query I rowsort label-3403
SELECT col1 / col1 - tab0.col1 * col0 AS col0 FROM tab0
----
-2063
-3394
-8098

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3404
SELECT DISTINCT ( - col0 ) + CAST( NULL AS SIGNED ) FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-3404
SELECT DISTINCT ( - col0 ) + CAST ( NULL AS INTEGER ) FROM tab1
----
NULL

query I rowsort
SELECT col0 - - col0 * - tab2.col2 AS col2 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT col1 * - col2 + col1 AS col2 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT - tab0.col0 + tab0.col0 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - col2 * col2 + 72 FROM tab1 AS cor0
----
-2844
-3177
-9144

query I rowsort
SELECT ALL col0 * col0 + - 52 AS col1 FROM tab2 AS cor0
----
-3
6032
6189

query I rowsort
SELECT + col0 + - col2 * 8 * + col2 AS col1 FROM tab1 AS cor0
----
-23325
-25928
-73648

query I rowsort
SELECT DISTINCT + col2 + - col2 * + col1 AS col0 FROM tab1 cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL + col0 * cor0.col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + col2 + col1 + 22 AS col0 FROM tab0 AS cor0
----
120
141
195

query I rowsort
SELECT + + ( + col2 ) * - 85 + col1 AS col1 FROM tab2 AS cor0
----
-2151
-2264
-3213

query I rowsort
SELECT - + 50 AS col2 FROM tab1 AS cor0
----
-50
-50
-50

onlyif mysql # use DIV operator for integer division
query I rowsort label-3416
SELECT ALL col1 * col2 DIV - cor0.col0 + col1 + - cor0.col0 col2 FROM tab1 AS cor0
----
-445
-62
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3416
SELECT ALL col1 * col2 / - cor0.col0 + col1 + - cor0.col0 col2 FROM tab1 AS cor0
----
-445
-62
-82

query I rowsort
SELECT 60 * col2 FROM tab0 AS cor0
----
1980
4920
60

onlyif mysql # use DIV operator for integer division
query I rowsort label-3418
SELECT DISTINCT + - col1 + + col2 DIV ( col0 * col0 ) AS col2 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-3418
SELECT DISTINCT + - col1 + + col2 / ( col0 * col0 ) AS col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + col1 + cor0.col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT ALL - col0 * col0 + col0 AS col2 FROM tab1 AS cor0
----
-4032
-6
-6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3421
SELECT + col0 * + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3421
SELECT + col0 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col0 + 6 * col2 FROM tab0 AS cor0
----
-29
174
403

query I rowsort
SELECT - col2 * + 17 AS col0 FROM tab2 AS cor0
----
-442
-459
-646

onlyif mysql # use DIV operator for integer division
query I rowsort label-3424
SELECT 27 DIV + tab2.col0 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 0a35ad941cb1878fb87082ac21ea8241

skipif mysql # not compatible
query I rowsort label-3424
SELECT 27 / + tab2.col0 AS col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 0a35ad941cb1878fb87082ac21ea8241

query I rowsort
SELECT ALL 88 * 28 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 7d3bf0b706033ab10b22f7bd582ec3ad

query I rowsort
SELECT + 59 * 63 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to ad12016ec5877052e69926c49ed87889

query I rowsort
SELECT - 71 + ( col0 ) AS col2 FROM tab0 AS cor0
----
-36
-47
18

query I rowsort
SELECT - + 31 + + cor0.col0 FROM tab1 AS cor0
----
-28
33
49

query I rowsort
SELECT DISTINCT 16 * + col2 FROM tab0 cor0
----
1312
16
528

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( + col0 ) * col1 + + 85 + + col1 col2 FROM tab2 AS cor0
----
-101
-1241
-4458

query I rowsort
SELECT - 6 AS col2 FROM tab1 AS cor0
----
-6
-6
-6

query I rowsort
SELECT - 1 * 83 FROM tab0 AS cor0
----
-83
-83
-83

query I rowsort
SELECT DISTINCT 10 * col1 AS col1 FROM tab2 AS cor0
----
170
310
590

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col1 * cor0.col2 col2 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT ALL - + ( - col2 ) * - cor0.col1 AS col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL col0 + ( + col1 + col2 ) * ( + col2 ) AS col1 FROM tab1
----
10544
3883
4323

query I rowsort
SELECT ALL + ( - 26 ) AS col1 FROM tab1 AS cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to 4e49eac022daeae6f88f610644ba3754

query I rowsort
SELECT DISTINCT col2 + + 4 AS col0 FROM tab2
----
30
31
42

query I rowsort
SELECT DISTINCT cor0.col0 AS col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3440
SELECT ALL - 13 DIV - 46 + - col1 * col2 FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-3440
SELECT ALL - 13 / - 46 + - col1 * col2 FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT - ( 0 ) * col0 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL col1 + col0 * col0 AS col0 FROM tab2
----
6143
6258
80

query I rowsort
SELECT + cor0.col1 * - cor0.col2 * 8 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to bc5f73ce356a9ffb572c9653a72e55ab

query I rowsort
SELECT DISTINCT 11 * 38 + col0 FROM tab2
----
425
496
497

query I rowsort
SELECT col0 * - 70 * - col1 FROM tab0
----
144480
237650
566930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 97 col2 FROM tab0, tab1 AS cor0
----
9 values hashing to e4a6bd848a69226cbb7ad3d154be321b

query I rowsort
SELECT - 48 * - col2 AS col0 FROM tab1
----
2592
2736
4608

query I rowsort
SELECT col0 * + cor0.col0 + 13 FROM tab0 AS cor0
----
1238
589
7934

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - col0 + + col2 col0 FROM tab0 AS cor0
----
-1224
-543
-7839

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 96 + - col0 * + ( + 80 ) col1 FROM tab1 AS cor0
----
-144
-5024
-6304

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3451
SELECT ALL + col2 * CAST( NULL AS DECIMAL ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3451
SELECT ALL + col2 * CAST ( NULL AS REAL ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 * + col2 AS col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT - - 25 + - cor0.col1 * + 34 FROM tab0, tab0 AS cor0
----
9 values hashing to 420df064007da58696336810ed451846

onlyif mysql # use DIV operator for integer division
query I rowsort label-3454
SELECT DISTINCT + - col1 + 31 DIV - 3 AS col0 FROM tab2 AS cor0
----
-27
-41
-69

skipif mysql # not compatible
query I rowsort label-3454
SELECT DISTINCT + - col1 + 31 / - 3 AS col0 FROM tab2 AS cor0
----
-27
-41
-69

query I rowsort
SELECT DISTINCT col1 + col1 * + col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT DISTINCT - col2 + + 40 AS col2 FROM tab1 AS cor0
----
-14
-17
-56

query I rowsort
SELECT DISTINCT + 32 FROM tab1, tab1 cor0
----
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + col1 col2 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT - col1 - col1 * col1 AS col0 FROM tab0 AS cor0
----
-7482
-8372
-9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-3460
SELECT + + cor0.col0 + col1 DIV + cor0.col1 FROM tab2 cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-3460
SELECT + + cor0.col0 + col1 / + cor0.col1 FROM tab2 cor0
----
79
8
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3461
SELECT DISTINCT + 8 + + 18 * col0 * + CAST( NULL AS DECIMAL ) AS col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3461
SELECT DISTINCT + 8 + + 18 * col0 * + CAST ( NULL AS REAL ) AS col2 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3462
SELECT - 31 DIV - col1 + + col1 + 49 AS col2 FROM tab2 AS cor0
----
108
67
81

skipif mysql # not compatible
query I rowsort label-3462
SELECT - 31 / - col1 + + col1 + 49 AS col2 FROM tab2 AS cor0
----
108
67
81

query I rowsort
SELECT + ( + col1 ) + - col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 78 + col2 + cor0.col2 * 35 * - 54 AS col0 FROM tab2 AS cor0
----
-49192
-51081
-71860

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 18 * + col1 + + col2 col1 FROM tab2 AS cor0
----
1088
344
585

query I rowsort
SELECT + - 19 * cor0.col1 FROM tab2 AS cor0
----
-1121
-323
-589

query I rowsort
SELECT - - col1 - + ( - cor0.col0 ) FROM tab0 cor0
----
110
132
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3468
SELECT tab2.col2 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3468
SELECT tab2.col2 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * 94 - + col2 * + col2 AS col2 FROM tab0 AS cor0
----
-15278
-9119
-9173

query I rowsort
SELECT ALL col2 FROM tab0 WHERE NOT - col1 * col2 IN ( + col0 )
----
1
33
82

query I rowsort
SELECT DISTINCT - col2 - - col0 AS col2 FROM tab1
----
-16
-51
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-3472
SELECT - tab1.col2 - + col1 DIV - col2 AS col2 FROM tab1
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-3472
SELECT - tab1.col2 - + col1 / - col2 AS col2 FROM tab1
----
-54
-57
-96

query I rowsort
SELECT - col1 AS col1 FROM tab0 WHERE NULL >= NULL
----

query III rowsort
SELECT ALL * FROM tab2 cor0 WHERE NOT NULL NOT IN ( - cor0.col0 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT ( col2 * - col2 * - col0 ) = ( NULL )
----

query I rowsort
SELECT DISTINCT col0 + + col2 + + col2 AS col2 FROM tab1 WHERE col1 >= NULL
----

query I rowsort
SELECT DISTINCT col0 * col2 * - col1 + - col1 AS col1 FROM tab1
----
-36490
-4238
-99853

onlyif mysql # use DIV operator for integer division
query I rowsort label-3478
SELECT tab2.col2 + + col0 DIV + col1 AS col1 FROM tab2
----
27
27
42

skipif mysql # not compatible
query I rowsort label-3478
SELECT tab2.col2 + + col0 / + col1 AS col1 FROM tab2
----
27
27
42

query I rowsort
SELECT DISTINCT col0 * col0 FROM tab0 WHERE ( col0 ) NOT IN ( col1 * + col2 )
----
1225
576
7921

query I rowsort
SELECT + col2 + tab0.col2 + col1 AS col2 FROM tab0
----
152
255
99

query I rowsort
SELECT - col2 + + col1 - + col0 AS col0 FROM tab0
----
-80
29
61

query I rowsort
SELECT ALL - col0 + - col2 * col1 + col1 FROM tab2
----
-1553
-708
-813

query III rowsort
SELECT * FROM tab1 WHERE NOT tab1.col0 - - col1 NOT IN ( col1 + + col1 / - col2 + col0 * col0 )
----

query I rowsort
SELECT DISTINCT col2 AS col1 FROM tab0 WHERE NOT ( + col1 ) BETWEEN ( - col2 ) AND - col0
----
1
33
82

query I rowsort
SELECT DISTINCT + col2 * tab1.col0 + + col1 * col0 FROM tab1
----
240
4288
8720

query I rowsort
SELECT DISTINCT tab0.col0 + - col1 * - col2 AS col2 FROM tab0 WHERE ( + col1 ) = col2 * - col1
----

query I rowsort
SELECT ALL + col0 + col2 * tab1.col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT + col1 / col2 FROM tab2 AS cor0 WHERE NOT ( col0 ) NOT IN ( + col2 + col1 * - col1 ) OR + col2 > + col2
----

query I rowsort
SELECT - + col2 * - cor0.col1 FROM tab2 AS cor0
----
1534
646
837

query III rowsort
SELECT * FROM tab2 WHERE col2 IN ( col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT - cor0.col2 * col1 + col2 AS col2 FROM tab1 AS cor0
----
-1152
-1350
-513

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * col2 col0 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT + + col1 * + col1 + col1 AS col2 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT cor0.col2 + cor0.col0 + - cor0.col2 AS col0 FROM tab0, tab1 AS cor0
----
3
64
80

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT NULL = ( - col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - 11 * col1 + cor0.col2 col2 FROM tab2 AS cor0
----
-228
-321
-701

query I rowsort
SELECT DISTINCT col0 + col1 + col1 FROM tab1 AS cor0
----
106
55
84

query I rowsort
SELECT + - cor0.col2 + 28 FROM tab1 AS cor0
----
-26
-29
-68

query I rowsort
SELECT DISTINCT col0 * + col1 + - cor0.col1 AS col0 FROM tab0 AS cor0
----
1978
3298
8008

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3500
SELECT col1 + - CAST( col2 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort label-3500
SELECT col1 + - CAST ( col2 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT + - col1 * cor0.col2 + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT + + col1 + - 29 FROM tab1 AS cor0
----
-16
-19
-3

query I rowsort
SELECT DISTINCT - - col2 * - ( col2 ) * cor0.col2 - cor0.col0 FROM tab0 cor0
----
-35961
-36
-551457

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3504
SELECT ALL - col0 * - CAST( NULL AS SIGNED ) + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3504
SELECT ALL - col0 * - CAST ( NULL AS INTEGER ) + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col1 + - 16 FROM tab0 AS cor0
----
70
75
81

query I rowsort
SELECT ALL + col1 * - col2 + - 3 AS col1 FROM tab2 AS cor0
----
-1537
-649
-840

query I rowsort
SELECT ALL + col2 + + ( col1 ) + + col1 FROM tab0 AS cor0
----
195
205
264

query I rowsort
SELECT col2 + + 91 * col0 AS col1 FROM tab1 AS cor0
----
327
5881
7376

query I rowsort
SELECT ALL col0 - cor0.col1 AS col2 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT DISTINCT col1 + 32 FROM tab1 AS cor0
----
42
45
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-3511
SELECT ALL + col2 DIV col2 + + col1 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-3511
SELECT ALL + col2 / col2 + + col1 FROM tab1 AS cor0
----
11
14
27

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3512
SELECT + CAST( NULL AS SIGNED ) + col0 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3512
SELECT + CAST ( NULL AS INTEGER ) + col0 AS col1 FROM tab1 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3513
SELECT ALL - 59 DIV + 34 FROM tab2 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-3513
SELECT ALL - 59 / + 34 FROM tab2 cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3514
SELECT + CAST( NULL AS DECIMAL ) * + col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3514
SELECT + CAST ( NULL AS REAL ) * + col1 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3515
SELECT DISTINCT ( ( col0 ) ) DIV col0 + - 52 + col2 * 50 * col0 AS col2 FROM tab0 AS cor0
----
1699
364849
39549

skipif mysql # not compatible
query I rowsort label-3515
SELECT DISTINCT ( ( col0 ) ) / col0 + - 52 + col2 * 50 * col0 AS col2 FROM tab0 AS cor0
----
1699
364849
39549

query I rowsort
SELECT DISTINCT col0 * + cor0.col1 + col2 * col1 FROM tab1 AS cor0
----
1210
1482
2288

onlyif mysql # use DIV operator for integer division
query I rowsort label-3517
SELECT DISTINCT + col2 * ( 93 ) DIV tab0.col0 col0 FROM tab0
----
127
2
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3517
SELECT DISTINCT + col2 * ( 93 ) / tab0.col0 col0 FROM tab0
----
127
2
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-3518
SELECT - cor0.col0 DIV + 51 FROM tab2 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-3518
SELECT - cor0.col0 / + 51 FROM tab2 AS cor0
----
-1
-1
0

query I rowsort
SELECT - col0 + + ( col2 + col2 ) FROM tab0
----
-33
42
75

query I rowsort
SELECT ALL 80 * 37 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 41ea2ef227d65252296e215d8d82584f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + - col0 col0 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3522
SELECT + - col0 * + cor0.col0 + CAST( + col0 AS SIGNED ) FROM tab2 AS cor0
----
-42
-6006
-6162

skipif mysql # not compatible
query I rowsort label-3522
SELECT + - col0 * + cor0.col0 + CAST ( + col0 AS INTEGER ) FROM tab2 AS cor0
----
-42
-6006
-6162

onlyif mysql # use DIV operator for integer division
query I rowsort label-3523
SELECT DISTINCT + col0 * col1 DIV - col0 + col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-3523
SELECT DISTINCT + col0 * col1 / - col0 + col1 FROM tab0 AS cor0
----
0

query III rowsort
SELECT * FROM tab0 WHERE NOT - col0 IN ( col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3525
SELECT DISTINCT + 40 * + col2 + col0 + col2 * cor0.col0 / - CAST( NULL AS SIGNED ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3525
SELECT DISTINCT + 40 * + col2 + col0 + col2 * cor0.col0 / - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - cor0.col2 * + col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-3527
SELECT + tab1.col1 DIV - col0 + - tab1.col0 FROM tab1
----
-11
-64
-80

skipif mysql # not compatible
query I rowsort label-3527
SELECT + tab1.col1 / - col0 + - tab1.col0 FROM tab1
----
-11
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3528
SELECT DISTINCT + tab0.col2 DIV + col0 FROM tab0
----
0
1

skipif mysql # not compatible
query I rowsort label-3528
SELECT DISTINCT + tab0.col2 / + col0 FROM tab0
----
0
1

query I rowsort
SELECT DISTINCT col0 + + col2 * - col1 + - col0 * + tab1.col1 AS col0 FROM tab1
----
-1146
-1479
-2208

query I rowsort
SELECT - tab2.col0 * - col1 AS col2 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-3531
SELECT DISTINCT - col1 DIV col0 AS col0 FROM tab1
----
-8
0

skipif mysql # not compatible
query I rowsort label-3531
SELECT DISTINCT - col1 / col0 AS col0 FROM tab1
----
-8
0

query I rowsort
SELECT DISTINCT col1 * - tab2.col0 + col1 - + col1 * + col1 AS col2 FROM tab2
----
-1147
-1615
-8024

onlyif mysql # use DIV operator for integer division
query I rowsort label-3533
SELECT - col0 * col0 DIV - col0 col1 FROM tab2
----
7
78
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3533
SELECT - col0 * col0 / - col0 col1 FROM tab2
----
7
78
79

query I rowsort
SELECT ALL 55 * + col1 + col1 * 81 FROM tab2
----
2312
4216
8024

onlyif mysql # use DIV operator for integer division
query I rowsort label-3535
SELECT - col1 DIV - cor0.col1 + - col1 * - col1 AS col1 FROM tab1 AS cor0
----
101
170
677

skipif mysql # not compatible
query I rowsort label-3535
SELECT - col1 / - cor0.col1 + - col1 * - col1 AS col1 FROM tab1 AS cor0
----
101
170
677

query I rowsort
SELECT 17 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col2 + col2 col2 FROM tab0
----
164
2
66

query I rowsort
SELECT - col2 * col0 + + cor0.col1 * col1 AS col2 FROM tab1 AS cor0
----
-3548
-7511
514

query I rowsort
SELECT DISTINCT + col0 + + 13 * - col1 AS col1 FROM tab1 AS cor0
----
-335
-66
-89

query I rowsort
SELECT + - col0 * + 15 + - col1 * + col0 AS col2 FROM tab2 AS cor0
----
-2528
-322
-5772

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3541
SELECT DISTINCT col0 + CAST( NULL AS SIGNED ) * - cor0.col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3541
SELECT DISTINCT col0 + CAST ( NULL AS INTEGER ) * - cor0.col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT - col2 + - col0 * - col2 * cor0.col1 FROM tab2 AS cor0
----
119626
50996
5832

onlyif mysql # use DIV operator for integer division
query I rowsort label-3543
SELECT ALL col2 DIV - ( - col1 ) FROM tab2 AS cor0
----
0
0
2

skipif mysql # not compatible
query I rowsort label-3543
SELECT ALL col2 / - ( - col1 ) FROM tab2 AS cor0
----
0
0
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-3544
SELECT + cor0.col1 + - ( - 8 ) DIV cor0.col1 AS col0 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-3544
SELECT + cor0.col1 + - ( - 8 ) / cor0.col1 AS col0 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3545
SELECT ALL - CAST( - 77 AS SIGNED ) + col1 AS col1 FROM tab0 cor0
----
163
168
174

skipif mysql # not compatible
query I rowsort label-3545
SELECT ALL - CAST ( - 77 AS INTEGER ) + col1 AS col1 FROM tab0 cor0
----
163
168
174

query I rowsort
SELECT - - 92 * cor0.col0 FROM tab2 AS cor0
----
644
7176
7268

query I rowsort
SELECT ALL - + 66 * - col1 FROM tab1 AS cor0
----
1716
660
858

query I rowsort
SELECT + 40 + 53 * col0 FROM tab0 AS cor0
----
1312
1895
4757

query I rowsort
SELECT DISTINCT - col0 + ( + cor0.col0 ) * cor0.col0 AS col1 FROM tab2 AS cor0
----
42
6006
6162

query I rowsort
SELECT - col1 - - col0 * - tab0.col2 AS col2 FROM tab0
----
-132
-7389
-878

query I rowsort
SELECT + col0 * cor0.col1 + - col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT cor0.col1 * - col0 - + 13 AS col0 FROM tab0 AS cor0
----
-2077
-3408
-8112

query I rowsort
SELECT + + 97 FROM tab0 cor0
----
97
97
97

query I rowsort
SELECT ALL + - col2 + col0 * - 86 FROM tab2 AS cor0
----
-629
-6734
-6832

query I rowsort
SELECT col0 * cor0.col1 - - cor0.col1 AS col2 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT - - col0 + cor0.col0 * + 78 + - col1 AS col0 FROM tab2 cor0
----
522
6103
6224

query I rowsort
SELECT - + cor0.col0 + + col1 * - col2 AS col2 FROM tab2 AS cor0
----
-1612
-725
-844

query I rowsort
SELECT ALL - 20 - col2 AS col2 FROM tab1 AS cor0
----
-116
-74
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col2 * col1 + col0 col1 FROM tab1
----
1328
1407
634

query I rowsort
SELECT DISTINCT + col2 + + col0 AS col0 FROM tab1
----
121
176
57

query I rowsort
SELECT 13 * tab2.col0 FROM tab2
----
1014
1027
91

query I rowsort
SELECT - col0 + col0 * - col2 + + col1 * - col1 AS col1 FROM tab2
----
-1157
-3370
-5587

query I rowsort
SELECT ALL cor0.col1 + 53 * - col2 AS col1 FROM tab2 cor0
----
-1319
-1400
-1997

query I rowsort
SELECT + col1 + + cor0.col2 * + col0 AS col0 FROM tab1 AS cor0
----
188
3658
7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-3565
SELECT ALL + - cor0.col1 + col0 DIV - col1 FROM tab2 AS cor0
----
-21
-31
-60

skipif mysql # not compatible
query I rowsort label-3565
SELECT ALL + - cor0.col1 + col0 / - col1 FROM tab2 AS cor0
----
-21
-31
-60

query I rowsort
SELECT ALL 63 + col2 AS col0 FROM tab1
----
117
120
159

query I rowsort
SELECT DISTINCT col1 + + col2 * col1 FROM tab0
----
194
2924
7553

query I rowsort
SELECT ALL 4 + col2 FROM tab1
----
100
58
61

query I rowsort
SELECT 3 + - col1 AS col2 FROM tab1
----
-10
-23
-7

query I rowsort
SELECT cor0.col1 + + cor0.col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + - col2 * + cor0.col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + col1 * col2 * + col1 FROM tab0 AS cor0
----
244068
679042
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col1 + + col2 col1 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT ALL 27 + col0 * tab1.col1 AS col1 FROM tab1
----
105
1067
667

query I rowsort
SELECT ( col0 ) + + tab0.col2 * tab0.col2 AS col0 FROM tab0
----
1113
36
6813

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 * col1 col0 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-3577
SELECT + col0 DIV col2 + col2 AS col2 FROM tab1 AS cor0
----
54
58
96

skipif mysql # not compatible
query I rowsort label-3577
SELECT + col0 / col2 + col2 AS col2 FROM tab1 AS cor0
----
54
58
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-3578
SELECT DISTINCT col0 + col0 * col1 DIV col0 FROM tab2
----
137
38
96

skipif mysql # not compatible
query I rowsort label-3578
SELECT DISTINCT col0 + col0 * col1 / col0 FROM tab2
----
137
38
96

query I rowsort
SELECT ALL - col1 * cor0.col1 * + cor0.col1 FROM tab0 cor0
----
-636056
-753571
-912673

query I rowsort
SELECT - col2 * tab2.col2 AS col2 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT 94 * - col0 + col1 AS col0 FROM tab2
----
-627
-7273
-7409

query I rowsort
SELECT ALL col2 * + tab0.col2 * col2 FROM tab0
----
1
35937
551368

onlyif mysql # use DIV operator for integer division
query I rowsort label-3583
SELECT DISTINCT + col2 DIV - col2 AS col2 FROM tab1
----
-1

skipif mysql # not compatible
query I rowsort label-3583
SELECT DISTINCT + col2 / - col2 AS col2 FROM tab1
----
-1

query I rowsort
SELECT DISTINCT - 81 * tab1.col1 AS col1 FROM tab1
----
-1053
-2106
-810

query I rowsort
SELECT tab2.col0 * col1 + - col1 FROM tab2
----
1326
186
4543

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 9 * - col0 + col2 * - col2 col0 FROM tab0
----
-1305
-316
-7525

query I rowsort
SELECT + ( tab0.col2 + - tab0.col0 * col1 ) FROM tab0
----
-2031
-3394
-8017

query I rowsort
SELECT + col2 * + col1 * col1 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT 20 * - col2 + + tab1.col2 AS col1 FROM tab1
----
-1026
-1083
-1824

query I rowsort
SELECT DISTINCT + col0 * - col1 AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + + col2 * - col0 AS col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - 89 * col2 AS col0 FROM tab2 AS cor0
----
-2314
-2403
-3382

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col1 col2 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT + 7 + col0 * + 92 + - col1 * - col1 AS col1 FROM tab1 AS cor0
----
5995
7536
959

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 29 + col1 col1 FROM tab2 AS cor0
----
46
60
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-3596
SELECT DISTINCT + + col0 * + col2 * 0 + 70 DIV + col1 FROM tab1 AS cor0
----
2
5
7

skipif mysql # not compatible
query I rowsort label-3596
SELECT DISTINCT + + col0 * + col2 * 0 + 70 / + col1 FROM tab1 AS cor0
----
2
5
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + col0 ) col0 FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT + + col1 + + col2 AS col2 FROM tab2 cor0
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3599
SELECT DISTINCT CAST( NULL AS SIGNED ) * col1 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-3599
SELECT DISTINCT CAST ( NULL AS INTEGER ) * col1 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col1 FROM tab2, tab0 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3601
SELECT ALL + ( + col2 + + col0 * - CAST( col1 AS SIGNED ) ) AS col1 FROM tab2
----
-1305
-190
-4576

skipif mysql # not compatible
query I rowsort label-3601
SELECT ALL + ( + col2 + + col0 * - CAST ( col1 AS INTEGER ) ) AS col1 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT 44 + col2 AS col0 FROM tab0
----
126
45
77

query I rowsort
SELECT DISTINCT - ( col2 ) * cor0.col0 * + 55 FROM tab1 AS cor0
----
-200640
-422400
-8910

query I rowsort
SELECT - + 29 * - 33 FROM tab0 cor0
----
957
957
957

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 88 col0 FROM tab0, tab2 AS cor0
----
88

onlyif mysql # use DIV operator for integer division
query I rowsort label-3606
SELECT ALL + col1 DIV + col2 AS col0 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3606
SELECT ALL + col1 / + col2 AS col0 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3607
SELECT DISTINCT - col1 DIV + col1 FROM tab2
----
-1

skipif mysql # not compatible
query I rowsort label-3607
SELECT DISTINCT - col1 / + col1 FROM tab2
----
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3608
SELECT + - col1 * CAST( + 7 AS SIGNED ) - col1 AS col1 FROM tab1 AS cor0
----
-104
-208
-80

skipif mysql # not compatible
query I rowsort label-3608
SELECT + - col1 * CAST ( + 7 AS INTEGER ) - col1 AS col1 FROM tab1 AS cor0
----
-104
-208
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3609
SELECT col0 / - CAST( NULL AS SIGNED ) + - ( + col1 ) col2 FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3609
SELECT col0 / - CAST ( NULL AS INTEGER ) + - ( + col1 ) col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + tab0.col0 * + col2 AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT - col1 * col2 + - col2 AS col1 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT + 30 * col1 AS col1 FROM tab2 AS cor0
----
1770
510
930

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * - col2 * - tab1.col2 col1 FROM tab1
----
207936
737280
8748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( + 83 ) + col1 col1 FROM tab1 AS cor0
----
-57
-70
-73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3615
SELECT - CAST( - col0 AS SIGNED ) - cor0.col1 FROM tab0 AS cor0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort label-3615
SELECT - CAST ( - col0 AS INTEGER ) - cor0.col1 FROM tab0 AS cor0
----
-2
-62
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3616
SELECT ALL CAST( NULL AS SIGNED ) + + 83 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3616
SELECT ALL CAST ( NULL AS INTEGER ) + + 83 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + col1 + col2 AS col1 FROM tab1 AS cor0
----
124
134
205

query I rowsort
SELECT ALL + 77 + + 94 AS col1 FROM tab0 AS cor0
----
171
171
171

query I rowsort
SELECT 95 + + col2 FROM tab1 AS cor0
----
149
152
191

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3620
SELECT - CAST( + col0 AS SIGNED ) FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-3620
SELECT - CAST ( + col0 AS INTEGER ) FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT - ( col1 * - col1 ) FROM tab0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 72 * col2 + col0 col2 FROM tab0
----
107
2400
5993

query I rowsort
SELECT - col1 * + col2 AS col1 FROM tab2
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3624
SELECT CAST( NULL AS SIGNED ) * tab1.col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3624
SELECT CAST ( NULL AS INTEGER ) * tab1.col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - col0 * - col1 + col2 AS col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT ALL + 42 * col0 FROM tab2 cor0
----
294
3276
3318

onlyif mysql # use DIV operator for integer division
query I rowsort label-3627
SELECT DISTINCT 14 DIV - col2 + + cor0.col0 * col0 * col2 AS col0 FROM tab0 AS cor0
----
1211
19008
649522

skipif mysql # not compatible
query I rowsort label-3627
SELECT DISTINCT 14 / - col2 + + cor0.col0 * col0 * col2 AS col0 FROM tab0 AS cor0
----
1211
19008
649522

query I rowsort
SELECT DISTINCT 80 * col0 + + col0 FROM tab2 AS cor0
----
567
6318
6399

query I rowsort
SELECT ALL - ( - cor0.col1 ) FROM tab0, tab2 AS cor0
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT ALL + col2 + 76 * col2 * col1 + - col2 AS col0 FROM tab0
----
215688
567112
7372

query I rowsort
SELECT + ( - cor0.col1 ) + + 30 FROM tab1, tab2 AS cor0
----
9 values hashing to 55470b96a4f7c9f2ff4af5cd7433536e

onlyif mysql # use DIV operator for integer division
query I rowsort label-3632
SELECT DISTINCT + col1 DIV col0 - + 79 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
-229
-5056
-6320

skipif mysql # not compatible
query I rowsort label-3632
SELECT DISTINCT + col1 / col0 - + 79 * + cor0.col0 AS col1 FROM tab1 AS cor0
----
-229
-5056
-6320

query I rowsort
SELECT DISTINCT + 39 * + col0 FROM tab2 AS cor0
----
273
3042
3081

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 + + col2 col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT - - 94 * col2 FROM tab1 AS cor0
----
5076
5358
9024

query I rowsort
SELECT + - cor0.col2 + col1 * col0 AS col0 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT - - cor0.col1 + - col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 83 col1 FROM tab0 AS cor0
----
-83

query I rowsort
SELECT DISTINCT - + col2 - col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT col1 * + tab0.col0 * col2 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT + + cor0.col0 * + col1 + + col1 AS col0 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT + col2 * - col0 + - 78 - col1 * - col1 AS col2 FROM tab0 cor0
----
6526
905
9296

query I rowsort
SELECT + 93 + + 63 - col2 * - col1 AS col0 FROM tab0
----
253
2994
7618

query I rowsort
SELECT ALL 69 - + col2 AS col2 FROM tab2
----
31
42
43

query I rowsort
SELECT DISTINCT 87 * cor0.col0 + col2 FROM tab2 cor0
----
636
6812
6911

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3646
SELECT ALL - col1 + col0 * - CAST( NULL AS SIGNED ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3646
SELECT ALL - col1 + col0 * - CAST ( NULL AS INTEGER ) col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT cor0.col1 * + ( - col1 ) AS col0 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - 58 AS col1 FROM tab2, tab2 AS cor0
----
-58

query I rowsort
SELECT - col1 * 26 + 74 AS col0 FROM tab2 AS cor0
----
-1460
-368
-732

query I rowsort
SELECT ALL col1 + cor0.col2 * - 90 FROM tab0 AS cor0
----
-2884
-7289
7

query I rowsort
SELECT DISTINCT col2 + + col1 * - col2 AS col2 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT ALL col1 * - 98 * col0 + - col2 AS col1 FROM tab2 AS cor0
----
-131652
-21293
-451022

query I rowsort
SELECT DISTINCT - col1 * col2 + cor0.col2 AS col1 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT + - cor0.col1 * - 11 + + 42 AS col0 FROM tab0 AS cor0
----
1043
1109
988

query I rowsort
SELECT DISTINCT + col2 * - 57 FROM tab2 cor0
----
-1482
-1539
-2166

query I rowsort
SELECT ALL - col1 + 61 * 77 AS col1 FROM tab2 cor0
----
4638
4666
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3657
SELECT ALL + cor0.col2 * + cor0.col0 + + cor0.col2 DIV + col0 FROM tab0 AS cor0
----
35
7298
793

skipif mysql # not compatible
query I rowsort label-3657
SELECT ALL + cor0.col2 * + cor0.col0 + + cor0.col2 / + col0 FROM tab0 AS cor0
----
35
7298
793

query I rowsort
SELECT DISTINCT + - col2 * + 44 FROM tab2 cor0
----
-1144
-1188
-1672

query I rowsort
SELECT ALL + - col0 * - col1 + + cor0.col2 FROM tab2 cor0
----
1381
244
4628

query I rowsort
SELECT col1 + + 85 AS col1 FROM tab0 cor0
----
171
176
182

query I rowsort
SELECT DISTINCT - - col2 + 24 AS col2 FROM tab2 AS cor0
----
50
51
62

query I rowsort
SELECT DISTINCT + col2 * + 1 + + cor0.col0 * + col0 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT - + col2 + col2 + cor0.col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + 55 FROM tab1 cor0
----
55
55
55

query I rowsort
SELECT - + col2 * 12 - col0 FROM tab1 AS cor0
----
-1232
-651
-748

query I rowsort
SELECT - - col2 * 38 FROM tab1 AS cor0
----
2052
2166
3648

onlyif mysql # use DIV operator for integer division
query I rowsort label-3667
SELECT + col1 DIV + tab1.col0 + + tab1.col0 AS col2 FROM tab1
----
11
64
80

skipif mysql # not compatible
query I rowsort label-3667
SELECT + col1 / + tab1.col0 + + tab1.col0 AS col2 FROM tab1
----
11
64
80

query I rowsort
SELECT ALL 87 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 8661ffbd1a72897c495405c53b816e50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3669
SELECT + col2 * - CAST( - ( + col1 ) * 30 AS SIGNED ) FROM tab2
----
19380
25110
46020

skipif mysql # not compatible
query I rowsort label-3669
SELECT + col2 * - CAST ( - ( + col1 ) * 30 AS INTEGER ) FROM tab2
----
19380
25110
46020

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - 20 + + col2 col0 FROM tab2 AS cor0
----
1206
378
647

query I rowsort
SELECT ALL + col2 * ( col2 ) * col2 FROM tab2 cor0
----
17576
19683
54872

query I rowsort
SELECT col2 * 42 + col2 FROM tab1 AS cor0
----
2322
2451
4128

query I rowsort
SELECT ALL col1 * col1 + col0 * col1 AS col0 FROM tab0 AS cor0
----
12804
16380
9460

onlyif mysql # use DIV operator for integer division
query I rowsort label-3674
SELECT - col1 DIV - col1 + col1 AS col0 FROM tab2 AS cor0
----
18
32
60

skipif mysql # not compatible
query I rowsort label-3674
SELECT - col1 / - col1 + col1 AS col0 FROM tab2 AS cor0
----
18
32
60

query I rowsort
SELECT col0 + col2 * ( + cor0.col2 ) AS col1 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT - col0 * - ( - col2 ) FROM tab1 AS cor0
----
-162
-3648
-7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3677
SELECT DISTINCT cor0.col0 - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3677
SELECT DISTINCT cor0.col0 - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT - col1 * col0 + col0 FROM tab1 AS cor0
----
-576
-75
-960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 - cor0.col2 col2 FROM tab1 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3680
SELECT col1 * ( - 9 ) + col0 DIV - 1 FROM tab2 AS cor0
----
-232
-286
-609

skipif mysql # not compatible
query I rowsort label-3680
SELECT col1 * ( - 9 ) + col0 / - 1 FROM tab2 AS cor0
----
-232
-286
-609

query I rowsort
SELECT ALL cor0.col0 * 84 * + col0 FROM tab1 AS cor0
----
344064
537600
756

onlyif mysql # use DIV operator for integer division
query I rowsort label-3682
SELECT + 49 DIV + cor0.col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-3682
SELECT + 49 / + cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col0 * col0 * col0 AS col0 FROM tab2 cor0
----
343
474552
493039

query I rowsort
SELECT + + cor0.col0 * cor0.col2 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - 46 * cor0.col0 AS col0 FROM tab0 AS cor0
----
-1104
-1610
-4094

query I rowsort
SELECT DISTINCT + 47 * + col1 AS col1 FROM tab0 AS cor0
----
4042
4277
4559

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3687
SELECT - + CAST( NULL AS SIGNED ) + col1 * col1 col0 FROM tab0 cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3687
SELECT - + CAST ( NULL AS INTEGER ) + col1 * col1 col0 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 58 FROM tab2 cor0
----
-58

query I rowsort
SELECT ALL - - col2 - - col1 * col1 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT - col0 * + col1 + + cor0.col2 - + col2 AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + 49 * cor0.col2 FROM tab0 AS cor0
----
1617
4018
49

query I rowsort
SELECT + + col1 * - cor0.col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - 28 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c3e7fa3d059fc708f03c60e9cef0c115

query I rowsort
SELECT + + 29 * col2 * ( 77 ) AS col1 FROM tab1 AS cor0
----
120582
127281
214368

query I rowsort
SELECT 38 + - cor0.col0 FROM tab1 AS cor0
----
-26
-42
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-3696
SELECT + 92 + col0 DIV col2 FROM tab0 AS cor0
----
127
92
93

skipif mysql # not compatible
query I rowsort label-3696
SELECT + 92 + col0 / col2 FROM tab0 AS cor0
----
127
92
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-3697
SELECT col0 + - col1 DIV - ( - col2 * col1 ) FROM tab0 cor0
----
24
34
89

skipif mysql # not compatible
query I rowsort label-3697
SELECT col0 + - col1 / - ( - col2 * col1 ) FROM tab0 cor0
----
24
34
89

query I rowsort
SELECT - cor0.col0 - - cor0.col2 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT + - col2 * ( - col2 ) AS col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - + cor0.col2 + col1 * + col1 FROM tab0 AS cor0
----
7363
8199
9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-3701
SELECT col0 DIV 42 FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-3701
SELECT col0 / 42 FROM tab2 AS cor0
----
0
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 36 col1 FROM tab1 AS cor0
----
36
36
36

query I rowsort
SELECT ALL + cor0.col0 * + cor2.col2 AS col0 FROM tab1, tab0 AS cor0, tab1 AS cor1, tab2, tab0 AS cor2
----
243 values hashing to f8f15080964d346fb2fc5afd2d4258be

onlyif mysql # use DIV operator for integer division
query I rowsort label-3704
SELECT ALL + col0 + - 76 DIV - col0 AS col2 FROM tab0
----
27
37
89

skipif mysql # not compatible
query I rowsort label-3704
SELECT ALL + col0 + - 76 / - col0 AS col2 FROM tab0
----
27
37
89

query I rowsort
SELECT + + ( - col0 ) * + col1 + + ( col0 ) FROM tab1 AS cor0
----
-576
-75
-960

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3706
SELECT - CAST( NULL AS SIGNED ) col1 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-3706
SELECT - CAST ( NULL AS INTEGER ) col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT - - 45 AS col1 FROM tab0 cor0
----
45
45
45

query I rowsort
SELECT - cor0.col0 + - col2 * - ( + col1 ) AS col1 FROM tab2 AS cor0
----
1456
567
830

query I rowsort
SELECT ALL - 8 AS col1 FROM tab1
----
-8
-8
-8

query I rowsort
SELECT + cor0.col0 FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

onlyif mysql # use DIV operator for integer division
query I rowsort label-3711
SELECT col0 * - ( + col0 ) DIV + col0 AS col0 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3711
SELECT col0 * - ( + col0 ) / + col0 AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL col2 + + 36 FROM tab1 AS cor0
----
132
90
93

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - - col0 * CAST ( + 83 AS REAL ) + + col1 FROM tab2 cor0
----
612
6533
6574

query I rowsort
SELECT col1 + ( col1 ) FROM tab1 cor0
----
20
26
52

query I rowsort
SELECT ALL col0 + + col0 * 60 * - col2 FROM tab2 AS cor0
----
-11333
-121602
-180041

query I rowsort
SELECT DISTINCT 11 + + 17 AS col0 FROM tab1, tab2 AS cor0
----
28

query I rowsort
SELECT - 28 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to eac00a95d734c7071360ed392c3f39bc

query I rowsort
SELECT ALL + 49 * - cor0.col0 + + col1 FROM tab0 AS cor0
----
-1090
-1618
-4270

query I rowsort
SELECT DISTINCT + - ( + col2 ) AS col1 FROM tab1 AS cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 45 * col2 * col2 col2 FROM tab2 AS cor0
----
-30420
-32805
-64980

query I rowsort
SELECT ALL + col2 + 67 AS col2 FROM tab2 AS cor0
----
105
93
94

query I rowsort
SELECT DISTINCT + ( - cor0.col1 ) * col1 AS col2 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT col2 * - 40 FROM tab2
----
-1040
-1080
-1520

query I rowsort
SELECT 60 * cor0.col0 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to b6f806a2a820db2d3281c31b431cfb4b

query I rowsort
SELECT - col2 * + col1 + col2 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT - + 14 AS col2 FROM tab1 cor0
----
-14
-14
-14

query I rowsort
SELECT ALL - + col0 + - col0 * + 60 - ( - col0 ) FROM tab1 AS cor0
----
-180
-3840
-4800

query I rowsort
SELECT DISTINCT - 70 + col0 FROM tab1 AS cor0
----
-6
-67
10

query I rowsort
SELECT 42 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT cor0.col0 + col1 * col0 FROM tab0 cor0
----
2088
3430
8188

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 7 col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 3362c0cb2b2c663037159d0699d46b76

query I rowsort
SELECT - 97 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 12bd12d33f03250bee508c5641e140d5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 - tab1.col0 * + col2 col0 FROM tab1
----
-188
-3658
-7693

query I rowsort
SELECT - + col1 + - col1 AS col1 FROM tab0 AS cor0
----
-172
-182
-194

onlyif mysql # use DIV operator for integer division
query I rowsort label-3735
SELECT cor0.col2 - - col1 DIV - col1 FROM tab2 AS cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-3735
SELECT cor0.col2 - - col1 / - col1 FROM tab2 AS cor0
----
25
26
37

query I rowsort
SELECT 21 * - col2 * - col1 + - col0 AS col0 FROM tab1 AS cor0
----
11906
26128
29481

query I rowsort
SELECT + - 54 + col1 AS col1 FROM tab0 AS cor0
----
32
37
43

query I rowsort
SELECT 32 AS col1 FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to cf4f01ac97eb83445b1721f3ae28961a

query I rowsort
SELECT - col0 * + col1 - - ( - tab0.col0 ) AS col2 FROM tab0
----
-2088
-3430
-8188

query I rowsort
SELECT DISTINCT + col1 * - col0 * + cor0.col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT ALL - - cor0.col0 * + cor0.col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL - + col0 * - 92 AS col0 FROM tab1 AS cor0
----
276
5888
7360

query I rowsort
SELECT col1 * col1 + + 88 AS col2 FROM tab0 AS cor0
----
7484
8369
9497

query I rowsort
SELECT ALL + col1 * - col1 - col1 FROM tab0 cor0
----
-7482
-8372
-9506

query I rowsort
SELECT + col0 * + col2 * cor0.col0 FROM tab1 AS cor0
----
233472
486
614400

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3746
SELECT col1 * - CAST( 95 AS SIGNED ) FROM tab0
----
-8170
-8645
-9215

skipif mysql # not compatible
query I rowsort label-3746
SELECT col1 * - CAST ( 95 AS INTEGER ) FROM tab0
----
-8170
-8645
-9215

query I rowsort
SELECT + col2 + ( - col1 ) * - col0 + + col0 AS col2 FROM tab0
----
2121
3431
8270

query I rowsort
SELECT col0 + + col1 + - col2 * col2 FROM tab0
----
-6544
-979
131

query I rowsort
SELECT DISTINCT - - col0 * + 29 FROM tab0 AS cor0
----
1015
2581
696

query I rowsort
SELECT DISTINCT - col0 * ( col0 ) AS col1 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT - + col1 + ( + col2 ) AS col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT + - col2 - - ( 89 ) FROM tab2 AS cor0
----
51
62
63

query I rowsort
SELECT ALL - + col0 * - 46 + + 55 * col1 AS col1 FROM tab1 AS cor0
----
1568
3494
4395

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 + - col1 * 77 col2 FROM tab1 AS cor0
----
-1999
-706
-921

query I rowsort
SELECT ALL + col1 + 13 + + cor0.col1 FROM tab2 AS cor0
----
131
47
75

query I rowsort
SELECT DISTINCT - col2 * 18 * cor0.col0 FROM tab0 cor0
----
-131364
-14256
-630

query I rowsort
SELECT 96 + - col1 FROM tab1
----
70
83
86

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0 CROSS JOIN tab2, tab0 AS cor1, tab1 AS cor2
----
3645 values hashing to e678818485e7b492c8b5d6db976ebc7d

query I rowsort
SELECT DISTINCT - - 26 * col0 FROM tab1 AS cor0
----
1664
2080
78

query I rowsort
SELECT + 77 FROM tab0 cor0
----
77
77
77

query I rowsort
SELECT ( 19 ) AS col0 FROM tab0 AS cor0
----
19
19
19

onlyif mysql # use DIV operator for integer division
query I rowsort label-3762
SELECT ALL 70 * cor0.col0 + col0 * col1 DIV - 41 AS col1 FROM tab2 AS cor0
----
485
5348
5498

skipif mysql # not compatible
query I rowsort label-3762
SELECT ALL 70 * cor0.col0 + col0 * col1 / - 41 AS col1 FROM tab2 AS cor0
----
485
5348
5498

onlyif mysql # use DIV operator for integer division
query I rowsort label-3763
SELECT 89 DIV 74 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3763
SELECT 89 / 74 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - 38 * - col1 FROM tab2 AS cor0
----
1178
2242
646

onlyif mysql # use DIV operator for integer division
query I rowsort label-3765
SELECT ALL + col1 + col0 DIV + col1 AS col1 FROM tab1 AS cor0
----
16
19
26

skipif mysql # not compatible
query I rowsort label-3765
SELECT ALL + col1 + col0 / + col1 AS col1 FROM tab1 AS cor0
----
16
19
26

query I rowsort
SELECT + - col0 * + cor0.col1 AS col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL cor0.col2 + + col1 + col2 * + 77 * cor0.col2 AS col2 FROM tab2 AS cor0
----
111243
52137
56191

query I rowsort
SELECT - col1 * 98 AS col1 FROM tab2 AS cor0
----
-1666
-3038
-5782

query I rowsort
SELECT + - 35 + + 82 FROM tab2 AS cor0
----
47
47
47

query I rowsort
SELECT ALL 11 + + cor0.col2 FROM tab2 AS cor0
----
37
38
49

query I rowsort
SELECT + col2 * + cor0.col2 * col1 AS col2 FROM tab1 AS cor0
----
119808
32490
75816

query I rowsort
SELECT ALL 71 + 13 AS col2 FROM tab2 cor0
----
84
84
84

query I rowsort
SELECT + cor0.col0 * + 97 FROM tab2 AS cor0
----
679
7566
7663

query I rowsort
SELECT ALL + col1 * col0 + + col0 * + 23 FROM tab1 cor0
----
147
2112
2880

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3775
SELECT ALL - CAST( NULL AS SIGNED ) * col2 * - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3775
SELECT ALL - CAST ( NULL AS INTEGER ) * col2 * - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - tab0.col1 * ( 4 ) AS col0 FROM tab0
----
-344
-364
-388

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab1.col1 * + col2 + 23 * col1 col0 FROM tab1
----
1547
2002
800

query I rowsort
SELECT ALL - 56 AS col0 FROM tab0, tab2 AS cor0, tab1, tab0 AS cor1
----
81 values hashing to 34348c65780193c8d601ab14b29af6e7

query I rowsort
SELECT + ( - cor0.col1 ) AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT DISTINCT - col0 * col0 + + col0 FROM tab1
----
-4032
-6
-6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 - - col1 * - col2 col1 FROM tab1 AS cor0
----
-1168
-1401
-506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3782
SELECT DISTINCT - - CAST( col0 AS SIGNED ) + - col2 * ( col1 ) FROM tab1 AS cor0
----
-1168
-1401
-506

skipif mysql # not compatible
query I rowsort label-3782
SELECT DISTINCT - - CAST ( col0 AS INTEGER ) + - col2 * ( col1 ) FROM tab1 AS cor0
----
-1168
-1401
-506

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3783
SELECT - col2 * col1 + - col2 + + CAST( col2 AS SIGNED ) FROM tab1
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-3783
SELECT - col2 * col1 + - col2 + + CAST ( col2 AS INTEGER ) FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT + col1 * col2 + - ( ( - col2 ) ) FROM tab0
----
2871
7544
98

query I rowsort
SELECT DISTINCT - col2 + - 16 AS col2 FROM tab1 AS cor0
----
-112
-70
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-3786
SELECT col0 + col1 DIV - cor0.col1 AS col1 FROM tab1 cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-3786
SELECT col0 + col1 / - cor0.col1 AS col1 FROM tab1 cor0
----
2
63
79

query I rowsort
SELECT + col2 * col0 + col1 AS col0 FROM tab0
----
132
7389
878

query I rowsort
SELECT ALL 97 AS col0 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5e0d31ac41981bcdf6a665538a71a09c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor0.col1 col1 FROM tab2, tab2 cor0
----
17
31
59

query I rowsort
SELECT ALL - 18 AS col2 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 2dbe09d9295cfd52d854fefabf2cec4e

query I rowsort
SELECT + col0 * 78 FROM tab1 AS cor0
----
234
4992
6240

onlyif mysql # use DIV operator for integer division
query I rowsort label-3792
SELECT DISTINCT + cor0.col0 DIV - 24 AS col0 FROM tab1 AS cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-3792
SELECT DISTINCT + cor0.col0 / - 24 AS col0 FROM tab1 AS cor0
----
-2
-3
0

query I rowsort
SELECT + col2 * 33 AS col2 FROM tab0 AS cor0
----
1089
2706
33

query I rowsort
SELECT DISTINCT col0 * - 76 + 8 * - col1 FROM tab0 cor0
----
-2512
-3436
-7492

query I rowsort
SELECT ALL col1 + - ( col1 ) * col0 FROM tab1 cor0
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-3796
SELECT col0 DIV - 27 FROM tab0 AS cor0
----
-1
-3
0

skipif mysql # not compatible
query I rowsort label-3796
SELECT col0 / - 27 FROM tab0 AS cor0
----
-1
-3
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3797
SELECT ALL + col2 DIV - 94 + + col0 AS col1 FROM tab2 AS cor0
----
7
78
79

skipif mysql # not compatible
query I rowsort label-3797
SELECT ALL + col2 / - 94 + + col0 AS col1 FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT + col2 * + 21 FROM tab1 AS cor0
----
1134
1197
2016

query I rowsort
SELECT + 48 * col2 AS col0 FROM tab1 cor0
----
2592
2736
4608

query I rowsort
SELECT - 87 AS col0 FROM tab1, tab1 cor0
----
9 values hashing to 84bcab58a965cc8ae97b39d2d01b3d23

query I rowsort
SELECT 63 + col1 + + 84 * 53 FROM tab0 AS cor0
----
4601
4606
4612

onlyif mysql # use DIV operator for integer division
query I rowsort label-3802
SELECT - + cor0.col1 DIV - col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3802
SELECT - + cor0.col1 / - col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - col2 * col2 + col0 * col2 + col0 AS col2 FROM tab0 AS cor0
----
-273
663
69

query I rowsort
SELECT ALL 63 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 38764a6e696d1a6b5095e29ef84959c0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3805
SELECT ALL cor0.col0 DIV cor0.col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-3805
SELECT ALL cor0.col0 / cor0.col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 60 * col0 + + col2 - 67 * + col0 col0 FROM tab2 AS cor0
----
-22
-515
-520

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3807
SELECT ALL - col0 * cor0.col0 + - CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3807
SELECT ALL - col0 * cor0.col0 + - CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 + col1 * ( cor0.col0 ) AS col1 FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT - - col2 * + 21 + - col0 AS col1 FROM tab2 AS cor0
----
468
560
719

query I rowsort
SELECT + - col2 * 94 AS col0 FROM tab1 AS cor0
----
-5076
-5358
-9024

onlyif mysql # use DIV operator for integer division
query I rowsort label-3811
SELECT - + col1 + + cor0.col2 DIV cor0.col2 FROM tab0 cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-3811
SELECT - + col1 + + cor0.col2 / cor0.col2 FROM tab0 cor0
----
-85
-90
-96

query I rowsort
SELECT ALL 31 AS col2 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to c3c6f92f0ca72d71793339f88a57e336

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + cor0.col1 + - col1 * col1 col1 FROM tab2 AS cor0
----
-1178
-1632
-8083

query I rowsort
SELECT ALL - 17 + + col1 * 57 FROM tab0
----
4885
5170
5512

onlyif mysql # use DIV operator for integer division
query I rowsort label-3815
SELECT ALL + col0 - - col2 DIV - col2 AS col1 FROM tab0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-3815
SELECT ALL + col0 - - col2 / - col2 AS col1 FROM tab0
----
23
34
88

query I rowsort
SELECT ALL tab1.col0 * tab1.col2 FROM tab1
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-3817
SELECT DISTINCT col1 + col0 * col0 DIV col1 + col1 * tab2.col1 FROM tab2
----
3643
673
993

skipif mysql # not compatible
query I rowsort label-3817
SELECT DISTINCT col1 + col0 * col0 / col1 + col1 * tab2.col1 FROM tab2
----
3643
673
993

query III rowsort
SELECT * FROM tab0 WHERE NOT NULL NOT BETWEEN ( NULL ) AND ( NULL )
----

query I rowsort
SELECT ALL - tab0.col0 * - col1 AS col0 FROM tab0
----
2064
3395
8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * col0 col1 FROM tab0 AS cor0
----
35
7298
792

onlyif mysql # use DIV operator for integer division
query I rowsort label-3821
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-3821
SELECT ALL col0 / - col0 col0 FROM tab2 AS cor0
----
-1
-1
-1

query I rowsort
SELECT + + cor0.col2 + + col0 * - col2 AS col1 FROM tab1 AS cor0
----
-108
-3591
-7584

query I rowsort
SELECT - cor0.col0 AS col1 FROM tab1, tab2, tab2 cor0
----
27 values hashing to c82df1de3cb666224690a83f3d790d79

query I rowsort
SELECT DISTINCT - - col2 + - col1 AS col0 FROM tab1 AS cor0
----
28
47
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 + col0 col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT DISTINCT + - cor0.col0 + + col0 + col0 * col2 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT ALL + + col1 + cor0.col0 AS col0 FROM tab0 AS cor0
----
110
132
180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - col0 col1 FROM tab0 AS cor0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * + col1 col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + - col1 * col0 - ( - cor0.col1 ) AS col0 FROM tab0 cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL - 40 * col1 + - ( cor0.col0 ) AS col2 FROM tab2 cor0
----
-1247
-2438
-759

query I rowsort
SELECT DISTINCT + - cor0.col2 + col2 AS col1 FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3833
SELECT ALL col0 DIV - col0 + + cor0.col1 FROM tab2 AS cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-3833
SELECT ALL col0 / - col0 + + cor0.col1 FROM tab2 AS cor0
----
16
30
58

query I rowsort
SELECT col0 * + tab2.col0 + col1 + + col1 FROM tab2
----
111
6202
6275

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col0 * col1 + - tab0.col2 + - tab0.col2 col0 FROM tab0
----
3393
663954
68046

onlyif mysql # use DIV operator for integer division
query I rowsort label-3836
SELECT col1 * + col1 + tab1.col0 DIV + col2 - col1 FROM tab1
----
156
650
91

skipif mysql # not compatible
query I rowsort label-3836
SELECT col1 * + col1 + tab1.col0 / + col2 - col1 FROM tab1
----
156
650
91

query I rowsort
SELECT ALL + 86 + col1 + cor0.col1 AS col0 FROM tab1 AS cor0
----
106
112
138

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3838
SELECT ALL - col0 * + col0 + - col1 + ( cor0.col0 + CAST( - col0 AS SIGNED ) ) * cor0.col1 AS col0 FROM tab2 AS cor0
----
-6143
-6258
-80

skipif mysql # not compatible
query I rowsort label-3838
SELECT ALL - col0 * + col0 + - col1 + ( cor0.col0 + CAST ( - col0 AS INTEGER ) ) * cor0.col1 AS col0 FROM tab2 AS cor0
----
-6143
-6258
-80

query I rowsort
SELECT ALL + 8 * col2 + col0 * col2 AS col0 FROM tab2 AS cor0
----
2236
3306
405

query I rowsort
SELECT - 55 * col0 AS col0 FROM tab2 AS cor0
----
-385
-4290
-4345

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3841
SELECT ALL col1 / col0 + - CAST( NULL AS SIGNED ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3841
SELECT ALL col1 / col0 + - 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 + - col0 * cor0.col2 col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + col1 * col0 + + col1 AS col0 FROM tab2
----
1360
248
4661

query I rowsort
SELECT ALL col0 + + col2 * - col2 AS col0 FROM tab0 WHERE NOT ( NULL ) < col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-3845
SELECT col1 + - tab0.col0 DIV - tab0.col0 FROM tab0
----
87
92
98

skipif mysql # not compatible
query I rowsort label-3845
SELECT col1 + - tab0.col0 / - tab0.col0 FROM tab0
----
87
92
98

query I rowsort
SELECT DISTINCT - col1 + + tab2.col2 AS col0 FROM tab2
----
-33
-4
21

query I rowsort
SELECT DISTINCT col2 AS col0 FROM tab0 WHERE ( NULL ) BETWEEN NULL AND ( col0 )
----

query I rowsort
SELECT ALL col0 + col0 + + col2 FROM tab2
----
182
196
41

query I rowsort
SELECT ALL col0 * tab0.col1 + + col2 - col0 FROM tab0
----
2073
3361
8092

query I rowsort
SELECT ALL - col2 + tab2.col0 + + col2 FROM tab2
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-3851
SELECT DISTINCT - col1 + - tab0.col0 DIV - tab0.col2 AS col1 FROM tab0 WHERE ( + col1 + + col2 ) NOT IN ( col0 )
----
-62
-86
-90

skipif mysql # not compatible
query I rowsort label-3851
SELECT DISTINCT - col1 + - tab0.col0 / - tab0.col2 AS col1 FROM tab0 WHERE ( + col1 + + col2 ) NOT IN ( col0 )
----
-62
-86
-90

query I rowsort
SELECT tab0.col0 * col1 + - col1 AS col1 FROM tab0
----
1978
3298
8008

query I rowsort
SELECT ALL col0 * - col2 / tab0.col1 AS col0 FROM tab0 WHERE NULL NOT BETWEEN ( col2 / + col1 ) AND NULL
----

query I rowsort
SELECT col2 * - col0 * col0 + col2 FROM tab2
----
-1296
-158158
-237120

query I rowsort
SELECT + tab2.col2 * col0 * + col1 AS col1 FROM tab2
----
119652
51034
5859

query I rowsort
SELECT ALL - col1 AS col0 FROM tab1 WHERE NOT col0 + col1 = NULL
----

query I rowsort
SELECT tab1.col2 + + tab1.col1 * col2 + col0 FROM tab1
----
1424
1461
691

query I rowsort
SELECT + col1 AS col1 FROM tab2 WHERE NOT col0 NOT IN ( - col0 + col2 )
----

query I rowsort
SELECT ALL - col2 * col1 + col0 AS col1 FROM tab0
----
-2814
-62
-7373

query I rowsort
SELECT col2 * col1 + tab0.col1 + - tab0.col0 FROM tab0
----
159
2900
7464

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL BETWEEN NULL AND col2 + + col2
----

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE ( NULL ) NOT IN ( col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * col2 + col1 * + col1 * - col2 col1 FROM tab1
----
-14976
-35100
-5130

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( NULL ) < + col0 * + col1
----

query I rowsort
SELECT DISTINCT col1 AS col1 FROM tab2 WHERE NULL >= NULL
----

query I rowsort
SELECT col1 + col0 * col0 AS col2 FROM tab1
----
35
4106
6413

query I rowsort
SELECT tab2.col0 * tab2.col1 * col1 + col2 * + col0 FROM tab2 WHERE col0 >= ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 + + col1 col0 FROM tab1
----
20
26
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab1.col1 * - col1 * col1 - col2 col0 FROM tab1 WHERE NOT col1 IN ( col0 )
----
17522
2101
943

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( + col0 + - 31 ) col2 FROM tab1
----
-28
33
49

query I rowsort
SELECT - col1 * col0 + col0 AS col2 FROM tab1
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-3872
SELECT DISTINCT - 24 DIV col0 AS col0 FROM tab2
----
-3
0

skipif mysql # not compatible
query I rowsort label-3872
SELECT DISTINCT - 24 / col0 AS col0 FROM tab2
----
-3
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-3873
SELECT + cor0.col1 DIV + col1 FROM tab2 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-3873
SELECT + cor0.col1 / + col1 FROM tab2 cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - col1 + + col1 * col0 AS col2 FROM tab1 AS cor0
----
1027
52
630

onlyif mysql # use DIV operator for integer division
query I rowsort label-3875
SELECT ALL + - col1 DIV col0 AS col0 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-3875
SELECT ALL + - col1 / col0 AS col0 FROM tab1 AS cor0
----
-8
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * - col1 col2 FROM tab0 AS cor0
----
2064
3395
8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3877
SELECT ALL col2 * - CAST( - col0 * col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
26136
35
598436

skipif mysql # not compatible
query I rowsort label-3877
SELECT ALL col2 * - CAST ( - col0 * col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT - col0 + - ( col1 ) FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL - + col2 * - col0 * 86 FROM tab2 AS cor0
----
16254
174408
258172

query I rowsort
SELECT DISTINCT + col1 + - 96 FROM tab2 AS cor0
----
-37
-65
-79

query I rowsort
SELECT - + cor0.col1 AS col2 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT + tab1.col0 + - col0 * + 95 AS col2 FROM tab1
----
-282
-6016
-7520

query I rowsort
SELECT ALL 36 * - tab2.col2 * 58 AS col2 FROM tab2
----
-54288
-56376
-79344

query I rowsort
SELECT + col0 * - 5 FROM tab2 AS cor0
----
-35
-390
-395

query I rowsort
SELECT - col2 * - 62 FROM tab0 cor0
----
2046
5084
62

query I rowsort
SELECT DISTINCT - col1 * 11 - + col1 FROM tab0 cor0
----
-1032
-1092
-1164

query I rowsort
SELECT ALL + col2 + cor0.col0 AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT + col2 + - 81 AS col1 FROM tab0 AS cor0
----
-48
-80
1

query I rowsort
SELECT - 0 + col2 AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT 10 + + col1 * - cor0.col0 * 86 AS col1 FROM tab0 AS cor0
----
-177494
-291960
-696504

query I rowsort
SELECT DISTINCT 10 * + 19 FROM tab2 AS cor0
----
190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3892
SELECT - + CAST( NULL AS DECIMAL ) + - col0 * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3892
SELECT - + CAST ( NULL AS REAL ) + - col0 * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3893
SELECT ALL + 14 + + col1 DIV - cor0.col0 FROM tab0 AS cor0
----
11
12
13

skipif mysql # not compatible
query I rowsort label-3893
SELECT ALL + 14 + + col1 / - cor0.col0 FROM tab0 AS cor0
----
11
12
13

onlyif mysql # use DIV operator for integer division
query I rowsort label-3894
SELECT DISTINCT col2 + - col0 DIV col0 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-3894
SELECT DISTINCT col2 + - col0 / col0 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT 51 + ( col2 + col2 ) * - col0 FROM tab0 cor0
----
-14545
-1533
-19

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3896
SELECT ALL + CAST( - col0 AS SIGNED ) FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-3896
SELECT ALL + CAST ( - col0 AS INTEGER ) FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-3897
SELECT - col1 + col2 + + col2 DIV - 25 AS col1 FROM tab2 AS cor0
----
-34
-5
20

skipif mysql # not compatible
query I rowsort label-3897
SELECT - col1 + col2 + + col2 / - 25 AS col1 FROM tab2 AS cor0
----
-34
-5
20

query I rowsort
SELECT DISTINCT + cor0.col0 + + col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT col1 * 50 + + col0 * cor0.col0 - - col2 AS col1 FROM tab0 AS cor0
----
12553
4909
6076

query I rowsort
SELECT - - ( + col2 ) + + col2 FROM tab2 AS cor0
----
52
54
76

query I rowsort
SELECT + 84 * + cor0.col0 + - ( col2 + cor0.col2 ) FROM tab1 AS cor0
----
144
5262
6528

onlyif mysql # use DIV operator for integer division
query I rowsort label-3902
SELECT ALL - tab1.col0 + - col2 + col0 DIV ( - col2 ) AS col0 FROM tab1
----
-122
-176
-57

skipif mysql # not compatible
query I rowsort label-3902
SELECT ALL - tab1.col0 + - col2 + col0 / ( - col2 ) AS col0 FROM tab1
----
-122
-176
-57

query I rowsort
SELECT DISTINCT + 77 + cor0.col0 FROM tab2, tab0 AS cor0
----
101
112
166

query I rowsort
SELECT + ( col0 ) * - col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT + 17 * col0 AS col0 FROM tab2 cor0
----
119
1326
1343

query I rowsort
SELECT - 67 + col0 AS col2 FROM tab0 AS cor0
----
-32
-43
22

query I rowsort
SELECT + + col1 + + col1 AS col2 FROM tab2 AS cor0
----
118
34
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 34 col2 FROM tab0
----
34
34
34

query I rowsort
SELECT ALL 3 FROM tab0, tab1 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT col1 * - col2 + + cor0.col0 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT + 6 + tab2.col2 FROM tab2
----
32
33
44

query I rowsort
SELECT ALL col2 + - col2 * - col0 AS col1 FROM tab0
----
36
7380
825

query I rowsort
SELECT ALL - tab2.col1 + - 99 AS col1 FROM tab2
----
-116
-130
-158

query I rowsort
SELECT + col2 + + 42 * - col0 FROM tab2 AS cor0
----
-267
-3250
-3280

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab2, tab2 cor2
----
3645 values hashing to 5a114c3d024b82b28eeddb04849c8215

query I rowsort
SELECT DISTINCT col2 * - tab1.col2 * + tab1.col0 AS col0 FROM tab1
----
-207936
-737280
-8748

query I rowsort
SELECT ALL + - col1 * - col2 AS col1 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT - 21 * col1 FROM tab0
----
-1806
-1911
-2037

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3919
SELECT DISTINCT + CAST( 49 AS SIGNED ) * + col1 AS col1 FROM tab1
----
1274
490
637

skipif mysql # not compatible
query I rowsort label-3919
SELECT DISTINCT + CAST ( 49 AS INTEGER ) * + col1 AS col1 FROM tab1
----
1274
490
637

query I rowsort
SELECT - 21 * + col0 FROM tab2
----
-147
-1638
-1659

query I rowsort
SELECT 0 * 98 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT ( - col0 ) - col0 FROM tab1 AS cor0
----
-128
-160
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col0 * - cor0.col2 - col1 col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT DISTINCT 24 FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab2 AS cor2
----
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3925
SELECT DISTINCT - - CAST( NULL AS DECIMAL ) * - col0 AS col2 FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3925
SELECT DISTINCT - - CAST ( NULL AS REAL ) * - col0 AS col2 FROM tab1 cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 9 col2 FROM tab1 AS cor0
----
9

query I rowsort
SELECT - col2 + - col0 * col2 * - ( col1 ) FROM tab1
----
36423
4158
99744

query I rowsort
SELECT DISTINCT col1 - - col2 AS col2 FROM tab2
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3929
SELECT DISTINCT CAST( NULL AS SIGNED ) - 48 AS col0 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-3929
SELECT DISTINCT CAST ( NULL AS INTEGER ) - 48 AS col0 FROM tab0
----
NULL

query I rowsort
SELECT - 20 - + col2 AS col1 FROM tab2
----
-46
-47
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-3931
SELECT + col1 * 52 + col2 DIV - col0 FROM tab2
----
1609
3068
884

skipif mysql # not compatible
query I rowsort label-3931
SELECT + col1 * 52 + col2 / - col0 FROM tab2
----
1609
3068
884

query I rowsort
SELECT col2 - + 3 AS col0 FROM tab1
----
51
54
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 51 + + col1 * col1 + - col0 * 80 col2 FROM tab1 AS cor0
----
-4969
-6180
487

query I rowsort
SELECT - col1 * - col2 + cor0.col2 AS col1 FROM tab1 cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT + 78 + + col2 FROM tab0 AS cor0
----
111
160
79

query I rowsort
SELECT + 12 + - col0 AS col2 FROM tab0 AS cor0
----
-12
-23
-77

query I rowsort
SELECT - col2 * - 66 * - cor0.col1 FROM tab0 AS cor0
----
-187308
-492492
-6402

query I rowsort
SELECT - ( cor0.col1 ) AS col0 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT ALL + col0 + - col1 + + col0 AS col0 FROM tab0
----
-27
-38
87

onlyif mysql # use DIV operator for integer division
query I rowsort label-3940
SELECT + - 64 + - cor0.col2 DIV col2 AS col0 FROM tab0 AS cor0
----
-65
-65
-65

skipif mysql # not compatible
query I rowsort label-3940
SELECT + - 64 + - cor0.col2 / col2 AS col0 FROM tab0 AS cor0
----
-65
-65
-65

query I rowsort
SELECT + - cor0.col2 + col2 * col2 FROM tab1 cor0
----
2862
3192
9120

query I rowsort
SELECT col0 * + 73 AS col1 FROM tab1 AS cor0
----
219
4672
5840

query I rowsort
SELECT col1 * + col2 + col2 * col0 AS col2 FROM tab1 AS cor0
----
1566
4218
8928

onlyif mysql # use DIV operator for integer division
query I rowsort label-3944
SELECT DISTINCT - 50 DIV col2 AS col2 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-3944
SELECT DISTINCT - 50 / col2 AS col2 FROM tab1
----
0

query I rowsort
SELECT - cor0.col1 + - col0 AS col2 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT ALL + + col0 * - 75 FROM tab1 cor0
----
-225
-4800
-6000

query I rowsort
SELECT - - col0 * - 66 AS col2 FROM tab0 AS cor0
----
-1584
-2310
-5874

query I rowsort
SELECT ALL col1 * + 55 * cor0.col0 AS col2 FROM tab0 cor0
----
113520
186725
445445

query I rowsort
SELECT DISTINCT col2 + + 46 * - col0 AS col1 FROM tab1 AS cor0
----
-2887
-3584
-84

query I rowsort
SELECT + 90 * 84 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to dbb8982273d006c7d26b616f3066e3c1

query I rowsort
SELECT - col0 * - tab2.col2 AS col1 FROM tab2
----
189
2028
3002

query I rowsort
SELECT + + cor0.col1 + - 76 AS col2 FROM tab0 AS cor0
----
10
15
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-3953
SELECT DISTINCT col2 + col0 DIV - col1 FROM tab2 AS cor0
----
25
27
34

skipif mysql # not compatible
query I rowsort label-3953
SELECT DISTINCT col2 + col0 / - col1 FROM tab2 AS cor0
----
25
27
34

query I rowsort
SELECT DISTINCT + + col2 * + 80 AS col2 FROM tab0 AS cor0
----
2640
6560
80

query I rowsort
SELECT col1 * + 15 AS col0 FROM tab0 AS cor0
----
1290
1365
1455

query I rowsort
SELECT DISTINCT + col1 + col0 * col0 AS col2 FROM tab0 AS cor0
----
1322
662
8012

query I rowsort
SELECT ALL + - ( + col0 ) FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT ALL + ( + 19 ) * cor0.col2 AS col0 FROM tab2 cor0
----
494
513
722

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 48 col2 FROM tab0 AS cor0
----
-48
-48
-48

query I rowsort
SELECT + 81 * - col1 + + col2 * - ( + 40 * col0 + - 3 ) AS col1 FROM tab1 AS cor0
----
-146559
-307965
-8424

query I rowsort
SELECT + 30 * col1 FROM tab1 AS cor0
----
300
390
780

query I rowsort
SELECT DISTINCT - col1 * - col1 * col2 FROM tab0 AS cor0
----
244068
679042
9409

query I rowsort
SELECT ALL - col1 + 34 AS col2 FROM tab1 AS cor0
----
21
24
8

query I rowsort
SELECT 1 + col1 AS col2 FROM tab1 AS cor0
----
11
14
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-3965
SELECT col0 + + col2 DIV + col1 AS col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-3965
SELECT col0 + + col2 / + col1 AS col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT ALL + ( col2 ) * + col2 + col2 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL + - 3 * - col1 AS col2 FROM tab0 AS cor0
----
258
273
291

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3968
SELECT DISTINCT + col0 * + col0 + 22 * - col1 * + col0 + CAST( NULL AS DECIMAL ) * col0 * - col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3968
SELECT DISTINCT + col0 * + col0 + 22 * - col1 * + col0 + CAST ( NULL AS REAL ) * col0 * - col0 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-3969
SELECT ALL 69 DIV col0 + - col1 FROM tab2 AS cor0
----
-17
-22
-59

skipif mysql # not compatible
query I rowsort label-3969
SELECT ALL 69 / col0 + - col1 FROM tab2 AS cor0
----
-17
-22
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 18 col0 FROM tab2 cor0
----
18

query I rowsort
SELECT DISTINCT + col1 + cor0.col2 AS col0 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT ALL + col1 * cor0.col0 + - col2 AS col1 FROM tab1 cor0
----
24
583
944

query I rowsort
SELECT DISTINCT + col2 - col2 * - 25 * - col0 FROM tab1 AS cor0
----
-191904
-3996
-91143

query I rowsort
SELECT ALL + col0 * col2 + ( + cor0.col2 ) * col0 * + col2 AS col0 FROM tab2 AS cor0
----
117078
5292
54756

query I rowsort
SELECT col2 * + 1 AS col0 FROM tab2
----
26
27
38

query I rowsort
SELECT ALL + - ( + col2 ) * - col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT - + col1 - col0 FROM tab0 cor0
----
-110
-132
-180

onlyif mysql # use DIV operator for integer division
query I rowsort label-3978
SELECT DISTINCT - col2 + col0 * + col0 + 45 DIV col0 FROM tab2 AS cor0
----
28
6058
6203

skipif mysql # not compatible
query I rowsort label-3978
SELECT DISTINCT - col2 + col0 * + col0 + 45 / col0 FROM tab2 AS cor0
----
28
6058
6203

query I rowsort
SELECT ALL 87 AS col1 FROM tab2 AS cor0
----
87
87
87

query I rowsort
SELECT ALL + ( tab2.col1 + + col0 ) AS col1 FROM tab2
----
137
38
96

query I rowsort
SELECT + tab1.col0 * - 23 FROM tab1, tab0 AS cor0
----
9 values hashing to e9624cdc45488e38bd1d49c31ef0f48b

query I rowsort
SELECT + tab0.col2 * - col1 AS col1 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT - ( - col2 ) + 55 * cor0.col0 FROM tab2 AS cor0
----
412
4316
4383

query I rowsort
SELECT 50 + col2 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
2078
239
3052

query I rowsort
SELECT ALL tab0.col0 + - tab0.col2 AS col0 FROM tab0
----
-9
34
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + col2 * + 83 col2 FROM tab1 AS cor0
----
4536
4788
8064

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3987
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + 92 FROM tab1, tab2, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-3987
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + 92 FROM tab1, tab2, tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL - tab0.col1 + col1 * tab0.col1 AS col2 FROM tab0
----
7310
8190
9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 80 * 71 col1 FROM tab1
----
-5680
-5680
-5680

query I rowsort
SELECT DISTINCT - - ( col1 ) + col0 AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT + - ( col2 ) AS col0 FROM tab2 cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + col0 AS REAL ) * col2 FROM tab1
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3993
SELECT + + ( col2 ) + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-3993
SELECT + + ( col2 ) + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col1 * col2 + col0 AS col0 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT DISTINCT - col0 * + cor0.col1 + col2 * col2 - col2 AS col2 FROM tab2 cor0
----
-3952
485
63

query I rowsort
SELECT DISTINCT + col1 + + cor0.col1 AS col1 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT 79 + cor0.col2 FROM tab1 AS cor0
----
133
136
175

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-3998
SELECT - col2 * - col0 + - CAST( - ( col2 ) * col0 AS SIGNED ) + col1 AS col2 FROM tab2 AS cor0
----
409
4115
6021

skipif mysql # not compatible
query I rowsort label-3998
SELECT - col2 * - col0 + - CAST ( - ( col2 ) * col0 AS INTEGER ) + col1 AS col2 FROM tab2 AS cor0
----
409
4115
6021

query I rowsort
SELECT DISTINCT + cor0.col2 * - col1 + ( - col2 ) * - col0 FROM tab2 AS cor0
----
-648
2356
494

onlyif mysql # use DIV operator for integer division
query I rowsort label-4000
SELECT DISTINCT - col0 - cor0.col1 DIV + col0 col2 FROM tab2 cor0
----
-11
-78
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4000
SELECT DISTINCT - col0 - cor0.col1 / + col0 col2 FROM tab2 cor0
----
-11
-78
-79

query I rowsort
SELECT + 21 * cor0.col0 FROM tab2 AS cor0
----
147
1638
1659

onlyif mysql # use DIV operator for integer division
query I rowsort label-4002
SELECT col0 DIV col1 + cor0.col2 + cor0.col2 FROM tab1 AS cor0
----
108
120
198

skipif mysql # not compatible
query I rowsort label-4002
SELECT col0 / col1 + cor0.col2 + cor0.col2 FROM tab1 AS cor0
----
108
120
198

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4003
SELECT col1 - - CAST( + col1 * - col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

skipif mysql # not compatible
query I rowsort label-4003
SELECT col1 - - CAST ( + col1 * - col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
-1235
-1378
-560

onlyif mysql # use DIV operator for integer division
query I rowsort label-4004
SELECT DISTINCT col2 * col2 DIV + col0 AS col1 FROM tab0 AS cor0
----
0
45
75

skipif mysql # not compatible
query I rowsort label-4004
SELECT DISTINCT col2 * col2 / + col0 AS col1 FROM tab0 AS cor0
----
0
45
75

query I rowsort
SELECT DISTINCT - col2 * + col1 + + col0 + + col1 AS col2 FROM tab2
----
-1397
-550
-799

query I rowsort
SELECT - cor0.col0 AS col0 FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to adaea38eae032c1639715f21831dd376

query I rowsort
SELECT 21 AS col0 FROM tab0, tab0 AS cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

query I rowsort
SELECT ALL + col0 + ( col2 ) AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT ALL col2 + - col1 AS col1 FROM tab1 cor0
----
28
47
83

query I rowsort
SELECT col2 * + 81 FROM tab2 AS cor0
----
2106
2187
3078

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4011
SELECT DISTINCT cor0.col1 + 35 * ( + col0 ) * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4011
SELECT DISTINCT cor0.col1 + 35 * ( + col0 ) * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT col2 * col1 + - ( col0 ) * 13 + col1 AS col1 FROM tab0 AS cor0
----
-261
2612
6396

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4013
SELECT + col1 + + CAST( + col2 AS SIGNED ) + + col1 FROM tab0 AS cor0
----
195
205
264

skipif mysql # not compatible
query I rowsort label-4013
SELECT + col1 + + CAST ( + col2 AS INTEGER ) + + col1 FROM tab0 AS cor0
----
195
205
264

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4014
SELECT DISTINCT + col2 * + CAST( col2 AS SIGNED ) FROM tab1 cor0
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort label-4014
SELECT DISTINCT + col2 * + CAST ( col2 AS INTEGER ) FROM tab1 cor0
----
2916
3249
9216

onlyif mysql # use DIV operator for integer division
query I rowsort label-4015
SELECT DISTINCT - col0 * - ( ( - col0 ) ) DIV col0 AS col2 FROM tab2 AS cor0
----
-7
-78
-79

skipif mysql # not compatible
query I rowsort label-4015
SELECT DISTINCT - col0 * - ( ( - col0 ) ) / col0 AS col2 FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4016
SELECT DISTINCT + CAST( col2 AS SIGNED ) + col2 * + 33 FROM tab1 AS cor0
----
1836
1938
3264

skipif mysql # not compatible
query I rowsort label-4016
SELECT DISTINCT + CAST ( col2 AS INTEGER ) + col2 * + 33 FROM tab1 AS cor0
----
1836
1938
3264

query I rowsort
SELECT ALL - ( 68 ) * cor0.col0 + cor0.col2 FROM tab1 AS cor0
----
-150
-4295
-5344

query I rowsort
SELECT - ( + col0 ) * + col1 AS col2 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT col2 + + 9 + + col0 * col1 * - col1 FROM tab1
----
-13415
-1965
-6334

query I rowsort
SELECT ALL + - 61 AS col1 FROM tab2 AS cor0 CROSS JOIN tab2 cor1
----
9 values hashing to 51f53697966a79d306a4570537cd91a1

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab2 AS cor0 CROSS JOIN tab0, tab0 AS cor1, tab1 cor2, tab2 AS cor3
----
3645 values hashing to 81a27955147133c47c9e8e63dacc5c37

query I rowsort
SELECT col1 * 10 + + col2 AS col1 FROM tab0
----
893
971
992

query I rowsort
SELECT col2 * 10 + + cor0.col1 * col2 AS col1 FROM tab0 cor0
----
107
3168
8282

onlyif mysql # use DIV operator for integer division
query I rowsort label-4024
SELECT ALL col0 DIV col1 + + col1 FROM tab1
----
16
19
26

skipif mysql # not compatible
query I rowsort label-4024
SELECT ALL col0 / col1 + + col1 FROM tab1
----
16
19
26

query I rowsort
SELECT - ( col2 ) * col2 + + 31 - 76 AS col1 FROM tab2 AS cor0
----
-1489
-721
-774

onlyif mysql # use DIV operator for integer division
query I rowsort label-4026
SELECT - + col0 - col1 * - col1 DIV - col1 FROM tab0 AS cor0
----
-110
-132
-180

skipif mysql # not compatible
query I rowsort label-4026
SELECT - + col0 - col1 * - col1 / - col1 FROM tab0 AS cor0
----
-110
-132
-180

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 3 col0 FROM tab1, tab1 AS cor0, tab0, tab2 AS cor1
----
3

query I rowsort
SELECT 13 + col2 AS col0 FROM tab2 AS cor0
----
39
40
51

query I rowsort
SELECT col2 + + col0 + + col0 FROM tab2 AS cor0
----
182
196
41

query I rowsort
SELECT 43 + - col2 + - col0 AS col2 FROM tab2 AS cor0
----
-61
-74
9

query I rowsort
SELECT + col2 * - col1 + col1 * 11 * - 19 AS col0 FROM tab0 cor0
----
-20370
-20812
-26481

query I rowsort
SELECT - col0 + + 59 FROM tab2 AS cor0
----
-19
-20
52

query I rowsort
SELECT - + col0 * - col1 * + 72 + col2 AS col1 FROM tab0 AS cor0
----
148641
244441
583210

query I rowsort
SELECT - 35 * cor0.col0 AS col1 FROM tab2 AS cor0
----
-245
-2730
-2765

query I rowsort
SELECT DISTINCT tab1.col1 * cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 23253cfee4cea5e1d4f993bec937f9fe

query I rowsort
SELECT + col0 * 13 AS col0 FROM tab2 AS cor0
----
1014
1027
91

query I rowsort
SELECT DISTINCT + cor1.col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
3
64
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4038
SELECT + CAST( NULL AS SIGNED ) / - cor0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-4038
SELECT + CAST ( NULL AS INTEGER ) / - cor0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + cor1.col0 AS col2 FROM tab0, tab0 cor0, tab2 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL - - col1 + col2 AS col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT ALL + + col0 * + col1 + - col2 * col1 FROM tab1 AS cor0
----
-1326
-208
70

query I rowsort
SELECT ALL + - col0 * + col1 + + 21 AS col2 FROM tab1 AS cor0
----
-1019
-57
-619

query I rowsort
SELECT ALL - - col2 + col1 * col1 FROM tab1 AS cor0
----
157
265
730

query I rowsort
SELECT + - 60 + col2 * 79 FROM tab0 AS cor0
----
19
2547
6418

query I rowsort
SELECT DISTINCT - col2 + col1 + col1 FROM tab0 cor0
----
100
139
193

onlyif mysql # use DIV operator for integer division
query I rowsort label-4046
SELECT DISTINCT + col0 DIV col2 - cor0.col1 AS col1 FROM tab0 AS cor0
----
-62
-86
-90

skipif mysql # not compatible
query I rowsort label-4046
SELECT DISTINCT + col0 / col2 - cor0.col1 AS col1 FROM tab0 AS cor0
----
-62
-86
-90

query I rowsort
SELECT + 75 AS col1 FROM tab1 cor0
----
75
75
75

query I rowsort
SELECT DISTINCT - 65 + col1 FROM tab0 AS cor0
----
21
26
32

query I rowsort
SELECT - col2 + + col0 AS col1 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT ALL - + col1 * - col1 * + 51 AS col0 FROM tab0 AS cor0
----
377196
422331
479859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( 89 ) col2 FROM tab0
----
89
89
89

query I rowsort
SELECT col0 * 28 AS col0 FROM tab1
----
1792
2240
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - col2 + - col2 col0 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT DISTINCT cor0.col2 + col1 AS col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT 42 * col1 + - col0 AS col0 FROM tab1 AS cor0
----
1089
356
466

query I rowsort
SELECT ALL - col1 * - cor0.col1 AS col2 FROM tab1 AS cor0
----
100
169
676

skipif mysql # not compatible
query I rowsort
SELECT ALL + - col1 * ( col1 ) + col0 * + CAST ( - 38 + cor0.col0 AS REAL ) FROM tab2 AS cor0
----
-1178
-361
2950

query I rowsort
SELECT cor0.col0 AS col2 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT + col2 * - col0 + + tab1.col0 * col2 * - col1 FROM tab1
----
-107520
-40128
-4374

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 7 col1 FROM tab0
----
-7
-7
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 + col0 col2 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT - col2 * + 87 FROM tab0
----
-2871
-7134
-87

query I rowsort
SELECT 88 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4064
SELECT + CAST( col2 AS SIGNED ) - col2 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4064
SELECT + CAST ( col2 AS INTEGER ) - col2 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - col0 * tab1.col0 + tab1.col2 + - 38 FROM tab1
----
-4077
-6342
7

query I rowsort
SELECT 40 * ( col1 ) FROM tab0
----
3440
3640
3880

query I rowsort
SELECT 90 * + col0 FROM tab0
----
2160
3150
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-4068
SELECT DISTINCT 48 DIV - col1 + col0 AS col1 FROM tab2
----
6
77
78

skipif mysql # not compatible
query I rowsort label-4068
SELECT DISTINCT 48 / - col1 + col0 AS col1 FROM tab2
----
6
77
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4069
SELECT DISTINCT + CAST( NULL AS SIGNED ) * col0 + col2 * + cor0.col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4069
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * col0 + col2 * + cor0.col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT 82 + col2 AS col2 FROM tab1 AS cor0
----
136
139
178

query I rowsort
SELECT col0 + col1 + + col2 AS col0 FROM tab1
----
131
189
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab1.col2 * col1 - + col2 col2 FROM tab1
----
-1344
-1458
-627

query I rowsort
SELECT + col1 + 4 * col0 + - ( - 20 * col2 ) AS col0 FROM tab2
----
1093
599
891

query I rowsort
SELECT 88 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to c46e7cf9bf516fdfde88534336a28177

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4075
SELECT - CAST( NULL AS DECIMAL ) / 92 + col1 * 7 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-4075
SELECT - CAST ( NULL AS REAL ) / 92 + col1 * 7 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - tab1.col2 * 93 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 4d2fa05e31c762d2c3608a2933318b69

query I rowsort
SELECT + - 21 + col0 * col0 + col0 AS col2 FROM tab1 AS cor0
----
-9
4139
6459

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4078
SELECT ALL - CAST( NULL AS DECIMAL ) * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4078
SELECT ALL - CAST ( NULL AS REAL ) * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor0.col2 + col2 * col1 * 93 FROM tab2 AS cor0
----
142636
60040
77814

query I rowsort
SELECT ALL + tab0.col0 + 35 FROM tab0
----
124
59
70

query I rowsort
SELECT ( + col0 ) * - col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT 11 * 19 FROM tab0, tab0 AS cor0, tab1 cor1
----
27 values hashing to 12262843169b311222981b16b41d9fa1

query I rowsort
SELECT ALL - tab2.col0 * 73 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to fe83635e968632deb7df297f6122f8f9

query I rowsort
SELECT ALL + col1 * cor0.col2 + 0 * - col1 + col1 FROM tab2 AS cor0
----
1593
663
868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 4 + cor0.col2 * 39 col1 FROM tab2 AS cor0
----
1018
1057
1486

query I rowsort
SELECT DISTINCT col1 + - col0 * - cor0.col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT DISTINCT - - 84 * - cor0.col2 AS col2 FROM tab0 AS cor0
----
-2772
-6888
-84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 18 * col2 col0 FROM tab0 AS cor0
----
1476
18
594

query I rowsort
SELECT 78 - cor1.col2 AS col0 FROM tab0, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 8d0fb6e2b1c3251f664c32ea28f8cc33

query I rowsort
SELECT DISTINCT 20 AS col0 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
20

query I rowsort
SELECT DISTINCT - col1 * - ( ( - tab2.col2 ) ) FROM tab2
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4092
SELECT - tab1.col2 * - CAST( NULL AS SIGNED ) + col0 * col0 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4092
SELECT - tab1.col2 * - CAST ( NULL AS INTEGER ) + col0 * col0 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT - 29 FROM tab0, tab2 cor0, tab1 AS cor1
----
27 values hashing to 56a8aa9e4c5d3c934d1853afeb22653e

query I rowsort
SELECT ALL + 27 AS col0 FROM tab1, tab1 AS cor0, tab2 cor1
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

onlyif mysql # use DIV operator for integer division
query I rowsort label-4095
SELECT + - 0 DIV - 33 FROM tab2 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4095
SELECT + - 0 / - 33 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + + col2 + + col0 * col0 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT ( - col0 ) * col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT - col2 + 48 * col1 * - 71 AS col2 FROM tab2 AS cor0
----
-105675
-201098
-57974

query I rowsort
SELECT - - 6 - + col0 * + col0 FROM tab2 AS cor0
----
-43
-6078
-6235

query I rowsort
SELECT ALL + - col2 * + col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT col2 * + ( col0 ) + + ( col0 ) AS col0 FROM tab2 AS cor0
----
196
2106
3081

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4102
SELECT - CAST( col2 AS SIGNED ) * + cor0.col1 FROM tab1 AS cor0
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-4102
SELECT - CAST ( col2 AS INTEGER ) * + cor0.col1 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - ( - 63 ) * cor0.col1 FROM tab2 AS cor0
----
1071
1953
3717

query I rowsort
SELECT + col1 + + col2 * col2 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT + col2 + ( col0 ) FROM tab2
----
104
117
34

query I rowsort
SELECT 14 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

query I rowsort
SELECT - col0 * + 47 - - 30 FROM tab1
----
-111
-2978
-3730

query I rowsort
SELECT DISTINCT + 46 FROM tab1 cor0
----
46

query I rowsort
SELECT ALL + - 25 FROM tab0 AS cor0
----
-25
-25
-25

query I rowsort
SELECT - 0 * - 25 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col1 - col0 * col1 FROM tab2 AS cor0
----
-1326
-186
-4543

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + 84 AS REAL ) * - col0 FROM tab2 cor0
----
-588
-6552
-6636

query I rowsort
SELECT - - col1 + + cor0.col0 * - 56 FROM tab1 AS cor0
----
-142
-3574
-4467

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 0 col1 FROM tab0, tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4115
SELECT + - 51 DIV - cor0.col1 AS col1 FROM tab1 AS cor0
----
1
3
5

skipif mysql # not compatible
query I rowsort label-4115
SELECT + - 51 / - cor0.col1 AS col1 FROM tab1 AS cor0
----
1
3
5

query I rowsort
SELECT 40 * - 17 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to d0fc6ca2ef4f3b185faf3eb002f09083

query I rowsort
SELECT ALL + cor0.col0 + col0 * col1 + col2 FROM tab1 AS cor0
----
1216
135
761

onlyif mysql # use DIV operator for integer division
query I rowsort label-4118
SELECT DISTINCT + col2 DIV + 22 FROM tab1
----
2
4

skipif mysql # not compatible
query I rowsort label-4118
SELECT DISTINCT + col2 / + 22 FROM tab1
----
2
4

query I rowsort
SELECT DISTINCT 70 + - tab1.col2 AS col2 FROM tab1, tab0 AS cor0
----
-26
13
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 + - col0 col2 FROM tab2 cor0
----
-41
-52
20

query I rowsort
SELECT + tab2.col2 + + 70 AS col0 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to 677d2923d8c33a6a19352f8359ad2ffe

query I rowsort
SELECT - cor0.col0 * + col2 + col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT ALL - 39 * col1 FROM tab2 cor0
----
-1209
-2301
-663

query I rowsort
SELECT ALL 41 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT DISTINCT ( + col2 ) * + ( col1 ) + + col0 + 2 * - 84 AS col0 FROM tab2 AS cor0
----
1444
557
676

query I rowsort
SELECT ALL + - col1 * col2 + col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT + ( + col1 ) * + 11 + - ( col1 ) AS col1 FROM tab1 AS cor0
----
100
130
260

query I rowsort
SELECT DISTINCT + ( - col1 + col2 ) * tab0.col0 AS col1 FROM tab0
----
-1272
-3360
-801

query I rowsort
SELECT + 41 * - col0 * col0 FROM tab1 AS cor0
----
-167936
-262400
-369

query I rowsort
SELECT ALL 87 AS col0 FROM tab2
----
87
87
87

query I rowsort
SELECT col1 * ( col1 ) - + col2 * + cor0.col2 FROM tab2 cor0
----
-1155
232
2805

query I rowsort
SELECT ALL col0 - 6 FROM tab0
----
18
29
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-4133
SELECT DISTINCT - col2 * col0 DIV 61 + - col0 * col0 AS col0 FROM tab2 AS cor0
----
-52
-6117
-6290

skipif mysql # not compatible
query I rowsort label-4133
SELECT DISTINCT - col2 * col0 / 61 + - col0 * col0 AS col0 FROM tab2 AS cor0
----
-52
-6117
-6290

query I rowsort
SELECT ALL - - cor0.col1 - col2 FROM tab2 AS cor0
----
-21
33
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4135
SELECT ALL col1 * + ( + 38 * + col2 ) + + CAST( NULL AS SIGNED ) - - col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4135
SELECT ALL col1 * + ( + 38 * + col2 ) + + CAST ( NULL AS INTEGER ) - - col2 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - col1 * + cor0.col1 + + col2 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
167
278
756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 70 col0 FROM tab0
----
70
70
70

query I rowsort
SELECT col2 + ( ( col2 ) ) AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT - col1 - + 96 * - cor0.col1 AS col1 FROM tab1 AS cor0
----
1235
2470
950

query I rowsort
SELECT ALL col1 + + 59 FROM tab0 cor0
----
145
150
156

query I rowsort
SELECT DISTINCT - tab2.col0 * col1 + - col0 AS col0 FROM tab2
----
-1422
-224
-4680

query I rowsort
SELECT + - ( - col2 ) * - col2 + - col0 FROM tab2 AS cor0
----
-1523
-736
-754

query I rowsort
SELECT + 7 + - col1 FROM tab0 AS cor0
----
-79
-84
-90

query I rowsort
SELECT ALL + ( 2 + col0 ) FROM tab1
----
5
66
82

query I rowsort
SELECT - + 33 * + cor0.col0 + + col1 * cor0.col1 AS col2 FROM tab0 cor0
----
5344
6604
8254

onlyif mysql # use DIV operator for integer division
query I rowsort label-4146
SELECT 55 + col1 * col1 DIV cor0.col0 FROM tab1 AS cor0
----
280
56
57

skipif mysql # not compatible
query I rowsort label-4146
SELECT 55 + col1 * col1 / cor0.col0 FROM tab1 AS cor0
----
280
56
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-4147
SELECT - 69 DIV ( - col1 ) FROM tab2 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-4147
SELECT - 69 / ( - col1 ) FROM tab2 AS cor0
----
1
2
4

query I rowsort
SELECT - col0 + + 56 AS col1 FROM tab0 AS cor0
----
-33
21
32

query I rowsort
SELECT cor0.col0 + 35 FROM tab1 AS cor0
----
115
38
99

query I rowsort
SELECT 35 + - cor0.col0 FROM tab1 AS cor0
----
-29
-45
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-4151
SELECT + col0 DIV cor0.col0 AS col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4151
SELECT + col0 / cor0.col0 AS col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - cor0.col2 - col2 AS col1 FROM tab1 AS cor0
----
-108
-114
-192

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( col0 ) + ( 27 ) col1 FROM tab2 AS cor0
----
-51
-52
20

query I rowsort
SELECT ALL - 15 FROM tab0, tab0 cor0
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

query I rowsort
SELECT - col0 * 19 + col2 AS col1 FROM tab2 AS cor0
----
-106
-1456
-1463

query I rowsort
SELECT - cor0.col2 * cor0.col0 + 19 + + col1 FROM tab1 AS cor0
----
-117
-3619
-7648

query I rowsort
SELECT - - col1 + + cor0.col0 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT col2 * col1 + + col2 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT DISTINCT + col1 + - col0 * ( col1 ) + - col0 * col1 FROM tab0 AS cor0
----
-16107
-4042
-6693

query I rowsort
SELECT + cor0.col2 + + ( + col2 ) + col1 * - cor0.col0 AS col1 FROM tab1 AS cor0
----
-526
-848
30

query I rowsort
SELECT - + col1 * - col1 + + col0 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT ALL + col0 * 79 FROM tab2 cor0
----
553
6162
6241

query I rowsort
SELECT - col0 + - cor0.col2 * + col2 FROM tab2 AS cor0
----
-1523
-736
-754

query I rowsort
SELECT ALL - 49 * - 90 AS col0 FROM tab1 AS cor0
----
4410
4410
4410

query I rowsort
SELECT DISTINCT - - col2 * 24 AS col1 FROM tab0 AS cor0
----
1968
24
792

query I rowsort
SELECT col2 * 9 * 89 + col0 * + col2 - 33 FROM tab0
----
27192
72947
803

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4167
SELECT ALL + col0 + - CAST( NULL AS SIGNED ) + + col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4167
SELECT ALL + col0 + - CAST ( NULL AS INTEGER ) + + col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 68 FROM tab1 cor0
----
-68

query I rowsort
SELECT ALL - + 67 * + col2 + col2 FROM tab0 AS cor0
----
-2178
-5412
-66

query I rowsort
SELECT - 18 + - col2 FROM tab1 AS cor0
----
-114
-72
-75

query I rowsort
SELECT DISTINCT ( 47 ) FROM tab1, tab1 AS cor0, tab2 AS cor1
----
47

query I rowsort
SELECT ALL - + col0 + col2 * cor0.col2 AS col2 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT cor0.col1 - 32 FROM tab0 AS cor0
----
54
59
65

skipif mysql # not compatible
query I rowsort
SELECT col2 * - CAST ( - 23 AS REAL ) * + col2 + col1 FROM tab1 AS cor0
----
211981
67094
74737

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - col0 * col0 + col1 col1 FROM tab1
----
-4022
-6307
20

query I rowsort
SELECT + 47 + + col0 FROM tab0
----
136
71
82

query I rowsort
SELECT DISTINCT col0 - col1 * col2 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT DISTINCT + col0 - col1 * + 21 FROM tab2
----
-1161
-278
-644

query I rowsort
SELECT 99 + col0 - ( - col0 ) FROM tab0
----
147
169
277

query I rowsort
SELECT DISTINCT tab2.col2 - col2 * + 67 FROM tab2
----
-1716
-1782
-2508

query I rowsort
SELECT tab2.col1 * + col1 * 55 AS col2 FROM tab2
----
15895
191455
52855

onlyif mysql # use DIV operator for integer division
query I rowsort label-4182
SELECT DISTINCT + col0 DIV + ( col1 ) FROM tab2 AS cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-4182
SELECT DISTINCT + col0 / + ( col1 ) FROM tab2 AS cor0
----
0
1
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4183
SELECT - + col2 + + CAST( NULL AS SIGNED ) * - col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4183
SELECT - + col2 + + CAST ( NULL AS INTEGER ) * - col0 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4184
SELECT ALL col2 DIV col2 + ( + col0 ) DIV 77 + - tab0.col1 FROM tab0
----
-85
-89
-96

skipif mysql # not compatible
query I rowsort label-4184
SELECT ALL col2 / col2 + ( + col0 ) / 77 + - tab0.col1 FROM tab0
----
-85
-89
-96

query I rowsort
SELECT DISTINCT - col1 + 94 FROM tab1
----
68
81
84

query I rowsort
SELECT ALL + col0 + 77 FROM tab2
----
155
156
84

query I rowsort
SELECT ALL - col2 + + ( col2 * + col0 ) FROM tab0
----
34
7216
759

query I rowsort
SELECT + col2 * - 47 + col2 FROM tab0 AS cor0
----
-1518
-3772
-46

query I rowsort
SELECT col0 + - ( col1 ) AS col2 FROM tab0 AS cor0
----
-2
-62
-62

query I rowsort
SELECT ALL + col0 * 63 + col2 FROM tab2 AS cor0
----
468
4940
5015

query I rowsort
SELECT + col1 * - 26 - col1 * col0 * + ( + 93 * - col1 ) FROM tab1 AS cor0
----
1257022
187928
594940

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * 15 + + 94 col2 FROM tab2
----
349
559
979

onlyif mysql # use DIV operator for integer division
query I rowsort label-4193
SELECT + col2 * cor0.col2 - col0 DIV + cor0.col0 FROM tab2 AS cor0
----
1443
675
728

skipif mysql # not compatible
query I rowsort label-4193
SELECT + col2 * cor0.col2 - col0 / + cor0.col0 FROM tab2 AS cor0
----
1443
675
728

query I rowsort
SELECT ALL + 0 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT + + 5 * + cor0.col2 FROM tab0 AS cor0
----
165
410
5

query I rowsort
SELECT + ( cor0.col0 ) * col0 FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-4197
SELECT + ( 76 ) * + col2 DIV col2 FROM tab1 AS cor0
----
76
76
76

skipif mysql # not compatible
query I rowsort label-4197
SELECT + ( 76 ) * + col2 / col2 FROM tab1 AS cor0
----
76
76
76

query I rowsort
SELECT ALL + - 16 * 45 AS col2 FROM tab0 AS cor0
----
-720
-720
-720

query I rowsort
SELECT + 23 + - tab1.col1 FROM tab0, tab2, tab1 AS cor0, tab1
----
81 values hashing to fbefa87c878e3c86b1ab4b1dd8ed35e5

query I rowsort
SELECT tab1.col2 * + 5 + - col2 FROM tab1
----
216
228
384

query I rowsort
SELECT DISTINCT - cor0.col1 * col0 + col0 AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

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 - col0 * col1 * - col0 AS col1 FROM tab2 AS cor0
----
106097
1519
358956

query I rowsort
SELECT ALL + + col1 * - col2 * + col1 + - 80 * col2 AS col0 FROM tab1 AS cor0
----
-10260
-23904
-40824

query I rowsort
SELECT DISTINCT - cor0.col1 * col0 - - col0 AS col2 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL + col0 - - col0 AS col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT + + ( - col1 ) * col0 * col1 AS col0 FROM tab2 cor0
----
-22831
-271518
-6727

query I rowsort
SELECT ALL - 48 - cor0.col1 AS col0 FROM tab2 AS cor0
----
-107
-65
-79

query I rowsort
SELECT - col0 + - col2 * col1 FROM tab0 AS cor0
----
-132
-2862
-7551

query I rowsort
SELECT DISTINCT + - 78 AS col0 FROM tab1 cor0
----
-78

query I rowsort
SELECT ALL + + col1 * + col0 + col1 + col1 FROM tab1 AS cor0
----
1066
130
660

query I rowsort
SELECT ALL + 43 * col0 + + col0 FROM tab0 AS cor0
----
1056
1540
3916

query I rowsort
SELECT DISTINCT col0 - + col1 * - col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT - - 8 AS col1 FROM tab2 AS cor0
----
8
8
8

query I rowsort
SELECT DISTINCT + col2 * col0 + + col0 * - 67 AS col1 FROM tab2 AS cor0
----
-2291
-280
-3198

query I rowsort
SELECT DISTINCT - cor1.col1 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
-17
-31
-59

query I rowsort
SELECT 40 + col0 * - col0 FROM tab0 cor0
----
-1185
-536
-7881

query I rowsort
SELECT + + col2 + 61 FROM tab1 AS cor0
----
115
118
157

query I rowsort
SELECT + 28 FROM tab2, tab2 AS cor0
----
9 values hashing to aad32232c428b3ecb5ada63f7e9b0a97

query I rowsort
SELECT - ( - col2 ) + col2 * - col0 * + col0 AS col1 FROM tab0 cor0
----
-1224
-18975
-649440

onlyif mysql # use DIV operator for integer division
query I rowsort label-4221
SELECT cor0.col0 DIV col2 col2 FROM tab1 AS cor0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4221
SELECT cor0.col0 / col2 col2 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT - 73 * col1 * + ( 65 + - col0 * ( cor0.col0 ) ) FROM tab1 AS cor0
----
-106288
2942630
6011915

query I rowsort
SELECT + 82 + col1 AS col2 FROM tab1 AS cor0
----
108
92
95

query I rowsort
SELECT - 93 + col0 * col2 FROM tab1
----
3555
69
7587

query I rowsort
SELECT - 97 + col1 + cor0.col1 FROM tab2 AS cor0
----
-35
-63
21

query I rowsort
SELECT + 98 * col0 + - ( + col0 ) * col2 + + 56 FROM tab1 AS cor0
----
188
216
2680

query I rowsort
SELECT + - 86 + - col2 * + col2 + col2 * col0 FROM tab2 AS cor0
----
-626
1266
1472

query I rowsort
SELECT ALL 42 * + tab1.col1 AS col2 FROM tab1
----
1092
420
546

onlyif mysql # use DIV operator for integer division
query I rowsort label-4229
SELECT + 11 DIV + cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 83c163442931d28e4160369d40047ea7

skipif mysql # not compatible
query I rowsort label-4229
SELECT + 11 / + cor0.col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 83c163442931d28e4160369d40047ea7

query I rowsort
SELECT DISTINCT 52 + col1 AS col2 FROM tab0
----
138
143
149

query I rowsort
SELECT DISTINCT ( - col0 ) * col2 + + col1 * 5 AS col2 FROM tab2
----
-1733
-2917
-34

query I rowsort
SELECT ALL + 29 * + col1 + tab0.col1 FROM tab0
----
2580
2730
2910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4233
SELECT CAST( NULL AS DECIMAL ) * 45 + col1 + col0 * col2 col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4233
SELECT CAST ( NULL AS REAL ) * 45 + col1 + col0 * col2 col0 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4234
SELECT ALL - ( - col1 ) + col2 DIV col0 + + 81 FROM tab0
----
168
172
178

skipif mysql # not compatible
query I rowsort label-4234
SELECT ALL - ( - col1 ) + col2 / col0 + + 81 FROM tab0
----
168
172
178

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 91 + col0 col0 FROM tab2
----
-12
-13
-84

query I rowsort
SELECT ALL col0 + + col2 + - col1 FROM tab1
----
111
163
31

query I rowsort
SELECT ALL + cor0.col2 + + 17 FROM tab0 AS cor0
----
18
50
99

query I rowsort
SELECT DISTINCT + - col2 + ( - col1 ) AS col2 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT - col0 * + col2 AS col1 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT + col1 + - cor0.col1 AS col0 FROM tab2 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4241
SELECT col1 DIV col2 + ( tab0.col0 ) AS col1 FROM tab0
----
132
26
90

skipif mysql # not compatible
query I rowsort label-4241
SELECT col1 / col2 + ( tab0.col0 ) AS col1 FROM tab0
----
132
26
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 58 col1 FROM tab2
----
58
58
58

query I rowsort
SELECT ALL col1 + col1 * tab0.col1 * col1 AS col1 FROM tab0
----
636142
753662
912770

query I rowsort
SELECT DISTINCT - + col2 + - 34 * 68 AS col1 FROM tab0 cor0
----
-2313
-2345
-2394

query I rowsort
SELECT ALL - col0 * + col2 + - col2 * - cor0.col0 - - col1 AS col0 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4246
SELECT DISTINCT - + col0 + CAST( NULL AS SIGNED ) + ( + col1 * col2 ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4246
SELECT DISTINCT - + col0 + CAST ( NULL AS INTEGER ) + ( + col1 * col2 ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT 81 AS col2 FROM tab1, tab2 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

query I rowsort
SELECT DISTINCT + tab0.col2 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
1
33
82

query I rowsort
SELECT ALL 97 AS col2 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

query I rowsort
SELECT ALL 86 * - 47 FROM tab0, tab2 AS cor0
----
9 values hashing to 9271bd76c83018e2ffed1e7093a8656e

query I rowsort
SELECT + 98 FROM tab0, tab2 AS cor0
----
9 values hashing to f9dee8c21116f1aed64ac5160e190809

query I rowsort
SELECT - + col2 + - 48 FROM tab2 cor0
----
-74
-75
-86

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4254
SELECT ALL + CAST( + col2 AS SIGNED ) + col1 FROM tab0 AS cor0
----
119
173
98

skipif mysql # not compatible
query I rowsort label-4254
SELECT ALL + CAST ( + col2 AS INTEGER ) + col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT DISTINCT - - 10 AS col0 FROM tab0 cor0
----
10

query I rowsort
SELECT ALL - tab1.col1 * - col2 * col0 AS col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT + col1 * col2 * col1 AS col2 FROM tab2
----
10982
25947
90506

query I rowsort
SELECT col0 + + 48 AS col0 FROM tab2 AS cor0
----
126
127
55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4259
SELECT ALL - col1 * - col0 / - CAST( NULL AS SIGNED ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4259
SELECT ALL - col1 * - col0 / - CAST ( NULL AS INTEGER ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - tab1.col1 * - col2 FROM tab1
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-4261
SELECT tab2.col2 DIV - tab2.col0 FROM tab2
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-4261
SELECT tab2.col2 / - tab2.col0 FROM tab2
----
-3
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4262
SELECT - cor0.col0 - - col0 DIV + ( - 31 ) AS col1 FROM tab1 AS cor0
----
-3
-66
-82

skipif mysql # not compatible
query I rowsort label-4262
SELECT - cor0.col0 - - col0 / + ( - 31 ) AS col1 FROM tab1 AS cor0
----
-3
-66
-82

query I rowsort
SELECT - - cor0.col1 * col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT - ( + col1 ) - - col1 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col2 + + cor0.col0 AS col0 FROM tab1 cor0
----
121
176
57

query I rowsort
SELECT - + 55 * + col1 + ( 27 ) AS col0 FROM tab2 cor0
----
-1678
-3218
-908

query I rowsort
SELECT + + col0 + - 21 FROM tab1 AS cor0
----
-18
43
59

query I rowsort
SELECT - + 14 FROM tab2, tab0 AS cor0
----
9 values hashing to d321461994ba49c3a70fa6373032fc94

query I rowsort
SELECT - 9 + - col1 AS col0 FROM tab2
----
-26
-40
-68

query I rowsort
SELECT DISTINCT + 68 * - col2 AS col2 FROM tab0
----
-2244
-5576
-68

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4271
SELECT - - CAST( 92 AS SIGNED ) FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

skipif mysql # not compatible
query I rowsort label-4271
SELECT - - CAST ( 92 AS INTEGER ) FROM tab0 AS cor0 CROSS JOIN tab1 cor1
----
9 values hashing to 516fa45c8b06f9f67d6e500bfd435c1a

query I rowsort
SELECT ( + col2 ) - + col2 * 25 AS col0 FROM tab0
----
-1968
-24
-792

query I rowsort
SELECT ALL - col1 * - col0 - 44 FROM tab0
----
2020
3351
8055

onlyif mysql # use DIV operator for integer division
query I rowsort label-4274
SELECT DISTINCT + col2 * col1 DIV 7 - - col2 * col2 FROM tab2
----
1536
848
895

skipif mysql # not compatible
query I rowsort label-4274
SELECT DISTINCT + col2 * col1 / 7 - - col2 * col2 FROM tab2
----
1536
848
895

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - 24 col2 FROM tab2 AS cor0
----
14
2
3

query I rowsort
SELECT DISTINCT + - cor0.col2 * 0 + + cor0.col0 - + col2 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4277
SELECT - col1 * CAST( cor0.col1 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

skipif mysql # not compatible
query I rowsort label-4277
SELECT - col1 * CAST ( cor0.col1 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-7396
-8281
-9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-4278
SELECT ALL col2 DIV - col1 + col0 AS col2 FROM tab2 AS cor0
----
7
77
78

skipif mysql # not compatible
query I rowsort label-4278
SELECT ALL col2 / - col1 + col0 AS col2 FROM tab2 AS cor0
----
7
77
78

query I rowsort
SELECT tab0.col1 FROM tab0, tab2, tab2 cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT 83 AS col2 FROM tab1
----
83

query I rowsort
SELECT ALL + col1 * col1 * ( col0 ) AS col0 FROM tab1
----
13520
2028
6400

query I rowsort
SELECT + col2 + + tab0.col1 * col0 AS col2 FROM tab0
----
2097
3396
8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-4283
SELECT + col2 * col2 DIV - 83 + col1 FROM tab0
----
10
73
97

skipif mysql # not compatible
query I rowsort label-4283
SELECT + col2 * col2 / - 83 + col1 FROM tab0
----
10
73
97

query I rowsort
SELECT tab0.col0 + tab0.col2 AS col0 FROM tab0
----
171
36
57

query I rowsort
SELECT + col0 * - col1 + col1 FROM tab0
----
-1978
-3298
-8008

onlyif mysql # use DIV operator for integer division
query I rowsort label-4286
SELECT DISTINCT - col1 * - ( col2 ) + cor0.col0 DIV - col0 - + col1 * - cor0.col2 col0 FROM tab2 AS cor0
----
1291
1673
3067

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4286
SELECT DISTINCT - col1 * - ( col2 ) + cor0.col0 / - col0 - + col1 * - cor0.col2 col0 FROM tab2 AS cor0
----
1291
1673
3067

query I rowsort
SELECT col1 * 33 + - cor0.col2 FROM tab1 AS cor0
----
273
333
804

query I rowsort
SELECT DISTINCT - + col1 + 91 * 31 FROM tab1 AS cor0
----
2795
2808
2811

onlyif mysql # use DIV operator for integer division
query I rowsort label-4289
SELECT ALL - - col2 * col1 DIV + 21 + + col2 * - col1 + - 46 FROM tab2 AS cor0
----
-1507
-662
-844

skipif mysql # not compatible
query I rowsort label-4289
SELECT ALL - - col2 * col1 / + 21 + + col2 * - col1 + - 46 FROM tab2 AS cor0
----
-1507
-662
-844

onlyif mysql # use DIV operator for integer division
query I rowsort label-4290
SELECT - col1 + ( col1 ) * col0 DIV - ( - 41 ) FROM tab0 AS cor0
----
-15
-36
106

skipif mysql # not compatible
query I rowsort label-4290
SELECT - col1 + ( col1 ) * col0 / - ( - 41 ) FROM tab0 AS cor0
----
-15
-36
106

query I rowsort
SELECT ALL + col1 + + col0 * - 53 AS col1 FROM tab0 AS cor0
----
-1186
-1758
-4626

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4292
SELECT + col2 / CAST( NULL AS SIGNED ) + col2 * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4292
SELECT + col2 / CAST ( NULL AS INTEGER ) + col2 * col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4293
SELECT DISTINCT col2 * CAST( cor0.col0 AS SIGNED ) + col2 * + CAST( NULL AS DECIMAL ) + 69 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4293
SELECT DISTINCT col2 * CAST ( cor0.col0 AS INTEGER ) + col2 * + CAST ( NULL AS REAL ) + 69 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + col0 * + ( cor0.col0 ) * - cor0.col1 + - col1 FROM tab0 AS cor0
----
-118922
-49622
-720902

query I rowsort
SELECT DISTINCT + col1 + col0 * cor0.col2 FROM tab1 AS cor0
----
188
3658
7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-4296
SELECT cor0.col1 DIV + cor0.col0 - col1 * col0 FROM tab1 AS cor0
----
-1040
-640
-70

skipif mysql # not compatible
query I rowsort label-4296
SELECT cor0.col1 / + cor0.col0 - col1 * col0 FROM tab1 AS cor0
----
-1040
-640
-70

query I rowsort
SELECT DISTINCT cor0.col1 * ( + col2 ) + col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT 28 + + ( + col0 ) FROM tab2
----
106
107
35

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4299
SELECT CAST( 98 AS SIGNED ) AS col0 FROM tab2
----
98
98
98

skipif mysql # not compatible
query I rowsort label-4299
SELECT CAST ( 98 AS INTEGER ) AS col0 FROM tab2
----
98
98
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 71 * col0 col1 FROM tab2 cor0
----
-497
-5538
-5609

onlyif mysql # use DIV operator for integer division
query I rowsort label-4301
SELECT DISTINCT + + ( col0 ) DIV + col1 FROM tab2 cor0
----
0
1
4

skipif mysql # not compatible
query I rowsort label-4301
SELECT DISTINCT + + ( col0 ) / + col1 FROM tab2 cor0
----
0
1
4

query I rowsort
SELECT - ( + 38 ) * + col0 AS col2 FROM tab0 AS cor0
----
-1330
-3382
-912

query I rowsort
SELECT ALL - col1 * + col2 * 24 FROM tab0 AS cor0
----
-179088
-2328
-68112

query I rowsort
SELECT DISTINCT + ( 85 * + tab2.col0 ) FROM tab2
----
595
6630
6715

query I rowsort
SELECT + 54 AS col2 FROM tab2 cor0
----
54
54
54

query I rowsort
SELECT ALL + 38 AS col1 FROM tab2 AS cor0
----
38
38
38

query I rowsort
SELECT DISTINCT + + col0 - - col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT + cor0.col2 * col2 + col2 + + ( col0 ) * col0 FROM tab1 AS cor0
----
15712
2979
7402

query I rowsort
SELECT 50 * col2 FROM tab0 AS cor0
----
1650
4100
50

query I rowsort
SELECT DISTINCT + - col0 * - col1 + + col0 AS col2 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL + col0 + col1 * col0 AS col1 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL 88 * col0 AS col0 FROM tab1 AS cor0
----
264
5632
7040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 * col1 + - 33 col2 FROM tab1 AS cor0
----
136
643
67

query I rowsort
SELECT + col1 + + cor0.col1 * - 26 AS col1 FROM tab1 AS cor0
----
-250
-325
-650

query I rowsort
SELECT ALL col2 * col2 + 24 FROM tab1 AS cor0
----
2940
3273
9240

query I rowsort
SELECT DISTINCT + + ( + cor0.col1 ) AS col1 FROM tab1 cor0
----
10
13
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * - col1 col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL 34 * - col1 AS col0 FROM tab1 AS cor0
----
-340
-442
-884

query I rowsort
SELECT DISTINCT - - 1 * col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT - col1 * + ( + col2 ) FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - col0 + + 95 AS col0 FROM tab0 AS cor0
----
6
60
71

query I rowsort
SELECT ALL + 32 * cor0.col1 * - col1 FROM tab1 AS cor0
----
-21632
-3200
-5408

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4323
SELECT CAST( - 79 AS SIGNED ) FROM tab1 AS cor0
----
-79
-79
-79

skipif mysql # not compatible
query I rowsort label-4323
SELECT CAST ( - 79 AS INTEGER ) FROM tab1 AS cor0
----
-79
-79
-79

query I rowsort
SELECT DISTINCT ( 44 ) * - col2 * - col2 AS col1 FROM tab0 AS cor0
----
295856
44
47916

query I rowsort
SELECT - col2 + + ( col1 ) + col0 AS col0 FROM tab1
----
-25
-3
17

query I rowsort
SELECT ALL - 0 FROM tab1, tab2, tab1 AS cor0, tab0
----
81 values hashing to 1f117f467f45d8c6b7553e2e3c842942

onlyif mysql # use DIV operator for integer division
query I rowsort label-4327
SELECT + 48 DIV col2 FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4327
SELECT + 48 / col2 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT ALL + - col2 * - cor0.col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT tab2.col1 AS col0 FROM tab2, tab1, tab2 cor0
----
17
31
59

query I rowsort
SELECT ALL 81 FROM tab1, tab2 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - tab2.col1 col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
-17
-31
-59

query I rowsort
SELECT ALL + ( col2 ) * col2 FROM tab2
----
1444
676
729

onlyif mysql # use DIV operator for integer division
query I rowsort label-4333
SELECT DISTINCT col1 DIV + ( tab0.col1 ) FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-4333
SELECT DISTINCT col1 / + ( tab0.col1 ) FROM tab0
----
1

query I rowsort
SELECT DISTINCT - col1 + - cor0.col1 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT ALL + col2 - + cor0.col0 FROM tab2 AS cor0
----
-41
-52
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col0 * - col1 col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT ALL 24 AS col1 FROM tab2, tab1 AS cor0
----
9 values hashing to b0d834ef9e4346801b6aaa0e74b2c8ef

query I rowsort
SELECT ALL 22 FROM tab1, tab0, tab1 AS cor0, tab1 cor1
----
81 values hashing to c6f049334398e3533dd6996714479a2f

query I rowsort
SELECT + cor0.col1 - 29 FROM tab0, tab2 AS cor0, tab0 AS cor1, tab1, tab2 AS cor2
----
243 values hashing to 7337ce90db7f17b0f125f121cfe8028d

query I rowsort
SELECT DISTINCT - cor1.col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
-10
-13
-26

query I rowsort
SELECT ALL + col0 + col2 + + 70 * - 4 * cor0.col1 FROM tab1 AS cor0
----
-2679
-3464
-7223

onlyif mysql # use DIV operator for integer division
query I rowsort label-4342
SELECT DISTINCT + col2 DIV col1 AS col2 FROM tab1
----
2
5
7

skipif mysql # not compatible
query I rowsort label-4342
SELECT DISTINCT + col2 / col1 AS col2 FROM tab1
----
2
5
7

query I rowsort
SELECT - - col0 + - col2 AS col2 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT col1 * cor0.col2 + + ( col2 ) FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT + col2 + col1 - col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT - + col2 * - col1 + + cor0.col0 * col0 FROM tab0 AS cor0
----
1322
15383
3414

query I rowsort
SELECT DISTINCT col2 * col0 + 10 * - col1 AS col1 FROM tab2
----
-121
1438
2832

query I rowsort
SELECT ALL 4 FROM tab0, tab2 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT + col1 + - ( col1 ) * - col0 FROM tab0 AS cor0
----
2150
3492
8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + cor0.col0 col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL + - 34 * - col2 * cor0.col2 + - cor0.col0 AS col1 FROM tab1 AS cor0
----
110402
313264
99141

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 77 * 76 col2 FROM tab2 AS cor0
----
5852
5852
5852

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * - 30 * col2 + - col2 col0 FROM tab0 AS cor0
----
-223942
-2911
-85173

query I rowsort
SELECT DISTINCT + 7 * + cor0.col0 AS col2 FROM tab1 AS cor0
----
21
448
560

query I rowsort
SELECT col2 * + ( + col1 ) FROM tab2
----
1534
646
837

query I rowsort
SELECT - col1 * ( - tab0.col0 + + tab0.col2 ) FROM tab0
----
-774
3298
637

query I rowsort
SELECT DISTINCT + 64 AS col0 FROM tab1, tab2 AS cor0
----
64

query I rowsort
SELECT col0 - + col0 AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT - col1 * + cor0.col2 - col2 AS col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT + ( col1 ) + cor0.col2 AS col0 FROM tab2 AS cor0
----
55
58
85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 - - col0 col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT 16 * - cor0.col0 + cor0.col1 FROM tab0 AS cor0
----
-1333
-298
-463

query I rowsort
SELECT ALL ( tab0.col1 + - col2 ) AS col1 FROM tab0
----
53
9
96

query I rowsort
SELECT - cor0.col1 AS col2 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT ALL - 74 FROM tab0
----
-74
-74
-74

onlyif mysql # use DIV operator for integer division
query I rowsort label-4366
SELECT + - col0 * col0 * col0 + col2 + col2 DIV 25 FROM tab2 AS cor0
----
-315
-474525
-493000

skipif mysql # not compatible
query I rowsort label-4366
SELECT + - col0 * col0 * col0 + col2 + col2 / 25 FROM tab2 AS cor0
----
-315
-474525
-493000

query I rowsort
SELECT + 7 - col0 AS col1 FROM tab1 AS cor0
----
-57
-73
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-4368
SELECT DISTINCT + ( + 40 ) + + col0 DIV col1 AS col0 FROM tab0 AS cor0
----
40

skipif mysql # not compatible
query I rowsort label-4368
SELECT DISTINCT + ( + 40 ) + + col0 / col1 AS col0 FROM tab0 AS cor0
----
40

query I rowsort
SELECT ALL col0 * + 36 - col0 AS col1 FROM tab0 cor0
----
1225
3115
840

query I rowsort
SELECT ALL - ( - 15 ) + + col1 * - 97 FROM tab1 AS cor0
----
-1246
-2507
-955

query I rowsort
SELECT - col0 * - col0 * + col0 AS col0 FROM tab0 AS cor0
----
13824
42875
704969

query I rowsort
SELECT ALL ( 32 ) * + col1 AS col0 FROM tab1 AS cor0
----
320
416
832

query I rowsort
SELECT - - ( - ( cor0.col2 ) ) * - col0 * col1 FROM tab0 cor0
----
3395
664118
68112

onlyif mysql # use DIV operator for integer division
query I rowsort label-4374
SELECT DISTINCT col2 + 27 DIV - cor0.col0 AS col1 FROM tab1 AS cor0
----
45
57
96

skipif mysql # not compatible
query I rowsort label-4374
SELECT DISTINCT col2 + 27 / - cor0.col0 AS col1 FROM tab1 AS cor0
----
45
57
96

query I rowsort
SELECT ALL - + col2 * + ( - col2 + + 45 ) FROM tab2 cor0
----
-266
-486
-494

query I rowsort
SELECT ALL - - ( col0 ) * - col0 AS col1 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL - col2 + + 77 AS col2 FROM tab1 AS cor0
----
-19
20
23

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 + + 87 * - col2 col1 FROM tab2 AS cor0
----
-2203
-2318
-3289

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4379
SELECT DISTINCT + + CAST( ( col0 - 56 ) AS SIGNED ) * - 7 + cor0.col1 + - col0 AS col1 FROM tab1 AS cor0
----
-110
-235
394

skipif mysql # not compatible
query I rowsort label-4379
SELECT DISTINCT + + CAST ( ( col0 - 56 ) AS INTEGER ) * - 7 + cor0.col1 + - col0 AS col1 FROM tab1 AS cor0
----
-110
-235
394

query I rowsort
SELECT ALL - 79 * + cor0.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 799eb6b46fc85c8f7962a894fde3ea6b

query I rowsort
SELECT + col0 * + col1 * + col2 - col1 AS col2 FROM tab1
----
36470
4186
99827

query I rowsort
SELECT DISTINCT + 67 * - col1 AS col1 FROM tab1 AS cor0
----
-1742
-670
-871

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 92 * col0 * - cor0.col1 col0 FROM tab0 AS cor0
----
189888
312340
745108

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col0 + col2 col1 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - col2 + col2 - col0 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT col2 + + 70 FROM tab2 AS cor0
----
108
96
97

query I rowsort
SELECT + col1 * cor0.col0 + + col0 + + 79 * col1 AS col1 FROM tab1 AS cor0
----
1494
2135
2147

query I rowsort
SELECT 42 + - 66 * cor1.col0 AS col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 70c22db36addf799d80e84398e4dd5f2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + 89 * 74 + col0 col0 FROM tab0 AS cor0
----
6696
6718
6766

query I rowsort
SELECT ALL + col2 + + ( col1 ) * + col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT cor0.col2 * col2 + - cor0.col2 * col0 FROM tab0 AS cor0
----
-34
-574
297

query I rowsort
SELECT DISTINCT col2 * ( ( col1 ) ) * 14 - - 86 AS col2 FROM tab1 AS cor0
----
17558
19742
8066

query I rowsort
SELECT DISTINCT + col1 + ( - 79 ) * + col1 FROM tab0 cor0
----
-6708
-7098
-7566

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col0 col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ALL col2 + - 8 AS col0 FROM tab0 cor0
----
-7
25
74

query I rowsort
SELECT ALL - col0 * + col2 + + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT - col0 * col0 + 6 AS col2 FROM tab1
----
-3
-4090
-6394

query I rowsort
SELECT DISTINCT - col0 * + ( + ( col1 ) ) + col2 FROM tab0 AS cor0
----
-2031
-3394
-8017

query I rowsort
SELECT col2 + ( - 2 ) + col0 FROM tab1 AS cor0
----
119
174
55

query I rowsort
SELECT DISTINCT - col1 * + cor0.col1 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT + + col0 * - col2 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT + 48 AS col0 FROM tab2 AS cor0
----
48

query I rowsort
SELECT + - 51 AS col1 FROM tab2 AS cor0
----
-51
-51
-51

query I rowsort
SELECT - 9 FROM tab2, tab1 cor0
----
9 values hashing to caf28657beb43049740febe1fa9ded5a

query I rowsort
SELECT ALL 19 * col1 AS col0 FROM tab2 AS cor0
----
1121
323
589

query I rowsort
SELECT - tab1.col2 * + col2 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT col0 * ( + 66 * + col2 ) + col2 + + ( + col1 ) AS col2 FROM tab1
----
10772
240835
506989

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 87 col1 FROM tab1 AS cor0
----
87
87
87

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + col0 * 88 col1 FROM tab1 AS cor0
----
261
5568
6960

query I rowsort
SELECT DISTINCT col1 * col1 + 49 AS col1 FROM tab1 AS cor0
----
149
218
725

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 25 + col2 col0 FROM tab0
----
107
26
58

query I rowsort
SELECT DISTINCT col2 * + col2 + - ( - col1 ) * + col1 FROM tab0 cor0
----
15005
8485
9410

query I rowsort
SELECT + col0 - - col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT + + col1 * col1 * cor0.col1 AS col2 FROM tab0 AS cor0
----
636056
753571
912673

query I rowsort
SELECT DISTINCT - 25 AS col0 FROM tab0 AS cor0
----
-25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col0 * 3 col2 FROM tab1 AS cor0
----
12288
19200
27

query I rowsort
SELECT - col2 + + col2 + - 61 AS col1 FROM tab0 AS cor0
----
-61
-61
-61

onlyif mysql # use DIV operator for integer division
query I rowsort label-4418
SELECT DISTINCT + tab0.col0 + col1 DIV - col2 AS col0 FROM tab0
----
-62
22
88

skipif mysql # not compatible
query I rowsort label-4418
SELECT DISTINCT + tab0.col0 + col1 / - col2 AS col0 FROM tab0
----
-62
22
88

query I rowsort
SELECT ALL - - col1 * col2 + 10 AS col0 FROM tab2 AS cor0
----
1544
656
847

query I rowsort
SELECT DISTINCT - col1 * col0 AS col2 FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4421
SELECT + col1 * - CAST( NULL AS DECIMAL ) * + 55 + col0 + - col1 * + col2 * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4421
SELECT + col1 * - CAST ( NULL AS REAL ) * + 55 + col0 + - col1 * + col2 * + col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - cor0.col2 * col1 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL col0 + 82 AS col1 FROM tab1 AS cor0
----
146
162
85

query I rowsort
SELECT - col0 + 81 + 73 FROM tab1 AS cor0
----
151
74
90

query I rowsort
SELECT + ( + col2 ) * - 32 AS col2 FROM tab2 cor0
----
-1216
-832
-864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 25 col0 FROM tab0
----
25
25
25

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 col2 FROM tab0, tab2, tab0 cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # use DIV operator for integer division
query I rowsort label-4428
SELECT + tab0.col0 DIV tab0.col0 col1 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4428
SELECT + tab0.col0 / tab0.col0 col1 FROM tab0
----
1
1
1

query I rowsort
SELECT col0 * ( + col2 ) FROM tab2
----
189
2028
3002

query I rowsort
SELECT + col1 + 70 + col1 * col0 * + col2 FROM tab0
----
3562
664279
68268

query I rowsort
SELECT DISTINCT col2 * - ( - 86 ) AS col1 FROM tab0 AS cor0
----
2838
7052
86

query I rowsort
SELECT DISTINCT - - cor0.col0 + + col1 AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT + col2 * 6 FROM tab2 AS cor0
----
156
162
228

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4434
SELECT ALL + - col0 * CAST( 15 * + col2 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-109470
-11880
-525

skipif mysql # not compatible
query I rowsort label-4434
SELECT ALL + - col0 * CAST ( 15 * + col2 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-109470
-11880
-525

query I rowsort
SELECT 45 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 60b9f935ee8e404d155a2f5e9515c050

query I rowsort
SELECT cor0.col2 + cor0.col2 AS col1 FROM tab1, tab0 cor0, tab1 AS cor1
----
27 values hashing to 967dc9bd7c6cd98d217c6cb5a61f5e63

query I rowsort
SELECT - col1 + - 75 * - cor0.col1 FROM tab0 AS cor0
----
6364
6734
7178

query I rowsort
SELECT + - col2 * - col0 + col2 * + ( col2 + col2 ) AS col0 FROM tab0 AS cor0
----
20746
2970
37

query I rowsort
SELECT ( - col0 ) + + col1 AS col2 FROM tab1 cor0
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-4440
SELECT DISTINCT + CAST( col1 AS SIGNED ) DIV cor0.col0 AS col0 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-4440
SELECT DISTINCT + CAST ( col1 AS INTEGER ) / cor0.col0 AS col0 FROM tab0 AS cor0
----
1
2
3

query I rowsort
SELECT + - col1 + col2 * col2 AS col0 FROM tab0 AS cor0
----
-96
1003
6633

query I rowsort
SELECT 53 - col2 AS col1 FROM tab2 AS cor0
----
15
26
27

onlyif mysql # use DIV operator for integer division
query I rowsort label-4443
SELECT col2 DIV + ( col2 ) + col2 + ( col2 ) FROM tab1
----
109
115
193

skipif mysql # not compatible
query I rowsort label-4443
SELECT col2 / + ( col2 ) + col2 + ( col2 ) FROM tab1
----
109
115
193

query I rowsort
SELECT - - 62 + col2 FROM tab2 AS cor0
----
100
88
89

query I rowsort
SELECT - + col0 - cor0.col2 AS col1 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT col2 + ( + col2 * + tab2.col0 ) + 80 * - col0 AS col0 FROM tab2
----
-3280
-344
-4186

query I rowsort
SELECT 31 - + col1 * + cor0.col2 FROM tab1 cor0
----
-1217
-1373
-539

query I rowsort
SELECT + col0 * 90 + + col2 FROM tab0 AS cor0
----
2193
3151
8092

query I rowsort
SELECT - tab1.col0 * ( col0 ) AS col2 FROM tab1
----
-4096
-6400
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4450
SELECT DISTINCT + CAST( + 74 AS SIGNED ) * col1 FROM tab0
----
6364
6734
7178

skipif mysql # not compatible
query I rowsort label-4450
SELECT DISTINCT + CAST ( + 74 AS INTEGER ) * col1 FROM tab0
----
6364
6734
7178

onlyif mysql # use DIV operator for integer division
query I rowsort label-4451
SELECT + col1 DIV ( tab1.col1 + ( + 11 ) ) AS col0 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4451
SELECT + col1 / ( tab1.col1 + ( + 11 ) ) AS col0 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 16 * - ( - col2 ) col1 FROM tab2
----
416
432
608

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + ( col1 ) * + col1 col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT col0 * col1 * - ( + 28 ) FROM tab2 cor0
----
-128856
-37604
-6076

query I rowsort
SELECT - col2 * + col0 + + 60 * + cor0.col1 FROM tab2 cor0
----
-1982
1512
1671

query I rowsort
SELECT - ( col0 ) + + col2 + - 85 AS col2 FROM tab1 AS cor0
----
-34
-69
-92

query I rowsort
SELECT 26 * + col1 FROM tab1
----
260
338
676

query I rowsort
SELECT + 35 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to d9b103f79c4e8f0de4b7c1c821783a29

query I rowsort
SELECT DISTINCT + col2 * - col0 + - 19 AS col2 FROM tab2 AS cor0
----
-2047
-208
-3021

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col2 - - col2 col1 FROM tab0 cor0
----
164
2
66

query I rowsort
SELECT ALL ( col1 ) - col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT DISTINCT - 2 + col0 FROM tab0 AS cor0
----
22
33
87

query I rowsort
SELECT - 94 AS col1 FROM tab2 cor0
----
-94
-94
-94

query I rowsort
SELECT ALL - cor0.col2 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT + col1 + + ( - 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
----
35
7298
792

query I rowsort
SELECT ALL - - 66 FROM tab1 cor0
----
66
66
66

query I rowsort
SELECT DISTINCT ( - 3 ) FROM tab0, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
-3

query I rowsort
SELECT DISTINCT - col0 * 91 FROM tab2 cor0
----
-637
-7098
-7189

query I rowsort
SELECT DISTINCT + col1 * + ( ( - col0 ) ) FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT 25 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

query I rowsort
SELECT DISTINCT - col2 + - col2 * + col0 AS col2 FROM tab0 AS cor0
----
-36
-7380
-825

onlyif mysql # use DIV operator for integer division
query I rowsort label-4473
SELECT - + 55 DIV - col0 AS col0 FROM tab2 AS cor0
----
0
0
7

skipif mysql # not compatible
query I rowsort label-4473
SELECT - + 55 / - col0 AS col0 FROM tab2 AS cor0
----
0
0
7

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 DISTINCT col0 * col1 * - ( ( col2 ) ) FROM tab2 AS cor0
----
-119652
-51034
-5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-4476
SELECT - cor0.col0 DIV - col0 AS col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4476
SELECT - cor0.col0 / - col0 AS col0 FROM tab2 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4477
SELECT col0 + col0 DIV - col1 col1 FROM tab2 cor0
----
7
75
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4477
SELECT col0 + col0 / - col1 col1 FROM tab2 cor0
----
7
75
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - 95 col0 FROM tab0 AS cor0
----
-95

query I rowsort
SELECT 18 * - col0 FROM tab2 AS cor0
----
-126
-1404
-1422

query I rowsort
SELECT ALL col1 * 5 AS col2 FROM tab0 AS cor0
----
430
455
485

query I rowsort
SELECT DISTINCT + col1 + 49 AS col0 FROM tab0 AS cor0
----
135
140
146

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4482
SELECT ALL col1 * CAST( NULL AS DECIMAL ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4482
SELECT ALL col1 * CAST ( NULL AS REAL ) AS col2 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4483
SELECT DISTINCT - + col1 DIV 72 FROM tab1 cor0
----
0

skipif mysql # not compatible
query I rowsort label-4483
SELECT DISTINCT - + col1 / 72 FROM tab1 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4484
SELECT - + cor0.col2 DIV + 48 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4484
SELECT - + cor0.col2 / + 48 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 + cor0.col2 + - col1 AS col2 FROM tab2 AS cor0
----
-7
23
59

query I rowsort
SELECT - col1 + - col2 * 42 AS col0 FROM tab2 AS cor0
----
-1151
-1165
-1613

skipif mysql # not compatible
query I rowsort
SELECT col1 * + CAST ( - col0 * + col1 AS REAL ) FROM tab0 cor0
----
-177504
-329315
-737009

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4488
SELECT DISTINCT - ( col1 * + CAST( col2 AS SIGNED ) ) FROM tab0
----
-2838
-7462
-97

skipif mysql # not compatible
query I rowsort label-4488
SELECT DISTINCT - ( col1 * + CAST ( col2 AS INTEGER ) ) FROM tab0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + col0 * + 76 col0 FROM tab0 AS cor0
----
1848
2695
6853

query I rowsort
SELECT DISTINCT 13 AS col0 FROM tab2, tab0 cor0, tab0 AS cor1
----
13

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4491
SELECT ALL + + ( - 72 ) * + col2 + + CAST( col0 AS SIGNED ) FROM tab0 AS cor0
----
-2352
-37
-5815

skipif mysql # not compatible
query I rowsort label-4491
SELECT ALL + + ( - 72 ) * + col2 + + CAST ( col0 AS INTEGER ) FROM tab0 AS cor0
----
-2352
-37
-5815

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4492
SELECT ALL ( cor0.col0 ) + + cor0.col2 + CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4492
SELECT ALL ( cor0.col0 ) + + cor0.col2 + CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor0.col1 * col2 AS col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT ALL - 44 * cor0.col1 + col2 * - ( - col0 ) AS col1 FROM tab0 AS cor0
----
-2992
-4233
3294

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 58 * 36 + - col1 col2 FROM tab2 AS cor0
----
-2105
-2119
-2147

query I rowsort
SELECT ALL - ( col0 ) * - col1 + + ( col0 ) + cor0.col2 FROM tab2 AS cor0
----
1460
251
4706

query I rowsort
SELECT DISTINCT - + col0 * - col1 + col1 AS col1 FROM tab2 cor0
----
1360
248
4661

query I rowsort
SELECT ALL - cor0.col1 * 55 AS col0 FROM tab2 AS cor0
----
-1705
-3245
-935

query I rowsort
SELECT + col1 + - col2 * - col2 - 70 AS col0 FROM tab1 cor0
----
2872
3189
9159

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 77 col1 FROM tab1 AS cor0
----
77
77
77

onlyif mysql # use DIV operator for integer division
query I rowsort label-4501
SELECT + - ( + cor0.col1 ) DIV col0 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-4501
SELECT + - ( + cor0.col1 ) / col0 FROM tab2 AS cor0
----
-4
0
0

query I rowsort
SELECT DISTINCT - ( - col2 ) * col2 + + col0 + 86 AS col1 FROM tab1 AS cor0
----
3005
3399
9382

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4503
SELECT + col1 * cor0.col2 + col0 + CAST( NULL AS SIGNED ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4503
SELECT + col1 * cor0.col2 + col0 + CAST ( NULL AS INTEGER ) col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col1 * 0 + - col2 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4505
SELECT + col1 * + CAST( + 62 AS SIGNED ) - + tab1.col2 col0 FROM tab1
----
1558
563
710

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4505
SELECT + col1 * + CAST ( + 62 AS INTEGER ) - + tab1.col2 col0 FROM tab1
----
1558
563
710

query I rowsort
SELECT col0 * 78 AS col0 FROM tab1
----
234
4992
6240

query I rowsort
SELECT ALL - 49 * - col2 * col0 + 38 AS col1 FROM tab2 AS cor0
----
147136
9299
99410

query I rowsort
SELECT + 32 + col2 FROM tab0 cor0
----
114
33
65

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 77 col1 FROM tab1, tab0 cor0
----
77

query I rowsort
SELECT ALL + 78 * col0 AS col2 FROM tab0 AS cor0
----
1872
2730
6942

onlyif mysql # use DIV operator for integer division
query I rowsort label-4511
SELECT + - col2 DIV + col2 AS col2 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-4511
SELECT + - col2 / + col2 AS col2 FROM tab1 cor0
----
-1
-1
-1

query I rowsort
SELECT DISTINCT - ( tab2.col1 ) FROM tab2, tab0 AS cor0
----
-17
-31
-59

query I rowsort
SELECT tab2.col1 * - col1 + col2 * - col1 FROM tab2
----
-1798
-5015
-935

query I rowsort
SELECT col1 * col0 + col2 + - col0 AS col2 FROM tab0
----
2073
3361
8092

onlyif mysql # use DIV operator for integer division
query I rowsort label-4515
SELECT - col2 * cor0.col0 * col1 - 27 * col2 DIV + CAST( - cor0.col1 AS SIGNED ) FROM tab2 AS cor0
----
-119641
-50974
-5836

skipif mysql # not compatible
query I rowsort label-4515
SELECT - col2 * cor0.col0 * col1 - 27 * col2 / + CAST ( - cor0.col1 AS INTEGER ) FROM tab2 AS cor0
----
-119641
-50974
-5836

onlyif mysql # use DIV operator for integer division
query I rowsort label-4516
SELECT + col2 DIV col0 + ( - col1 * col1 ) FROM tab1 AS cor0
----
-100
-168
-658

skipif mysql # not compatible
query I rowsort label-4516
SELECT + col2 / col0 + ( - col1 * col1 ) FROM tab1 AS cor0
----
-100
-168
-658

query I rowsort
SELECT DISTINCT + 1 + col0 FROM tab1
----
4
65
81

query I rowsort
SELECT + - 12 + - col2 * ( + col2 ) FROM tab1 AS cor0
----
-2928
-3261
-9228

query I rowsort
SELECT ALL ( + 16 ) * + col1 + + tab0.col2 FROM tab0
----
1409
1538
1553

query I rowsort
SELECT DISTINCT + col0 + 32 * + col1 AS col2 FROM tab0
----
2776
3001
3139

query I rowsort
SELECT 35 * col0 AS col2 FROM tab2
----
245
2730
2765

query I rowsort
SELECT DISTINCT - ( col0 * + col2 ) FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - 93 FROM tab2 cor0
----
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-4524
SELECT ALL + cor0.col1 DIV col0 + - col0 FROM tab2 AS cor0
----
-3
-78
-79

skipif mysql # not compatible
query I rowsort label-4524
SELECT ALL + cor0.col1 / col0 + - col0 FROM tab2 AS cor0
----
-3
-78
-79

query I rowsort
SELECT ALL - col1 + col2 * ( col1 ) AS col0 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT col2 * + cor0.col0 + col1 FROM tab1 cor0
----
188
3658
7693

query I rowsort
SELECT ALL 31 FROM tab2, tab0 cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query I rowsort
SELECT ALL 33 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT + tab0.col0 * cor0.col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 9dd217b6385bf38f78d8b6e6b7864578

query I rowsort
SELECT DISTINCT + col1 * - 98 + - col0 + - col1 AS col0 FROM tab0 AS cor0
----
-8538
-9098
-9638

query I rowsort
SELECT DISTINCT col1 + 17 AS col1 FROM tab2 AS cor0
----
34
48
76

query I rowsort
SELECT + + col0 + + 6 AS col2 FROM tab0 AS cor0
----
30
41
95

query I rowsort
SELECT ALL + col1 * - col2 - - cor0.col2 * col0 AS col0 FROM tab0 AS cor0
----
-164
-2046
-62

query I rowsort
SELECT DISTINCT col1 + - ( + col0 ) FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT ALL col0 + ( 10 ) FROM tab0 AS cor0
----
34
45
99

query I rowsort
SELECT col2 * - 90 + - tab0.col1 AS col0 FROM tab0
----
-187
-3056
-7471

query I rowsort
SELECT cor3.col2 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab0 AS cor2, tab1 AS cor3
----
243 values hashing to 39c7e653e7a493eb9c9e3dad9ba3b8c2

query I rowsort
SELECT DISTINCT ( col2 ) * + col1 - - 86 AS col0 FROM tab0 AS cor0
----
183
2924
7548

onlyif mysql # use DIV operator for integer division
query I rowsort label-4539
SELECT ALL 58 + 77 - col0 DIV - cor0.col0 AS col2 FROM tab1 AS cor0
----
136
136
136

skipif mysql # not compatible
query I rowsort label-4539
SELECT ALL 58 + 77 - col0 / - cor0.col0 AS col2 FROM tab1 AS cor0
----
136
136
136

query I rowsort
SELECT - 93 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to 38f445d95788c7dc754ff688a62df03b

query I rowsort
SELECT - + col2 + 29 + col1 FROM tab2 AS cor0
----
33
62
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-4542
SELECT + col1 * - col0 - col0 DIV col1 FROM tab2 AS cor0
----
-1347
-217
-4603

skipif mysql # not compatible
query I rowsort label-4542
SELECT + col1 * - col0 - col0 / col1 FROM tab2 AS cor0
----
-1347
-217
-4603

query I rowsort
SELECT + col1 - 46 AS col0 FROM tab0 cor0
----
40
45
51

query I rowsort
SELECT - col0 + col1 * col0 + - 92 AS col2 FROM tab0
----
1948
3268
7918

query I rowsort
SELECT DISTINCT - col0 * - cor0.col1 AS col2 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT - 34 + cor0.col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 4b8b22643b918873e1e2bdb254fda7a4

query I rowsort
SELECT + - ( col2 ) + - cor0.col1 AS col2 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT DISTINCT col0 * ( + 75 ) AS col0 FROM tab2
----
525
5850
5925

query I rowsort
SELECT - + col0 + + col1 AS col0 FROM tab2 cor0
----
-19
-62
24

query I rowsort
SELECT + 80 + col0 AS col0 FROM tab2 AS cor0
----
158
159
87

query I rowsort
SELECT + col0 * - col2 + col2 AS col0 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT - tab1.col1 FROM tab1, tab2, tab0 cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT ALL 30 AS col0 FROM tab2
----
30
30
30

query I rowsort
SELECT DISTINCT 10 + - col1 FROM tab2
----
-21
-49
-7

query I rowsort
SELECT ALL col1 + - col1 * - col0 + tab1.col0 FROM tab1
----
107
1133
714

onlyif mysql # use DIV operator for integer division
query I rowsort label-4556
SELECT col0 DIV col1 col0 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4556
SELECT col0 / col1 col0 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL + 1 AS col1 FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * tab0.col0 col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - 57 + - 45 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
-102

query I rowsort
SELECT DISTINCT - col0 * + ( 15 ) * col0 + - cor0.col1 * - 72 AS col2 FROM tab0 AS cor0
----
-112263
-11391
-2448

query I rowsort
SELECT DISTINCT + col1 - - col2 FROM tab2
----
55
58
85

query I rowsort
SELECT + col0 + - ( tab1.col0 ) * col2 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT ALL col1 - + 2 AS col2 FROM tab0
----
84
89
95

query I rowsort
SELECT DISTINCT - col1 - 34 * tab2.col1 FROM tab2
----
-1085
-2065
-595

onlyif mysql # use DIV operator for integer division
query I rowsort label-4565
SELECT col1 + - 7 + - 24 DIV + col2 FROM tab1
----
19
3
6

skipif mysql # not compatible
query I rowsort label-4565
SELECT col1 + - 7 + - 24 / + col2 FROM tab1
----
19
3
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4566
SELECT cor0.col0 * - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4566
SELECT cor0.col0 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4567
SELECT CAST( NULL AS SIGNED ) * - col0 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4567
SELECT CAST ( NULL AS INTEGER ) * - col0 AS col1 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( - col2 ) + col0 + + col2 * col2 * col0 AS col2 FROM tab2
----
114193
5137
52832

query I rowsort
SELECT + 41 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 5b18986bb294412b3d9f07b7e6fc821e

query I rowsort
SELECT ALL + 17 * - col1 FROM tab0
----
-1462
-1547
-1649

query I rowsort
SELECT ALL + ( + col2 ) * + col2 + - col2 FROM tab0
----
0
1056
6642

query I rowsort
SELECT - 77 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 3a24155cb91ceff1e67bb51c07b72107

query I rowsort
SELECT - ( + col0 ) * ( col0 ) AS col2 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT - + 87 * col0 AS col0 FROM tab1 AS cor0
----
-261
-5568
-6960

query I rowsort
SELECT ALL + 38 * + col0 FROM tab0 AS cor0
----
1330
3382
912

query I rowsort
SELECT + 75 * col1 + 57 AS col0 FROM tab1 AS cor0
----
1032
2007
807

query I rowsort
SELECT ALL - col2 * col2 + col0 AS col0 FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT - 63 * - col1 FROM tab1
----
1638
630
819

query I rowsort
SELECT DISTINCT col1 * - col2 + col0 AS col1 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT + 4 * + col2 * 87 FROM tab0 AS cor0
----
11484
28536
348

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4581
SELECT DISTINCT ( - col0 ) * + CAST( NULL AS DECIMAL ) + 85 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4581
SELECT DISTINCT ( - col0 ) * + CAST ( NULL AS REAL ) + 85 AS col1 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - tab1.col0 + col1 col1 FROM tab1
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-4583
SELECT DISTINCT col1 + + col1 * col1 DIV + col2 FROM tab1
----
11
14
38

skipif mysql # not compatible
query I rowsort label-4583
SELECT DISTINCT col1 + + col1 * col1 / + col2 FROM tab1
----
11
14
38

query I rowsort
SELECT - col0 + - tab1.col0 * col1 + + tab1.col1 FROM tab1
----
-1107
-55
-694

onlyif mysql # use DIV operator for integer division
query I rowsort label-4585
SELECT ALL + col2 + + col0 * + col1 DIV - col1 AS col2 FROM tab0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-4585
SELECT ALL + col2 + + col0 * + col1 / - col1 AS col2 FROM tab0
----
-34
-7
9

query I rowsort
SELECT DISTINCT col2 * col2 - col0 AS col0 FROM tab2 AS cor0
----
1365
598
722

query I rowsort
SELECT DISTINCT - + cor0.col2 * - cor0.col2 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT + - col1 - col0 AS col0 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT col0 * tab0.col2 + col2 AS col0 FROM tab0
----
36
7380
825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + tab2.col2 col2 FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-4591
SELECT col2 DIV col2 + - col0 + col0 col2 FROM tab0 cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4591
SELECT col2 / col2 + - col0 + col0 col2 FROM tab0 cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-4592
SELECT ALL cor0.col2 DIV + col2 + col2 - col2 AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4592
SELECT ALL cor0.col2 / + col2 + col2 - col2 AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL + - col2 + col1 + + col1 AS col1 FROM tab1 AS cor0
----
-2
-37
-70

query I rowsort
SELECT DISTINCT col1 + - col0 AS col0 FROM tab0 AS cor0
----
2
62

query I rowsort
SELECT col1 + + col0 * + cor0.col2 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT col2 * col2 + + col0 * + col0 FROM tab1
----
15616
2925
7345

query I rowsort
SELECT col1 * col1 - col2 FROM tab0
----
7363
8199
9408

query I rowsort
SELECT DISTINCT - col1 * + tab2.col1 + tab2.col2 AS col0 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT ALL + + col0 * col0 * + col1 AS col2 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT ALL + col0 + - col0 + + col0 AS col0 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + 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 ALL - col2 + - col2 col0 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT - ( cor0.col2 ) + + col0 AS col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT + 9 * col1 FROM tab1 cor0
----
117
234
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + col0 * col0 * - col0 col2 FROM tab1 AS cor0
----
-262087
-511904
27

query I rowsort
SELECT + col2 * + cor0.col1 * + col2 AS col1 FROM tab2 AS cor0
----
22599
24548
39884

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - cor0.col1 ) col0 FROM tab0 cor0
----
-86
-91
-97

query I rowsort
SELECT + 80 * col0 FROM tab0 AS cor0
----
1920
2800
7120

query I rowsort
SELECT ALL - 73 * - col1 FROM tab2 AS cor0
----
1241
2263
4307

query I rowsort
SELECT DISTINCT ( col2 ) * - col0 * - col0 + cor0.col1 FROM tab2 AS cor0
----
1354
158243
237175

query I rowsort
SELECT DISTINCT - col2 * - col1 * + col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT - - col2 * + col2 AS col1 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT + col2 + + col1 * cor0.col2 FROM tab2 AS cor0
----
1560
684
864

query I rowsort
SELECT ALL - - 94 AS col0 FROM tab1 AS cor0
----
94
94
94

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col1 * cor0.col0 col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT - col1 * + col0 * + col2 AS col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT ALL - col0 * - col0 * + cor0.col2 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT cor0.col2 FROM tab2, tab2 AS cor0, tab1, tab2 cor1
----
81 values hashing to c4e6b1f1d28e731664a15a6f7cda4da9

query I rowsort
SELECT ALL col2 - col0 * col2 * col1 FROM tab2
----
-119626
-50996
-5832

query I rowsort
SELECT + col1 + tab2.col2 * + tab2.col0 FROM tab2
----
2087
220
3019

query I rowsort
SELECT ALL - col0 * + col0 + col1 * + col0 AS col2 FROM tab0
----
1488
178
2170

onlyif mysql # use DIV operator for integer division
query I rowsort label-4622
SELECT - col0 DIV - col0 AS col1 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-4622
SELECT - col0 / - col0 AS col1 FROM tab1
----
1
1
1

query I rowsort
SELECT DISTINCT + col2 * col2 + tab1.col2 FROM tab1
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-4624
SELECT + tab1.col1 DIV tab1.col0 + + col2 * col0 FROM tab1
----
170
3648
7680

skipif mysql # not compatible
query I rowsort label-4624
SELECT + tab1.col1 / tab1.col0 + + col2 * col0 FROM tab1
----
170
3648
7680

query I rowsort
SELECT DISTINCT - col0 / col0 + col1 FROM tab2 WHERE NOT ( tab2.col0 / col0 ) NOT BETWEEN NULL AND - col1
----

query I rowsort
SELECT ALL + col2 * - col2 + + tab2.col2 FROM tab2
----
-1406
-650
-702

query I rowsort
SELECT col2 + + col1 * + col2 FROM tab2
----
1560
684
864

query I rowsort
SELECT col0 * + col1 + + col2 * col2 / tab0.col0 FROM tab0 WHERE NULL NOT IN ( col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 + - col2 * col1 col2 FROM tab2
----
-1593
-663
-868

query III rowsort
SELECT * FROM tab2 WHERE NOT col0 * col2 > NULL
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NULL NOT IN ( col1 * col2 )
----

query I rowsort
SELECT DISTINCT col0 * - col2 * - col2 AS col0 FROM tab0
----
26136
35
598436

query I rowsort
SELECT col2 * - col2 - col2 FROM tab1
----
-2970
-3306
-9312

query I rowsort
SELECT col0 + + col1 - col1 AS col0 FROM tab2
----
7
78
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-4635
SELECT - col0 + col1 DIV + col1 FROM tab2
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-4635
SELECT - col0 + col1 / + col1 FROM tab2
----
-6
-77
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT tab0.col0 * + col2 + + col0 col0 FROM tab0 WHERE ( NULL ) NOT IN ( + col1 * col2 )
----

query I rowsort
SELECT DISTINCT tab0.col0 * col0 + + col0 - + col1 * + col2 FROM tab0
----
-2238
1163
548

onlyif mysql # use DIV operator for integer division
query I rowsort label-4638
SELECT - col0 DIV - tab0.col2 + col2 * - col0 FROM tab0
----
-7297
-792
0

skipif mysql # not compatible
query I rowsort label-4638
SELECT - col0 / - tab0.col2 + col2 * - col0 FROM tab0
----
-7297
-792
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4639
SELECT ALL - tab0.col2 + col2 DIV col1 FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-4639
SELECT ALL - tab0.col2 + col2 / col1 FROM tab0
----
-1
-33
-82

query I rowsort
SELECT DISTINCT - tab2.col2 * col0 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT ALL + tab2.col0 * tab2.col0 AS col2 FROM tab2
----
49
6084
6241

query I rowsort
SELECT col0 + + tab0.col1 + col0 FROM tab0 WHERE ( - col2 * col1 / + col0 + + col2 / col1 ) <> NULL
----

query I rowsort
SELECT + col1 * + col2 * col0 FROM tab1
----
36480
4212
99840

onlyif mysql # use DIV operator for integer division
query I rowsort label-4644
SELECT tab1.col2 DIV + tab1.col2 + - col1 * tab1.col1 AS col1 FROM tab1
----
-168
-675
-99

skipif mysql # not compatible
query I rowsort label-4644
SELECT tab1.col2 / + tab1.col2 + - col1 * tab1.col1 AS col1 FROM tab1
----
-168
-675
-99

query I rowsort
SELECT DISTINCT col1 * + col0 + + col0 - - col0 FROM tab2 AS cor0
----
1501
231
4758

query III rowsort
SELECT ALL * FROM tab1 WHERE NULL BETWEEN col1 AND NULL
----

query I rowsort
SELECT col0 - + col1 AS col1 FROM tab1
----
-23
54
67

query I rowsort
SELECT + col0 * col0 + - col0 * + col2 * - col0 FROM tab1
----
237568
495
620800

query I rowsort
SELECT DISTINCT - col0 * - col0 + col2 FROM tab1
----
4153
63
6496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col2 * + col1 + - tab2.col1 col0 FROM tab2
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * + col2 col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT - col0 * col1 + + col1 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT ALL col2 * + col0 + + col2 * - col2 FROM tab2
----
-540
1352
1558

query I rowsort
SELECT col1 * - 98 * col0 FROM tab0 cor0
----
-202272
-332710
-793702

query I rowsort
SELECT - col2 - col2 AS col0 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT - 75 - + col0 FROM tab0 AS cor0
----
-110
-164
-99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + cor0.col0 * - col0 col2 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT DISTINCT + + col2 * - col2 + + ( col2 ) - col2 * col2 FROM tab1 AS cor0
----
-18336
-5778
-6441

query I rowsort
SELECT + cor0.col1 * 98 FROM tab1, tab1 AS cor0
----
9 values hashing to 78f73cc3df4091f36a0c49a0e073121b

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0, tab2 cor1, tab2, tab1 AS cor2
----
3645 values hashing to 97b2ae21242e1e40418ee2ad06544f7a

query I rowsort
SELECT DISTINCT + + col1 * + col2 * col0 AS col0 FROM tab2 AS cor0
----
119652
51034
5859

query I rowsort
SELECT ALL - col0 + 64 AS col2 FROM tab1 AS cor0
----
-16
0
61

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 7 col1 FROM tab2 AS cor0
----
119
217
413

query I rowsort
SELECT - col1 * 51 + + col1 * + cor0.col1 * + 57 FROM tab2 AS cor0
----
15606
195408
53196

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 86 - - cor1.col1 col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
112
96
99

query I rowsort
SELECT - + ( col1 ) * col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT ALL col1 * ( - tab0.col1 ) * - tab0.col2 FROM tab0
----
244068
679042
9409

query I rowsort
SELECT tab1.col1 * + col0 + 71 AS col1 FROM tab1
----
1111
149
711

query I rowsort
SELECT + ( - col0 ) * cor0.col2 FROM tab2 AS cor0
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-4670
SELECT - col2 * 13 DIV - col0 AS col1 FROM tab2 AS cor0
----
4
50
6

skipif mysql # not compatible
query I rowsort label-4670
SELECT - col2 * 13 / - col0 AS col1 FROM tab2 AS cor0
----
4
50
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 45 col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

query I rowsort
SELECT + 89 AS col2 FROM tab1, tab2 cor0
----
9 values hashing to 5c8428e9f1e7de3d09cb0814b4cc1743

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 84 FROM tab2, tab2 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT DISTINCT tab1.col0 * + col1 * tab1.col0 FROM tab1
----
234
40960
83200

query I rowsort
SELECT DISTINCT ( - 78 ) FROM tab1, tab2 AS cor0
----
-78

query I rowsort
SELECT ALL + 70 + ( col1 ) * + col0 FROM tab2 cor0
----
1413
287
4672

query I rowsort
SELECT DISTINCT - 64 * cor0.col2 * col0 + col2 * - cor0.col2 AS col1 FROM tab1 AS cor0
----
-13284
-236721
-500736

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( col1 AS REAL ) / col1 + col2 * col2 / col2 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT ALL + + 53 + 49 + + cor0.col2 AS col1 FROM tab2 cor0
----
128
129
140

query I rowsort
SELECT 33 FROM tab1, tab2 cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

query I rowsort
SELECT 0 FROM tab0, tab0 cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT DISTINCT + ( tab2.col2 + col0 ) * col0 FROM tab2
----
238
8112
9243

query I rowsort
SELECT + col2 * - 66 FROM tab2 AS cor0
----
-1716
-1782
-2508

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4685
SELECT - + CAST( NULL AS SIGNED ) * col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4685
SELECT - + CAST ( NULL AS INTEGER ) * col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 14 + col1 AS col0 FROM tab2
----
31
45
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 65 * col2 + + col2 col2 FROM tab1
----
3564
3762
6336

query I rowsort
SELECT DISTINCT col1 + + col1 * col0 * cor0.col0 AS col1 FROM tab1 AS cor0
----
260
40970
83213

query I rowsort
SELECT - tab0.col1 - - col2 FROM tab0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-4690
SELECT 78 DIV - col2 AS col0 FROM tab0
----
-2
-78
0

skipif mysql # not compatible
query I rowsort label-4690
SELECT 78 / - col2 AS col0 FROM tab0
----
-2
-78
0

query I rowsort
SELECT - col2 + 0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT col0 * + col1 * cor0.col1 + + col1 * - col1 * col1 AS col1 FROM tab2 AS cor0
----
-23064
17918
66139

query I rowsort
SELECT - col2 - + tab1.col1 * col2 FROM tab1
----
-1344
-1458
-627

query I rowsort
SELECT + col2 + + ( cor0.col2 ) FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT - col0 * + col2 + col2 FROM tab1 cor0
----
-108
-3591
-7584

query I rowsort
SELECT ALL col2 * - col2 - - col2 FROM tab1 AS cor0
----
-2862
-3192
-9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-4697
SELECT col1 DIV 1 + col1 FROM tab0 AS cor0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-4697
SELECT col1 / 1 + col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT col0 * + cor0.col1 + - 76 AS col0 FROM tab1 AS cor0
----
2
564
964

query I rowsort
SELECT + col0 * + 57 + + 24 FROM tab1 AS cor0
----
195
3672
4584

query I rowsort
SELECT + + cor0.col0 + - cor0.col1 FROM tab0 AS cor0
----
-2
-62
-62

skipif mysql # not compatible
query I rowsort
SELECT - col0 + CAST ( col1 AS REAL ) * + col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT DISTINCT + - col0 + 6 FROM tab1 AS cor0
----
-58
-74
3

query I rowsort
SELECT ALL - col0 * col2 * col0 AS col1 FROM tab0 AS cor0
----
-1225
-19008
-649522

query I rowsort
SELECT 73 FROM tab0 cor0 CROSS JOIN tab0 cor1
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT ALL + 30 * cor1.col2 * cor1.col2 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 33cb95d979427f8fccc7196697175397

query I rowsort
SELECT DISTINCT tab2.col2 * col2 + + col2 + col1 FROM tab2
----
1499
761
787

query I rowsort
SELECT - col0 + tab1.col1 + col0 FROM tab1
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-4708
SELECT ALL col1 + + col2 * 25 DIV col1 AS col1 FROM tab0
----
113
95
97

skipif mysql # not compatible
query I rowsort label-4708
SELECT ALL col1 + + col2 * 25 / col1 AS col1 FROM tab0
----
113
95
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4709
SELECT col2 * - CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4709
SELECT col2 * - CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 96 + tab0.col0 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to 582854078be196b60e3362f5269871cf

query I rowsort
SELECT DISTINCT - col0 * col0 + - 70 * col0 AS col2 FROM tab2
----
-11544
-11771
-539

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab1.col1 + + 45 * col2 col1 FROM tab1
----
2456
2575
4333

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4713
SELECT DISTINCT CAST( NULL AS DECIMAL ) AS col1 FROM tab0, tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4713
SELECT DISTINCT CAST ( NULL AS REAL ) AS col1 FROM tab0, tab0 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4714
SELECT ALL col0 + 56 DIV 81 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-4714
SELECT ALL col0 + 56 / 81 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - col1 + ( - 62 ) AS col1 FROM tab2 AS cor0
----
-121
-79
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-4716
SELECT ALL col0 DIV + tab2.col0 + col1 * col2 AS col0 FROM tab2
----
1535
647
838

skipif mysql # not compatible
query I rowsort label-4716
SELECT ALL col0 / + tab2.col0 + col1 * col2 AS col0 FROM tab2
----
1535
647
838

query I rowsort
SELECT - - col1 - + 18 FROM tab0 AS cor0
----
68
73
79

query I rowsort
SELECT DISTINCT - - col2 * + col0 + col0 + col0 FROM tab1 AS cor0
----
168
3776
7840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4719
SELECT ALL - CAST( - 74 + col1 AS SIGNED ) * - col2 AS col1 FROM tab2
----
-1161
-2166
-390

skipif mysql # not compatible
query I rowsort label-4719
SELECT ALL - CAST ( - 74 + col1 AS INTEGER ) * - col2 AS col1 FROM tab2
----
-1161
-2166
-390

query I rowsort
SELECT + col0 + - 88 FROM tab1
----
-24
-8
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 13 col0 FROM tab1
----
-13
-13
-13

query I rowsort
SELECT + 85 * tab1.col2 + - col1 * ( + 47 ) AS col0 FROM tab1
----
3368
4375
7549

query I rowsort
SELECT + 65 * cor0.col2 AS col0 FROM tab1 AS cor0
----
3510
3705
6240

query I rowsort
SELECT + 90 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

onlyif mysql # use DIV operator for integer division
query I rowsort label-4725
SELECT ( - 34 ) + col2 DIV + col2 AS col0 FROM tab1
----
-33
-33
-33

skipif mysql # not compatible
query I rowsort label-4725
SELECT ( - 34 ) + col2 / + col2 AS col0 FROM tab1
----
-33
-33
-33

query I rowsort
SELECT ALL - 40 - - col0 FROM tab2 AS cor0
----
-33
38
39

query I rowsort
SELECT ALL + 39 + + col0 FROM tab2 AS cor0
----
117
118
46

query I rowsort
SELECT ALL 44 * + cor0.col2 * + col2 + + col1 AS col0 FROM tab0 AS cor0
----
141
295947
48002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4729
SELECT DISTINCT + - col2 * col0 + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4729
SELECT DISTINCT + - col2 * col0 + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT - - col0 + col1 AS col2 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT - col2 * col0 + ( col1 ) FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT + - 92 * + col0 FROM tab2 AS cor0
----
-644
-7176
-7268

query I rowsort
SELECT ALL - col1 * - col1 + col1 AS col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT 65 * cor0.col2 AS col0 FROM tab1 cor0
----
3510
3705
6240

query I rowsort
SELECT ALL + ( - cor0.col0 ) * 6 * - 26 + col1 + - cor0.col1 FROM tab2 AS cor0
----
1092
12168
12324

query I rowsort
SELECT ALL + col0 + - col2 * + ( cor0.col2 ) FROM tab1 AS cor0
----
-2913
-3185
-9136

query I rowsort
SELECT + col2 * + cor0.col2 * 19 FROM tab1 AS cor0
----
175104
55404
61731

query I rowsort
SELECT DISTINCT + ( - col2 * col1 ) FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT col2 * + 48 AS col1 FROM tab1 AS cor0
----
2592
2736
4608

query I rowsort
SELECT - - cor0.col2 * col0 * col0 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT ALL col2 * - col1 + - 29 FROM tab1 cor0
----
-1277
-1433
-599

query I rowsort
SELECT DISTINCT + + col1 - + ( ( col2 ) ) AS col0 FROM tab2 AS cor0
----
-21
33
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * 63 col2 FROM tab2 AS cor0
----
-1638
-1701
-2394

query I rowsort
SELECT - + col2 + ( + col0 ) FROM tab1 AS cor0
----
-16
-51
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col1 * - cor0.col0 col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT + ( col2 ) * + col2 AS col2 FROM tab0 AS cor0
----
1
1089
6724

query I rowsort
SELECT DISTINCT - 80 * 55 FROM tab2 AS cor0
----
-4400

query I rowsort
SELECT ALL - ( - col1 ) * col0 + cor0.col2 AS col2 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT col0 + col2 * col1 AS col2 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT DISTINCT - cor0.col0 FROM tab0, tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1
----
-24
-35
-89

query I rowsort
SELECT + col1 + + 76 FROM tab1 AS cor0
----
102
86
89

query I rowsort
SELECT ALL - cor0.col1 + + col1 * col1 AS col1 FROM tab0 AS cor0
----
7310
8190
9312

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4753
SELECT ALL + CAST( col2 AS SIGNED ) * - col1 AS col2 FROM tab1 cor0
----
-1248
-1404
-570

skipif mysql # not compatible
query I rowsort label-4753
SELECT ALL + CAST ( col2 AS INTEGER ) * - col1 AS col2 FROM tab1 cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col2 + col0 + - col1 * - cor0.col2 col0 FROM tab0 AS cor0
----
15013
229
5700

query I rowsort
SELECT ( - col1 ) + cor0.col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4756
SELECT + - CAST( col2 AS SIGNED ) + - col1 * - ( col0 ) FROM tab0 AS cor0
----
2031
3394
8017

skipif mysql # not compatible
query I rowsort label-4756
SELECT + - CAST ( col2 AS INTEGER ) + - col1 * - ( col0 ) FROM tab0 AS cor0
----
2031
3394
8017

query I rowsort
SELECT DISTINCT col2 + 1 AS col0 FROM tab0
----
2
34
83

query I rowsort
SELECT - col0 + col2 * col1 AS col2 FROM tab1
----
1168
1401
506

query I rowsort
SELECT + - col1 + col2 + + col1 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT col0 * col0 + - cor0.col2 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT - + 36 * col0 FROM tab1 AS cor0
----
-108
-2304
-2880

query I rowsort
SELECT tab1.col2 + tab1.col0 FROM tab1
----
121
176
57

query I rowsort
SELECT + ( col2 ) * col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT DISTINCT 87 AS col0 FROM tab1, tab2 cor0
----
87

query I rowsort
SELECT DISTINCT - ( cor0.col1 ) AS col0 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT + cor0.col0 + 78 FROM tab2 AS cor0
----
156
157
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-4767
SELECT ALL - col2 DIV col1 + cor0.col1 AS col0 FROM tab2 AS cor0
----
15
31
59

skipif mysql # not compatible
query I rowsort label-4767
SELECT ALL - col2 / col1 + cor0.col1 AS col0 FROM tab2 AS cor0
----
15
31
59

query I rowsort
SELECT ALL 15 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

onlyif mysql # use DIV operator for integer division
query I rowsort label-4769
SELECT ALL - tab2.col1 DIV - ( col2 + + tab2.col1 ) AS col2 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4769
SELECT ALL - tab2.col1 / - ( col2 + + tab2.col1 ) AS col2 FROM tab2
----
0
0
0

query I rowsort
SELECT col1 * - 21 AS col1 FROM tab0
----
-1806
-1911
-2037

query I rowsort
SELECT - col0 * col1 * col2 AS col0 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT + + 93 + - col0 * + col1 FROM tab0 AS cor0
----
-1971
-3302
-8006

onlyif mysql # use DIV operator for integer division
query I rowsort label-4773
SELECT + - 71 DIV - cor0.col0 FROM tab0 AS cor0
----
0
2
2

skipif mysql # not compatible
query I rowsort label-4773
SELECT + - 71 / - cor0.col0 FROM tab0 AS cor0
----
0
2
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4774
SELECT CAST( NULL AS DECIMAL ) AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-4774
SELECT CAST ( NULL AS REAL ) AS col1 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # use DIV operator for integer division
query I rowsort label-4775
SELECT col1 DIV col1 + + col2 AS col2 FROM tab0 cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-4775
SELECT col1 / col1 + + col2 AS col2 FROM tab0 cor0
----
2
34
83

query I rowsort
SELECT - + 91 + col0 + + col1 AS col2 FROM tab0 AS cor0
----
19
41
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-4777
SELECT + + 49 DIV - col0 + + col1 + 69 * cor0.col1 FROM tab1 AS cor0
----
1804
700
910

skipif mysql # not compatible
query I rowsort label-4777
SELECT + + 49 / - col0 + + col1 + 69 * cor0.col1 FROM tab1 AS cor0
----
1804
700
910

query I rowsort
SELECT + col0 + - 63 * - col1 AS col1 FROM tab2 AS cor0
----
1150
1960
3795

query I rowsort
SELECT ALL col0 * + 79 + col2 * - col0 FROM tab1
----
-1360
1408
75

query I rowsort
SELECT - + col0 + + ( - 85 * col0 ) AS col0 FROM tab0 AS cor0
----
-2064
-3010
-7654

query I rowsort
SELECT + - col0 * - ( cor0.col1 ) FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - col0 * - col1 + col0 FROM tab1 AS cor0
----
1120
704
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-4783
SELECT col2 + - col0 * col0 DIV + col1 col0 FROM tab2 AS cor0
----
-329
-77
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4783
SELECT col2 + - col0 * col0 / + col1 col0 FROM tab2 AS cor0
----
-329
-77
26

query I rowsort
SELECT DISTINCT + col2 + 51 AS col1 FROM tab2
----
77
78
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4785
SELECT + tab1.col2 * CAST( - col1 + col1 AS SIGNED ) FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4785
SELECT + tab1.col2 * CAST ( - col1 + col1 AS INTEGER ) FROM tab1
----
0
0
0

query I rowsort
SELECT ALL + col1 * - 89 + col0 AS col1 FROM tab0 AS cor0
----
-7630
-8010
-8598

query I rowsort
SELECT ALL col2 + ( + 70 ) * + col1 * cor0.col2 - col2 * - col1 * cor0.col2 AS col1 FROM tab0 AS cor0
----
1134306
292347
6888

query I rowsort
SELECT DISTINCT + col2 * 75 AS col1 FROM tab0 AS cor0
----
2475
6150
75

query I rowsort
SELECT DISTINCT + col1 * - 36 + col1 * - cor0.col2 - + col1 * col2 AS col0 FROM tab1 AS cor0
----
-1500
-2964
-3744

query I rowsort
SELECT + cor0.col1 * ( + 62 ) + col2 AS col1 FROM tab0 AS cor0
----
5365
5724
6015

query I rowsort
SELECT + + col1 - - col1 AS col0 FROM tab1 AS cor0
----
20
26
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 * ( - 51 ) + col2 + - col0 col1 FROM tab1 cor0
----
-102
-3271
-4064

query I rowsort
SELECT col2 * col2 + 53 AS col1 FROM tab1 AS cor0
----
2969
3302
9269

query I rowsort
SELECT + - col1 - - col0 AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT ALL - col1 * + 78 AS col2 FROM tab0 cor0
----
-6708
-7098
-7566

query I rowsort
SELECT DISTINCT - col0 + + col0 * 82 FROM tab0 AS cor0
----
1944
2835
7209

query I rowsort
SELECT DISTINCT + col0 + ( 25 ) AS col2 FROM tab0 AS cor0
----
114
49
60

query I rowsort
SELECT + col1 + col2 + + 76 FROM tab1 AS cor0
----
143
156
185

query I rowsort
SELECT ALL + + cor0.col2 - - col2 AS col2 FROM tab1 AS cor0
----
108
114
192

onlyif mysql # use DIV operator for integer division
query I rowsort label-4800
SELECT ALL - CAST( 21 AS SIGNED ) DIV col1 + 87 AS col0 FROM tab0 AS cor0
----
87
87
87

skipif mysql # not compatible
query I rowsort label-4800
SELECT ALL - CAST ( 21 AS INTEGER ) / col1 + 87 AS col0 FROM tab0 AS cor0
----
87
87
87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4801
SELECT + CAST( 45 AS SIGNED ) + col1 FROM tab1 AS cor0
----
55
58
71

skipif mysql # not compatible
query I rowsort label-4801
SELECT + CAST ( 45 AS INTEGER ) + col1 FROM tab1 AS cor0
----
55
58
71

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4802
SELECT DISTINCT - CAST( NULL AS SIGNED ) + col0 / cor0.col0 col0 FROM tab2 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4802
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + col0 / cor0.col0 col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - - col0 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT col0 * - ( col0 ) * col0 FROM tab0
----
-13824
-42875
-704969

query I rowsort
SELECT DISTINCT + col0 + - cor0.col2 * - col1 * + 12 AS col0 FROM tab2 cor0
----
10051
18486
7831

query I rowsort
SELECT DISTINCT - ( col0 ) + + 24 * 10 FROM tab0 AS cor0
----
151
205
216

query I rowsort
SELECT col0 - - col2 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT ALL 50 FROM tab1, tab1 cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

query I rowsort
SELECT DISTINCT - + 37 + col1 * - col1 FROM tab2 AS cor0
----
-326
-3518
-998

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * - cor0.col0 col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL col0 * cor0.col1 * col2 FROM tab0 cor0
----
3395
664118
68112

query I rowsort
SELECT ALL 39 * col0 * + ( - tab1.col1 + col2 ) FROM tab1
----
117312
258960
3276

query I rowsort
SELECT col2 * - ( col0 ) + col0 + + ( col1 ) FROM tab0 AS cor0
----
-682
-7118
97

query I rowsort
SELECT DISTINCT - + col1 * 53 + + ( col2 ) FROM tab2 AS cor0
----
-1616
-3101
-863

query I rowsort
SELECT ALL 65 * tab0.col1 FROM tab0
----
5590
5915
6305

query I rowsort
SELECT ALL + 79 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 4857f2e1b1dbd184de4827f145dd02a1

query I rowsort
SELECT ( + 21 ) AS col1 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 312c166f4dc412730c43555105b1f44b

onlyif mysql # use DIV operator for integer division
query I rowsort label-4818
SELECT ( col2 ) * col2 + 44 * tab0.col0 DIV CAST( - col0 AS SIGNED ) - - col1 AS col2 FROM tab0
----
1131
54
6771

skipif mysql # not compatible
query I rowsort label-4818
SELECT ( col2 ) * col2 + 44 * tab0.col0 / CAST ( - col0 AS INTEGER ) - - col1 AS col2 FROM tab0
----
1131
54
6771

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4819
SELECT DISTINCT tab1.col2 + col1 * + ( + ( - col1 ) ) - - CAST( NULL AS SIGNED ) AS col1 FROM tab1
----
NULL

skipif mysql # not compatible
query I rowsort label-4819
SELECT DISTINCT tab1.col2 + col1 * + ( + ( - col1 ) ) - - CAST ( NULL AS INTEGER ) AS col1 FROM tab1
----
NULL

query I rowsort
SELECT DISTINCT + col2 * col1 * 18 - tab2.col0 AS col0 FROM tab2
----
11549
15059
27534

query I rowsort
SELECT ALL + 1 * - col2 - - col0 AS col0 FROM tab0
----
-9
34
7

query I rowsort
SELECT DISTINCT + col1 * col0 - ( + col2 * - col2 ) FROM tab2
----
2787
5278
946

onlyif mysql # use DIV operator for integer division
query I rowsort label-4823
SELECT 81 DIV - ( col0 ) FROM tab1 AS cor0
----
-1
-1
-27

skipif mysql # not compatible
query I rowsort label-4823
SELECT 81 / - ( col0 ) FROM tab1 AS cor0
----
-1
-1
-27

query I rowsort
SELECT ALL - col1 * 14 FROM tab0 AS cor0
----
-1204
-1274
-1358

query I rowsort
SELECT DISTINCT - ( - 26 ) + - col0 + - ( + cor0.col1 * col1 + col0 ) FROM tab0 AS cor0
----
-7418
-8433
-9453

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4826
SELECT DISTINCT + - CAST( + col2 AS SIGNED ) + col0 * cor0.col0 AS col2 FROM tab2 AS cor0
----
22
6058
6203

skipif mysql # not compatible
query I rowsort label-4826
SELECT DISTINCT + - CAST ( + col2 AS INTEGER ) + col0 * cor0.col0 AS col2 FROM tab2 AS cor0
----
22
6058
6203

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 ( - cor0.col0 ) AS col2 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4829
SELECT DISTINCT CAST( NULL AS SIGNED ) * 47 + - col2 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4829
SELECT DISTINCT CAST ( NULL AS INTEGER ) * 47 + - col2 AS col1 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + 63 * col1 FROM tab0 AS cor0
----
5418
5733
6111

onlyif mysql # use DIV operator for integer division
query I rowsort label-4831
SELECT + + cor0.col2 DIV + 32 FROM tab1 cor0
----
1
1
3

skipif mysql # not compatible
query I rowsort label-4831
SELECT + + cor0.col2 / + 32 FROM tab1 cor0
----
1
1
3

query I rowsort
SELECT - + tab0.col0 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

onlyif mysql # use DIV operator for integer division
query I rowsort label-4833
SELECT col0 DIV col1 + + col2 AS col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-4833
SELECT col0 / col1 + + col2 AS col2 FROM tab0
----
1
33
82

query I rowsort
SELECT + col1 + - 32 FROM tab0
----
54
59
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-4835
SELECT col2 + + col2 DIV + col1 AS col1 FROM tab2
----
26
27
40

skipif mysql # not compatible
query I rowsort label-4835
SELECT col2 + + col2 / + col1 AS col1 FROM tab2
----
26
27
40

query I rowsort
SELECT DISTINCT ( - col0 ) * - col0 AS col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT - cor0.col1 AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT DISTINCT - + cor0.col2 * + col1 AS col1 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL col2 * col2 + + 84 + - col1 FROM tab1 AS cor0
----
2974
3323
9287

query I rowsort
SELECT ALL col1 * col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-4841
SELECT - cor0.col0 DIV CAST( + col0 AS SIGNED ) + + col2 AS col1 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-4841
SELECT - cor0.col0 / CAST ( + col0 AS INTEGER ) + + col2 AS col1 FROM tab1 AS cor0
----
53
56
95

onlyif mysql # use DIV operator for integer division
query I rowsort label-4842
SELECT DISTINCT - - cor0.col0 DIV 53 FROM tab2 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-4842
SELECT DISTINCT - - cor0.col0 / 53 FROM tab2 AS cor0
----
0
1

query I rowsort
SELECT ALL + cor0.col2 * + col0 + ( - col1 ) FROM tab0 AS cor0
----
-62
706
7207

query I rowsort
SELECT DISTINCT - col1 * 94 FROM tab2 AS cor0
----
-1598
-2914
-5546

query I rowsort
SELECT ALL - col2 * + col2 + - 61 AS col0 FROM tab2 AS cor0
----
-1505
-737
-790

query I rowsort
SELECT ALL 25 * col0 * ( col2 ) + col0 * + 12 AS col1 FROM tab1
----
192960
4086
91968

query I rowsort
SELECT DISTINCT - 60 + - col2 AS col2 FROM tab1
----
-114
-117
-156

onlyif mysql # use DIV operator for integer division
query I rowsort label-4848
SELECT + tab2.col0 + col0 DIV + 40 col0 FROM tab2
----
7
79
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4848
SELECT + tab2.col0 + col0 / + 40 col0 FROM tab2
----
7
79
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-4849
SELECT col1 DIV + col0 + col0 + col1 AS col1 FROM tab0
----
113
134
181

skipif mysql # not compatible
query I rowsort label-4849
SELECT col1 / + col0 + col0 + col1 AS col1 FROM tab0
----
113
134
181

onlyif mysql # use DIV operator for integer division
query I rowsort label-4850
SELECT DISTINCT + 67 DIV + col1 + tab0.col2 * col2 FROM tab0
----
1
1089
6724

skipif mysql # not compatible
query I rowsort label-4850
SELECT DISTINCT + 67 / + col1 + tab0.col2 * col2 FROM tab0
----
1
1089
6724

onlyif mysql # use DIV operator for integer division
query I rowsort label-4851
SELECT DISTINCT - - col0 DIV col1 + - ( col2 ) * col0 * - col1 FROM tab2 AS cor0
----
119653
51038
5859

skipif mysql # not compatible
query I rowsort label-4851
SELECT DISTINCT - - col0 / col1 + - ( col2 ) * col0 * - col1 FROM tab2 AS cor0
----
119653
51038
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-4852
SELECT col0 + + 67 * col2 DIV - cor0.col1 AS col0 FROM tab0 cor0
----
-1
29
35

skipif mysql # not compatible
query I rowsort label-4852
SELECT col0 + + 67 * col2 / - cor0.col1 AS col0 FROM tab0 cor0
----
-1
29
35

query I rowsort
SELECT ALL + + col0 + - 7 AS col2 FROM tab2 AS cor0
----
0
71
72

query I rowsort
SELECT + - cor0.col0 + + 48 AS col1 FROM tab1 AS cor0
----
-16
-32
45

query I rowsort
SELECT DISTINCT - cor0.col1 + col0 * ( + col0 ) FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT ALL + col0 * - 78 FROM tab0 AS cor0
----
-1872
-2730
-6942

query I rowsort
SELECT - - col2 + 31 * cor0.col0 + + col2 * 84 AS col2 FROM tab2 AS cor0
----
2512
4628
5679

onlyif mysql # use DIV operator for integer division
query I rowsort label-4858
SELECT ALL - col1 * + col1 + col1 DIV col1 AS col0 FROM tab2 AS cor0
----
-288
-3480
-960

skipif mysql # not compatible
query I rowsort label-4858
SELECT ALL - col1 * + col1 + col1 / col1 AS col0 FROM tab2 AS cor0
----
-288
-3480
-960

query I rowsort
SELECT 91 + + 15 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to e3a970c661a05070afa8a3ed8dca742e

query I rowsort
SELECT 5 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 6797d40099023779b89feb627d94a3e7

onlyif mysql # use DIV operator for integer division
query I rowsort label-4861
SELECT DISTINCT + col2 + - cor0.col0 DIV - col1 FROM tab1 cor0
----
102
54
63

skipif mysql # not compatible
query I rowsort label-4861
SELECT DISTINCT + col2 + - cor0.col0 / - col1 FROM tab1 cor0
----
102
54
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4862
SELECT ALL + col0 + + CAST( NULL AS SIGNED ) / - 87 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4862
SELECT ALL + col0 + + CAST ( NULL AS INTEGER ) / - 87 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 * 88 * col2 AS col2 FROM tab1
----
109824
123552
50160

query I rowsort
SELECT DISTINCT + - 39 AS col0 FROM tab0, tab0 AS cor0
----
-39

query I rowsort
SELECT tab1.col0 * col2 * - col0 FROM tab1
----
-233472
-486
-614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + 66 ) col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT 75 * 87 FROM tab1, tab2, tab0 AS cor0, tab0
----
81 values hashing to 036f7975d9fc1eae2dc8b6fab252d5e6

query I rowsort
SELECT ALL - col0 * ( cor0.col0 ) + - 34 AS col0 FROM tab0 AS cor0
----
-1259
-610
-7955

onlyif mysql # use DIV operator for integer division
query I rowsort label-4869
SELECT DISTINCT + col0 DIV col1 + + col0 - cor0.col2 col0 FROM tab1 AS cor0
----
-10
-51
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4869
SELECT DISTINCT + col0 / col1 + + col0 - cor0.col2 col0 FROM tab1 AS cor0
----
-10
-51
13

query I rowsort
SELECT DISTINCT + ( - col2 ) * + col0 + ( - 31 ) AS col1 FROM tab2 AS cor0
----
-2059
-220
-3033

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * - col2 + - col1 col2 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT + tab2.col0 AS col0 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT - 86 + + 34 * + cor0.col2 AS col1 FROM tab2 AS cor0
----
1206
798
832

query I rowsort
SELECT + col1 + + 59 AS col1 FROM tab0 AS cor0
----
145
150
156

query I rowsort
SELECT + - col1 + 22 FROM tab2 AS cor0
----
-37
-9
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 9 * col2 col1 FROM tab1 AS cor0
----
486
513
864

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 35 - col0 col0 FROM tab0 AS cor0
----
-54
0
11

query I rowsort
SELECT + col1 + + tab0.col1 + 88 * + col2 FROM tab0
----
282
3076
7398

query I rowsort
SELECT + col1 * col0 - - col1 FROM tab0 AS cor0
----
2150
3492
8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - col2 col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - + 47 + col0 FROM tab1 AS cor0
----
-44
17
33

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4882
SELECT ( col1 ) - CAST( - col1 + - col1 AS SIGNED ) col2 FROM tab0 AS cor0
----
258
273
291

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4882
SELECT ( col1 ) - CAST ( - col1 + - col1 AS INTEGER ) col2 FROM tab0 AS cor0
----
258
273
291

onlyif mysql # use DIV operator for integer division
query I rowsort label-4883
SELECT - cor0.col1 + - col2 DIV 60 AS col2 FROM tab1 AS cor0
----
-10
-14
-26

skipif mysql # not compatible
query I rowsort label-4883
SELECT - cor0.col1 + - col2 / 60 AS col2 FROM tab1 AS cor0
----
-10
-14
-26

query I rowsort
SELECT DISTINCT + + col0 * cor0.col0 AS col2 FROM tab2 AS cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-4885
SELECT + - col0 * - col2 - ( 25 ) DIV + cor0.col1 AS col1 FROM tab1 AS cor0
----
162
3646
7679

skipif mysql # not compatible
query I rowsort label-4885
SELECT + - col0 * - col2 - ( 25 ) / + cor0.col1 AS col1 FROM tab1 AS cor0
----
162
3646
7679

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4886
SELECT DISTINCT - col0 * col1 * CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4886
SELECT DISTINCT - col0 * col1 * CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4887
SELECT ALL - col0 * - col2 + CAST( NULL AS SIGNED ) * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4887
SELECT ALL - col0 * - col2 + CAST ( NULL AS INTEGER ) * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 + + col2 * ( - col0 ) AS col2 FROM tab1 AS cor0
----
-136
-3638
-7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-4889
SELECT DISTINCT + + col2 * col1 DIV + 95 - 31 AS col1 FROM tab1 AS cor0
----
-17
-18
-25

skipif mysql # not compatible
query I rowsort label-4889
SELECT DISTINCT + + col2 * col1 / + 95 - 31 AS col1 FROM tab1 AS cor0
----
-17
-18
-25

query I rowsort
SELECT DISTINCT - col0 + ( 57 ) AS col0 FROM tab2 AS cor0
----
-21
-22
50

skipif mysql # not compatible
query I rowsort
SELECT col1 * CAST ( - col2 AS REAL ) FROM tab0 cor0
----
-2838
-7462
-97

query I rowsort
SELECT + cor0.col1 * - col1 * col2 + + cor0.col0 AS col0 FROM tab1 AS cor0
----
-16144
-36501
-5636

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + col1 * ( col2 ) * - col0 col2 FROM tab0 AS cor0
----
-3396
-664200
-68145

query I rowsort
SELECT + + cor0.col0 + - col2 * 91 FROM tab2 AS cor0
----
-2288
-2450
-3379

query I rowsort
SELECT ( col2 + + col2 ) FROM tab2
----
52
54
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-4896
SELECT ALL - col1 * + col1 * col0 + - 84 DIV col1 AS col1 FROM tab2 AS cor0
----
-22835
-271519
-6729

skipif mysql # not compatible
query I rowsort label-4896
SELECT ALL - col1 * + col1 * col0 + - 84 / col1 AS col1 FROM tab2 AS cor0
----
-22835
-271519
-6729

query I rowsort
SELECT - cor0.col0 * cor0.col2 * - col0 + col2 AS col0 FROM tab0 AS cor0
----
1226
19041
649604

query I rowsort
SELECT DISTINCT + 72 * - cor0.col1 FROM tab0 AS cor0
----
-6192
-6552
-6984

onlyif mysql # use DIV operator for integer division
query I rowsort label-4899
SELECT + cor0.col2 DIV + 54 + col0 * col2 AS col0 FROM tab0 cor0
----
35
7299
792

skipif mysql # not compatible
query I rowsort label-4899
SELECT + cor0.col2 / + 54 + col0 * col2 AS col0 FROM tab0 cor0
----
35
7299
792

query I rowsort
SELECT ( 46 ) AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 31818c9d4d325eb248735c97cb1dce39

query I rowsort
SELECT DISTINCT col2 * tab0.col0 + - 59 AS col2 FROM tab0
----
-24
7239
733

query I rowsort
SELECT + tab0.col2 + - 52 * cor0.col2 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to c9c9d3671b2b6417af1f84eac8bc5aa3

query I rowsort
SELECT ALL cor2.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 05835f29dd9cd4fa16889de54dec3cb6

query I rowsort
SELECT DISTINCT 29 - col0 FROM tab2
----
-49
-50
22

query I rowsort
SELECT - + 2 + col0 AS col0 FROM tab2 AS cor0
----
5
76
77

query I rowsort
SELECT DISTINCT 54 AS col0 FROM tab1, tab1 AS cor0
----
54

query I rowsort
SELECT - ( + col2 ) * col1 AS col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + cor0.col1 * 34 - col0 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-3308
-7238
722

query I rowsort
SELECT col1 * - 62 * cor0.col2 - col0 AS col0 FROM tab0 AS cor0
----
-175980
-462733
-6049

query I rowsort
SELECT + + 16 * + 90 - + col1 AS col1 FROM tab2 AS cor0
----
1381
1409
1423

query I rowsort
SELECT + col1 + + col1 * col2 AS col2 FROM tab2 AS cor0
----
1593
663
868

query I rowsort
SELECT ALL + 14 + - col1 * + col1 - ( - col0 ) AS col2 FROM tab1
----
-22
-659
-75

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab1 cor1, tab0 cor2
----
3645 values hashing to 64312dc66df177d8c745c63c0bdd4dc7

query I rowsort
SELECT ALL - 35 * - col0 FROM tab1 AS cor0
----
105
2240
2800

query I rowsort
SELECT ALL col0 * + col0 * + col2 + col1 AS col2 FROM tab0
----
1322
19094
649613

query I rowsort
SELECT + 37 * - col0 FROM tab2
----
-259
-2886
-2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * + col2 col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT + - ( - col1 ) + + col1 * 68 FROM tab1 AS cor0
----
1794
690
897

query I rowsort
SELECT ALL + - 28 * col1 FROM tab2 AS cor0
----
-1652
-476
-868

query I rowsort
SELECT ALL col0 * - ( 83 ) AS col2 FROM tab1
----
-249
-5312
-6640

onlyif mysql # use DIV operator for integer division
query I rowsort label-4921
SELECT + col1 DIV 42 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-4921
SELECT + col1 / 42 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4922
SELECT + + col0 + CAST( NULL AS SIGNED ) * + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-4922
SELECT + + col0 + CAST ( NULL AS INTEGER ) * + col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor1.col2 AS col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
26
27
38

query I rowsort
SELECT + col1 + - col0 * - cor0.col0 FROM tab0 cor0
----
1322
662
8012

onlyif mysql # use DIV operator for integer division
query I rowsort label-4925
SELECT DISTINCT - col2 DIV + col1 col0 FROM tab1 AS cor0
----
-2
-5
-7

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-4925
SELECT DISTINCT - col2 / + col1 col0 FROM tab1 AS cor0
----
-2
-5
-7

query I rowsort
SELECT ALL col2 * col0 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT + + col2 * 46 AS col0 FROM tab0 AS cor0
----
1518
3772
46

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 * col2 col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT - ( 86 ) * col0 AS col0 FROM tab0 AS cor0
----
-2064
-3010
-7654

query I rowsort
SELECT 60 + + col2 * col1 AS col0 FROM tab0 AS cor0
----
157
2898
7522

query I rowsort
SELECT ALL 1 + - col1 AS col1 FROM tab1 AS cor0
----
-12
-25
-9

query I rowsort
SELECT DISTINCT + + col2 * + cor0.col0 AS col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-4933
SELECT ALL + col1 DIV + col2 + col2 - - col1 AS col2 FROM tab0 AS cor0
----
121
174
195

skipif mysql # not compatible
query I rowsort label-4933
SELECT ALL + col1 / + col2 + col2 - - col1 AS col2 FROM tab0 AS cor0
----
121
174
195

query I rowsort
SELECT ALL - cor0.col0 * 41 FROM tab1 AS cor0
----
-123
-2624
-3280

query I rowsort
SELECT col1 * - ( col0 * col2 ) AS col0 FROM tab1 AS cor0
----
-36480
-4212
-99840

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4936
SELECT DISTINCT + CAST( NULL AS SIGNED ) AS col0 FROM tab0, tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-4936
SELECT DISTINCT + CAST ( NULL AS INTEGER ) AS col0 FROM tab0, tab2 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-4937
SELECT + col2 DIV - col1 + tab1.col2 FROM tab1
----
52
52
89

skipif mysql # not compatible
query I rowsort label-4937
SELECT + col2 / - col1 + tab1.col2 FROM tab1
----
52
52
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 63 col2 FROM tab2 AS cor0
----
-63
-63
-63

query I rowsort
SELECT ALL + cor0.col2 * col1 + - col2 * col1 FROM tab1 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4940
SELECT + + col1 * - cor0.col2 + cor0.col2 DIV col1 FROM tab1 AS cor0
----
-1241
-1402
-565

skipif mysql # not compatible
query I rowsort label-4940
SELECT + + col1 * - cor0.col2 + cor0.col2 / col1 FROM tab1 AS cor0
----
-1241
-1402
-565

query I rowsort
SELECT + col2 + - col1 * + col2 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT DISTINCT + + col2 * + col2 + cor0.col1 * cor0.col1 AS col0 FROM tab2 AS cor0
----
1690
1733
4157

query I rowsort
SELECT col0 FROM tab2 WHERE NOT ( NOT NULL IN ( col2 ) ) AND NULL IN ( + col0 )
----

query I rowsort
SELECT - 78 * - col2 FROM tab0 AS cor0
----
2574
6396
78

query I rowsort
SELECT DISTINCT + col2 + - cor0.col1 * - col1 AS col0 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT ALL + col2 * - col0 + cor0.col2 AS col2 FROM tab2 cor0
----
-162
-2002
-2964

query I rowsort
SELECT col0 * + col2 + col1 FROM tab1 AS cor0
----
188
3658
7693

query I rowsort
SELECT ALL + + cor0.col0 + col1 * + col2 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT - - col1 + col0 * + cor0.col2 FROM tab1 AS cor0
----
188
3658
7693

onlyif mysql # use DIV operator for integer division
query I rowsort label-4950
SELECT ALL - col0 DIV - col2 + + col0 FROM tab0 cor0
----
24
70
90

skipif mysql # not compatible
query I rowsort label-4950
SELECT ALL - col0 / - col2 + + col0 FROM tab0 cor0
----
24
70
90

query I rowsort
SELECT DISTINCT + col0 + col0 * - col1 AS col2 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL + - col0 * - col1 - + col0 AS col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT ALL - - cor0.col1 + - col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 + + col1 * + cor0.col2 * col0 AS col0 FROM tab2 AS cor0
----
119711
51051
5890

query I rowsort
SELECT - col1 * cor0.col0 + col2 AS col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT DISTINCT + 64 * col0 FROM tab2 AS cor0
----
448
4992
5056

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-4958
SELECT DISTINCT - 83 DIV + col2 FROM tab0 AS cor0
----
-1
-2
-83

skipif mysql # not compatible
query I rowsort label-4958
SELECT DISTINCT - 83 / + col2 FROM tab0 AS cor0
----
-1
-2
-83

query I rowsort
SELECT - ( 56 ) * + col0 + col0 + col1 FROM tab1 cor0
----
-139
-3510
-4387

query I rowsort
SELECT ALL col2 * + 56 AS col2 FROM tab2 AS cor0
----
1456
1512
2128

query I rowsort
SELECT ALL cor0.col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL ( - 23 ) AS col2 FROM tab0 AS cor0
----
-23
-23
-23

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-4963
SELECT ALL CAST( + col0 AS SIGNED ) * - col1 FROM tab1 AS cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-4963
SELECT ALL CAST ( + col0 AS INTEGER ) * - col1 FROM tab1 AS cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 18 * col2 + + tab2.col0 * - col1 + tab2.col2 * col0 col2 FROM tab2
----
-2106
2343
458

query I rowsort
SELECT col0 * + tab1.col1 * + col2 + col1 AS col1 FROM tab1
----
36490
4238
99853

query I rowsort
SELECT 50 + + 86 * col1 FROM tab2
----
1512
2716
5124

onlyif mysql # use DIV operator for integer division
query I rowsort label-4967
SELECT + tab1.col2 DIV - col0 AS col0 FROM tab1
----
-1
-18
0

skipif mysql # not compatible
query I rowsort label-4967
SELECT + tab1.col2 / - col0 AS col0 FROM tab1
----
-1
-18
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-4968
SELECT col0 + + col1 DIV cor0.col1 AS col0 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-4968
SELECT col0 + + col1 / cor0.col1 AS col0 FROM tab2 AS cor0
----
79
8
80

query I rowsort
SELECT DISTINCT - + col0 * col1 + + col1 - + col2 FROM tab1 AS cor0
----
-106
-1123
-687

query I rowsort
SELECT DISTINCT - col1 - col0 AS col2 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT DISTINCT 76 * col2 + - col0 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
2241
4004
5890

query I rowsort
SELECT + col1 + col2 * + col1 * col0 AS col2 FROM tab2 AS cor0
----
119711
51051
5890

query I rowsort
SELECT col1 + + 23 * - tab2.col1 + col2 AS col0 FROM tab2
----
-1272
-336
-655

onlyif mysql # use DIV operator for integer division
query I rowsort label-4974
SELECT DISTINCT col0 DIV tab0.col0 + col0 FROM tab0
----
25
36
90

skipif mysql # not compatible
query I rowsort label-4974
SELECT DISTINCT col0 / tab0.col0 + col0 FROM tab0
----
25
36
90

query I rowsort
SELECT ALL + col2 + col2 * + col1 * + col2 FROM tab1
----
119904
32547
75870

query I rowsort
SELECT DISTINCT 94 + col1 FROM tab2
----
111
125
153

query I rowsort
SELECT - col0 - + col0 * + col0 AS col0 FROM tab0
----
-1260
-600
-8010

query I rowsort
SELECT DISTINCT ( - col0 ) + tab1.col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT 13 * col2 * col2 FROM tab2
----
18772
8788
9477

query I rowsort
SELECT col0 AS col0 FROM tab2 AS cor0 WHERE ( col2 ) <= ( NULL )
----

query I rowsort
SELECT ALL col2 * col1 + + col1 AS col0 FROM tab2
----
1593
663
868

query I rowsort
SELECT DISTINCT + col0 + col2 * - col0 + col0 AS col2 FROM tab2
----
-175
-1872
-2844

query I rowsort
SELECT cor0.col0 * col1 FROM tab1 AS cor0 WHERE NOT ( cor0.col2 ) < col0
----
1040
78

query I rowsort
SELECT tab1.col0 FROM tab1 WHERE NULL NOT IN ( - tab1.col0 + col1 )
----

query III rowsort
SELECT ALL * FROM tab1 WHERE + col2 * - col0 BETWEEN ( - col2 + col0 ) AND ( NULL )
----

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL < - col0
----

query I rowsort
SELECT ALL + col0 + + col2 AS col1 FROM tab0 WHERE NOT + tab0.col0 IN ( col0 )
----

query I rowsort
SELECT ALL - col2 + - col0 * + col1 AS col1 FROM tab2
----
-1381
-244
-4628

query I rowsort
SELECT ALL tab1.col1 + col1 FROM tab1
----
20
26
52

query I rowsort
SELECT tab1.col0 AS col0 FROM tab1 WHERE col1 NOT BETWEEN - col2 AND col2
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-4991
SELECT col0 * cor0.col1 * + cor0.col0 + + col0 DIV col0 - + col1 AS col2 FROM tab2 cor0
----
106081
1489
358898

skipif mysql # not compatible
query I rowsort label-4991
SELECT col0 * cor0.col1 * + cor0.col0 + + col0 / col0 - + col1 AS col2 FROM tab2 cor0
----
106081
1489
358898

query I rowsort
SELECT col2 * col0 + col1 FROM tab2
----
2087
220
3019

onlyif mysql # use DIV operator for integer division
query I rowsort label-4993
SELECT ALL - col0 + + col1 DIV + col1 FROM tab2
----
-6
-77
-78

skipif mysql # not compatible
query I rowsort label-4993
SELECT ALL - col0 + + col1 / + col1 FROM tab2
----
-6
-77
-78

query I rowsort
SELECT col1 * col0 * col2 + tab0.col0 FROM tab0
----
3430
664207
68136

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + col2 col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT tab1.col1 * tab1.col1 FROM tab1
----
100
169
676

query IIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 WHERE ( NULL ) <> NULL
----

query I rowsort
SELECT + col2 + + col1 * col1 FROM tab0
----
7429
8363
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-4999
SELECT col1 + tab0.col1 * col0 DIV col0 AS col0 FROM tab0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-4999
SELECT col1 + tab0.col1 * col0 / col0 AS col0 FROM tab0
----
172
182
194

query I rowsort
SELECT - cor0.col0 * - cor0.col1 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 WHERE NOT NULL <= ( NULL )
----

query I rowsort
SELECT col0 * tab0.col2 * + col0 AS col0 FROM tab0
----
1225
19008
649522

query I rowsort
SELECT + cor0.col0 FROM tab2 AS cor0 CROSS JOIN tab2
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT - col1 * col0 * cor0.col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + + cor0.col1 col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL cor0.col2 * - col1 * + col2 FROM tab0 AS cor0
----
-611884
-93654
-97

query I rowsort
SELECT DISTINCT + + cor0.col0 * - col0 FROM tab1 AS cor0
----
-4096
-6400
-9

query I rowsort
SELECT ALL - col1 * + col1 + + col0 * - col0 AS col0 FROM tab1 AS cor0
----
-4196
-6569
-685

query I rowsort
SELECT DISTINCT col0 + + col2 AS col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT DISTINCT + - col1 + col0 FROM tab0 cor0
----
-2
-62

query I rowsort
SELECT DISTINCT col1 - - tab0.col2 * + col1 * - col1 FROM tab0
----
-243982
-678951
-9312

query I rowsort
SELECT DISTINCT col0 * col1 - 50 FROM tab1
----
28
590
990

query I rowsort
SELECT col2 * - ( - col1 ) + - col0 * - col0 AS col1 FROM tab1 cor0
----
1413
4666
7648

query I rowsort
SELECT col2 * ( col1 ) AS col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT - col0 + col2 + 6 FROM tab1
----
-1
22
57

query I rowsort
SELECT ALL col2 - + col1 * + col1 FROM tab0 cor0
----
-7363
-8199
-9408

query I rowsort
SELECT ALL - col2 * + ( - col2 * col2 ) FROM tab1 AS cor0
----
157464
185193
884736

onlyif mysql # use DIV operator for integer division
query I rowsort label-5017
SELECT + col2 DIV + col1 - col2 AS col2 FROM tab2 AS cor0
----
-26
-27
-36

skipif mysql # not compatible
query I rowsort label-5017
SELECT + col2 / + col1 - col2 AS col2 FROM tab2 AS cor0
----
-26
-27
-36

query I rowsort
SELECT DISTINCT - + ( col2 ) * - col1 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - + col0 - 72 FROM tab0 AS cor0
----
-107
-161
-96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5020
SELECT ALL CAST( NULL AS SIGNED ) * + col1 + col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5020
SELECT ALL CAST ( NULL AS INTEGER ) * + col1 + col1 AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 11 * - 31 AS col0 FROM tab2 AS cor0
----
-341
-341
-341

query I rowsort
SELECT DISTINCT + col2 * - 57 * col0 - + col0 * - col1 * col2 FROM tab0 AS cor0
----
1400
22968
248132

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 12 col1 FROM tab1 AS cor0
----
-12

query I rowsort
SELECT ALL - + 34 + col2 AS col2 FROM tab0 AS cor0
----
-1
-33
48

query I rowsort
SELECT - 70 * - cor0.col1 + - col1 * - col2 AS col1 FROM tab0 AS cor0
----
13832
6887
8858

query I rowsort
SELECT ALL col0 * - 83 + + cor0.col2 + - cor0.col2 FROM tab2 AS cor0
----
-581
-6474
-6557

query I rowsort
SELECT ALL + - 24 - 81 FROM tab0 cor0
----
-105
-105
-105

query I rowsort
SELECT ALL + - col2 * ( - cor0.col2 + 58 * col0 ) FROM tab2 AS cor0
----
-10233
-116948
-172672

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * + col1 col0 FROM tab1 AS cor0
----
-1040
-640
-78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5030
SELECT - + CAST( - col0 AS SIGNED ) + col0 AS col2 FROM tab2 AS cor0
----
14
156
158

skipif mysql # not compatible
query I rowsort label-5030
SELECT - + CAST ( - col0 AS INTEGER ) + col0 AS col2 FROM tab2 AS cor0
----
14
156
158

query I rowsort
SELECT DISTINCT + col1 * col2 + col2 AS col0 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT 8 + col1 * - cor0.col2 AS col0 FROM tab0 AS cor0
----
-2830
-7454
-89

query I rowsort
SELECT 94 * + col0 FROM tab1 AS cor0
----
282
6016
7520

query I rowsort
SELECT cor1.col0 AS col0 FROM tab0, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT ( 97 ) FROM tab1
----
97
97
97

query I rowsort
SELECT - col0 * - cor0.col2 AS col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT ALL - 65 * col0 + - col1 FROM tab2 AS cor0
----
-486
-5129
-5152

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 51 col0 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to d8bf0a05c9c4d2a93812d106baae4752

query I rowsort
SELECT DISTINCT - + col0 + - col2 * cor0.col2 FROM tab2 AS cor0
----
-1523
-736
-754

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5041
SELECT + cor0.col1 + CAST( NULL AS SIGNED ) + + 70 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5041
SELECT + cor0.col1 + CAST ( NULL AS INTEGER ) + + 70 FROM tab2, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + col0 * - col1 AS col1 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT + 86 * + tab0.col1 FROM tab0
----
7396
7826
8342

query I rowsort
SELECT cor0.col0 * tab1.col1 FROM tab1, tab1 AS cor0
----
9 values hashing to c7e3d87815c66f5a8360e4fe15424a79

query I rowsort
SELECT ALL + - cor0.col2 + - col2 FROM tab2 AS cor0
----
-52
-54
-76

onlyif mysql # use DIV operator for integer division
query I rowsort label-5046
SELECT - - col0 * col2 DIV 61 FROM tab0 AS cor0
----
0
119
12

skipif mysql # not compatible
query I rowsort label-5046
SELECT - - col0 * col2 / 61 FROM tab0 AS cor0
----
0
119
12

onlyif mysql # use DIV operator for integer division
query I rowsort label-5047
SELECT DISTINCT + - col0 + + col1 DIV - 37 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-5047
SELECT DISTINCT + - col0 + + col1 / - 37 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT + - col1 + + col0 + 73 FROM tab0 AS cor0
----
11
71

query I rowsort
SELECT ALL - col2 * - 16 + - col2 AS col2 FROM tab2 AS cor0
----
390
405
570

query I rowsort
SELECT - - col0 + 73 AS col2 FROM tab2 AS cor0
----
151
152
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5051
SELECT col2 DIV - ( - col2 ) FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5051
SELECT col2 / - ( - col2 ) FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL col0 + + col2 * + 50 FROM tab1 AS cor0
----
2703
2914
4880

query I rowsort
SELECT - cor0.col2 * + ( - col2 ) AS col0 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT - cor0.col1 AS col0 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
-17
-31
-59

query I rowsort
SELECT ALL 26 * tab2.col1 AS col2 FROM tab2
----
1534
442
806

onlyif mysql # use DIV operator for integer division
query I rowsort label-5056
SELECT col1 DIV - ( col2 ) + - tab1.col0 AS col1 FROM tab1
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-5056
SELECT col1 / - ( col2 ) + - tab1.col0 AS col1 FROM tab1
----
-3
-64
-80

query I rowsort
SELECT col0 - + 42 FROM tab0
----
-18
-7
47

query I rowsort
SELECT DISTINCT cor0.col1 * - 27 * + col1 FROM tab0 AS cor0
----
-199692
-223587
-254043

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5059
SELECT ALL - col0 + CAST( + col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-5059
SELECT ALL - col0 + CAST ( + col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT + - ( + col1 ) * col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT + 15 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to d1d280d38bf9c2d5d5ec90dd43aeaffd

query I rowsort
SELECT col2 * cor0.col2 + col2 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT ALL col0 + - col1 * - tab2.col1 AS col1 FROM tab2
----
3559
368
968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5064
SELECT + + CAST( NULL AS SIGNED ) + - 88 * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5064
SELECT + + CAST ( NULL AS INTEGER ) + - 88 * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + tab0.col1 + + col2 FROM tab0
----
119
173
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5066
SELECT ALL cor1.col2 DIV cor0.col2 AS col0 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to 31da090e991c26271830536e193d83f0

skipif mysql # not compatible
query I rowsort label-5066
SELECT ALL cor1.col2 / cor0.col2 AS col0 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to 31da090e991c26271830536e193d83f0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col1 col1 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

onlyif mysql # use DIV operator for integer division
query I rowsort label-5068
SELECT DISTINCT ( + col0 ) + col1 DIV col1 FROM tab2 AS cor0
----
79
8
80

skipif mysql # not compatible
query I rowsort label-5068
SELECT DISTINCT ( + col0 ) + col1 / col1 FROM tab2 AS cor0
----
79
8
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5069
SELECT ALL cor0.col0 DIV cor0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

skipif mysql # not compatible
query I rowsort label-5069
SELECT ALL cor0.col0 / cor0.col0 FROM tab0, tab0 AS cor0
----
9 values hashing to 001554c2952f1a80506b182ee04686f5

query I rowsort
SELECT 43 + col0 * col2 FROM tab0 AS cor0
----
7341
78
835

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 95 * - col1 col2 FROM tab0 AS cor0
----
8170
8645
9215

query I rowsort
SELECT DISTINCT + cor0.col2 * col0 + + 47 AS col2 FROM tab0 AS cor0
----
7345
82
839

query I rowsort
SELECT DISTINCT - col0 * + col1 + - 50 AS col0 FROM tab0 cor0
----
-2114
-3445
-8149

query I rowsort
SELECT + 82 + + col2 FROM tab0 AS cor0
----
115
164
83

query I rowsort
SELECT ALL ( 32 * + col1 ) + ( + ( col1 ) ) AS col2 FROM tab2
----
1023
1947
561

onlyif mysql # use DIV operator for integer division
query I rowsort label-5076
SELECT col2 + col1 DIV - col0 + + 67 FROM tab2
----
105
90
93

skipif mysql # not compatible
query I rowsort label-5076
SELECT col2 + col1 / - col0 + + 67 FROM tab2
----
105
90
93

query I rowsort
SELECT 5 * 55 FROM tab1
----
275
275
275

query I rowsort
SELECT ALL 71 * - col0 AS col2 FROM tab1 AS cor0
----
-213
-4544
-5680

query I rowsort
SELECT ALL tab2.col2 + col0 * - tab2.col2 * col2 AS col0 FROM tab2
----
-114038
-5076
-52702

query I rowsort
SELECT DISTINCT + ( col1 ) + - col1 FROM tab0
----
0

query I rowsort
SELECT cor0.col1 + tab0.col2 * 63 FROM tab0, tab0 AS cor0
----
9 values hashing to c3196767ed6a718c6c7c8821a13d57f6

query I rowsort
SELECT ALL + + col1 * - cor0.col1 FROM tab0 cor0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL col2 + col0 * - col0 AS col0 FROM tab2 AS cor0
----
-22
-6058
-6203

query I rowsort
SELECT DISTINCT + tab1.col1 + - 14 AS col1 FROM tab1, tab1 AS cor0
----
-1
-4
12

query I rowsort
SELECT - + col2 + col1 * - col0 AS col2 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT ALL - - col1 * col0 AS col0 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - 44 * - cor0.col1 FROM tab1 AS cor0
----
1144
440
572

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5088
SELECT DISTINCT - col0 / col0 + + CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5088
SELECT DISTINCT - col0 / col0 + + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT - tab0.col1 + ( col1 ) AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT + 11 AS col1 FROM tab0, tab1 AS cor0
----
11

query I rowsort
SELECT col0 + - cor0.col2 AS col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT ALL - col2 + + col1 * + col1 - + col0 AS col1 FROM tab1 cor0
----
-21
-7
619

query I rowsort
SELECT - cor1.col0 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 26e45cd9fe71a2b90a8bdef20c88e70d

query I rowsort
SELECT ALL + + col0 * - col1 + col2 AS col1 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT ALL col1 * ( col2 ) + - col2 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT DISTINCT - cor0.col1 FROM tab2, tab1 AS cor0, tab1 cor1
----
-10
-13
-26

query I rowsort
SELECT + + col2 * - col0 * - ( + col1 * cor0.col2 + - 75 ) AS col2 FROM tab2 AS cor0
----
144018
1714142
2958852

onlyif mysql # use DIV operator for integer division
query I rowsort label-5098
SELECT + + col2 + + cor0.col1 DIV col0 FROM tab2 cor0
----
26
31
38

skipif mysql # not compatible
query I rowsort label-5098
SELECT + + col2 + + cor0.col1 / col0 FROM tab2 cor0
----
26
31
38

query I rowsort
SELECT ALL + col1 * - col2 + - col0 FROM tab1 AS cor0
----
-1328
-1407
-634

onlyif mysql # use DIV operator for integer division
query I rowsort label-5100
SELECT col0 DIV 77 - + col0 FROM tab1 AS cor0
----
-3
-64
-79

skipif mysql # not compatible
query I rowsort label-5100
SELECT col0 / 77 - + col0 FROM tab1 AS cor0
----
-3
-64
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5101
SELECT ALL + CAST( NULL AS DECIMAL ) + 17 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5101
SELECT ALL + CAST ( NULL AS REAL ) + 17 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 - 59 * + col2 AS col2 FROM tab0 AS cor0
----
-1914
-4756
-58

query I rowsort
SELECT ( - 74 ) + + col1 * col2 FROM tab2 cor0
----
1460
572
763

query I rowsort
SELECT + 56 + - col2 FROM tab1 AS cor0
----
-1
-40
2

query I rowsort
SELECT ALL - cor0.col0 + - col1 * col0 AS col1 FROM tab2 AS cor0
----
-1422
-224
-4680

query I rowsort
SELECT - ( + col1 ) * col1 + - 96 FROM tab1 AS cor0
----
-196
-265
-772

query I rowsort
SELECT DISTINCT - cor0.col2 * + 3 FROM tab2 AS cor0
----
-114
-78
-81

query I rowsort
SELECT DISTINCT 42 * 84 FROM tab0 cor0
----
3528

query I rowsort
SELECT ALL + - col0 + - 6 AS col1 FROM tab1 AS cor0
----
-70
-86
-9

query I rowsort
SELECT ALL - col2 * col2 - + col1 AS col2 FROM tab1 AS cor0
----
-2942
-3259
-9229

query I rowsort
SELECT + ( - col1 ) - - col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + tab2.col1 + 76 FROM tab2, tab1, tab1 AS cor0
----
27 values hashing to cace3a4fc009363dbccc9c069aafcd82

query I rowsort
SELECT 99 * ( col2 ) * cor0.col2 - + col0 FROM tab1 AS cor0
----
288681
321587
912304

query I rowsort
SELECT ALL - 16 + col0 AS col0 FROM tab2 AS cor0
----
-9
62
63

query I rowsort
SELECT - cor0.col0 + + col1 * col0 AS col0 FROM tab2 cor0
----
1264
210
4524

query I rowsort
SELECT col1 + tab2.col0 + - tab2.col0 * - col1 AS col1 FROM tab2
----
1439
255
4739

query I rowsort
SELECT + col2 + + 68 * col0 FROM tab0 AS cor0
----
1665
2381
6134

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + col2 col1 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT + + col1 * col2 AS col0 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT col1 - - col0 * ( 41 ) AS col1 FROM tab1 AS cor0
----
149
2634
3293

query I rowsort
SELECT - col1 * col1 + + col2 AS col0 FROM tab0 cor0
----
-7363
-8199
-9408

onlyif mysql # use DIV operator for integer division
query I rowsort label-5122
SELECT 34 DIV 26 AS col0 FROM tab1
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5122
SELECT 34 / 26 AS col0 FROM tab1
----
1
1
1

query I rowsort
SELECT DISTINCT + 81 AS col0 FROM tab2, tab0 AS cor0
----
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5124
SELECT CAST( col0 AS SIGNED ) * - col2 col1 FROM tab0
----
-35
-7298
-792

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5124
SELECT CAST ( col0 AS INTEGER ) * - col2 col1 FROM tab0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5125
SELECT ALL col2 DIV + 26 FROM tab1 cor0
----
2
2
3

skipif mysql # not compatible
query I rowsort label-5125
SELECT ALL col2 / + 26 FROM tab1 cor0
----
2
2
3

query I rowsort
SELECT - col0 * col2 + - col0 AS col2 FROM tab2 cor0
----
-196
-2106
-3081

query I rowsort
SELECT - + col1 + col2 AS col0 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT + + col2 * + cor0.col0 + + cor0.col0 * col1 * cor0.col0 FROM tab0 AS cor0
----
118860
50328
728109

query I rowsort
SELECT 16 AS col1 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

query I rowsort
SELECT ALL - 8 AS col2 FROM tab0
----
-8
-8
-8

onlyif mysql # use DIV operator for integer division
query I rowsort label-5131
SELECT DISTINCT col1 DIV 32 AS col2 FROM tab0 AS cor0
----
2
3

skipif mysql # not compatible
query I rowsort label-5131
SELECT DISTINCT col1 / 32 AS col2 FROM tab0 AS cor0
----
2
3

query I rowsort
SELECT DISTINCT + col1 * ( + ( col1 ) ) AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT - col0 * col1 * col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5134
SELECT + + col1 * CAST( - ( col0 ) AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-5134
SELECT + + col1 * CAST ( - ( col0 ) AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + - 58 FROM tab0, tab2 AS cor0, tab2, tab1 AS cor1
----
81 values hashing to 897f42d096eff3935f4f50603850c23b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 12 col1 FROM tab1
----
12

query I rowsort
SELECT ALL + tab2.col0 * 66 - 30 FROM tab2
----
432
5118
5184

query I rowsort
SELECT + + cor0.col1 * col0 + col1 AS col2 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT col2 - 53 * 59 * + col2 FROM tab2 AS cor0
----
-118788
-81276
-84402

query I rowsort
SELECT ALL + col0 + + col0 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT + col0 * col0 - ( - col1 ) AS col2 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT DISTINCT col2 * 72 FROM tab0 AS cor0
----
2376
5904
72

onlyif mysql # use DIV operator for integer division
query I rowsort label-5143
SELECT ALL + col1 DIV col0 + + 45 FROM tab2 AS cor0
----
45
45
49

skipif mysql # not compatible
query I rowsort label-5143
SELECT ALL + col1 / col0 + + 45 FROM tab2 AS cor0
----
45
45
49

query I rowsort
SELECT ALL - - col0 + - 61 FROM tab1 AS cor0
----
-58
19
3

query I rowsort
SELECT ALL col2 * - tab0.col1 AS col0 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT - col0 + + tab1.col2 FROM tab1
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-5147
SELECT - col2 + col2 DIV col2 col1 FROM tab0
----
-32
-81
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5147
SELECT - col2 + col2 / col2 col1 FROM tab0
----
-32
-81
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5148
SELECT DISTINCT col2 DIV + tab0.col0 + col0 * - col2 FROM tab0
----
-35
-7298
-791

skipif mysql # not compatible
query I rowsort label-5148
SELECT DISTINCT col2 / + tab0.col0 + col0 * - col2 FROM tab0
----
-35
-7298
-791

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT + col2 * - col1 NOT IN ( + col1 )
----

query I rowsort
SELECT + col2 * + tab1.col0 - - col0 FROM tab1
----
165
3712
7760

query I rowsort
SELECT ALL + col1 + col1 * - col2 FROM tab2
----
-1475
-629
-806

query I rowsort
SELECT + col0 * col1 + tab0.col2 + - col0 FROM tab0
----
2073
3361
8092

query I rowsort
SELECT ALL - tab2.col0 * + col1 * - col1 AS col2 FROM tab2
----
22831
271518
6727

onlyif mysql # use DIV operator for integer division
query I rowsort label-5154
SELECT + col1 * col2 - col1 DIV + col1 AS col2 FROM tab0
----
2837
7461
96

skipif mysql # not compatible
query I rowsort label-5154
SELECT + col1 * col2 - col1 / + col1 AS col2 FROM tab0
----
2837
7461
96

query I rowsort
SELECT DISTINCT + col2 + - col1 * - col2 FROM tab1
----
1344
1458
627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 2 col2 FROM tab1 cor0
----
-2
-2
-2

query I rowsort
SELECT DISTINCT - - 21 + 10 FROM tab2, tab0 AS cor0
----
31

query I rowsort
SELECT DISTINCT col1 - col2 * tab1.col0 AS col0 FROM tab1
----
-136
-3638
-7667

query I rowsort
SELECT tab0.col2 - - col1 FROM tab0
----
119
173
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5160
SELECT ALL - 23 + col1 * + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5160
SELECT ALL - 23 + col1 * + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5161
SELECT + + cor0.col0 * - cor0.col1 + - col2 DIV - ( col2 ) FROM tab1 AS cor0
----
-1039
-639
-77

skipif mysql # not compatible
query I rowsort label-5161
SELECT + + cor0.col0 * - cor0.col1 + - col2 / - ( col2 ) FROM tab1 AS cor0
----
-1039
-639
-77

query I rowsort
SELECT + + 6 * col0 FROM tab1 AS cor0
----
18
384
480

query I rowsort
SELECT DISTINCT + - ( - tab0.col2 ) FROM tab0, tab2, tab1 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + + col1 * col1 * - col2 FROM tab1 AS cor0
----
-16224
-36504
-5700

query I rowsort
SELECT ALL + + 52 + col0 AS col1 FROM tab0 cor0
----
141
76
87

query I rowsort
SELECT - - 50 AS col2 FROM tab0 AS cor0
----
50
50
50

query I rowsort
SELECT DISTINCT + cor1.col1 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab1, tab1 AS cor2
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-5168
SELECT DISTINCT + - col1 DIV - col2 AS col2 FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-5168
SELECT DISTINCT + - col1 / - col2 AS col2 FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT - 81 AS col2 FROM tab1
----
-81
-81
-81

query I rowsort
SELECT - cor0.col2 + col0 * col2 AS col0 FROM tab2 cor0
----
162
2002
2964

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0, tab2 cor1, tab2, tab0 AS cor2
----
3645 values hashing to 5ec52b92c3c8d78cc0a61df3fc16f18b

query I rowsort
SELECT ALL - + col1 + + cor0.col1 AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 99 FROM tab2 AS cor0 CROSS JOIN tab0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to c841a8d826151b422ecdb71db0250739

onlyif mysql # use DIV operator for integer division
query I rowsort label-5174
SELECT col2 DIV - ( + 20 ) FROM tab0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-5174
SELECT col2 / - ( + 20 ) FROM tab0
----
-1
-4
0

query I rowsort
SELECT col1 * - 14 FROM tab0
----
-1204
-1274
-1358

query I rowsort
SELECT DISTINCT cor1.col1 AS col0 FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
17
31
59

query I rowsort
SELECT tab0.col0 + - 37 * + col0 FROM tab0
----
-1260
-3204
-864

onlyif mysql # use DIV operator for integer division
query I rowsort label-5178
SELECT ALL col0 + 65 * tab0.col2 DIV - col2 + col0 FROM tab0
----
-17
113
5

skipif mysql # not compatible
query I rowsort label-5178
SELECT ALL col0 + 65 * tab0.col2 / - col2 + col0 FROM tab0
----
-17
113
5

onlyif mysql # use DIV operator for integer division
query I rowsort label-5179
SELECT - ( + col1 ) DIV - col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-5179
SELECT - ( + col1 ) / - col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT - - 75 + col1 AS col1 FROM tab2 AS cor0
----
106
134
92

query I rowsort
SELECT - + ( ( col2 ) ) * + col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT ALL tab0.col1 + + 11 + tab0.col2 AS col2 FROM tab0, tab2 cor0, tab0 AS cor1
----
27 values hashing to 1e09f037afa6646191a69994a59e0653

query I rowsort
SELECT - col0 * 84 + + col1 AS col0 FROM tab0 AS cor0
----
-1930
-2843
-7385

query I rowsort
SELECT ALL - col2 * + cor0.col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT + col2 * + ( - cor0.col1 ) AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-5186
SELECT DISTINCT col1 DIV cor0.col0 FROM tab2 cor0
----
0
4

skipif mysql # not compatible
query I rowsort label-5186
SELECT DISTINCT col1 / cor0.col0 FROM tab2 cor0
----
0
4

query I rowsort
SELECT - col2 * + cor0.col0 AS col0 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT + + col2 * col0 + col0 FROM tab1 cor0
----
165
3712
7760

onlyif mysql # use DIV operator for integer division
query I rowsort label-5189
SELECT DISTINCT - col1 * 67 DIV + cor0.col1 FROM tab0 cor0
----
-67

skipif mysql # not compatible
query I rowsort label-5189
SELECT DISTINCT - col1 * 67 / + cor0.col1 FROM tab0 cor0
----
-67

query I rowsort
SELECT - col0 + - col1 * - 18 FROM tab2 AS cor0
----
227
551
984

query I rowsort
SELECT DISTINCT + - col1 * 31 FROM tab2 AS cor0
----
-1829
-527
-961

query I rowsort
SELECT DISTINCT - col2 * ( col0 + col1 ) FROM tab0 AS cor0
----
-132
-14760
-3630

query I rowsort
SELECT cor0.col0 AS col0 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT - 76 AS col1 FROM tab0
----
-76

query I rowsort
SELECT - col1 * cor0.col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT - col1 * - ( + cor0.col0 ) AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT + col0 * + col1 + + 84 FROM tab2
----
1427
301
4686

onlyif mysql # use DIV operator for integer division
query I rowsort label-5198
SELECT ALL col0 + col0 DIV - col2 col0 FROM tab0
----
0
24
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5198
SELECT ALL col0 + col0 / - col2 col0 FROM tab0
----
0
24
88

query I rowsort
SELECT - 41 AS col0 FROM tab0, tab2 cor0
----
9 values hashing to 4ba0c102091f9cbc9fe9439b04584e70

query I rowsort
SELECT DISTINCT - col1 * ( + col2 + col0 ) AS col0 FROM tab0
----
-15561
-3492
-4902

query I rowsort
SELECT + col2 - 86 FROM tab0 AS cor0
----
-4
-53
-85

query I rowsort
SELECT ALL - col2 * 67 FROM tab0
----
-2211
-5494
-67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 66 col0 FROM tab2, tab0 AS cor0, tab1, tab2 AS cor1
----
66

query I rowsort
SELECT DISTINCT 55 * + tab1.col2 AS col0 FROM tab1
----
2970
3135
5280

query I rowsort
SELECT col0 + - col2 * - 60 FROM tab1
----
3243
3484
5840

query I rowsort
SELECT - ( + col2 + - col1 ) FROM tab1
----
-28
-47
-83

query I rowsort
SELECT col2 * - tab0.col0 + + col2 FROM tab0
----
-34
-7216
-759

query I rowsort
SELECT 10 AS col0 FROM tab1, tab1 AS cor0, tab2 cor1
----
27 values hashing to 0fe3e45a9ecd49584c2ab442100d5176

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - ( col2 ) * cor0.col0 + col2 col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT + ( col0 ) + + 49 * - 36 FROM tab2 AS cor0
----
-1685
-1686
-1757

query I rowsort
SELECT DISTINCT col2 + - cor0.col1 AS col2 FROM tab1 AS cor0
----
28
47
83

query I rowsort
SELECT - - cor0.col0 + - col0 AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 * + col1 + 10 * col1 * - col1 AS col1 FROM tab1 AS cor0
----
-1640
-2730
-6838

query I rowsort
SELECT + 23 AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to 546d49aa433406dd83ea19885588e658

onlyif mysql # use DIV operator for integer division
query I rowsort label-5215
SELECT ALL col1 + + cor0.col1 DIV + ( cor0.col0 ) AS col2 FROM tab2 AS cor0
----
17
35
59

skipif mysql # not compatible
query I rowsort label-5215
SELECT ALL col1 + + cor0.col1 / + ( cor0.col0 ) AS col2 FROM tab2 AS cor0
----
17
35
59

query I rowsort
SELECT DISTINCT 66 + + col0 FROM tab2 cor0
----
144
145
73

query I rowsort
SELECT - 71 + col1 FROM tab0 cor0
----
15
20
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * col1 * col2 col0 FROM tab0
----
611884
93654
97

query I rowsort
SELECT col2 + 58 FROM tab0 AS cor0
----
140
59
91

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5220
SELECT ALL CAST( NULL AS SIGNED ) FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-5220
SELECT ALL CAST ( NULL AS INTEGER ) FROM tab1, tab0, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL - cor0.col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * col1 * - col2 col1 FROM tab2
----
-22599
-24548
-39884

query I rowsort
SELECT ALL + 10 AS col1 FROM tab0
----
10
10
10

query I rowsort
SELECT - col2 + col1 * cor0.col0 AS col2 FROM tab2 AS cor0
----
1305
190
4576

query I rowsort
SELECT ALL 22 * - col0 AS col1 FROM tab0 AS cor0
----
-1958
-528
-770

query I rowsort
SELECT - 42 * col0 + + cor0.col0 FROM tab2 AS cor0
----
-287
-3198
-3239

query I rowsort
SELECT ALL - + ( col0 ) FROM tab2 cor0
----
-7
-78
-79

query I rowsort
SELECT ALL - 67 * - tab2.col0 * col1 AS col2 FROM tab2
----
14539
308334
89981

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5229
SELECT + ( + col0 ) / - col0 + CAST( NULL AS DECIMAL ) / tab2.col1 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5229
SELECT + ( + col0 ) / - col0 + CAST ( NULL AS REAL ) / tab2.col1 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 9 * col1 * col0 FROM tab0
----
-18576
-30555
-72891

query I rowsort
SELECT - ( + 11 ) + col0 * + 26 AS col1 FROM tab1 AS cor0
----
1653
2069
67

query I rowsort
SELECT + - ( col1 ) + - col2 FROM tab2 AS cor0
----
-55
-58
-85

onlyif mysql # use DIV operator for integer division
query I rowsort label-5233
SELECT DISTINCT + col0 + + ( cor0.col1 ) DIV col0 AS col2 FROM tab1 AS cor0
----
11
64
80

skipif mysql # not compatible
query I rowsort label-5233
SELECT DISTINCT + col0 + + ( cor0.col1 ) / col0 AS col2 FROM tab1 AS cor0
----
11
64
80

query I rowsort
SELECT ( 11 ) AS col0 FROM tab0, tab0 AS cor0, tab2 AS cor1, tab2 AS cor2
----
81 values hashing to 288f8fb62e079d095c14d7cf3e2d3359

query I rowsort
SELECT ALL + - col2 * col1 + - col2 FROM tab2 cor0
----
-1560
-684
-864

query I rowsort
SELECT ALL ( - 48 ) + col2 AS col1 FROM tab1 AS cor0
----
48
6
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( + cor0.col2 ) * col0 col2 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-5238
SELECT ALL col0 DIV + 62 + + col0 FROM tab1 AS cor0
----
3
65
81

skipif mysql # not compatible
query I rowsort label-5238
SELECT ALL col0 / + 62 + + col0 FROM tab1 AS cor0
----
3
65
81

query I rowsort
SELECT col2 + 12 * - col0 AS col1 FROM tab2
----
-57
-910
-910

query I rowsort
SELECT ALL col0 + - col0 AS col0 FROM tab2 cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 93 * + 68 col1 FROM tab1
----
6324

query I rowsort
SELECT - 37 FROM tab2, tab0 AS cor0
----
9 values hashing to ed4644af7729c2425ea6cc3d84c6504f

onlyif mysql # use DIV operator for integer division
query I rowsort label-5243
SELECT ALL + col1 DIV - 4 AS col0 FROM tab1
----
-2
-3
-6

skipif mysql # not compatible
query I rowsort label-5243
SELECT ALL + col1 / - 4 AS col0 FROM tab1
----
-2
-3
-6

query I rowsort
SELECT - 31 * + tab2.col1 FROM tab2
----
-1829
-527
-961

query I rowsort
SELECT - col0 * col2 * col1 FROM tab1 cor0
----
-36480
-4212
-99840

query I rowsort
SELECT DISTINCT - col1 + + ( col0 ) AS col2 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT ( tab2.col0 ) - + col2 FROM tab2
----
-20
41
52

query I rowsort
SELECT DISTINCT col2 * + col0 - - ( 88 ) FROM tab0
----
123
7386
880

query I rowsort
SELECT DISTINCT + col2 * + col2 - ( - ( + col1 ) ) AS col0 FROM tab1
----
2942
3259
9229

onlyif mysql # use DIV operator for integer division
query I rowsort label-5250
SELECT - 79 + tab0.col0 DIV - col2 - + tab0.col1 DIV col0 FROM tab0
----
-116
-81
-82

skipif mysql # not compatible
query I rowsort label-5250
SELECT - 79 + tab0.col0 / - col2 - + tab0.col1 / col0 FROM tab0
----
-116
-81
-82

query I rowsort
SELECT - cor0.col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT ALL - col1 - + col2 AS col1 FROM tab1
----
-109
-67
-80

query I rowsort
SELECT - col1 + 3 FROM tab1 cor0
----
-10
-23
-7

onlyif mysql # use DIV operator for integer division
query I rowsort label-5254
SELECT col2 * 67 DIV col1 AS col2 FROM tab1 AS cor0
----
139
381
494

skipif mysql # not compatible
query I rowsort label-5254
SELECT col2 * 67 / col1 AS col2 FROM tab1 AS cor0
----
139
381
494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col2 + + col2 col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL col1 * ( - col0 ) + + col0 FROM tab1 cor0
----
-576
-75
-960

onlyif mysql # use DIV operator for integer division
query I rowsort label-5257
SELECT - col1 DIV 93 AS col1 FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5257
SELECT - col1 / 93 AS col1 FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT - - col2 + + 41 FROM tab1 cor0
----
137
95
98

query I rowsort
SELECT DISTINCT + col2 + 24 * + 53 AS col1 FROM tab1
----
1326
1329
1368

query I rowsort
SELECT ALL + col0 * col2 + col1 AS col2 FROM tab2
----
2087
220
3019

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5261
SELECT DISTINCT + - col0 / CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5261
SELECT DISTINCT + - col0 / CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT + - col2 * - 66 AS col2 FROM tab2 AS cor0
----
1716
1782
2508

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col2 * col1 col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ALL - col2 * - col0 + + col0 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT col1 * 54 + tab0.col0 * col2 + col2 * ( + tab0.col0 ) FROM tab0
----
19510
5308
6228

query I rowsort
SELECT ALL + col0 + - ( col0 ) FROM tab0
----
0
0
0

query I rowsort
SELECT ALL - cor0.col1 + - ( + col0 ) AS col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT 45 * - col1 FROM tab1 AS cor0
----
-1170
-450
-585

query I rowsort
SELECT - - 52 + + col2 FROM tab2 AS cor0
----
78
79
90

query I rowsort
SELECT ALL + - cor0.col1 + + cor0.col0 * - col2 * ( 39 ) FROM tab0 AS cor0
----
-1462
-284713
-30974

query I rowsort
SELECT DISTINCT col1 * + 41 + col1 FROM tab0 AS cor0
----
3612
3822
4074

query I rowsort
SELECT - ( col1 ) * + col2 + + ( col0 ) * + col0 AS col0 FROM tab0 AS cor0
----
-2262
1128
459

query I rowsort
SELECT DISTINCT + 4 - + ( col2 ) AS col1 FROM tab1 AS cor0
----
-50
-53
-92

query I rowsort
SELECT DISTINCT + ( col0 ) + + col2 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT + + col0 * - col1 + - col0 * ( + col1 ) FROM tab0 cor0
----
-16198
-4128
-6790

query I rowsort
SELECT ALL + col2 + + 16 FROM tab0 cor0
----
17
49
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-5277
SELECT ALL + col1 DIV 55 - + col1 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-5277
SELECT ALL + col1 / 55 - + col1 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT + 65 * + col1 + + col0 * 65 AS col0 FROM tab2 AS cor0
----
2470
6240
8905

query I rowsort
SELECT + 29 * + cor0.col1 + col0 * col2 * 21 AS col1 FROM tab0 AS cor0
----
155897
19126
3548

query I rowsort
SELECT ALL + 5 FROM tab2 cor0
----
5
5
5

query I rowsort
SELECT + col2 * col0 + col0 * 62 AS col0 FROM tab2 AS cor0
----
623
6864
7900

query I rowsort
SELECT DISTINCT + 7 + cor0.col0 FROM tab0 AS cor0
----
31
42
96

query I rowsort
SELECT + col0 + 79 FROM tab0 AS cor0
----
103
114
168

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + - ( col0 ) * - 46 col0 FROM tab2 cor0
----
349
3614
3672

query I rowsort
SELECT DISTINCT col1 + - col2 + cor0.col0 FROM tab1 AS cor0
----
-25
-3
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * cor0.col2 * - 15 col0 FROM tab1 cor0
----
18720
21060
8550

query I rowsort
SELECT DISTINCT + 36 + - col0 * - col1 FROM tab1 AS cor0
----
1076
114
676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( + col2 ) col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - - 85 AS col0 FROM tab0 cor0
----
85
85
85

query I rowsort
SELECT DISTINCT 95 FROM tab2 cor0
----
95

query I rowsort
SELECT DISTINCT ( cor0.col1 ) * col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT DISTINCT - col1 * col0 + - ( - 62 ) * col2 AS col1 FROM tab2 AS cor0
----
-2990
1013
1457

query I rowsort
SELECT + cor0.col1 * - col1 * col1 FROM tab1 AS cor0
----
-1000
-17576
-2197

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 + col2 col1 FROM tab2 cor0
----
55
58
85

query I rowsort
SELECT DISTINCT - - 88 * - col1 AS col1 FROM tab1 AS cor0
----
-1144
-2288
-880

query I rowsort
SELECT ALL - cor0.col1 * col0 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + 79 FROM tab2, tab0 cor0
----
9 values hashing to 40a2261caa2c5cdbfd80965d7df1231f

query I rowsort
SELECT - + col1 + + 28 FROM tab2 AS cor0
----
-3
-31
11

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5299
SELECT DISTINCT col1 * - CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5299
SELECT DISTINCT col1 * - CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + + cor0.col1 + 72 FROM tab0 cor0
----
158
163
169

query I rowsort
SELECT + + col0 * 95 * - col1 FROM tab2 AS cor0
----
-127585
-20615
-437190

query I rowsort
SELECT + col1 + + 11 FROM tab2 AS cor0
----
28
42
70

query I rowsort
SELECT DISTINCT - + ( col0 ) * + col0 AS col2 FROM tab1 cor0
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT 26 AS col1 FROM tab2 cor0
----
26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5305
SELECT - CAST( NULL AS SIGNED ) * col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5305
SELECT - CAST ( NULL AS INTEGER ) * col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( col1 ) + col0 AS col1 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT ( col2 ) + col1 * - col0 AS col0 FROM tab1 cor0
----
-24
-583
-944

query I rowsort
SELECT - - 85 FROM tab2 AS cor0
----
85
85
85

query I rowsort
SELECT DISTINCT - - 84 * col0 FROM tab1 AS cor0
----
252
5376
6720

query I rowsort
SELECT - col1 * - 11 AS col1 FROM tab2 AS cor0
----
187
341
649

query I rowsort
SELECT - cor0.col2 + 65 * - col1 FROM tab1 cor0
----
-1744
-707
-941

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5312
SELECT ALL + - CAST( NULL AS DECIMAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5312
SELECT ALL + - CAST ( NULL AS REAL ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * ( cor0.col0 ) col2 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT ALL - cor0.col0 * 97 FROM tab1 AS cor0
----
-291
-6208
-7760

query I rowsort
SELECT DISTINCT - 72 AS col2 FROM tab1 AS cor0
----
-72

query I rowsort
SELECT + 97 * col0 FROM tab2 cor0
----
679
7566
7663

query I rowsort
SELECT ALL + ( + col0 ) + - 39 + - col2 * + col1 FROM tab0 AS cor0
----
-101
-2853
-7412

query I rowsort
SELECT col0 + - col2 * tab2.col0 AS col1 FROM tab2
----
-182
-1950
-2923

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab1 AS cor0 CROSS JOIN tab0, tab0 cor1, tab1 AS cor2
----
3645 values hashing to e5255b2277726ba4514ff55622dec830

onlyif mysql # use DIV operator for integer division
query I rowsort label-5320
SELECT ALL col0 DIV + col1 AS col0 FROM tab0 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5320
SELECT ALL col0 / + col1 AS col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT + cor0.col1 + 20 FROM tab2 AS cor0
----
37
51
79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5322
SELECT ALL + col0 + CAST( NULL AS DECIMAL ) / 17 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5322
SELECT ALL + col0 + CAST ( NULL AS REAL ) / 17 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( - 22 ) FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 7dda382e7c08428abac8600fd696eb3e

query I rowsort
SELECT + - cor0.col2 + + col2 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col1 - 79 FROM tab2
----
-20
-48
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5326
SELECT col1 + + col1 DIV col2 AS col1 FROM tab1
----
10
13
26

skipif mysql # not compatible
query I rowsort label-5326
SELECT col1 + + col1 / col2 AS col1 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT - - col2 * 20 + col1 FROM tab1 AS cor0
----
1106
1150
1933

query I rowsort
SELECT - col0 + - ( + tab1.col0 ) * tab1.col0 AS col1 FROM tab1
----
-12
-4160
-6480

onlyif mysql # use DIV operator for integer division
query I rowsort label-5329
SELECT DISTINCT tab2.col1 DIV ( 90 ) FROM tab2
----
0

skipif mysql # not compatible
query I rowsort label-5329
SELECT DISTINCT tab2.col1 / ( 90 ) FROM tab2
----
0

query I rowsort
SELECT + 71 + 21 * cor0.col2 * 90 AS col0 FROM tab1 cor0
----
102131
107801
181511

query I rowsort
SELECT DISTINCT cor0.col2 FROM tab2, tab2 AS cor0, tab0 AS cor1, tab1 AS cor2
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 74 - + cor0.col1 col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 093d55adc24a704298a6d81763aa9b63

query I rowsort
SELECT col2 * + 29 FROM tab0
----
2378
29
957

query I rowsort
SELECT - cor0.col1 * + 29 AS col2 FROM tab0 AS cor0
----
-2494
-2639
-2813

query I rowsort
SELECT 54 * cor0.col0 FROM tab2 cor0
----
378
4212
4266

query I rowsort
SELECT - ( - col2 ) + cor0.col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT - 9 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to caf28657beb43049740febe1fa9ded5a

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 57 + col1 * ( col2 ) * col2 col2 FROM tab2
----
22542
24491
39827

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col0 col0 FROM tab1, tab2 AS cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5340
SELECT DISTINCT 68 DIV col1 + - 37 FROM tab1
----
-31
-32
-35

skipif mysql # not compatible
query I rowsort label-5340
SELECT DISTINCT 68 / col1 + - 37 FROM tab1
----
-31
-32
-35

query I rowsort
SELECT - + col1 + + col2 - + col2 AS col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT ALL + 68 + + col0 * - col0 AS col0 FROM tab2 AS cor0
----
-6016
-6173
19

query I rowsort
SELECT DISTINCT - + col2 * + cor0.col0 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-5344
SELECT col0 * 81 + 38 DIV col0 FROM tab1 AS cor0
----
255
5184
6480

skipif mysql # not compatible
query I rowsort label-5344
SELECT col0 * 81 + 38 / col0 FROM tab1 AS cor0
----
255
5184
6480

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5345
SELECT ALL + + cor0.col0 + + CAST( NULL AS DECIMAL ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5345
SELECT ALL + + cor0.col0 + + CAST ( NULL AS REAL ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5346
SELECT - + col1 + 55 DIV - col1 AS col2 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-5346
SELECT - + col1 + 55 / - col1 AS col2 FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5347
SELECT + - col2 * CAST( NULL AS SIGNED ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5347
SELECT + - col2 * CAST ( NULL AS INTEGER ) * col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5348
SELECT col1 / CAST( NULL AS DECIMAL ) + - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5348
SELECT col1 / CAST ( NULL AS REAL ) + - col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5349
SELECT + ( col1 ) DIV ( ( col0 ) * 98 ) FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5349
SELECT + ( col1 ) / ( ( col0 ) * 98 ) FROM tab2
----
0
0
0

query I rowsort
SELECT col0 + col2 * - col0 + + tab0.col2 AS col2 FROM tab0
----
-7127
-735
1

query I rowsort
SELECT - col2 + - 14 AS col2 FROM tab1 AS cor0
----
-110
-68
-71

query I rowsort
SELECT + - col0 + col1 + - col0 FROM tab2 AS cor0
----
-141
-97
17

onlyif mysql # use DIV operator for integer division
query I rowsort label-5353
SELECT DISTINCT - 92 + - col0 DIV col2 AS col0 FROM tab1 AS cor0
----
-92
-93

skipif mysql # not compatible
query I rowsort label-5353
SELECT DISTINCT - 92 + - col0 / col2 AS col0 FROM tab1 AS cor0
----
-92
-93

query I rowsort
SELECT ALL - col1 * col1 - col1 AS col2 FROM tab2 AS cor0
----
-306
-3540
-992

onlyif mysql # use DIV operator for integer division
query I rowsort label-5355
SELECT DISTINCT - + cor0.col2 DIV CAST( 63 AS SIGNED ) + col0 AS col0 FROM tab0 AS cor0
----
24
35
88

skipif mysql # not compatible
query I rowsort label-5355
SELECT DISTINCT - + cor0.col2 / CAST ( 63 AS INTEGER ) + col0 AS col0 FROM tab0 AS cor0
----
24
35
88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5356
SELECT DISTINCT - col1 * CAST( col2 AS DECIMAL ) * col2 - + CAST( NULL AS SIGNED ) * col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5356
SELECT DISTINCT - col1 * CAST ( col2 AS REAL ) * col2 - + CAST ( NULL AS INTEGER ) * col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + 43 AS col2 FROM tab2, tab1, tab1 AS cor0
----
43

onlyif mysql # use DIV operator for integer division
query I rowsort label-5358
SELECT ALL + - col2 DIV - 27 AS col2 FROM tab2 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-5358
SELECT ALL + - col2 / - 27 AS col2 FROM tab2 AS cor0
----
0
1
1

query I rowsort
SELECT DISTINCT - + col2 * - col1 + - cor0.col1 FROM tab2 AS cor0
----
1475
629
806

onlyif mysql # use DIV operator for integer division
query I rowsort label-5360
SELECT DISTINCT - col0 DIV 41 FROM tab2 AS cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-5360
SELECT DISTINCT - col0 / 41 FROM tab2 AS cor0
----
-1
0

query I rowsort
SELECT DISTINCT + + col0 - 42 FROM tab1 AS cor0
----
-39
22
38

query I rowsort
SELECT DISTINCT cor0.col0 * col1 + - col0 * col0 FROM tab2 AS cor0
----
-1482
-4898
168

onlyif mysql # use DIV operator for integer division
query I rowsort label-5363
SELECT - col2 DIV col1 - - col0 col1 FROM tab1
----
1
59
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5363
SELECT - col2 / col1 - - col0 col1 FROM tab1
----
1
59
73

query I rowsort
SELECT - 70 + col0 * - col0 AS col2 FROM tab0
----
-1295
-646
-7991

query I rowsort
SELECT 89 * col0 AS col0 FROM tab1
----
267
5696
7120

query I rowsort
SELECT ALL col1 + col0 * 92 AS col2 FROM tab2
----
675
7235
7285

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col1 * col0 + col2 col2 FROM tab2 cor0
----
1381
244
4628

query I rowsort
SELECT col1 + + col1 + + cor0.col1 FROM tab1 cor0
----
30
39
78

query I rowsort
SELECT DISTINCT - ( col1 ) * - col1 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT + + col0 * 8 AS col0 FROM tab1 AS cor0
----
24
512
640

query I rowsort
SELECT DISTINCT - cor0.col2 + + 48 * + col0 * - 0 AS col0 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT col2 * 54 FROM tab2 AS cor0
----
1404
1458
2052

query I rowsort
SELECT ALL - 34 * - col0 + - cor0.col2 FROM tab1 AS cor0
----
2119
2624
48

query I rowsort
SELECT - + 81 * col0 AS col1 FROM tab1 cor0
----
-243
-5184
-6480

query I rowsort
SELECT + col2 * - 65 - col0 * + col1 FROM tab1 AS cor0
----
-3588
-4345
-7280

onlyif mysql # use DIV operator for integer division
query I rowsort label-5376
SELECT + col2 * cor0.col2 - - col0 DIV ( + 83 ) FROM tab0 AS cor0
----
1
1089
6725

skipif mysql # not compatible
query I rowsort label-5376
SELECT + col2 * cor0.col2 - - col0 / ( + 83 ) FROM tab0 AS cor0
----
1
1089
6725

skipif mysql # not compatible
query I rowsort
SELECT - ( - col1 ) + - cor0.col1 + CAST ( col1 AS REAL ) FROM tab1 cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-5378
SELECT + cor0.col2 * + col2 + col2 * - col1 * col0 + + col0 DIV - cor0.col1 AS col1 FROM tab0 AS cor0
----
-3394
-657394
-67023

skipif mysql # not compatible
query I rowsort label-5378
SELECT + cor0.col2 * + col2 + col2 * - col1 * col0 + + col0 / - cor0.col1 AS col1 FROM tab0 AS cor0
----
-3394
-657394
-67023

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 22 * + col1 col0 FROM tab2 AS cor0
----
-1298
-374
-682

query I rowsort
SELECT 8 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 33069adc3c1142d31511ec88fcfa40af

query I rowsort
SELECT ALL + 39 FROM tab2, tab1 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

query I rowsort
SELECT + ( - 42 ) * + col0 FROM tab1
----
-126
-2688
-3360

query I rowsort
SELECT - - 10 + + col0 FROM tab1 AS cor0
----
13
74
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + col0 col1 FROM tab1 cor0
----
-23
54
67

query I rowsort
SELECT + col1 + col1 + col1 AS col0 FROM tab2
----
177
51
93

query I rowsort
SELECT + 55 + col0 - col2 * + col0 FROM tab0 AS cor0
----
-713
-7154
55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5387
SELECT 53 + col1 - + CAST( NULL AS DECIMAL ) * col0 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5387
SELECT 53 + col1 - + CAST ( NULL AS REAL ) * col0 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + - col1 + - col1 - + col2 * col0 FROM tab0 AS cor0
----
-229
-7480
-964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) col0 FROM tab0
----
1
33
82

query I rowsort
SELECT tab2.col1 AS col1 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT + 71 + + col2 FROM tab1
----
125
128
167

onlyif mysql # use DIV operator for integer division
query I rowsort label-5392
SELECT DISTINCT - 80 DIV - tab0.col2 FROM tab0, tab1 cor0, tab2 AS cor1
----
0
2
80

skipif mysql # not compatible
query I rowsort label-5392
SELECT DISTINCT - 80 / - tab0.col2 FROM tab0, tab1 cor0, tab2 AS cor1
----
0
2
80

query I rowsort
SELECT ALL + 31 + cor0.col0 * + col1 AS col1 FROM tab0 cor0
----
2095
3426
8130

onlyif mysql # use DIV operator for integer division
query I rowsort label-5394
SELECT - ( + cor0.col1 ) + + col0 DIV ( - cor0.col2 ) AS col0 FROM tab1 AS cor0
----
-11
-13
-26

skipif mysql # not compatible
query I rowsort label-5394
SELECT - ( + cor0.col1 ) + + col0 / ( - cor0.col2 ) AS col0 FROM tab1 AS cor0
----
-11
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + col2 col1 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL - - 89 FROM tab0 AS cor0
----
89
89
89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5397
SELECT ALL - ( cor0.col0 ) + + CAST( NULL AS SIGNED ) * + col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5397
SELECT ALL - ( cor0.col0 ) + + CAST ( NULL AS INTEGER ) * + col2 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col2 * + col2 + col1 FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT + + 62 FROM tab1 AS cor0
----
62
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( - col1 ) + - ( col2 * + col1 ) col1 FROM tab0 AS cor0
----
-2752
-7371
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5401
SELECT ALL + col2 + + cor0.col1 * ( col1 ) DIV + col2 FROM tab1 AS cor0
----
58
66
97

skipif mysql # not compatible
query I rowsort label-5401
SELECT ALL + col2 + + cor0.col1 * ( col1 ) / + col2 FROM tab1 AS cor0
----
58
66
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5402
SELECT DISTINCT col0 + col0 / CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5402
SELECT DISTINCT col0 + col0 / CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5403
SELECT + col0 + - CAST( col0 AS SIGNED ) * - col0 col1 FROM tab2 AS cor0
----
56
6162
6320

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5403
SELECT + col0 + - CAST ( col0 AS INTEGER ) * - col0 col1 FROM tab2 AS cor0
----
56
6162
6320

onlyif mysql # use DIV operator for integer division
query I rowsort label-5404
SELECT ALL - col0 DIV - 91 + col1 AS col2 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-5404
SELECT ALL - col0 / - 91 + col1 AS col2 FROM tab0 cor0
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5405
SELECT DISTINCT col0 - + CAST( + cor0.col1 AS SIGNED ) FROM tab1 AS cor0
----
-23
54
67

skipif mysql # not compatible
query I rowsort label-5405
SELECT DISTINCT col0 - + CAST ( + cor0.col1 AS INTEGER ) FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + col1 * 98 FROM tab1 AS cor0
----
1274
2548
980

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - col0 + col2 col0 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL - 99 + + col2 * col1 AS col0 FROM tab0 AS cor0
----
-2
2739
7363

onlyif mysql # use DIV operator for integer division
query I rowsort label-5409
SELECT ALL - col1 DIV 44 - col1 FROM tab1 AS cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-5409
SELECT ALL - col1 / 44 - col1 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT 13 + - col1 * - col0 AS col0 FROM tab2 AS cor0
----
1356
230
4615

query I rowsort
SELECT + col2 + + 18 FROM tab0 AS cor0
----
100
19
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-5412
SELECT DISTINCT - ( cor0.col2 ) + + col1 * - col2 DIV + col2 AS col1 FROM tab0 cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-5412
SELECT DISTINCT - ( cor0.col2 ) + + col1 * - col2 / + col2 AS col1 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT DISTINCT 25 - col0 FROM tab0 AS cor0
----
-10
-64
1

query I rowsort
SELECT + 63 FROM tab0 cor0
----
63
63
63

query I rowsort
SELECT DISTINCT col0 * + col0 * 86 AS col2 FROM tab0
----
105350
49536
681206

query I rowsort
SELECT + + col0 * 8 * - col0 AS col2 FROM tab2 AS cor0
----
-392
-48672
-49928

onlyif mysql # use DIV operator for integer division
query I rowsort label-5417
SELECT ALL tab1.col2 DIV + 32 AS col0 FROM tab1
----
1
1
3

skipif mysql # not compatible
query I rowsort label-5417
SELECT ALL tab1.col2 / + 32 AS col0 FROM tab1
----
1
1
3

query I rowsort
SELECT DISTINCT + 10 + - 47 AS col0 FROM tab0, tab2 AS cor0
----
-37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 33 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 620d384286e82d1c6c8b1b2b109a7da5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5420
SELECT DISTINCT CAST( 64 AS SIGNED ) FROM tab0, tab1 AS cor0
----
64

skipif mysql # not compatible
query I rowsort label-5420
SELECT DISTINCT CAST ( 64 AS INTEGER ) FROM tab0, tab1 AS cor0
----
64

query I rowsort
SELECT tab1.col1 * 58 AS col2 FROM tab1
----
1508
580
754

query I rowsort
SELECT - cor0.col1 + + col1 + col2 AS col0 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT ALL 38 + + col0 FROM tab1 AS cor0
----
102
118
41

query I rowsort
SELECT DISTINCT + col2 * + col0 + col2 AS col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT DISTINCT cor1.col0 + + cor0.col2 AS col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c345857bb273aa2639457b7deb30fe90

query I rowsort
SELECT + + col2 * cor0.col0 + - col0 FROM tab1 AS cor0
----
159
3584
7600

onlyif mysql # use DIV operator for integer division
query I rowsort label-5427
SELECT + 17 DIV + col1 + col1 FROM tab2 AS cor0
----
18
31
59

skipif mysql # not compatible
query I rowsort label-5427
SELECT + 17 / + col1 + col1 FROM tab2 AS cor0
----
18
31
59

query I rowsort
SELECT + - 66 * 48 AS col2 FROM tab1 cor0
----
-3168
-3168
-3168

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5429
SELECT CAST( NULL AS SIGNED ) * 19 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5429
SELECT CAST ( NULL AS INTEGER ) * 19 AS col1 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - + 96 * + col2 AS col0 FROM tab0 AS cor0
----
-3168
-7872
-96

query I rowsort
SELECT 73 + - col0 AS col2 FROM tab0 AS cor0
----
-16
38
49

query I rowsort
SELECT DISTINCT ( + col0 ) + col2 * - col1 FROM tab1 AS cor0
----
-1168
-1401
-506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 - col0 col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT - col2 * cor0.col1 * col1 AS col0 FROM tab2 AS cor0
----
-10982
-25947
-90506

query I rowsort
SELECT ALL + - 6 * cor0.col0 FROM tab0 AS cor0
----
-144
-210
-534

query I rowsort
SELECT ALL - - col1 * col2 FROM tab1 cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + 46 * cor0.col1 - col1 FROM tab1 AS cor0
----
1170
450
585

onlyif mysql # use DIV operator for integer division
query I rowsort label-5438
SELECT 16 DIV col1 + + ( - 35 ) FROM tab0 AS cor0
----
-35
-35
-35

skipif mysql # not compatible
query I rowsort label-5438
SELECT 16 / col1 + + ( - 35 ) FROM tab0 AS cor0
----
-35
-35
-35

onlyif mysql # use DIV operator for integer division
query I rowsort label-5439
SELECT - - col1 * + col1 + col0 DIV - 27 AS col1 FROM tab1 AS cor0
----
167
676
98

skipif mysql # not compatible
query I rowsort label-5439
SELECT - - col1 * + col1 + col0 / - 27 AS col1 FROM tab1 AS cor0
----
167
676
98

query I rowsort
SELECT DISTINCT ( - col1 ) * + col0 + - col2 AS col1 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT - + 23 * col2 AS col1 FROM tab0 AS cor0
----
-1886
-23
-759

onlyif mysql # use DIV operator for integer division
query I rowsort label-5442
SELECT col2 * col1 + - col1 * + col1 DIV col1 FROM tab0 AS cor0
----
0
2752
7371

skipif mysql # not compatible
query I rowsort label-5442
SELECT col2 * col1 + - col1 * + col1 / col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT ALL - 72 + col1 FROM tab1 AS cor0
----
-46
-59
-62

query I rowsort
SELECT + col0 * col2 * + col2 AS col1 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT col2 * + 11 AS col1 FROM tab2 AS cor0
----
286
297
418

query I rowsort
SELECT + col2 - ( 19 ) * - col2 FROM tab0 AS cor0
----
1640
20
660

query I rowsort
SELECT col1 + col2 * col2 * col2 - - col1 AS col0 FROM tab0
----
195
36109
551550

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + + col1 + + 23 * + col0 * col1 col2 FROM tab1 AS cor0
----
14787
1874
24029

query I rowsort
SELECT DISTINCT + col0 + + 62 FROM tab0 AS cor0
----
151
86
97

query I rowsort
SELECT ALL + + col2 * + col0 AS col1 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col1 * + ( 97 ) - + col2 AS col0 FROM tab0 AS cor0
----
8309
8745
9408

query I rowsort
SELECT col0 + + col1 * - 77 AS col1 FROM tab1 AS cor0
----
-1999
-706
-921

onlyif mysql # use DIV operator for integer division
query I rowsort label-5453
SELECT + cor0.col2 DIV + col0 + col2 + col2 FROM tab1 AS cor0
----
114
126
193

skipif mysql # not compatible
query I rowsort label-5453
SELECT + cor0.col2 / + col0 + col2 + col2 FROM tab1 AS cor0
----
114
126
193

query I rowsort
SELECT ALL + cor0.col1 + 14 FROM tab2 AS cor0
----
31
45
73

query I rowsort
SELECT - col1 * 62 + col0 AS col0 FROM tab0 AS cor0
----
-5308
-5553
-5979

query I rowsort
SELECT - - 0 * + col0 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - 31 * 58 + col2 * - 42 AS col1 FROM tab1 AS cor0
----
-4066
-4192
-5830

onlyif mysql # use DIV operator for integer division
query I rowsort label-5458
SELECT col1 DIV + 34 AS col0 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5458
SELECT col1 / + 34 AS col0 FROM tab1
----
0
0
0

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab0, tab1 AS cor2
----
3645 values hashing to d0428a2939e158628acd4bd449471d5b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * col0 col1 FROM tab2 AS cor0
----
-1343
-217
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5461
SELECT 36 DIV + col2 col1 FROM tab0 cor0
----
0
1
36

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5461
SELECT 36 / + col2 col1 FROM tab0 cor0
----
0
1
36

query I rowsort
SELECT cor0.col0 + col2 * - col1 AS col2 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT + 24 * - col1 FROM tab1 AS cor0
----
-240
-312
-624

query I rowsort
SELECT 23 AS col2 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to 546d49aa433406dd83ea19885588e658

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0, tab0 cor1, tab2 cor2
----
972 values hashing to 1e9d01970ae508486ddabec967bb176c

query I rowsort
SELECT ALL ( tab2.col0 ) * - col0 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT col2 + col1 * ( col2 ) + col0 AS col2 FROM tab0
----
133
2895
7633

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * col2 col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL 91 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
27 values hashing to deebbcfb9c7803a34dca6bd860849afe

onlyif mysql # use DIV operator for integer division
query I rowsort label-5470
SELECT cor0.col0 DIV - col2 FROM tab0 AS cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-5470
SELECT cor0.col0 / - col2 FROM tab0 AS cor0
----
-1
-35
0

query I rowsort
SELECT - col0 * tab2.col0 + - col2 * + tab2.col1 FROM tab2
----
-6887
-7618
-886

onlyif mysql # use DIV operator for integer division
query I rowsort label-5472
SELECT DISTINCT col0 DIV col2 AS col0 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-5472
SELECT DISTINCT col0 / col2 AS col0 FROM tab1
----
0
1

query III rowsort
SELECT * FROM tab2 WHERE NOT col1 - + col1 NOT IN ( col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5474
SELECT DISTINCT + col0 DIV col2 + + col0 AS col1 FROM tab1 WHERE NOT col0 - - col0 IN ( col1 + col2 )
----
3
65
80

skipif mysql # not compatible
query I rowsort label-5474
SELECT DISTINCT + col0 / col2 + + col0 AS col1 FROM tab1 WHERE NOT col0 - - col0 IN ( col1 + col2 )
----
3
65
80

query I rowsort
SELECT - col1 AS col1 FROM tab0 WHERE NOT ( NULL ) <= - col0 * col2 - col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5476
SELECT ALL + col0 DIV col2 AS col0 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-5476
SELECT ALL + col0 / col2 AS col0 FROM tab1
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5477
SELECT ALL + col0 DIV tab2.col0 col0 FROM tab2
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5477
SELECT ALL + col0 / tab2.col0 col0 FROM tab2
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5478
SELECT + col1 * col2 DIV - tab1.col0 FROM tab1
----
-15
-468
-8

skipif mysql # not compatible
query I rowsort label-5478
SELECT + col1 * col2 / - tab1.col0 FROM tab1
----
-15
-468
-8

query I rowsort
SELECT ALL col2 + - col2 * + col1 + col1 * + tab2.col0 FROM tab2
----
-593
3094
735

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( NULL ) < ( NULL )
----

query I rowsort
SELECT + tab1.col1 + col2 + + col0 AS col2 FROM tab1
----
131
189
83

query I rowsort
SELECT - col0 * tab0.col1 AS col1 FROM tab0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-5483
SELECT DISTINCT + col1 DIV + col1 col0 FROM tab1
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5483
SELECT DISTINCT + col1 / + col1 col0 FROM tab1
----
1

query I rowsort
SELECT ALL - tab1.col0 FROM tab1 WHERE NOT col1 + - col2 * + col1 < NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5485
SELECT ALL - col2 + - col2 * - col0 + col0 DIV + col1 AS col0 FROM tab1
----
108
3597
7590

skipif mysql # not compatible
query I rowsort label-5485
SELECT ALL - col2 + - col2 * - col0 + col0 / + col1 AS col0 FROM tab1
----
108
3597
7590

query I rowsort
SELECT + 51 + + cor1.col2 * - 76 FROM tab0, tab2 AS cor0, tab1 AS cor1, tab2 AS cor2
----
81 values hashing to 107e996aca65defa0f6c10d52b54713b

query I rowsort
SELECT ALL + 98 * col0 FROM tab1 cor0
----
294
6272
7840

query I rowsort
SELECT + + 51 + - col0 AS col1 FROM tab1 AS cor0
----
-13
-29
48

query I rowsort
SELECT ALL - col0 * col1 FROM tab1 WHERE NULL NOT IN ( col0 + - col2 * tab1.col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5490
SELECT col0 DIV col0 col1 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5490
SELECT col0 / col0 col1 FROM tab0
----
1
1
1

query III rowsort
SELECT ALL * FROM tab0 WHERE col2 <> tab0.col0 / + col1
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query IIIIII rowsort
SELECT * FROM tab2, tab1 AS cor0 WHERE ( NULL ) < ( NULL )
----

query I rowsort
SELECT ALL cor0.col1 AS col2 FROM tab1, tab0 cor0
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query I rowsort
SELECT DISTINCT - col0 * col1 + col2 * tab0.col0 FROM tab0
----
-1272
-3360
-801

query III rowsort
SELECT ALL * FROM tab0 WHERE ( NULL ) < col2
----

query I rowsort
SELECT ALL col0 + + col0 * - col0 FROM tab2 WHERE ( col1 ) NOT IN ( col2 )
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT - col0 * col0 + - col1 AS col2 FROM tab0
----
-1322
-662
-8012

onlyif mysql # use DIV operator for integer division
query I rowsort label-5498
SELECT - col1 DIV + tab0.col1 - + col1 AS col2 FROM tab0
----
-87
-92
-98

skipif mysql # not compatible
query I rowsort label-5498
SELECT - col1 / + tab0.col1 - + col1 AS col2 FROM tab0
----
-87
-92
-98

query I rowsort
SELECT DISTINCT col2 + - col1 * + tab0.col2 AS col1 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT col1 FROM tab1 WHERE ( col0 ) NOT IN ( + col1 * col1 )
----
10
13
26

query I rowsort
SELECT ALL col0 + - col0 * tab2.col0 FROM tab2
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT col2 + + col0 * col0 FROM tab2
----
6110
6279
76

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL NOT BETWEEN NULL AND ( col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5504
SELECT col2 DIV + col0 col0 FROM tab0
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5504
SELECT col2 / + col0 col0 FROM tab0
----
0
0
1

query I rowsort
SELECT ALL col1 AS col0 FROM tab1 WHERE NOT + col2 > ( - col1 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-5506
SELECT ALL - 6 + col1 DIV - col0 + col1 FROM tab2 AS cor0
----
11
21
53

skipif mysql # not compatible
query I rowsort label-5506
SELECT ALL - 6 + col1 / - col0 + col1 FROM tab2 AS cor0
----
11
21
53

query I rowsort
SELECT DISTINCT col0 + - col0 - col2 AS col0 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT + ( - col0 ) * - col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - - col2 + 12 * + col2 FROM tab2 AS cor0
----
338
351
494

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - + CAST ( col1 AS REAL ) FROM tab0 AS cor0
----
-86
-91
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5511
SELECT CAST( col0 AS SIGNED ) * col1 FROM tab0 cor0
----
2064
3395
8099

skipif mysql # not compatible
query I rowsort label-5511
SELECT CAST ( col0 AS INTEGER ) * col1 FROM tab0 cor0
----
2064
3395
8099

query I rowsort
SELECT DISTINCT - - ( - 59 ) * - col2 FROM tab2 AS cor0
----
1534
1593
2242

query I rowsort
SELECT ALL + 22 + + 36 FROM tab2 AS cor0
----
58
58
58

query I rowsort
SELECT ALL - col0 * 78 + - col0 * + cor0.col0 AS col1 FROM tab0 AS cor0
----
-14863
-2448
-3955

query I rowsort
SELECT DISTINCT - + col2 * - cor0.col0 + col0 * + col1 - col1 AS col1 FROM tab0 AS cor0
----
15306
2770
3333

onlyif mysql # use DIV operator for integer division
query I rowsort label-5516
SELECT ALL + ( - 98 ) DIV - cor0.col0 AS col0 FROM tab1 AS cor0
----
1
1
32

skipif mysql # not compatible
query I rowsort label-5516
SELECT ALL + ( - 98 ) / - cor0.col0 AS col0 FROM tab1 AS cor0
----
1
1
32

query I rowsort
SELECT ALL - ( - 94 ) FROM tab0
----
94
94
94

query I rowsort
SELECT ALL ( + col0 + col1 ) FROM tab2
----
137
38
96

query I rowsort
SELECT - col1 * + 85 * col1 + tab2.col1 FROM tab2
----
-24548
-295826
-81654

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 27 col0 FROM tab2, tab1, tab1 AS cor0
----
27

query I rowsort
SELECT ALL col2 * 44 FROM tab1
----
2376
2508
4224

query I rowsort
SELECT - tab0.col1 + - 69 AS col0 FROM tab0
----
-155
-160
-166

query I rowsort
SELECT + 17 AS col1 FROM tab2, tab1 cor0
----
9 values hashing to 43298e43365fccb5146ea32003753c92

query I rowsort
SELECT - col0 + ( col0 ) AS col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - col1 + tab2.col1 col2 FROM tab2
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-5526
SELECT + col2 * + tab2.col2 - col1 DIV - col1 FROM tab2
----
1445
677
730

skipif mysql # not compatible
query I rowsort label-5526
SELECT + col2 * + tab2.col2 - col1 / - col1 FROM tab2
----
1445
677
730

query I rowsort
SELECT DISTINCT + - cor0.col0 * - ( col1 ) + + cor0.col2 + - 0 AS col1 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT DISTINCT + cor0.col1 * cor0.col0 FROM tab1 AS cor0
----
1040
640
78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 * 4 col1 FROM tab1 AS cor0
----
-216
-228
-384

query I rowsort
SELECT DISTINCT - + col1 * + 27 FROM tab2 AS cor0
----
-1593
-459
-837

query I rowsort
SELECT - + cor0.col0 * 34 + cor0.col1 FROM tab1 AS cor0
----
-2166
-2707
-76

query I rowsort
SELECT ALL + col2 + - col1 AS col0 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT + col1 + 9 * + col1 FROM tab0 AS cor0
----
860
910
970

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + col2 * - col1 - col0 col0 FROM tab1
----
-1408
-1410
-698

onlyif mysql # use DIV operator for integer division
query I rowsort label-5535
SELECT DISTINCT 97 DIV + col1 + col2 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-5535
SELECT DISTINCT 97 / + col1 + col2 FROM tab0
----
2
34
83

query I rowsort
SELECT 66 - col0 FROM tab0
----
-23
31
42

query I rowsort
SELECT DISTINCT + col2 + + col1 + 92 FROM tab1
----
159
172
201

query I rowsort
SELECT col2 * col1 - 58 FROM tab0
----
2780
39
7404

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 59 + - col1 + col1 col1 FROM tab2
----
-59
-59
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-5540
SELECT - col0 + tab1.col1 DIV col1 AS col2 FROM tab1
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-5540
SELECT - col0 + tab1.col1 / col1 AS col2 FROM tab1
----
-2
-63
-79

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5541
SELECT + col0 * ( ( + col1 ) ) + CAST( NULL AS DECIMAL ) AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5541
SELECT + col0 * ( ( + col1 ) ) + CAST ( NULL AS REAL ) AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col1 * + ( + col0 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT DISTINCT - col0 + 49 AS col2 FROM tab2 AS cor0
----
-29
-30
42

query I rowsort
SELECT DISTINCT + col2 * - 58 * 81 AS col0 FROM tab2 AS cor0
----
-122148
-126846
-178524

query I rowsort
SELECT + - cor0.col0 + cor0.col0 AS col1 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL + - col1 + col1 * col0 FROM tab1 AS cor0
----
1027
52
630

query I rowsort
SELECT - + col2 + 73 FROM tab0 AS cor0
----
-9
40
72

query I rowsort
SELECT ALL + col0 + + col0 * col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT cor0.col1 + col0 * col0 AS col2 FROM tab1 AS cor0
----
35
4106
6413

query I rowsort
SELECT - + cor0.col1 * col0 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + - col1 + col1 - 97 * ( + col2 ) * - 49 AS col2 FROM tab1 AS cor0
----
256662
270921
456288

onlyif mysql # use DIV operator for integer division
query I rowsort label-5552
SELECT DISTINCT - 75 + - col1 DIV + col2 AS col0 FROM tab1
----
-75

skipif mysql # not compatible
query I rowsort label-5552
SELECT DISTINCT - 75 + - col1 / + col2 AS col0 FROM tab1
----
-75

query I rowsort
SELECT - ( - col1 ) + + col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT DISTINCT + col0 + ( col2 ) AS col1 FROM tab1
----
121
176
57

query I rowsort
SELECT DISTINCT - 21 * - 25 + - col1 + - col1 FROM tab0
----
331
343
353

query I rowsort
SELECT col0 + + 98 + col2 FROM tab1
----
155
219
274

query I rowsort
SELECT DISTINCT - ( - col0 ) + - 86 FROM tab2 AS cor0
----
-7
-79
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 * - col1 + + 73 col2 FROM tab2 AS cor0
----
-1270
-144
-4529

query I rowsort
SELECT DISTINCT + cor0.col0 * col2 + col1 * 34 AS col2 FROM tab1 AS cor0
----
1046
3988
8122

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5560
SELECT - + CAST( NULL AS SIGNED ) FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-5560
SELECT - + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT + + col0 * col0 AS col1 FROM tab2 cor0
----
49
6084
6241

query I rowsort
SELECT DISTINCT ( + col0 ) * + col1 AS col1 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT ALL 53 AS col1 FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
27 values hashing to 866ae1b4ab9e5b4043ac1bcfd413aaa6

query I rowsort
SELECT ALL 77 * tab1.col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 0e94edc0b0f9158e070618dcc95fc9ce

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 - + 44 col0 FROM tab2 AS cor0
----
-122
-123
-51

query I rowsort
SELECT DISTINCT + col0 + + 7 FROM tab0 AS cor0
----
31
42
96

query I rowsort
SELECT ALL + col0 * col0 + - col0 + + ( 4 ) FROM tab1 AS cor0
----
10
4036
6324

query I rowsort
SELECT ALL + cor0.col1 * 21 + cor0.col2 FROM tab0 cor0
----
1839
1993
2038

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( 6 AS REAL ) FROM tab2, tab2 AS cor0, tab2 AS cor1, tab0 AS cor2
----
6

query I rowsort
SELECT ALL - + col0 + 59 AS col1 FROM tab1 AS cor0
----
-21
-5
56

query I rowsort
SELECT 64 AS col1 FROM tab2, tab0, tab2 cor0
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5572
SELECT + + 86 * - col2 * col1 - ( ( col1 ) + - CAST( NULL AS SIGNED ) ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5572
SELECT + + 86 * - col2 * col1 - ( ( col1 ) + - CAST ( NULL AS INTEGER ) ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - cor1.col1 AS col0 FROM tab1, tab0 cor0, tab2 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

query I rowsort
SELECT - 59 AS col2 FROM tab1 AS cor0
----
-59
-59
-59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5575
SELECT ALL 87 * - col1 * col0 + - CAST( + 75 AS SIGNED ) + col1 * CAST( - col0 AS SIGNED ) FROM tab0 AS cor0
----
-181707
-298835
-712787

skipif mysql # not compatible
query I rowsort label-5575
SELECT ALL 87 * - col1 * col0 + - CAST ( + 75 AS INTEGER ) + col1 * CAST ( - col0 AS INTEGER ) FROM tab0 AS cor0
----
-181707
-298835
-712787

query I rowsort
SELECT cor0.col1 * 33 - col1 AS col0 FROM tab0 cor0
----
2752
2912
3104

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5577
SELECT - CAST( 41 AS SIGNED ) FROM tab0 AS cor0
----
-41
-41
-41

skipif mysql # not compatible
query I rowsort label-5577
SELECT - CAST ( 41 AS INTEGER ) FROM tab0 AS cor0
----
-41
-41
-41

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5578
SELECT - CAST( col1 AS SIGNED ) * - col2 AS col2 FROM tab0 cor0
----
2838
7462
97

skipif mysql # not compatible
query I rowsort label-5578
SELECT - CAST ( col1 AS INTEGER ) * - col2 AS col2 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT col2 * col2 * col2 - + 7 AS col1 FROM tab1 AS cor0
----
157457
185186
884729

query I rowsort
SELECT DISTINCT - + ( + cor0.col1 ) + col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - + 37 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to ed4644af7729c2425ea6cc3d84c6504f

query I rowsort
SELECT ALL + col0 + - ( - col2 ) * cor0.col1 AS col0 FROM tab1 AS cor0
----
1328
1407
634

onlyif mysql # use DIV operator for integer division
query I rowsort label-5583
SELECT DISTINCT + col0 DIV + col1 FROM tab2
----
0
1
4

skipif mysql # not compatible
query I rowsort label-5583
SELECT DISTINCT + col0 / + col1 FROM tab2
----
0
1
4

query I rowsort
SELECT DISTINCT + ( - col1 ) * col1 FROM tab1
----
-100
-169
-676

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * - col0 col2 FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT tab1.col2 * - ( + col0 * - col0 ) FROM tab1
----
233472
486
614400

query I rowsort
SELECT 62 AS col2 FROM tab2, tab1 cor0, tab2 AS cor1
----
27 values hashing to 4911b1417a3797d23dd8f38b6ed05c1b

onlyif mysql # use DIV operator for integer division
query I rowsort label-5588
SELECT ALL - col1 * + ( - 41 * - col1 ) - - col2 DIV col0 AS col0 FROM tab0
----
-303235
-339521
-385769

skipif mysql # not compatible
query I rowsort label-5588
SELECT ALL - col1 * + ( - 41 * - col1 ) - - col2 / col0 AS col0 FROM tab0
----
-303235
-339521
-385769

query I rowsort
SELECT + col0 + col0 + - tab1.col2 AS col0 FROM tab1
----
-48
64
71

query I rowsort
SELECT ALL - col1 * + col1 + - 87 * col2 FROM tab2 AS cor0
----
-3310
-3595
-5743

query I rowsort
SELECT - col1 * + ( - 13 * - col1 ) - col0 FROM tab1 AS cor0
----
-1364
-2277
-8791

query I rowsort
SELECT ( - 21 ) - - col1 FROM tab1
----
-11
-8
5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col0 col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT + ( - ( col0 ) ) AS col1 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT ALL ( - col1 ) * col1 + + col1 FROM tab2
----
-272
-3422
-930

onlyif mysql # use DIV operator for integer division
query I rowsort label-5596
SELECT DISTINCT - col0 + col0 DIV - col1 FROM tab2
----
-7
-79
-83

skipif mysql # not compatible
query I rowsort label-5596
SELECT DISTINCT - col0 + col0 / - col1 FROM tab2
----
-7
-79
-83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5597
SELECT + - col0 + col2 * CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5597
SELECT + - col0 + col2 * CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * - cor0.col2 + + 58 AS col1 FROM tab1 AS cor0
----
-1190
-1346
-512

query I rowsort
SELECT DISTINCT col0 * - col0 + + col0 FROM tab1 AS cor0
----
-4032
-6
-6320

query I rowsort
SELECT ALL + + col2 * - col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT cor0.col2 * col1 + - 36 AS col1 FROM tab1 AS cor0
----
1212
1368
534

query I rowsort
SELECT DISTINCT tab0.col0 + - tab0.col1 * + 49 AS col0 FROM tab0, tab0 AS cor0
----
-4190
-4370
-4718

query I rowsort
SELECT ALL + 3 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to 3cf1e377a943589897b8d431a834f1ba

query I rowsort
SELECT ALL + + 99 * + col1 + col1 FROM tab0 AS cor0
----
8600
9100
9700

query I rowsort
SELECT DISTINCT 26 + col0 * + 71 AS col1 FROM tab2 AS cor0
----
523
5564
5635

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 9 col1 FROM tab0 AS cor0
----
-9
-9
-9

query I rowsort
SELECT DISTINCT - col1 - cor0.col0 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT + + 94 AS col1 FROM tab2 AS cor0
----
94

query I rowsort
SELECT ALL - - 79 * + col1 AS col0 FROM tab0 AS cor0
----
6794
7189
7663

query I rowsort
SELECT 15 * col1 * + col1 FROM tab0 cor0
----
110940
124215
141135

query I rowsort
SELECT DISTINCT - 79 AS col1 FROM tab2 cor0
----
-79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 42 * - col2 col2 FROM tab2 AS cor0
----
-1092
-1134
-1596

query I rowsort
SELECT ALL - - col0 + + col1 AS col2 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT ALL - + col0 * - 96 AS col0 FROM tab0 AS cor0
----
2304
3360
8544

query I rowsort
SELECT ALL col0 * + 85 * col0 AS col2 FROM tab0 AS cor0
----
104125
48960
673285

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5616
SELECT DISTINCT - col2 + + CAST( NULL AS DECIMAL ) AS col2 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5616
SELECT DISTINCT - col2 + + CAST ( NULL AS REAL ) AS col2 FROM tab0 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5617
SELECT DISTINCT + col0 + ( - col0 ) DIV + col1 FROM tab1 AS cor0
----
3
58
74

skipif mysql # not compatible
query I rowsort label-5617
SELECT DISTINCT + col0 + ( - col0 ) / + col1 FROM tab1 AS cor0
----
3
58
74

query I rowsort
SELECT ALL cor0.col0 * col1 AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL + col2 * - 0 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT 90 + + col1 AS col2 FROM tab0
----
176
181
187

query I rowsort
SELECT - - cor0.col2 + - col2 * - col1 AS col0 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT DISTINCT ( col1 ) * col2 FROM tab2 cor0
----
1534
646
837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5623
SELECT - - CAST( col2 AS SIGNED ) FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-5623
SELECT - - CAST ( col2 AS INTEGER ) FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL col0 + - col0 * - col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT ALL + ( 67 ) + - col2 FROM tab2 AS cor0
----
29
40
41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - ( cor0.col0 ) * col0 col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL + ( - col0 ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5628
SELECT - - 68 + + col2 * col0 DIV col0 FROM tab2 AS cor0
----
106
94
95

skipif mysql # not compatible
query I rowsort label-5628
SELECT - - 68 + + col2 * col0 / col0 FROM tab2 AS cor0
----
106
94
95

query I rowsort
SELECT DISTINCT + ( + 82 ) * col2 * cor0.col2 + + col2 + + col0 FROM tab1 AS cor0
----
239169
266539
755888

onlyif mysql # use DIV operator for integer division
query I rowsort label-5630
SELECT DISTINCT + col0 + cor0.col1 DIV - col1 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-10
33
6

skipif mysql # not compatible
query I rowsort label-5630
SELECT DISTINCT + col0 + cor0.col1 / - col1 - cor0.col2 AS col2 FROM tab0 AS cor0
----
-10
33
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 21 - + cor0.col2 * - cor0.col2 * + ( col1 ) col0 FROM tab2 AS cor0
----
22620
24569
39905

query I rowsort
SELECT + col2 * 28 + col0 * + col0 * col1 FROM tab0 AS cor0
----
118853
50460
723107

query I rowsort
SELECT DISTINCT + col0 * ( + cor0.col2 ) FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT ALL - col2 * col0 - col0 FROM tab2
----
-196
-2106
-3081

query I rowsort
SELECT col2 - - 26 * col1 FROM tab1
----
317
434
730

onlyif mysql # use DIV operator for integer division
query I rowsort label-5636
SELECT DISTINCT - ( - col1 ) DIV col1 col0 FROM tab0 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5636
SELECT DISTINCT - ( - col1 ) / col1 col0 FROM tab0 AS cor0
----
1

query I rowsort
SELECT DISTINCT - - col0 * 12 FROM tab1 AS cor0
----
36
768
960

query I rowsort
SELECT ALL - 41 + ( - col1 ) AS col0 FROM tab2 AS cor0
----
-100
-58
-72

query I rowsort
SELECT ALL ( col0 ) * - col1 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL col0 * col2 * col1 FROM tab2
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-5641
SELECT ALL + ( - col2 ) * + col0 + + 77 + col0 DIV - col0 FROM tab0
----
-716
-7222
41

skipif mysql # not compatible
query I rowsort label-5641
SELECT ALL + ( - col2 ) * + col0 + + 77 + col0 / - col0 FROM tab0
----
-716
-7222
41

query I rowsort
SELECT tab2.col1 + col2 * col0 + + col1 * tab2.col1 AS col1 FROM tab2
----
1181
3308
5568

onlyif mysql # use DIV operator for integer division
query I rowsort label-5643
SELECT DISTINCT + - col1 DIV col2 + 90 DIV ( - col2 + + CAST( - col0 AS SIGNED ) ) AS col1 FROM tab0 AS cor0
----
-1
-3
-99

skipif mysql # not compatible
query I rowsort label-5643
SELECT DISTINCT + - col1 / col2 + 90 / ( - col2 + + CAST ( - col0 AS INTEGER ) ) AS col1 FROM tab0 AS cor0
----
-1
-3
-99

query I rowsort
SELECT ALL 68 * col2 + - col1 FROM tab1
----
3646
3866
6515

query I rowsort
SELECT 15 * - ( - col2 ) + col2 * col1 AS col1 FROM tab2 AS cor0
----
1216
1242
1924

query I rowsort
SELECT ALL 4 * cor0.col2 AS col1 FROM tab1, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 48e28c5834d26a6a11c374f2c89f7120

query I rowsort
SELECT - cor0.col2 * + ( + 62 ) - + col0 FROM tab2 AS cor0
----
-1681
-1690
-2435

query I rowsort
SELECT ALL - col1 * col0 + 14 * col2 FROM tab1 cor0
----
158
304
678

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * - col0 + 18 * - col0 col0 FROM tab1 AS cor0
----
-45
2944
4960

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( - 81 ) col2 FROM tab1, tab2 AS cor0
----
-81

query I rowsort
SELECT - ( col2 ) - col0 FROM tab2 cor0
----
-104
-117
-34

onlyif mysql # use DIV operator for integer division
query I rowsort label-5652
SELECT - - cor0.col1 DIV + col1 - col0 AS col2 FROM tab1 AS cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-5652
SELECT - - cor0.col1 / + col1 - col0 AS col2 FROM tab1 AS cor0
----
-2
-63
-79

query I rowsort
SELECT DISTINCT + 30 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1
----
30

query I rowsort
SELECT + + 37 - - col2 FROM tab0 AS cor0
----
119
38
70

query I rowsort
SELECT 58 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 9ee363c6ac19cfdb8a50c7dfd5cc2b8a

query I rowsort
SELECT DISTINCT - col1 * col0 + ( - tab2.col1 ) AS col0 FROM tab2
----
-1360
-248
-4661

query I rowsort
SELECT col1 * 47 AS col2 FROM tab1
----
1222
470
611

onlyif mysql # use DIV operator for integer division
query I rowsort label-5658
SELECT ALL tab0.col2 + col2 DIV - 35 FROM tab0
----
1
33
80

skipif mysql # not compatible
query I rowsort label-5658
SELECT ALL tab0.col2 + col2 / - 35 FROM tab0
----
1
33
80

query I rowsort
SELECT ALL ( col0 ) AS col0 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT - 44 + + col1 FROM tab0 AS cor0
----
42
47
53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5661
SELECT DISTINCT cor0.col0 * col0 * - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5661
SELECT DISTINCT cor0.col0 * col0 * - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + + cor0.col2 * - col1 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ( 37 ) * + col2 FROM tab1
----
1998
2109
3552

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - ( tab2.col1 ) ) * - col1 col0 FROM tab2
----
289
3481
961

onlyif mysql # use DIV operator for integer division
query I rowsort label-5665
SELECT ALL - col0 DIV - col2 AS col1 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-5665
SELECT ALL - col0 / - col2 AS col1 FROM tab0
----
0
1
35

query I rowsort
SELECT + - 63 * + col2 AS col2 FROM tab0 cor0
----
-2079
-5166
-63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col0 + - col2 col1 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT col0 + col1 * - col2 AS col2 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT ALL + col0 * col2 * - col1 AS col0 FROM tab0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT tab1.col0 * - tab1.col2 AS col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT - + 17 * 69 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to a7c22b6b5f680c62fcd7f5f0ea7f3629

query I rowsort
SELECT DISTINCT col1 * col0 * - 18 FROM tab0 cor0
----
-145782
-37152
-61110

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col1 + + col1 * cor0.col1 col1 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT ALL + + col0 + - col1 AS col1 FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT DISTINCT - 42 + + tab1.col2 * cor0.col1 FROM tab1, tab0, tab1 AS cor0
----
9 values hashing to 90f1653b6e2df442181763346fadbf7c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - cor0.col1 * 62 col0 FROM tab2 AS cor0
----
-1054
-1922
-3658

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col2 col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT ALL 46 * + col2 FROM tab2
----
1196
1242
1748

onlyif mysql # use DIV operator for integer division
query I rowsort label-5679
SELECT DISTINCT - col1 DIV col1 AS col2 FROM tab0
----
-1

skipif mysql # not compatible
query I rowsort label-5679
SELECT DISTINCT - col1 / col1 AS col2 FROM tab0
----
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5680
SELECT + tab2.col1 + + cor0.col1 + cor0.col0 DIV + cor0.col2 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to b51ccd99e37db5a8f018d89d118d9180

skipif mysql # not compatible
query I rowsort label-5680
SELECT + tab2.col1 + + cor0.col1 + cor0.col0 / + cor0.col2 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to b51ccd99e37db5a8f018d89d118d9180

query I rowsort
SELECT 61 - - col1 AS col0 FROM tab2
----
120
78
92

query I rowsort
SELECT DISTINCT - col0 * col1 * col1 AS col2 FROM tab1
----
-13520
-2028
-6400

query IIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab0, tab2 cor1, tab2 AS cor2
----
972 values hashing to a698694a7dac245e42212ff0316bdf45

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * ( ( - col2 ) ) col1 FROM tab2
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5685
SELECT + cor0.col0 * CAST( col1 + col0 AS SIGNED ) * - col0 AS col0 FROM tab1 AS cor0
----
-261
-303104
-595200

skipif mysql # not compatible
query I rowsort label-5685
SELECT + cor0.col0 * CAST ( col1 + col0 AS INTEGER ) * - col0 AS col0 FROM tab1 AS cor0
----
-261
-303104
-595200

query I rowsort
SELECT - col1 * - ( + col2 ) FROM tab2
----
1534
646
837

query I rowsort
SELECT + - col2 * - ( - col0 ) AS col2 FROM tab1 cor0
----
-162
-3648
-7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5688
SELECT - 34 DIV + col0 + col0 * col2 AS col0 FROM tab1 AS cor0
----
151
3648
7680

skipif mysql # not compatible
query I rowsort label-5688
SELECT - 34 / + col0 + col0 * col2 AS col0 FROM tab1 AS cor0
----
151
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-5689
SELECT + ( col1 + col0 ) DIV + tab0.col2 col0 FROM tab0
----
132
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5689
SELECT + ( col1 + col0 ) / + tab0.col2 col0 FROM tab0
----
132
2
3

query I rowsort
SELECT + col1 * + cor0.col1 + cor0.col0 FROM tab2 cor0
----
3559
368
968

query I rowsort
SELECT 84 FROM tab2, tab0 AS cor0, tab1 AS cor1, tab0 cor2
----
81 values hashing to 3c092ed1a99ddb5afc7049fd2b9427f9

query I rowsort
SELECT - 21 * col0 FROM tab1 AS cor0
----
-1344
-1680
-63

query I rowsort
SELECT ALL + col0 * col1 + col0 * + ( - cor0.col2 + + 18 ) FROM tab2 AS cor0
----
-237
154
3978

query I rowsort
SELECT ALL - 95 + col2 * + ( col0 ) + col2 AS col2 FROM tab2 AS cor0
----
121
1959
2945

query I rowsort
SELECT col0 * - tab2.col0 AS col2 FROM tab2
----
-49
-6084
-6241

query I rowsort
SELECT + ( + ( + col0 ) ) * + 55 FROM tab1
----
165
3520
4400

query I rowsort
SELECT 25 * col2 FROM tab2 AS cor0
----
650
675
950

onlyif mysql # use DIV operator for integer division
query I rowsort label-5698
SELECT + col0 * - col2 + col0 DIV col1 col0 FROM tab1 AS cor0
----
-162
-3642
-7674

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5698
SELECT + col0 * - col2 + col0 / col1 col0 FROM tab1 AS cor0
----
-162
-3642
-7674

query I rowsort
SELECT ALL + - ( - cor0.col1 ) AS col0 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT + cor0.col2 * - col1 * col2 + col1 FROM tab0 AS cor0
----
-611793
-93568
0

query I rowsort
SELECT DISTINCT - 22 + col1 AS col1 FROM tab1 AS cor0
----
-12
-9
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5702
SELECT ALL + col2 * + ( + cor0.col0 * - CAST( NULL AS SIGNED ) ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5702
SELECT ALL + col2 * + ( + cor0.col0 * - CAST ( NULL AS INTEGER ) ) AS col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 34 AS col2 FROM tab2 cor0
----
34
34
34

query I rowsort
SELECT DISTINCT - ( col0 ) * col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL + col1 * 55 AS col1 FROM tab2 AS cor0
----
1705
3245
935

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5706
SELECT DISTINCT + col0 + - col0 + col1 * CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-5706
SELECT DISTINCT + col0 + - col0 + col1 * CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5707
SELECT ALL cor0.col0 + col0 * col1 + + CAST( + ( - col2 ) AS SIGNED ) * - ( 17 + - col0 * col0 ) FROM tab1 AS cor0
----
-231799
-611648
513

skipif mysql # not compatible
query I rowsort label-5707
SELECT ALL cor0.col0 + col0 * col1 + + CAST ( + ( - col2 ) AS INTEGER ) * - ( 17 + - col0 * col0 ) FROM tab1 AS cor0
----
-231799
-611648
513

query I rowsort
SELECT DISTINCT 62 + - col0 FROM tab1 cor0
----
-18
-2
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + col0 col0 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT ALL col0 * + 23 AS col1 FROM tab0 AS cor0
----
2047
552
805

query I rowsort
SELECT ALL 53 * col0 FROM tab2 AS cor0
----
371
4134
4187

query I rowsort
SELECT - 11 * 11 + col2 AS col2 FROM tab1 AS cor0
----
-25
-64
-67

query I rowsort
SELECT DISTINCT + + cor0.col2 * - ( col0 ) FROM tab1 cor0
----
-162
-3648
-7680

query I rowsort
SELECT - 89 + col1 AS col1 FROM tab0 AS cor0
----
-3
2
8

query I rowsort
SELECT cor0.col2 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1, tab2 cor2
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT ALL - 75 * - col0 FROM tab0 cor0
----
1800
2625
6675

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0, tab1 cor2
----
3645 values hashing to 71d467ba3372dfdd21847af1687c92e7

query I rowsort
SELECT - tab2.col1 * + col2 + col2 * col0 FROM tab2
----
-648
2356
494

query I rowsort
SELECT DISTINCT + cor0.col2 * col0 * cor0.col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT col1 * + ( + cor0.col1 ) FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT + + cor0.col2 * - ( - 55 ) + col1 FROM tab2 AS cor0
----
1489
1516
2107

query I rowsort
SELECT - col2 + col1 - - col2 AS col1 FROM tab0
----
86
91
97

query I rowsort
SELECT + 88 * + col2 * col1 AS col2 FROM tab0
----
249744
656656
8536

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0, tab2, tab0 cor1
----
972 values hashing to e4c748f267e8d2a0e6d563281e1fb975

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 + - ( - col2 ) col2 FROM tab1
----
0

query I rowsort
SELECT - tab1.col1 - - col1 FROM tab1
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + 40 col1 FROM tab0
----
122
41
73

query I rowsort
SELECT - col1 * - ( - col0 ) - col2 AS col1 FROM tab0
----
-2097
-3396
-8181

query I rowsort
SELECT - col2 * 1 + 32 * col2 FROM tab1
----
1674
1767
2976

query I rowsort
SELECT DISTINCT + - col2 + 42 FROM tab0 cor0
----
-40
41
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-5731
SELECT ALL - col2 + - col1 DIV - col0 FROM tab0 AS cor0
----
-30
-81
1

skipif mysql # not compatible
query I rowsort label-5731
SELECT ALL - col2 + - col1 / - col0 FROM tab0 AS cor0
----
-30
-81
1

query I rowsort
SELECT + col2 + + 57 + col1 FROM tab0
----
155
176
230

onlyif mysql # use DIV operator for integer division
query I rowsort label-5733
SELECT DISTINCT - col2 DIV - ( col2 ) + + col1 AS col2 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-5733
SELECT DISTINCT - col2 / - ( col2 ) + + col1 AS col2 FROM tab1
----
11
14
27

query I rowsort
SELECT - - cor0.col0 + + cor0.col2 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
2919
3313
9296

query I rowsort
SELECT + + 69 + col1 * + col1 FROM tab2 AS cor0
----
1030
3550
358

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5736
SELECT col1 + CAST( col2 AS SIGNED ) + col1 FROM tab2
----
144
72
89

skipif mysql # not compatible
query I rowsort label-5736
SELECT col1 + CAST ( col2 AS INTEGER ) + col1 FROM tab2
----
144
72
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - col0 + 38 * col0 col1 FROM tab2 AS cor0
----
315
9048
9243

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5738
SELECT DISTINCT tab0.col0 + + CAST( + col1 AS SIGNED ) * - col0 + + col1 * + tab0.col2 AS col1 FROM tab0
----
-3263
-548
798

skipif mysql # not compatible
query I rowsort label-5738
SELECT DISTINCT tab0.col0 + + CAST ( + col1 AS INTEGER ) * - col0 + + col1 * + tab0.col2 AS col1 FROM tab0
----
-3263
-548
798

query I rowsort
SELECT ALL - 94 * - col1 FROM tab0 AS cor0
----
8084
8554
9118

query I rowsort
SELECT DISTINCT 12 * col0 FROM tab1
----
36
768
960

onlyif mysql # use DIV operator for integer division
query I rowsort label-5741
SELECT ALL - + col0 DIV 43 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-5741
SELECT ALL - + col0 / 43 FROM tab1 AS cor0
----
-1
-1
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5742
SELECT ALL + CAST( - col2 AS SIGNED ) AS col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-5742
SELECT ALL + CAST ( - col2 AS INTEGER ) AS col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL + 92 AS col2 FROM tab2 AS cor0
----
92
92
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-5744
SELECT - - 47 DIV + 10 FROM tab0 AS cor0
----
4
4
4

skipif mysql # not compatible
query I rowsort label-5744
SELECT - - 47 / + 10 FROM tab0 AS cor0
----
4
4
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-5745
SELECT DISTINCT + - ( - 18 ) DIV col1 FROM tab2 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-5745
SELECT DISTINCT + - ( - 18 ) / col1 FROM tab2 AS cor0
----
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-5746
SELECT + col0 DIV + col2 AS col1 FROM tab0 AS cor0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-5746
SELECT + col0 / + col2 AS col1 FROM tab0 AS cor0
----
0
1
35

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * + ( cor0.col2 ) * 29 col1 FROM tab2 AS cor0
----
18734
24273
44486

query I rowsort
SELECT 66 + col2 * ( - col1 ) * + col1 FROM tab0
----
-244002
-678976
-9343

query I rowsort
SELECT - col0 * - col2 + tab1.col2 * 78 AS col1 FROM tab1
----
15168
4374
8094

query I rowsort
SELECT DISTINCT col2 - col2 * 31 FROM tab1 AS cor0
----
-1620
-1710
-2880

query I rowsort
SELECT DISTINCT + + col2 - col1 * - 17 FROM tab2 AS cor0
----
1029
327
554

query I rowsort
SELECT DISTINCT + 44 * - cor0.col0 - 61 FROM tab1 AS cor0
----
-193
-2877
-3581

query I rowsort
SELECT ALL + col0 * - cor0.col2 + + col2 * + col1 AS col2 FROM tab2 AS cor0
----
-2356
-494
648

query I rowsort
SELECT ALL - + cor0.col1 + - col0 * + col1 + - ( + cor0.col0 ) AS col1 FROM tab0 AS cor0
----
-2174
-3527
-8279

query I rowsort
SELECT ALL 34 * - col1 + col2 * + cor0.col1 FROM tab1 cor0
----
230
520
806

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5756
SELECT DISTINCT - col0 - + col0 * - CAST( col0 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
4032
6
6320

skipif mysql # not compatible
query I rowsort label-5756
SELECT DISTINCT - col0 - + col0 * - CAST ( col0 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT col2 + col1 * col1 - - cor0.col1 FROM tab2 AS cor0
----
1019
344
3566

query I rowsort
SELECT DISTINCT col2 + 65 FROM tab1 cor0
----
119
122
161

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5759
SELECT ALL col0 + + CAST( NULL AS DECIMAL ) + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5759
SELECT ALL col0 + + CAST ( NULL AS REAL ) + col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + 52 col0 FROM tab1 AS cor0
----
26
39
42

query I rowsort
SELECT ALL - cor0.col1 * - cor0.col0 AS col1 FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-5762
SELECT ALL + col1 DIV 6 FROM tab2 AS cor0
----
2
5
9

skipif mysql # not compatible
query I rowsort label-5762
SELECT ALL + col1 / 6 FROM tab2 AS cor0
----
2
5
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5763
SELECT + col1 + - CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
109
67
80

skipif mysql # not compatible
query I rowsort label-5763
SELECT + col1 + - CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - col1 + 70 AS col1 FROM tab0 cor0
----
-16
-21
-27

query I rowsort
SELECT ALL + col1 + + ( - ( col0 ) ) FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT + col1 * - col1 * col1 + + col2 * + ( - col0 ) FROM tab2 cor0
----
-207407
-29980
-7915

query I rowsort
SELECT - col0 * col1 + - col2 - - col2 AS col0 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * - col2 col0 FROM tab1 cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT + + col0 + col2 AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT - tab1.col0 * - col2 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT - col0 + - ( 79 ) FROM tab2 AS cor0
----
-157
-158
-86

query I rowsort
SELECT - ( + 4 ) AS col0 FROM tab1
----
-4
-4
-4

query I rowsort
SELECT ( - col2 + col2 ) AS col1 FROM tab0
----
0
0
0

query I rowsort
SELECT ALL + ( 39 ) * col0 FROM tab2
----
273
3042
3081

query I rowsort
SELECT DISTINCT - + 84 + - ( col0 ) FROM tab0 AS cor0
----
-108
-119
-173

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5776
SELECT - CAST( NULL AS SIGNED ) * 73 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5776
SELECT - CAST ( NULL AS INTEGER ) * 73 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 * - col1 + + col0 FROM tab0 AS cor0
----
-7372
-8192
-9374

query I rowsort
SELECT + col0 + - 39 AS col0 FROM tab1 AS cor0
----
-36
25
41

onlyif mysql # use DIV operator for integer division
query I rowsort label-5779
SELECT ALL - 23 * col1 * col1 + col1 DIV + cor0.col2 FROM tab1 AS cor0
----
-15548
-2300
-3887

skipif mysql # not compatible
query I rowsort label-5779
SELECT ALL - 23 * col1 * col1 + col1 / + cor0.col2 FROM tab1 AS cor0
----
-15548
-2300
-3887

query I rowsort
SELECT DISTINCT col2 + + col2 * - cor0.col2 AS col1 FROM tab2 AS cor0
----
-1406
-650
-702

query I rowsort
SELECT DISTINCT - col2 * col2 + - col1 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT ALL - col1 - - col0 AS col2 FROM tab0 AS cor0
----
-2
-62
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5783
SELECT + cor0.col1 + col1 DIV col0 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-5783
SELECT + cor0.col1 + col1 / col0 FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT DISTINCT col0 + cor0.col1 AS col1 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT ALL col2 - + col2 * col2 FROM tab1 cor0
----
-2862
-3192
-9120

query I rowsort
SELECT + col2 * ( col1 ) + col1 AS col2 FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT ALL - - cor0.col2 + - ( - col1 ) * + col0 FROM tab0 AS cor0
----
2097
3396
8181

query I rowsort
SELECT DISTINCT col0 + - 38 AS col1 FROM tab0 AS cor0
----
-14
-3
51

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5789
SELECT ALL + - col0 * CAST( - col0 AS SIGNED ) + col0 * col0 AS col1 FROM tab2 cor0
----
12168
12482
98

skipif mysql # not compatible
query I rowsort label-5789
SELECT ALL + - col0 * CAST ( - col0 AS INTEGER ) + col0 * col0 AS col1 FROM tab2 cor0
----
12168
12482
98

query I rowsort
SELECT ALL - col2 + - col2 - col1 * - cor0.col0 FROM tab1 AS cor0
----
-30
526
848

query I rowsort
SELECT DISTINCT - col1 * cor0.col1 + - col2 + + col1 * cor0.col1 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT - cor0.col2 + - 33 FROM tab1 AS cor0
----
-129
-87
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col2 * - col1 + - col2 col2 FROM tab0 AS cor0
----
-2871
-7544
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col1 + - col0 col0 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT - col2 * ( col1 ) + col0 + + col0 FROM tab2 AS cor0
----
-1378
-488
-823

query I rowsort
SELECT - col2 + - ( cor0.col0 ) FROM tab1 AS cor0
----
-121
-176
-57

query I rowsort
SELECT + col0 * - cor0.col0 * + col1 + col2 AS col1 FROM tab0 AS cor0
----
-118824
-49503
-720729

query I rowsort
SELECT - - cor0.col1 + 9 FROM tab0 AS cor0
----
100
106
95

query I rowsort
SELECT cor0.col0 + ( - 11 ) + + col1 * + col1 FROM tab2 AS cor0
----
3548
357
957

query I rowsort
SELECT - 68 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 5febf382d36d6e0191889c41b928786f

query IIIIII rowsort
SELECT * FROM tab1, tab1 AS cor0 WHERE NULL = ( NULL )
----

query I rowsort
SELECT ALL 4 * 47 AS col1 FROM tab1, tab2 AS cor0
----
9 values hashing to 228fa03c91d763366172e642f3f8c466

query I rowsort
SELECT - + col1 * + col1 + - col0 AS col2 FROM tab2 cor0
----
-3559
-368
-968

query I rowsort
SELECT - col0 + + col0 * col0 FROM tab0 AS cor0
----
1190
552
7832

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 + - col1 col1 FROM tab0 AS cor0
----
-119
-173
-98

query I rowsort
SELECT ALL + tab0.col1 * tab0.col0 AS col1 FROM tab0
----
2064
3395
8099

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT + col2 * col2 NOT IN ( col2 * col1 / col0 - + col1 )
----

query I rowsort
SELECT col0 * + col0 * col2 AS col0 FROM tab1 WHERE col1 NOT IN ( + col0 )
----
233472
486
614400

query I rowsort
SELECT DISTINCT + col1 + - col0 * - col0 AS col1 FROM tab0 WHERE NOT - col0 IN ( - col0 )
----

query I rowsort
SELECT DISTINCT - col0 * - col0 + - col0 FROM tab0
----
1190
552
7832

query I rowsort
SELECT ALL 60 + + col1 FROM tab2
----
119
77
91

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-5813
SELECT - 16 DIV + col2 AS col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-5813
SELECT - 16 / + col2 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - tab2.col2 * + col1 AS col1 FROM tab2
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT col1 - col0 * col2 FROM tab0
----
-706
-7207
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-5816
SELECT DISTINCT + col2 DIV + col1 - col2 col2 FROM tab1
----
-52
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5816
SELECT DISTINCT + col2 / + col1 - col2 col2 FROM tab1
----
-52
-89

query I rowsort
SELECT + col1 + + col1 * - col0 - - col2 FROM tab2 AS cor0
----
-1288
-159
-4517

query I rowsort
SELECT + cor0.col1 + - 63 FROM tab0, tab2 AS cor0
----
9 values hashing to bebc0abe8644b7e85fca610a70098c2f

query I rowsort
SELECT DISTINCT + cor0.col2 - col1 FROM tab0 AS cor0
----
-53
-9
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 20 + col2 col0 FROM tab0 cor0
----
102
21
53

query I rowsort
SELECT DISTINCT col2 + col2 * col0 AS col2 FROM tab1 AS cor0
----
216
3705
7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 45 col0 FROM tab0 AS cor0
----
45
45
45

query I rowsort
SELECT DISTINCT - + 0 * col2 AS col0 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5824
SELECT ALL + 65 + col1 DIV 54 FROM tab0 AS cor0
----
66
66
66

skipif mysql # not compatible
query I rowsort label-5824
SELECT ALL + 65 + col1 / 54 FROM tab0 AS cor0
----
66
66
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5825
SELECT + - col2 / col2 + - CAST( NULL AS SIGNED ) * + 0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5825
SELECT + - col2 / col2 + - CAST ( NULL AS INTEGER ) * + 0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-5826
SELECT + + col2 DIV - col0 + col1 FROM tab0 AS cor0
----
85
91
97

skipif mysql # not compatible
query I rowsort label-5826
SELECT + + col2 / - col0 + col1 FROM tab0 AS cor0
----
85
91
97

query I rowsort
SELECT 94 + + col1 FROM tab1 AS cor0
----
104
107
120

query I rowsort
SELECT ALL + cor0.col2 - - col0 * 38 FROM tab1 AS cor0
----
168
2489
3136

query I rowsort
SELECT ( col2 ) * ( + 28 ) + col1 AS col0 FROM tab0 AS cor0
----
1010
125
2387

query I rowsort
SELECT ALL + - 63 * col0 AS col1 FROM tab1 AS cor0
----
-189
-4032
-5040

query I rowsort
SELECT ALL + cor0.col1 * cor0.col1 * + col2 + - cor0.col2 FROM tab2 AS cor0
----
10944
25920
90480

query I rowsort
SELECT ALL - col1 * cor0.col1 + - col0 AS col0 FROM tab1 cor0
----
-164
-249
-679

query I rowsort
SELECT col0 + 93 AS col1 FROM tab1 AS cor0
----
157
173
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * 23 * ( col1 ) col1 FROM tab2 AS cor0
----
14858
19251
35282

onlyif mysql # use DIV operator for integer division
query I rowsort label-5835
SELECT DISTINCT - col0 + - ( col0 ) + + col2 DIV + col2 AS col0 FROM tab0 AS cor0
----
-177
-47
-69

skipif mysql # not compatible
query I rowsort label-5835
SELECT DISTINCT - col0 + - ( col0 ) + + col2 / + col2 AS col0 FROM tab0 AS cor0
----
-177
-47
-69

query I rowsort
SELECT ALL - col2 + - col2 * col1 AS col2 FROM tab0 AS cor0
----
-2871
-7544
-98

query I rowsort
SELECT ALL - 12 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to e698dd57d3aac30af14ce35da434bb45

query I rowsort
SELECT + col1 * + col1 + col0 FROM tab2 AS cor0
----
3559
368
968

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5839
SELECT ALL - + col1 * CAST( NULL AS SIGNED ) + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5839
SELECT ALL - + col1 * CAST ( NULL AS INTEGER ) + cor0.col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col2 + 26 AS col1 FROM tab0 AS cor0
----
108
27
59

query I rowsort
SELECT + 76 - - 20 * - col0 AS col1 FROM tab2 AS cor0
----
-1484
-1504
-64

query I rowsort
SELECT ALL - 21 * col1 AS col2 FROM tab2 AS cor0
----
-1239
-357
-651

query I rowsort
SELECT 61 * col1 FROM tab1 AS cor0
----
1586
610
793

query I rowsort
SELECT col0 - ( - col2 ) AS col0 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT + 18 * - 6 - - cor0.col2 FROM tab1, tab0 cor0
----
9 values hashing to 79638ff9bc8ab4921e22ad66cfc2b33e

onlyif mysql # use DIV operator for integer division
query I rowsort label-5846
SELECT - cor1.col0 DIV 50 + cor0.col0 + cor0.col1 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 01d93a3e9c76152a52849f29f79c48f3

skipif mysql # not compatible
query I rowsort label-5846
SELECT - cor1.col0 / 50 + cor0.col0 + cor0.col1 AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 01d93a3e9c76152a52849f29f79c48f3

onlyif mysql # use DIV operator for integer division
query I rowsort label-5847
SELECT + ( tab0.col0 ) DIV col2 AS col2 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-5847
SELECT + ( tab0.col0 ) / col2 AS col2 FROM tab0
----
0
1
35

query I rowsort
SELECT ALL + col1 * - col2 AS col0 FROM tab0 cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 55 col1 FROM tab0 AS cor0
----
55

query I rowsort
SELECT DISTINCT + - col2 + cor0.col2 FROM tab2 AS cor0
----
0

query I rowsort
SELECT - + cor0.col1 * col1 + col0 AS col2 FROM tab1 AS cor0
----
-36
-673
-89

query I rowsort
SELECT DISTINCT - cor0.col1 * + col0 + + col0 * - 77 AS col2 FROM tab2 AS cor0
----
-10608
-7426
-756

query I rowsort
SELECT 21 * col2 AS col1 FROM tab0
----
1722
21
693

query I rowsort
SELECT + col2 * col1 + col1 AS col1 FROM tab1
----
1261
1430
580

query I rowsort
SELECT DISTINCT 99 * + col0 + col1 * - tab2.col1 * - tab2.col2 FROM tab2
----
18803
26640
98228

query I rowsort
SELECT tab0.col0 + - ( tab0.col2 ) + + col1 FROM tab0
----
131
77
98

query I rowsort
SELECT DISTINCT 93 * col2 - col2 * + col0 FROM tab1
----
1248
1653
4860

onlyif mysql # use DIV operator for integer division
query I rowsort label-5858
SELECT DISTINCT col2 - + col0 DIV + col1 FROM tab1
----
51
54
90

skipif mysql # not compatible
query I rowsort label-5858
SELECT DISTINCT col2 - + col0 / + col1 FROM tab1
----
51
54
90

query I rowsort
SELECT DISTINCT + 43 + + col0 AS col1 FROM tab1 AS cor0
----
107
123
46

query I rowsort
SELECT + - col1 * col0 - - col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT 92 + cor0.col0 * 62 FROM tab2 AS cor0
----
4928
4990
526

query I rowsort
SELECT ALL - col1 + + col2 AS col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL ( col1 ) + - 69 FROM tab2 AS cor0
----
-10
-38
-52

query I rowsort
SELECT DISTINCT - 48 * col0 AS col0 FROM tab0
----
-1152
-1680
-4272

query I rowsort
SELECT ALL ( + ( + col2 ) * 82 ) AS col2 FROM tab2
----
2132
2214
3116

query I rowsort
SELECT ALL + ( + col0 * 50 ) + + col2 * col1 FROM tab2
----
1187
4596
5434

query I rowsort
SELECT col1 * - col1 + ( 84 * col0 ) AS col1 FROM tab0
----
-5380
-6469
-805

onlyif mysql # use DIV operator for integer division
query I rowsort label-5868
SELECT DISTINCT 52 + col2 DIV - col0 FROM tab1
----
34
51
52

skipif mysql # not compatible
query I rowsort label-5868
SELECT DISTINCT 52 + col2 / - col0 FROM tab1
----
34
51
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-5869
SELECT 88 + + col1 * col0 DIV col1 + + col2 FROM tab2
----
122
192
205

skipif mysql # not compatible
query I rowsort label-5869
SELECT 88 + + col1 * col0 / col1 + + col2 FROM tab2
----
122
192
205

query I rowsort
SELECT - col1 * tab0.col1 AS col2 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT - col2 * + 84 + - col2 FROM tab1
----
-4590
-4845
-8160

query I rowsort
SELECT ALL ( 16 ) * + cor0.col2 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to d059351c64af69b130200d54d42fcde1

query I rowsort
SELECT ALL + - col1 + - ( - cor0.col0 ) * col2 AS col1 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT + col2 + - ( ( col2 ) ) AS col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + 22 AS col1 FROM tab2 cor0
----
22
22
22

query I rowsort
SELECT DISTINCT 28 * - 74 FROM tab2 cor0
----
-2072

query I rowsort
SELECT ALL ( - ( col0 ) ) + col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT ( col0 ) * + col0 + cor0.col0 FROM tab2 AS cor0
----
56
6162
6320

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - - CAST ( col2 AS REAL ) + col1 AS col0 FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT DISTINCT - col0 + + 31 FROM tab1 AS cor0
----
-33
-49
28

query I rowsort
SELECT ALL - - cor0.col2 * + cor0.col0 + cor0.col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL - ( col1 ) * col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT 80 * col0 AS col2 FROM tab2 AS cor0
----
560
6240
6320

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5884
SELECT ALL + col0 / - 44 + + col0 / - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5884
SELECT ALL + col0 / - 44 + + col0 / - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL cor0.col0 * col0 + + col1 FROM tab2 AS cor0
----
6143
6258
80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5886
SELECT + - 50 * col2 + col1 * + CAST( - 25 AS SIGNED ) col2 FROM tab2 cor0
----
-2125
-2325
-2775

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-5886
SELECT + - 50 * col2 + col1 * + CAST ( - 25 AS INTEGER ) col2 FROM tab2 cor0
----
-2125
-2325
-2775

query I rowsort
SELECT DISTINCT - + col0 + 69 FROM tab1 AS cor0
----
-11
5
66

query I rowsort
SELECT ALL + 79 + + col1 * cor0.col0 FROM tab2 AS cor0
----
1422
296
4681

query I rowsort
SELECT 31 * - cor0.col1 AS col1 FROM tab1 AS cor0
----
-310
-403
-806

query I rowsort
SELECT ALL - 2 AS col0 FROM tab1 AS cor0
----
-2
-2
-2

query I rowsort
SELECT DISTINCT 99 + 91 * + col2 FROM tab1 cor0
----
5013
5286
8835

query I rowsort
SELECT DISTINCT - - 39 * 92 FROM tab0 AS cor0
----
3588

query I rowsort
SELECT + col0 * col1 + col1 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + 44 + col2 col0 FROM tab1 AS cor0
----
-2759
-3424
-78

query I rowsort
SELECT DISTINCT col2 * ( + col1 ) FROM tab2
----
1534
646
837

query I rowsort
SELECT DISTINCT 87 * 7 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1, tab2 AS cor2
----
609

query I rowsort
SELECT 11 AS col1 FROM tab0, tab0 AS cor0
----
9 values hashing to f4d199584b44732f1a897e6691b4ea00

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT - CAST ( col2 + + col0 AS REAL ) AS col0 FROM tab0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT + 0 * + col2 AS col2 FROM tab2
----
0

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( 90 AS REAL ) AS col2 FROM tab1
----
90
90
90

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab2 cor0, tab0 AS cor1, tab1 cor2
----
972 values hashing to 2d99dda76af061a3fac120e0e49e6c53

query I rowsort
SELECT 86 * + col1 FROM tab1 cor0
----
1118
2236
860

query I rowsort
SELECT - 86 AS col1 FROM tab0
----
-86
-86
-86

query I rowsort
SELECT 40 AS col0 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to e4d10f7d6c34a281f524e45e82ebd2a0

query I rowsort
SELECT DISTINCT - 69 + - col0 FROM tab1
----
-133
-149
-72

query I rowsort
SELECT DISTINCT - col2 * col1 + + col0 FROM tab1
----
-1168
-1401
-506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col2 - cor0.col2 col1 FROM tab2 cor0
----
-52
-54
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col0 ) + + ( + col2 ) * - col1 col2 FROM tab2 AS cor0
----
-1456
-567
-830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 39 col2 FROM tab2 AS cor0
----
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5910
SELECT + - col2 * + cor0.col1 - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5910
SELECT + - col2 * + cor0.col1 - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( + col1 ) + - col0 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT DISTINCT col0 * + 99 FROM tab2 AS cor0
----
693
7722
7821

query I rowsort
SELECT col0 + ( + col0 ) FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL col0 + - ( cor0.col2 * col2 ) FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT ALL + col0 * - 30 AS col2 FROM tab2 AS cor0
----
-210
-2340
-2370

onlyif mysql # use DIV operator for integer division
query I rowsort label-5916
SELECT + col2 DIV - col1 + - col2 AS col0 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-5916
SELECT + col2 / - col1 + - col2 AS col0 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT col2 * + 54 - col2 AS col2 FROM tab0 AS cor0
----
1749
4346
53

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5918
SELECT + cor0.col2 + ( + col1 * col0 ) - CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5918
SELECT + cor0.col2 + ( + col1 * col0 ) - CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col2 + + col1 * - cor0.col2 AS col0 FROM tab1 AS cor0
----
-1152
-1350
-513

query I rowsort
SELECT + cor0.col0 + 44 AS col2 FROM tab1 AS cor0
----
108
124
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 53 * + 8 + col1 col2 FROM tab1 AS cor0
----
434
437
450

query I rowsort
SELECT ALL + col0 * - 91 AS col2 FROM tab0 AS cor0
----
-2184
-3185
-8099

query I rowsort
SELECT ALL col1 + col1 * col1 AS col0 FROM tab2 AS cor0
----
306
3540
992

query I rowsort
SELECT col2 + 70 AS col1 FROM tab2 AS cor0
----
108
96
97

query I rowsort
SELECT ALL + 99 * 33 * - col0 AS col2 FROM tab2 AS cor0
----
-22869
-254826
-258093

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col2 + ( + col1 * + cor0.col0 ) col0 FROM tab1 AS cor0
----
24
583
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-5927
SELECT + col2 * 36 + col2 DIV col0 AS col2 FROM tab2 AS cor0
----
1368
936
975

skipif mysql # not compatible
query I rowsort label-5927
SELECT + col2 * 36 + col2 / col0 AS col2 FROM tab2 AS cor0
----
1368
936
975

query I rowsort
SELECT + col2 + - 9 FROM tab2 cor0
----
17
18
29

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * col0 + - col1 col2 FROM tab0 AS cor0
----
-2150
-3492
-8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-5930
SELECT DISTINCT - col2 + col2 DIV - cor0.col1 FROM tab1 AS cor0
----
-103
-56
-62

skipif mysql # not compatible
query I rowsort label-5930
SELECT DISTINCT - col2 + col2 / - cor0.col1 FROM tab1 AS cor0
----
-103
-56
-62

query I rowsort
SELECT ALL - 3 FROM tab1, tab2 AS cor0
----
9 values hashing to 95b6b9b4aae5cc2d9545db9f8940b2dc

query I rowsort
SELECT ALL + + 89 * col0 FROM tab2 AS cor0
----
623
6942
7031

query I rowsort
SELECT - + 8 * - col2 FROM tab1 AS cor0
----
432
456
768

query I rowsort
SELECT ALL ( ( + col2 ) ) * cor0.col1 * + col0 AS col1 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT ALL ( cor0.col1 ) + col0 AS col2 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT - 7 + + col0 FROM tab1 AS cor0
----
-4
57
73

query I rowsort
SELECT + - 0 * col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + + col2 + col2 * col0 AS col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT + 59 AS col2 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to e29fef8cdec1ee45a71d213f16d2f1d3

query I rowsort
SELECT cor0.col1 * + col2 FROM tab2 cor0
----
1534
646
837

onlyif mysql # use DIV operator for integer division
query I rowsort label-5941
SELECT col1 DIV col1 - - 54 * + col0 FROM tab1 AS cor0
----
163
3457
4321

skipif mysql # not compatible
query I rowsort label-5941
SELECT col1 / col1 - - 54 * + col0 FROM tab1 AS cor0
----
163
3457
4321

query I rowsort
SELECT ALL + col2 + col1 * col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT - - col0 + cor0.col0 AS col1 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT col1 * col2 * 42 + + 88 FROM tab0
----
119284
313492
4162

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( - col1 ) - col1 col0 FROM tab1
----
-20
-26
-52

query I rowsort
SELECT ALL 26 * col0 - col2 * ( - col1 ) AS col0 FROM tab1
----
1482
2234
3328

onlyif mysql # use DIV operator for integer division
query I rowsort label-5947
SELECT ALL + col1 + col1 DIV col2 AS col1 FROM tab0 cor0
----
194
88
92

skipif mysql # not compatible
query I rowsort label-5947
SELECT ALL + col1 + col1 / col2 AS col1 FROM tab0 cor0
----
194
88
92

query I rowsort
SELECT + ( col0 ) * + cor0.col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - - 3 * - cor0.col0 * + col2 + col0 AS col2 FROM tab0 AS cor0
----
-21805
-2352
-70

query I rowsort
SELECT ALL - col1 * col1 + - col2 AS col2 FROM tab1 AS cor0
----
-157
-265
-730

query I rowsort
SELECT 95 + + 35 + + col1 AS col1 FROM tab2
----
147
161
189

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5952
SELECT DISTINCT - CAST( col0 AS SIGNED ) + + col2 AS col0 FROM tab2
----
-41
-52
20

skipif mysql # not compatible
query I rowsort label-5952
SELECT DISTINCT - CAST ( col0 AS INTEGER ) + + col2 AS col0 FROM tab2
----
-41
-52
20

query I rowsort
SELECT 66 AS col0 FROM tab1, tab2, tab0 cor0, tab2 AS cor1
----
81 values hashing to dc112f70fecc29a6e605a39541192f43

query I rowsort
SELECT col2 * 53 + col0 * - ( col0 ) * + col2 + tab0.col0 FROM tab0
----
-1137
-17235
-645087

onlyif mysql # use DIV operator for integer division
query I rowsort label-5955
SELECT ALL + + col0 * + cor0.col0 DIV - ( + col0 ) FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-5955
SELECT ALL + + col0 * + cor0.col0 / - ( + col0 ) FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - 90 FROM tab1, tab1 cor0, tab2 AS cor1
----
-90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 46 - col0 col2 FROM tab0 AS cor0
----
-43
11
22

onlyif mysql # use DIV operator for integer division
query I rowsort label-5958
SELECT + + 38 DIV col1 + - col0 + 27 DIV + col0 FROM tab2 cor0
----
-3
-77
-78

skipif mysql # not compatible
query I rowsort label-5958
SELECT + + 38 / col1 + - col0 + 27 / + col0 FROM tab2 cor0
----
-3
-77
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 + - col1 col0 FROM tab0 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-5960
SELECT + - 9 * col2 * + col0 + 48 DIV + col1 FROM tab1 AS cor0
----
-1457
-32828
-69117

skipif mysql # not compatible
query I rowsort label-5960
SELECT + - 9 * col2 * + col0 + 48 / + col1 FROM tab1 AS cor0
----
-1457
-32828
-69117

query I rowsort
SELECT ALL col1 + + col2 + + 81 AS col2 FROM tab1 AS cor0
----
148
161
190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5962
SELECT col0 + col2 * ( ( + col2 ) * - CAST( - col1 AS SIGNED ) ) + col2 AS col2 FROM tab0 AS cor0
----
133
612055
93711

skipif mysql # not compatible
query I rowsort label-5962
SELECT col0 + col2 * ( ( + col2 ) * - CAST ( - col1 AS INTEGER ) ) + col2 AS col2 FROM tab0 AS cor0
----
133
612055
93711

query I rowsort
SELECT DISTINCT - - col1 + col2 * + 93 * col0 FROM tab1 AS cor0
----
15092
339274
714253

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 91 col2 FROM tab0 cor0
----
-91
-91
-91

query I rowsort
SELECT DISTINCT - ( + cor0.col0 ) * - 88 + col1 * col0 FROM tab1 AS cor0
----
342
6272
8080

onlyif mysql # use DIV operator for integer division
query I rowsort label-5966
SELECT - col2 DIV col0 + + 48 + col2 AS col0 FROM tab0 AS cor0
----
130
49
80

skipif mysql # not compatible
query I rowsort label-5966
SELECT - col2 / col0 + + 48 + col2 AS col0 FROM tab0 AS cor0
----
130
49
80

query I rowsort
SELECT ALL - 18 + + col0 * - col0 AS col2 FROM tab0 AS cor0
----
-1243
-594
-7939

query I rowsort
SELECT + col1 + - 13 AS col2 FROM tab0
----
73
78
84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * 41 col2 FROM tab1
----
1066
410
533

query I rowsort
SELECT col1 + ( 13 * col2 + + 58 ) AS col2 FROM tab0
----
1215
168
573

query I rowsort
SELECT DISTINCT 25 FROM tab0, tab2 AS cor0
----
25

onlyif mysql # use DIV operator for integer division
query I rowsort label-5972
SELECT - col1 DIV - col0 + col1 FROM tab1
----
10
13
34

skipif mysql # not compatible
query I rowsort label-5972
SELECT - col1 / - col0 + col1 FROM tab1
----
10
13
34

query I rowsort
SELECT DISTINCT - - col0 + col1 AS col1 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT col0 + 83 AS col2 FROM tab0 AS cor0
----
107
118
172

onlyif mysql # use DIV operator for integer division
query I rowsort label-5975
SELECT ALL - cor0.col0 DIV ( 79 ) AS col2 FROM tab2 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-5975
SELECT ALL - cor0.col0 / ( 79 ) AS col2 FROM tab2 AS cor0
----
-1
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col0 - ( + 46 ) col2 FROM tab0 AS cor0
----
-135
-70
-81

query I rowsort
SELECT - col2 + + 49 FROM tab2 AS cor0
----
11
22
23

query I rowsort
SELECT + col2 * - cor0.col0 AS col1 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL + + 18 AS col1 FROM tab1 AS cor0
----
18
18
18

query I rowsort
SELECT DISTINCT col2 * cor0.col2 AS col2 FROM tab2 AS cor0
----
1444
676
729

query I rowsort
SELECT ALL ( col0 ) + + col0 AS col0 FROM tab0 cor0
----
178
48
70

query I rowsort
SELECT DISTINCT col2 * + col1 + cor0.col2 AS col1 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL col1 + 40 * + col0 * + ( 55 ) FROM tab2 AS cor0
----
15431
171659
173817

query I rowsort
SELECT DISTINCT + col0 + + col0 * col2 FROM tab0 AS cor0
----
70
7387
816

query I rowsort
SELECT DISTINCT - ( ( col1 ) ) + col1 * - 29 FROM tab2 AS cor0
----
-1770
-510
-930

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5986
SELECT ALL + - 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-5986
SELECT ALL + - CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5987
SELECT ALL - CAST( NULL AS SIGNED ) + + col1 * + col1 * col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-5987
SELECT ALL - CAST ( NULL AS INTEGER ) + + col1 * + col1 * col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 * - col0 * + col1 AS col2 FROM tab1 cor0
----
-13520
-2028
-6400

query I rowsort
SELECT DISTINCT + + 80 * - col2 FROM tab0 AS cor0
----
-2640
-6560
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-5990
SELECT ALL col1 DIV ( col2 ) + 80 * - col0 FROM tab1 AS cor0
----
-240
-5120
-6400

skipif mysql # not compatible
query I rowsort label-5990
SELECT ALL col1 / ( col2 ) + 80 * - col0 FROM tab1 AS cor0
----
-240
-5120
-6400

query I rowsort
SELECT ALL + col2 * col2 + + col0 * - 53 * + col1 FROM tab2 AS cor0
----
-10772
-243230
-69735

query I rowsort
SELECT + + col0 + col1 AS col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL + 31 + col2 AS col1 FROM tab1 AS cor0
----
127
85
88

query I rowsort
SELECT ( + 80 ) + - col1 * + col0 FROM tab2 AS cor0
----
-1263
-137
-4522

query I rowsort
SELECT DISTINCT col2 - - col2 * col2 AS col0 FROM tab1 AS cor0
----
2970
3306
9312

query I rowsort
SELECT DISTINCT + - 39 * col2 FROM tab0 cor0
----
-1287
-3198
-39

query I rowsort
SELECT ALL + col2 * 85 AS col0 FROM tab2 AS cor0
----
2210
2295
3230

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-5998
SELECT DISTINCT cor0.col2 + CAST( col2 AS SIGNED ) * col0 AS col1 FROM tab1 AS cor0
----
216
3705
7776

skipif mysql # not compatible
query I rowsort label-5998
SELECT DISTINCT cor0.col2 + CAST ( col2 AS INTEGER ) * col0 AS col1 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT + + col1 * + col1 + col2 AS col2 FROM tab0 cor0
----
7429
8363
9410

query I rowsort
SELECT DISTINCT 58 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col2 * + col2 + - col2 * - col2 col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT + col1 + 53 AS col1 FROM tab2
----
112
70
84

query I rowsort
SELECT DISTINCT + tab1.col1 * 4 FROM tab1
----
104
40
52

query I rowsort
SELECT ALL + col2 + + col2 FROM tab2 cor0
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + col1 * + 28 col2 FROM tab2 AS cor0
----
1574
397
861

query I rowsort
SELECT - ( col0 ) * 2 FROM tab2 AS cor0
----
-14
-156
-158

query I rowsort
SELECT col1 * col0 * + col1 AS col1 FROM tab1 cor0
----
13520
2028
6400

query I rowsort
SELECT DISTINCT + 35 FROM tab1, tab2 AS cor0, tab0 cor1, tab0 AS cor2
----
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-6009
SELECT - 61 DIV + col1 + + CAST( cor0.col2 AS SIGNED ) FROM tab0 AS cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-6009
SELECT - 61 / + col1 + + CAST ( cor0.col2 AS INTEGER ) FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 * 27 col0 FROM tab1 AS cor0
----
1458
1539
2592

query I rowsort
SELECT - 63 * col2 AS col1 FROM tab0
----
-2079
-5166
-63

query I rowsort
SELECT col0 * + tab1.col0 AS col1 FROM tab1
----
4096
6400
9

query I rowsort
SELECT - col2 * col0 * + ( col1 * col2 + col2 ) AS col2 FROM tab0
----
-2273832
-3430
-55056112

query I rowsort
SELECT + tab2.col1 + + 58 * col0 AS col2 FROM tab2
----
437
4583
4599

onlyif mysql # use DIV operator for integer division
query I rowsort label-6015
SELECT 43 DIV 96 AS col0 FROM tab2
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6015
SELECT 43 / 96 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT + ( + col0 ) * + col1 AS col0 FROM tab2
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6017
SELECT + 17 DIV + ( + cor0.col2 + + col1 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6017
SELECT + 17 / + ( + cor0.col2 + + col1 ) FROM tab0 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6018
SELECT CAST( NULL AS DECIMAL ) * 24 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6018
SELECT CAST ( NULL AS REAL ) * 24 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6019
SELECT + + ( - col0 ) DIV col1 FROM tab2 AS cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-6019
SELECT + + ( - col0 ) / col1 FROM tab2 AS cor0
----
-1
-4
0

query I rowsort
SELECT - col0 * + 88 FROM tab0 AS cor0
----
-2112
-3080
-7832

query I rowsort
SELECT DISTINCT + 98 + col0 AS col1 FROM tab2 AS cor0
----
105
176
177

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 - - col0 col1 FROM tab1 AS cor0
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6023
SELECT + CAST( 55 AS SIGNED ) + - col2 * - col1 AS col0 FROM tab0 AS cor0
----
152
2893
7517

skipif mysql # not compatible
query I rowsort label-6023
SELECT + CAST ( 55 AS INTEGER ) + - col2 * - col1 AS col0 FROM tab0 AS cor0
----
152
2893
7517

onlyif mysql # use DIV operator for integer division
query I rowsort label-6024
SELECT ALL col0 DIV 83 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6024
SELECT ALL col0 / 83 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - ( + 53 ) FROM tab1
----
-53

query I rowsort
SELECT - + 12 * - col2 + col0 AS col1 FROM tab2 AS cor0
----
331
390
535

onlyif mysql # use DIV operator for integer division
query I rowsort label-6027
SELECT ALL - col2 DIV - col1 AS col2 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-6027
SELECT ALL - col2 / - col1 AS col2 FROM tab2
----
0
0
2

query I rowsort
SELECT col2 + col1 + ( col1 ) AS col0 FROM tab0 AS cor0
----
195
205
264

onlyif mysql # use DIV operator for integer division
query I rowsort label-6029
SELECT - + col1 + col0 DIV + col0 + - col2 FROM tab0 AS cor0
----
-118
-172
-97

skipif mysql # not compatible
query I rowsort label-6029
SELECT - + col1 + col0 / + col0 + - col2 FROM tab0 AS cor0
----
-118
-172
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6030
SELECT ALL - col2 - - col0 * CAST( NULL AS SIGNED ) FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6030
SELECT ALL - col2 - - col0 * CAST ( NULL AS INTEGER ) FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + col1 + col0 + - 66 FROM tab2
----
-28
30
71

query I rowsort
SELECT + 15 - - col2 FROM tab0 AS cor0
----
16
48
97

query I rowsort
SELECT DISTINCT - + col1 + - col1 * + col1 FROM tab2 AS cor0
----
-306
-3540
-992

query I rowsort
SELECT + + col1 + + col0 AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT ALL - ( + cor0.col0 ) + 74 AS col1 FROM tab1 AS cor0
----
-6
10
71

query I rowsort
SELECT ALL - ( - col0 ) * + ( col0 ) * col1 AS col1 FROM tab0 cor0
----
118825
49536
720811

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col0 + - cor0.col1 col0 FROM tab2 AS cor0
----
-24
19
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6038
SELECT 45 * col1 + CAST( + col0 AS SIGNED ) DIV - cor0.col1 - + CAST( col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
1167
380
499

skipif mysql # not compatible
query I rowsort label-6038
SELECT 45 * col1 + CAST ( + col0 AS INTEGER ) / - cor0.col1 - + CAST ( col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
1167
380
499

query I rowsort
SELECT DISTINCT - 5 * col0 + + 81 FROM tab0 AS cor0
----
-364
-39
-94

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6040
SELECT + + col1 + + CAST( col0 AS SIGNED ) FROM tab1 cor0
----
29
74
93

skipif mysql # not compatible
query I rowsort label-6040
SELECT + + col1 + + CAST ( col0 AS INTEGER ) FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT + cor0.col0 + col0 AS col1 FROM tab0 cor0
----
178
48
70

skipif mysql # not compatible
query I rowsort
SELECT col2 + CAST ( col0 AS REAL ) FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT + + col0 * ( ( col0 ) ) + col2 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT - cor1.col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to d4c673b7444eb9927ec63175b43c6b84

query I rowsort
SELECT ALL col2 + + 25 * cor0.col2 FROM tab2 AS cor0
----
676
702
988

query I rowsort
SELECT ALL col2 * cor0.col0 * cor0.col0 FROM tab2 AS cor0
----
1323
158184
237158

onlyif mysql # use DIV operator for integer division
query I rowsort label-6047
SELECT DISTINCT - 54 DIV - col1 FROM tab1 cor0
----
2
4
5

skipif mysql # not compatible
query I rowsort label-6047
SELECT DISTINCT - 54 / - col1 FROM tab1 cor0
----
2
4
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6048
SELECT ALL + col0 * col2 * col1 + CAST( NULL AS SIGNED ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6048
SELECT ALL + col0 * col2 * col1 + CAST ( NULL AS INTEGER ) col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 AS cor0, tab0 AS cor1, tab1 cor2
----
972 values hashing to 9af67d6f98010464af5d560bf949d487

query I rowsort
SELECT ALL + 77 FROM tab0, tab1 AS cor0, tab0 AS cor1, tab2 AS cor2
----
81 values hashing to 38f487c2147ee2fe05527e38c5e0503b

query I rowsort
SELECT + - 6 * - cor0.col2 FROM tab0 AS cor0
----
198
492
6

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6052
SELECT DISTINCT CAST( NULL AS SIGNED ) + + col0 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6052
SELECT DISTINCT CAST ( NULL AS INTEGER ) + + col0 * - cor0.col1 AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - + col0 - 4 AS col0 FROM tab0 AS cor0
----
-28
-39
-93

query I rowsort
SELECT DISTINCT + cor0.col2 * + 11 AS col1 FROM tab1 AS cor0
----
1056
594
627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + ( + 87 ) col2 FROM tab1 AS cor0
----
100
113
97

query I rowsort
SELECT ALL + cor0.col2 * + 63 FROM tab0 AS cor0
----
2079
5166
63

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6057
SELECT + col0 + - CAST( - col1 AS SIGNED ) FROM tab1 AS cor0
----
29
74
93

skipif mysql # not compatible
query I rowsort label-6057
SELECT + col0 + - CAST ( - col1 AS INTEGER ) FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT ALL - cor0.col0 * + 38 * col1 FROM tab1 AS cor0
----
-24320
-2964
-39520

query I rowsort
SELECT + col2 * + 35 FROM tab0 AS cor0
----
1155
2870
35

query I rowsort
SELECT ALL col1 * - ( + 28 ) FROM tab2 AS cor0
----
-1652
-476
-868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col0 * + ( - col2 ) col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + - col2 * col2 * 4 FROM tab0 AS cor0
----
-26896
-4
-4356

query I rowsort
SELECT ALL col1 * 75 AS col0 FROM tab0 cor0
----
6450
6825
7275

query I rowsort
SELECT ALL + - col1 * + col1 * col1 + - col0 AS col1 FROM tab0 AS cor0
----
-636080
-753660
-912708

query I rowsort
SELECT col1 + - ( col2 ) * + col2 AS col2 FROM tab1 AS cor0
----
-2890
-3239
-9203

query I rowsort
SELECT + tab0.col1 * - tab0.col1 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to 0456bcedc217ad4d7d255310d4eb4931

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6067
SELECT DISTINCT + cor0.col0 * + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6067
SELECT DISTINCT + cor0.col0 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + tab1.col0 * 1 - col0 FROM tab1
----
0
0
0

query I rowsort
SELECT 75 FROM tab2, tab2 cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

onlyif mysql # use DIV operator for integer division
query I rowsort label-6070
SELECT + cor0.col1 DIV - cor0.col2 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6070
SELECT + cor0.col1 / - cor0.col2 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT ( cor0.col0 ) AS col0 FROM tab0, tab0 cor0
----
24
35
89

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0, tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1, tab2 AS cor2
----
3645 values hashing to b9fc7433316cc7891b52d2a23a135419

query I rowsort
SELECT DISTINCT - + cor0.col2 + - col1 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT + col2 + + col1 * + ( col0 ) * col0 FROM tab2 AS cor0
----
106135
1546
358982

query I rowsort
SELECT DISTINCT - - col0 + + col0 + 19 AS col1 FROM tab0 AS cor0
----
197
67
89

query I rowsort
SELECT ( - 33 * + tab2.col2 ) FROM tab2
----
-1254
-858
-891

query I rowsort
SELECT - col2 + - 90 * col0 FROM tab0 AS cor0
----
-2193
-3151
-8092

query I rowsort
SELECT ALL + - ( - col1 ) + 89 FROM tab1 AS cor0
----
102
115
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-6079
SELECT ALL - ( cor0.col0 ) + ( col2 ) DIV + col1 AS col0 FROM tab2 AS cor0
----
-7
-77
-78

skipif mysql # not compatible
query I rowsort label-6079
SELECT ALL - ( cor0.col0 ) + ( col2 ) / + col1 AS col0 FROM tab2 AS cor0
----
-7
-77
-78

query I rowsort
SELECT - + col1 + - col1 * cor0.col1 FROM tab0 AS cor0
----
-7482
-8372
-9506

query I rowsort
SELECT DISTINCT 11 + - col1 AS col1 FROM tab1 AS cor0
----
-15
-2
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6082
SELECT DISTINCT col1 * cor0.col1 DIV col1 FROM tab0 cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-6082
SELECT DISTINCT col1 * cor0.col1 / col1 FROM tab0 cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6083
SELECT col2 + col1 DIV ( - col1 ) AS col1 FROM tab0 AS cor0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-6083
SELECT col2 + col1 / ( - col1 ) AS col1 FROM tab0 AS cor0
----
0
32
81

query I rowsort
SELECT ALL + - col1 + - cor0.col2 FROM tab2 AS cor0
----
-55
-58
-85

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 93 * col1 col2 FROM tab0 AS cor0
----
-7998
-8463
-9021

query I rowsort
SELECT - + 14 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to d321461994ba49c3a70fa6373032fc94

onlyif mysql # use DIV operator for integer division
query I rowsort label-6087
SELECT DISTINCT - + cor0.col2 + col0 + - col1 DIV 43 AS col1 FROM tab0 AS cor0
----
-11
32
5

skipif mysql # not compatible
query I rowsort label-6087
SELECT DISTINCT - + cor0.col2 + col0 + - col1 / 43 AS col1 FROM tab0 AS cor0
----
-11
32
5

query I rowsort
SELECT ALL - + col1 * - col0 + + 69 * col2 FROM tab0 AS cor0
----
13757
3464
4341

query I rowsort
SELECT ALL - + 22 * cor0.col0 FROM tab1 AS cor0
----
-1408
-1760
-66

query I rowsort
SELECT - - col1 * col0 + col2 * + 62 AS col1 FROM tab2 AS cor0
----
1891
3699
6214

query I rowsort
SELECT ALL - col1 + + col2 * col1 * col0 FROM tab2 AS cor0
----
119593
51017
5828

onlyif mysql # use DIV operator for integer division
query I rowsort label-6092
SELECT col0 DIV cor0.col0 FROM tab0 cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6092
SELECT col0 / cor0.col0 FROM tab0 cor0
----
1
1
1

query I rowsort
SELECT ALL - - col1 + 33 * + 62 FROM tab0 AS cor0
----
2132
2137
2143

query I rowsort
SELECT ALL + col2 + + ( + col0 ) FROM tab2 AS cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * 4 col1 FROM tab0 AS cor0
----
-140
-356
-96

query I rowsort
SELECT DISTINCT + col1 * + col2 + + col1 AS col1 FROM tab2 AS cor0
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-6097
SELECT 1 DIV - col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6097
SELECT 1 / - col2 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL tab1.col0 + - col2 FROM tab1
----
-16
-51
7

query I rowsort
SELECT 47 FROM tab0, tab0 cor0
----
9 values hashing to 4fe192f296791e1e40ea00a68aa8dab7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6100
SELECT col0 DIV 38 + - col2 AS col1 FROM tab1 cor0
----
-54
-56
-94

skipif mysql # not compatible
query I rowsort label-6100
SELECT col0 / 38 + - col2 AS col1 FROM tab1 cor0
----
-54
-56
-94

query I rowsort
SELECT DISTINCT - col0 + 12 FROM tab1 AS cor0
----
-52
-68
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + 12 ) col2 FROM tab0 AS cor0
----
12

onlyif mysql # use DIV operator for integer division
query I rowsort label-6103
SELECT col2 DIV + col2 + col2 AS col0 FROM tab1 AS cor0
----
55
58
97

skipif mysql # not compatible
query I rowsort label-6103
SELECT col2 / + col2 + col2 AS col0 FROM tab1 AS cor0
----
55
58
97

query I rowsort
SELECT DISTINCT - + cor0.col1 * col1 AS col0 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT - + cor0.col1 + - col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT - col1 + col1 * 7 FROM tab0 AS cor0
----
516
546
582

query I rowsort
SELECT ALL + - col0 - - col1 AS col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL - + ( col0 ) * + ( - col2 ) + + col1 * 40 + - col2 FROM tab2 AS cor0
----
1402
3644
4362

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( - col1 ) + + col2 col0 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT col2 * - 33 FROM tab1
----
-1782
-1881
-3168

query I rowsort
SELECT + 84 + + 75 FROM tab2
----
159
159
159

query I rowsort
SELECT DISTINCT ( - col2 ) + - col2 AS col0 FROM tab2
----
-52
-54
-76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 66 * col1 col0 FROM tab1
----
1716
660
858

query I rowsort
SELECT tab2.col0 * col1 * - 14 AS col1 FROM tab2
----
-18802
-3038
-64428

query I rowsort
SELECT col2 + 79 FROM tab0 AS cor0
----
112
161
80

query I rowsort
SELECT - col0 + ( + cor0.col2 ) FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT - - cor0.col1 * cor0.col2 AS col1 FROM tab2 cor0
----
1534
646
837

query I rowsort
SELECT 93 * + col1 + col1 * - cor0.col0 FROM tab2 AS cor0
----
238
2666
885

query I rowsort
SELECT + ( + 11 ) + - col1 AS col0 FROM tab2 AS cor0
----
-20
-48
-6

query I rowsort
SELECT DISTINCT cor1.col1 AS col0 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6121
SELECT + + CAST( NULL AS DECIMAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6121
SELECT + + CAST ( NULL AS REAL ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + 25 * cor0.col1 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 486127fb97b979df6fedac3928625e8b

query I rowsort
SELECT - 10 + - col0 AS col2 FROM tab2 AS cor0
----
-17
-88
-89

query I rowsort
SELECT - col0 + + 33 AS col0 FROM tab1 AS cor0
----
-31
-47
30

query I rowsort
SELECT + + col1 + - col2 FROM tab1 AS cor0
----
-28
-47
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col0 ) col1 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL - col1 - - cor0.col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col2 * col1 + - col0 AS col2 FROM tab1 AS cor0
----
-1328
-1407
-634

onlyif mysql # use DIV operator for integer division
query I rowsort label-6129
SELECT DISTINCT + - col0 DIV + col0 FROM tab1 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-6129
SELECT DISTINCT + - col0 / + col0 FROM tab1 AS cor0
----
-1

query I rowsort
SELECT ALL + + col0 * col2 - cor0.col0 * - col0 FROM tab1 AS cor0
----
14080
171
7744

query I rowsort
SELECT ALL - 82 * + col1 AS col0 FROM tab1
----
-1066
-2132
-820

query I rowsort
SELECT ALL - col1 * + col0 * - col0 AS col0 FROM tab1
----
234
40960
83200

query I rowsort
SELECT DISTINCT + - col2 - col2 AS col1 FROM tab0 AS cor0
----
-164
-2
-66

query I rowsort
SELECT ALL + tab2.col0 * + col0 * - col1 FROM tab2
----
-106097
-1519
-358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * col0 col2 FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT ALL col2 * + 95 FROM tab1
----
5130
5415
9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-6137
SELECT ALL - + 38 DIV + col0 FROM tab0 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-6137
SELECT ALL - + 38 / + col0 FROM tab0 AS cor0
----
-1
-1
0

query I rowsort
SELECT col1 * + col0 + + col0 FROM tab1 AS cor0
----
1120
704
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 75 * - col2 + + col0 col1 FROM tab0 AS cor0
----
110
2499
6239

query I rowsort
SELECT ALL - col0 + + col1 * col2 AS col0 FROM tab1 AS cor0
----
1168
1401
506

query I rowsort
SELECT DISTINCT + tab1.col2 - 42 * - col2 AS col2 FROM tab1
----
2322
2451
4128

query I rowsort
SELECT + ( col1 ) * - col0 + + col0 + col1 FROM tab2
----
-1247
-179
-4465

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6143
SELECT CAST( NULL AS SIGNED ) - col0 AS col1 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6143
SELECT CAST ( NULL AS INTEGER ) - col0 AS col1 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6144
SELECT - CAST( NULL AS SIGNED ) * - col0 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6144
SELECT - CAST ( NULL AS INTEGER ) * - col0 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT 36 - + col0 FROM tab0
----
-53
1
12

query I rowsort
SELECT ALL col2 * col1 + - col2 FROM tab1
----
1152
1350
513

query I rowsort
SELECT - 37 * col2 FROM tab0 AS cor0
----
-1221
-3034
-37

onlyif mysql # use DIV operator for integer division
query I rowsort label-6148
SELECT + col2 + - col2 DIV col2 FROM tab1 AS cor0
----
53
56
95

skipif mysql # not compatible
query I rowsort label-6148
SELECT + col2 + - col2 / col2 FROM tab1 AS cor0
----
53
56
95

query I rowsort
SELECT ALL + 10 AS col1 FROM tab0 AS cor0
----
10
10
10

query I rowsort
SELECT DISTINCT + - cor0.col2 * col2 AS col0 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT ( - col0 ) * - col0 FROM tab1 cor0
----
4096
6400
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * + cor0.col2 col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT - col2 + 36 AS col1 FROM tab2 AS cor0
----
-2
10
9

query I rowsort
SELECT + ( 24 ) + - col0 FROM tab1 cor0
----
-40
-56
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-6155
SELECT - 1 * + ( col1 ) + + col2 DIV + col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-6155
SELECT - 1 * + ( col1 ) + + col2 / + col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT + ( col1 ) + + col1 * 6 AS col2 FROM tab2 cor0
----
119
217
413

query I rowsort
SELECT DISTINCT ( col1 ) + col0 AS col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT 61 + - col0 * col2 FROM tab1 AS cor0
----
-101
-3587
-7619

query I rowsort
SELECT ALL - 34 + 99 AS col1 FROM tab2 AS cor0
----
65
65
65

query I rowsort
SELECT ALL + - ( col1 ) * col0 + ( + 72 ) FROM tab2 AS cor0
----
-1271
-145
-4530

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6161
SELECT ALL cor1.col0 + + CAST( NULL AS DECIMAL ) FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6161
SELECT ALL cor1.col0 + + CAST ( NULL AS REAL ) FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6162
SELECT col0 + col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6162
SELECT col0 + col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 10 * col0 + - ( 63 * col2 ) AS col2 FROM tab0 AS cor0
----
-2319
-413
-6056

query I rowsort
SELECT 28 AS col0 FROM tab0 AS cor0
----
28
28
28

query I rowsort
SELECT DISTINCT col1 * - col0 + col1 FROM tab0 AS cor0
----
-1978
-3298
-8008

query I rowsort
SELECT ALL - cor0.col0 * col0 + col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT + cor0.col1 - - col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT DISTINCT tab0.col2 * tab0.col0 AS col2 FROM tab0
----
35
7298
792

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6169
SELECT + col2 - - 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-6169
SELECT + col2 - - CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6170
SELECT DISTINCT col0 DIV - 49 FROM tab1 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-6170
SELECT DISTINCT col0 / - 49 FROM tab1 cor0
----
-1
0

query I rowsort
SELECT - col0 + 18 + cor0.col1 AS col0 FROM tab2 AS cor0
----
-1
-44
42

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6172
SELECT ALL + col2 * CAST( NULL AS SIGNED ) - - col2 * + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6172
SELECT ALL + col2 * CAST ( NULL AS INTEGER ) - - col2 * + col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 95 + col2 * + 0 - ( col0 ) FROM tab0
----
6
60
71

query I rowsort
SELECT ALL 39 - + col0 FROM tab2
----
-39
-40
32

query I rowsort
SELECT ALL - col0 * - 90 FROM tab2 cor0
----
630
7020
7110

query I rowsort
SELECT + col1 + 35 * col2 * cor0.col0 FROM tab1 AS cor0
----
127690
268813
5696

query I rowsort
SELECT ALL + col1 + - col1 + + 36 * col0 FROM tab2 AS cor0
----
252
2808
2844

onlyif mysql # use DIV operator for integer division
query I rowsort label-6178
SELECT DISTINCT cor0.col2 DIV + 69 + - col2 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-6178
SELECT DISTINCT cor0.col2 / + 69 + - col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT + + col0 + - col1 * ( + col0 ) AS col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT - col2 * - 44 - - col2 FROM tab1 AS cor0
----
2430
2565
4320

query I rowsort
SELECT DISTINCT - col1 + - 7 FROM tab2 AS cor0
----
-24
-38
-66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6182
SELECT ALL + cor0.col1 * CAST( + col0 AS SIGNED ) FROM tab2 cor0
----
1343
217
4602

skipif mysql # not compatible
query I rowsort label-6182
SELECT ALL + cor0.col1 * CAST ( + col0 AS INTEGER ) FROM tab2 cor0
----
1343
217
4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-6183
SELECT + col2 + 82 DIV - 74 FROM tab0
----
0
32
81

skipif mysql # not compatible
query I rowsort label-6183
SELECT + col2 + 82 / - 74 FROM tab0
----
0
32
81

query I rowsort
SELECT ALL + 37 - 41 FROM tab1 AS cor0
----
-4
-4
-4

query I rowsort
SELECT - 24 + + col1 FROM tab0 cor0
----
62
67
73

query I rowsort
SELECT ALL - col0 + 10 FROM tab0 AS cor0
----
-14
-25
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6187
SELECT ALL col0 + ( - col1 + + col0 ) DIV 71 AS col0 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-6187
SELECT ALL col0 + ( - col1 + + col0 ) / 71 AS col0 FROM tab0
----
24
35
89

query I rowsort
SELECT ALL col1 + - 13 AS col0 FROM tab0
----
73
78
84

query I rowsort
SELECT - + col0 + col1 + col2 FROM tab0 AS cor0
----
63
84
95

query I rowsort
SELECT - col0 * - 83 FROM tab2 AS cor0
----
581
6474
6557

query I rowsort
SELECT DISTINCT 47 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
47

query I rowsort
SELECT DISTINCT - col1 + 37 * col0 AS col0 FROM tab0
----
1198
3202
802

query I rowsort
SELECT 43 AS col1 FROM tab2 AS cor0
----
43
43
43

query I rowsort
SELECT col0 + 5 + cor0.col1 FROM tab1 cor0
----
34
79
98

query I rowsort
SELECT ALL + 73 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT DISTINCT - tab0.col1 * col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT - cor0.col1 AS col2 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT + col1 * 27 + - col2 FROM tab2
----
1567
421
810

query I rowsort
SELECT - col0 * 30 * ( - col0 ) AS col0 FROM tab1
----
122880
192000
270

query I rowsort
SELECT DISTINCT - col0 + col2 + - col2 * + col2 FROM tab2
----
-1485
-709
-728

query I rowsort
SELECT ALL 74 * - col0 AS col2 FROM tab1 AS cor0
----
-222
-4736
-5920

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT DISTINCT + col2 + col0 * + col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL - + ( + 58 ) * - cor0.col0 + - col1 FROM tab2 cor0
----
375
4465
4565

query I rowsort
SELECT DISTINCT + 80 * 76 - + col1 FROM tab2 AS cor0
----
6021
6049
6063

query I rowsort
SELECT + + ( + col0 ) + + col0 AS col0 FROM tab1 cor0
----
128
160
6

query I rowsort
SELECT + cor0.col2 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT ALL + + 68 + col0 FROM tab1 AS cor0
----
132
148
71

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 62 * + col0 col2 FROM tab0 AS cor0
----
1488
2170
5518

skipif mysql # not compatible
query I rowsort
SELECT ALL - 21 * + col0 + CAST ( 92 AS REAL ) AS col0 FROM tab0 AS cor0
----
-1777
-412
-643

query I rowsort
SELECT ALL 53 * + col0 FROM tab0
----
1272
1855
4717

onlyif mysql # use DIV operator for integer division
query I rowsort label-6212
SELECT DISTINCT cor0.col1 DIV + col0 + 64 FROM tab1 cor0
----
64
72

skipif mysql # not compatible
query I rowsort label-6212
SELECT DISTINCT cor0.col1 / + col0 + 64 FROM tab1 cor0
----
64
72

query I rowsort
SELECT + col1 - ( - col2 ) AS col0 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL col0 + ( 72 ) * + col1 FROM tab2 AS cor0
----
1303
2239
4326

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 * col0 col0 FROM tab0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-6216
SELECT - cor0.col2 DIV 80 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-6216
SELECT - cor0.col2 / 80 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - col1 + - col1 * - col1 * col1 AS col1 FROM tab1 AS cor0
----
17550
2184
990

query I rowsort
SELECT ALL tab2.col0 * - 67 + - tab2.col1 AS col1 FROM tab2, tab2 cor0
----
9 values hashing to 7e0643cd646c54ba5ee3c19d6a3d1772

query I rowsort
SELECT cor1.col0 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT ALL col1 * 65 AS col1 FROM tab1
----
1690
650
845

query I rowsort
SELECT DISTINCT ( + cor0.col1 ) FROM tab1, tab2 AS cor0, tab0 AS cor1
----
17
31
59

query I rowsort
SELECT ALL cor0.col0 AS col0 FROM tab2, tab2 cor0, tab1 AS cor1
----
27 values hashing to 1e1f10953eb8effe9b20e746f8a7fd83

query I rowsort
SELECT ALL 68 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + ( col0 ) AS INTEGER ) * CAST ( col0 AS REAL ) FROM tab2
----
49
6084
6241

query I rowsort
SELECT - 21 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 631fbd1fd929405aba54a22c2a06c757

query I rowsort
SELECT ALL 87 * + ( - tab0.col1 ) FROM tab0
----
-7482
-7917
-8439

query I rowsort
SELECT - ( 74 ) + cor0.col2 * - col2 AS col1 FROM tab0 AS cor0
----
-1163
-6798
-75

query I rowsort
SELECT 88 * col2 + + col0 FROM tab2 AS cor0
----
2366
2383
3423

query I rowsort
SELECT 88 * col0 + + col0 FROM tab0 AS cor0
----
2136
3115
7921

query I rowsort
SELECT - 22 + col0 * - 67 FROM tab2 cor0
----
-491
-5248
-5315

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + 34 + + col1 col0 FROM tab0 AS cor0
----
52
57
63

query I rowsort
SELECT cor0.col0 + col2 + - ( + col2 + col2 ) AS col0 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT ( - col0 ) * col0 + + col2 FROM tab1
----
-4039
-6304
45

query I rowsort
SELECT - 75 * + tab0.col1 FROM tab0
----
-6450
-6825
-7275

onlyif mysql # use DIV operator for integer division
query I rowsort label-6235
SELECT DISTINCT + col2 DIV + col0 + - cor0.col1 FROM tab2 AS cor0
----
-17
-28
-59

skipif mysql # not compatible
query I rowsort label-6235
SELECT DISTINCT + col2 / + col0 + - cor0.col1 FROM tab2 AS cor0
----
-17
-28
-59

query I rowsort
SELECT DISTINCT col2 * col0 - - cor0.col2 * - col2 AS col0 FROM tab0 cor0
----
-297
34
574

query I rowsort
SELECT 36 + + col2 FROM tab1 AS cor0
----
132
90
93

query I rowsort
SELECT + col2 * + 26 FROM tab0
----
2132
26
858

query I rowsort
SELECT DISTINCT 46 * - col0 AS col0 FROM tab1
----
-138
-2944
-3680

query I rowsort
SELECT ALL + col0 + col2 * - 78 FROM tab1 AS cor0
----
-4209
-4382
-7408

query I rowsort
SELECT ALL - col2 * col2 + 96 AS col0 FROM tab2 AS cor0
----
-1348
-580
-633

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6242
SELECT DISTINCT cor0.col1 + cor0.col2 + + CAST( NULL AS SIGNED ) AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6242
SELECT DISTINCT cor0.col1 + cor0.col2 + + CAST ( NULL AS INTEGER ) AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT + 62 * col0 FROM tab2
----
434
4836
4898

query I rowsort
SELECT ALL + + col1 * cor0.col2 + 71 * + col1 FROM tab2 AS cor0
----
1853
3038
5723

query I rowsort
SELECT ALL + col2 * + ( col2 ) - - cor0.col1 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT ALL - cor0.col1 + + ( col0 ) FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + col0 + + ( + col0 ) FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT ALL cor0.col0 + + col1 AS col2 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - 86 + + col2 AS col2 FROM tab0
----
-4
-53
-85

query I rowsort
SELECT + 52 AS col0 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 76100d10f51995d20efdeb657e444d3c

query I rowsort
SELECT DISTINCT col1 + + tab1.col2 * + col0 FROM tab1
----
188
3658
7693

query I rowsort
SELECT DISTINCT + 79 * col1 FROM tab1 AS cor0
----
1027
2054
790

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6253
SELECT - CAST( NULL AS DECIMAL ) - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6253
SELECT - CAST ( NULL AS REAL ) - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + cor0.col2 * col1 + col2 + col2 * cor0.col2 FROM tab2 AS cor0
----
1593
2128
2236

query I rowsort
SELECT + + col2 * col0 - col0 AS col1 FROM tab2 AS cor0
----
182
1950
2923

query I rowsort
SELECT ALL ( col2 ) * - col2 + - col1 * ( + col2 ) AS col1 FROM tab1 AS cor0
----
-10464
-3819
-4320

query I rowsort
SELECT + - 68 + 61 * col2 FROM tab0 AS cor0
----
-7
1945
4934

query I rowsort
SELECT DISTINCT + 92 AS col0 FROM tab1 AS cor0
----
92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * 71 col0 FROM tab0 AS cor0
----
-6106
-6461
-6887

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6260
SELECT - CAST( NULL AS SIGNED ) * 37 - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6260
SELECT - CAST ( NULL AS INTEGER ) * 37 - col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor0.col0 - ( cor0.col2 ) AS col1 FROM tab0 AS cor0
----
-9
34
7

query I rowsort
SELECT DISTINCT - 25 * - 90 AS col2 FROM tab2
----
2250

query I rowsort
SELECT + - col1 + 13 AS col2 FROM tab1 cor0
----
-13
0
3

query I rowsort
SELECT + ( - col2 ) * cor0.col1 AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT - 20 + cor0.col0 + col2 AS col0 FROM tab2 AS cor0
----
14
84
97

query I rowsort
SELECT DISTINCT + ( + col1 * col0 ) - - col2 AS col1 FROM tab0
----
2097
3396
8181

query I rowsort
SELECT + + col1 * col0 + + col2 FROM tab1 cor0
----
1136
132
697

query I rowsort
SELECT DISTINCT col1 * + tab0.col2 * - col1 AS col1 FROM tab0
----
-244068
-679042
-9409

query I rowsort
SELECT ALL col2 * + tab1.col1 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL + col0 FROM tab0 WHERE NULL NOT IN ( - tab0.col0 )
----

query I rowsort
SELECT DISTINCT + col2 + tab2.col0 * - col1 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT col2 * col2 / col1 AS col2 FROM tab1 WHERE NULL IN ( - col2 )
----

query I rowsort
SELECT col0 * - col0 + - col0 - col0 * + col2 FROM tab1
----
-14160
-174
-7808

query I rowsort
SELECT col0 * col0 - col1 * col2 AS col1 FROM tab1 AS cor0
----
-1395
3526
5152

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL BETWEEN NULL AND col2 * + col2 * col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6276
SELECT col1 * col2 + tab1.col1 DIV tab1.col0 FROM tab1
----
1248
1412
570

skipif mysql # not compatible
query I rowsort label-6276
SELECT col1 * col2 + tab1.col1 / tab1.col0 FROM tab1
----
1248
1412
570

query III rowsort
SELECT * FROM tab2 WHERE NULL < col1
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * + col2 col1 FROM tab0 WHERE NOT col2 >= NULL
----

query I rowsort
SELECT col0 + col0 * + tab2.col2 FROM tab2
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-6280
SELECT ALL - col2 + + col0 * tab1.col1 DIV + col1 FROM tab1
----
-16
-51
7

skipif mysql # not compatible
query I rowsort label-6280
SELECT ALL - col2 + + col0 * tab1.col1 / + col1 FROM tab1
----
-16
-51
7

query I rowsort
SELECT DISTINCT col2 + col1 * - col2 AS col0 FROM tab1
----
-1152
-1350
-513

query I rowsort
SELECT ALL - col0 * col0 + col0 FROM tab2 cor0
----
-42
-6006
-6162

query I rowsort
SELECT DISTINCT - col0 + - cor0.col2 - - col2 * cor0.col2 FROM tab0 AS cor0
----
-35
1032
6553

onlyif mysql # use DIV operator for integer division
query I rowsort label-6284
SELECT DISTINCT - + cor0.col1 * col1 DIV col0 + + col0 * + cor0.col2 + + cor0.col2 FROM tab2 cor0
----
2010
3037
79

skipif mysql # not compatible
query I rowsort label-6284
SELECT DISTINCT - + cor0.col1 * col1 / col0 + + col0 * + cor0.col2 + + cor0.col2 FROM tab2 cor0
----
2010
3037
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-6285
SELECT DISTINCT - cor0.col2 * col1 - cor0.col2 DIV - col0 col2 FROM tab2 AS cor0
----
-1534
-646
-834

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6285
SELECT DISTINCT - cor0.col2 * col1 - cor0.col2 / - col0 col2 FROM tab2 AS cor0
----
-1534
-646
-834

query I rowsort
SELECT ALL + - col1 + cor0.col1 + + col0 FROM tab0 cor0
----
24
35
89

query I rowsort
SELECT DISTINCT + col0 + - col2 - col1 FROM tab0 AS cor0
----
-63
-84
-95

query I rowsort
SELECT - cor0.col2 + col0 * + col2 AS col2 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT ALL col2 * + cor0.col1 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT col1 * col1 + col1 * + col0 * + col2 AS col1 FROM tab2 AS cor0
----
123133
51323
6820

query I rowsort
SELECT ALL col0 * + col1 * col1 - - col2 FROM tab1
----
13616
2082
6457

query I rowsort
SELECT DISTINCT - col1 - - col0 * tab1.col1 AS col2 FROM tab1
----
1027
52
630

query I rowsort
SELECT + - col2 - 41 AS col1 FROM tab2 AS cor0
----
-67
-68
-79

query I rowsort
SELECT DISTINCT - col0 * - ( + col2 * - col0 ) FROM tab1 AS cor0
----
-233472
-486
-614400

onlyif mysql # use DIV operator for integer division
query I rowsort label-6295
SELECT + + col2 + col0 * cor0.col0 DIV + cor0.col1 AS col0 FROM tab2 AS cor0
----
129
28
405

skipif mysql # not compatible
query I rowsort label-6295
SELECT + + col2 + col0 * cor0.col0 / + cor0.col1 AS col0 FROM tab2 AS cor0
----
129
28
405

query I rowsort
SELECT DISTINCT + col0 * + ( + ( - col2 ) ) FROM tab2 cor0
----
-189
-2028
-3002

query I rowsort
SELECT + col0 * - col1 - col1 * - cor0.col1 FROM tab1 cor0
----
-540
-871
598

onlyif mysql # use DIV operator for integer division
query I rowsort label-6298
SELECT + cor0.col1 + + 11 DIV 12 AS col2 FROM tab2 AS cor0
----
17
31
59

skipif mysql # not compatible
query I rowsort label-6298
SELECT + cor0.col1 + + 11 / 12 AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT DISTINCT col2 * + 12 FROM tab1 AS cor0
----
1152
648
684

query I rowsort
SELECT - + col1 + + cor0.col0 FROM tab2 AS cor0
----
-24
19
62

query I rowsort
SELECT - col2 + + col2 * + col0 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT - col2 + tab0.col0 + - col0 * col2 * tab0.col2 AS col1 FROM tab0
----
-1
-26145
-598429

query III rowsort
SELECT * FROM tab1 WHERE ( NULL ) NOT BETWEEN col2 AND + tab1.col1
----

query III rowsort
SELECT * FROM tab2 WHERE NOT ( + col2 * + col2 ) IN ( col0 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query I rowsort
SELECT DISTINCT col2 - + col0 FROM tab2 WHERE NOT NULL BETWEEN NULL AND col2 + col1
----

query I rowsort
SELECT + + ( + col2 ) * + col1 AS col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + col2 + + col0 * col0 FROM tab1
----
4153
63
6496

query I rowsort
SELECT ALL + tab2.col0 AS col0 FROM tab2 WHERE NOT ( - col2 * + col1 ) < ( NULL )
----

query I rowsort
SELECT DISTINCT + tab2.col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
7
78
79

query I rowsort
SELECT DISTINCT + tab2.col1 * tab2.col2 FROM tab2
----
1534
646
837

query I rowsort
SELECT ALL cor0.col0 + 41 FROM tab0, tab1 AS cor0
----
9 values hashing to 43e977fac5670cb543cbc893b4946fb9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6312
SELECT DISTINCT + col2 DIV col2 col0 FROM tab1 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6312
SELECT DISTINCT + col2 / col2 col0 FROM tab1 AS cor0
----
1

query I rowsort
SELECT DISTINCT + 95 * - col2 FROM tab0 AS cor0
----
-3135
-7790
-95

query I rowsort
SELECT - 24 + col1 * col1 FROM tab2 AS cor0
----
265
3457
937

query I rowsort
SELECT - cor0.col0 + 38 FROM tab0 AS cor0
----
-51
14
3

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6316
SELECT - + CAST( - 4 AS SIGNED ) + col0 FROM tab2 cor0
----
11
82
83

skipif mysql # not compatible
query I rowsort label-6316
SELECT - + CAST ( - 4 AS INTEGER ) + col0 FROM tab2 cor0
----
11
82
83

query I rowsort
SELECT + cor0.col0 * - 4 + - col0 * 45 AS col0 FROM tab0 AS cor0
----
-1176
-1715
-4361

onlyif mysql # use DIV operator for integer division
query I rowsort label-6318
SELECT ALL - col0 + col0 DIV col1 FROM tab2 AS cor0
----
-7
-75
-77

skipif mysql # not compatible
query I rowsort label-6318
SELECT ALL - col0 + col0 / col1 FROM tab2 AS cor0
----
-7
-75
-77

query I rowsort
SELECT ALL - + col0 * + col1 + cor0.col0 * 16 - 41 * - col0 FROM tab2 AS cor0
----
-156
182
3160

query I rowsort
SELECT 98 * 39 FROM tab2 AS cor0
----
3822
3822
3822

query I rowsort
SELECT + ( + 81 ) AS col0 FROM tab0 AS cor0
----
81
81
81

query I rowsort
SELECT DISTINCT + - cor0.col2 AS col1 FROM tab0, tab2, tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT DISTINCT 52 AS col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
52

query I rowsort
SELECT DISTINCT + + 61 + + col1 FROM tab0 AS cor0
----
147
152
158

query I rowsort
SELECT ALL + ( - 75 ) FROM tab0 AS cor0
----
-75
-75
-75

query I rowsort
SELECT DISTINCT - 82 * 68 AS col2 FROM tab2 cor0
----
-5576

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * + 99 * - col0 + col2 col1 FROM tab0 AS cor0
----
121276
57057
784261

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 * + col0 * + 9 col1 FROM tab2 cor0
----
12087
1953
41418

query I rowsort
SELECT + - col2 + - ( col0 ) * + col1 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT ALL - cor0.col0 AS col0 FROM tab0, tab1 cor0
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

query I rowsort
SELECT + col1 + - 73 AS col2 FROM tab2 AS cor0
----
-14
-42
-56

query I rowsort
SELECT ALL col0 * + 62 AS col2 FROM tab2
----
434
4836
4898

query I rowsort
SELECT ALL + col2 + - 54 * - ( col0 ) FROM tab2
----
405
4238
4304

onlyif mysql # use DIV operator for integer division
query I rowsort label-6334
SELECT DISTINCT + col0 DIV + col2 + col2 - + col2 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-6334
SELECT DISTINCT + col0 / + col2 + col2 - + col2 FROM tab1
----
0
1

query I rowsort
SELECT ALL - tab0.col0 - tab0.col0 AS col2 FROM tab0
----
-178
-48
-70

onlyif mysql # use DIV operator for integer division
query I rowsort label-6336
SELECT - - col0 DIV 90 + col0 - col1 * + ( - col2 ) AS col1 FROM tab2 AS cor0
----
1612
725
844

skipif mysql # not compatible
query I rowsort label-6336
SELECT - - col0 / 90 + col0 - col1 * + ( - col2 ) AS col1 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-6337
SELECT + cor0.col2 DIV - cor0.col0 + col0 * col2 + col1 AS col1 FROM tab1 AS cor0
----
170
3658
7692

skipif mysql # not compatible
query I rowsort label-6337
SELECT + cor0.col2 / - cor0.col0 + col0 * col2 + col1 AS col1 FROM tab1 AS cor0
----
170
3658
7692

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6338
SELECT ALL + col2 * - CAST( NULL AS SIGNED ) + + col0 * - col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6338
SELECT ALL + col2 * - CAST ( NULL AS INTEGER ) + + col0 * - col0 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6339
SELECT DISTINCT + CAST( NULL AS SIGNED ) * + col0 * col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6339
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * + col0 * col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT 73 + - col1 * + col2 FROM tab0
----
-24
-2765
-7389

query I rowsort
SELECT ALL col0 * - col2 + col1 + - col2 FROM tab1
----
-190
-3695
-7763

query I rowsort
SELECT - 37 + cor0.col2 AS col1 FROM tab2 AS cor0
----
-10
-11
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6343
SELECT - col2 * col1 DIV + col0 + + CAST( col1 AS SIGNED ) * col1 * 78 AS col2 FROM tab1 AS cor0
----
13167
52260
7792

skipif mysql # not compatible
query I rowsort label-6343
SELECT - col2 * col1 / + col0 + + CAST ( col1 AS INTEGER ) * col1 * 78 AS col2 FROM tab1 AS cor0
----
13167
52260
7792

query I rowsort
SELECT DISTINCT - 55 * + col1 AS col2 FROM tab1 AS cor0
----
-1430
-550
-715

query I rowsort
SELECT ALL + + col2 * col1 + col1 * 55 AS col2 FROM tab1 AS cor0
----
1120
1963
2834

query I rowsort
SELECT 16 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

query I rowsort
SELECT col1 * + col0 - col2 * + col0 AS col0 FROM tab1
----
-3008
-6640
-84

query I rowsort
SELECT DISTINCT col0 * cor0.col0 + cor0.col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT ALL - - cor0.col2 - col1 FROM tab0 AS cor0
----
-53
-9
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col0 + - col0 col0 FROM tab1 AS cor0
----
-128
-160
-6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 * - col0 * 71 col0 FROM tab1 cor0
----
11502
259008
545280

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6352
SELECT ALL + cor0.col1 * + col2 + col0 * col0 * CAST( 26 * col1 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
1065530
2164448
7488

skipif mysql # not compatible
query I rowsort label-6352
SELECT ALL + cor0.col1 * + col2 + col0 * col0 * CAST ( 26 * col1 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
1065530
2164448
7488

query I rowsort
SELECT DISTINCT + + col2 + + col2 * col0 AS col1 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT col2 + ( 69 ) AS col0 FROM tab2 AS cor0
----
107
95
96

query I rowsort
SELECT - + col0 * + col0 * + col0 FROM tab1 AS cor0
----
-262144
-27
-512000

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 col0 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT col0 - + ( - 74 ) * cor0.col0 AS col0 FROM tab1 AS cor0
----
225
4800
6000

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6358
SELECT + - col2 * col2 + - ( + cor0.col0 ) / CAST( NULL AS DECIMAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6358
SELECT + - col2 * col2 + - ( + cor0.col0 ) / CAST ( NULL AS REAL ) FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - - col2 + + 36 FROM tab1 AS cor0
----
132
90
93

query I rowsort
SELECT + col2 * - col2 + + 83 AS col2 FROM tab0 AS cor0
----
-1006
-6641
82

query I rowsort
SELECT + col2 + ( - 96 ) AS col0 FROM tab0 AS cor0
----
-14
-63
-95

query I rowsort
SELECT ALL + col1 + col2 + col0 * col2 FROM tab0 AS cor0
----
133
7471
911

query I rowsort
SELECT DISTINCT tab2.col2 * col1 * 89 AS col1 FROM tab2
----
136526
57494
74493

query I rowsort
SELECT col1 + - col0 + + ( + 72 ) * + cor0.col0 AS col2 FROM tab2 cor0
----
528
5597
5626

query I rowsort
SELECT ALL col2 * ( col2 ) FROM tab1
----
2916
3249
9216

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * - col0 + - col0 * col0 col2 FROM tab1
----
-14080
-171
-7744

query I rowsort
SELECT - 11 * + col1 AS col1 FROM tab1
----
-110
-143
-286

query I rowsort
SELECT DISTINCT 71 AS col1 FROM tab1, tab0, tab1 AS cor0
----
71

query I rowsort
SELECT ALL + 33 + + col2 AS col2 FROM tab1
----
129
87
90

query I rowsort
SELECT DISTINCT - 42 * - col2 + + 99 FROM tab1
----
2367
2493
4131

onlyif mysql # use DIV operator for integer division
query I rowsort label-6371
SELECT DISTINCT + col2 DIV tab1.col2 + + col2 FROM tab1
----
55
58
97

skipif mysql # not compatible
query I rowsort label-6371
SELECT DISTINCT + col2 / tab1.col2 + + col2 FROM tab1
----
55
58
97

query I rowsort
SELECT + col0 * col0 * col1 + col0 * + col0 + - ( col1 ) * - col1 AS col1 FROM tab0
----
129459
57508
737013

query I rowsort
SELECT - tab2.col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 6e0b7d583bc2c53842166d3e6ba2d6d2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6374
SELECT col1 * - cor0.col0 * CAST( + ( col1 ) AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

skipif mysql # not compatible
query I rowsort label-6374
SELECT col1 * - cor0.col0 * CAST ( + ( col1 ) AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

query I rowsort
SELECT col0 * + col2 * - col0 FROM tab0
----
-1225
-19008
-649522

onlyif mysql # use DIV operator for integer division
query I rowsort label-6376
SELECT ALL - tab1.col2 DIV 28 AS col2 FROM tab1
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-6376
SELECT ALL - tab1.col2 / 28 AS col2 FROM tab1
----
-1
-2
-3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 38 col1 FROM tab2, tab1 AS cor0
----
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-6378
SELECT col0 + - ( + col0 ) DIV col0 AS col1 FROM tab0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-6378
SELECT col0 + - ( + col0 ) / col0 AS col1 FROM tab0
----
23
34
88

query I rowsort
SELECT cor0.col0 * 80 AS col1 FROM tab2 AS cor0
----
560
6240
6320

query I rowsort
SELECT ALL + + col2 * - cor0.col0 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT ALL - col0 * - 46 FROM tab1 cor0
----
138
2944
3680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6382
SELECT ALL - col1 DIV + ( - col1 ) col0 FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6382
SELECT ALL - col1 / + ( - col1 ) col0 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT 18 AS col1 FROM tab1 AS cor0
----
18
18
18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6384
SELECT + - CAST( NULL AS SIGNED ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6384
SELECT + - CAST ( NULL AS INTEGER ) * col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - ( - col1 ) * - cor0.col1 AS col1 FROM tab1 cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - col2 * - 60 AS col2 FROM tab2 AS cor0
----
1560
1620
2280

query I rowsort
SELECT ALL ( + 73 ) + col2 FROM tab2 AS cor0
----
100
111
99

query I rowsort
SELECT DISTINCT - 54 + col1 AS col2 FROM tab0 AS cor0
----
32
37
43

query I rowsort
SELECT + 43 FROM tab1, tab0 AS cor0
----
9 values hashing to 199105619049271147956de52e7f5ed4

query I rowsort
SELECT ALL 90 FROM tab0, tab2 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT 49 * 51 AS col2 FROM tab1 AS cor0
----
2499
2499
2499

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6392
SELECT - CAST( - 36 AS SIGNED ) + + col2 * cor0.col0 AS col2 FROM tab1 AS cor0
----
198
3684
7716

skipif mysql # not compatible
query I rowsort label-6392
SELECT - CAST ( - 36 AS INTEGER ) + + col2 * cor0.col0 AS col2 FROM tab1 AS cor0
----
198
3684
7716

query I rowsort
SELECT + col0 + - col1 * + 59 AS col2 FROM tab0 AS cor0
----
-5050
-5280
-5688

query I rowsort
SELECT + - col2 * ( col0 ) + - cor0.col2 AS col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT col2 * 1 + + col2 FROM tab0 AS cor0
----
164
2
66

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6396
SELECT DISTINCT col1 * CAST( NULL AS SIGNED ) + col2 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6396
SELECT DISTINCT col1 * CAST ( NULL AS INTEGER ) + col2 AS col2 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * + cor0.col0 col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + + col0 + col2 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT DISTINCT col2 - - ( - col2 + col2 ) AS col2 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT + cor0.col0 + ( + 50 ) AS col1 FROM tab0 AS cor0
----
139
74
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6401
SELECT - cor0.col0 DIV ( - col1 * col0 ) + - col0 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-6401
SELECT - cor0.col0 / ( - col1 * col0 ) + - col0 AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + cor0.col1 * cor0.col2 + col1 AS col1 FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT ALL - cor1.col2 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

query I rowsort
SELECT + col0 * + col0 + col2 FROM tab1 AS cor0
----
4153
63
6496

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - cor0.col2 * - cor0.col0 col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col0 * col0 * col2 - + 55 AS col1 FROM tab2 cor0
----
1268
158129
237103

query I rowsort
SELECT ALL ( - col0 ) - + 28 * col2 * - col0 FROM tab2
----
5285
56706
83977

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6408
SELECT ALL cor0.col1 * - CAST( NULL AS SIGNED ) FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6408
SELECT ALL cor0.col1 * - CAST ( NULL AS INTEGER ) FROM tab1, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT - col0 * col0 - tab1.col2 FROM tab1
----
-4153
-63
-6496

query I rowsort
SELECT + - 20 AS col0 FROM tab2 AS cor0
----
-20
-20
-20

onlyif mysql # use DIV operator for integer division
query I rowsort label-6411
SELECT ALL + col2 DIV col1 - - 67 FROM tab2 AS cor0
----
67
67
69

skipif mysql # not compatible
query I rowsort label-6411
SELECT ALL + col2 / col1 - - 67 FROM tab2 AS cor0
----
67
67
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 + - col1 - - 55 col0 FROM tab0 AS cor0
----
-41
2
46

query I rowsort
SELECT + 72 - - col2 AS col0 FROM tab2 AS cor0
----
110
98
99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6414
SELECT + col2 / col0 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6414
SELECT + col2 / col0 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 2 * col0 + col1 AS col2 FROM tab1 AS cor0
----
138
173
32

query I rowsort
SELECT + - col1 * - col2 + col2 FROM tab0 AS cor0
----
2871
7544
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 75 col2 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

onlyif mysql # use DIV operator for integer division
query I rowsort label-6418
SELECT + - col2 + - 15 DIV + col2 FROM tab0 AS cor0
----
-16
-33
-82

skipif mysql # not compatible
query I rowsort label-6418
SELECT + - col2 + - 15 / + col2 FROM tab0 AS cor0
----
-16
-33
-82

query I rowsort
SELECT - - col1 + - ( - col2 ) * + col0 AS col2 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT - cor0.col1 * 57 * col1 + col0 FROM tab2 AS cor0
----
-16394
-198339
-54770

query I rowsort
SELECT ALL col2 * col0 + - col0 FROM tab2 cor0
----
182
1950
2923

query I rowsort
SELECT DISTINCT col0 + - col1 AS col1 FROM tab1 cor0
----
-23
54
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6423
SELECT + cor0.col1 - + CAST( NULL AS SIGNED ) AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-6423
SELECT + cor0.col1 - + CAST ( NULL AS INTEGER ) AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT - cor0.col1 * 91 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to a77725e3def29fc968577fc9f01effc2

onlyif mysql # use DIV operator for integer division
query I rowsort label-6425
SELECT 73 DIV cor0.col1 FROM tab1, tab2 cor0
----
9 values hashing to 36d00a2b29852f88ac26d257535464fb

skipif mysql # not compatible
query I rowsort label-6425
SELECT 73 / cor0.col1 FROM tab1, tab2 cor0
----
9 values hashing to 36d00a2b29852f88ac26d257535464fb

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6426
SELECT - CAST( NULL AS DECIMAL ) * col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6426
SELECT - CAST ( NULL AS REAL ) * col1 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 60 * + col0 * + col0 FROM tab1 AS cor0
----
-245760
-384000
-540

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col2 + col1 ) * col0 col2 FROM tab1
----
240
4288
8720

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - col2 + col0 ) col1 FROM tab0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6430
SELECT + tab2.col2 DIV - 31 AS col1 FROM tab2
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-6430
SELECT + tab2.col2 / - 31 AS col1 FROM tab2
----
-1
0
0

query I rowsort
SELECT ALL cor1.col0 - - 99 AS col2 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 28963b6a313ad915bceb6f8aead71509

query I rowsort
SELECT - ( ( col0 ) ) * - 29 * + col2 FROM tab2 AS cor0
----
5481
58812
87058

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 62 col0 FROM tab1
----
-62

query I rowsort
SELECT ALL ( 47 + - col1 ) FROM tab1
----
21
34
37

query I rowsort
SELECT ALL + ( - 71 + - col2 ) AS col1 FROM tab1
----
-125
-128
-167

query I rowsort
SELECT ALL + ( cor0.col1 ) + + col0 * - col0 AS col2 FROM tab2 AS cor0
----
-18
-6025
-6224

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * col1 col2 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT DISTINCT + + 64 AS col2 FROM tab1 AS cor0
----
64

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 50 * cor0.col1 col2 FROM tab1 AS cor0
----
1300
500
650

onlyif mysql # use DIV operator for integer division
query I rowsort label-6440
SELECT col0 + + col1 DIV - col1 AS col1 FROM tab1
----
2
63
79

skipif mysql # not compatible
query I rowsort label-6440
SELECT col0 + + col1 / - col1 AS col1 FROM tab1
----
2
63
79

query I rowsort
SELECT ALL + col0 * + tab2.col1 + + 63 * 71 + tab2.col0 AS col1 FROM tab2
----
4697
5895
9153

query I rowsort
SELECT + 46 * - col1 + col0 * 66 FROM tab2
----
-964
2434
4432

query I rowsort
SELECT tab1.col1 + - col0 * col2 + + col2 FROM tab1
----
-3581
-7571
-82

query I rowsort
SELECT ALL + col1 - - col0 FROM tab1
----
29
74
93

query I rowsort
SELECT - col0 * - tab1.col1 - tab1.col1 FROM tab1
----
1027
52
630

query I rowsort
SELECT ALL 13 - col1 FROM tab0
----
-73
-78
-84

query I rowsort
SELECT col2 + - tab2.col2 - - 42 FROM tab2
----
42
42
42

query I rowsort
SELECT 9 * - tab1.col1 + col1 * - col1 FROM tab1
----
-190
-286
-910

query I rowsort
SELECT ALL + col0 + col0 * col1 FROM tab2 AS cor0
----
1422
224
4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6450
SELECT 27 DIV - col0 - 5 AS col0 FROM tab2 AS cor0
----
-5
-5
-8

skipif mysql # not compatible
query I rowsort label-6450
SELECT 27 / - col0 - 5 AS col0 FROM tab2 AS cor0
----
-5
-5
-8

query I rowsort
SELECT + col0 + - cor0.col2 * + 60 FROM tab2 AS cor0
----
-1482
-1613
-2201

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 * - col1 col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT DISTINCT - col1 + 86 * tab2.col0 AS col1 FROM tab2
----
571
6649
6777

query I rowsort
SELECT DISTINCT col1 + - col2 * col2 + - col1 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT - - tab0.col1 FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6456
SELECT - col0 * CAST( + col0 AS SIGNED ) + col0 FROM tab0
----
-1190
-552
-7832

skipif mysql # not compatible
query I rowsort label-6456
SELECT - col0 * CAST ( + col0 AS INTEGER ) + col0 FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT - 92 FROM tab0, tab0 cor0
----
9 values hashing to 1af709a79a3e56281ffdce4d931d5965

query I rowsort
SELECT + cor0.col2 * ( 45 ) AS col0 FROM tab0 AS cor0
----
1485
3690
45

query I rowsort
SELECT col2 * + col2 + col2 FROM tab1
----
2970
3306
9312

onlyif mysql # use DIV operator for integer division
query I rowsort label-6460
SELECT ALL + col0 + - ( - 6 ) + - col0 DIV col0 AS col2 FROM tab0
----
29
40
94

skipif mysql # not compatible
query I rowsort label-6460
SELECT ALL + col0 + - ( - 6 ) + - col0 / col0 AS col2 FROM tab0
----
29
40
94

query I rowsort
SELECT - - col0 * 38 FROM tab1 cor0
----
114
2432
3040

query I rowsort
SELECT ALL + 44 * + col1 FROM tab0 AS cor0
----
3784
4004
4268

onlyif mysql # use DIV operator for integer division
query I rowsort label-6463
SELECT col1 DIV - col0 AS col2 FROM tab1 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-6463
SELECT col1 / - col0 AS col2 FROM tab1 AS cor0
----
-8
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6464
SELECT DISTINCT - CAST( col0 AS SIGNED ) * + col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-6464
SELECT DISTINCT - CAST ( col0 AS INTEGER ) * + col1 AS col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT 51 FROM tab1 cor0
----
51

query I rowsort
SELECT ALL - col0 + - col1 + col2 FROM tab1 AS cor0
----
-17
25
3

query I rowsort
SELECT ALL - ( 58 ) FROM tab1 AS cor0
----
-58
-58
-58

query I rowsort
SELECT ( cor0.col0 ) * + col2 AS col1 FROM tab1 cor0
----
162
3648
7680

query I rowsort
SELECT + - col0 * - col0 + col0 FROM tab2 AS cor0
----
56
6162
6320

query I rowsort
SELECT ALL - - 52 + + col1 FROM tab1 AS cor0
----
62
65
78

query I rowsort
SELECT col2 * + 3 AS col2 FROM tab0 AS cor0
----
246
3
99

query I rowsort
SELECT + cor0.col2 * ( col1 ) AS col2 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT col0 + col0 + - col2 FROM tab1 cor0
----
-48
64
71

query I rowsort
SELECT col2 + ( + col1 ) FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT ALL - - col0 - - cor0.col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT ALL - + cor0.col0 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
-19
-62
24

query I rowsort
SELECT ALL + cor0.col0 - + 69 FROM tab0 cor0
----
-34
-45
20

query I rowsort
SELECT ALL - col2 - col1 * col0 * col0 AS col0 FROM tab0
----
-118826
-49569
-720893

onlyif mysql # use DIV operator for integer division
query I rowsort label-6479
SELECT ALL - col2 - + tab0.col1 DIV col2 FROM tab0
----
-35
-83
-98

skipif mysql # not compatible
query I rowsort label-6479
SELECT ALL - col2 - + tab0.col1 / col2 FROM tab0
----
-35
-83
-98

query I rowsort
SELECT ( col1 ) - - cor0.col2 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT 91 * - col1 + - cor0.col2 FROM tab0 AS cor0
----
-7859
-8363
-8828

query I rowsort
SELECT - + cor0.col2 * + ( col0 ) FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT + col2 + ( 42 + col0 ) FROM tab0
----
213
78
99

query I rowsort
SELECT DISTINCT + - cor0.col1 * col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT DISTINCT + 98 + col2 AS col0 FROM tab1 AS cor0
----
152
155
194

query I rowsort
SELECT ALL ( + col2 ) AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT - 98 * col0 FROM tab1 AS cor0
----
-294
-6272
-7840

onlyif mysql # use DIV operator for integer division
query I rowsort label-6488
SELECT - + col0 + col0 DIV + 42 FROM tab0 AS cor0
----
-24
-35
-87

skipif mysql # not compatible
query I rowsort label-6488
SELECT - + col0 + col0 / + 42 FROM tab0 AS cor0
----
-24
-35
-87

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6489
SELECT DISTINCT ( + col2 ) + tab0.col2 * + CAST( col0 AS SIGNED ) * - col1 FROM tab0
----
-3394
-664036
-68079

skipif mysql # not compatible
query I rowsort label-6489
SELECT DISTINCT ( + col2 ) + tab0.col2 * + CAST ( col0 AS INTEGER ) * - col1 FROM tab0
----
-3394
-664036
-68079

query I rowsort
SELECT ( + 26 ) * + col0 AS col1 FROM tab2
----
182
2028
2054

query I rowsort
SELECT + 24 * col2 FROM tab0
----
1968
24
792

skipif mysql # not compatible
query I rowsort
SELECT CAST ( + 89 AS REAL ) + + col2 FROM tab1
----
143
146
185

query I rowsort
SELECT - + 8 AS col1 FROM tab0 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to 47f43f23dcd23959d97d8e3b0aab692e

query I rowsort
SELECT + col2 + + col2 * + col0 FROM tab1
----
216
3705
7776

query I rowsort
SELECT + - ( + cor0.col0 ) AS col0 FROM tab2 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 3000337dd3f11e9cfd5a312b01ef3f8b

query I rowsort
SELECT + - col0 * - col2 + 27 FROM tab1 AS cor0
----
189
3675
7707

onlyif mysql # use DIV operator for integer division
query I rowsort label-6497
SELECT ALL col2 DIV cor0.col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6497
SELECT ALL col2 / cor0.col2 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL 5 * - col1 FROM tab0 AS cor0
----
-430
-455
-485

query I rowsort
SELECT DISTINCT cor0.col0 + - col1 AS col0 FROM tab2 AS cor0
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 - + col1 * 75 * col2 col1 FROM tab2 AS cor0
----
-115024
-48412
-62748

query I rowsort
SELECT ALL - cor0.col0 + col1 + - col2 FROM tab2 AS cor0
----
-100
-3
-45

query I rowsort
SELECT col1 + + col0 * col1 FROM tab2 AS cor0
----
1360
248
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-6503
SELECT ALL - ( col1 ) DIV 35 + - ( col2 ) DIV ( col2 ) FROM tab1 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6503
SELECT ALL - ( col1 ) / 35 + - ( col2 ) / ( col2 ) FROM tab1 AS cor0
----
-1
-1
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6504
SELECT ALL - tab0.col0 * col1 * - CAST( - col1 AS SIGNED ) col1 FROM tab0
----
-177504
-329315
-737009

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6504
SELECT ALL - tab0.col0 * col1 * - CAST ( - col1 AS INTEGER ) col1 FROM tab0
----
-177504
-329315
-737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-6505
SELECT - col2 + + col0 DIV + cor0.col1 FROM tab2 AS cor0
----
-25
-27
-34

skipif mysql # not compatible
query I rowsort label-6505
SELECT - col2 + + col0 / + cor0.col1 FROM tab2 AS cor0
----
-25
-27
-34

query I rowsort
SELECT + col2 * 35 + col0 * col1 * ( + cor0.col1 ) FROM tab1 AS cor0
----
16880
3918
8395

query I rowsort
SELECT DISTINCT - 41 + - col1 * - col2 * + 21 FROM tab0 AS cor0
----
156661
1996
59557

onlyif mysql # use DIV operator for integer division
query I rowsort label-6508
SELECT ALL - - col0 DIV ( col0 ) AS col0 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-6508
SELECT ALL - - col0 / ( col0 ) AS col0 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT + col0 * - 24 AS col0 FROM tab1 AS cor0
----
-1536
-1920
-72

query I rowsort
SELECT ALL - col0 * col1 * 21 FROM tab2
----
-28203
-4557
-96642

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6511
SELECT col0 * CAST( col0 AS SIGNED ) FROM tab1 AS cor0
----
4096
6400
9

skipif mysql # not compatible
query I rowsort label-6511
SELECT col0 * CAST ( col0 AS INTEGER ) FROM tab1 AS cor0
----
4096
6400
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6512
SELECT ALL + CAST( 12 AS SIGNED ) col0 FROM tab0
----
12
12
12

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6512
SELECT ALL + CAST ( 12 AS INTEGER ) col0 FROM tab0
----
12
12
12

query I rowsort
SELECT + - 69 + + col2 FROM tab1 cor0
----
-12
-15
27

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6514
SELECT ALL + CAST( NULL AS SIGNED ) + col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6514
SELECT ALL + CAST ( NULL AS INTEGER ) + col2 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 35 FROM tab1 cor0
----
-35

query I rowsort
SELECT - 93 - - ( - col1 + col1 * - ( + cor0.col2 ) ) AS col0 FROM tab0 AS cor0
----
-287
-3017
-7646

onlyif mysql # use DIV operator for integer division
query I rowsort label-6517
SELECT DISTINCT + 57 + + col1 DIV - col1 + CAST( - col0 AS SIGNED ) FROM tab0 AS cor0
----
-33
21
32

skipif mysql # not compatible
query I rowsort label-6517
SELECT DISTINCT + 57 + + col1 / - col1 + CAST ( - col0 AS INTEGER ) FROM tab0 AS cor0
----
-33
21
32

query I rowsort
SELECT - + cor0.col0 * col1 * col1 - + ( cor0.col1 ) FROM tab2 AS cor0
----
-22848
-271577
-6758

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 + - col0 * - col0 * ( - 71 ) col1 FROM tab0 AS cor0
----
-40872
-562302
-86940

query I rowsort
SELECT ALL + col0 * - ( col0 ) FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-6521
SELECT ALL 75 * - cor0.col2 + col0 + + col1 DIV col0 AS col1 FROM tab1 AS cor0
----
-4039
-4211
-7120

skipif mysql # not compatible
query I rowsort label-6521
SELECT ALL 75 * - cor0.col2 + col0 + + col1 / col0 AS col1 FROM tab1 AS cor0
----
-4039
-4211
-7120

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * 58 + col0 col2 FROM tab0 AS cor0
----
1416
2065
5251

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6523
SELECT - + CAST( NULL AS DECIMAL ) * - col0 + - col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6523
SELECT - + CAST ( NULL AS REAL ) * - col0 + - col2 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + cor0.col2 + cor0.col2 AS col1 FROM tab0 AS cor0
----
164
2
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - ( - ( + col1 ) ) col0 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT + - ( col0 ) + cor0.col0 AS col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - - 84 * + col1 + + col1 * col0 FROM tab0 AS cor0
----
11543
15743
9288

onlyif mysql # use DIV operator for integer division
query I rowsort label-6528
SELECT ALL cor0.col1 + - col1 DIV - CAST( cor0.col2 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
10
13
26

skipif mysql # not compatible
query I rowsort label-6528
SELECT ALL cor0.col1 + - col1 / - CAST ( cor0.col2 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT col0 * - cor0.col0 FROM tab0 cor0
----
-1225
-576
-7921

query I rowsort
SELECT ALL col0 + + tab0.col2 + tab0.col2 FROM tab0
----
253
37
90

query I rowsort
SELECT ( - col2 ) + cor0.col2 * col0 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT - 67 AS col0 FROM tab2
----
-67
-67
-67

query I rowsort
SELECT - 37 FROM tab1, tab2 cor0
----
9 values hashing to ed4644af7729c2425ea6cc3d84c6504f

query I rowsort
SELECT ALL tab1.col1 * 0 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL + 39 FROM tab0, tab2, tab0 AS cor0
----
27 values hashing to ed2ebd9def3e2c38aa46cb3af60fe229

query I rowsort
SELECT + + 29 - + col0 AS col1 FROM tab0 AS cor0
----
-6
-60
5

query I rowsort
SELECT - - cor0.col0 * - col0 + - 51 FROM tab2 AS cor0
----
-100
-6135
-6292

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6538
SELECT - col1 + col0 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6538
SELECT - col1 + col0 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - + 63 + col1 + col0 * - col1 FROM tab2 AS cor0
----
-1389
-249
-4606

query I rowsort
SELECT - ( + col0 ) * + col1 - col0 AS col0 FROM tab2 AS cor0
----
-1422
-224
-4680

onlyif mysql # use DIV operator for integer division
query I rowsort label-6541
SELECT DISTINCT - 47 DIV + col1 AS col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6541
SELECT DISTINCT - 47 / + col1 AS col1 FROM tab0 AS cor0
----
0

query I rowsort
SELECT DISTINCT + - 43 AS col2 FROM tab2 AS cor0
----
-43

query I rowsort
SELECT + col2 * - col2 * col1 AS col0 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT ALL + 48 * - col0 + col1 AS col2 FROM tab2 AS cor0
----
-305
-3685
-3775

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6545
SELECT col0 + cor0.col0 + - CAST( - col1 AS SIGNED ) FROM tab2 AS cor0
----
175
215
45

skipif mysql # not compatible
query I rowsort label-6545
SELECT col0 + cor0.col0 + - CAST ( - col1 AS INTEGER ) FROM tab2 AS cor0
----
175
215
45

query I rowsort
SELECT ALL - ( + col2 ) FROM tab1 cor0
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col0 + + ( - col2 ) col1 FROM tab2 AS cor0
----
11
111
58

query I rowsort
SELECT + cor0.col1 - cor0.col0 FROM tab2 AS cor0
----
-19
-62
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6549
SELECT DISTINCT + col0 + col1 * CAST( NULL AS SIGNED ) AS col0 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6549
SELECT DISTINCT + col0 + col1 * CAST ( NULL AS INTEGER ) AS col0 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 * + col1 col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT col1 * ( + 75 ) FROM tab1 AS cor0
----
1950
750
975

query I rowsort
SELECT col2 * + cor0.col2 * col0 FROM tab2 cor0
----
114076
5103
52728

query I rowsort
SELECT + col2 + + ( cor0.col1 ) + col0 AS col0 FROM tab0 AS cor0
----
133
143
262

query I rowsort
SELECT ( 66 ) * col2 FROM tab2 cor0
----
1716
1782
2508

query I rowsort
SELECT 23 AS col0 FROM tab2 cor0
----
23
23
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-6556
SELECT DISTINCT 11 DIV - col0 + + col0 FROM tab1 AS cor0
----
0
64
80

skipif mysql # not compatible
query I rowsort label-6556
SELECT DISTINCT 11 / - col0 + + col0 FROM tab1 AS cor0
----
0
64
80

query I rowsort
SELECT + ( + col2 ) * col0 AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - col1 * 90 AS col1 FROM tab1 AS cor0
----
-1170
-2340
-900

query I rowsort
SELECT ALL cor0.col1 * col0 + cor0.col2 FROM tab0 cor0
----
2097
3396
8181

onlyif mysql # use DIV operator for integer division
query I rowsort label-6560
SELECT DISTINCT + + 8 + - col0 DIV col1 FROM tab2 AS cor0
----
4
7
8

skipif mysql # not compatible
query I rowsort label-6560
SELECT DISTINCT + + 8 + - col0 / col1 FROM tab2 AS cor0
----
4
7
8

onlyif mysql # use DIV operator for integer division
query I rowsort label-6561
SELECT DISTINCT col1 DIV 21 FROM tab0 cor0
----
4

skipif mysql # not compatible
query I rowsort label-6561
SELECT DISTINCT col1 / 21 FROM tab0 cor0
----
4

onlyif mysql # use DIV operator for integer division
query I rowsort label-6562
SELECT ALL - col2 DIV - col1 + - col1 AS col1 FROM tab2 AS cor0
----
-15
-31
-59

skipif mysql # not compatible
query I rowsort label-6562
SELECT ALL - col2 / - col1 + - col1 AS col1 FROM tab2 AS cor0
----
-15
-31
-59

query I rowsort
SELECT DISTINCT + col0 - ( col1 ) FROM tab0 AS cor0
----
-2
-62

onlyif mysql # use DIV operator for integer division
query I rowsort label-6564
SELECT ALL - - 55 * + cor0.col1 + col1 DIV 45 FROM tab1 AS cor0
----
1430
550
715

skipif mysql # not compatible
query I rowsort label-6564
SELECT ALL - - 55 * + cor0.col1 + col1 / 45 FROM tab1 AS cor0
----
1430
550
715

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col2 + + col0 col1 FROM tab1 AS cor0
----
-16
-51
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6566
SELECT ALL - CAST( NULL AS SIGNED ) * + 94 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6566
SELECT ALL - CAST ( NULL AS INTEGER ) * + 94 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 19 + - col1 FROM tab1 AS cor0
----
-29
-32
-45

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6568
SELECT DISTINCT + - CAST( - col1 AS SIGNED ) + col0 * + col1 FROM tab1 cor0
----
104
1053
650

skipif mysql # not compatible
query I rowsort label-6568
SELECT DISTINCT + - CAST ( - col1 AS INTEGER ) + col0 * + col1 FROM tab1 cor0
----
104
1053
650

query I rowsort
SELECT ALL - col0 * + cor0.col2 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
-196
-2106
-3081

query I rowsort
SELECT ALL cor0.col2 + - col0 AS col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT DISTINCT - 97 * + col0 + col0 AS col1 FROM tab1 AS cor0
----
-288
-6144
-7680

query I rowsort
SELECT DISTINCT + - 3 + col0 * + col1 * col2 AS col2 FROM tab1 cor0
----
36477
4209
99837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + col1 * - col0 + col2 col2 FROM tab1 cor0
----
-24
-583
-944

onlyif mysql # use DIV operator for integer division
query I rowsort label-6574
SELECT DISTINCT + 89 + cor0.col0 DIV col2 AS col1 FROM tab0 AS cor0
----
124
89
90

skipif mysql # not compatible
query I rowsort label-6574
SELECT DISTINCT + 89 + cor0.col0 / col2 AS col1 FROM tab0 AS cor0
----
124
89
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-6575
SELECT DISTINCT - cor0.col2 DIV + cor0.col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-6575
SELECT DISTINCT - cor0.col2 / + cor0.col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( - col2 AS REAL ) AS col2 FROM tab1 AS cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6577
SELECT ALL - col2 DIV + col0 + ( col0 ) AS col1 FROM tab1 cor0
----
-15
64
79

skipif mysql # not compatible
query I rowsort label-6577
SELECT ALL - col2 / + col0 + ( col0 ) AS col1 FROM tab1 cor0
----
-15
64
79

query I rowsort
SELECT ALL - col2 * - col2 + + col2 AS col0 FROM tab2 AS cor0
----
1482
702
756

query I rowsort
SELECT + 17 + - col1 AS col0 FROM tab2 cor0
----
-14
-42
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 93 col1 FROM tab2 AS cor0
----
-93
-93
-93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor1.col1 col2 FROM tab0 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 72 + - col1 * - col1 * ( + 11 ) col2 FROM tab0
----
103571
81428
91163

query I rowsort
SELECT DISTINCT col2 * 0 FROM tab0 cor0
----
0

query I rowsort
SELECT 8 * col0 * + 45 AS col1 FROM tab0
----
12600
32040
8640

query I rowsort
SELECT ALL - cor0.col1 + - 44 * 12 AS col2 FROM tab0 AS cor0
----
-614
-619
-625

query I rowsort
SELECT ALL + col0 * 70 AS col2 FROM tab2 AS cor0
----
490
5460
5530

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col1 * col2 col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT ALL + 70 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

onlyif mysql # use DIV operator for integer division
query I rowsort label-6589
SELECT DISTINCT col2 * ( + col0 ) + col0 * col0 DIV - 63 col1 FROM tab2
----
189
1932
2903

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6589
SELECT DISTINCT col2 * ( + col0 ) + col0 * col0 / - 63 col1 FROM tab2
----
189
1932
2903

query I rowsort
SELECT DISTINCT + col1 * col2 + - 44 FROM tab2
----
1490
602
793

onlyif mysql # use DIV operator for integer division
query I rowsort label-6591
SELECT DISTINCT + tab1.col2 + - 88 DIV + col2 col1 FROM tab1
----
53
56
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6591
SELECT DISTINCT + tab1.col2 + - 88 / + col2 col1 FROM tab1
----
53
56
96

query I rowsort
SELECT col1 - + tab1.col2 * 60 AS col2 FROM tab1
----
-3214
-3410
-5747

query I rowsort
SELECT col2 * + 57 AS col0 FROM tab2
----
1482
1539
2166

query I rowsort
SELECT DISTINCT + tab1.col1 + 79 * - col2 FROM tab1
----
-4240
-4493
-7571

query I rowsort
SELECT DISTINCT col2 + col1 * tab2.col2 FROM tab2
----
1560
684
864

query I rowsort
SELECT DISTINCT + tab2.col0 + + 52 AS col1 FROM tab2
----
130
131
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6597
SELECT DISTINCT + col0 + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6597
SELECT DISTINCT + col0 + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + col0 FROM tab2 WHERE NOT NULL < NULL
----

query I rowsort
SELECT col2 * - col0 * col1 + tab2.col1 + col1 FROM tab2 WHERE NOT NULL < col2 + col2
----

query I rowsort
SELECT ALL - tab1.col0 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1
----
9 values hashing to 4ec304b8ce935f2226e7548d72c2b2f0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + tab1.col0 col0 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6602
SELECT DISTINCT - col0 DIV col0 col0 FROM tab2 AS cor0
----
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6602
SELECT DISTINCT - col0 / col0 col0 FROM tab2 AS cor0
----
-1

query I rowsort
SELECT col1 + + col2 * - col0 AS col0 FROM tab1 AS cor0
----
-136
-3638
-7667

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 * cor0.col2 col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT + col2 * - col2 AS col2 FROM tab2 cor0
----
-1444
-676
-729

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE NOT NULL NOT BETWEEN + cor0.col1 * col2 AND col0
----

query I rowsort
SELECT ALL col0 + col0 + + col0 * + col0 FROM tab2 AS cor0
----
6240
63
6399

query I rowsort
SELECT - cor0.col2 AS col0 FROM tab2, tab0 cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

query I rowsort
SELECT ALL col2 AS col2 FROM tab1 cor0 WHERE col1 > NULL
----

query I rowsort
SELECT ALL col2 * col2 - col1 AS col0 FROM tab0 cor0
----
-96
1003
6633

onlyif mysql # use DIV operator for integer division
query I rowsort label-6611
SELECT ALL - col2 + col0 DIV + col1 AS col2 FROM tab2 AS cor0
----
-25
-27
-34

skipif mysql # not compatible
query I rowsort label-6611
SELECT ALL - col2 + col0 / + col1 AS col2 FROM tab2 AS cor0
----
-25
-27
-34

query I rowsort
SELECT - col1 + col1 * col1 * col2 AS col0 FROM tab1
----
16211
36478
5690

query I rowsort
SELECT + + col2 + col0 * col1 AS col1 FROM tab2 cor0
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-6614
SELECT DISTINCT col0 DIV + col0 col1 FROM tab1 AS cor0
----
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6614
SELECT DISTINCT col0 / + col0 col1 FROM tab1 AS cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6615
SELECT - col2 + - col2 DIV - col1 FROM tab2 AS cor0
----
-26
-27
-36

skipif mysql # not compatible
query I rowsort label-6615
SELECT - col2 + - col2 / - col1 FROM tab2 AS cor0
----
-26
-27
-36

query I rowsort
SELECT cor0.col2 + + col2 AS col1 FROM tab0 AS cor0
----
164
2
66

query I rowsort
SELECT DISTINCT col2 * + col0 + col1 AS col0 FROM tab0
----
132
7389
878

onlyif mysql # use DIV operator for integer division
query I rowsort label-6618
SELECT ALL + col0 DIV col2 AS col1 FROM tab1 cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6618
SELECT ALL + col0 / col2 AS col1 FROM tab1 cor0
----
0
0
1

query I rowsort
SELECT - col0 * + col1 + - col2 FROM tab1
----
-1136
-132
-697

query I rowsort
SELECT + tab1.col0 + - col0 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT tab0.col2 + + col1 + - col0 * col2 FROM tab0
----
-673
-7125
63

query I rowsort
SELECT + - 60 * col0 AS col2 FROM tab0 AS cor0
----
-1440
-2100
-5340

onlyif mysql # use DIV operator for integer division
query I rowsort label-6623
SELECT + + 92 DIV col2 + + col2 * col0 FROM tab1 AS cor0
----
163
3649
7680

skipif mysql # not compatible
query I rowsort label-6623
SELECT + + 92 / col2 + + col2 * col0 FROM tab1 AS cor0
----
163
3649
7680

query I rowsort
SELECT ALL col0 * - tab2.col2 * + col2 AS col1 FROM tab2
----
-114076
-5103
-52728

query I rowsort
SELECT ALL col0 * tab1.col2 * col0 FROM tab1
----
233472
486
614400

query I rowsort
SELECT DISTINCT + col1 FROM tab1 WHERE - col0 + col0 / - col1 < ( NULL )
----

query I rowsort
SELECT DISTINCT + col2 * col2 * col1 AS col2 FROM tab2
----
22599
24548
39884

query I rowsort
SELECT + col1 + + col2 AS col1 FROM tab2
----
55
58
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-6629
SELECT - - col0 + + col0 * 48 DIV col0 FROM tab1 AS cor0
----
112
128
51

skipif mysql # not compatible
query I rowsort label-6629
SELECT - - col0 + + col0 * 48 / col0 FROM tab1 AS cor0
----
112
128
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + 23 col1 FROM tab2 AS cor0
----
40
54
82

query I rowsort
SELECT + 41 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to f6a440b478f0d00f8326a8c51fe094b8

query I rowsort
SELECT 97 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

query I rowsort
SELECT - tab0.col0 * + col2 AS col0 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT ALL - 30 AS col2 FROM tab1
----
-30
-30
-30

query I rowsort
SELECT tab0.col1 + + col0 + + col2 AS col0 FROM tab0
----
133
143
262

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - tab1.col2 col0 FROM tab1
----
-121
-176
-57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - tab1.col1 * - col1 - col0 col2 FROM tab1 WHERE NULL NOT IN ( - col0 * col0 )
----

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT NULL IN ( col2 + col0 )
----

query I rowsort
SELECT DISTINCT col1 * col1 + - col2 * - col0 FROM tab0
----
15579
8188
9444

query III rowsort
SELECT ALL * FROM tab0 WHERE NULL NOT IN ( + col1 - col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + - col2 * col2 col0 FROM tab2
----
-1427
-617
-698

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col1 - col2 * - col0 col0 FROM tab2
----
2146
251
3036

query I rowsort
SELECT - col2 + col1 AS col1 FROM tab1 WHERE NOT col2 NOT BETWEEN ( NULL ) AND - col2
----

query I rowsort
SELECT - col2 FROM tab2 WHERE col0 * - col0 BETWEEN col2 + - col2 * + col1 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-6645
SELECT col0 DIV col1 col1 FROM tab0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6645
SELECT col0 / col1 col1 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 + + tab0.col2 AS col0 FROM tab0 WHERE NOT ( col1 * + col1 ) NOT BETWEEN col1 / col2 AND - col2
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab1.col2 + tab1.col1 col0 FROM tab1
----
109
67
80

query I rowsort
SELECT col2 FROM tab2 WHERE NOT NULL <> + col1
----

query I rowsort
SELECT + col1 + col0 FROM tab1 WHERE NOT NULL BETWEEN col0 AND ( NULL )
----

query I rowsort
SELECT + col0 + col1 * + col1 AS col2 FROM tab1
----
164
249
679

query I rowsort
SELECT ALL col1 FROM tab2 WHERE - col0 IN ( col1 * col2 )
----

query I rowsort
SELECT ALL col1 * - col1 + col2 AS col1 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT DISTINCT col0 * - col0 + col1 * - col0 AS col2 FROM tab0
----
-16020
-2640
-4620

query I rowsort
SELECT ALL tab1.col1 + col0 * col2 AS col1 FROM tab1
----
188
3658
7693

query I rowsort
SELECT DISTINCT - col2 FROM tab2 WHERE + tab2.col0 > ( col1 )
----
-26
-38

query III rowsort
SELECT * FROM tab0 WHERE NOT col1 > ( col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

onlyif mysql # use DIV operator for integer division
query I rowsort label-6657
SELECT col0 DIV col2 + + tab1.col2 FROM tab1
----
54
58
96

skipif mysql # not compatible
query I rowsort label-6657
SELECT col0 / col2 + + tab1.col2 FROM tab1
----
54
58
96

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL IN ( col2 - col2 )
----

query I rowsort
SELECT tab2.col1 * col0 * col2 AS col1 FROM tab2
----
119652
51034
5859

onlyif mysql # use DIV operator for integer division
query I rowsort label-6660
SELECT - col2 DIV + col0 + - col0 * tab0.col1 * - col2 AS col1 FROM tab0
----
3395
664118
68111

skipif mysql # not compatible
query I rowsort label-6660
SELECT - col2 / + col0 + - col0 * tab0.col1 * - col2 AS col1 FROM tab0
----
3395
664118
68111

onlyif mysql # use DIV operator for integer division
query I rowsort label-6661
SELECT DISTINCT col2 DIV col0 + + col2 + tab2.col0 FROM tab2
----
104
117
37

skipif mysql # not compatible
query I rowsort label-6661
SELECT DISTINCT col2 / col0 + + col2 + tab2.col0 FROM tab2
----
104
117
37

query I rowsort
SELECT - col1 * col0 + col0 AS col1 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT col2 * col2 + tab1.col0 FROM tab1
----
2919
3313
9296

query I rowsort
SELECT - col2 AS col2 FROM tab0 WHERE NOT ( NULL ) IN ( col0 - + col1 )
----

query I rowsort
SELECT cor0.col0 * - 24 AS col0 FROM tab1 AS cor0
----
-1536
-1920
-72

query I rowsort
SELECT + col1 * 36 AS col1 FROM tab2 AS cor0
----
1116
2124
612

query I rowsort
SELECT DISTINCT + + col0 * - 45 FROM tab0 AS cor0
----
-1080
-1575
-4005

query I rowsort
SELECT + tab1.col1 * + col0 - col1 FROM tab1
----
1027
52
630

query I rowsort
SELECT DISTINCT + 4 FROM tab0, tab1 AS cor0, tab0 cor1
----
4

query I rowsort
SELECT DISTINCT + col1 * col1 * - col1 FROM tab1
----
-1000
-17576
-2197

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * tab2.col2 + - 10 col0 FROM tab2
----
-1544
-656
-847

query I rowsort
SELECT + tab1.col0 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to dd18b93263a6cd425fc7cc84d9137870

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + 69 col0 FROM tab0 AS cor0
----
-13
36
68

query IIIIIIIII rowsort
SELECT * FROM tab2, tab1 cor0 CROSS JOIN tab1 cor1
----
243 values hashing to 89e3b35a4a4f02d7b83645addb9dcdc3

query I rowsort
SELECT - ( col0 + col0 ) * ( - 35 ) AS col1 FROM tab2
----
490
5460
5530

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6676
SELECT + 48 + + ( col0 ) + + CAST( - col2 AS SIGNED ) FROM tab0 cor0
----
39
55
82

skipif mysql # not compatible
query I rowsort label-6676
SELECT + 48 + + ( col0 ) + + CAST ( - col2 AS INTEGER ) FROM tab0 cor0
----
39
55
82

query I rowsort
SELECT - + col2 * - col2 + - col2 * + 17 FROM tab0 cor0
----
-16
528
5330

onlyif mysql # use DIV operator for integer division
query I rowsort label-6678
SELECT + 66 DIV - 95 col1 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6678
SELECT + 66 / - 95 col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6679
SELECT + col1 DIV cor0.col2 AS col0 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6679
SELECT + col1 / cor0.col2 AS col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL col2 + col2 + ( col1 ) FROM tab1
----
124
134
205

query I rowsort
SELECT DISTINCT - - tab0.col0 * tab0.col0 AS col0 FROM tab0, tab2, tab2 AS cor0
----
1225
576
7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-6682
SELECT + + 25 DIV + col1 FROM tab2 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6682
SELECT + + 25 / + col1 FROM tab2 AS cor0
----
0
0
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-6683
SELECT + col2 + col1 DIV - ( - col2 + - col0 ) AS col0 FROM tab2 AS cor0
----
26
27
38

skipif mysql # not compatible
query I rowsort label-6683
SELECT + col2 + col1 / - ( - col2 + - col0 ) AS col0 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT - cor0.col2 * + col2 * + 2 + - col2 FROM tab1 AS cor0
----
-18528
-5886
-6555

query I rowsort
SELECT + 94 * + 73 FROM tab2
----
6862
6862
6862

query I rowsort
SELECT - ( + cor0.col1 ) * - col1 FROM tab0 AS cor0
----
7396
8281
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 58 col0 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to a38440572743ed8a3d8af7b49a5388c9

query I rowsort
SELECT cor0.col2 + + 46 FROM tab0, tab2 AS cor0
----
9 values hashing to 12ac2c911ebc449ce7e87e03bf0fdc73

query I rowsort
SELECT DISTINCT col2 * - col1 AS col0 FROM tab1 cor0
----
-1248
-1404
-570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 45 col2 FROM tab0 AS cor0
----
-45
-45
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-6691
SELECT + cor0.col0 DIV - col0 - + 46 * + col1 FROM tab1 AS cor0
----
-1197
-461
-599

skipif mysql # not compatible
query I rowsort label-6691
SELECT + cor0.col0 / - col0 - + 46 * + col1 FROM tab1 AS cor0
----
-1197
-461
-599

onlyif mysql # use DIV operator for integer division
query I rowsort label-6692
SELECT + 93 DIV - col2 FROM tab0 cor0
----
-1
-2
-93

skipif mysql # not compatible
query I rowsort label-6692
SELECT + 93 / - col2 FROM tab0 cor0
----
-1
-2
-93

query I rowsort
SELECT ALL - 11 * cor0.col0 FROM tab2 AS cor0
----
-77
-858
-869

query I rowsort
SELECT ALL - - 29 * + col0 + col0 * col2 AS col1 FROM tab1 AS cor0
----
10000
249
5504

query I rowsort
SELECT - + cor0.col0 * - cor0.col2 * - col0 + + col2 AS col2 FROM tab2 AS cor0
----
-1296
-158158
-237120

query I rowsort
SELECT - col0 + ( col2 ) AS col0 FROM tab0 AS cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6697
SELECT ALL cor0.col0 DIV + 68 + + col0 FROM tab2 AS cor0
----
7
79
80

skipif mysql # not compatible
query I rowsort label-6697
SELECT ALL cor0.col0 / + 68 + + col0 FROM tab2 AS cor0
----
7
79
80

query I rowsort
SELECT ALL + cor0.col0 * - col0 + - col2 + + col1 AS col1 FROM tab1 AS cor0
----
-37
-4143
-6483

query I rowsort
SELECT DISTINCT col2 * + cor0.col1 AS col1 FROM tab0 cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT + + cor0.col0 + + ( + ( col0 ) ) * + 21 FROM tab1 AS cor0
----
1408
1760
66

query I rowsort
SELECT ALL 9 + tab1.col1 AS col0 FROM tab1
----
19
22
35

query I rowsort
SELECT + 94 * + col2 FROM tab2
----
2444
2538
3572

onlyif mysql # use DIV operator for integer division
query I rowsort label-6703
SELECT - col1 DIV 98 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6703
SELECT - col1 / 98 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT - col0 + - col0 + ( + col2 * col0 ) AS col1 FROM tab2
----
175
1872
2844

query I rowsort
SELECT ALL col2 * - col2 - col0 AS col0 FROM tab0 AS cor0
----
-1113
-36
-6813

query I rowsort
SELECT ALL + col1 * 24 AS col0 FROM tab1 AS cor0
----
240
312
624

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6707
SELECT DISTINCT - CAST( NULL AS SIGNED ) + + ( - col1 ) FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6707
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + + ( - col1 ) FROM tab1 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6708
SELECT - + CAST( 78 AS SIGNED ) + cor0.col0 FROM tab0 AS cor0
----
-43
-54
11

skipif mysql # not compatible
query I rowsort label-6708
SELECT - + CAST ( 78 AS INTEGER ) + cor0.col0 FROM tab0 AS cor0
----
-43
-54
11

query I rowsort
SELECT - - col2 * - col1 AS col2 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT + - 30 FROM tab0 AS cor0
----
-30

query I rowsort
SELECT DISTINCT ( 71 ) FROM tab0 cor0
----
71

query I rowsort
SELECT - col1 - 76 * col2 FROM tab0 AS cor0
----
-173
-2594
-6323

query I rowsort
SELECT + + 65 - + 98 FROM tab1 AS cor0
----
-33
-33
-33

query I rowsort
SELECT 75 AS col1 FROM tab2 AS cor0
----
75
75
75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6715
SELECT - CAST( NULL AS SIGNED ) * col1 AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6715
SELECT - CAST ( NULL AS INTEGER ) * col1 AS col1 FROM tab1
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6716
SELECT ALL CAST( NULL AS DECIMAL ) FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-6716
SELECT ALL CAST ( NULL AS REAL ) FROM tab0, tab2, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT DISTINCT + ( - cor0.col0 ) * - 97 FROM tab1 cor0
----
291
6208
7760

query I rowsort
SELECT - - cor0.col0 + + col1 AS col1 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL 20 * col1 AS col0 FROM tab1 AS cor0
----
200
260
520

query I rowsort
SELECT ALL - 30 * cor0.col2 FROM tab0 AS cor0
----
-2460
-30
-990

onlyif mysql # use DIV operator for integer division
query I rowsort label-6721
SELECT col0 * col1 + - col0 DIV + col1 FROM tab2
----
1339
217
4601

skipif mysql # not compatible
query I rowsort label-6721
SELECT col0 * col1 + - col0 / + col1 FROM tab2
----
1339
217
4601

query I rowsort
SELECT ALL + 70 * col1 - col2 FROM tab0
----
5987
6288
6789

onlyif mysql # use DIV operator for integer division
query I rowsort label-6723
SELECT ALL - tab0.col2 DIV - 47 - + tab0.col2 * 3 * ( col2 ) AS col1 FROM tab0
----
-20171
-3
-3267

skipif mysql # not compatible
query I rowsort label-6723
SELECT ALL - tab0.col2 / - 47 - + tab0.col2 * 3 * ( col2 ) AS col1 FROM tab0
----
-20171
-3
-3267

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 + - col0 col0 FROM tab0 AS cor0
----
2
62
62

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 cor2
----
972 values hashing to 5342fb4caf4767cb98bd21989bad099f

onlyif mysql # use DIV operator for integer division
query I rowsort label-6726
SELECT ALL col2 DIV 36 FROM tab2
----
0
0
1

skipif mysql # not compatible
query I rowsort label-6726
SELECT ALL col2 / 36 FROM tab2
----
0
0
1

query I rowsort
SELECT ALL + 60 + - 25 AS col0 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to 0d13dfd4c4a9d51ace3582c31cadcdbc

query I rowsort
SELECT ( 91 ) AS col1 FROM tab1 AS cor0
----
91
91
91

query I rowsort
SELECT - 53 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to fee5c00ad71c23e23683a32c71fe6e7d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 57 * - 52 col0 FROM tab1 AS cor0
----
-2964

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( + cor0.col1 ) * col1 + col1 col0 FROM tab0 AS cor0
----
-7310
-8190
-9312

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col0 + - col1 col1 FROM tab2 cor0
----
-137
-38
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6733
SELECT col2 + + col0 DIV 87 AS col2 FROM tab1
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6733
SELECT col2 + + col0 / 87 AS col2 FROM tab1
----
54
57
96

query I rowsort
SELECT DISTINCT + col0 + - tab0.col1 AS col1 FROM tab0
----
-2
-62

query I rowsort
SELECT DISTINCT + 61 FROM tab0, tab1, tab2 cor0
----
61

query I rowsort
SELECT 10 + - col1 * 24 FROM tab1
----
-230
-302
-614

query I rowsort
SELECT tab0.col1 + col1 + col2 FROM tab0
----
195
205
264

query I rowsort
SELECT DISTINCT + col0 * + tab2.col1 + + col2 AS col0 FROM tab2
----
1381
244
4628

query I rowsort
SELECT ALL - - col0 * col2 + 46 * col2 FROM tab1 cor0
----
12096
2646
6270

query I rowsort
SELECT DISTINCT 79 * col2 AS col2 FROM tab2 AS cor0
----
2054
2133
3002

query I rowsort
SELECT DISTINCT - - col2 * col2 + + 99 AS col0 FROM tab1 cor0
----
3015
3348
9315

query I rowsort
SELECT ALL + + col2 + 48 FROM tab1 cor0
----
102
105
144

query I rowsort
SELECT DISTINCT + col1 + col0 + - 26 * col2 * - col2 FROM tab2 AS cor0
----
17713
18992
37640

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6744
SELECT cor0.col0 - CAST( NULL AS SIGNED ) / col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6744
SELECT cor0.col0 - CAST ( NULL AS INTEGER ) / col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-6745
SELECT - + col0 * 44 - - col1 * col2 DIV 3 AS col1 FROM tab2 AS cor0
----
-29
-2921
-3261

skipif mysql # not compatible
query I rowsort label-6745
SELECT - + col0 * 44 - - col1 * col2 / 3 AS col1 FROM tab2 AS cor0
----
-29
-2921
-3261

query I rowsort
SELECT DISTINCT - cor0.col1 + col2 * + 17 + + col1 FROM tab1 AS cor0
----
1632
918
969

query I rowsort
SELECT - - col0 + 2 * - col2 FROM tab2 cor0
----
-47
26
3

query I rowsort
SELECT DISTINCT + + col1 + 22 FROM tab2 AS cor0
----
39
53
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-6749
SELECT ALL + col0 DIV - cor0.col1 + + cor0.col2 * + col1 + - 25 * + 73 AS col2 FROM tab1 cor0
----
-1261
-421
-583

skipif mysql # not compatible
query I rowsort label-6749
SELECT ALL + col0 / - cor0.col1 + + cor0.col2 * + col1 + - 25 * + 73 AS col2 FROM tab1 cor0
----
-1261
-421
-583

query I rowsort
SELECT - col2 * ( - col2 + col0 ) FROM tab1 AS cor0
----
-399
1536
2754

query I rowsort
SELECT ALL col1 * col2 - col1 AS col0 FROM tab2
----
1475
629
806

query I rowsort
SELECT + + col0 + + 49 FROM tab2 AS cor0
----
127
128
56

query I rowsort
SELECT + col2 * + col1 + col0 - - col0 FROM tab1 AS cor0
----
1408
1410
698

query I rowsort
SELECT ALL col0 * 5 + col0 AS col0 FROM tab2 AS cor0
----
42
468
474

query I rowsort
SELECT - + col2 - col0 * - cor0.col2 FROM tab0 AS cor0
----
34
7216
759

onlyif mysql # use DIV operator for integer division
query I rowsort label-6756
SELECT col0 DIV - 91 AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6756
SELECT col0 / - 91 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT + col0 * + 41 AS col1 FROM tab2 AS cor0
----
287
3198
3239

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 65 col2 FROM tab2, tab2 AS cor0
----
65

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6759
SELECT tab1.col1 * - CAST( NULL AS DECIMAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6759
SELECT tab1.col1 * - CAST ( NULL AS REAL ) AS col1 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT tab2.col1 * + col1 * tab2.col1 + col2 + col2 AS col2 FROM tab2
----
205431
29845
4989

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6761
SELECT ALL + col1 + - CAST( NULL AS SIGNED ) / col1 AS col1 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6761
SELECT ALL + col1 + - CAST ( NULL AS INTEGER ) / col1 AS col1 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col0 * - ( - tab0.col0 ) AS col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT - col0 * col0 * col2 FROM tab2 AS cor0
----
-1323
-158184
-237158

query I rowsort
SELECT - 54 * - col1 AS col1 FROM tab2 cor0
----
1674
3186
918

query I rowsort
SELECT ALL + + ( col2 ) * - col0 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-6766
SELECT DISTINCT col2 DIV - cor0.col0 + - col2 + ( col1 * ( 10 ) ) FROM tab0 AS cor0
----
826
828
969

skipif mysql # not compatible
query I rowsort label-6766
SELECT DISTINCT col2 / - cor0.col0 + - col2 + ( col1 * ( 10 ) ) FROM tab0 AS cor0
----
826
828
969

query I rowsort
SELECT - + 52 * + col0 AS col0 FROM tab0 AS cor0
----
-1248
-1820
-4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-6768
SELECT DISTINCT - - 93 DIV 31 FROM tab2, tab0, tab1 AS cor0
----
3

skipif mysql # not compatible
query I rowsort label-6768
SELECT DISTINCT - - 93 / 31 FROM tab2, tab0, tab1 AS cor0
----
3

query I rowsort
SELECT 39 * - 0 AS col0 FROM tab2, tab2 AS cor0, tab2 cor1
----
27 values hashing to e2568b01dd411b5a206068697d0ed0d2

query I rowsort
SELECT - 52 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to e8a5cb10c0973a78554f344d4f6e7e74

query I rowsort
SELECT DISTINCT 73 * - cor0.col2 + ( - cor0.col0 + cor0.col1 ) * 29 AS col0 FROM tab2 AS cor0
----
-1275
-2449
-4572

query I rowsort
SELECT ALL + 41 * - col1 - + col2 FROM tab1 cor0
----
-1120
-467
-629

query I rowsort
SELECT + col2 + + 52 AS col2 FROM tab2 AS cor0
----
78
79
90

query I rowsort
SELECT + 87 + cor0.col0 FROM tab1 cor0
----
151
167
90

query I rowsort
SELECT ( - col0 ) * - col2 - col2 FROM tab2
----
162
2002
2964

query I rowsort
SELECT - 39 + - col2 * col0 FROM tab2
----
-2067
-228
-3041

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 44 * col2 col0 FROM tab2 AS cor0
----
1144
1188
1672

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6778
SELECT ALL + CAST( NULL AS SIGNED ) * - col0 + cor0.col0 * + col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6778
SELECT ALL + CAST ( NULL AS INTEGER ) * - col0 + cor0.col0 * + col1 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 86 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 9d2e1e8eda15b3b83dd7136dfc4f19af

query I rowsort
SELECT + 47 AS col0 FROM tab1 cor0
----
47
47
47

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - col1 + - col0 col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + + col2 * + col2 FROM tab2 cor0
----
1444
676
729

query I rowsort
SELECT DISTINCT + - 83 + col2 + col2 AS col0 FROM tab2 AS cor0
----
-29
-31
-7

query I rowsort
SELECT DISTINCT + cor0.col2 * cor0.col2 + col1 AS col0 FROM tab0 AS cor0
----
1175
6815
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 9 col0 FROM tab2
----
-9
-9
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6786
SELECT DISTINCT - - col0 + col2 DIV - cor0.col2 FROM tab0 AS cor0
----
23
34
88

skipif mysql # not compatible
query I rowsort label-6786
SELECT DISTINCT - - col0 + col2 / - cor0.col2 FROM tab0 AS cor0
----
23
34
88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col0 col2 FROM tab1 cor0
----
3
64
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-6788
SELECT - 67 DIV - col2 col2 FROM tab0 AS cor0
----
0
2
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6788
SELECT - 67 / - col2 col2 FROM tab0 AS cor0
----
0
2
67

query I rowsort
SELECT col2 + col0 * 52 FROM tab0 AS cor0
----
1281
1821
4710

query I rowsort
SELECT DISTINCT 49 + + col0 AS col0 FROM tab1
----
113
129
52

query I rowsort
SELECT ALL col0 * + ( - col2 * + col1 ) AS col2 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT - cor0.col1 * - col1 + 31 FROM tab0 AS cor0
----
7427
8312
9440

query I rowsort
SELECT + + col1 + + col2 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
-1003
-6633
96

query I rowsort
SELECT DISTINCT - cor0.col2 + + 65 FROM tab1 AS cor0
----
-31
11
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6795
SELECT + col1 + CAST( NULL AS SIGNED ) * 15 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-6795
SELECT + col1 + CAST ( NULL AS INTEGER ) * 15 col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * ( col0 + + col2 ) AS col0 FROM tab1 cor0
----
1210
1482
2288

query I rowsort
SELECT - col0 - 15 FROM tab0 AS cor0
----
-104
-39
-50

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6798
SELECT col1 * - CAST( col1 AS SIGNED ) - col1 AS col1 FROM tab1 AS cor0
----
-110
-182
-702

skipif mysql # not compatible
query I rowsort label-6798
SELECT col1 * - CAST ( col1 AS INTEGER ) - col1 AS col1 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT + col1 * - col0 + - col2 AS col1 FROM tab1 cor0
----
-1136
-132
-697

query I rowsort
SELECT DISTINCT col2 * col0 * + col0 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT + + col0 * + 53 FROM tab1 cor0
----
159
3392
4240

onlyif mysql # use DIV operator for integer division
query I rowsort label-6802
SELECT - col0 DIV + tab0.col0 AS col2 FROM tab0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-6802
SELECT - col0 / + tab0.col0 AS col2 FROM tab0
----
-1
-1
-1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 44 col0 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT + col0 * 58 AS col0 FROM tab2
----
406
4524
4582

query I rowsort
SELECT - - col0 * col2 + + 69 * - col0 AS col1 FROM tab1 AS cor0
----
-45
-768
2160

query I rowsort
SELECT + col0 + - 76 AS col2 FROM tab1 cor0
----
-12
-73
4

query I rowsort
SELECT - - col1 - col2 AS col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT ALL col0 * - 84 + + col2 - + col0 * 36 AS col2 FROM tab1
----
-306
-7623
-9504

query I rowsort
SELECT ALL + col2 - 12 * - col2 FROM tab0
----
1066
13
429

query I rowsort
SELECT ALL col2 + - col1 - 95 * col2 AS col0 FROM tab1
----
-5102
-5368
-9037

query I rowsort
SELECT ALL ( + col2 ) - col2 AS col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + col0 + + cor0.col1 * cor0.col1 AS col0 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT DISTINCT + 62 + - col2 FROM tab0 cor0
----
-20
29
61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6814
SELECT DISTINCT - col0 + CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-6814
SELECT DISTINCT - col0 + CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL

query I rowsort
SELECT DISTINCT tab1.col2 + col0 * 65 * + col1 FROM tab1
----
41657
5124
67696

query I rowsort
SELECT 5 * 8 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to b1e8ffeef334b4a2b01b2f91e649c2d3

query I rowsort
SELECT DISTINCT 39 AS col0 FROM tab1
----
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6818
SELECT - 54 + cor0.col0 * col2 + CAST( NULL AS SIGNED ) * - col2 FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6818
SELECT - 54 + cor0.col0 * col2 + CAST ( NULL AS INTEGER ) * - col2 FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - cor1.col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
-10
-13
-26

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab0 cor0, tab2, tab0 AS cor1
----
972 values hashing to 380241bbc503a31e70494611a87ffd99

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6821
SELECT - CAST( - col1 AS SIGNED ) + col2 FROM tab2 cor0
----
55
58
85

skipif mysql # not compatible
query I rowsort label-6821
SELECT - CAST ( - col1 AS INTEGER ) + col2 FROM tab2 cor0
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6822
SELECT DISTINCT + CAST( + col1 AS SIGNED ) + col1 AS col0 FROM tab0 AS cor0
----
172
182
194

skipif mysql # not compatible
query I rowsort label-6822
SELECT DISTINCT + CAST ( + col1 AS INTEGER ) + col1 AS col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT ALL col1 - + col2 * col1 AS col2 FROM tab0 AS cor0
----
-2752
-7371
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-6824
SELECT DISTINCT + ( + 90 ) DIV col2 + col1 * + 30 + col0 AS col1 FROM tab1 AS cor0
----
365
470
784

skipif mysql # not compatible
query I rowsort label-6824
SELECT DISTINCT + ( + 90 ) / col2 + col1 * + 30 + col0 AS col1 FROM tab1 AS cor0
----
365
470
784

onlyif mysql # use DIV operator for integer division
query I rowsort label-6825
SELECT - + col1 DIV - col1 + cor0.col1 DIV - 6 col0 FROM tab2 AS cor0
----
-1
-4
-8

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6825
SELECT - + col1 / - col1 + cor0.col1 / - 6 col0 FROM tab2 AS cor0
----
-1
-4
-8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6826
SELECT DISTINCT - + CAST( NULL AS SIGNED ) * col1 + + col2 * - col0 + + 93 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6826
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) * col1 + + col2 * - col0 + + 93 FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL - ( + cor0.col2 ) - cor0.col0 AS col0 FROM tab0 AS cor0
----
-171
-36
-57

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6828
SELECT CAST( NULL AS SIGNED ) + col1 * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6828
SELECT CAST ( NULL AS INTEGER ) + col1 * - col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + 90 * + col1 FROM tab0 AS cor0
----
7740
8190
8730

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6830
SELECT DISTINCT + - CAST( NULL AS DECIMAL ) / + 34 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-6830
SELECT DISTINCT + - CAST ( NULL AS REAL ) / + 34 FROM tab0 cor0
----
NULL

query I rowsort
SELECT + - 21 + col2 * + cor0.col0 AS col2 FROM tab2 AS cor0
----
168
2007
2981

query I rowsort
SELECT ALL + col2 + col0 + - col0 * + col0 FROM tab1 cor0
----
-3975
-6224
48

query I rowsort
SELECT + 10 + + ( + cor0.col2 ) AS col0 FROM tab0 AS cor0
----
11
43
92

query I rowsort
SELECT ALL - - 47 * 28 AS col1 FROM tab2 AS cor0
----
1316
1316
1316

query I rowsort
SELECT DISTINCT 14 * tab1.col1 AS col0 FROM tab1
----
140
182
364

query I rowsort
SELECT ALL - 58 AS col2 FROM tab2
----
-58
-58
-58

query I rowsort
SELECT - 28 * cor0.col2 * cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to e4b7cd22e4f5389eaf565ae0cd52ff41

query I rowsort
SELECT ALL + - 21 FROM tab0 cor0
----
-21
-21
-21

onlyif mysql # use DIV operator for integer division
query I rowsort label-6839
SELECT - + 45 + - cor0.col2 DIV + ( ( col1 ) ) FROM tab2 AS cor0
----
-45
-45
-47

skipif mysql # not compatible
query I rowsort label-6839
SELECT - + 45 + - cor0.col2 / + ( ( col1 ) ) FROM tab2 AS cor0
----
-45
-45
-47

query I rowsort
SELECT + 36 * - col2 FROM tab0 AS cor0
----
-1188
-2952
-36

query I rowsort
SELECT DISTINCT - - col0 + + 30 * col2 AS col0 FROM tab2 AS cor0
----
1219
817
858

query I rowsort
SELECT ALL + col1 * 60 AS col0 FROM tab0 AS cor0
----
5160
5460
5820

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6843
SELECT ALL - col2 + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6843
SELECT ALL - col2 + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + col1 * - 44 * - cor0.col1 FROM tab2 AS cor0
----
12716
153164
42284

query I rowsort
SELECT cor0.col0 - - ( - 77 ) AS col0 FROM tab0 AS cor0
----
-42
-53
12

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab2 AS cor0, tab1 cor1, tab2, tab2 AS cor2
----
3645 values hashing to c670882ff9ea3f0bb08fc55ec569be96

query I rowsort
SELECT ALL col1 * col0 + col0 * cor0.col1 FROM tab2 AS cor0
----
2686
434
9204

onlyif mysql # use DIV operator for integer division
query I rowsort label-6848
SELECT cor0.col2 DIV - 37 AS col0 FROM tab0 cor0
----
-2
0
0

skipif mysql # not compatible
query I rowsort label-6848
SELECT cor0.col2 / - 37 AS col0 FROM tab0 cor0
----
-2
0
0

query I rowsort
SELECT + col2 * - col1 AS col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - ( + cor0.col0 ) AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

query I rowsort
SELECT + col1 * - col0 + - ( - col1 ) AS col0 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT + + 85 + + col2 AS col2 FROM tab1 AS cor0
----
139
142
181

query I rowsort
SELECT col1 * col2 + 56 FROM tab1 AS cor0
----
1304
1460
626

query I rowsort
SELECT - col1 * + col0 + 5 AS col2 FROM tab1 AS cor0
----
-1035
-635
-73

query I rowsort
SELECT col2 * + col0 - - col0 FROM tab2 AS cor0
----
196
2106
3081

query I rowsort
SELECT DISTINCT - 94 + col2 AS col2 FROM tab2 AS cor0
----
-56
-67
-68

query I rowsort
SELECT ALL cor0.col0 + + cor0.col1 AS col0 FROM tab2 AS cor0
----
137
38
96

query I rowsort
SELECT - 56 + - col2 AS col2 FROM tab1 AS cor0
----
-110
-113
-152

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * + cor0.col1 col1 FROM tab2 cor0
----
-289
-3481
-961

onlyif mysql # use DIV operator for integer division
query I rowsort label-6860
SELECT ALL + ( tab1.col2 ) DIV col1 - - col1 AS col2 FROM tab1
----
15
20
28

skipif mysql # not compatible
query I rowsort label-6860
SELECT ALL + ( tab1.col2 ) / col1 - - col1 AS col2 FROM tab1
----
15
20
28

query I rowsort
SELECT ALL 70 FROM tab0, tab1 AS cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT - col2 - col1 AS col2 FROM tab1 cor0
----
-109
-67
-80

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6863
SELECT + 57 * - col1 * CAST( 78 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-137826
-262314
-75582

skipif mysql # not compatible
query I rowsort label-6863
SELECT + 57 * - col1 * CAST ( 78 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-137826
-262314
-75582

query I rowsort
SELECT - + col2 * + col1 + - cor0.col2 FROM tab2 cor0
----
-1560
-684
-864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6865
SELECT 33 + + col2 / col0 + col0 * + col1 * - CAST( NULL AS SIGNED ) col0 FROM tab2
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-6865
SELECT 33 + + col2 / col0 + col0 * + col1 * - CAST ( NULL AS INTEGER ) col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - 56 AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
-56

query I rowsort
SELECT 48 FROM tab2, tab0 cor0, tab1 AS cor1
----
27 values hashing to 0ef571a8722ab7270aa7272c1174b88e

query I rowsort
SELECT DISTINCT - 33 AS col0 FROM tab2, tab1 AS cor0
----
-33

query I rowsort
SELECT col0 * - col2 * cor0.col0 + + col1 FROM tab2 AS cor0
----
-1292
-158125
-237141

onlyif mysql # use DIV operator for integer division
query I rowsort label-6870
SELECT 42 DIV col0 AS col1 FROM tab2
----
0
0
6

skipif mysql # not compatible
query I rowsort label-6870
SELECT 42 / col0 AS col1 FROM tab2
----
0
0
6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 14 + + 46 * - col0 col2 FROM tab1 cor0
----
-124
-2930
-3666

query I rowsort
SELECT DISTINCT - 25 AS col0 FROM tab0, tab1, tab0 AS cor0
----
-25

query I rowsort
SELECT DISTINCT + cor1.col1 AS col2 FROM tab1, tab0 AS cor0, tab0 AS cor1
----
86
91
97

query I rowsort
SELECT 12 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to d4f5a8e032294c3b9342821617800972

query I rowsort
SELECT - 9 AS col1 FROM tab1
----
-9
-9
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-6876
SELECT ALL 1 DIV col0 + col0 * col0 * col2 FROM tab0 AS cor0
----
1225
19008
649522

skipif mysql # not compatible
query I rowsort label-6876
SELECT ALL 1 / col0 + col0 * col0 * col2 FROM tab0 AS cor0
----
1225
19008
649522

query I rowsort
SELECT ALL + ( col0 ) * cor0.col1 + ( - 64 ) + cor0.col0 * ( + col0 + - col2 * + col0 ) FROM tab1 AS cor0
----
-228800
-463
-607024

query I rowsort
SELECT DISTINCT + col1 - + 30 * - col0 AS col1 FROM tab2 AS cor0
----
2387
2399
241

query I rowsort
SELECT ALL - - 35 + + col0 * col1 FROM tab1 AS cor0
----
1075
113
675

query I rowsort
SELECT + - col1 * + col1 * col2 AS col2 FROM tab1 AS cor0
----
-16224
-36504
-5700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( - col0 ) * cor0.col0 - + ( col2 ) col2 FROM tab2 AS cor0
----
22
6058
6203

query I rowsort
SELECT ALL + cor0.col2 AS col1 FROM tab2, tab0 cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT + 94 + 73 * + col2 AS col0 FROM tab0 AS cor0
----
167
2503
6080

query I rowsort
SELECT + col2 * + col1 + - col2 AS col0 FROM tab0 AS cor0
----
2805
7380
96

query I rowsort
SELECT - 40 + - col1 AS col1 FROM tab0 AS cor0
----
-126
-131
-137

onlyif mysql # use DIV operator for integer division
query I rowsort label-6886
SELECT DISTINCT + - col0 * col2 DIV + col0 AS col1 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-6886
SELECT DISTINCT + - col0 * col2 / + col0 AS col1 FROM tab1 AS cor0
----
-54
-57
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-6887
SELECT 56 DIV - col0 AS col1 FROM tab2 AS cor0
----
-8
0
0

skipif mysql # not compatible
query I rowsort label-6887
SELECT 56 / - col0 AS col1 FROM tab2 AS cor0
----
-8
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col2 * cor1.col2 * 81 col2 FROM tab2, tab2 AS cor0, tab2 cor1
----
27 values hashing to 1f3dad39efd864d92494f58c45cfb3af

query I rowsort
SELECT ALL col2 * 84 AS col2 FROM tab0
----
2772
6888
84

query I rowsort
SELECT 75 AS col0 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT - - cor0.col0 * ( col2 ) * col2 FROM tab0 AS cor0
----
26136
35
598436

onlyif mysql # use DIV operator for integer division
query I rowsort label-6892
SELECT col1 DIV - CAST( - 28 AS SIGNED ) FROM tab0 AS cor0
----
3
3
3

skipif mysql # not compatible
query I rowsort label-6892
SELECT col1 / - CAST ( - 28 AS INTEGER ) FROM tab0 AS cor0
----
3
3
3

query I rowsort
SELECT + 62 + 75 * col1 * col2 FROM tab0 AS cor0
----
212912
559712
7337

query I rowsort
SELECT - 0 * - col2 AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT 16 * cor0.col0 AS col1 FROM tab2 AS cor0
----
112
1248
1264

query I rowsort
SELECT + + ( - 13 ) * cor0.col1 AS col0 FROM tab0 AS cor0
----
-1118
-1183
-1261

query I rowsort
SELECT - ( + col2 ) * col1 FROM tab2 AS cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-6898
SELECT 38 DIV + col0 FROM tab1 cor0
----
0
0
12

skipif mysql # not compatible
query I rowsort label-6898
SELECT 38 / + col0 FROM tab1 cor0
----
0
0
12

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6899
SELECT ALL col0 * CAST( col2 AS SIGNED ) * col0 FROM tab1
----
233472
486
614400

skipif mysql # not compatible
query I rowsort label-6899
SELECT ALL col0 * CAST ( col2 AS INTEGER ) * col0 FROM tab1
----
233472
486
614400

query I rowsort
SELECT 0 * col0 + - col1 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT + - ( + col1 ) * col2 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT - - col1 * + 51 + cor0.col0 AS col1 FROM tab0 AS cor0
----
4410
4730
4982

query I rowsort
SELECT DISTINCT col2 * - col2 - 80 AS col1 FROM tab0
----
-1169
-6804
-81

query I rowsort
SELECT + + 29 AS col2 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col2 + + col0 col0 FROM tab2
----
1523
736
754

query I rowsort
SELECT - col2 * - col2 * 44 + + 82 * col0 + + col1 FROM tab1
----
128576
148214
412077

query I rowsort
SELECT ALL + 85 * col1 - + 78 FROM tab2
----
1367
2557
4937

onlyif mysql # use DIV operator for integer division
query I rowsort label-6908
SELECT ALL 28 - tab2.col0 DIV + col1 FROM tab2
----
24
27
28

skipif mysql # not compatible
query I rowsort label-6908
SELECT ALL 28 - tab2.col0 / + col1 FROM tab2
----
24
27
28

query I rowsort
SELECT ALL - + col1 + + cor0.col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + cor0.col1 AS col0 FROM tab1, tab1 cor0
----
10
13
26

query I rowsort
SELECT - 40 + - col0 * 51 * 25 FROM tab2 AS cor0
----
-100765
-8965
-99490

query I rowsort
SELECT - cor0.col2 * - col1 + 78 FROM tab2 cor0
----
1612
724
915

query I rowsort
SELECT + - 98 + col0 - - 53 FROM tab1 AS cor0
----
-42
19
35

query I rowsort
SELECT ALL + col0 + cor0.col1 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT DISTINCT col0 + col2 * - col1 AS col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT - col0 + cor0.col2 AS col1 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT ALL + col2 * ( + 44 ) FROM tab2 AS cor0
----
1144
1188
1672

query I rowsort
SELECT DISTINCT 38 * col2 AS col2 FROM tab1
----
2052
2166
3648

query I rowsort
SELECT DISTINCT - cor0.col0 * ( - tab0.col1 ) AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 116454f2268e21c1351daf3f5803c987

query I rowsort
SELECT ALL + tab0.col0 * col0 FROM tab0
----
1225
576
7921

query I rowsort
SELECT ALL - col0 + + 65 AS col2 FROM tab2 AS cor0
----
-13
-14
58

query I rowsort
SELECT ALL - - col1 * cor0.col0 AS col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT + col1 + ( col1 ) AS col1 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT col1 + ( cor0.col0 ) AS col0 FROM tab1 AS cor0
----
29
74
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6925
SELECT + col1 * CAST( 96 AS SIGNED ) * - cor0.col1 FROM tab2 cor0
----
-27744
-334176
-92256

skipif mysql # not compatible
query I rowsort label-6925
SELECT + col1 * CAST ( 96 AS INTEGER ) * - cor0.col1 FROM tab2 cor0
----
-27744
-334176
-92256

query I rowsort
SELECT - cor0.col0 + col1 * col0 AS col2 FROM tab2 AS cor0
----
1264
210
4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6927
SELECT + + CAST( 98 AS SIGNED ) * - col1 AS col2 FROM tab0 AS cor0
----
-8428
-8918
-9506

skipif mysql # not compatible
query I rowsort label-6927
SELECT + + CAST ( 98 AS INTEGER ) * - col1 AS col2 FROM tab0 AS cor0
----
-8428
-8918
-9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-6928
SELECT ALL - 86 DIV 1 + + col1 * + 23 FROM tab1 cor0
----
144
213
512

skipif mysql # not compatible
query I rowsort label-6928
SELECT ALL - 86 / 1 + + col1 * + 23 FROM tab1 cor0
----
144
213
512

query I rowsort
SELECT DISTINCT 90 * col2 + cor0.col1 * - ( + col0 ) FROM tab1 AS cor0
----
4490
4782
7600

query I rowsort
SELECT - 68 AS col0 FROM tab1 AS cor0
----
-68
-68
-68

query I rowsort
SELECT + 37 + - col2 AS col2 FROM tab0 AS cor0
----
-45
36
4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6932
SELECT ALL CAST( - 63 AS SIGNED ) + col1 FROM tab1 AS cor0
----
-37
-50
-53

skipif mysql # not compatible
query I rowsort label-6932
SELECT ALL CAST ( - 63 AS INTEGER ) + col1 FROM tab1 AS cor0
----
-37
-50
-53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - col0 col1 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT + col1 * cor0.col2 + + col1 * col0 FROM tab2 cor0
----
1054
1989
6136

query I rowsort
SELECT - 77 + cor0.col2 FROM tab0 AS cor0
----
-44
-76
5

query I rowsort
SELECT DISTINCT - 78 AS col1 FROM tab2, tab1 AS cor0
----
-78

query I rowsort
SELECT ALL tab0.col2 AS col1 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 7786718bd8042022537378d40ec87475

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 17 col1 FROM tab2 cor0
----
-17

query I rowsort
SELECT ALL + col2 + + cor0.col0 * col0 AS col2 FROM tab0 cor0
----
1226
609
8003

query I rowsort
SELECT ALL - 90 AS col0 FROM tab1 AS cor0
----
-90
-90
-90

query I rowsort
SELECT ALL + + col0 * + cor0.col0 + - col1 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT + + col1 + col2 * col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT - - col0 - col1 AS col0 FROM tab0 AS cor0
----
-2
-62

query I rowsort
SELECT DISTINCT + + 18 + col0 + col1 FROM tab1 AS cor0
----
111
47
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-6945
SELECT ALL col1 + - col2 DIV + col2 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-6945
SELECT ALL col1 + - col2 / + col2 FROM tab1 AS cor0
----
12
25
9

query I rowsort
SELECT DISTINCT + + cor0.col2 * - col0 * + col2 + + col2 FROM tab0 AS cor0
----
-26103
-34
-598354

query I rowsort
SELECT DISTINCT cor0.col2 - + col2 AS col1 FROM tab0 cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 15 col0 FROM tab2
----
15

query I rowsort
SELECT col0 - col1 * col2 FROM tab1
----
-1168
-1401
-506

query I rowsort
SELECT - ( - cor0.col2 ) * col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + col1 * col1 * col2 FROM tab0 AS cor0
----
244068
679042
9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 59 col0 FROM tab1
----
59
59
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-6953
SELECT + col2 + + col2 DIV col1 + - col0 * col0 AS col2 FROM tab2
----
-22
-6058
-6201

skipif mysql # not compatible
query I rowsort label-6953
SELECT + col2 + + col2 / col1 + - col0 * col0 AS col2 FROM tab2
----
-22
-6058
-6201

query I rowsort
SELECT DISTINCT tab2.col0 * + col1 - - tab2.col2 FROM tab2
----
1381
244
4628

query I rowsort
SELECT DISTINCT col1 - + tab2.col0 * col1 FROM tab2
----
-1326
-186
-4543

query I rowsort
SELECT tab1.col1 + - col2 * tab1.col0 * + tab1.col0 AS col0 FROM tab1
----
-233462
-460
-614387

query I rowsort
SELECT col1 * + tab1.col1 + + tab1.col0 * + col0 - - tab1.col2 * + col2 * col0 FROM tab1
----
212132
743849
9433

onlyif mysql # use DIV operator for integer division
query I rowsort label-6958
SELECT DISTINCT - + col0 + col2 DIV - col0 FROM tab0 AS cor0
----
-25
-35
-89

skipif mysql # not compatible
query I rowsort label-6958
SELECT DISTINCT - + col0 + col2 / - col0 FROM tab0 AS cor0
----
-25
-35
-89

query I rowsort
SELECT ALL - col1 * - col2 + - col1 + col1 FROM tab0 AS cor0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-6960
SELECT ALL + 52 DIV + col2 + + col2 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-6960
SELECT ALL + 52 / + col2 + + col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + - 32 * - col2 FROM tab0 AS cor0
----
1056
2624
32

query I rowsort
SELECT DISTINCT - col2 * cor0.col2 + col1 FROM tab1 cor0
----
-2890
-3239
-9203

query I rowsort
SELECT + + 96 FROM tab0 AS cor0
----
96
96
96

query I rowsort
SELECT ALL 71 + + col2 FROM tab0
----
104
153
72

query I rowsort
SELECT ALL cor0.col2 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2, tab2 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT 41 + - 55 AS col2 FROM tab0 AS cor0
----
-14
-14
-14

query I rowsort
SELECT ALL - 61 * ( + col2 ) AS col1 FROM tab0 AS cor0
----
-2013
-5002
-61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6968
SELECT - CAST( NULL AS SIGNED ) + col0 * - col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-6968
SELECT - CAST ( NULL AS INTEGER ) + col0 * - col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + cor1.col2 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

query I rowsort
SELECT DISTINCT - 23 FROM tab0, tab2 AS cor0
----
-23

query I rowsort
SELECT cor0.col0 * - col2 + + col2 FROM tab0 AS cor0
----
-34
-7216
-759

query I rowsort
SELECT ALL col0 * tab1.col2 + - 32 * col2 FROM tab1
----
-1566
1824
4608

query I rowsort
SELECT DISTINCT + 67 AS col2 FROM tab2, tab0 AS cor0
----
67

query I rowsort
SELECT - - ( 39 ) * + col1 AS col2 FROM tab2 cor0
----
1209
2301
663

query I rowsort
SELECT ALL + col2 + col2 * col0 AS col2 FROM tab0 cor0
----
36
7380
825

query I rowsort
SELECT DISTINCT - - col2 * 66 - col1 * col1 FROM tab0 AS cor0
----
-2869
-5218
-9343

query I rowsort
SELECT ALL + + 76 - cor0.col1 * + cor0.col1 AS col2 FROM tab1 cor0
----
-24
-600
-93

query I rowsort
SELECT ALL - - ( cor0.col1 ) * col1 + col0 + - col2 FROM tab2 AS cor0
----
330
3533
941

onlyif mysql # use DIV operator for integer division
query I rowsort label-6979
SELECT ALL - col2 DIV 97 AS col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-6979
SELECT ALL - col2 / 97 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT DISTINCT - col1 + - 99 FROM tab0 AS cor0
----
-185
-190
-196

query I rowsort
SELECT + cor0.col1 * + 45 FROM tab1 cor0
----
1170
450
585

query I rowsort
SELECT ALL + cor0.col2 + col0 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT 25 * + cor0.col2 FROM tab1, tab0 cor0
----
9 values hashing to f842e80ab8716fc80545d5c751b92dd1

query I rowsort
SELECT 23 * + 31 AS col0 FROM tab0 AS cor0
----
713
713
713

query I rowsort
SELECT col2 * - col1 + - ( + col1 ) AS col2 FROM tab0
----
-194
-2924
-7553

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-6986
SELECT ALL - - ( col2 ) + - CAST( col1 + + cor0.col0 AS SIGNED ) * col2 AS col0 FROM tab1 AS cor0
----
-1512
-4161
-8832

skipif mysql # not compatible
query I rowsort label-6986
SELECT ALL - - ( col2 ) + - CAST ( col1 + + cor0.col0 AS INTEGER ) * col2 AS col0 FROM tab1 AS cor0
----
-1512
-4161
-8832

query I rowsort
SELECT ALL - col1 + col1 * - col2 FROM tab0 cor0
----
-194
-2924
-7553

query I rowsort
SELECT DISTINCT col1 * col0 - + col2 FROM tab0 AS cor0
----
2031
3394
8017

onlyif mysql # use DIV operator for integer division
query I rowsort label-6989
SELECT cor0.col1 DIV + cor0.col2 + - 52 AS col1 FROM tab0 AS cor0
----
-50
-51
45

skipif mysql # not compatible
query I rowsort label-6989
SELECT cor0.col1 / + cor0.col2 + - 52 AS col1 FROM tab0 AS cor0
----
-50
-51
45

query I rowsort
SELECT ALL + + 21 + - col0 FROM tab0 cor0
----
-14
-3
-68

query I rowsort
SELECT cor0.col2 * + ( cor0.col0 ) FROM tab0, tab0 AS cor0
----
9 values hashing to e1120e7b687b32270ef70393236e7341

query I rowsort
SELECT ALL ( col0 ) * col1 + - 59 * + col0 FROM tab0 cor0
----
1330
2848
648

query I rowsort
SELECT ALL 83 FROM tab0, tab2 AS cor0
----
9 values hashing to 18f405c31a0fb47ce3cc9f7effa8855c

query I rowsort
SELECT ALL 80 AS col1 FROM tab2, tab0 AS cor0
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

onlyif mysql # use DIV operator for integer division
query I rowsort label-6995
SELECT col2 * col2 + + col2 DIV col0 AS col1 FROM tab2
----
1444
676
732

skipif mysql # not compatible
query I rowsort label-6995
SELECT col2 * col2 + + col2 / col0 AS col1 FROM tab2
----
1444
676
732

query I rowsort
SELECT DISTINCT - 84 + col1 FROM tab1 AS cor0
----
-58
-71
-74

query I rowsort
SELECT ALL 39 FROM tab2, tab1, tab0 AS cor0
----
27 values hashing to ed2ebd9def3e2c38aa46cb3af60fe229

onlyif mysql # use DIV operator for integer division
query I rowsort label-6998
SELECT ALL 57 * col0 DIV + col2 AS col1 FROM tab1
----
3
47
64

skipif mysql # not compatible
query I rowsort label-6998
SELECT ALL 57 * col0 / + col2 AS col1 FROM tab1
----
3
47
64

query I rowsort
SELECT - + 4 FROM tab2 cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 5784540a5af6ca2be84399d314acd2fd

query I rowsort
SELECT + col0 + 21 FROM tab2 AS cor0
----
100
28
99

query I rowsort
SELECT DISTINCT + 93 AS col0 FROM tab0
----
93

query I rowsort
SELECT - 76 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to d90b4aa5f03b4a149aa925c4a88acca0

query I rowsort
SELECT DISTINCT + cor1.col2 * cor1.col0 AS col1 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
162
3648
7680

query I rowsort
SELECT + col2 + + 48 FROM tab1
----
102
105
144

query I rowsort
SELECT + 70 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 9758da65ae4711e3e8c8def2fe026911

query I rowsort
SELECT DISTINCT + col1 * - ( - col2 ) FROM tab2
----
1534
646
837

query I rowsort
SELECT - col0 * 3 * + col0 AS col2 FROM tab2
----
-147
-18252
-18723

query I rowsort
SELECT + 78 + col1 + - col0 FROM tab2
----
102
16
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-7009
SELECT - col0 * col0 DIV + tab1.col2 FROM tab1
----
-66
-71
0

skipif mysql # not compatible
query I rowsort label-7009
SELECT - col0 * col0 / + tab1.col2 FROM tab1
----
-66
-71
0

query I rowsort
SELECT 15 * - 87 FROM tab0
----
-1305
-1305
-1305

query I rowsort
SELECT - tab2.col1 + col0 AS col0 FROM tab2
----
-24
19
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7012
SELECT CAST( col0 AS SIGNED ) * col2 FROM tab0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-7012
SELECT CAST ( col0 AS INTEGER ) * col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT + 15 * - col0 AS col0 FROM tab2
----
-105
-1170
-1185

query I rowsort
SELECT DISTINCT 7 + + col2 FROM tab1
----
103
61
64

query I rowsort
SELECT DISTINCT - 44 + + col0 * col0 AS col1 FROM tab1
----
-35
4052
6356

onlyif mysql # use DIV operator for integer division
query I rowsort label-7016
SELECT DISTINCT - - 75 DIV col1 FROM tab2 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-7016
SELECT DISTINCT - - 75 / col1 FROM tab2 AS cor0
----
1
2
4

query I rowsort
SELECT ( col2 ) * - tab2.col0 AS col1 FROM tab2
----
-189
-2028
-3002

query I rowsort
SELECT - 69 * col0 + - col1 + 49 AS col1 FROM tab1 AS cor0
----
-184
-4377
-5484

query I rowsort
SELECT - col2 * + col0 + 81 + + col2 FROM tab0 AS cor0
----
-678
-7135
47

query I rowsort
SELECT col1 + col2 * + cor0.col1 + - col2 AS col2 FROM tab1 AS cor0
----
1165
1376
523

query I rowsort
SELECT + ( col1 ) * cor0.col0 + col0 AS col1 FROM tab2 cor0
----
1422
224
4680

query I rowsort
SELECT + + cor0.col2 * - col1 * - 93 - 27 FROM tab0 AS cor0
----
263907
693939
8994

query I rowsort
SELECT ALL - - col0 + col2 * - col0 AS col1 FROM tab2 AS cor0
----
-182
-1950
-2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * + col1 - col2 * col2 * + col2 col2 FROM tab0 cor0
----
-28541
-543087
9408

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0, tab1 cor1, tab0, tab2 AS cor2
----
3645 values hashing to d2c0c94b38e721d8cf9f7df226475a2f

query I rowsort
SELECT ALL 18 * + col0 FROM tab2 AS cor0
----
126
1404
1422

query I rowsort
SELECT col2 - + tab0.col1 AS col0 FROM tab0
----
-53
-9
-96

query I rowsort
SELECT ( col2 ) - + col1 * ( + 81 + - col0 ) AS col1 FROM tab1
----
-113
-1974
83

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab1 cor0 CROSS JOIN tab2, tab2 AS cor1
----
972 values hashing to f9adf26f20dc8fcc43c2de18a5fd4859

query I rowsort
SELECT col2 + + col2 * 22 FROM tab2 AS cor0
----
598
621
874

query I rowsort
SELECT ALL + col2 * col1 + ( - col0 ) * col2 FROM tab1 AS cor0
----
-3078
-6432
1242

onlyif mysql # use DIV operator for integer division
query I rowsort label-7032
SELECT DISTINCT - col2 DIV col0 FROM tab0 cor0
----
-1
0

skipif mysql # not compatible
query I rowsort label-7032
SELECT DISTINCT - col2 / col0 FROM tab0 cor0
----
-1
0

query I rowsort
SELECT - col0 * cor0.col0 - col0 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT DISTINCT + 87 * col0 FROM tab1 AS cor0
----
261
5568
6960

query I rowsort
SELECT - - 37 - col0 AS col0 FROM tab2 AS cor0
----
-41
-42
30

query I rowsort
SELECT col2 + + 34 AS col1 FROM tab1
----
130
88
91

query I rowsort
SELECT tab1.col1 - col0 * - 25 * - tab1.col2 FROM tab1
----
-191987
-4024
-91190

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7038
SELECT col1 * CAST( 86 AS SIGNED ) FROM tab1 AS cor0
----
1118
2236
860

skipif mysql # not compatible
query I rowsort label-7038
SELECT col1 * CAST ( 86 AS INTEGER ) FROM tab1 AS cor0
----
1118
2236
860

query I rowsort
SELECT DISTINCT - col0 + - col1 + + 33 * col0 AS col0 FROM tab2
----
193
2437
2511

query I rowsort
SELECT DISTINCT col0 + + col1 * + tab2.col1 AS col2 FROM tab2
----
3559
368
968

query I rowsort
SELECT - 92 * + 50 FROM tab0 AS cor0
----
-4600
-4600
-4600

onlyif mysql # use DIV operator for integer division
query I rowsort label-7042
SELECT ALL 8 DIV col2 FROM tab0 AS cor0
----
0
0
8

skipif mysql # not compatible
query I rowsort label-7042
SELECT ALL 8 / col2 FROM tab0 AS cor0
----
0
0
8

query I rowsort
SELECT - col2 * - 3 + col2 * col2 FROM tab0 cor0
----
1188
4
6970

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7044
SELECT + CAST( col2 AS SIGNED ) * + cor0.col2 * + col2 FROM tab1 AS cor0
----
157464
185193
884736

skipif mysql # not compatible
query I rowsort label-7044
SELECT + CAST ( col2 AS INTEGER ) * + cor0.col2 * + col2 FROM tab1 AS cor0
----
157464
185193
884736

query I rowsort
SELECT ALL 53 * - 33 + col0 + - col0 FROM tab2 AS cor0
----
-1749
-1749
-1749

query I rowsort
SELECT DISTINCT + ( - ( + col1 ) ) FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT + 70 + + col2 * - col0 AS col0 FROM tab2 AS cor0
----
-119
-1958
-2932

query I rowsort
SELECT DISTINCT - + 62 * + col1 AS col1 FROM tab0 AS cor0
----
-5332
-5642
-6014

query I rowsort
SELECT ALL + col0 + col1 * + col0 FROM tab1 AS cor0
----
1120
704
81

query I rowsort
SELECT ALL - 59 + + col2 AS col0 FROM tab2 AS cor0
----
-21
-32
-33

query I rowsort
SELECT ALL col0 * - col0 * col1 AS col2 FROM tab2
----
-106097
-1519
-358956

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7052
SELECT DISTINCT + CAST( NULL AS SIGNED ) * 23 FROM tab2 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7052
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * 23 FROM tab2 cor0
----
NULL

query I rowsort
SELECT - - ( - col0 ) * - col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT ALL 31 * + 28 * + col1 AS col2 FROM tab0
----
74648
78988
84196

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7055
SELECT - CAST( + col2 AS SIGNED ) FROM tab0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-7055
SELECT - CAST ( + col2 AS INTEGER ) FROM tab0
----
-1
-33
-82

query I rowsort
SELECT ( + 90 ) FROM tab0
----
90
90
90

query I rowsort
SELECT + 90 + col1 * col2 AS col2 FROM tab0 AS cor0
----
187
2928
7552

query I rowsort
SELECT ALL + col1 + col0 * col1 * col0 AS col1 FROM tab0 cor0
----
118922
49622
720902

query I rowsort
SELECT DISTINCT - - ( ( cor0.col1 ) ) * - col0 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT ALL + - 41 * col1 AS col2 FROM tab1 AS cor0
----
-1066
-410
-533

query I rowsort
SELECT cor0.col2 AS col1 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT ALL + - col2 + + col2 FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 71 * - col0 col1 FROM tab2 AS cor0
----
497
5538
5609

query I rowsort
SELECT ALL + col2 + + cor0.col0 AS col0 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - 21 * - col2 FROM tab1 AS cor0
----
1134
1197
2016

query I rowsort
SELECT ALL 75 * col0 FROM tab0 AS cor0
----
1800
2625
6675

query I rowsort
SELECT 10 * cor0.col0 AS col2 FROM tab0 AS cor0
----
240
350
890

query I rowsort
SELECT - tab1.col0 + + 65 AS col0 FROM tab1
----
-15
1
62

query I rowsort
SELECT ( - 5 ) AS col0 FROM tab0
----
-5
-5
-5

query I rowsort
SELECT ( - col1 + col0 ) AS col2 FROM tab1
----
-23
54
67

query I rowsort
SELECT - 68 * - 49 AS col0 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to b1989e9bfc6879e15a292ed951adea0f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * - col0 col1 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + - col1 + - col0 * col2 FROM tab0 AS cor0
----
-132
-7389
-878

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col2 * - col2 + col2 col1 FROM tab2 cor0
----
-1406
-650
-702

query I rowsort
SELECT - + col1 * ( col1 ) + col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT + col1 * - col0 + col0 FROM tab2 AS cor0
----
-1264
-210
-4524

query I rowsort
SELECT ALL + - col1 - - col0 * col1 FROM tab0 AS cor0
----
1978
3298
8008

query I rowsort
SELECT + col1 * col1 * - cor0.col0 + + col1 * + col0 * cor0.col1 FROM tab2 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7079
SELECT DISTINCT - - cor0.col1 DIV col1 + cor0.col2 * col0 + cor0.col2 AS col2 FROM tab2 AS cor0
----
2055
217
3041

skipif mysql # not compatible
query I rowsort label-7079
SELECT DISTINCT - - cor0.col1 / col1 + cor0.col2 * col0 + cor0.col2 AS col2 FROM tab2 AS cor0
----
2055
217
3041

query I rowsort
SELECT ALL - cor0.col1 + ( col2 ) FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT - col1 + - col0 * col0 * col2 FROM tab2 AS cor0
----
-1354
-158243
-237175

query I rowsort
SELECT ALL + - col2 + + 83 AS col1 FROM tab1 AS cor0
----
-13
26
29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7083
SELECT - col1 * CAST( - col0 AS SIGNED ) + - cor0.col0 AS col2 FROM tab0 AS cor0
----
2040
3360
8010

skipif mysql # not compatible
query I rowsort label-7083
SELECT - col1 * CAST ( - col0 AS INTEGER ) + - cor0.col0 AS col2 FROM tab0 AS cor0
----
2040
3360
8010

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7084
SELECT DISTINCT + + col2 * - CAST( - 84 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
4536
4788
8064

skipif mysql # not compatible
query I rowsort label-7084
SELECT DISTINCT + + col2 * - CAST ( - 84 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
4536
4788
8064

query I rowsort
SELECT ALL + tab2.col1 - col2 AS col2 FROM tab2
----
-21
33
4

query I rowsort
SELECT col0 - + col0 * - col1 AS col1 FROM tab0
----
2088
3430
8188

query I rowsort
SELECT ALL + cor0.col0 * - col1 - ( + cor0.col2 + + col2 ) FROM tab0 AS cor0
----
-2130
-3397
-8263

query I rowsort
SELECT DISTINCT - cor0.col2 * cor0.col1 AS col2 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT ALL - col1 + - ( + col2 ) AS col1 FROM tab1 AS cor0
----
-109
-67
-80

query I rowsort
SELECT + - cor0.col2 * - col1 * col0 AS col2 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT - + col2 - ( - 61 ) FROM tab2 AS cor0
----
23
34
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-7092
SELECT DISTINCT cor0.col2 DIV - cor0.col1 - cor0.col2 FROM tab0 AS cor0
----
-1
-33
-82

skipif mysql # not compatible
query I rowsort label-7092
SELECT DISTINCT cor0.col2 / - cor0.col1 - cor0.col2 FROM tab0 AS cor0
----
-1
-33
-82

query I rowsort
SELECT ALL 13 * 50 * col2 FROM tab2 cor0
----
16900
17550
24700

query I rowsort
SELECT 3 * col1 + col1 + 79 * - ( cor0.col2 ) AS col2 FROM tab2 AS cor0
----
-1818
-2009
-2934

query I rowsort
SELECT - - ( - col1 ) * col1 AS col2 FROM tab0 cor0
----
-7396
-8281
-9409

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col2 col1 FROM tab1, tab0 cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT col0 * 36 FROM tab1 AS cor0
----
108
2304
2880

query I rowsort
SELECT DISTINCT - cor0.col2 * - col2 + col1 FROM tab2 AS cor0
----
1461
735
760

query I rowsort
SELECT ALL col1 * + col2 * - col0 FROM tab2 cor0
----
-119652
-51034
-5859

query I rowsort
SELECT - - cor0.col1 * - ( - col0 ) FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT + tab2.col1 - + 67 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to ac8c7aa413170045e0e846956b55212b

query I rowsort
SELECT - 11 + col1 FROM tab1 AS cor0
----
-1
15
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-7103
SELECT ALL - 2 DIV + col0 AS col2 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7103
SELECT ALL - 2 / + col0 AS col2 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - col2 * + col0 * col1 FROM tab0 cor0
----
-3395
-664118
-68112

query I rowsort
SELECT DISTINCT cor0.col1 - 35 FROM tab2 AS cor0
----
-18
-4
24

query I rowsort
SELECT ALL cor0.col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT - col2 + ( + col0 ) * col0 AS col1 FROM tab0 AS cor0
----
1224
543
7839

query I rowsort
SELECT + col2 * 97 FROM tab2 cor0
----
2522
2619
3686

query I rowsort
SELECT + 52 FROM tab0, tab2 AS cor0
----
9 values hashing to 7f4ae30893ab330784829711032ae599

query I rowsort
SELECT ALL + 84 + col2 AS col0 FROM tab1 AS cor0
----
138
141
180

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7111
SELECT DISTINCT + CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7111
SELECT DISTINCT + CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT col0 + + col1 + cor0.col2 FROM tab2 AS cor0
----
134
163
65

query I rowsort
SELECT - + 37 - col0 AS col0 FROM tab1 AS cor0
----
-101
-117
-40

query I rowsort
SELECT - + col1 + 72 FROM tab0 AS cor0
----
-14
-19
-25

query I rowsort
SELECT + 19 * + col1 + + col0 - + col1 FROM tab0 cor0
----
1572
1727
1781

query I rowsort
SELECT DISTINCT - col1 + + ( col0 ) * col2 FROM tab1 AS cor0
----
136
3638
7667

onlyif mysql # use DIV operator for integer division
query I rowsort label-7117
SELECT ALL - 28 DIV col2 AS col0 FROM tab0 AS cor0
----
-28
0
0

skipif mysql # not compatible
query I rowsort label-7117
SELECT ALL - 28 / col2 AS col0 FROM tab0 AS cor0
----
-28
0
0

query I rowsort
SELECT DISTINCT + 81 * col2 + - col1 + - col1 AS col0 FROM tab2 cor0
----
1988
2125
3044

query I rowsort
SELECT ( ( - col1 ) ) * - 16 FROM tab2 AS cor0
----
272
496
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-7120
SELECT DISTINCT 29 + col1 + + col0 DIV - 63 FROM tab0 AS cor0
----
115
119
126

skipif mysql # not compatible
query I rowsort label-7120
SELECT DISTINCT 29 + col1 + + col0 / - 63 FROM tab0 AS cor0
----
115
119
126

query I rowsort
SELECT DISTINCT + + col0 * + 9 FROM tab1 AS cor0
----
27
576
720

query I rowsort
SELECT ALL 95 * col1 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
1577
2918
5579

query I rowsort
SELECT - - 81 + col0 FROM tab0 AS cor0
----
105
116
170

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + cor0.col1 col1 FROM tab0 cor0
----
2
62
62

query I rowsort
SELECT + 15 * + cor0.col1 + col2 FROM tab1 AS cor0
----
207
291
444

query I rowsort
SELECT ALL - - col0 + col0 * col1 * col1 FROM tab1 AS cor0
----
13600
2031
6464

query I rowsort
SELECT + 24 * - tab1.col1 AS col0 FROM tab1
----
-240
-312
-624

query I rowsort
SELECT - 81 + col2 * 75 + cor0.col2 FROM tab0 AS cor0
----
-5
2427
6151

query I rowsort
SELECT col2 + + col1 * col0 * col0 FROM tab1 AS cor0
----
288
41017
83296

query I rowsort
SELECT - tab1.col1 FROM tab1, tab0 cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

onlyif mysql # use DIV operator for integer division
query I rowsort label-7131
SELECT - col1 DIV + col0 + - tab0.col1 FROM tab0
----
-89
-92
-99

skipif mysql # not compatible
query I rowsort label-7131
SELECT - col1 / + col0 + - tab0.col1 FROM tab0
----
-89
-92
-99

query I rowsort
SELECT - col1 + col0 * ( - col1 ) * cor0.col0 AS col0 FROM tab2 AS cor0
----
-106114
-1550
-359015

query I rowsort
SELECT DISTINCT + col2 * - cor0.col1 + + cor0.col2 * + 1 AS col0 FROM tab2 AS cor0
----
-1508
-608
-810

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * cor0.col0 + - col1 - + 5 col0 FROM tab0 cor0
----
-137
-7394
-883

query I rowsort
SELECT col1 * - col2 + cor0.col0 FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-7136
SELECT + cor0.col2 * ( - cor0.col0 ) + col1 DIV - col0 FROM tab2 AS cor0
----
-193
-2028
-3002

skipif mysql # not compatible
query I rowsort label-7136
SELECT + cor0.col2 * ( - cor0.col0 ) + col1 / - col0 FROM tab2 AS cor0
----
-193
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-7137
SELECT - - cor0.col0 DIV ( + col0 + col2 ) FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7137
SELECT - - cor0.col0 / ( + col0 + col2 ) FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7138
SELECT DISTINCT + - 5 DIV - 72 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
0

skipif mysql # not compatible
query I rowsort label-7138
SELECT DISTINCT + - 5 / - 72 AS col2 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + ( col0 ) col2 FROM tab1 cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT 71 AS col1 FROM tab2 cor0 CROSS JOIN tab0, tab2 AS cor1, tab1 cor2, tab0 AS cor3
----
71

query I rowsort
SELECT col2 * + 51 AS col2 FROM tab2
----
1326
1377
1938

query I rowsort
SELECT col0 + col0 - col1 * ( col1 ) * col2 AS col2 FROM tab2 AS cor0
----
-10824
-25933
-90350

query I rowsort
SELECT 17 * 63 AS col1 FROM tab0
----
1071
1071
1071

query I rowsort
SELECT DISTINCT col1 - + cor0.col1 * ( col2 ) FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT DISTINCT col2 * col2 - 93 * - col2 AS col2 FROM tab1 AS cor0
----
18144
7938
8550

query I rowsort
SELECT DISTINCT - + cor0.col0 * + col0 - - col1 * col2 FROM tab2 AS cor0
----
-4550
-5595
788

query I rowsort
SELECT ALL - cor0.col1 + 21 * ( col2 ) FROM tab1 AS cor0
----
1108
1187
2003

query I rowsort
SELECT - 73 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 84ab9db5468b4a1781bd8d5c8e0e77fc

query I rowsort
SELECT ALL col2 * ( cor0.col0 ) FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL + 43 * - 43 FROM tab1, tab1 AS cor0
----
9 values hashing to dfb2364f980e17c4ec4804008014964c

query I rowsort
SELECT ALL + cor0.col2 * + 73 AS col0 FROM tab0 AS cor0
----
2409
5986
73

onlyif mysql # use DIV operator for integer division
query I rowsort label-7152
SELECT DISTINCT - ( - col0 ) + + col1 * col2 DIV ( - col1 + 74 ) FROM tab2 AS cor0
----
180
26
90

skipif mysql # not compatible
query I rowsort label-7152
SELECT DISTINCT - ( - col0 ) + + col1 * col2 / ( - col1 + 74 ) FROM tab2 AS cor0
----
180
26
90

query I rowsort
SELECT ALL cor0.col1 * 73 FROM tab2 cor0
----
1241
2263
4307

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 48 col2 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 0ef571a8722ab7270aa7272c1174b88e

query I rowsort
SELECT col0 + - 27 AS col1 FROM tab1 AS cor0
----
-24
37
53

query I rowsort
SELECT + col1 * + 5 FROM tab1 cor0
----
130
50
65

query I rowsort
SELECT cor1.col2 AS col0 FROM tab2, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to 7f4a9bf24d64833706dfbdd0baf49d79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 47 col1 FROM tab2
----
-47
-47
-47

query I rowsort
SELECT + + 55 FROM tab1 cor0
----
55
55
55

query I rowsort
SELECT ALL + col2 * col1 - + 58 * col0 * + col1 FROM tab2 AS cor0
----
-11749
-265382
-77248

query I rowsort
SELECT DISTINCT + + 97 AS col1 FROM tab1 AS cor0
----
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7162
SELECT ALL ( col2 ) * + CAST( NULL AS DECIMAL ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7162
SELECT ALL ( col2 ) * + CAST ( NULL AS REAL ) col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + 62 * - tab0.col0 + - col1 AS col1 FROM tab0
----
-1574
-2267
-5609

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + col2 col2 FROM tab1
----
-7
16
51

query I rowsort
SELECT ALL col0 + + ( + col0 ) FROM tab1
----
128
160
6

query I rowsort
SELECT ALL - 80 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 4dde3bd5652d30396b9cadd0e2cfb680

query I rowsort
SELECT - ( col1 ) * col0 + - col1 - - 36 * - col0 FROM tab0
----
-11394
-3014
-4752

query I rowsort
SELECT DISTINCT - 14 FROM tab2, tab0, tab2 cor0
----
-14

query I rowsort
SELECT - + 93 * - 60 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 91a4466a5edbb9017ca2eea094ca766f

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - ( col1 ) * col0 * + cor0.col2 - col0 * col2 col0 FROM tab1 AS cor0
----
32832
4050
92160

query I rowsort
SELECT ALL col0 * col0 + + 0 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT DISTINCT 26 + col1 * + 4 * - col0 AS col1 FROM tab2 AS cor0
----
-18382
-5346
-842

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7173
SELECT DISTINCT - col0 * col2 + - CAST( NULL AS SIGNED ) AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7173
SELECT DISTINCT - col0 * col2 + - CAST ( NULL AS INTEGER ) AS col2 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT ALL + - 7 + + col1 - + cor0.col0 FROM tab2 AS cor0
----
-26
-69
17

query I rowsort
SELECT ALL 36 * col2 FROM tab1 AS cor0
----
1944
2052
3456

query I rowsort
SELECT DISTINCT - - 35 * + col0 + col2 FROM tab1 AS cor0
----
159
2297
2896

query I rowsort
SELECT ( col0 ) + + ( - col0 ) AS col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + 81 + + col2 * + ( col1 ) + col1 FROM tab0
----
275
3005
7634

query I rowsort
SELECT col0 * - tab1.col0 AS col2 FROM tab1
----
-4096
-6400
-9

query I rowsort
SELECT DISTINCT 75 AS col2 FROM tab0, tab0 AS cor0, tab0 AS cor1
----
75

query I rowsort
SELECT DISTINCT - col2 * - col2 + col0 FROM tab1
----
2919
3313
9296

query I rowsort
SELECT col1 * col2 + col1 AS col0 FROM tab0
----
194
2924
7553

query I rowsort
SELECT ALL + ( - col1 * tab1.col2 ) + + 96 * tab1.col1 * ( col1 ) AS col2 FROM tab1
----
14976
63492
9030

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 14 col0 FROM tab2, tab1 AS cor0, tab2 AS cor1
----
14

query I rowsort
SELECT ALL - ( col1 ) + 64 FROM tab0 cor0
----
-22
-27
-33

query I rowsort
SELECT DISTINCT 56 FROM tab1, tab2 AS cor0, tab1 AS cor1
----
56

onlyif mysql # use DIV operator for integer division
query I rowsort label-7187
SELECT ALL col2 DIV col0 AS col0 FROM tab2
----
0
0
3

skipif mysql # not compatible
query I rowsort label-7187
SELECT ALL col2 / col0 AS col0 FROM tab2
----
0
0
3

query I rowsort
SELECT DISTINCT - col2 + ( col0 ) * col0 AS col0 FROM tab0 cor0
----
1224
543
7839

query I rowsort
SELECT DISTINCT cor0.col0 * - ( - col0 ) * cor0.col1 AS col2 FROM tab1 AS cor0
----
234
40960
83200

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * - col0 col2 FROM tab1 cor0
----
1040
640
78

query I rowsort
SELECT + cor0.col2 + - cor0.col0 * col1 FROM tab1 cor0
----
-24
-583
-944

query I rowsort
SELECT cor0.col0 * - col1 + - col2 * + cor0.col1 FROM tab1 cor0
----
-1210
-1482
-2288

query I rowsort
SELECT ALL col0 * - col1 AS col0 FROM tab2 cor0
----
-1343
-217
-4602

query I rowsort
SELECT - + col1 * - ( col2 ) AS col0 FROM tab0 cor0
----
2838
7462
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + col1 * ( + col1 ) col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT + col1 + 48 * col2 * col1 AS col2 FROM tab2 AS cor0
----
31025
40207
73691

onlyif mysql # use DIV operator for integer division
query I rowsort label-7197
SELECT ALL + - col1 DIV - col0 AS col1 FROM tab0 AS cor0
----
1
2
3

skipif mysql # not compatible
query I rowsort label-7197
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-7198
SELECT DISTINCT - + col2 * + CAST( NULL AS SIGNED ) + + 11 * col2 AS col2 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7198
SELECT DISTINCT - + col2 * + CAST ( NULL AS INTEGER ) + + 11 * col2 AS col2 FROM tab1 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 - 98 col1 FROM tab0 AS cor0
----
-63
-74
-9

query I rowsort
SELECT ALL + col2 + + col2 + col0 AS col0 FROM tab2 cor0
----
130
155
61

query I rowsort
SELECT DISTINCT col0 * + col1 + col2 + - ( - tab1.col1 + col0 ) * - 1 * tab1.col2 AS col2 FROM tab1
----
-1110
3775
7568

query I rowsort
SELECT ALL + cor0.col1 + col1 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7203
SELECT DISTINCT - + CAST( NULL AS SIGNED ) * + 2 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7203
SELECT DISTINCT - + CAST ( NULL AS INTEGER ) * + 2 AS col1 FROM tab0 AS cor0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col1 + ( + col1 ) col0 FROM tab1 AS cor0
----
20
26
52

onlyif mysql # use DIV operator for integer division
query I rowsort label-7205
SELECT cor0.col0 DIV - 9 FROM tab2 AS cor0
----
-8
-8
0

skipif mysql # not compatible
query I rowsort label-7205
SELECT cor0.col0 / - 9 FROM tab2 AS cor0
----
-8
-8
0

query I rowsort
SELECT DISTINCT - 41 * col2 - - col1 AS col1 FROM tab2 AS cor0
----
-1007
-1076
-1541

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col2 ) * + col0 + + 92 + 4 * - col0 col1 FROM tab1 AS cor0
----
242
3484
7452

query I rowsort
SELECT + - 12 AS col1 FROM tab2 cor0
----
-12
-12
-12

query I rowsort
SELECT ALL 66 * col2 * - col0 AS col0 FROM tab0 AS cor0
----
-2310
-481668
-52272

query I rowsort
SELECT ( + cor0.col1 ) AS col0 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT + 49 + col0 * + col2 * + col2 AS col0 FROM tab1 AS cor0
----
207985
737329
8797

query I rowsort
SELECT tab0.col1 + col2 + - col2 * tab0.col2 AS col0 FROM tab0
----
-6551
-970
97

query I rowsort
SELECT - 15 + + col2 FROM tab1 AS cor0
----
39
42
81

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7214
SELECT - CAST( + col2 AS SIGNED ) * col0 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif mysql # not compatible
query I rowsort label-7214
SELECT - CAST ( + col2 AS INTEGER ) * col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT col0 + + 41 FROM tab2 AS cor0
----
119
120
48

query I rowsort
SELECT col2 * + 40 + 97 AS col2 FROM tab1
----
2257
2377
3937

query I rowsort
SELECT col2 * + col2 * - col1 FROM tab1
----
-119808
-32490
-75816

query I rowsort
SELECT ALL 64 FROM tab1, tab1 cor0, tab1 cor1
----
27 values hashing to c8b19f4c3ff38700cd2bb8a077bf29b9

query I rowsort
SELECT DISTINCT - col2 + + 8 AS col1 FROM tab0
----
-25
-74
7

query I rowsort
SELECT ALL col1 * - 18 + col1 * col2 FROM tab2
----
279
340
472

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + + ( col0 + + tab1.col2 ) * col2 col1 FROM tab1
----
16909
3104
6907

query I rowsort
SELECT - 96 AS col2 FROM tab1
----
-96
-96
-96

query I rowsort
SELECT tab1.col2 * tab1.col2 * col1 FROM tab1
----
119808
32490
75816

query I rowsort
SELECT - 60 AS col0 FROM tab2 AS cor0
----
-60
-60
-60

query I rowsort
SELECT 62 + col1 AS col0 FROM tab2 AS cor0
----
121
79
93

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7226
SELECT DISTINCT - CAST( col0 AS SIGNED ) * col2 FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-7226
SELECT DISTINCT - CAST ( col0 AS INTEGER ) * col2 FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT DISTINCT - col0 * - col1 + col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT col1 + + col0 + - col1 FROM tab1
----
3
64
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col2 col1 FROM tab0, tab1 AS cor0
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT + - col1 * 84 FROM tab1 cor0
----
-1092
-2184
-840

query I rowsort
SELECT + 64 * - tab2.col1 FROM tab2
----
-1088
-1984
-3776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 4 + - col0 col1 FROM tab1 AS cor0
----
-60
-76
1

query I rowsort
SELECT + col0 - 86 FROM tab2 AS cor0
----
-7
-79
-8

query I rowsort
SELECT DISTINCT cor0.col1 * 32 AS col2 FROM tab2 AS cor0
----
1888
544
992

query I rowsort
SELECT - - col2 * 9 AS col0 FROM tab0 AS cor0
----
297
738
9

query I rowsort
SELECT DISTINCT col1 + 53 * 65 - + col1 AS col0 FROM tab2
----
3445

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + cor0.col0 + col2 + ( 34 + col0 ) col2 FROM tab1 AS cor0
----
-485
-830
13

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 * + 4 col0 FROM tab0 cor0
----
140
356
96

query I rowsort
SELECT ALL + - col2 * - col2 AS col1 FROM tab1 AS cor0
----
2916
3249
9216

query I rowsort
SELECT DISTINCT - 89 + + col1 * + col0 AS col1 FROM tab0 AS cor0
----
1975
3306
8010

query I rowsort
SELECT DISTINCT ( - ( - cor0.col1 ) ) FROM tab1, tab2 AS cor0, tab2 AS cor1
----
17
31
59

query I rowsort
SELECT ( col1 ) + + col2 * + cor0.col1 AS col0 FROM tab0 cor0
----
194
2924
7553

query I rowsort
SELECT DISTINCT + 2 AS col0 FROM tab1
----
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7244
SELECT + - col2 * - CAST( col2 AS SIGNED ) * - col1 FROM tab2 AS cor0
----
-22599
-24548
-39884

skipif mysql # not compatible
query I rowsort label-7244
SELECT + - col2 * - CAST ( col2 AS INTEGER ) * - col1 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT DISTINCT cor0.col0 * 56 FROM tab2, tab2 AS cor0
----
392
4368
4424

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + 61 * + col1 col1 FROM tab2 cor0
----
1037
1891
3599

query I rowsort
SELECT DISTINCT 7 + col1 AS col0 FROM tab0
----
104
93
98

query I rowsort
SELECT - + 15 * cor0.col0 AS col2 FROM tab2, tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
27 values hashing to e0f79b8dc833ffb0ad2085d087bb2642

skipif mysql # not compatible
query I rowsort
SELECT ALL - CAST ( col2 AS REAL ) * + col2 + + col1 * + tab1.col1 AS col0 FROM tab1
----
-2240
-3149
-9047

query I rowsort
SELECT + col2 * + 99 + - col0 AS col0 FROM tab1 cor0
----
5343
5579
9424

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7251
SELECT + + CAST( + col2 AS SIGNED ) + cor0.col2 AS col1 FROM tab1 AS cor0
----
108
114
192

skipif mysql # not compatible
query I rowsort label-7251
SELECT + + CAST ( + col2 AS INTEGER ) + cor0.col2 AS col1 FROM tab1 AS cor0
----
108
114
192

query I rowsort
SELECT ALL + col0 + + 93 FROM tab1 AS cor0
----
157
173
96

query I rowsort
SELECT ALL + - 73 AS col2 FROM tab0 AS cor0
----
-73
-73
-73

query I rowsort
SELECT - col1 + - col0 * col2 AS col0 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT + col2 * - 37 + + col2 FROM tab0 AS cor0
----
-1188
-2952
-36

query I rowsort
SELECT ALL - + col2 * - cor0.col1 AS col1 FROM tab0 AS cor0
----
2838
7462
97

query I rowsort
SELECT DISTINCT col1 * col1 + + col0 FROM tab1 AS cor0
----
164
249
679

query I rowsort
SELECT col2 + col2 * - col1 * + col2 AS col2 FROM tab0 cor0
----
-611802
-93621
-96

query I rowsort
SELECT ALL + ( col2 ) + cor0.col1 FROM tab1 AS cor0
----
109
67
80

query I rowsort
SELECT ALL + 9 + col0 FROM tab1 AS cor0
----
12
73
89

query I rowsort
SELECT DISTINCT + + col0 + - col2 FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT ( col2 ) * + col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7263
SELECT col0 * col1 + CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7263
SELECT col0 * col1 + CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 98 + col2 AS col0 FROM tab2 AS cor0
----
124
125
136

query I rowsort
SELECT DISTINCT 83 + + 68 + col0 * + col1 AS col0 FROM tab0
----
2215
3546
8250

query I rowsort
SELECT col0 + 58 * 57 FROM tab0 AS cor0
----
3330
3341
3395

query I rowsort
SELECT DISTINCT + col1 * - col2 + col0 AS col0 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT - col2 + + 73 FROM tab0 AS cor0
----
-9
40
72

query I rowsort
SELECT ALL - col1 + + 86 * + 74 AS col2 FROM tab0 AS cor0
----
6267
6273
6278

query I rowsort
SELECT ALL + cor1.col1 FROM tab1, tab1 AS cor0, tab1 AS cor1
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT + 72 AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to 906b63c9adb7d9ac7355cab71a25fc49

query I rowsort
SELECT ALL + col0 * col0 + - col1 FROM tab0 AS cor0
----
1128
490
7830

query I rowsort
SELECT ALL - col2 + col2 * col2 * col1 FROM tab0 AS cor0
----
611802
93621
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 86 + + 98 col0 FROM tab1 AS cor0
----
184
184
184

query I rowsort
SELECT DISTINCT + 83 * col2 AS col1 FROM tab1 AS cor0
----
4482
4731
7968

query I rowsort
SELECT + ( + col1 ) AS col1 FROM tab0 cor0
----
86
91
97

query I rowsort
SELECT + - col1 * col1 + + col1 FROM tab0 AS cor0
----
-7310
-8190
-9312

query I rowsort
SELECT DISTINCT + + 71 * 76 AS col2 FROM tab0 AS cor0
----
5396

query I rowsort
SELECT - col2 + + 11 + col2 FROM tab2
----
11
11
11

query I rowsort
SELECT ALL col0 * + 17 * + tab0.col0 + + tab0.col1 + 26 AS col2 FROM tab0
----
134774
20948
9904

query I rowsort
SELECT DISTINCT col1 + - tab1.col1 AS col2 FROM tab1
----
0

query I rowsort
SELECT DISTINCT + 41 AS col2 FROM tab0, tab2 AS cor0
----
41

query I rowsort
SELECT - ( - 49 ) FROM tab2 AS cor0
----
49
49
49

query I rowsort
SELECT col0 + - 93 AS col1 FROM tab1 AS cor0
----
-13
-29
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7285
SELECT CAST( NULL AS SIGNED ) - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7285
SELECT CAST ( NULL AS INTEGER ) - col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + col1 + col0 * - col0 * - col2 FROM tab1 AS cor0
----
233482
512
614413

query I rowsort
SELECT ALL + col0 + ( col2 ) FROM tab2
----
104
117
34

query I rowsort
SELECT + + 59 * - cor1.col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to c6562728cbe83d5c41c0d28a8056e09e

query I rowsort
SELECT DISTINCT + ( - col1 ) + - col1 FROM tab1
----
-20
-26
-52

onlyif mysql # use DIV operator for integer division
query I rowsort label-7290
SELECT + ( - col0 ) DIV + col2 col1 FROM tab0
----
-1
-35
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7290
SELECT + ( - col0 ) / + col2 col1 FROM tab0
----
-1
-35
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7291
SELECT DISTINCT + tab1.col1 DIV tab1.col0 AS col1 FROM tab1, tab0, tab0 AS cor0
----
0
8

skipif mysql # not compatible
query I rowsort label-7291
SELECT DISTINCT + tab1.col1 / tab1.col0 AS col1 FROM tab1, tab0, tab0 AS cor0
----
0
8

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7292
SELECT + CAST( NULL AS SIGNED ) + 21 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7292
SELECT + CAST ( NULL AS INTEGER ) + 21 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - ( col1 ) + + tab1.col2 AS col1 FROM tab1
----
28
47
83

query I rowsort
SELECT DISTINCT - + ( + col1 ) AS col2 FROM tab1 AS cor0
----
-10
-13
-26

query I rowsort
SELECT + col2 * - 28 FROM tab2
----
-1064
-728
-756

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * - tab0.col1 col0 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT ALL + 22 * 68 AS col2 FROM tab2
----
1496
1496
1496

query I rowsort
SELECT ( col2 * col1 ) + + 62 AS col1 FROM tab2
----
1596
708
899

query I rowsort
SELECT DISTINCT ( col2 ) * col0 FROM tab0
----
35
7298
792

query I rowsort
SELECT tab0.col0 - col2 AS col1 FROM tab0
----
-9
34
7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7301
SELECT 64 * col2 / + CAST( NULL AS SIGNED ) + col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7301
SELECT 64 * col2 / + CAST ( NULL AS INTEGER ) + col0 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7302
SELECT ALL - 92 DIV - col0 FROM tab1
----
1
1
30

skipif mysql # not compatible
query I rowsort label-7302
SELECT ALL - 92 / - col0 FROM tab1
----
1
1
30

query I rowsort
SELECT ALL col2 + - col1 * + col2 + 0 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT DISTINCT + 98 * - col2 AS col1 FROM tab1
----
-5292
-5586
-9408

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7305
SELECT DISTINCT + col2 + + CAST( NULL AS SIGNED ) * ( - col0 ) FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7305
SELECT DISTINCT + col2 + + CAST ( NULL AS INTEGER ) * ( - col0 ) FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7306
SELECT ALL + col1 - col2 DIV col2 AS col1 FROM tab1 cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-7306
SELECT ALL + col1 - col2 / col2 AS col1 FROM tab1 cor0
----
12
25
9

query I rowsort
SELECT + col0 + 32 + col1 FROM tab2
----
128
169
70

query I rowsort
SELECT - - col2 * - col2 + + cor0.col0 FROM tab1 AS cor0
----
-2913
-3185
-9136

onlyif mysql # use DIV operator for integer division
query I rowsort label-7309
SELECT DISTINCT + cor0.col2 DIV + ( col0 ) col1 FROM tab2 AS cor0
----
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7309
SELECT DISTINCT + cor0.col2 / + ( col0 ) col1 FROM tab2 AS cor0
----
0
3

query I rowsort
SELECT 14 - col1 FROM tab2 AS cor0
----
-17
-3
-45

query I rowsort
SELECT ALL - col1 * + tab1.col1 * - 15 FROM tab1
----
10140
1500
2535

query I rowsort
SELECT - 65 * - col1 FROM tab1
----
1690
650
845

query I rowsort
SELECT - cor0.col0 + - col1 * col0 - col1 * 73 FROM tab2 AS cor0
----
-2487
-2663
-8987

query I rowsort
SELECT - + cor0.col1 + + col0 + + col0 AS col0 FROM tab1 AS cor0
----
-20
118
147

query I rowsort
SELECT - 68 * col0 AS col1 FROM tab0
----
-1632
-2380
-6052

query I rowsort
SELECT DISTINCT 16 * col1 AS col1 FROM tab2
----
272
496
944

onlyif mysql # use DIV operator for integer division
query I rowsort label-7317
SELECT DISTINCT - col1 + cor0.col2 DIV + 13 AS col0 FROM tab1 AS cor0
----
-22
-6

skipif mysql # not compatible
query I rowsort label-7317
SELECT DISTINCT - col1 + cor0.col2 / + 13 AS col0 FROM tab1 AS cor0
----
-22
-6

query I rowsort
SELECT + + 51 FROM tab0 cor0
----
51
51
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-7319
SELECT DISTINCT + 53 DIV + col0 FROM tab2 cor0
----
0
7

skipif mysql # not compatible
query I rowsort label-7319
SELECT DISTINCT + 53 / + col0 FROM tab2 cor0
----
0
7

query I rowsort
SELECT + - ( 59 ) AS col0 FROM tab1 AS cor0
----
-59
-59
-59

query I rowsort
SELECT + - col1 * col2 + col2 AS col2 FROM tab2 AS cor0
----
-1508
-608
-810

query I rowsort
SELECT + 17 + col1 FROM tab0 cor0
----
103
108
114

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7323
SELECT + CAST( NULL AS SIGNED ) * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7323
SELECT + CAST ( NULL AS INTEGER ) * col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 80 * - cor0.col1 AS col2 FROM tab2 AS cor0
----
-1360
-2480
-4720

query IIIIIIIIIIII rowsort
SELECT * FROM tab0, tab1 cor0, tab1 cor1, tab0 AS cor2
----
972 values hashing to b51b4342db121ebc2d3d353dcd8ed521

query I rowsort
SELECT + col1 + ( col0 ) FROM tab1
----
29
74
93

query I rowsort
SELECT ALL + ( + 83 ) + + cor0.col0 AS col0 FROM tab0 AS cor0
----
107
118
172

query I rowsort
SELECT - 25 + + col2 FROM tab2 AS cor0
----
1
13
2

query I rowsort
SELECT DISTINCT - col2 - cor0.col0 * 66 * ( - col2 ) FROM tab2 AS cor0
----
12447
133822
198094

query I rowsort
SELECT DISTINCT + col0 * cor0.col0 * - ( + col2 + col1 ) FROM tab2 cor0
----
-2842
-343255
-517140

query I rowsort
SELECT DISTINCT ( col0 ) + cor0.col0 AS col0 FROM tab2 cor0
----
14
156
158

query I rowsort
SELECT ALL + - ( - col0 ) * - 62 + - col0 FROM tab1 AS cor0
----
-189
-4032
-5040

query I rowsort
SELECT ALL + - col2 * + col0 * - ( - 9 ) FROM tab0 AS cor0
----
-315
-65682
-7128

query I rowsort
SELECT DISTINCT col1 + + cor0.col1 * + 10 + col0 FROM tab0 AS cor0
----
1090
1102
970

query I rowsort
SELECT DISTINCT - col1 * col1 + 31 FROM tab0 AS cor0
----
-7365
-8250
-9378

query I rowsort
SELECT ALL - 83 FROM tab2 AS cor0 CROSS JOIN tab0 cor1
----
9 values hashing to d55748f39f403ec273099c0d87b0bfbb

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col0 * - col1 col1 FROM tab2 AS cor0
----
-22831
-271518
-6727

query I rowsort
SELECT + 38 + - col2 FROM tab0 AS cor0
----
-44
37
5

query I rowsort
SELECT ALL ( + 27 * - cor0.col1 ) FROM tab2, tab2 AS cor0
----
9 values hashing to 0ffd37e68a96c8b6827d9c1d6666ede7

query I rowsort
SELECT + cor0.col0 + cor0.col0 AS col0 FROM tab1 AS cor0
----
128
160
6

query I rowsort
SELECT - - col2 + + col1 AS col1 FROM tab2 AS cor0
----
55
58
85

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7342
SELECT DISTINCT CAST( NULL AS SIGNED ) * - 79 FROM tab1, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7342
SELECT DISTINCT CAST ( NULL AS INTEGER ) * - 79 FROM tab1, tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col2 * CAST ( - col2 AS REAL ) + - col1 / + 84 AS col2 FROM tab0
----
-1090
-2
-6725

query I rowsort
SELECT - 4 * - col1 FROM tab1 AS cor0
----
104
40
52

query I rowsort
SELECT + ( tab0.col0 ) AS col0 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * + cor0.col2 col0 FROM tab0 AS cor0
----
-1
-1089
-6724

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7347
SELECT ALL + CAST( NULL AS SIGNED ) * ( - col1 * + col2 ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7347
SELECT ALL + CAST ( NULL AS INTEGER ) * ( - col1 * + col2 ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 14 + - col0 FROM tab1 AS cor0
----
-50
-66
11

onlyif mysql # use DIV operator for integer division
query I rowsort label-7349
SELECT DISTINCT tab0.col0 * - 77 * tab0.col0 + + col0 - + col2 DIV + col1 FROM tab0
----
-44328
-609828
-94290

skipif mysql # not compatible
query I rowsort label-7349
SELECT DISTINCT tab0.col0 * - 77 * tab0.col0 + + col0 - + col2 / + col1 FROM tab0
----
-44328
-609828
-94290

query I rowsort
SELECT col1 + col0 * col2 - - col0 AS col1 FROM tab2
----
2165
227
3098

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7351
SELECT DISTINCT - col2 * - CAST( col1 AS SIGNED ) - + col2 * + ( col0 ) AS col1 FROM tab0
----
164
2046
62

skipif mysql # not compatible
query I rowsort label-7351
SELECT DISTINCT - col2 * - CAST ( col1 AS INTEGER ) - + col2 * + ( col0 ) AS col1 FROM tab0
----
164
2046
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-7352
SELECT col1 + + col1 * col0 * col1 + col2 DIV + 72 col2 FROM tab2
----
22848
271577
6758

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7352
SELECT col1 + + col1 * col0 * col1 + col2 / + 72 col2 FROM tab2
----
22848
271577
6758

query I rowsort
SELECT - - col0 + + 57 FROM tab0 AS cor0
----
146
81
92

query I rowsort
SELECT - cor0.col2 - 48 FROM tab2 AS cor0
----
-74
-75
-86

onlyif mysql # use DIV operator for integer division
query I rowsort label-7355
SELECT - col2 + cor0.col2 DIV 56 FROM tab1 AS cor0
----
-54
-56
-95

skipif mysql # not compatible
query I rowsort label-7355
SELECT - col2 + cor0.col2 / 56 FROM tab1 AS cor0
----
-54
-56
-95

query I rowsort
SELECT ALL + col2 + - col1 + 77 AS col1 FROM tab1
----
105
124
160

query I rowsort
SELECT ALL + - 13 + 83 * col2 FROM tab1 AS cor0
----
4469
4718
7955

query I rowsort
SELECT DISTINCT - + col1 * 84 AS col1 FROM tab1 AS cor0
----
-1092
-2184
-840

query I rowsort
SELECT ALL ( + tab0.col2 ) AS col2 FROM tab0
----
1
33
82

query I rowsort
SELECT - ( 20 ) * col0 * + 65 AS col0 FROM tab2
----
-101400
-102700
-9100

query I rowsort
SELECT - col0 + col1 * - col2 AS col1 FROM tab1
----
-1328
-1407
-634

query I rowsort
SELECT ALL col1 + + ( - col0 ) * 31 FROM tab1 cor0
----
-1974
-2467
-67

onlyif mysql # use DIV operator for integer division
query I rowsort label-7363
SELECT DISTINCT + col1 + col1 * col2 DIV col0 AS col1 FROM tab0 cor0
----
174
204
99

skipif mysql # not compatible
query I rowsort label-7363
SELECT DISTINCT + col1 + col1 * col2 / col0 AS col1 FROM tab0 cor0
----
174
204
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-7364
SELECT DISTINCT col2 * - col1 + col1 DIV - col0 AS col1 FROM tab1 AS cor0
----
-1248
-1412
-570

skipif mysql # not compatible
query I rowsort label-7364
SELECT DISTINCT col2 * - col1 + col1 / - col0 AS col1 FROM tab1 AS cor0
----
-1248
-1412
-570

query I rowsort
SELECT - col2 + 68 FROM tab1 AS cor0
----
-28
11
14

query I rowsort
SELECT 46 + - col1 FROM tab0
----
-40
-45
-51

query I rowsort
SELECT DISTINCT + 25 * col1 FROM tab0
----
2150
2275
2425

query I rowsort
SELECT ALL + col1 * col2 + 10 * - col2 AS col2 FROM tab0 AS cor0
----
2508
6642
87

query I rowsort
SELECT DISTINCT - 61 AS col2 FROM tab0 AS cor0
----
-61

query I rowsort
SELECT ALL - + 41 * col2 AS col2 FROM tab0 AS cor0
----
-1353
-3362
-41

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 * col2 + - col2 col0 FROM tab2 AS cor0
----
162
2002
2964

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7372
SELECT + - col0 * 74 - + 24 * col1 * - CAST( NULL AS SIGNED ) FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7372
SELECT + - col0 * 74 - + 24 * col1 * - CAST ( NULL AS INTEGER ) FROM tab0 cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7373
SELECT ALL - + cor0.col1 * CAST( col0 AS SIGNED ) AS col0 FROM tab1 cor0
----
-1040
-640
-78

skipif mysql # not compatible
query I rowsort label-7373
SELECT ALL - + cor0.col1 * CAST ( col0 AS INTEGER ) AS col0 FROM tab1 cor0
----
-1040
-640
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 - + 20 col0 FROM tab0 AS cor0
----
15
4
69

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7375
SELECT ALL - + col0 + + CAST( col1 + col0 AS SIGNED ) * CAST( NULL AS SIGNED ) col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7375
SELECT ALL - + col0 + + CAST ( col1 + col0 AS INTEGER ) * 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 + + col0 * cor0.col0 + - col2 * - col1 col2 FROM tab0 cor0
----
1322
15383
3414

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7377
SELECT DISTINCT + col0 + + CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7377
SELECT DISTINCT + col0 + + CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7378
SELECT DISTINCT + cor0.col2 + CAST( - 30 AS SIGNED ) FROM tab2 cor0
----
-3
-4
8

skipif mysql # not compatible
query I rowsort label-7378
SELECT DISTINCT + cor0.col2 + CAST ( - 30 AS INTEGER ) FROM tab2 cor0
----
-3
-4
8

query I rowsort
SELECT DISTINCT col2 * col1 + 20 * + col2 * - col0 AS col1 FROM tab0 AS cor0
----
-13002
-138498
-603

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7380
SELECT ALL - cor0.col0 * CAST( NULL AS SIGNED ) + col1 * - col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7380
SELECT ALL - cor0.col0 * CAST ( NULL AS INTEGER ) + col1 * - col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 25 + cor0.col1 FROM tab0, tab2 AS cor0, tab2 cor1
----
27 values hashing to 863a9e6e96af5609962b1e1fca103d8d

query I rowsort
SELECT ALL + col1 + 41 FROM tab0 AS cor0
----
127
132
138

query I rowsort
SELECT + 67 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to b56f8a4f1fcebc9802481256df61e97c

query I rowsort
SELECT ALL + col1 + + 50 * + col0 - col1 FROM tab0
----
1200
1750
4450

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab0.col0 - col0 col2 FROM tab0
----
0
0
0

query I rowsort
SELECT + 32 + + col0 * - col2 * col0 - col0 * - cor0.col2 FROM tab0 AS cor0
----
-1158
-18184
-642192

query I rowsort
SELECT + 51 * col0 + col0 + col1 FROM tab2 AS cor0
----
395
4115
4125

query I rowsort
SELECT + ( + 42 ) * cor0.col0 * col2 FROM tab0 cor0
----
1470
306516
33264

query I rowsort
SELECT + col1 + 18 FROM tab1 AS cor0
----
28
31
44

query I rowsort
SELECT ALL + tab2.col1 + 90 AS col1 FROM tab2
----
107
121
149

query I rowsort
SELECT ALL - col1 + + 12 FROM tab0
----
-74
-79
-85

query I rowsort
SELECT ALL + + col0 + + col1 * + col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT + 65 * col2 FROM tab2 AS cor0
----
1690
1755
2470

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col0 + - cor0.col1 col0 FROM tab2 AS cor0
----
1326
186
4543

query I rowsort
SELECT ALL 16 * col0 * col2 + ( col1 + - col1 ) AS col1 FROM tab2
----
3024
32448
48032

query I rowsort
SELECT ALL + + cor0.col0 + cor0.col1 * - col0 * - 83 AS col2 FROM tab2 cor0
----
111548
18018
382044

query I rowsort
SELECT DISTINCT 29 + col2 * - 5 FROM tab1 AS cor0
----
-241
-256
-451

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + 80 col0 FROM tab2 AS cor0
----
80

query I rowsort
SELECT ALL - col0 + col0 * 86 * ( col2 ) AS col2 FROM tab2 AS cor0
----
16247
174330
258093

query I rowsort
SELECT ALL + + col0 * + col1 + - 12 AS col0 FROM tab2 AS cor0
----
1331
205
4590

query I rowsort
SELECT DISTINCT 58 * - tab0.col2 + - col0 FROM tab0
----
-1938
-4845
-93

query I rowsort
SELECT DISTINCT 73 + - col0 AS col2 FROM tab0
----
-16
38
49

query I rowsort
SELECT - col0 * + col1 + - col0 FROM tab1
----
-1120
-704
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 21 + + col0 col2 FROM tab0
----
14
3
68

query I rowsort
SELECT col1 * + 10 AS col1 FROM tab2
----
170
310
590

query I rowsort
SELECT ALL - col1 * - col1 + col2 FROM tab0
----
7429
8363
9410

query I rowsort
SELECT 98 + - col0 AS col1 FROM tab2
----
19
20
91

query I rowsort
SELECT cor1.col1 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT ALL - + ( - col0 ) * ( + col0 ) AS col0 FROM tab2 AS cor0
----
49
6084
6241

query I rowsort
SELECT - - 9 * col0 * + ( col1 ) AS col2 FROM tab1 AS cor0
----
5760
702
9360

query I rowsort
SELECT DISTINCT - 42 + cor0.col2 AS col0 FROM tab1 AS cor0
----
12
15
54

query I rowsort
SELECT DISTINCT - + col2 + col1 * + col2 * + col1 FROM tab2 AS cor0
----
10944
25920
90480

onlyif mysql # use DIV operator for integer division
query I rowsort label-7413
SELECT ALL + - col1 * col1 DIV 59 FROM tab2 cor0
----
-16
-4
-59

skipif mysql # not compatible
query I rowsort label-7413
SELECT ALL + - col1 * col1 / 59 FROM tab2 cor0
----
-16
-4
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-7414
SELECT DISTINCT - + col1 + - col1 DIV - col2 FROM tab1 cor0
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-7414
SELECT DISTINCT - + col1 + - col1 / - col2 FROM tab1 cor0
----
-10
-13
-26

query I rowsort
SELECT DISTINCT + 88 + col2 FROM tab0 AS cor0
----
121
170
89

query I rowsort
SELECT ALL col0 * col0 - - 44 AS col0 FROM tab1 AS cor0
----
4140
53
6444

query I rowsort
SELECT - col2 * col0 + - tab1.col0 * col1 * + col2 AS col1 FROM tab1
----
-107520
-40128
-4374

query I rowsort
SELECT DISTINCT tab2.col2 AS col2 FROM tab2, tab1 cor0
----
26
27
38

onlyif mysql # use DIV operator for integer division
query I rowsort label-7419
SELECT - col0 DIV + col1 col1 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7419
SELECT - col0 / + col1 col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT col1 - col0 * - col0 FROM tab2
----
6143
6258
80

query I rowsort
SELECT - - col1 - + col1 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - cor0.col0 * - cor0.col2 - col0 AS col2 FROM tab0 AS cor0
----
0
7209
768

query I rowsort
SELECT - - col1 + + col1 AS col0 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ALL - col0 * col0 * col1 FROM tab1
----
-234
-40960
-83200

query I rowsort
SELECT + cor0.col2 * - col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT + + cor0.col2 * + col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT - cor0.col1 * - cor0.col1 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT ALL - + col1 * - col2 + + col1 FROM tab1 cor0
----
1261
1430
580

query I rowsort
SELECT ALL + col2 * col1 + col2 AS col0 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT ALL + ( col2 ) * cor0.col0 + col2 AS col1 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT + col0 / col2 FROM tab2 WHERE NOT ( NULL < ( col1 ) ) AND ( NULL ) NOT IN ( col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7432
SELECT + col1 + col2 DIV + col0 FROM tab1 AS cor0
----
10
14
44

skipif mysql # not compatible
query I rowsort label-7432
SELECT + col1 + col2 / + col0 FROM tab1 AS cor0
----
10
14
44

query I rowsort
SELECT + + col1 + col0 * - col1 FROM tab1 AS cor0
----
-1027
-52
-630

onlyif mysql # use DIV operator for integer division
query I rowsort label-7434
SELECT DISTINCT - cor0.col2 DIV cor0.col1 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-7434
SELECT DISTINCT - cor0.col2 / cor0.col1 FROM tab0 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7435
SELECT col0 * + col1 + + col1 * cor0.col2 DIV + col0 FROM tab0 AS cor0
----
2182
3397
8182

skipif mysql # not compatible
query I rowsort label-7435
SELECT col0 * + col1 + + col1 * cor0.col2 / + col0 FROM tab0 AS cor0
----
2182
3397
8182

query I rowsort
SELECT + 86 * col1 + col0 * col0 FROM tab0 AS cor0
----
15747
7972
9567

query I rowsort
SELECT ALL col2 + - col2 * tab1.col1 + + col1 FROM tab1
----
-1139
-1324
-503

query I rowsort
SELECT + col2 * - col0 * col0 + col0 * col2 * - col2 FROM tab2 AS cor0
----
-210912
-351234
-6426

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT ( - col1 ) NOT IN ( col1 )
----

query I rowsort
SELECT - tab2.col2 + - col2 FROM tab2
----
-52
-54
-76

query I rowsort
SELECT ALL col0 * - col0 + col1 FROM tab0
----
-1128
-490
-7830

query I rowsort
SELECT DISTINCT col1 * + col1 + col0 FROM tab0
----
7420
8370
9444

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 * + col1 + tab1.col0 * tab1.col0 + + col2 col1 FROM tab1
----
1467
4723
7744

query I rowsort
SELECT col2 / col0 - + col2 FROM tab0 WHERE NOT NULL <> col0
----

query III rowsort
SELECT * FROM tab0 WHERE NULL NOT BETWEEN col0 * col1 AND ( NULL )
----

query I rowsort
SELECT ALL col0 * + col0 * + col1 + col0 FROM tab0
----
118860
49560
720900

query I rowsort
SELECT ALL col1 AS col2 FROM tab2 WHERE + col1 BETWEEN col0 + + tab2.col0 * col2 AND - col0
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7448
SELECT + col1 + + col1 DIV + col1 FROM tab1
----
11
14
27

skipif mysql # not compatible
query I rowsort label-7448
SELECT + col1 + + col1 / + col1 FROM tab1
----
11
14
27

query I rowsort
SELECT ALL cor1.col0 FROM tab0, tab0 AS cor0, tab2 AS cor1, tab2, tab0 AS cor2
----
243 values hashing to 455e4df3bf7b0fa681c56e89df1a761f

query I rowsort
SELECT tab1.col1 AS col1 FROM tab1 WHERE NOT ( + col2 ) BETWEEN col1 AND - col1 / col1 + col0 + col0
----
26

query I rowsort
SELECT DISTINCT + col1 FROM tab2 WHERE col2 * + col0 BETWEEN ( col0 ) AND ( NULL )
----

query I rowsort
SELECT + col1 AS col0 FROM tab0 WHERE NULL <= NULL
----

query III rowsort
SELECT * FROM tab2 WHERE NULL NOT IN ( - col2 * - col1 )
----

query I rowsort
SELECT tab1.col1 + col0 - + col2 FROM tab1
----
-25
-3
17

query I rowsort
SELECT col1 FROM tab0 WHERE NOT ( NULL ) IN ( col1 * tab0.col1 )
----

query I rowsort
SELECT ALL + tab1.col0 * col0 AS col1 FROM tab1
----
4096
6400
9

query III rowsort
SELECT * FROM tab1 WHERE NOT NULL IN ( col1 * col1 )
----

query I rowsort
SELECT DISTINCT col2 * + col2 * col0 AS col2 FROM tab0
----
26136
35
598436

query I rowsort
SELECT DISTINCT + col1 * col0 * col2 + col0 FROM tab0 AS cor0
----
3430
664207
68136

query I rowsort
SELECT ALL + col1 + cor0.col0 * + col2 + + col0 AS col1 FROM tab2 cor0
----
2165
227
3098

query III rowsort
SELECT ALL * FROM tab0 AS cor0 WHERE ( NULL ) NOT BETWEEN - col2 AND NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7462
SELECT col0 DIV col2 col2 FROM tab1
----
0
0
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7462
SELECT col0 / col2 col2 FROM tab1
----
0
0
1

query III rowsort
SELECT * FROM tab2 WHERE NOT col1 + - col0 * col1 > NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-7464
SELECT ALL - col1 DIV col2 + - col0 * + col2 AS col2 FROM tab0
----
-132
-7299
-794

skipif mysql # not compatible
query I rowsort label-7464
SELECT ALL - col1 / col2 + - col0 * + col2 AS col2 FROM tab0
----
-132
-7299
-794

query I rowsort
SELECT ALL + tab2.col1 * + col2 AS col0 FROM tab2
----
1534
646
837

query I rowsort
SELECT + col1 - tab1.col0 FROM tab1
----
-54
-67
23

query I rowsort
SELECT ALL col1 * col0 * + col2 + col2 + + tab0.col1 FROM tab0
----
3493
664291
68231

query I rowsort
SELECT col2 * col1 + tab1.col2 AS col2 FROM tab1
----
1344
1458
627

onlyif mysql # use DIV operator for integer division
query I rowsort label-7469
SELECT DISTINCT col2 + col2 DIV + col1 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-7469
SELECT DISTINCT col2 + col2 / + col1 FROM tab0
----
1
33
82

query I rowsort
SELECT ALL - col1 * + tab1.col0 * col0 + - tab1.col1 FROM tab1
----
-260
-40970
-83213

query I rowsort
SELECT ALL col1 * col0 AS col1 FROM tab2 WHERE NOT - col1 IN ( + col0 )
----
1343
217
4602

skipif mysql # not compatible
query I rowsort
SELECT - ( - col1 ) + - CAST ( - col2 AS REAL ) * - col1 AS col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL - 87 + col1 * - col0 * + col0 + col1 FROM tab0 AS cor0
----
-118815
-49537
-720807

query I rowsort
SELECT DISTINCT + col0 * - cor0.col1 + - col2 FROM tab2 AS cor0
----
-1381
-244
-4628

query I rowsort
SELECT ALL + + 98 + + cor0.col0 AS col2 FROM tab1 AS cor0
----
101
162
178

query I rowsort
SELECT ALL + 56 * + col1 + cor0.col2 AS col0 FROM tab0 AS cor0
----
4849
5178
5433

query I rowsort
SELECT DISTINCT col1 + + col1 * col0 AS col1 FROM tab0 AS cor0
----
2150
3492
8190

query I rowsort
SELECT + cor0.col2 * + col1 * - 71 FROM tab1 AS cor0
----
-40470
-88608
-99684

query I rowsort
SELECT ALL + + 22 + col2 AS col0 FROM tab0 AS cor0
----
104
23
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-7480
SELECT ALL col2 DIV + col2 + - ( - 78 ) col0 FROM tab1 AS cor0
----
79
79
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7480
SELECT ALL col2 / + col2 + - ( - 78 ) col0 FROM tab1 AS cor0
----
79
79
79

query I rowsort
SELECT 3 + col0 * cor0.col2 * + col1 FROM tab0 AS cor0
----
3398
664121
68115

query I rowsort
SELECT DISTINCT 39 AS col2 FROM tab2
----
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col2 ) - col1 * col1 col2 FROM tab2
----
-251
-3455
-934

query I rowsort
SELECT ALL + 6 * col2 * col1 + - cor0.col1 FROM tab0 AS cor0
----
16942
44681
485

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( - col1 ) + col2 * - col2 col1 FROM tab1 AS cor0
----
-2890
-3239
-9203

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col2 ) + col0 + 4 col1 FROM tab1 AS cor0
----
125
180
61

query I rowsort
SELECT + cor0.col1 * - col0 * col2 + - cor0.col0 - - col1 * 57 FROM tab2 AS cor0
----
-116367
-4099
-50144

query I rowsort
SELECT DISTINCT - ( cor0.col2 ) * ( cor0.col0 * - col0 ) AS col0 FROM tab1 cor0
----
233472
486
614400

query I rowsort
SELECT ALL + col1 * col1 + col0 * col2 * - tab1.col1 AS col1 FROM tab1
----
-3536
-36380
-99671

query I rowsort
SELECT DISTINCT + 15 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
15

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7491
SELECT DISTINCT + col1 * CAST( col0 AS SIGNED ) + tab1.col2 AS col1 FROM tab1
----
1136
132
697

skipif mysql # not compatible
query I rowsort label-7491
SELECT DISTINCT + col1 * CAST ( col0 AS INTEGER ) + tab1.col2 AS col1 FROM tab1
----
1136
132
697

query I rowsort
SELECT ALL + col1 - cor0.col1 AS col2 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - tab0.col2 + 58 AS col2 FROM tab0
----
-24
25
57

query I rowsort
SELECT ALL col1 * ( col0 * + 89 ) + - 14 + - col2 * - 82 FROM tab1 AS cor0
----
100418
11356
61620

query I rowsort
SELECT ( col2 ) * col1 + + col2 FROM tab0
----
2871
7544
98

query I rowsort
SELECT ALL 94 AS col2 FROM tab1
----
94
94
94

query I rowsort
SELECT ALL - 52 - ( col0 ) FROM tab0 AS cor0
----
-141
-76
-87

query I rowsort
SELECT ALL cor0.col0 * cor0.col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cf1383d310e5e3e19470e0b8dc064d0c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 48 col2 FROM tab1 AS cor0
----
-48
-48
-48

query I rowsort
SELECT DISTINCT - 49 - col2 FROM tab2 AS cor0
----
-75
-76
-87

query I rowsort
SELECT + ( 17 ) * col0 FROM tab0 AS cor0
----
1513
408
595

query I rowsort
SELECT DISTINCT - 45 + cor0.col0 + cor0.col0 FROM tab0 AS cor0
----
133
25
3

query I rowsort
SELECT col0 * + 77 AS col2 FROM tab1 cor0
----
231
4928
6160

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0 CROSS JOIN tab0, tab1 AS cor1, tab0 cor2
----
3645 values hashing to 64312dc66df177d8c745c63c0bdd4dc7

query I rowsort
SELECT col2 * - ( col1 ) + + ( 15 ) AS col1 FROM tab2
----
-1519
-631
-822

onlyif mysql # use DIV operator for integer division
query I rowsort label-7506
SELECT col2 DIV 92 AS col0 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7506
SELECT col2 / 92 AS col0 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT ALL + + 31 * 23 FROM tab2 AS cor0
----
713
713
713

query I rowsort
SELECT col2 * - 8 + col1 AS col2 FROM tab1 AS cor0
----
-406
-446
-755

query I rowsort
SELECT - + ( + ( + col2 ) ) AS col2 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT ALL + col1 + ( - col2 ) AS col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT ALL - ( - 36 ) FROM tab2 AS cor0
----
36
36
36

query I rowsort
SELECT ALL - cor0.col2 * col2 * col2 FROM tab1 AS cor0
----
-157464
-185193
-884736

query I rowsort
SELECT DISTINCT + + col1 * + 42 AS col2 FROM tab2 AS cor0
----
1302
2478
714

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7514
SELECT ALL - col0 + col1 - CAST( col1 + col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-137
-38
-96

skipif mysql # not compatible
query I rowsort label-7514
SELECT ALL - col0 + col1 - CAST ( col1 + col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-137
-38
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col1 + + col1 + col0 col0 FROM tab0 AS cor0
----
196
229
271

query I rowsort
SELECT DISTINCT + + 31 FROM tab1, tab0, tab0 AS cor0
----
31

query I rowsort
SELECT DISTINCT + - 1 * col0 + col2 AS col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT + 54 + - col1 FROM tab2 AS cor0
----
-5
23
37

query IIIIIIIII rowsort
SELECT ALL * FROM tab1, tab0 cor0 CROSS JOIN tab0 AS cor1
----
243 values hashing to 3581f59ff9574f9d6290fc6bca0b5e4d

query I rowsort
SELECT - col2 * cor0.col1 FROM tab2 cor0
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-7521
SELECT + col1 DIV - 3 AS col1 FROM tab0 AS cor0
----
-28
-30
-32

skipif mysql # not compatible
query I rowsort label-7521
SELECT + col1 / - 3 AS col1 FROM tab0 AS cor0
----
-28
-30
-32

query I rowsort
SELECT ALL + + col1 * - 33 + + 57 FROM tab1 AS cor0
----
-273
-372
-801

query I rowsort
SELECT - col0 * 9 FROM tab2 cor0
----
-63
-702
-711

query I rowsort
SELECT - col2 * - 30 * cor0.col0 + cor0.col1 FROM tab1 AS cor0
----
109450
230413
4886

onlyif mysql # use DIV operator for integer division
query I rowsort label-7525
SELECT + col2 DIV 89 AS col0 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7525
SELECT + col2 / 89 AS col0 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT - - col1 * col0 * + col2 FROM tab2 AS cor0
----
119652
51034
5859

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7527
SELECT + + CAST( NULL AS SIGNED ) * - 7 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7527
SELECT + + CAST ( NULL AS INTEGER ) * - 7 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - ( col1 ) + col0 col1 FROM tab0 AS cor0
----
-2
-62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7529
SELECT + CAST( - ( col1 ) AS SIGNED ) + col1 AS col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-7529
SELECT + CAST ( - ( col1 ) AS INTEGER ) + col1 AS col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 70 * + col0 + col2 * col2 FROM tab2 AS cor0
----
-4086
-4784
239

query I rowsort
SELECT DISTINCT + + ( 59 ) * + col2 FROM tab0 AS cor0
----
1947
4838
59

query I rowsort
SELECT + + 38 * col2 AS col1 FROM tab0 AS cor0
----
1254
3116
38

query I rowsort
SELECT - cor0.col1 * 7 + + col2 AS col1 FROM tab1 AS cor0
----
-128
-13
5

query I rowsort
SELECT DISTINCT - col2 + ( + col0 * - col2 ) AS col1 FROM tab0
----
-36
-7380
-825

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + ( + col0 ) col2 FROM tab1
----
29
74
93

query I rowsort
SELECT + col2 + + 94 * 65 FROM tab1
----
6164
6167
6206

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + ( col0 ) col1 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT - - ( ( cor1.col2 ) ) AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT DISTINCT - 75 AS col2 FROM tab2
----
-75

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7540
SELECT ALL + col2 * - CAST( + ( col2 ) AS SIGNED ) AS col2 FROM tab1
----
-2916
-3249
-9216

skipif mysql # not compatible
query I rowsort label-7540
SELECT ALL + col2 * - CAST ( + ( col2 ) AS INTEGER ) AS col2 FROM tab1
----
-2916
-3249
-9216

query I rowsort
SELECT DISTINCT 84 AS col0 FROM tab2, tab2 AS cor0, tab1 AS cor1
----
84

query I rowsort
SELECT col0 - 34 AS col2 FROM tab1
----
-31
30
46

query I rowsort
SELECT - col0 * + cor0.col1 AS col1 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT 0 AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 18 * col2 col2 FROM tab1
----
1026
1728
972

query I rowsort
SELECT DISTINCT + 14 AS col2 FROM tab2, tab1 AS cor0
----
14

query I rowsort
SELECT + 5 * + col1 AS col1 FROM tab0
----
430
455
485

query I rowsort
SELECT DISTINCT 1 FROM tab0, tab0 AS cor0
----
1

query I rowsort
SELECT col2 - - 2 FROM tab2 cor0
----
28
29
40

query I rowsort
SELECT + ( cor0.col2 ) * cor0.col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ( - 25 + tab0.col2 ) * col1 * - col1 FROM tab0
----
-472017
-59168
225816

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7552
SELECT + col2 * + col0 * CAST( col2 AS SIGNED ) + - col2 AS col2 FROM tab1 cor0
----
207879
737184
8694

skipif mysql # not compatible
query I rowsort label-7552
SELECT + col2 * + col0 * CAST ( col2 AS INTEGER ) + - col2 AS col2 FROM tab1 cor0
----
207879
737184
8694

onlyif mysql # use DIV operator for integer division
query I rowsort label-7553
SELECT + - col1 DIV + col1 + 29 FROM tab0 AS cor0
----
28
28
28

skipif mysql # not compatible
query I rowsort label-7553
SELECT + - col1 / + col1 + 29 FROM tab0 AS cor0
----
28
28
28

query I rowsort
SELECT 24 + - col0 AS col1 FROM tab0 cor0
----
-11
-65
0

query I rowsort
SELECT - cor0.col1 - + col0 * col2 FROM tab0 AS cor0
----
-132
-7389
-878

query I rowsort
SELECT + ( col1 ) + col0 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT + col0 * + col0 * 98 + - ( + col1 ) * + col2 AS col1 FROM tab0 AS cor0
----
119953
53610
768796

query I rowsort
SELECT ALL + 98 FROM tab0, tab2 AS cor0, tab2 cor1
----
27 values hashing to c758e8afbdfa6aae279045b0e9cbacc2

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + + col2 * 52 + - col2 col0 FROM tab0
----
1716
4264
52

query I rowsort
SELECT ALL - 99 + + col2 AS col1 FROM tab2
----
-61
-72
-73

query I rowsort
SELECT + col0 + + col1 + + col0 * - col0 FROM tab1
----
-4022
-6307
20

query I rowsort
SELECT + col1 + ( - 98 ) * + col1 AS col2 FROM tab2 AS cor0
----
-1649
-3007
-5723

query I rowsort
SELECT DISTINCT - col2 + - col2 * + col2 AS col0 FROM tab0 AS cor0
----
-1122
-2
-6806

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + - cor0.col1 col2 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT + - col0 + ( cor0.col2 ) AS col2 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT col1 * + 75 AS col0 FROM tab0 AS cor0
----
6450
6825
7275

query I rowsort
SELECT DISTINCT col0 + - 66 * 76 * + col0 FROM tab2 AS cor0
----
-35105
-391170
-396185

query I rowsort
SELECT + - col1 * + ( 37 ) + col1 FROM tab2 AS cor0
----
-1116
-2124
-612

query I rowsort
SELECT - cor0.col2 + ( col0 ) FROM tab2 AS cor0
----
-20
41
52

query I rowsort
SELECT - col0 + + ( 36 + + col0 ) * col0 FROM tab0 AS cor0
----
11036
1416
2450

query I rowsort
SELECT ALL - - col2 * col2 - col2 FROM tab2 AS cor0
----
1406
650
702

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7572
SELECT ALL col2 + + CAST( col1 AS SIGNED ) AS col1 FROM tab2 AS cor0
----
55
58
85

skipif mysql # not compatible
query I rowsort label-7572
SELECT ALL col2 + + CAST ( col1 AS INTEGER ) AS col1 FROM tab2 AS cor0
----
55
58
85

query I rowsort
SELECT ALL tab2.col2 * - col0 AS col2 FROM tab2
----
-189
-2028
-3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-7574
SELECT DISTINCT 20 DIV col1 FROM tab1
----
0
1
2

skipif mysql # not compatible
query I rowsort label-7574
SELECT DISTINCT 20 / col1 FROM tab1
----
0
1
2

query I rowsort
SELECT DISTINCT - + col1 * ( + col2 ) AS col0 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT ALL - - cor0.col0 + - col2 * + col1 FROM tab2 AS cor0
----
-1456
-567
-830

onlyif mysql # use DIV operator for integer division
query I rowsort label-7577
SELECT ALL - col2 DIV - 39 FROM tab1 AS cor0
----
1
1
2

skipif mysql # not compatible
query I rowsort label-7577
SELECT ALL - col2 / - 39 FROM tab1 AS cor0
----
1
1
2

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7578
SELECT CAST( NULL AS SIGNED ) * + col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7578
SELECT CAST ( NULL AS INTEGER ) * + col0 AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT 44 * col1 AS col0 FROM tab1 AS cor0
----
1144
440
572

onlyif mysql # use DIV operator for integer division
query I rowsort label-7580
SELECT + col0 + cor0.col2 DIV - cor0.col1 AS col2 FROM tab1 AS cor0
----
1
59
73

skipif mysql # not compatible
query I rowsort label-7580
SELECT + col0 + cor0.col2 / - cor0.col1 AS col2 FROM tab1 AS cor0
----
1
59
73

query I rowsort
SELECT - ( + 55 ) * + col1 AS col1 FROM tab2 AS cor0
----
-1705
-3245
-935

query I rowsort
SELECT + ( + col1 ) * - cor0.col1 AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT + 45 AS col0 FROM tab0 AS cor0
----
45
45
45

query I rowsort
SELECT DISTINCT + + col1 + cor0.col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT ALL + ( + col1 ) + col1 AS col0 FROM tab2 AS cor0
----
118
34
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7586
SELECT ALL - + CAST( col2 AS SIGNED ) * - col0 AS col2 FROM tab0 cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-7586
SELECT ALL - + CAST ( col2 AS INTEGER ) * - col0 AS col2 FROM tab0 cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 81 * 63 col2 FROM tab1 AS cor0
----
-5103

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + 84 col0 FROM tab1 AS cor0
----
110
94
97

query I rowsort
SELECT ALL - - 66 AS col2 FROM tab2 AS cor0
----
66
66
66

query I rowsort
SELECT ALL + 39 * col0 * col1 FROM tab1 AS cor0
----
24960
3042
40560

query I rowsort
SELECT DISTINCT - 74 AS col2 FROM tab2 AS cor0
----
-74

query I rowsort
SELECT col0 * - cor0.col1 + + 14 FROM tab1 AS cor0
----
-1026
-626
-64

query I rowsort
SELECT + ( + 94 ) + tab0.col2 * ( ( col2 ) + + col2 ) AS col0 FROM tab0
----
13542
2272
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7594
SELECT + + col0 DIV - CAST( 17 AS SIGNED ) FROM tab1 AS cor0
----
-3
-4
0

skipif mysql # not compatible
query I rowsort label-7594
SELECT + + col0 / - CAST ( 17 AS INTEGER ) FROM tab1 AS cor0
----
-3
-4
0

query I rowsort
SELECT DISTINCT - + col0 * col2 + col1 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT col0 + + cor0.col2 * - col1 AS col1 FROM tab0 cor0
----
-2814
-62
-7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-7597
SELECT ALL + + col1 + col2 DIV - cor0.col2 FROM tab1 AS cor0
----
12
25
9

skipif mysql # not compatible
query I rowsort label-7597
SELECT ALL + + col1 + col2 / - cor0.col2 FROM tab1 AS cor0
----
12
25
9

query I rowsort
SELECT 4 FROM tab1, tab0 AS cor0
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

onlyif mysql # use DIV operator for integer division
query I rowsort label-7599
SELECT DISTINCT - + col2 + CAST( - col1 AS SIGNED ) DIV + col0 AS col2 FROM tab0 AS cor0
----
-3
-36
-83

skipif mysql # not compatible
query I rowsort label-7599
SELECT DISTINCT - + col2 + CAST ( - col1 AS INTEGER ) / + col0 AS col2 FROM tab0 AS cor0
----
-3
-36
-83

query I rowsort
SELECT ALL - - col2 * - cor0.col0 * col0 + col0 * - cor0.col2 FROM tab0 AS cor0
----
-1260
-19800
-656820

onlyif mysql # use DIV operator for integer division
query I rowsort label-7601
SELECT ALL - col0 DIV - col2 + + 66 * col1 AS col1 FROM tab0 AS cor0
----
5676
6007
6437

skipif mysql # not compatible
query I rowsort label-7601
SELECT ALL - col0 / - col2 + + 66 * col1 AS col1 FROM tab0 AS cor0
----
5676
6007
6437

query I rowsort
SELECT DISTINCT - + col2 * col1 + + col1 AS col2 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT + col0 + - 70 FROM tab1 cor0
----
-6
-67
10

onlyif mysql # use DIV operator for integer division
query I rowsort label-7604
SELECT DISTINCT - + col1 DIV + col0 FROM tab0 cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-7604
SELECT DISTINCT - + col1 / + col0 FROM tab0 cor0
----
-1
-2
-3

query I rowsort
SELECT - 50 * 71 FROM tab2 cor0
----
-3550
-3550
-3550

query I rowsort
SELECT + - 31 * - cor0.col1 AS col2 FROM tab1 cor0
----
310
403
806

query I rowsort
SELECT 37 + - 14 * + cor0.col2 FROM tab1 AS cor0
----
-1307
-719
-761

query I rowsort
SELECT ALL - cor1.col2 AS col1 FROM tab1 cor0 CROSS JOIN tab1, tab2 AS cor1
----
27 values hashing to f9d4bb8677db7b98c7ed89d06e6e8cd6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + tab2.col0 * ( col2 ) col2 FROM tab2
----
189
2028
3002

query I rowsort
SELECT ALL - 22 FROM tab2 AS cor0 CROSS JOIN tab1, tab0 AS cor1
----
27 values hashing to 647e567609c5ada1d3454d2102819bfe

onlyif mysql # use DIV operator for integer division
query I rowsort label-7611
SELECT ALL col2 DIV + col1 + - 89 FROM tab0 AS cor0
----
-89
-89
-89

skipif mysql # not compatible
query I rowsort label-7611
SELECT ALL col2 / + col1 + - 89 FROM tab0 AS cor0
----
-89
-89
-89

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7612
SELECT DISTINCT col1 + + col2 + CAST( NULL AS SIGNED ) * col1 * + col1 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7612
SELECT DISTINCT col1 + + col2 + CAST ( NULL AS INTEGER ) * col1 * + col1 AS col1 FROM tab1 AS cor0
----
NULL

query IIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 AS cor0, tab0 AS cor1, tab0 cor2
----
972 values hashing to d522b52b67b20888d3544d25cb98f232

onlyif mysql # use DIV operator for integer division
query I rowsort label-7614
SELECT - col2 DIV cor0.col0 + ( - 4 ) * col1 AS col1 FROM tab2 AS cor0
----
-127
-236
-68

skipif mysql # not compatible
query I rowsort label-7614
SELECT - col2 / cor0.col0 + ( - 4 ) * col1 AS col1 FROM tab2 AS cor0
----
-127
-236
-68

query I rowsort
SELECT ALL - col2 * cor0.col2 * + col2 AS col1 FROM tab2 cor0
----
-17576
-19683
-54872

query I rowsort
SELECT - 65 + - col0 * + 87 FROM tab1 AS cor0
----
-326
-5633
-7025

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7617
SELECT ALL + col1 / - cor0.col2 + - CAST( NULL AS DECIMAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7617
SELECT ALL + col1 / - cor0.col2 + - CAST ( NULL AS REAL ) AS col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT tab0.col2 FROM tab1, tab0 AS cor0 CROSS JOIN tab0, tab1 AS cor1
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT + col0 * col0 - - ( - col2 ) AS col2 FROM tab0
----
1224
543
7839

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 + + tab0.col0 col1 FROM tab0
----
-2
-62
-62

query I rowsort
SELECT col2 * col1 * 90 AS col1 FROM tab0
----
255420
671580
8730

query I rowsort
SELECT col2 - + col2 * + ( col2 ) FROM tab0
----
-1056
-6642
0

query I rowsort
SELECT DISTINCT - col2 + tab1.col1 + col2 FROM tab1
----
10
13
26

query I rowsort
SELECT DISTINCT col2 + - col0 + 73 AS col2 FROM tab2
----
21
32
93

query I rowsort
SELECT ALL - 52 AS col0 FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to e8a5cb10c0973a78554f344d4f6e7e74

query I rowsort
SELECT - col0 * col1 * 85 + 99 * col2 AS col1 FROM tab0
----
-172173
-288476
-680297

query I rowsort
SELECT ALL col0 + col2 + - 46 * + tab2.col1 * col2 AS col2 FROM tab2
----
-29599
-38468
-70460

query I rowsort
SELECT + 61 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 8d4dfe649433a599fc4b10830cc7ce55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7629
SELECT ALL - tab0.col2 + CAST( NULL AS SIGNED ) AS col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7629
SELECT ALL - tab0.col2 + CAST ( NULL AS INTEGER ) AS col2 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT - col0 * + 78 FROM tab2 cor0
----
-546
-6084
-6162

query I rowsort
SELECT DISTINCT + col1 * 19 * - 79 + - col0 * col2 AS col1 FROM tab2 AS cor0
----
-28519
-46720
-90587

query I rowsort
SELECT DISTINCT cor0.col0 AS col1 FROM tab2, tab0 cor0, tab2 AS cor1, tab1 AS cor2
----
24
35
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-7633
SELECT - ( + col2 ) DIV - col0 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-7633
SELECT - ( + col2 ) / - col0 FROM tab1
----
0
1
18

query I rowsort
SELECT 92 + col1 + col1 * - tab2.col1 FROM tab2
----
-180
-3330
-838

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 14 col2 FROM tab0, tab0 cor0
----
9 values hashing to 83e5779d2487d12495e7d816c797264f

onlyif mysql # use DIV operator for integer division
query I rowsort label-7636
SELECT col2 + - col1 DIV tab1.col0 FROM tab1
----
46
57
96

skipif mysql # not compatible
query I rowsort label-7636
SELECT col2 + - col1 / tab1.col0 FROM tab1
----
46
57
96

query I rowsort
SELECT ALL - cor1.col0 AS col1 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT ALL col0 + + 35 + col0 FROM tab1
----
163
195
41

query I rowsort
SELECT + - cor0.col2 + + col1 * + cor0.col2 AS col1 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT ALL + + 43 + col2 * - col2 AS col1 FROM tab0 AS cor0
----
-1046
-6681
42

query I rowsort
SELECT ALL - ( col0 ) * - col0 AS col1 FROM tab1 AS cor0
----
4096
6400
9

query I rowsort
SELECT ALL 37 + - 47 AS col1 FROM tab0, tab1 AS cor0, tab2 AS cor1, tab0 AS cor2
----
81 values hashing to d02dd3860bad8257b8dc483efe370af0

query I rowsort
SELECT DISTINCT + col0 + - 47 AS col1 FROM tab2 AS cor0
----
-40
31
32

query I rowsort
SELECT DISTINCT col1 * - col2 * col2 FROM tab2 AS cor0
----
-22599
-24548
-39884

query I rowsort
SELECT - 27 * - col1 + - col2 FROM tab0 AS cor0
----
2289
2375
2618

onlyif mysql # use DIV operator for integer division
query I rowsort label-7646
SELECT ALL + + col0 * + cor0.col2 + - col2 DIV col1 - col2 FROM tab1 AS cor0
----
106
3586
7577

skipif mysql # not compatible
query I rowsort label-7646
SELECT ALL + + col0 * + cor0.col2 + - col2 / col1 - col2 FROM tab1 AS cor0
----
106
3586
7577

query I rowsort
SELECT col0 * col1 + - 72 * col1 * col0 FROM tab2 AS cor0
----
-15407
-326742
-95353

query I rowsort
SELECT ALL cor0.col0 + col2 * + col1 + - 74 FROM tab2 AS cor0
----
1538
651
770

query I rowsort
SELECT + 72 + col0 FROM tab1 AS cor0
----
136
152
75

query I rowsort
SELECT ALL - 13 - cor0.col1 AS col1 FROM tab2 AS cor0
----
-30
-44
-72

query I rowsort
SELECT + 39 + cor0.col0 * 84 AS col0 FROM tab0 AS cor0
----
2055
2979
7515

query I rowsort
SELECT DISTINCT col0 - + 22 AS col1 FROM tab1
----
-19
42
58

query I rowsort
SELECT ALL - col1 + 2 AS col1 FROM tab2
----
-15
-29
-57

query I rowsort
SELECT - + 7 + col1 + + col0 * 45 AS col1 FROM tab2 AS cor0
----
339
3562
3565

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7655
SELECT - col2 * - col1 * - CAST( NULL AS SIGNED ) + 24 + col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7655
SELECT - col2 * - col1 * - CAST ( NULL AS INTEGER ) + 24 + col0 AS col0 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 94 + - col1 * - ( col0 ) FROM tab1 AS cor0
----
-16
546
946

onlyif mysql # use DIV operator for integer division
query I rowsort label-7657
SELECT col0 DIV 24 FROM tab1 AS cor0
----
0
2
3

skipif mysql # not compatible
query I rowsort label-7657
SELECT col0 / 24 FROM tab1 AS cor0
----
0
2
3

query I rowsort
SELECT - cor0.col1 * 57 AS col0 FROM tab0, tab2 AS cor0
----
9 values hashing to 8b1e807eeef9377dda7f27d358d84877

query I rowsort
SELECT - col1 * + cor0.col2 + col2 FROM tab0 cor0
----
-2805
-7380
-96

query I rowsort
SELECT + col1 * - col2 * col2 FROM tab2
----
-22599
-24548
-39884

onlyif mysql # use DIV operator for integer division
query I rowsort label-7661
SELECT ALL tab1.col0 DIV col2 AS col2 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-7661
SELECT ALL tab1.col0 / col2 AS col2 FROM tab1
----
0
0
1

query I rowsort
SELECT ALL 38 + col0 * + col1 FROM tab1 cor0
----
1078
116
678

onlyif mysql # use DIV operator for integer division
query I rowsort label-7663
SELECT ALL ( col0 ) DIV 42 FROM tab1 AS cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-7663
SELECT ALL ( col0 ) / 42 FROM tab1 AS cor0
----
0
1
1

query I rowsort
SELECT DISTINCT 67 AS col1 FROM tab1 AS cor0
----
67

query I rowsort
SELECT DISTINCT + + col1 + col0 * ( 44 ) FROM tab0 AS cor0
----
1142
1637
4007

query I rowsort
SELECT - col2 * col0 * - ( 61 ) + col2 + + col1 FROM tab1 AS cor0
----
222595
468589
9962

query I rowsort
SELECT ALL 76 + + col0 * + col0 AS col0 FROM tab1
----
4172
6476
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-7668
SELECT ( - 21 ) DIV col1 + + col2 - col1 DIV - tab0.col2 FROM tab0
----
35
83
98

skipif mysql # not compatible
query I rowsort label-7668
SELECT ( - 21 ) / col1 + + col2 - col1 / - tab0.col2 FROM tab0
----
35
83
98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7669
SELECT - col1 - + CAST( NULL AS SIGNED ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7669
SELECT - col1 - + CAST ( NULL AS INTEGER ) AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + - ( + cor0.col2 + col2 ) col0 FROM tab0 cor0
----
-1
-33
-82

query I rowsort
SELECT col2 * 18 - col2 AS col2 FROM tab0 AS cor0
----
1394
17
561

query I rowsort
SELECT - col0 * - col0 + cor0.col2 FROM tab2 AS cor0
----
6110
6279
76

query I rowsort
SELECT - 67 FROM tab2, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 95c9eba643f6489e03be4d5e83f1ef99

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 47 col1 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
47

query I rowsort
SELECT - col1 * + ( + cor0.col0 ) - + col0 FROM tab1 AS cor0
----
-1120
-704
-81

query I rowsort
SELECT + cor0.col1 * col1 - cor0.col1 AS col1 FROM tab0 AS cor0
----
7310
8190
9312

query I rowsort
SELECT - col2 + + 68 * - col1 FROM tab1 cor0
----
-1822
-737
-980

onlyif mysql # use DIV operator for integer division
query I rowsort label-7678
SELECT - col0 DIV ( col1 ) - col0 * - col2 FROM tab0 AS cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-7678
SELECT - col0 / ( col1 ) - col0 * - col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT ALL - - cor1.col2 AS col1 FROM tab2, tab0 AS cor0, tab1, tab0 AS cor1
----
81 values hashing to e938777ebffc2e3e9c0cdfaa4f732c05

query I rowsort
SELECT ALL col2 * col1 + - cor0.col0 * col1 AS col1 FROM tab0 AS cor0
----
-3298
-637
774

query I rowsort
SELECT - col0 * + ( - col0 ) FROM tab2 cor0
----
49
6084
6241

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7682
SELECT DISTINCT cor0.col1 - + CAST( NULL AS SIGNED ) * ( + col1 ) * cor0.col0 AS col1 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7682
SELECT DISTINCT cor0.col1 - + CAST ( NULL AS INTEGER ) * ( + col1 ) * cor0.col0 AS col1 FROM tab0 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7683
SELECT cor0.col0 - CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7683
SELECT cor0.col0 - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT 70 * cor0.col1 FROM tab1, tab1 AS cor0
----
1820
700
910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7685
SELECT + col1 * CAST( NULL AS SIGNED ) AS col2 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7685
SELECT + col1 * CAST ( NULL AS INTEGER ) AS col2 FROM tab2
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-7686
SELECT - col1 DIV 14 AS col1 FROM tab2
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-7686
SELECT - col1 / 14 AS col1 FROM tab2
----
-1
-2
-4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 * col0 + col0 col2 FROM tab0 AS cor0
----
1260
600
8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-7688
SELECT - col1 DIV - 73 AS col0 FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7688
SELECT - col1 / - 73 AS col0 FROM tab0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7689
SELECT + 39 DIV + 44 FROM tab2, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

skipif mysql # not compatible
query I rowsort label-7689
SELECT + 39 / + 44 FROM tab2, tab2 AS cor0
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT ALL - tab1.col1 * + ( col0 ) * tab1.col0 AS col2 FROM tab1
----
-234
-40960
-83200

query I rowsort
SELECT col1 * - 83 + - cor0.col2 FROM tab0 AS cor0
----
-7171
-7635
-8052

onlyif mysql # use DIV operator for integer division
query I rowsort label-7692
SELECT + - ( + col2 ) * col1 DIV + ( col0 ) + col2 * col2 FROM tab2 AS cor0
----
1436
610
657

skipif mysql # not compatible
query I rowsort label-7692
SELECT + - ( + col2 ) * col1 / + ( col0 ) + col2 * col2 FROM tab2 AS cor0
----
1436
610
657

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 91 + col0 col1 FROM tab0
----
-2
-56
-67

query I rowsort
SELECT ALL - tab2.col1 + 52 FROM tab2
----
-7
21
35

query I rowsort
SELECT DISTINCT + 88 + cor0.col2 * col1 FROM tab1 AS cor0
----
1336
1492
658

query I rowsort
SELECT + - col1 - cor0.col0 FROM tab2 AS cor0
----
-137
-38
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-7697
SELECT ALL cor0.col1 DIV col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7697
SELECT ALL cor0.col1 / col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT 74 * col0 * col2 FROM tab2 AS cor0
----
13986
150072
222148

query I rowsort
SELECT + col0 * + 41 + - col2 AS col0 FROM tab1 AS cor0
----
2567
3184
69

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + ( + 5 ) col1 FROM tab0 AS cor0
----
-5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7701
SELECT DISTINCT - CAST( NULL AS SIGNED ) / 63 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-7701
SELECT DISTINCT - CAST ( NULL AS INTEGER ) / 63 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT 38 * + cor0.col1 FROM tab2 AS cor0
----
1178
2242
646

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - 99 * cor0.col1 - + cor0.col0 * col2 * + 86 col0 FROM tab0 AS cor0
----
-59598
-618619
6593

query I rowsort
SELECT - 46 - - col2 FROM tab2 AS cor0
----
-19
-20
-8

query I rowsort
SELECT ALL - 48 * + col0 FROM tab2 AS cor0
----
-336
-3744
-3792

query I rowsort
SELECT + + cor0.col0 + - col2 * + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT DISTINCT + 2 * 48 + cor1.col2 + + ( cor0.col0 ) FROM tab1 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 641e5e2e42cf759841eed7da86b820fc

query I rowsort
SELECT + 38 + + col0 FROM tab1 AS cor0
----
102
118
41

query I rowsort
SELECT 27 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

query I rowsort
SELECT ALL + - cor0.col2 + + cor0.col2 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT col2 + col0 * col2 AS col0 FROM tab1 AS cor0
----
216
3705
7776

query I rowsort
SELECT - 76 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to d90b4aa5f03b4a149aa925c4a88acca0

query I rowsort
SELECT ALL + col0 * 24 FROM tab2 AS cor0
----
168
1872
1896

onlyif mysql # use DIV operator for integer division
query I rowsort label-7714
SELECT + col2 * ( - col0 ) DIV - col1 FROM tab1 AS cor0
----
364
590
6

skipif mysql # not compatible
query I rowsort label-7714
SELECT + col2 * ( - col0 ) / - col1 FROM tab1 AS cor0
----
364
590
6

query I rowsort
SELECT ( col0 + ( 46 ) ) FROM tab0
----
135
70
81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 16 + col2 col0 FROM tab1
----
38
41
80

query I rowsort
SELECT + col1 * - col2 + col2 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT DISTINCT + 65 * - col1 AS col1 FROM tab2
----
-1105
-2015
-3835

query I rowsort
SELECT + 85 + col1 AS col0 FROM tab2
----
102
116
144

onlyif mysql # use DIV operator for integer division
query I rowsort label-7720
SELECT - col2 DIV col1 - - col0 DIV - ( - col2 + - 92 ) AS col1 FROM tab1
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-7720
SELECT - col2 / col1 - - col0 / - ( - col2 + - 92 ) AS col1 FROM tab1
----
-2
-5
-7

query I rowsort
SELECT + - tab0.col2 + tab0.col0 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to 09b61d5303a3c257c2b4280abfc64db7

query I rowsort
SELECT ALL + 34 * col1 * + tab1.col2 + col2 FROM tab1
----
19437
42528
47790

query I rowsort
SELECT + 23 * tab2.col0 AS col0 FROM tab2
----
161
1794
1817

query I rowsort
SELECT ALL - - col1 + + cor0.col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT cor0.col1 + 3 AS col1 FROM tab1 AS cor0
----
13
16
29

onlyif mysql # use DIV operator for integer division
query I rowsort label-7726
SELECT ALL - col1 DIV 24 + ( - col1 ) AS col1 FROM tab1 AS cor0
----
-10
-13
-27

skipif mysql # not compatible
query I rowsort label-7726
SELECT ALL - col1 / 24 + ( - col1 ) AS col1 FROM tab1 AS cor0
----
-10
-13
-27

query I rowsort
SELECT ALL - cor0.col1 * + 50 + 34 FROM tab0 AS cor0
----
-4266
-4516
-4816

query I rowsort
SELECT DISTINCT + col2 - col1 * + col2 AS col2 FROM tab1 AS cor0
----
-1152
-1350
-513

onlyif mysql # use DIV operator for integer division
query I rowsort label-7729
SELECT col2 * 4 DIV col0 + cor0.col2 * - col2 * - col2 AS col0 FROM tab0 AS cor0
----
1
35942
551371

skipif mysql # not compatible
query I rowsort label-7729
SELECT col2 * 4 / col0 + cor0.col2 * - col2 * - col2 AS col0 FROM tab0 AS cor0
----
1
35942
551371

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7730
SELECT DISTINCT + col0 - + CAST( + col1 AS SIGNED ) * + col0 AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

skipif mysql # not compatible
query I rowsort label-7730
SELECT DISTINCT + col0 - + CAST ( + col1 AS INTEGER ) * + col0 AS col1 FROM tab0 AS cor0
----
-2040
-3360
-8010

onlyif mysql # use DIV operator for integer division
query I rowsort label-7731
SELECT col0 DIV ( + col0 ) + cor0.col0 FROM tab1 cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-7731
SELECT col0 / ( + col0 ) + cor0.col0 FROM tab1 cor0
----
4
65
81

query I rowsort
SELECT DISTINCT + - col0 * - ( col1 ) + cor0.col0 AS col1 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT ALL + - col2 * col2 + cor0.col2 * - col0 FROM tab1 AS cor0
----
-16896
-3078
-6897

query I rowsort
SELECT col2 * - ( - col0 ) AS col0 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - cor0.col1 * + 31 FROM tab0 AS cor0
----
-2666
-2821
-3007

query I rowsort
SELECT DISTINCT - 31 + col1 FROM tab1
----
-18
-21
-5

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + - col0 * 50 col0 FROM tab1 AS cor0
----
-124
-3190
-3987

onlyif mysql # use DIV operator for integer division
query I rowsort label-7738
SELECT ALL - col1 DIV - col1 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-7738
SELECT ALL - col1 / - col1 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort
SELECT - col0 * CAST ( - cor0.col0 AS REAL ) AS col0 FROM tab0 AS cor0
----
1225
576
7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * col0 + col0 col1 FROM tab0 cor0
----
2088
3430
8188

query I rowsort
SELECT ALL - cor0.col1 * - col2 - - 96 FROM tab0 AS cor0
----
193
2934
7558

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE NOT NULL = ( NULL )
----

query I rowsort
SELECT - col2 * + col1 + - tab0.col2 FROM tab0
----
-2871
-7544
-98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7744
SELECT col0 DIV tab0.col0 - col1 * col0 AS col1 FROM tab0
----
-2063
-3394
-8098

skipif mysql # not compatible
query I rowsort label-7744
SELECT col0 / tab0.col0 - col1 * col0 AS col1 FROM tab0
----
-2063
-3394
-8098

query I rowsort
SELECT ALL col2 * col1 * tab1.col1 FROM tab1
----
16224
36504
5700

query I rowsort
SELECT col0 * - tab2.col0 * - tab2.col0 FROM tab2
----
343
474552
493039

query I rowsort
SELECT col0 + col1 * col2 AS col1 FROM tab2
----
1612
725
844

query I rowsort
SELECT DISTINCT + col2 * col1 + tab2.col0 + tab2.col0 FROM tab2
----
1690
804
851

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL >= ( + col1 * - col0 )
----

query I rowsort
SELECT + tab2.col0 * + col1 * tab2.col1 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT DISTINCT col1 * col2 FROM tab0 WHERE NULL NOT BETWEEN ( NULL ) AND + col0 * + col1 + col0
----

query I rowsort
SELECT col0 * col2 + col0 * + col2 AS col1 FROM tab1
----
15360
324
7296

query I rowsort
SELECT + col0 * - col2 + + col1 AS col0 FROM tab1
----
-136
-3638
-7667

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE NOT + col2 <> ( col2 * - col2 )
----

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7755
SELECT + col0 * col2 + - CAST( - 34 + col1 AS SIGNED ) col1 FROM tab0 AS cor0
----
-28
7241
740

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-7755
SELECT + col0 * col2 + - CAST ( - 34 + col1 AS INTEGER ) col1 FROM tab0 AS cor0
----
-28
7241
740

query I rowsort
SELECT - 71 FROM tab2, tab0 AS cor0
----
9 values hashing to e72f95c346714d3065a96d67a6fd5062

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( NULL ) NOT IN ( - col2 - - col0 )
----

query I rowsort
SELECT ALL col0 * col0 FROM tab1 WHERE NOT ( NULL ) IN ( col1 + + col1 )
----

query I rowsort
SELECT DISTINCT - tab2.col0 * col0 AS col0 FROM tab2
----
-49
-6084
-6241

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab2.col1 * col1 col1 FROM tab2
----
289
3481
961

query I rowsort
SELECT ALL col1 * tab2.col0 * col2 AS col2 FROM tab2
----
119652
51034
5859

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT ( - col2 - + col1 ) IN ( + col1 * + col0 + tab2.col2 )
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

onlyif mysql # use DIV operator for integer division
query I rowsort label-7763
SELECT ALL col2 DIV + col1 FROM tab2
----
0
0
2

skipif mysql # not compatible
query I rowsort label-7763
SELECT ALL col2 / + col1 FROM tab2
----
0
0
2

query I rowsort
SELECT ALL col1 * tab0.col2 AS col0 FROM tab0
----
2838
7462
97

query I rowsort
SELECT + + 4 + - col1 FROM tab2 cor0
----
-13
-27
-55

query I rowsort
SELECT - 70 * col2 + - 84 - + 61 AS col1 FROM tab2 AS cor0
----
-1965
-2035
-2805

query I rowsort
SELECT DISTINCT - + 98 + - col1 AS col0 FROM tab2 AS cor0
----
-115
-129
-157

query I rowsort
SELECT + - ( col1 ) * col1 * - col1 + - col2 AS col2 FROM tab1 AS cor0
----
17522
2101
943

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 30 + + col0 * + 75 col1 FROM tab2 AS cor0
----
555
5880
5955

query I rowsort
SELECT ALL - ( col1 ) * + col1 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT + cor0.col1 + col1 * ( 38 ) + + col0 FROM tab0 AS cor0
----
3378
3638
3818

query I rowsort
SELECT - col1 * - cor0.col0 + + ( - col1 * - cor0.col2 ) FROM tab0 AS cor0
----
15561
3492
4902

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7773
SELECT - tab0.col1 + col2 + CAST( - col2 AS SIGNED ) FROM tab0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-7773
SELECT - tab0.col1 + col2 + CAST ( - col2 AS INTEGER ) FROM tab0
----
-86
-91
-97

query I rowsort
SELECT ( - 33 ) FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8035c665a75d22be5922be1a4e574e03

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7775
SELECT ALL CAST( NULL AS SIGNED ) FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-7775
SELECT ALL CAST ( NULL AS INTEGER ) FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL - 67 + + col0 FROM tab0
----
-32
-43
22

query I rowsort
SELECT ALL + col2 * col2 + - tab2.col0 * 67 * col1 FROM tab2
----
-13810
-307658
-88537

query I rowsort
SELECT ALL - 29 * cor0.col1 + col2 AS col0 FROM tab1 AS cor0
----
-233
-281
-700

query I rowsort
SELECT DISTINCT + col0 + - col1 + cor0.col0 FROM tab1 AS cor0
----
-20
118
147

query I rowsort
SELECT DISTINCT - ( + col0 ) + + col0 FROM tab1 AS cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7781
SELECT + CAST( col1 AS SIGNED ) + - col2 FROM tab0 AS cor0
----
53
9
96

skipif mysql # not compatible
query I rowsort label-7781
SELECT + CAST ( col1 AS INTEGER ) + - col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT DISTINCT + + 94 + + cor0.col2 FROM tab2 cor0
----
120
121
132

query I rowsort
SELECT ALL - - ( col2 ) - col0 AS col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT ALL + cor0.col1 AS col2 FROM tab1 cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 366ec539af0f37bd1519bc568f3d6775

query I rowsort
SELECT - - col1 + + col1 AS col2 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT - cor0.col0 + - col2 * col2 FROM tab0 cor0
----
-1113
-36
-6813

query I rowsort
SELECT + + 45 * col2 AS col0 FROM tab0 AS cor0
----
1485
3690
45

query I rowsort
SELECT - col2 + + col2 * - col0 FROM tab1
----
-216
-3705
-7776

query I rowsort
SELECT ALL + cor0.col1 * - col0 * + col2 AS col0 FROM tab0 AS cor0
----
-3395
-664118
-68112

query I rowsort
SELECT + 92 * - col1 AS col2 FROM tab1
----
-1196
-2392
-920

query I rowsort
SELECT DISTINCT - + col0 * cor0.col2 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT DISTINCT cor0.col1 * col0 + - col1 * + col2 AS col1 FROM tab1 AS cor0
----
-1326
-208
70

query I rowsort
SELECT ALL + col0 + col0 + col1 AS col1 FROM tab0 cor0
----
134
167
269

query I rowsort
SELECT DISTINCT - cor0.col1 + + col0 * - cor0.col1 FROM tab0 AS cor0
----
-2150
-3492
-8190

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col0 + + col0 col0 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT ( 58 ) + - col2 * col1 AS col1 FROM tab2 AS cor0
----
-1476
-588
-779

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7797
SELECT - CAST( col1 AS SIGNED ) * + col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif mysql # not compatible
query I rowsort label-7797
SELECT - CAST ( col1 AS INTEGER ) * + col0 AS col2 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT 3 * 30 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 96f7a90428db93f472e0d219bab64853

query I rowsort
SELECT ALL + + col1 + col1 AS col0 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT - - 12 * col0 AS col1 FROM tab0 AS cor0
----
1068
288
420

query I rowsort
SELECT 89 * col0 AS col1 FROM tab2 cor0
----
623
6942
7031

onlyif mysql # use DIV operator for integer division
query I rowsort label-7802
SELECT DISTINCT 91 DIV col2 AS col1 FROM tab0
----
1
2
91

skipif mysql # not compatible
query I rowsort label-7802
SELECT DISTINCT 91 / col2 AS col1 FROM tab0
----
1
2
91

query I rowsort
SELECT ALL 99 * - 57 AS col1 FROM tab0
----
-5643
-5643
-5643

query I rowsort
SELECT - col2 * col0 * col0 FROM tab1 AS cor0
----
-233472
-486
-614400

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col2 + col1 * col2 col1 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL cor0.col1 FROM tab0 AS cor0 CROSS JOIN tab1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query III rowsort
SELECT * FROM tab0 WHERE col0 * col2 <> ( col0 )
----
24
86
33
89
91
82

query I rowsort
SELECT ALL + tab2.col2 FROM tab1, tab1 AS cor0 CROSS JOIN tab2
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

onlyif mysql # use DIV operator for integer division
query I rowsort label-7809
SELECT ALL col1 DIV - col1 + - col1 AS col0 FROM tab1
----
-11
-14
-27

skipif mysql # not compatible
query I rowsort label-7809
SELECT ALL col1 / - col1 + - col1 AS col0 FROM tab1
----
-11
-14
-27

onlyif mysql # use DIV operator for integer division
query I rowsort label-7810
SELECT ALL - col2 * cor0.col0 DIV + col0 FROM tab2 AS cor0
----
-26
-27
-38

skipif mysql # not compatible
query I rowsort label-7810
SELECT ALL - col2 * cor0.col0 / + col0 FROM tab2 AS cor0
----
-26
-27
-38

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL NOT IN ( - col0 * + col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 col1 FROM tab2 WHERE NOT col1 * + col2 NOT IN ( col0 * + col1 + - col1 )
----

query I rowsort
SELECT DISTINCT col1 + col0 * + col2 * tab2.col1 AS col2 FROM tab2
----
119711
51051
5890

query I rowsort
SELECT ALL tab0.col0 * col1 + + col1 * tab0.col2 * tab0.col2 AS col1 FROM tab0
----
3492
619983
95718

query I rowsort
SELECT DISTINCT + col1 FROM tab2 WHERE col2 * - col2 <> - col2
----
17
31
59

query I rowsort
SELECT DISTINCT + col2 + tab2.col2 * col2 * + col2 FROM tab2
----
17602
19710
54910

query I rowsort
SELECT DISTINCT tab1.col0 + - col2 AS col1 FROM tab1
----
-16
-51
7

query I rowsort
SELECT ALL - col0 + col1 AS col2 FROM tab0 WHERE NULL >= NULL
----

query I rowsort
SELECT + col2 * + tab0.col0 AS col2 FROM tab0
----
35
7298
792

query I rowsort
SELECT - tab2.col1 + + col2 * + col2 * - col0 FROM tab2
----
-114093
-5134
-52787

query III rowsort
SELECT * FROM tab0 WHERE NULL NOT BETWEEN NULL AND - col0
----

query I rowsort
SELECT + tab0.col2 * col1 * - col1 AS col2 FROM tab0
----
-244068
-679042
-9409

query I rowsort
SELECT + + col2 * + col0 + col0 AS col0 FROM tab1 AS cor0
----
165
3712
7760

query I rowsort
SELECT DISTINCT + + col0 * col2 + col2 + + cor0.col1 * - col2 FROM tab0 AS cor0
----
-2013
-61
-82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab2.col1 + cor0.col0 col2 FROM tab2, tab0, tab1 AS cor0
----
9 values hashing to af3a539c18b07c0d2d3147e1b73e81ac

query I rowsort
SELECT ALL - col2 + col2 * + col2 FROM tab1 AS cor0
----
2862
3192
9120

query I rowsort
SELECT ALL - tab1.col2 + + col0 * + tab1.col1 FROM tab1
----
24
583
944

query I rowsort
SELECT col2 - tab0.col0 * + col0 * col0 FROM tab0
----
-13791
-42874
-704887

query I rowsort
SELECT DISTINCT col0 + col1 * tab1.col2 AS col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT cor0.col1 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to d671a064e2da709ca4cdfea317b8e892

query I rowsort
SELECT ALL col2 + + col1 * col2 AS col1 FROM tab0
----
2871
7544
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-7832
SELECT col0 + col0 DIV tab1.col2 AS col2 FROM tab1
----
3
65
80

skipif mysql # not compatible
query I rowsort label-7832
SELECT col0 + col0 / tab1.col2 AS col2 FROM tab1
----
3
65
80

query I rowsort
SELECT ALL + col2 - - col0 * col0 FROM tab1 AS cor0
----
4153
63
6496

query I rowsort
SELECT DISTINCT col0 + - cor0.col0 AS col2 FROM tab2 AS cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-7835
SELECT + col1 DIV col0 + + col1 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-7835
SELECT + col1 / col0 + + col1 FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT ALL + - col0 * - col1 * col2 + + col0 FROM tab0 cor0
----
3430
664207
68136

query I rowsort
SELECT - - col1 + col1 * - col2 AS col2 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL + - col0 * col2 + col0 * - col1 AS col0 FROM tab1 AS cor0
----
-240
-4288
-8720

query I rowsort
SELECT - col0 + cor0.col0 * - col0 FROM tab0 AS cor0
----
-1260
-600
-8010

query I rowsort
SELECT DISTINCT + - cor0.col2 + - col0 - col1 AS col1 FROM tab1 cor0
----
-131
-189
-83

query I rowsort
SELECT + + cor0.col1 * + col1 AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT - col0 + + col0 * col0 FROM tab1 AS cor0
----
4032
6
6320

query I rowsort
SELECT 97 - cor0.col1 FROM tab0 AS cor0
----
0
11
6

onlyif mysql # use DIV operator for integer division
query I rowsort label-7844
SELECT DISTINCT + col2 + 9 DIV col1 FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-7844
SELECT DISTINCT + col2 + 9 / col1 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT DISTINCT + col2 * - 60 + + col0 FROM tab0 AS cor0
----
-1956
-25
-4831

query I rowsort
SELECT + col1 + ( col2 + + col1 ) AS col0 FROM tab1 AS cor0
----
106
122
77

query I rowsort
SELECT - col0 * - 49 + col0 FROM tab0 AS cor0
----
1200
1750
4450

query I rowsort
SELECT ALL col1 + - 31 FROM tab0
----
55
60
66

query I rowsort
SELECT tab0.col0 * - col2 + - tab0.col1 AS col1 FROM tab0
----
-132
-7389
-878

query I rowsort
SELECT - 48 + + tab2.col1 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to 9aca838dd81f22c8a0b07a74e40b0937

query I rowsort
SELECT ALL tab1.col2 + + col1 * - 23 AS col1 FROM tab1
----
-173
-203
-544

query I rowsort
SELECT ALL + col2 + + col0 * - 51 FROM tab1
----
-3207
-3984
-99

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab0, tab2 AS cor0 CROSS JOIN tab1, tab2 AS cor1, tab1 cor2
----
3645 values hashing to db56d052e81a1ceebb4c3aea124670be

query I rowsort
SELECT DISTINCT + + cor0.col2 * ( + col0 ) + cor0.col2 * - col2 AS col1 FROM tab1 AS cor0
----
-1536
-2754
399

query I rowsort
SELECT - - 6 + col1 FROM tab0 AS cor0
----
103
92
97

query I rowsort
SELECT ALL 24 + col0 * - col1 FROM tab2 AS cor0
----
-1319
-193
-4578

query I rowsort
SELECT ALL col2 + - 19 AS col2 FROM tab0 AS cor0
----
-18
14
63

query I rowsort
SELECT col1 * col0 + - cor0.col2 * - 72 FROM tab2 AS cor0
----
2161
4079
6474

query I rowsort
SELECT DISTINCT + 59 - col0 AS col1 FROM tab0 cor0
----
-30
24
35

onlyif mysql # use DIV operator for integer division
query I rowsort label-7860
SELECT DISTINCT + CAST( col2 AS SIGNED ) DIV + col2 FROM tab1 AS cor0
----
1

skipif mysql # not compatible
query I rowsort label-7860
SELECT DISTINCT + CAST ( col2 AS INTEGER ) / + col2 FROM tab1 AS cor0
----
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-7861
SELECT + col2 * + 75 + - col2 + + col2 DIV cor0.col0 AS col1 FROM tab0 AS cor0
----
2443
6068
74

skipif mysql # not compatible
query I rowsort label-7861
SELECT + col2 * + 75 + - col2 + + col2 / cor0.col0 AS col1 FROM tab0 AS cor0
----
2443
6068
74

query I rowsort
SELECT - 68 + + 83 AS col2 FROM tab2 AS cor0
----
15
15
15

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 78 col1 FROM tab2 cor0
----
78
78
78

query I rowsort
SELECT ALL ( - 79 ) + + cor0.col1 + 11 * + col2 AS col0 FROM tab2 AS cor0
----
249
266
356

query I rowsort
SELECT DISTINCT + ( - cor0.col1 ) * + cor0.col2 AS col0 FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT DISTINCT - col0 - col0 FROM tab0 cor0
----
-178
-48
-70

query I rowsort
SELECT ALL + 53 * col1 AS col2 FROM tab0 AS cor0
----
4558
4823
5141

query I rowsort
SELECT - 33 * col1 * col0 - - ( + cor0.col2 ) FROM tab2 cor0
----
-151840
-44281
-7134

query I rowsort
SELECT ALL 4 FROM tab1 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 6fec965b60b9885c4af73e85422cfd9b

query I rowsort
SELECT - 55 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to ac76841ceecd2311e80c621d15bacdd3

query I rowsort
SELECT - + cor0.col2 * + col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL - - col0 + col1 * col2 FROM tab0 AS cor0
----
132
2862
7551

query I rowsort
SELECT DISTINCT + - 78 * + col1 + 48 AS col1 FROM tab1 AS cor0
----
-1980
-732
-966

query I rowsort
SELECT DISTINCT + + 50 FROM tab2 AS cor0
----
50

query I rowsort
SELECT DISTINCT - col0 * col0 * - ( col1 ) AS col2 FROM tab1 AS cor0
----
234
40960
83200

query I rowsort
SELECT ALL + col2 + cor0.col0 * - col2 FROM tab0 cor0
----
-34
-7216
-759

query I rowsort
SELECT + 36 * + col2 AS col2 FROM tab2 AS cor0
----
1368
936
972

onlyif mysql # use DIV operator for integer division
query I rowsort label-7878
SELECT + 55 DIV + col2 FROM tab0 AS cor0
----
0
1
55

skipif mysql # not compatible
query I rowsort label-7878
SELECT + 55 / + col2 FROM tab0 AS cor0
----
0
1
55

query I rowsort
SELECT DISTINCT col2 * 28 AS col1 FROM tab0 AS cor0
----
2296
28
924

query I rowsort
SELECT ALL - col0 - 19 FROM tab0 cor0
----
-108
-43
-54

query I rowsort
SELECT + - col1 * + ( cor0.col0 ) * - col0 - - col1 FROM tab1 AS cor0
----
260
40970
83213

query I rowsort
SELECT DISTINCT + col0 - ( col2 ) * - col0 FROM tab0 AS cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-7883
SELECT col2 DIV - 8 - + ( - col2 ) AS col2 FROM tab0 AS cor0
----
1
29
72

skipif mysql # not compatible
query I rowsort label-7883
SELECT col2 / - 8 - + ( - col2 ) AS col2 FROM tab0 AS cor0
----
1
29
72

query I rowsort
SELECT + col0 * + 73 FROM tab2 AS cor0
----
511
5694
5767

query I rowsort
SELECT DISTINCT + col0 * + 96 * + 1 FROM tab1 AS cor0
----
288
6144
7680

query I rowsort
SELECT + + cor0.col2 * + col0 FROM tab0 AS cor0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 25 col0 FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
25

query I rowsort
SELECT - - col1 * - col0 + + col1 FROM tab2 AS cor0
----
-1326
-186
-4543

query I rowsort
SELECT DISTINCT - + cor0.col2 + - ( + 28 ) AS col1 FROM tab1 AS cor0
----
-124
-82
-85

query I rowsort
SELECT DISTINCT - + cor0.col0 + - ( + col1 ) * col1 AS col0 FROM tab0 AS cor0
----
-7420
-8370
-9444

query I rowsort
SELECT DISTINCT - + col0 + + ( col2 ) * col0 FROM tab2 AS cor0
----
182
1950
2923

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7892
SELECT - - col1 + CAST( - col0 AS SIGNED ) AS col1 FROM tab1 AS cor0
----
-54
-67
23

skipif mysql # not compatible
query I rowsort label-7892
SELECT - - col1 + CAST ( - col0 AS INTEGER ) AS col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT col2 + + cor0.col2 + cor0.col2 FROM tab2 AS cor0
----
114
78
81

query I rowsort
SELECT ALL 29 FROM tab1, tab1 AS cor0, tab0 cor1
----
27 values hashing to 4c56285992bcb76e1aac22e6d23d1318

query I rowsort
SELECT - col0 + + 99 * cor0.col2 + + col1 AS col1 FROM tab1 AS cor0
----
5369
5589
9437

query I rowsort
SELECT col2 * - tab0.col1 + col2 + col2 AS col2 FROM tab0
----
-2772
-7298
-95

query I rowsort
SELECT DISTINCT tab0.col0 * ( - col0 ) FROM tab0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT + cor0.col1 + + col1 * col0 AS col2 FROM tab0 AS cor0
----
2150
3492
8190

onlyif mysql # use DIV operator for integer division
query I rowsort label-7899
SELECT + col2 * col0 DIV - col1 FROM tab0 cor0
----
-80
-9
0

skipif mysql # not compatible
query I rowsort label-7899
SELECT + col2 * col0 / - col1 FROM tab0 cor0
----
-80
-9
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7900
SELECT - cor0.col0 * cor0.col0 + CAST( + col1 AS SIGNED ) * col0 AS col2 FROM tab1 cor0
----
-3456
-5360
69

skipif mysql # not compatible
query I rowsort label-7900
SELECT - cor0.col0 * cor0.col0 + CAST ( + col1 AS INTEGER ) * col0 AS col2 FROM tab1 cor0
----
-3456
-5360
69

query I rowsort
SELECT - + col0 * cor0.col1 + + 98 AS col1 FROM tab1 AS cor0
----
-542
-942
20

query I rowsort
SELECT ALL - - 73 FROM tab1 AS cor0
----
73
73
73

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7903
SELECT CAST( cor0.col0 AS SIGNED ) AS col0 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

skipif mysql # not compatible
query I rowsort label-7903
SELECT CAST ( cor0.col0 AS INTEGER ) AS col0 FROM tab2, tab0 AS cor0 CROSS JOIN tab0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

onlyif mysql # use DIV operator for integer division
query I rowsort label-7904
SELECT ALL - ( col2 ) * 53 DIV col2 AS col0 FROM tab0
----
-53
-53
-53

skipif mysql # not compatible
query I rowsort label-7904
SELECT ALL - ( col2 ) * 53 / col2 AS col0 FROM tab0
----
-53
-53
-53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 * 62 * cor0.col1 col2 FROM tab1 AS cor0
----
39680
4836
64480

query I rowsort
SELECT + - col1 + + 14 FROM tab0 AS cor0
----
-72
-77
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + col2 * - 8 col2 FROM tab2 AS cor0
----
-130
-209
-225

query I rowsort
SELECT + + 44 FROM tab1 AS cor0
----
44
44
44

query I rowsort
SELECT DISTINCT + 15 FROM tab2
----
15

query I rowsort
SELECT ALL 49 AS col2 FROM tab2, tab2 cor0
----
9 values hashing to cb40783c0fff72e8802cdf0682e7cb55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7911
SELECT CAST( NULL AS SIGNED ) * 10 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7911
SELECT CAST ( NULL AS INTEGER ) * 10 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + ( - 97 ) AS col1 FROM tab2, tab2 cor0, tab2 AS cor1
----
27 values hashing to 12bd12d33f03250bee508c5641e140d5

query I rowsort
SELECT ALL col1 - + col1 AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT cor0.col1 * + cor0.col0 FROM tab0 AS cor0
----
2064
3395
8099

query I rowsort
SELECT - 76 * + col0 * - ( - 36 ) AS col1 FROM tab0 AS cor0
----
-243504
-65664
-95760

query I rowsort
SELECT ALL + tab0.col2 * + 37 FROM tab0
----
1221
3034
37

query I rowsort
SELECT DISTINCT + + col0 * 80 AS col2 FROM tab2 AS cor0
----
560
6240
6320

query I rowsort
SELECT - - 45 + col2 FROM tab2 cor0
----
71
72
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 30 col1 FROM tab1 AS cor0
----
30
30
30

query I rowsort
SELECT ALL col1 * + 66 AS col0 FROM tab2
----
1122
2046
3894

query I rowsort
SELECT + + col2 + - col2 * + col1 AS col0 FROM tab0 AS cor0
----
-2805
-7380
-96

query I rowsort
SELECT - col1 * 33 FROM tab1 AS cor0
----
-330
-429
-858

query I rowsort
SELECT 49 * col0 AS col0 FROM tab2 cor0
----
343
3822
3871

onlyif mysql # use DIV operator for integer division
query I rowsort label-7924
SELECT - col1 + - cor0.col1 DIV col0 FROM tab2 AS cor0
----
-17
-35
-59

skipif mysql # not compatible
query I rowsort label-7924
SELECT - col1 + - cor0.col1 / col0 FROM tab2 AS cor0
----
-17
-35
-59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - ( - cor0.col0 ) * - col2 col0 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT + col0 * 69 AS col0 FROM tab1 AS cor0
----
207
4416
5520

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 39 * ( - col1 ) col1 FROM tab2
----
-1209
-2301
-663

query I rowsort
SELECT col1 * + col1 + col2 AS col1 FROM tab1
----
157
265
730

query I rowsort
SELECT 49 + + col1 AS col1 FROM tab1
----
59
62
75

query I rowsort
SELECT 34 * col1 + col0 * - 45 * - col2 AS col0 FROM tab0 AS cor0
----
331504
38564
4873

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 85 + - ( - col2 ) col1 FROM tab2 cor0
----
-47
-58
-59

query I rowsort
SELECT 37 * + 64 + col2 FROM tab2 AS cor0
----
2394
2395
2406

query I rowsort
SELECT ALL - ( cor0.col2 ) * + col0 + - col2 FROM tab1 AS cor0
----
-216
-3705
-7776

query I rowsort
SELECT DISTINCT cor0.col2 + col0 FROM tab2 cor0
----
104
117
34

query I rowsort
SELECT - 77 * - col0 + + col2 FROM tab0 cor0
----
1881
2696
6935

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7936
SELECT ALL - col2 * + cor0.col2 + cor0.col1 * + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-7936
SELECT ALL - col2 * + cor0.col2 + cor0.col1 * + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7937
SELECT ALL - + CAST( 92 AS SIGNED ) * - col2 FROM tab2 AS cor0
----
2392
2484
3496

skipif mysql # not compatible
query I rowsort label-7937
SELECT ALL - + CAST ( 92 AS INTEGER ) * - col2 FROM tab2 AS cor0
----
2392
2484
3496

query I rowsort
SELECT cor1.col1 + ( - 23 ) AS col1 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to f80c92717f73c97aec2bb636ab48533a

query I rowsort
SELECT ( + col2 ) * - 24 FROM tab0 AS cor0
----
-1968
-24
-792

query I rowsort
SELECT 96 FROM tab0, tab1, tab2 AS cor0
----
27 values hashing to f1d978c2d5bfc6f26e0907ac777be83e

query I rowsort
SELECT DISTINCT 98 * - col1 FROM tab0
----
-8428
-8918
-9506

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 - - col0 col0 FROM tab0 cor0
----
110
132
180

query I rowsort
SELECT DISTINCT + - 7 * - col0 FROM tab0 cor0
----
168
245
623

query I rowsort
SELECT + - col1 * col2 AS col1 FROM tab2 cor0
----
-1534
-646
-837

query I rowsort
SELECT - 98 + ( col1 ) * - 97 AS col0 FROM tab1
----
-1068
-1359
-2620

query I rowsort
SELECT tab2.col0 * - col1 - - col2 * + tab2.col2 AS col2 FROM tab2
----
-3926
101
512

query I rowsort
SELECT - 55 * - cor0.col0 FROM tab0, tab2 AS cor0
----
9 values hashing to b19fd216dfa330e434e3d951022bc36d

query I rowsort
SELECT ALL - col2 + + col1 AS col1 FROM tab1 cor0
----
-28
-47
-83

onlyif mysql # use DIV operator for integer division
query I rowsort label-7949
SELECT ALL - - col2 DIV - ( col0 ) + col2 FROM tab2 AS cor0
----
24
26
38

skipif mysql # not compatible
query I rowsort label-7949
SELECT ALL - - col2 / - ( col0 ) + col2 FROM tab2 AS cor0
----
24
26
38

query I rowsort
SELECT + - col1 * ( - 35 ) + col0 FROM tab1 AS cor0
----
414
535
913

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7951
SELECT DISTINCT col0 + CAST( - 83 AS SIGNED ) FROM tab1 AS cor0
----
-19
-3
-80

skipif mysql # not compatible
query I rowsort label-7951
SELECT DISTINCT col0 + CAST ( - 83 AS INTEGER ) FROM tab1 AS cor0
----
-19
-3
-80

query I rowsort
SELECT ALL - + col2 + + col1 AS col0 FROM tab1 cor0
----
-28
-47
-83

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col2 * col2 * cor0.col2 + col0 * + CAST ( + col1 + - col2 AS REAL ) AS col1 FROM tab1 AS cor0
----
157380
182185
878096

query I rowsort
SELECT - cor0.col2 * - col1 + + 64 * - col2 AS col0 FROM tab0 AS cor0
----
2214
33
726

query I rowsort
SELECT + - col0 + + 79 * + 61 - col0 AS col1 FROM tab0 AS cor0
----
4641
4749
4771

query I rowsort
SELECT ALL - cor0.col1 + - col1 * col2 AS col0 FROM tab2 AS cor0
----
-1593
-663
-868

query I rowsort
SELECT + - col1 + - ( - cor0.col1 ) AS col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - 58 * + col1 FROM tab1
----
-1508
-580
-754

query I rowsort
SELECT 49 * tab1.col1 FROM tab1
----
1274
490
637

query I rowsort
SELECT ALL + tab1.col0 + + 67 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to d707ef9c98c6799c38d1f0842a97d741

query I rowsort
SELECT + tab2.col2 AS col1 FROM tab2, tab0, tab0 AS cor0
----
27 values hashing to 40fd8cc0de92ea68d73634c2d8f75bf5

query I rowsort
SELECT 59 * + col0 FROM tab2
----
413
4602
4661

onlyif mysql # use DIV operator for integer division
query I rowsort label-7963
SELECT ALL + 74 DIV cor0.col1 + 26 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 9d4ccf9a4b09ab5f9c109573e9aa6702

skipif mysql # not compatible
query I rowsort label-7963
SELECT ALL + 74 / cor0.col1 + 26 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 9d4ccf9a4b09ab5f9c109573e9aa6702

query I rowsort
SELECT tab1.col2 * + tab1.col0 AS col2 FROM tab1
----
162
3648
7680

query I rowsort
SELECT + + col2 * + 66 + 42 FROM tab0 AS cor0
----
108
2220
5454

query I rowsort
SELECT cor0.col0 + - 11 FROM tab1 AS cor0
----
-8
53
69

query I rowsort
SELECT DISTINCT + 0 FROM tab2, tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - 49 col1 FROM tab1 AS cor0
----
49
49
49

query I rowsort
SELECT DISTINCT + + col0 + col2 AS col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT DISTINCT - + 49 * col1 FROM tab0 AS cor0
----
-4214
-4459
-4753

query I rowsort
SELECT DISTINCT - 87 + - col0 AS col1 FROM tab0 AS cor0
----
-111
-122
-176

query I rowsort
SELECT + col2 * + col1 - 6 FROM tab1 AS cor0
----
1242
1398
564

query I rowsort
SELECT ALL tab2.col1 * col0 + ( - col2 ) FROM tab2
----
1305
190
4576

query I rowsort
SELECT ALL col0 * - col2 + col0 * + col0 + col2 AS col2 FROM tab0
----
-183
1191
705

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 54 + tab0.col1 col2 FROM tab0
----
140
145
151

onlyif mysql # use DIV operator for integer division
query I rowsort label-7976
SELECT + ( col0 ) DIV - ( + 4 ) FROM tab0
----
-22
-6
-8

skipif mysql # not compatible
query I rowsort label-7976
SELECT + ( col0 ) / - ( + 4 ) FROM tab0
----
-22
-6
-8

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-7978
SELECT col2 + + cor0.col0 + + col0 DIV + col0 FROM tab0 cor0
----
172
37
58

skipif mysql # not compatible
query I rowsort label-7978
SELECT col2 + + cor0.col0 + + col0 / + col0 FROM tab0 cor0
----
172
37
58

onlyif mysql # use DIV operator for integer division
query I rowsort label-7979
SELECT col0 DIV + tab0.col2 AS col2 FROM tab0
----
0
1
35

skipif mysql # not compatible
query I rowsort label-7979
SELECT col0 / + tab0.col2 AS col2 FROM tab0
----
0
1
35

query I rowsort
SELECT - + cor0.col2 * 78 + + col1 + + cor0.col1 FROM tab2 AS cor0
----
-1910
-2044
-2930

query I rowsort
SELECT col2 * + 67 FROM tab2 AS cor0
----
1742
1809
2546

query I rowsort
SELECT ALL - 9 FROM tab2 cor0
----
-9
-9
-9

query I rowsort
SELECT DISTINCT + ( col2 ) * + col1 + ( 47 ) AS col1 FROM tab2 AS cor0
----
1581
693
884

query I rowsort
SELECT DISTINCT + + 45 + + 12 * - col2 FROM tab1 AS cor0
----
-1107
-603
-639

query I rowsort
SELECT ALL - col1 + - col2 * - cor0.col2 * + 44 AS col0 FROM tab0 AS cor0
----
-53
295765
47830

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - + ( col1 ) col0 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT col2 + + col0 * 83 FROM tab1
----
303
5369
6736

query I rowsort
SELECT + col0 + ( ( + col0 ) ) * - col2 AS col1 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT ALL - - tab1.col1 AS col0 FROM tab1, tab2, tab1 AS cor0, tab0
----
81 values hashing to d7d3fabcafbed14f0d6ffd37195c971c

query I rowsort
SELECT col1 + 99 * + col0 * - col0 AS col0 FROM tab1
----
-405494
-633587
-865

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7991
SELECT ALL col0 + - CAST( - 20 AS SIGNED ) FROM tab2
----
27
98
99

skipif mysql # not compatible
query I rowsort label-7991
SELECT ALL col0 + - CAST ( - 20 AS INTEGER ) FROM tab2
----
27
98
99

query I rowsort
SELECT cor0.col2 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to c8f9fa9ef0f8702bd382e821378a96d8

query I rowsort
SELECT col0 + - col0 * tab2.col1 FROM tab2
----
-1264
-210
-4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-7994
SELECT ALL CAST( - ( - col0 ) * - col1 AS SIGNED ) FROM tab2
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-7994
SELECT ALL CAST ( - ( - col0 ) * - col1 AS INTEGER ) FROM tab2
----
-1343
-217
-4602

query I rowsort
SELECT ALL - col2 + - col1 * col0 AS col2 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT ALL col1 * + cor0.col2 + + col0 AS col0 FROM tab2 AS cor0
----
1612
725
844

onlyif mysql # use DIV operator for integer division
query I rowsort label-7997
SELECT DISTINCT 52 + - col0 DIV - col2 AS col2 FROM tab0 AS cor0
----
52
53
87

skipif mysql # not compatible
query I rowsort label-7997
SELECT DISTINCT 52 + - col0 / - col2 AS col2 FROM tab0 AS cor0
----
52
53
87

query I rowsort
SELECT - 22 + cor0.col1 FROM tab2 AS cor0
----
-5
37
9

query I rowsort
SELECT ALL - + ( + col1 ) + + col2 * - cor0.col2 FROM tab0 AS cor0
----
-1175
-6815
-98

query I rowsort
SELECT DISTINCT + - cor0.col1 + - 51 FROM tab1 AS cor0
----
-61
-64
-77

query I rowsort
SELECT + - 91 + + ( + col0 ) FROM tab0 AS cor0
----
-2
-56
-67

query I rowsort
SELECT ALL - col1 * col2 + + col0 * col1 AS col0 FROM tab2 AS cor0
----
-620
3068
697

query I rowsort
SELECT + ( - 62 ) FROM tab1
----
-62
-62
-62

query I rowsort
SELECT DISTINCT + ( col2 * col2 + tab0.col1 ) FROM tab0
----
1175
6815
98

query I rowsort
SELECT - ( - 43 ) FROM tab2
----
43
43
43

query I rowsort
SELECT ALL - tab0.col0 AS col1 FROM tab0, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to c3ebf1695ca74567bdc173dbe15186a8

query I rowsort
SELECT - 33 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 8035c665a75d22be5922be1a4e574e03

query I rowsort
SELECT - 14 AS col2 FROM tab1 AS cor0
----
-14
-14
-14

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8009
SELECT ALL CAST( NULL AS SIGNED ) col0 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8009
SELECT ALL CAST ( NULL AS INTEGER ) col0 FROM tab2, tab0 AS cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT ALL col2 + + col0 * 75 FROM tab2 AS cor0
----
552
5876
5963

query I rowsort
SELECT col0 * + col2 - cor0.col1 FROM tab2 AS cor0
----
158
1969
2985

query I rowsort
SELECT - col2 + col0 + - col1 * col2 AS col2 FROM tab0 AS cor0
----
-2847
-63
-7455

query I rowsort
SELECT DISTINCT cor0.col1 + ( - 61 ) FROM tab2 AS cor0
----
-2
-30
-44

query I rowsort
SELECT - + col2 + - col1 * + col2 AS col2 FROM tab1 AS cor0
----
-1344
-1458
-627

query I rowsort
SELECT - col2 + - 51 AS col0 FROM tab0 AS cor0
----
-133
-52
-84

query I rowsort
SELECT ALL - 26 * + col1 AS col2 FROM tab1 cor0
----
-260
-338
-676

onlyif mysql # use DIV operator for integer division
query I rowsort label-8017
SELECT 79 * + cor0.col0 + cor0.col1 DIV col1 FROM tab1 AS cor0
----
238
5057
6321

skipif mysql # not compatible
query I rowsort label-8017
SELECT 79 * + cor0.col0 + cor0.col1 / col1 FROM tab1 AS cor0
----
238
5057
6321

query I rowsort
SELECT - cor0.col1 * col2 + col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT + ( + 88 ) * - cor0.col2 + + col0 FROM tab0 AS cor0
----
-2880
-53
-7127

query I rowsort
SELECT - - cor0.col0 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 95b96ca1dbe2e39a0fa78f50d374f51a

query I rowsort
SELECT col2 * - col2 * 15 FROM tab1 cor0
----
-138240
-43740
-48735

query I rowsort
SELECT DISTINCT - col0 + + col2 * col0 AS col2 FROM tab2 cor0
----
182
1950
2923

onlyif mysql # use DIV operator for integer division
query I rowsort label-8023
SELECT ALL - + cor0.col1 DIV + 19 FROM tab2 AS cor0
----
-1
-3
0

skipif mysql # not compatible
query I rowsort label-8023
SELECT ALL - + cor0.col1 / + 19 FROM tab2 AS cor0
----
-1
-3
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8024
SELECT + - col2 * CAST( 24 + - col0 AS SIGNED ) FROM tab1 AS cor0
----
-1134
2280
5376

skipif mysql # not compatible
query I rowsort label-8024
SELECT + - col2 * CAST ( 24 + - col0 AS INTEGER ) FROM tab1 AS cor0
----
-1134
2280
5376

query I rowsort
SELECT + - cor0.col2 * ( + col1 * col1 ) FROM tab1 cor0
----
-16224
-36504
-5700

query I rowsort
SELECT ALL col2 + + 37 * col2 * col0 FROM tab2 AS cor0
----
111112
7020
75062

query I rowsort
SELECT cor0.col2 + - 84 * + col2 FROM tab1 AS cor0
----
-4482
-4731
-7968

query I rowsort
SELECT DISTINCT - - col2 + col0 * - col2 AS col1 FROM tab2 AS cor0
----
-162
-2002
-2964

query I rowsort
SELECT ALL - + 82 AS col2 FROM tab2 cor0
----
-82
-82
-82

query I rowsort
SELECT ( - cor0.col2 ) * 49 FROM tab0, tab1 AS cor0
----
9 values hashing to ec7b028f570e1876116d7bce8f88df12

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8031
SELECT - col1 * col0 * - CAST( col2 AS SIGNED ) FROM tab1
----
36480
4212
99840

skipif mysql # not compatible
query I rowsort label-8031
SELECT - col1 * col0 * - CAST ( col2 AS INTEGER ) FROM tab1
----
36480
4212
99840

query I rowsort
SELECT ALL + 97 AS col2 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to c73fa6978df8525c99d6bc792bb27123

query I rowsort
SELECT DISTINCT tab0.col2 + + tab0.col1 * + tab0.col1 FROM tab0
----
7429
8363
9410

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 83 col0 FROM tab1 AS cor0
----
-83
-83
-83

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 29 col1 FROM tab1
----
-29
-29
-29

query I rowsort
SELECT + ( - col2 ) * - ( col1 ) FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL + ( - col2 ) * col0 AS col2 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-8038
SELECT - 40 DIV - col0 - 2 AS col0 FROM tab1 AS cor0
----
-2
-2
11

skipif mysql # not compatible
query I rowsort label-8038
SELECT - 40 / - col0 - 2 AS col0 FROM tab1 AS cor0
----
-2
-2
11

query I rowsort
SELECT - col0 - + cor0.col2 FROM tab2 AS cor0
----
-104
-117
-34

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8040
SELECT ALL + - CAST( NULL AS SIGNED ) FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-8040
SELECT ALL + - CAST ( NULL AS INTEGER ) FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT DISTINCT col2 + + 60 + - cor0.col0 FROM tab1 AS cor0
----
111
53
76

query I rowsort
SELECT + col1 * + 46 FROM tab2 AS cor0
----
1426
2714
782

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8043
SELECT DISTINCT col2 * CAST( NULL AS SIGNED ) AS col2 FROM tab0
----
NULL

skipif mysql # not compatible
query I rowsort label-8043
SELECT DISTINCT col2 * CAST ( NULL AS INTEGER ) AS col2 FROM tab0
----
NULL

query I rowsort
SELECT - 7 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 82db7c0390abae7ccf4512b1302a6466

query I rowsort
SELECT ALL - col0 + cor0.col2 + - cor0.col2 FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-8046
SELECT ALL + col2 DIV + ( - col0 ) + - col2 col1 FROM tab1 AS cor0
----
-57
-72
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8046
SELECT ALL + col2 / + ( - col0 ) + - col2 col1 FROM tab1 AS cor0
----
-57
-72
-97

query I rowsort
SELECT + cor0.col0 + - 86 * - 93 AS col2 FROM tab1 cor0
----
8001
8062
8078

query I rowsort
SELECT DISTINCT + - col2 * cor0.col2 - col1 AS col2 FROM tab2 AS cor0
----
-1461
-735
-760

query I rowsort
SELECT DISTINCT + col2 + col2 * - col1 FROM tab1 AS cor0
----
-1152
-1350
-513

onlyif mysql # use DIV operator for integer division
query I rowsort label-8050
SELECT DISTINCT col2 + + col2 DIV 40 AS col1 FROM tab1 AS cor0
----
55
58
98

skipif mysql # not compatible
query I rowsort label-8050
SELECT DISTINCT col2 + + col2 / 40 AS col1 FROM tab1 AS cor0
----
55
58
98

query I rowsort
SELECT - ( 34 ) FROM tab0 AS cor0
----
-34
-34
-34

query I rowsort
SELECT ALL + col2 * 57 FROM tab1
----
3078
3249
5472

onlyif mysql # use DIV operator for integer division
query I rowsort label-8053
SELECT + CAST( + 51 AS SIGNED ) DIV col1 + - col0 FROM tab0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-8053
SELECT + CAST ( + 51 AS INTEGER ) / col1 + - col0 FROM tab0
----
-24
-35
-89

query I rowsort
SELECT DISTINCT - + 73 * col2 FROM tab0 AS cor0
----
-2409
-5986
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-8055
SELECT DISTINCT + col2 DIV + 97 FROM tab0 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8055
SELECT DISTINCT + col2 / + 97 FROM tab0 AS cor0
----
0

query I rowsort
SELECT + ( col2 ) * col0 AS col1 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT DISTINCT + + col2 * 38 AS col0 FROM tab1 AS cor0
----
2052
2166
3648

query I rowsort
SELECT ALL + + cor0.col0 * - col1 + - col0 AS col0 FROM tab0 AS cor0
----
-2088
-3430
-8188

query I rowsort
SELECT DISTINCT - 22 * - cor0.col1 + + cor0.col2 FROM tab2, tab2 AS cor0
----
1324
412
709

query I rowsort
SELECT DISTINCT + - cor0.col0 + col2 * col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT ALL + 13 + + col2 * col1 + - col2 AS col0 FROM tab0 AS cor0
----
109
2818
7393

query I rowsort
SELECT ALL - col1 + + col2 * col0 AS col1 FROM tab0 cor0
----
-62
706
7207

query I rowsort
SELECT DISTINCT + - ( - col1 ) - col1 AS col1 FROM tab1 AS cor0
----
0

query I rowsort
SELECT - 8 + + cor0.col0 AS col2 FROM tab0 cor0
----
16
27
81

query I rowsort
SELECT col2 + + col0 * - 39 * 88 + col1 FROM tab1 AS cor0
----
-10216
-219581
-274451

query I rowsort
SELECT + col1 * col0 + col0 * col2 AS col0 FROM tab0 AS cor0
----
15397
2856
3430

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8067
SELECT + CAST( + 39 AS SIGNED ) AS col0 FROM tab0
----
39
39
39

skipif mysql # not compatible
query I rowsort label-8067
SELECT + CAST ( + 39 AS INTEGER ) AS col0 FROM tab0
----
39
39
39

onlyif mysql # use DIV operator for integer division
query I rowsort label-8068
SELECT col0 DIV ( tab1.col1 + 96 ) AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8068
SELECT col0 / ( tab1.col1 + 96 ) AS col1 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - cor0.col1 - - col1 * col2 FROM tab0 cor0
----
0
2752
7371

query I rowsort
SELECT - - col0 * col2 + 42 AS col0 FROM tab1 AS cor0
----
204
3690
7722

query I rowsort
SELECT DISTINCT ( + col0 ) * - col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + 20 col1 FROM tab1 AS cor0
----
20
20
20

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( tab0.col2 ) * - tab0.col0 col2 FROM tab0
----
-35
-7298
-792

query I rowsort
SELECT 39 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to 5ecc4d3de68ae828a2d522dff8571cbf

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8075
SELECT + col1 / + CAST( NULL AS SIGNED ) + col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8075
SELECT + col1 / + CAST ( NULL AS INTEGER ) + col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - + col2 * + col1 AS col1 FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT DISTINCT 19 AS col1 FROM tab2, tab1 AS cor0
----
19

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8078
SELECT ALL + + col1 * CAST( NULL AS SIGNED ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8078
SELECT ALL + + col1 * CAST ( NULL AS INTEGER ) AS col1 FROM tab2 cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8079
SELECT DISTINCT - col1 DIV + 54 AS col0 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-8079
SELECT DISTINCT - col1 / + 54 AS col0 FROM tab0 AS cor0
----
-1

query I rowsort
SELECT ALL + col2 + + 60 AS col0 FROM tab0 AS cor0
----
142
61
93

onlyif mysql # use DIV operator for integer division
query I rowsort label-8081
SELECT ALL + + col1 DIV 14 FROM tab2 AS cor0
----
1
2
4

skipif mysql # not compatible
query I rowsort label-8081
SELECT ALL + + col1 / 14 FROM tab2 AS cor0
----
1
2
4

query I rowsort
SELECT + 68 FROM tab1, tab0 AS cor0, tab1 AS cor1
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8083
SELECT - CAST( col1 AS SIGNED ) + - col1 AS col2 FROM tab0 AS cor0
----
-172
-182
-194

skipif mysql # not compatible
query I rowsort label-8083
SELECT - CAST ( col1 AS INTEGER ) + - col1 AS col2 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT DISTINCT 85 FROM tab1 cor0
----
85

query I rowsort
SELECT ALL + ( - ( + col1 ) ) AS col2 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - + ( - 26 ) * - col2 + + cor0.col0 * - 79 FROM tab1 AS cor0
----
-1641
-6538
-8816

query I rowsort
SELECT - col1 + + 16 FROM tab2 AS cor0
----
-1
-15
-43

query I rowsort
SELECT col1 * col1 + col1 * - col1 FROM tab0
----
0
0
0

query I rowsort
SELECT DISTINCT + col1 * - 47 FROM tab1
----
-1222
-470
-611

onlyif mysql # use DIV operator for integer division
query I rowsort label-8090
SELECT - - col1 + col0 * cor0.col0 DIV + col0 FROM tab0 AS cor0
----
110
132
180

skipif mysql # not compatible
query I rowsort label-8090
SELECT - - col1 + col0 * cor0.col0 / + col0 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT DISTINCT 15 * col1 AS col1 FROM tab2 cor0
----
255
465
885

onlyif mysql # use DIV operator for integer division
query I rowsort label-8092
SELECT col2 DIV + col0 AS col0 FROM tab2 AS cor0
----
0
0
3

skipif mysql # not compatible
query I rowsort label-8092
SELECT col2 / + col0 AS col0 FROM tab2 AS cor0
----
0
0
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + + ( - col2 ) + col2 col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - 84 + col0 FROM tab2 cor0
----
-5
-6
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 64 col1 FROM tab2 AS cor0
----
-64

onlyif mysql # use DIV operator for integer division
query I rowsort label-8096
SELECT DISTINCT - cor0.col2 DIV + col1 AS col2 FROM tab2 AS cor0
----
-2
0

skipif mysql # not compatible
query I rowsort label-8096
SELECT DISTINCT - cor0.col2 / + col1 AS col2 FROM tab2 AS cor0
----
-2
0

query I rowsort
SELECT ALL + col1 + cor0.col2 * col0 AS col0 FROM tab2 AS cor0
----
2087
220
3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + cor0.col0 col2 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8099
SELECT 89 + col0 DIV + tab0.col1 + + 5 FROM tab0
----
94
94
94

skipif mysql # not compatible
query I rowsort label-8099
SELECT 89 + col0 / + tab0.col1 + + 5 FROM tab0
----
94
94
94

query I rowsort
SELECT ALL - ( col1 ) - - tab2.col2 * 35 AS col1 FROM tab2
----
1313
851
914

query I rowsort
SELECT col2 * cor0.col0 * ( col0 ) + col1 AS col1 FROM tab1 AS cor0
----
233482
512
614413

onlyif mysql # use DIV operator for integer division
query I rowsort label-8102
SELECT - - cor0.col2 DIV col2 AS col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8102
SELECT - - cor0.col2 / col2 AS col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT 96 + col1 * ( - cor0.col2 ) AS col1 FROM tab0 AS cor0
----
-1
-2742
-7366

query I rowsort
SELECT DISTINCT - 55 + col0 FROM tab2 AS cor0
----
-48
23
24

query I rowsort
SELECT ALL + 56 * col1 FROM tab2 cor0
----
1736
3304
952

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8106
SELECT DISTINCT CAST( NULL AS SIGNED ) col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8106
SELECT DISTINCT CAST ( NULL AS INTEGER ) col0 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
NULL

query I rowsort
SELECT - cor0.col2 * col0 + cor0.col0 * - col1 FROM tab1 AS cor0
----
-240
-4288
-8720

query I rowsort
SELECT - col0 + ( - cor0.col2 ) FROM tab1 cor0
----
-121
-176
-57

query I rowsort
SELECT + + cor0.col0 * col1 * col0 + - col2 AS col0 FROM tab1 AS cor0
----
180
40903
83104

query I rowsort
SELECT col0 * - ( col2 ) + + cor0.col1 + - cor0.col0 * col2 AS col1 FROM tab2 AS cor0
----
-347
-3997
-5987

query I rowsort
SELECT + cor0.col2 + + ( col0 ) FROM tab2 AS cor0
----
104
117
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 20 * + col0 col2 FROM tab2
----
140
1560
1580

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - 32 AS REAL ) AS col2 FROM tab0, tab2 AS cor0
----
9 values hashing to ef8f93119983b962f4c81381ebf4b1e6

query IIIIIIIIIIIIIII rowsort
SELECT DISTINCT * FROM tab2 AS cor0 CROSS JOIN tab2, tab0 AS cor1, tab1, tab0 AS cor2
----
3645 values hashing to 2566f3fa788816c8bfc482e730aaed74

query I rowsort
SELECT ( - 82 ) FROM tab0, tab1 AS cor0
----
9 values hashing to f800b0aad28b82b2deb67f7045c9a45c

query I rowsort
SELECT DISTINCT - cor0.col0 + 63 AS col1 FROM tab0 AS cor0
----
-26
28
39

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8117
SELECT - - col1 + CAST( - 40 AS SIGNED ) FROM tab2 AS cor0
----
-23
-9
19

skipif mysql # not compatible
query I rowsort label-8117
SELECT - - col1 + CAST ( - 40 AS INTEGER ) FROM tab2 AS cor0
----
-23
-9
19

query I rowsort
SELECT - col1 + col0 * col2 AS col1 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT - col2 * 18 AS col0 FROM tab1 AS cor0
----
-1026
-1728
-972

query I rowsort
SELECT + 20 + + col1 * - col1 FROM tab2 AS cor0
----
-269
-3461
-941

query I rowsort
SELECT DISTINCT + tab2.col0 + col2 * + col0 FROM tab2
----
196
2106
3081

query I rowsort
SELECT ALL - col0 * cor0.col1 * - cor0.col2 AS col1 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT 63 * ( - col1 ) FROM tab0 AS cor0
----
-5418
-5733
-6111

query I rowsort
SELECT ALL 88 * + col2 * + 25 + - cor0.col0 * + cor0.col1 AS col1 FROM tab1 AS cor0
----
118722
124760
210160

query I rowsort
SELECT ALL 82 * col0 AS col2 FROM tab2 AS cor0
----
574
6396
6478

query I rowsort
SELECT DISTINCT 80 FROM tab1, tab0, tab0 AS cor0
----
80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + col1 * - cor0.col1 col2 FROM tab1 AS cor0
----
-100
-169
-676

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8128
SELECT + + CAST( NULL AS SIGNED ) * - col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8128
SELECT + + CAST ( NULL AS INTEGER ) * - col0 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 * + col2 + - col1 * - 38 * - col2 FROM tab0 AS cor0
----
-105006
-276094
-3589

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + 14 * col0 - + 56 col0 FROM tab1 AS cor0
----
-68
783
968

query I rowsort
SELECT DISTINCT - 96 * col0 + + tab1.col2 FROM tab1
----
-234
-6087
-7584

query I rowsort
SELECT - ( col0 ) + col1 AS col1 FROM tab0 AS cor0
----
2
62
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - 15 + - ( col2 ) col0 FROM tab0 AS cor0
----
-16
-48
-97

query I rowsort
SELECT - col0 * col0 + + col1 * 17 AS col2 FROM tab2 AS cor0
----
-5081
-5952
478

query I rowsort
SELECT + - col2 + - col2 + col1 * + ( col0 ) * col1 FROM tab1 AS cor0
----
13328
1920
6286

query I rowsort
SELECT ALL col1 + + col0 * ( cor0.col1 ) FROM tab1 AS cor0
----
104
1053
650

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + + cor0.col1 * col2 col0 FROM tab2 AS cor0
----
1534
646
837

query I rowsort
SELECT ALL col1 * - col1 - - 24 * - col1 AS col1 FROM tab0 AS cor0
----
-10465
-11737
-9460

query I rowsort
SELECT ALL - cor0.col0 FROM tab0 cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 09d8a912de1b8ab762e5ffbe028ce99e

onlyif mysql # use DIV operator for integer division
query I rowsort label-8140
SELECT + col0 * col2 - + col2 DIV col0 AS col0 FROM tab2 AS cor0
----
186
2028
3002

skipif mysql # not compatible
query I rowsort label-8140
SELECT + col0 * col2 - + col2 / col0 AS col0 FROM tab2 AS cor0
----
186
2028
3002

query I rowsort
SELECT tab2.col0 * ( 18 * + tab2.col1 ) FROM tab2
----
24174
3906
82836

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 * + tab0.col2 col1 FROM tab0
----
1
1089
6724

query I rowsort
SELECT ALL + - 90 AS col0 FROM tab0 AS cor0
----
-90
-90
-90

query I rowsort
SELECT DISTINCT + cor0.col0 + - 55 FROM tab1 AS cor0
----
-52
25
9

query I rowsort
SELECT - ( cor0.col1 ) FROM tab2, tab1 cor0
----
9 values hashing to b234798d4706314ba14eaad539d0aa88

query I rowsort
SELECT col1 + + col1 - 63 FROM tab2
----
-1
-29
55

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8147
SELECT + + col2 * CAST( + col0 AS SIGNED ) FROM tab2 AS cor0
----
189
2028
3002

skipif mysql # not compatible
query I rowsort label-8147
SELECT + + col2 * CAST ( + col0 AS INTEGER ) FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-8148
SELECT + col1 DIV 25 FROM tab2
----
0
1
2

skipif mysql # not compatible
query I rowsort label-8148
SELECT + col1 / 25 FROM tab2
----
0
1
2

onlyif mysql # use DIV operator for integer division
query I rowsort label-8149
SELECT - col0 * tab0.col2 DIV tab0.col1 AS col0 FROM tab0
----
-80
-9
0

skipif mysql # not compatible
query I rowsort label-8149
SELECT - col0 * tab0.col2 / tab0.col1 AS col0 FROM tab0
----
-80
-9
0

query I rowsort
SELECT + tab2.col1 * 16 AS col0 FROM tab2
----
272
496
944

query I rowsort
SELECT - tab2.col1 * + 88 AS col1 FROM tab2, tab2 AS cor0
----
9 values hashing to f9a0144c5d5067925309551e258fd248

query I rowsort
SELECT ALL + tab1.col0 * col0 - 29 FROM tab1
----
-20
4067
6371

query I rowsort
SELECT DISTINCT 12 * col0 FROM tab2 AS cor0
----
84
936
948

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8154
SELECT + CAST( NULL AS SIGNED ) + + 9 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8154
SELECT + CAST ( NULL AS INTEGER ) + + 9 AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + 6 + - cor0.col1 FROM tab2 AS cor0
----
-11
-25
-53

query I rowsort
SELECT DISTINCT - cor0.col1 - col0 AS col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT - + 58 + 30 FROM tab2 AS cor0
----
-28
-28
-28

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * - 54 + col2 + col1 col2 FROM tab1
----
1484
607
811

query I rowsort
SELECT DISTINCT col2 + + 60 AS col2 FROM tab2
----
86
87
98

query I rowsort
SELECT DISTINCT + col0 * + col2 * col2 + + tab0.col0 AS col1 FROM tab0
----
26160
598525
70

query I rowsort
SELECT ALL 59 + + col2 FROM tab2
----
85
86
97

query I rowsort
SELECT DISTINCT + ( 72 ) * + col2 + ( - col1 ) AS col0 FROM tab1 AS cor0
----
3862
4094
6899

query I rowsort
SELECT ALL + 62 + - col1 * col1 FROM tab2 AS cor0
----
-227
-3419
-899

query I rowsort
SELECT ALL - cor0.col1 FROM tab0, tab1 cor0, tab2 AS cor1
----
27 values hashing to c7890469eabb2c6fc81454b35d2333b6

query I rowsort
SELECT DISTINCT - col0 + + col0 * col0 + + col0 AS col1 FROM tab2 cor0
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-8166
SELECT ALL 88 * + col0 DIV col0 FROM tab2 AS cor0
----
88
88
88

skipif mysql # not compatible
query I rowsort label-8166
SELECT ALL 88 * + col0 / col0 FROM tab2 AS cor0
----
88
88
88

query I rowsort
SELECT 47 - - ( col1 ) * - col1 FROM tab1 cor0
----
-122
-53
-629

query I rowsort
SELECT 84 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT - col0 - tab0.col1 * 11 * col1 AS col1 FROM tab0
----
-103534
-81380
-91180

query I rowsort
SELECT + 27 AS col2 FROM tab1, tab0, tab0 AS cor0
----
27 values hashing to 1a3cef5c33b8f87ffeded378fd207753

query I rowsort
SELECT tab1.col0 AS col2 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 778b50575a9b91448119ee0ee1a9c44f

query I rowsort
SELECT + 27 + + col0 * col1 FROM tab0
----
2091
3422
8126

query I rowsort
SELECT - 3 + - col0 * col2 AS col0 FROM tab2 AS cor0
----
-192
-2031
-3005

onlyif mysql # use DIV operator for integer division
query I rowsort label-8174
SELECT - tab0.col1 * col1 + + col1 DIV col1 FROM tab0
----
-7395
-8280
-9408

skipif mysql # not compatible
query I rowsort label-8174
SELECT - tab0.col1 * col1 + + col1 / col1 FROM tab0
----
-7395
-8280
-9408

query I rowsort
SELECT + 76 * + col2 FROM tab0
----
2508
6232
76

query I rowsort
SELECT ALL + col0 + - 42 AS col1 FROM tab1 AS cor0
----
-39
22
38

skipif mysql # not compatible
query I rowsort
SELECT ALL col0 + CAST ( - col2 * col1 AS REAL ) FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT + - col0 * 55 - col1 FROM tab1 AS cor0
----
-191
-3530
-4413

query I rowsort
SELECT + col1 + col0 * - col1 AS col2 FROM tab1 AS cor0
----
-1027
-52
-630

query I rowsort
SELECT DISTINCT + + col2 - + 61 AS col1 FROM tab2 AS cor0
----
-23
-34
-35

query I rowsort
SELECT ALL - col1 + - 79 * - 3 FROM tab0 cor0
----
140
146
151

query I rowsort
SELECT DISTINCT + + col0 + col2 * 36 * col0 AS col0 FROM tab0 AS cor0
----
1295
262817
28536

query I rowsort
SELECT - - col1 * + 35 FROM tab1 AS cor0
----
350
455
910

onlyif mysql # use DIV operator for integer division
query I rowsort label-8184
SELECT ALL col0 DIV - 73 + col0 FROM tab1 AS cor0
----
3
64
79

skipif mysql # not compatible
query I rowsort label-8184
SELECT ALL col0 / - 73 + col0 FROM tab1 AS cor0
----
3
64
79

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 * col0 + - 2 * - cor0.col1 col2 FROM tab2 AS cor0
----
1377
279
4720

query I rowsort
SELECT 96 AS col2 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 22c5141a629f0ef396738ee2c8be6303

onlyif mysql # use DIV operator for integer division
query I rowsort label-8187
SELECT ALL tab2.col2 DIV CAST( - col0 AS SIGNED ) FROM tab2
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-8187
SELECT ALL tab2.col2 / CAST ( - col0 AS INTEGER ) FROM tab2
----
-3
0
0

query I rowsort
SELECT + cor0.col0 + ( 4 ) FROM tab2 AS cor0
----
11
82
83

query I rowsort
SELECT 68 AS col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 599bee15ac4cc39b859854e07dfe7990

query I rowsort
SELECT + 93 + - tab1.col2 AS col0 FROM tab1, tab0 AS cor0
----
9 values hashing to 2ac7e30f7797373bc416b67d4ef0cd00

query I rowsort
SELECT + - col0 * + 77 + col2 * cor0.col1 FROM tab2 cor0
----
-4472
-5437
298

query I rowsort
SELECT ALL + 55 AS col0 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 832128adb1ddc65c3105e29cc2c8b3a3

query I rowsort
SELECT 87 * - cor0.col0 AS col2 FROM tab0, tab0 cor0
----
9 values hashing to 2386a026b72b8025d009218451fb0918

query I rowsort
SELECT ALL - col1 * 20 + cor0.col1 AS col2 FROM tab2 cor0
----
-1121
-323
-589

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 + + col2 col2 FROM tab1
----
108
114
192

query I rowsort
SELECT + 59 + + col0 + + tab1.col0 FROM tab1
----
187
219
65

query I rowsort
SELECT DISTINCT + + ( - col1 ) * col0 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + + col2 * - col1 - cor0.col1 FROM tab1 AS cor0
----
-1261
-1430
-580

query I rowsort
SELECT + col0 * 15 * - col1 FROM tab0 AS cor0
----
-121485
-30960
-50925

query I rowsort
SELECT DISTINCT ( 68 ) FROM tab1 cor0
----
68

query I rowsort
SELECT ALL + 76 + + cor0.col0 * - col1 FROM tab2 AS cor0
----
-1267
-141
-4526

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * col0 col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT ALL + 25 * + col1 * + cor0.col1 AS col0 FROM tab2 AS cor0
----
24025
7225
87025

query I rowsort
SELECT + cor0.col1 * - col2 + col1 AS col1 FROM tab1 AS cor0
----
-1235
-1378
-560

query I rowsort
SELECT ALL + + 12 * + col1 FROM tab1 AS cor0
----
120
156
312

query I rowsort
SELECT DISTINCT - + ( col2 ) * col2 + col2 AS col0 FROM tab1 AS cor0
----
-2862
-3192
-9120

onlyif mysql # use DIV operator for integer division
query I rowsort label-8207
SELECT - col1 DIV + col0 + + col1 AS col0 FROM tab2 AS cor0
----
17
27
59

skipif mysql # not compatible
query I rowsort label-8207
SELECT - col1 / + col0 + + col1 AS col0 FROM tab2 AS cor0
----
17
27
59

query I rowsort
SELECT - + 31 + + col2 FROM tab1 AS cor0
----
23
26
65

query I rowsort
SELECT DISTINCT ( col0 ) + - ( 65 ) FROM tab2 AS cor0
----
-58
13
14

query I rowsort
SELECT - - ( - col0 ) + col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT + + ( + col2 ) + - col2 AS col2 FROM tab2 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + col0 - col2 col0 FROM tab1 cor0
----
-16
-51
7

query I rowsort
SELECT + - col1 + + col0 * + ( + col1 + - col1 ) * cor0.col2 FROM tab1 AS cor0
----
-10
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-8214
SELECT ALL + ( tab2.col1 ) DIV + col0 + col0 * + col0 FROM tab2
----
53
6084
6241

skipif mysql # not compatible
query I rowsort label-8214
SELECT ALL + ( tab2.col1 ) / + col0 + col0 * + col0 FROM tab2
----
53
6084
6241

query I rowsort
SELECT + - col0 * col1 + col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT + - col0 * col0 - col0 AS col0 FROM tab1 AS cor0
----
-12
-4160
-6480

query I rowsort
SELECT DISTINCT + col1 - - col2 * tab2.col1 FROM tab2
----
1593
663
868

onlyif mysql # use DIV operator for integer division
query I rowsort label-8218
SELECT - 34 - - col1 DIV + col1 AS col0 FROM tab1 AS cor0
----
-33
-33
-33

skipif mysql # not compatible
query I rowsort label-8218
SELECT - 34 - - col1 / + col1 AS col0 FROM tab1 AS cor0
----
-33
-33
-33

query IIIIIIIIIIII rowsort
SELECT * FROM tab2, tab0, tab1 cor0, tab0 cor1
----
972 values hashing to 5e655b1287771868a8f868574a94d749

query I rowsort
SELECT DISTINCT + cor0.col1 FROM tab2, tab1, tab1 AS cor0
----
10
13
26

query I rowsort
SELECT 37 * col0 AS col0 FROM tab0 cor0
----
1295
3293
888

query I rowsort
SELECT - 86 * col0 FROM tab1 AS cor0
----
-258
-5504
-6880

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * + ( + 77 ) + cor0.col0 col0 FROM tab2 AS cor0
----
-1230
-2380
-4465

query I rowsort
SELECT DISTINCT col0 * col1 - col1 FROM tab0 cor0
----
1978
3298
8008

query I rowsort
SELECT - + col0 * - cor0.col2 + 78 AS col0 FROM tab1 AS cor0
----
240
3726
7758

query I rowsort
SELECT - col2 + ( + col2 ) + col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT col1 * 19 AS col2 FROM tab1 AS cor0
----
190
247
494

query I rowsort
SELECT col0 * col1 * + ( - ( + col0 ) ) AS col1 FROM tab2
----
-106097
-1519
-358956

onlyif mysql # use DIV operator for integer division
query I rowsort label-8229
SELECT DISTINCT + 12 DIV + tab0.col2 AS col0 FROM tab0
----
0
12

skipif mysql # not compatible
query I rowsort label-8229
SELECT DISTINCT + 12 / + tab0.col2 AS col0 FROM tab0
----
0
12

query I rowsort
SELECT DISTINCT - tab2.col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-8231
SELECT + ( - col0 ) DIV 53 AS col2 FROM tab1
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-8231
SELECT + ( - col0 ) / 53 AS col2 FROM tab1
----
-1
-1
0

query I rowsort
SELECT + 78 FROM tab0 cor0
----
78
78
78

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8233
SELECT + CAST( NULL AS SIGNED ) * 24 * col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8233
SELECT + CAST ( NULL AS INTEGER ) * 24 * col2 AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 41 + 78 col1 FROM tab0 AS cor0
----
37
37
37

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8235
SELECT + - CAST( + col0 AS SIGNED ) * cor0.col2 FROM tab0 AS cor0
----
-35
-7298
-792

skipif mysql # not compatible
query I rowsort label-8235
SELECT + - CAST ( + col0 AS INTEGER ) * cor0.col2 FROM tab0 AS cor0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-8236
SELECT DISTINCT col1 DIV - CAST( + col2 * col0 AS SIGNED ) AS col1 FROM tab1
----
0

skipif mysql # not compatible
query I rowsort label-8236
SELECT DISTINCT col1 / - CAST ( + col2 * col0 AS INTEGER ) AS col1 FROM tab1
----
0

query I rowsort
SELECT ALL - 32 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to ef8f93119983b962f4c81381ebf4b1e6

query I rowsort
SELECT ALL 29 AS col1 FROM tab0 AS cor0
----
29
29
29

query I rowsort
SELECT 50 FROM tab2, tab0 cor0
----
9 values hashing to dea2d1b74e0cdf67806af8c417324f52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - 89 col1 FROM tab0 AS cor0
----
-89
-89
-89

query I rowsort
SELECT 26 * - col1 FROM tab1 AS cor0
----
-260
-338
-676

skipif mysql # not compatible
query I rowsort
SELECT ALL + CAST ( cor0.col2 AS REAL ) * col1 FROM tab1 AS cor0
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + tab2.col0 * col0 col1 FROM tab2
----
49
6084
6241

onlyif mysql # use DIV operator for integer division
query I rowsort label-8244
SELECT - col2 DIV CAST( + col1 AS SIGNED ) FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8244
SELECT - col2 / CAST ( + col1 AS INTEGER ) FROM tab0
----
0
0
0

query I rowsort
SELECT ALL + col2 - + col1 AS col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT col1 * + col2 + + col2 * col2 AS col1 FROM tab1 AS cor0
----
10464
3819
4320

query I rowsort
SELECT cor0.col1 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT ALL + col1 - 68 FROM tab2
----
-37
-51
-9

query I rowsort
SELECT col1 - - tab2.col1 * 85 AS col2 FROM tab2
----
1462
2666
5074

query I rowsort
SELECT tab0.col1 - + 12 FROM tab0
----
74
79
85

onlyif mysql # use DIV operator for integer division
query I rowsort label-8251
SELECT 99 DIV - col0 AS col1 FROM tab2 AS cor0
----
-1
-1
-14

skipif mysql # not compatible
query I rowsort label-8251
SELECT 99 / - col0 AS col1 FROM tab2 AS cor0
----
-1
-1
-14

query I rowsort
SELECT 67 + + col1 FROM tab2 AS cor0
----
126
84
98

query I rowsort
SELECT + ( 82 ) + col0 AS col1 FROM tab0
----
106
117
171

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 53 col0 FROM tab2, tab1 AS cor0
----
53

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col1 ) + col2 col2 FROM tab0 cor0
----
119
173
98

query I rowsort
SELECT - col1 * + col1 + + col1 * cor0.col2 FROM tab2 cor0
----
-124
-1947
357

query I rowsort
SELECT + + 73 * col1 - col0 * col1 FROM tab2 AS cor0
----
-102
-295
2046

query I rowsort
SELECT ALL - 9 + col0 FROM tab2 AS cor0
----
-2
69
70

query I rowsort
SELECT DISTINCT + 10 + col1 * col1 AS col2 FROM tab2 AS cor0
----
299
3491
971

query I rowsort
SELECT - cor0.col2 + + col2 * + col1 FROM tab1 AS cor0
----
1152
1350
513

query I rowsort
SELECT ALL + 13 + - col2 FROM tab0 cor0
----
-20
-69
12

query I rowsort
SELECT 61 + + cor0.col1 FROM tab2 cor0
----
120
78
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-8263
SELECT ALL - col2 + + col1 DIV cor0.col2 FROM tab1 AS cor0
----
-54
-57
-96

skipif mysql # not compatible
query I rowsort label-8263
SELECT ALL - col2 + + col1 / cor0.col2 FROM tab1 AS cor0
----
-54
-57
-96

query I rowsort
SELECT + 81 + col0 AS col1 FROM tab2 cor0
----
159
160
88

query I rowsort
SELECT DISTINCT + col0 * + 83 + + col2 FROM tab0 AS cor0
----
2025
2906
7469

query I rowsort
SELECT DISTINCT - col1 + - 44 FROM tab2 cor0
----
-103
-61
-75

query I rowsort
SELECT ALL ( + ( - col1 ) ) + + col2 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT + col2 * - 96 FROM tab0 AS cor0
----
-3168
-7872
-96

query I rowsort
SELECT + cor0.col1 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to c61d27a0022e6d022371dc58819ab272

query I rowsort
SELECT + + 20 * col1 FROM tab1 AS cor0
----
200
260
520

query I rowsort
SELECT cor0.col2 + ( col1 ) * + col1 FROM tab2 cor0
----
327
3507
988

query I rowsort
SELECT col1 + - ( 31 ) FROM tab1 AS cor0
----
-18
-21
-5

query I rowsort
SELECT DISTINCT + tab0.col1 AS col0 FROM tab0, tab0 AS cor0, tab1 AS cor1
----
86
91
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8274
SELECT DISTINCT - + col1 + + CAST( NULL AS SIGNED ) - - col0 * + col0 AS col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8274
SELECT DISTINCT - + col1 + + CAST ( NULL AS INTEGER ) - - col0 * + col0 AS col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + cor0.col0 + - 75 AS col1 FROM tab1 AS cor0
----
-11
-72
5

query I rowsort
SELECT - + col0 + 34 * - cor0.col0 FROM tab2 AS cor0
----
-245
-2730
-2765

query I rowsort
SELECT DISTINCT col1 + - 64 FROM tab1 AS cor0
----
-38
-51
-54

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8278
SELECT ALL cor0.col2 * 59 + + cor0.col0 - col2 * - CAST( NULL AS SIGNED ) FROM tab1 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8278
SELECT ALL cor0.col2 * 59 + + cor0.col0 - col2 * - CAST ( NULL AS INTEGER ) FROM tab1 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + col0 * cor0.col2 * col1 FROM tab0 AS cor0
----
3430
664207
68136

query I rowsort
SELECT DISTINCT - cor0.col1 * - col0 AS col0 FROM tab1 AS cor0
----
1040
640
78

query I rowsort
SELECT col0 * 50 AS col2 FROM tab0 AS cor0
----
1200
1750
4450

query I rowsort
SELECT col2 + ( + 76 ) * - cor0.col1 FROM tab2 AS cor0
----
-1254
-2329
-4458

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8283
SELECT - - col2 / + CAST( NULL AS DECIMAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8283
SELECT - - col2 / + CAST ( NULL AS REAL ) AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8284
SELECT DISTINCT - col1 DIV 6 FROM tab2 AS cor0
----
-2
-5
-9

skipif mysql # not compatible
query I rowsort label-8284
SELECT DISTINCT - col1 / 6 FROM tab2 AS cor0
----
-2
-5
-9

query I rowsort
SELECT - col1 + + cor0.col1 * - col1 FROM tab1 AS cor0
----
-110
-182
-702

query I rowsort
SELECT ALL col1 * + ( - col2 * - col1 ) FROM tab0 AS cor0
----
244068
679042
9409

onlyif mysql # use DIV operator for integer division
query I rowsort label-8287
SELECT col0 + col1 DIV 11 FROM tab0 AS cor0
----
31
43
97

skipif mysql # not compatible
query I rowsort label-8287
SELECT col0 + col1 / 11 FROM tab0 AS cor0
----
31
43
97

query I rowsort
SELECT DISTINCT - 92 FROM tab0, tab1 cor0
----
-92

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 50 col2 FROM tab1 cor0 CROSS JOIN tab2, tab2 cor1, tab1 cor2
----
81 values hashing to 6932c991110d256d3f92f3e9538f8040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 78 col1 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to d8e5ef4db3419fc251e82c50ba04e048

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8291
SELECT DISTINCT - CAST( col2 AS SIGNED ) * cor0.col1 col0 FROM tab0 AS cor0
----
-2838
-7462
-97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8291
SELECT DISTINCT - CAST ( col2 AS INTEGER ) * cor0.col1 col0 FROM tab0 AS cor0
----
-2838
-7462
-97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8292
SELECT + CAST( - col1 AS SIGNED ) DIV - col1 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8292
SELECT + CAST ( - col1 AS INTEGER ) / - col1 AS col0 FROM tab1 AS cor0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT cor1.col1 col1 FROM tab2 AS cor0 CROSS JOIN tab2 AS cor1
----
17
31
59

onlyif mysql # use DIV operator for integer division
query I rowsort label-8294
SELECT + + 54 DIV - col0 FROM tab2 AS cor0
----
-7
0
0

skipif mysql # not compatible
query I rowsort label-8294
SELECT + + 54 / - col0 FROM tab2 AS cor0
----
-7
0
0

query I rowsort
SELECT DISTINCT + 6 * col2 AS col1 FROM tab1 cor0
----
324
342
576

query I rowsort
SELECT ALL - 24 FROM tab0, tab0 cor0, tab2 AS cor1
----
27 values hashing to f2e40f6e5cdbc2877843191cb261975f

query I rowsort
SELECT DISTINCT + - col2 + + col0 + 84 AS col0 FROM tab0 AS cor0
----
118
75
91

query I rowsort
SELECT ALL - col0 + col2 AS col1 FROM tab0 cor0
----
-34
-7
9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8299
SELECT - col1 + - col1 DIV col0 AS col2 FROM tab2
----
-17
-35
-59

skipif mysql # not compatible
query I rowsort label-8299
SELECT - col1 + - col1 / col0 AS col2 FROM tab2
----
-17
-35
-59

query I rowsort
SELECT 75 + col0 + + col2 AS col0 FROM tab0
----
111
132
246

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( - cor0.col2 ) col0 FROM tab2, tab0 AS cor0
----
9 values hashing to b5a4102107e5ebd26e341538f4fede1e

onlyif mysql # use DIV operator for integer division
query I rowsort label-8302
SELECT ALL col1 DIV 90 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8302
SELECT ALL col1 / 90 FROM tab1
----
0
0
0

query I rowsort
SELECT ALL - col1 * - tab1.col1 AS col1 FROM tab1
----
100
169
676

query I rowsort
SELECT ALL - col2 * col0 * 62 + - col1 FROM tab1
----
-10070
-226186
-476173

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + - col1 col2 FROM tab2
----
-33
-4
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-8306
SELECT 1 DIV - col2 + + ( + col2 + tab0.col1 ) AS col2 FROM tab0
----
119
173
97

skipif mysql # not compatible
query I rowsort label-8306
SELECT 1 / - col2 + + ( + col2 + tab0.col1 ) AS col2 FROM tab0
----
119
173
97

query I rowsort
SELECT 26 + col1 * ( + col0 ) FROM tab0
----
2090
3421
8125

query I rowsort
SELECT DISTINCT + ( col1 ) * - col0 AS col2 FROM tab0 cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-8309
SELECT ALL + ( + 73 ) + cor0.col2 DIV - 82 FROM tab1 AS cor0
----
72
73
73

skipif mysql # not compatible
query I rowsort label-8309
SELECT ALL + ( + 73 ) + cor0.col2 / - 82 FROM tab1 AS cor0
----
72
73
73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - ( + 53 ) + - col2 col1 FROM tab0
----
-4591
-4905
-5142

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 66 col1 FROM tab2, tab0 AS cor0
----
66

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( col1 * - col2 ) + - 84 col1 FROM tab1
----
-1332
-1488
-654

query I rowsort
SELECT DISTINCT col2 * - col2 + - col2 AS col0 FROM tab2
----
-1482
-702
-756

query I rowsort
SELECT ALL - col2 * - 83 FROM tab2 cor0
----
2158
2241
3154

onlyif mysql # use DIV operator for integer division
query I rowsort label-8315
SELECT 56 DIV col2 + col2 + CAST( + col2 + - col2 * 26 AS SIGNED ) FROM tab0
----
-1968
-791
32

skipif mysql # not compatible
query I rowsort label-8315
SELECT 56 / col2 + col2 + CAST ( + col2 + - col2 * 26 AS INTEGER ) FROM tab0
----
-1968
-791
32

onlyif mysql # use DIV operator for integer division
query I rowsort label-8316
SELECT DISTINCT col0 DIV + tab0.col0 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-8316
SELECT DISTINCT col0 / + tab0.col0 FROM tab0
----
1

query I rowsort
SELECT + 16 AS col1 FROM tab1
----
16
16
16

query I rowsort
SELECT - 78 AS col2 FROM tab2, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to c4f3c63f98c3c08f2848f46850a476d4

query I rowsort
SELECT DISTINCT col2 + 83 + - col1 FROM tab1
----
111
130
166

query I rowsort
SELECT ALL - col1 * 34 FROM tab2 AS cor0
----
-1054
-2006
-578

query I rowsort
SELECT DISTINCT - - col0 * cor0.col0 + 67 * + col2 AS col0 FROM tab2 AS cor0
----
1858
7826
8787

query I rowsort
SELECT DISTINCT + col1 * 29 FROM tab1 AS cor0
----
290
377
754

query I rowsort
SELECT ALL + col2 + ( ( col1 ) ) FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT ALL - col0 * 72 FROM tab0 AS cor0
----
-1728
-2520
-6408

query I rowsort
SELECT ALL + col1 * + ( col1 ) + - col1 FROM tab1 AS cor0
----
156
650
90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8326
SELECT ALL - col1 * CAST( - col1 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
289
3481
961

skipif mysql # not compatible
query I rowsort label-8326
SELECT ALL - col1 * CAST ( - col1 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
289
3481
961

query I rowsort
SELECT + + col2 + 40 FROM tab1 AS cor0
----
136
94
97

query I rowsort
SELECT ALL - cor0.col1 * ( - ( + col0 ) ) - cor0.col0 AS col0 FROM tab2 cor0
----
1264
210
4524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8329
SELECT cor0.col0 * CAST( 97 AS SIGNED ) FROM tab0 AS cor0
----
2328
3395
8633

skipif mysql # not compatible
query I rowsort label-8329
SELECT cor0.col0 * CAST ( 97 AS INTEGER ) FROM tab0 AS cor0
----
2328
3395
8633

query I rowsort
SELECT col1 * - ( - cor0.col0 ) * cor0.col0 FROM tab2 cor0
----
106097
1519
358956

skipif mysql # not compatible
query I rowsort
SELECT ALL + col0 * + CAST ( - 19 AS REAL ) + + col2 FROM tab2 AS cor0
----
-106
-1456
-1463

query I rowsort
SELECT DISTINCT - - col2 * 78 AS col1 FROM tab0 AS cor0
----
2574
6396
78

query I rowsort
SELECT 36 * + cor0.col2 + col2 * + col2 * + col1 FROM tab2 AS cor0
----
23571
25916
40820

query I rowsort
SELECT - + 80 + ( - col0 ) AS col1 FROM tab1 AS cor0
----
-144
-160
-83

query I rowsort
SELECT + + 33 + 36 AS col2 FROM tab1 AS cor0
----
69
69
69

query I rowsort
SELECT + col1 * 6 - - col2 AS col2 FROM tab1 cor0
----
117
174
210

query I rowsort
SELECT ( - 4 ) + - col0 * col0 AS col2 FROM tab1 AS cor0
----
-13
-4100
-6404

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + cor0.col1 * col1 col1 FROM tab0 AS cor0
----
-7396
-8281
-9409

query I rowsort
SELECT DISTINCT 27 * col0 + cor0.col1 FROM tab0 AS cor0
----
1042
2494
734

query I rowsort
SELECT DISTINCT - col1 + - cor0.col2 * 0 AS col2 FROM tab2 AS cor0
----
-17
-31
-59

query I rowsort
SELECT 64 * + col0 FROM tab0 AS cor0
----
1536
2240
5696

query I rowsort
SELECT ALL + col1 + + col1 * - col0 FROM tab0 cor0
----
-1978
-3298
-8008

query I rowsort
SELECT DISTINCT + col1 * tab1.col0 * - col1 FROM tab1
----
-13520
-2028
-6400

query I rowsort
SELECT - cor0.col0 * + col0 FROM tab1 cor0
----
-4096
-6400
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-8345
SELECT - 74 DIV col0 FROM tab0 cor0
----
-2
-3
0

skipif mysql # not compatible
query I rowsort label-8345
SELECT - 74 / col0 FROM tab0 cor0
----
-2
-3
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8346
SELECT 17 + col0 DIV col1 AS col1 FROM tab2 AS cor0
----
17
18
21

skipif mysql # not compatible
query I rowsort label-8346
SELECT 17 + col0 / col1 AS col1 FROM tab2 AS cor0
----
17
18
21

onlyif mysql # use DIV operator for integer division
query I rowsort label-8347
SELECT col2 * col0 + 15 DIV 32 AS col2 FROM tab0 cor0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-8347
SELECT col2 * col0 + 15 / 32 AS col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT 8 * col2 + col0 AS col0 FROM tab0 AS cor0
----
288
43
745

query I rowsort
SELECT DISTINCT - + cor0.col0 * col0 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

query I rowsort
SELECT DISTINCT col2 + - col1 AS col1 FROM tab2 cor0
----
-33
-4
21

query I rowsort
SELECT ALL - col1 * col2 + col0 FROM tab0 AS cor0
----
-2814
-62
-7373

onlyif mysql # use DIV operator for integer division
query I rowsort label-8352
SELECT DISTINCT + col1 + cor0.col0 DIV CAST( col0 * col0 AS SIGNED ) col2 FROM tab0 AS cor0
----
86
91
97

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8352
SELECT DISTINCT + col1 + cor0.col0 / CAST ( col0 * col0 AS INTEGER ) col2 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - - 39 * - col2 FROM tab1 cor0
----
-2106
-2223
-3744

query I rowsort
SELECT ALL col0 * + col1 * + 9 FROM tab2 AS cor0
----
12087
1953
41418

query I rowsort
SELECT DISTINCT 98 + cor0.col1 * - ( - col1 ) * col2 AS col2 FROM tab2 AS cor0
----
11080
26045
90604

query I rowsort
SELECT 87 * + col1 AS col2 FROM tab0 AS cor0
----
7482
7917
8439

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( col2 ) + - col1 col1 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT ALL - ( - cor0.col2 ) * - cor0.col2 AS col0 FROM tab2 cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL - - cor0.col2 + - col2 FROM tab0 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT ( 73 * + col1 ) col0 FROM tab0
----
6278
6643
7081

query I rowsort
SELECT + col2 + + 54 FROM tab1
----
108
111
150

query I rowsort
SELECT DISTINCT - 78 * tab2.col1 FROM tab2, tab0 AS cor0
----
-1326
-2418
-4602

onlyif mysql # use DIV operator for integer division
query I rowsort label-8363
SELECT ALL col0 + col0 DIV ( col1 ) col1 FROM tab2 AS cor0
----
7
79
83

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8363
SELECT ALL col0 + col0 / ( col1 ) col1 FROM tab2 AS cor0
----
7
79
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-8364
SELECT DISTINCT 21 DIV - col0 col1 FROM tab0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8364
SELECT DISTINCT 21 / - col0 col1 FROM tab0
----
0

query I rowsort
SELECT cor1.col1 AS col0 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT - col1 + - cor0.col2 * col1 FROM tab2 AS cor0
----
-1593
-663
-868

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - 71 col2 FROM tab1
----
-125
-128
-167

query I rowsort
SELECT cor0.col1 + cor0.col0 AS col1 FROM tab2 AS cor0
----
137
38
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8369
SELECT CAST( NULL AS SIGNED ) * ( col2 ) - - 53 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8369
SELECT CAST ( NULL AS INTEGER ) * ( col2 ) - - 53 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ( col1 ) + + tab2.col0 AS col1 FROM tab2
----
137
38
96

query I rowsort
SELECT - col2 - 30 FROM tab2
----
-56
-57
-68

query I rowsort
SELECT ALL + - 24 + - col2 - col2 * + col2 FROM tab0 AS cor0
----
-1146
-26
-6830

query I rowsort
SELECT ALL - 10 + - col0 AS col0 FROM tab2 AS cor0
----
-17
-88
-89

query I rowsort
SELECT DISTINCT col1 * 78 * col2 - cor0.col2 AS col2 FROM tab2 AS cor0
----
119626
50350
65259

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8375
SELECT ALL CAST( NULL AS SIGNED ) + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8375
SELECT ALL CAST ( NULL AS INTEGER ) + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + + col0 * col0 + col0 AS col0 FROM tab1 AS cor0
----
12
4160
6480

query I rowsort
SELECT + - ( col2 ) AS col0 FROM tab2 AS cor0
----
-26
-27
-38

query I rowsort
SELECT 52 * cor0.col0 FROM tab2, tab1 AS cor0
----
9 values hashing to 2f7302093825f052a60bd475237923bd

query I rowsort
SELECT - ( - col0 ) + - col2 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT DISTINCT + 77 * col2 AS col0 FROM tab0 AS cor0
----
2541
6314
77

query I rowsort
SELECT 43 * - col2 FROM tab1 AS cor0
----
-2322
-2451
-4128

query I rowsort
SELECT + + ( - cor0.col2 ) + + col1 * - 66 AS col1 FROM tab2 AS cor0
----
-1160
-2073
-3920

query I rowsort
SELECT + col2 * 6 + col1 * - 7 FROM tab1 AS cor0
----
142
272
485

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - ( cor0.col2 ) + col0 * col0 col0 FROM tab1 cor0
----
-45
4039
6304

query I rowsort
SELECT DISTINCT + 37 AS col2 FROM tab1 cor0
----
37

query I rowsort
SELECT ALL + 74 + col1 * - col0 AS col2 FROM tab2 cor0
----
-1269
-143
-4528

query I rowsort
SELECT DISTINCT + 77 - - cor0.col1 FROM tab1 AS cor0
----
103
87
90

query I rowsort
SELECT - - 67 AS col0 FROM tab2 AS cor0
----
67
67
67

query I rowsort
SELECT - col2 + + col0 * + 23 FROM tab1 AS cor0
----
1415
15
1744

onlyif mysql # use DIV operator for integer division
query I rowsort label-8390
SELECT ALL + + col2 DIV - col1 AS col0 FROM tab1 AS cor0
----
-2
-5
-7

skipif mysql # not compatible
query I rowsort label-8390
SELECT ALL + + col2 / - col1 AS col0 FROM tab1 AS cor0
----
-2
-5
-7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8391
SELECT DISTINCT col0 * col1 + col0 + CAST( NULL AS SIGNED ) * + col2 col1 FROM tab0
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8391
SELECT DISTINCT col0 * col1 + col0 + CAST ( NULL AS INTEGER ) * + col2 col1 FROM tab0
----
NULL

query I rowsort
SELECT ALL col0 + col1 AS col2 FROM tab2 cor0
----
137
38
96

query I rowsort
SELECT DISTINCT - ( col0 ) * - ( col0 ) - - cor0.col0 FROM tab0 AS cor0
----
1260
600
8010

query I rowsort
SELECT DISTINCT + + ( col1 ) * + 99 - col2 AS col1 FROM tab1 cor0
----
1191
2520
933

query I rowsort
SELECT ALL ( + col1 ) * - 3 FROM tab1 AS cor0
----
-30
-39
-78

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 col1 FROM tab2, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

query I rowsort
SELECT - + cor0.col2 * - ( - col1 ) - - col1 AS col1 FROM tab2 AS cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL col0 * + 30 FROM tab2 AS cor0
----
210
2340
2370

onlyif mysql # use DIV operator for integer division
query I rowsort label-8399
SELECT cor0.col1 DIV col0 + cor0.col1 FROM tab1 AS cor0
----
10
13
34

skipif mysql # not compatible
query I rowsort label-8399
SELECT cor0.col1 / col0 + cor0.col1 FROM tab1 AS cor0
----
10
13
34

query I rowsort
SELECT col2 * + 59 AS col1 FROM tab1 AS cor0
----
3186
3363
5664

query I rowsort
SELECT ALL + + 60 - + col0 AS col0 FROM tab0 AS cor0
----
-29
25
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-8402
SELECT DISTINCT - col0 DIV - col1 - 30 FROM tab0
----
-30

skipif mysql # not compatible
query I rowsort label-8402
SELECT DISTINCT - col0 / - col1 - 30 FROM tab0
----
-30

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8403
SELECT DISTINCT - - CAST( NULL AS DECIMAL ) + - col0 * col2 / cor0.col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8403
SELECT DISTINCT - - CAST ( NULL AS REAL ) + - col0 * col2 / cor0.col1 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col1 * 17 AS col0 FROM tab0 AS cor0
----
1462
1547
1649

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8405
SELECT ALL + CAST( 20 AS SIGNED ) * + col0 FROM tab1 AS cor0
----
1280
1600
60

skipif mysql # not compatible
query I rowsort label-8405
SELECT ALL + CAST ( 20 AS INTEGER ) * + col0 FROM tab1 AS cor0
----
1280
1600
60

query I rowsort
SELECT DISTINCT - col2 * 2 AS col0 FROM tab1 AS cor0
----
-108
-114
-192

query I rowsort
SELECT - + 26 + - ( col1 * - 30 ) + - 82 AS col0 FROM tab1 AS cor0
----
192
282
672

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8408
SELECT DISTINCT + CAST( NULL AS SIGNED ) * - 7 + + col1 AS col2 FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8408
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * - 7 + + col1 AS col2 FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL + ( col1 ) * col2 + + ( + cor0.col2 * + cor0.col1 ) AS col0 FROM tab2 cor0
----
1292
1674
3068

query I rowsort
SELECT ALL col0 + - col1 + + col2 FROM tab1
----
111
163
31

query I rowsort
SELECT ALL col2 + 18 AS col1 FROM tab1
----
114
72
75

query I rowsort
SELECT ALL col0 * col2 + - 59 AS col0 FROM tab2
----
130
1969
2943

query I rowsort
SELECT ALL + col0 + 4 * col2 * + col0 AS col1 FROM tab0
----
175
29281
3192

query I rowsort
SELECT ALL - - ( col0 ) FROM tab2 AS cor0
----
7
78
79

query I rowsort
SELECT - 83 AS col1 FROM tab2 cor0
----
-83
-83
-83

query I rowsort
SELECT ALL - col1 - col2 * col2 AS col2 FROM tab1 AS cor0
----
-2942
-3259
-9229

query I rowsort
SELECT - 37 * col1 FROM tab2 cor0
----
-1147
-2183
-629

query I rowsort
SELECT ALL 91 + + col1 FROM tab2 AS cor0
----
108
122
150

query I rowsort
SELECT + cor0.col2 * + cor0.col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT 82 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

query I rowsort
SELECT + cor0.col0 * + cor0.col0 + 4 AS col0 FROM tab2 AS cor0
----
53
6088
6245

query I rowsort
SELECT col0 * 44 AS col1 FROM tab1 AS cor0
----
132
2816
3520

query I rowsort
SELECT 3 * + 20 FROM tab1 AS cor0
----
60
60
60

query I rowsort
SELECT ( - col0 ) * col2 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 5 + + col0 * col2 * 11 col2 FROM tab2 AS cor0
----
2084
22313
33027

query I rowsort
SELECT ALL - 18 AS col0 FROM tab1 AS cor0
----
-18
-18
-18

query I rowsort
SELECT + col0 + + cor0.col2 * - col1 AS col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT ALL ( - 88 ) * - col0 FROM tab2 cor0
----
616
6864
6952

query I rowsort
SELECT col1 * col2 + tab1.col0 AS col0 FROM tab1
----
1328
1407
634

query I rowsort
SELECT + cor1.col1 AS col0 FROM tab0, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 7599b480125de521efed71b5b2413c7d

query I rowsort
SELECT 21 AS col1 FROM tab1, tab1 AS cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

query I rowsort
SELECT - 66 AS col0 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to cd4a3594ee8b45223ebf9f25840cd112

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 18 * col0 col1 FROM tab0 AS cor0
----
-1602
-432
-630

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col0 col2 FROM tab2
----
137
38
96

query I rowsort
SELECT tab1.col1 * + col2 + tab1.col0 AS col1 FROM tab1
----
1328
1407
634

query I rowsort
SELECT ALL + col2 * + col0 * tab1.col1 FROM tab1
----
36480
4212
99840

query I rowsort
SELECT DISTINCT ( + col0 ) * - col1 * + col0 AS col0 FROM tab0
----
-118825
-49536
-720811

query I rowsort
SELECT ALL 78 * 10 AS col2 FROM tab1
----
780
780
780

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8439
SELECT ALL + - 40 + col0 + - CAST( col0 AS SIGNED ) * col2 FROM tab0 AS cor0
----
-40
-7249
-808

skipif mysql # not compatible
query I rowsort label-8439
SELECT ALL + - 40 + col0 + - CAST ( col0 AS INTEGER ) * col2 FROM tab0 AS cor0
----
-40
-7249
-808

query I rowsort
SELECT ALL - - 37 * col2 AS col1 FROM tab0 AS cor0
----
1221
3034
37

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 42 col2 FROM tab0
----
-42
-42
-42

query I rowsort
SELECT + col2 - col2 * 64 AS col1 FROM tab0
----
-2079
-5166
-63

onlyif mysql # use DIV operator for integer division
query I rowsort label-8443
SELECT + + cor0.col1 DIV + col0 FROM tab2 AS cor0
----
0
0
4

skipif mysql # not compatible
query I rowsort label-8443
SELECT + + cor0.col1 / + col0 FROM tab2 AS cor0
----
0
0
4

query I rowsort
SELECT DISTINCT - cor0.col0 AS col1 FROM tab2, tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT col2 + col2 * col2 AS col2 FROM tab2
----
1482
702
756

query I rowsort
SELECT + 6 FROM tab1, tab2 AS cor0, tab0 cor1
----
27 values hashing to f1e8f0199f3714ee8fcc24ce0cc3ea04

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * 72 col1 FROM tab1
----
-216
-4608
-5760

query I rowsort
SELECT + ( + 82 ) FROM tab0, tab0 AS cor0
----
9 values hashing to f318fd9dac2de7af4b82cc7574bbca2c

query I rowsort
SELECT + ( col0 ) + cor0.col1 AS col2 FROM tab1 cor0
----
29
74
93

query I rowsort
SELECT col1 * - ( + col2 ) + + 53 + col0 AS col2 FROM tab1 AS cor0
----
-1115
-1348
-453

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 56 col1 FROM tab1
----
56
56
56

query I rowsort
SELECT - ( - col0 ) + + col2 FROM tab0 AS cor0
----
171
36
57

query I rowsort
SELECT col2 * - 66 + col0 AS col2 FROM tab2 cor0
----
-1638
-1775
-2429

query I rowsort
SELECT + + 2 * + cor0.col0 + col2 * col1 FROM tab2 AS cor0
----
1690
804
851

onlyif mysql # use DIV operator for integer division
query I rowsort label-8455
SELECT - + 36 DIV - 11 col0 FROM tab1 AS cor0
----
3
3
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8455
SELECT - + 36 / - 11 col0 FROM tab1 AS cor0
----
3
3
3

query I rowsort
SELECT + ( + cor0.col1 ) AS col1 FROM tab2 cor0
----
17
31
59

query I rowsort
SELECT - 16 * + col1 + - col1 AS col2 FROM tab0 AS cor0
----
-1462
-1547
-1649

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8458
SELECT ALL - col2 + CAST( col2 AS SIGNED ) FROM tab1 cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8458
SELECT ALL - col2 + CAST ( col2 AS INTEGER ) FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT - col0 + - ( + col2 ) * + cor0.col2 AS col1 FROM tab2 AS cor0
----
-1523
-736
-754

query I rowsort
SELECT DISTINCT col0 * 99 AS col2 FROM tab0
----
2376
3465
8811

query I rowsort
SELECT - col0 + - tab1.col0 * 99 AS col1 FROM tab1
----
-300
-6400
-8000

query I rowsort
SELECT + col0 + + tab0.col0 * - col1 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT col2 + ( - col0 ) AS col1 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT cor0.col2 + 82 * 20 AS col1 FROM tab0 AS cor0
----
1641
1673
1722

query I rowsort
SELECT - cor0.col0 * - ( ( col1 ) ) FROM tab2 AS cor0
----
1343
217
4602

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8466
SELECT + - col2 + CAST( NULL AS SIGNED ) / col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8466
SELECT + - col2 + CAST ( NULL AS INTEGER ) / col0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8467
SELECT ALL + - col2 + + CAST( + 75 AS SIGNED ) col2 FROM tab1 cor0
----
-21
18
21

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8467
SELECT ALL + - col2 + + CAST ( + 75 AS INTEGER ) col2 FROM tab1 cor0
----
-21
18
21

query I rowsort
SELECT + ( - 61 ) * col1 AS col1 FROM tab1 AS cor0
----
-1586
-610
-793

query I rowsort
SELECT ALL 75 * + col2 AS col0 FROM tab2 cor0
----
1950
2025
2850

onlyif mysql # use DIV operator for integer division
query I rowsort label-8470
SELECT ALL - cor0.col1 DIV - 73 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8470
SELECT ALL - cor0.col1 / - 73 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT ALL + + 26 AS col1 FROM tab1 AS cor0
----
26
26
26

query I rowsort
SELECT 45 FROM tab2 cor0
----
45
45
45

query I rowsort
SELECT ALL + - 90 + col0 FROM tab0 AS cor0
----
-1
-55
-66

query I rowsort
SELECT DISTINCT - + ( 33 ) + col1 AS col2 FROM tab1 AS cor0
----
-20
-23
-7

query I rowsort
SELECT ALL ( + col1 ) FROM tab2 cor0
----
17
31
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 49 col0 FROM tab2 AS cor0
----
-49
-49
-49

query I rowsort
SELECT DISTINCT - + ( - col2 ) + cor0.col1 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT - col2 - 3 FROM tab2
----
-29
-30
-41

query I rowsort
SELECT DISTINCT tab1.col1 * 77 FROM tab1
----
1001
2002
770

query I rowsort
SELECT col0 + - tab1.col0 * - tab1.col0 FROM tab1
----
12
4160
6480

query I rowsort
SELECT col2 - + 45 * - col1 FROM tab1
----
1224
507
681

query I rowsort
SELECT ALL - - col1 + col1 * + col1 FROM tab1 AS cor0
----
110
182
702

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + col1 + - col1 col1 FROM tab1 AS cor0
----
-20
-26
-52

query I rowsort
SELECT - col1 + - col0 - + 96 AS col1 FROM tab1 AS cor0
----
-125
-170
-189

query I rowsort
SELECT DISTINCT - + 85 * - cor0.col0 AS col1 FROM tab1 AS cor0
----
255
5440
6800

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 22 * col2 col0 FROM tab1
----
-1188
-1254
-2112

query I rowsort
SELECT 88 AS col0 FROM tab2, tab1 cor0
----
9 values hashing to 6be17b82ecb3e8b268fcb4ba610ddb37

onlyif mysql # use DIV operator for integer division
query I rowsort label-8488
SELECT + col1 * 66 DIV col0 col0 FROM tab1
----
10
10
572

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8488
SELECT + col1 * 66 / col0 col0 FROM tab1
----
10
10
572

onlyif mysql # use DIV operator for integer division
query I rowsort label-8489
SELECT col2 + - col1 DIV + col1 AS col2 FROM tab2 cor0
----
25
26
37

skipif mysql # not compatible
query I rowsort label-8489
SELECT col2 + - col1 / + col1 AS col2 FROM tab2 cor0
----
25
26
37

query I rowsort
SELECT DISTINCT 97 + + cor0.col1 FROM tab1 AS cor0
----
107
110
123

query I rowsort
SELECT tab1.col2 - - tab1.col2 FROM tab1
----
108
114
192

query I rowsort
SELECT DISTINCT - 95 * 86 - cor1.col1 AS col0 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
-8180
-8183
-8196

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 22 col1 FROM tab1
----
22
22
22

query I rowsort
SELECT - col2 - + col2 FROM tab1 cor0
----
-108
-114
-192

onlyif mysql # use DIV operator for integer division
query I rowsort label-8495
SELECT ALL 33 DIV + col1 + - col1 * - 36 AS col0 FROM tab1
----
363
470
937

skipif mysql # not compatible
query I rowsort label-8495
SELECT ALL 33 / + col1 + - col1 * - 36 AS col0 FROM tab1
----
363
470
937

query I rowsort
SELECT + col0 + + col2 + - col1 FROM tab0
----
-29
-61
80

query I rowsort
SELECT DISTINCT + col2 + tab2.col2 AS col1 FROM tab2
----
52
54
76

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * - col2 + col0 * - col0 col1 FROM tab1 AS cor0
----
-1413
-4666
-7648

query I rowsort
SELECT ALL col2 * - 34 + - col2 * - col1 FROM tab1 AS cor0
----
-1368
-2016
-432

query I rowsort
SELECT + col2 + - col1 * col1 AS col1 FROM tab1 AS cor0
----
-43
-622
-73

query I rowsort
SELECT - 20 * col2 FROM tab0
----
-1640
-20
-660

query I rowsort
SELECT DISTINCT col0 + col1 * - col0 * col0 FROM tab0
----
-118790
-49512
-720722

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8503
SELECT DISTINCT - CAST( NULL AS DECIMAL ) FROM tab1, tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8503
SELECT DISTINCT - CAST ( NULL AS REAL ) FROM tab1, tab2 AS cor0
----
NULL

query I rowsort
SELECT col0 + col0 * - col2 FROM tab1
----
-159
-3584
-7600

query I rowsort
SELECT - 76 AS col2 FROM tab2, tab0 AS cor0
----
9 values hashing to f8b6589bc7503fc720ca5430e3569317

query I rowsort
SELECT col1 * - col1 + col1 AS col1 FROM tab1 cor0
----
-156
-650
-90

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8507
SELECT ALL + - col2 * CAST( NULL AS SIGNED ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8507
SELECT ALL + - col2 * CAST ( NULL AS INTEGER ) AS col1 FROM tab0 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - col2 * 56 FROM tab1 AS cor0
----
-3024
-3192
-5376

onlyif mysql # use DIV operator for integer division
query I rowsort label-8509
SELECT - + col2 DIV + ( - col2 ) AS col0 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8509
SELECT - + col2 / + ( - col2 ) AS col0 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - col2 + cor0.col1 AS col1 FROM tab0 cor0
----
53
9
96

query I rowsort
SELECT ALL - - col1 + + ( cor0.col2 ) AS col0 FROM tab0 AS cor0
----
119
173
98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col1 * ( + col1 ) * col2 + - col0 * - cor0.col2 col1 FROM tab1 AS cor0
----
23904
36666
9348

query I rowsort
SELECT DISTINCT col1 + cor0.col2 * col0 AS col1 FROM tab0 AS cor0
----
132
7389
878

query I rowsort
SELECT - - col2 + ( col1 ) FROM tab1 cor0
----
109
67
80

query I rowsort
SELECT - + col1 * 66 FROM tab1 AS cor0
----
-1716
-660
-858

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 + + col1 col0 FROM tab1 AS cor0
----
20
26
52

query I rowsort
SELECT ALL - col2 * - 60 FROM tab1 AS cor0
----
3240
3420
5760

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0 CROSS JOIN tab1, tab0, tab0 cor1
----
3645 values hashing to 862fba9ac85fdf2cec88a0bec0808b7e

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - cor0.col2 col1 FROM tab1, tab1 AS cor0, tab2 AS cor1
----
27 values hashing to 44fdcd7cd603352d4d127811d164cc1e

query I rowsort
SELECT ALL + ( 91 ) * + col2 * - col1 + col2 AS col0 FROM tab2 AS cor0
----
-139568
-58748
-76140

query I rowsort
SELECT DISTINCT + - 80 + cor0.col2 FROM tab1 cor0
----
-23
-26
16

query I rowsort
SELECT DISTINCT - col2 - cor0.col1 FROM tab0 cor0
----
-119
-173
-98

query I rowsort
SELECT - + ( col2 ) AS col1 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT ALL - col1 - col0 FROM tab2 AS cor0
----
-137
-38
-96

query I rowsort
SELECT - 19 * col2 AS col1 FROM tab0 AS cor0
----
-1558
-19
-627

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 84 col1 FROM tab2 AS cor0
----
-84

query I rowsort
SELECT ALL + 66 + + col2 - col2 FROM tab0 AS cor0
----
66
66
66

query I rowsort
SELECT 46 AS col0 FROM tab2 cor0
----
46
46
46

query I rowsort
SELECT DISTINCT + col0 + + 9 + - col2 FROM tab1 cor0
----
-42
-7
16

query I rowsort
SELECT ALL - 75 * col1 + col0 AS col0 FROM tab2 AS cor0
----
-1196
-2318
-4347

query I rowsort
SELECT ALL + ( - col0 ) * col2 + + ( col2 ) * col0 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT - 32 + col0 + col2 FROM tab0
----
139
25
4

query I rowsort
SELECT ALL - col2 + col2 * cor0.col2 AS col0 FROM tab0 cor0
----
0
1056
6642

query I rowsort
SELECT + col2 * col1 - col0 AS col0 FROM tab0 AS cor0
----
2814
62
7373

query I rowsort
SELECT DISTINCT + - col2 - + col0 FROM tab2 AS cor0
----
-104
-117
-34

query I rowsort
SELECT ( + 45 ) AS col0 FROM tab0, tab0 cor0, tab0 AS cor1
----
27 values hashing to 14cec871edc37b5056cda01c8331fdca

query I rowsort
SELECT ALL 55 + col1 * col2 FROM tab2 AS cor0
----
1589
701
892

onlyif mysql # use DIV operator for integer division
query I rowsort label-8538
SELECT DISTINCT + - col0 DIV - col1 + - 2 + - col2 AS col1 FROM tab0 AS cor0
----
-3
-35
-84

skipif mysql # not compatible
query I rowsort label-8538
SELECT DISTINCT + - col0 / - col1 + - 2 + - col2 AS col1 FROM tab0 AS cor0
----
-3
-35
-84

query I rowsort
SELECT + + col2 * - col1 + col0 AS col0 FROM tab0 AS cor0
----
-2814
-62
-7373

query I rowsort
SELECT DISTINCT - 81 AS col1 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
-81

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 75 col0 FROM tab0 cor0
----
75
75
75

query I rowsort
SELECT ALL col1 - col0 * col1 AS col1 FROM tab1
----
-1027
-52
-630

query I rowsort
SELECT - tab1.col0 + col1 AS col0 FROM tab1
----
-54
-67
23

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT NULL BETWEEN col1 + col0 * + col1 AND ( col2 * col1 )
----

query I rowsort
SELECT ALL col0 * col2 + + col0 * - col2 * col0 AS col0 FROM tab2
----
-1134
-156156
-234156

query I rowsort
SELECT ALL - col1 FROM tab1 WHERE NOT + tab1.col2 = ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * - col1 col1 FROM tab0 WHERE NOT ( col0 ) >= NULL
----

query I rowsort
SELECT ALL + tab1.col2 AS col1 FROM tab1 WHERE NOT - col0 IN ( col2 )
----
54
57
96

query I rowsort
SELECT + col0 * + col1 AS col1 FROM tab2 WHERE ( col0 ) BETWEEN NULL AND NULL
----

query I rowsort
SELECT ALL - ( col0 ) * + ( - col0 ) + col0 FROM tab2 AS cor0
----
56
6162
6320

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab1, tab1 cor0, tab0 AS cor1, tab2, tab0 AS cor2
----
3645 values hashing to 93ed44f621cc970f32b0cc9543b45262

query I rowsort
SELECT + col1 * col0 * - col1 FROM tab0 AS cor0
----
-177504
-329315
-737009

onlyif mysql # use DIV operator for integer division
query I rowsort label-8553
SELECT DISTINCT + col0 DIV + col1 - - col0 AS col1 FROM tab1
----
3
70
86

skipif mysql # not compatible
query I rowsort label-8553
SELECT DISTINCT + col0 / + col1 - - col0 AS col1 FROM tab1
----
3
70
86

query I rowsort
SELECT + col1 - col2 AS col2 FROM tab1
----
-28
-47
-83

query I rowsort
SELECT - + 44 * cor0.col1 AS col2 FROM tab1, tab1 cor0
----
9 values hashing to 0dedac8e0d11456dae049daeaf7c78be

query I rowsort
SELECT cor1.col1 AS col0 FROM tab2, tab0 AS cor0, tab0 cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT ALL - col2 + + col0 * - tab2.col0 * col1 FROM tab2
----
-106135
-1546
-358982

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 col2 FROM tab0 AS cor0 WHERE NOT - col1 + col0 NOT BETWEEN NULL AND NULL
----

query I rowsort
SELECT DISTINCT col1 + + tab2.col1 * - tab2.col2 FROM tab2
----
-1475
-629
-806

onlyif mysql # use DIV operator for integer division
query I rowsort label-8560
SELECT col2 + col0 DIV col1 AS col1 FROM tab1
----
102
54
63

skipif mysql # not compatible
query I rowsort label-8560
SELECT col2 + col0 / col1 AS col1 FROM tab1
----
102
54
63

query III rowsort
SELECT DISTINCT * FROM tab2 cor0 WHERE NOT NULL > NULL
----

query I rowsort
SELECT DISTINCT + cor0.col1 FROM tab2 AS cor0 WHERE col2 IN ( + col1 )
----

query I rowsort
SELECT col1 + - col1 + + col2 AS col0 FROM tab2 WHERE NOT + col1 + col0 > NULL
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8564
SELECT - col0 DIV col2 + col0 AS col0 FROM tab1 WHERE NOT col2 + col0 * col1 * - col0 >= + col0
----
3
63
80

skipif mysql # not compatible
query I rowsort label-8564
SELECT - col0 / col2 + col0 AS col0 FROM tab1 WHERE NOT col2 + col0 * col1 * - col0 >= + col0
----
3
63
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8565
SELECT ALL + col0 DIV col1 + + col2 * + col0 FROM tab0
----
35
7298
792

skipif mysql # not compatible
query I rowsort label-8565
SELECT ALL + col0 / col1 + + col2 * + col0 FROM tab0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL tab1.col1 * col0 col0 FROM tab1
----
1040
640
78

query I rowsort
SELECT DISTINCT + col2 + + col0 AS col1 FROM tab0
----
171
36
57

query III rowsort
SELECT ALL * FROM tab2 WHERE NOT NULL BETWEEN ( + col2 + col1 ) AND ( NULL )
----

query I rowsort
SELECT ALL - col2 + col2 * col1 FROM tab2
----
1508
608
810

query I rowsort
SELECT + col2 + + col2 + col2 AS col0 FROM tab0
----
246
3
99

query I rowsort
SELECT - tab2.col1 + - col1 + - col0 FROM tab2 WHERE NULL NOT IN ( + col1 )
----

query I rowsort
SELECT col2 + + col2 * col1 * + col0 AS col1 FROM tab2
----
119678
51072
5886

query I rowsort
SELECT col2 * tab0.col2 + - col1 AS col0 FROM tab0
----
-96
1003
6633

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 + + tab0.col1 col0 FROM tab0
----
110
132
180

query I rowsort
SELECT - col1 / col2 AS col0 FROM tab2 WHERE NOT NULL IN ( - col0 * col1 )
----

query I rowsort
SELECT ALL - tab1.col0 * - col0 FROM tab1
----
4096
6400
9

query I rowsort
SELECT + col1 + - col2 * col1 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT - col1 * tab2.col2 * col0 + tab2.col1 FROM tab2
----
-119593
-51017
-5828

query I rowsort
SELECT + - 73 * - 63 FROM tab0 AS cor0
----
4599
4599
4599

query I rowsort
SELECT + 86 * 45 AS col2 FROM tab1 AS cor0
----
3870
3870
3870

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8581
SELECT + + CAST( NULL AS DECIMAL ) * + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8581
SELECT + + CAST ( NULL AS REAL ) * + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - col2 * - col2 + col1 AS col1 FROM tab0 cor0
----
1175
6815
98

query I rowsort
SELECT DISTINCT + col0 * + ( col0 ) FROM tab0
----
1225
576
7921

query I rowsort
SELECT + - cor0.col2 + - col0 AS col2 FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT ALL ( 63 ) AS col2 FROM tab0, tab2 AS cor0, tab2 AS cor1, tab0 cor2
----
81 values hashing to 29cdb8d01f1c3eb072511674b1c6d5fd

query I rowsort
SELECT DISTINCT - ( 24 ) AS col2 FROM tab1
----
-24

query I rowsort
SELECT col2 * + 13 FROM tab2
----
338
351
494

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * + col2 * + 22 col1 FROM tab1 AS cor0
----
-202752
-64152
-71478

query I rowsort
SELECT ALL + ( col1 ) + col1 * col1 AS col0 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT 27 + col0 FROM tab1 AS cor0
----
107
30
91

query I rowsort
SELECT ALL 52 * + col2 AS col2 FROM tab2 AS cor0
----
1352
1404
1976

query I rowsort
SELECT - 17 * col1 AS col0 FROM tab1 AS cor0
----
-170
-221
-442

query I rowsort
SELECT ALL - 79 * col2 + col2 + col2 FROM tab0
----
-2541
-6314
-77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 * 55 col1 FROM tab1
----
-1430
-550
-715

query I rowsort
SELECT + - cor0.col0 + 26 * - col2 AS col2 FROM tab0 AS cor0
----
-2221
-61
-882

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + - ( 62 ) col0 FROM tab0 AS cor0
----
-27
-38
27

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 39 col0 FROM tab0
----
39
39
39

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 71 + - col1 col0 FROM tab0 AS cor0
----
-6192
-6552
-6984

query I rowsort
SELECT - + cor0.col0 + - ( col0 ) AS col0 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT ALL col1 * - 7 FROM tab1 cor0
----
-182
-70
-91

query I rowsort
SELECT + + col1 + + col1 * 64 - col2 FROM tab1 AS cor0
----
1636
593
749

query I rowsort
SELECT - - cor0.col1 * - col0 + 87 + col2 AS col0 FROM tab0 AS cor0
----
-1944
-3307
-7930

query I rowsort
SELECT ALL ( 5 ) + col0 * col2 FROM tab2
----
194
2033
3007

query I rowsort
SELECT ( + col2 ) + + col0 AS col0 FROM tab2
----
104
117
34

query I rowsort
SELECT ALL + ( + col1 ) + col0 FROM tab1
----
29
74
93

query I rowsort
SELECT ( col2 ) * - col2 AS col2 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT 23 * + col1 FROM tab2 AS cor0
----
1357
391
713

query I rowsort
SELECT DISTINCT - 73 AS col0 FROM tab2, tab1 cor0
----
-73

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * col2 + col2 * - cor0.col1 col0 FROM tab2 cor0
----
-1566
-2090
-2210

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + ( + col2 ) * col2 * col2 + + col1 col1 FROM tab0 AS cor0
----
36023
551459
98

onlyif mysql # use DIV operator for integer division
query I rowsort label-8611
SELECT + col0 + - col0 DIV + col1 AS col1 FROM tab1 AS cor0
----
3
58
74

skipif mysql # not compatible
query I rowsort label-8611
SELECT + col0 + - col0 / + col1 AS col1 FROM tab1 AS cor0
----
3
58
74

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 91 * - col0 col2 FROM tab0 AS cor0
----
-2184
-3185
-8099

query I rowsort
SELECT 82 * 83 AS col1 FROM tab0
----
6806
6806
6806

query I rowsort
SELECT ALL + col2 + - col0 - col2 AS col0 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT ALL + ( col0 ) * - cor0.col0 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 23 * - col1 + col0 * + col1 col1 FROM tab0 AS cor0
----
1164
6006
86

query I rowsort
SELECT DISTINCT + 73 + - col1 * + col0 AS col1 FROM tab2 AS cor0
----
-1270
-144
-4529

query I rowsort
SELECT ALL - 74 + col0 * - col0 FROM tab2 AS cor0
----
-123
-6158
-6315

query I rowsort
SELECT ALL + 77 - col0 FROM tab1 AS cor0
----
-3
13
74

query I rowsort
SELECT DISTINCT ( + col0 ) + + col2 AS col0 FROM tab0 cor0
----
171
36
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-8621
SELECT - col0 DIV + 50 FROM tab1 AS cor0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-8621
SELECT - col0 / + 50 FROM tab1 AS cor0
----
-1
-1
0

query I rowsort
SELECT tab0.col1 + col2 + + col1 * + col1 * + col0 FROM tab0
----
177623
329413
737182

onlyif mysql # use DIV operator for integer division
query I rowsort label-8623
SELECT col0 + - ( + 38 ) DIV - cor0.col1 FROM tab0 AS cor0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-8623
SELECT col0 + - ( + 38 ) / - cor0.col1 FROM tab0 AS cor0
----
24
35
89

query I rowsort
SELECT + - cor0.col1 * + 12 * - 97 FROM tab2 AS cor0
----
19788
36084
68676

query I rowsort
SELECT - cor0.col0 * + 1 AS col1 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT DISTINCT - col2 + + 52 * col1 AS col2 FROM tab2 AS cor0
----
1585
3042
846

query I rowsort
SELECT DISTINCT - - col2 + + 62 * cor0.col2 AS col2 FROM tab0 AS cor0
----
2079
5166
63

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col2 * + cor0.col0 col2 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # use DIV operator for integer division
query I rowsort label-8629
SELECT ALL - 84 DIV cor0.col1 FROM tab2 AS cor0
----
-1
-2
-4

skipif mysql # not compatible
query I rowsort label-8629
SELECT ALL - 84 / cor0.col1 FROM tab2 AS cor0
----
-1
-2
-4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8630
SELECT CAST( 88 AS SIGNED ) * col1 FROM tab1 cor0
----
1144
2288
880

skipif mysql # not compatible
query I rowsort label-8630
SELECT CAST ( 88 AS INTEGER ) * col1 FROM tab1 cor0
----
1144
2288
880

query I rowsort
SELECT - col0 + - col2 * - col2 * col1 + + col1 AS col0 FROM tab0 AS cor0
----
159
611886
93716

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8632
SELECT DISTINCT - CAST( NULL AS SIGNED ) + col1 * + col2 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8632
SELECT DISTINCT - CAST ( NULL AS INTEGER ) + col1 * + col2 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ( 59 ) - - tab0.col2 AS col1 FROM tab0, tab0 cor0
----
9 values hashing to f91058157aa21c0463aad70e20faa3ad

query I rowsort
SELECT - 81 + + col2 + - col0 * col0 AS col2 FROM tab2 AS cor0
----
-103
-6139
-6284

query I rowsort
SELECT DISTINCT ( + col2 ) * + col2 * - col1 AS col0 FROM tab1 AS cor0
----
-119808
-32490
-75816

query I rowsort
SELECT ALL col1 + col2 - - col2 AS col0 FROM tab2
----
111
85
93

query I rowsort
SELECT DISTINCT cor0.col0 + + col2 + - col2 * col2 * cor0.col2 AS col0 FROM tab1 AS cor0
----
-157407
-185072
-884560

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col2 * - col1 col2 FROM tab1 cor0
----
-1248
-1404
-570

query I rowsort
SELECT - col0 * col0 - cor0.col0 AS col0 FROM tab2 AS cor0
----
-56
-6162
-6320

query I rowsort
SELECT col2 * col2 - cor0.col2 FROM tab0 AS cor0
----
0
1056
6642

query I rowsort
SELECT ALL col0 * col2 + cor0.col2 AS col1 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT + col0 * - col1 - - cor0.col2 AS col2 FROM tab2 AS cor0
----
-1305
-190
-4576

query I rowsort
SELECT DISTINCT + col1 * col0 + + cor0.col0 * col1 AS col1 FROM tab0 cor0
----
16198
4128
6790

onlyif mysql # use DIV operator for integer division
query I rowsort label-8644
SELECT - col0 DIV col0 + col1 * + col1 * - col2 FROM tab1 cor0
----
-16225
-36505
-5701

skipif mysql # not compatible
query I rowsort label-8644
SELECT - col0 / col0 + col1 * + col1 * - col2 FROM tab1 cor0
----
-16225
-36505
-5701

query I rowsort
SELECT DISTINCT + tab0.col2 * tab0.col1 FROM tab0
----
2838
7462
97

query I rowsort
SELECT col1 * - col2 + tab0.col1 * + col2 * + col2 AS col0 FROM tab0
----
0
604422
90816

query I rowsort
SELECT - col2 * - col0 + - col2 AS col1 FROM tab1
----
108
3591
7584

query I rowsort
SELECT - col2 * - col2 * col2 FROM tab1
----
157464
185193
884736

onlyif mysql # use DIV operator for integer division
query I rowsort label-8649
SELECT - col0 DIV + tab1.col1 AS col0 FROM tab1
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-8649
SELECT - col0 / + tab1.col1 AS col0 FROM tab1
----
-6
-6
0

query I rowsort
SELECT col2 + tab1.col0 * - col1 + col1 AS col1 FROM tab1
----
-573
-931
2

query I rowsort
SELECT DISTINCT - col2 + + col0 + col1 AS col0 FROM tab1
----
-25
-3
17

query I rowsort
SELECT col1 * + col2 + col2 * - col2 AS col1 FROM tab1
----
-1512
-2679
-7968

onlyif mysql # use DIV operator for integer division
query I rowsort label-8653
SELECT DISTINCT - col0 * col1 + tab1.col1 + col2 DIV - col2 AS col0 FROM tab1
----
-1028
-53
-631

skipif mysql # not compatible
query I rowsort label-8653
SELECT DISTINCT - col0 * col1 + tab1.col1 + col2 / - col2 AS col0 FROM tab1
----
-1028
-53
-631

query I rowsort
SELECT ALL + col0 + + col1 AS col1 FROM tab0
----
110
132
180

query I rowsort
SELECT - + col1 + - col0 + - col0 AS col1 FROM tab1 AS cor0
----
-138
-173
-32

query III rowsort
SELECT * FROM tab0 AS cor0 WHERE NOT - col0 >= col1 * + col1 OR NOT NULL IN ( col0 + + col1 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query I rowsort
SELECT ALL col2 * + col0 + + col1 FROM tab1 cor0
----
188
3658
7693

query I rowsort
SELECT DISTINCT - col0 * - col0 + col2 FROM tab2
----
6110
6279
76

onlyif mysql # use DIV operator for integer division
query I rowsort label-8659
SELECT col0 * + col1 DIV + col1 FROM tab0
----
24
35
89

skipif mysql # not compatible
query I rowsort label-8659
SELECT col0 * + col1 / + col1 FROM tab0
----
24
35
89

query I rowsort
SELECT - 77 * + tab1.col1 + + col2 * col1 * col0 FROM tab1
----
2210
35710
98839

query I rowsort
SELECT - col0 * - col1 + col2 FROM tab1
----
1136
132
697

query I rowsort
SELECT ALL + + col1 * col1 AS col2 FROM tab0 cor0
----
7396
8281
9409

query I rowsort
SELECT tab0.col1 + col0 * col2 FROM tab0
----
132
7389
878

query I rowsort
SELECT col2 + col1 * + col1 * - col1 FROM tab0
----
-636023
-753489
-912672

query I rowsort
SELECT + col1 + - col2 * - col0 AS col0 FROM tab1
----
188
3658
7693

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + - col0 col0 FROM tab0 cor0
----
-110
-132
-180

query I rowsort
SELECT ALL cor0.col1 * col2 + col2 * - cor0.col2 * + col2 AS col1 FROM tab0 AS cor0
----
-33099
-543906
96

query I rowsort
SELECT ALL + cor0.col0 * + col0 + col1 FROM tab2 AS cor0
----
6143
6258
80

onlyif mysql # use DIV operator for integer division
query I rowsort label-8669
SELECT DISTINCT + - col1 DIV col0 AS col1 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-8669
SELECT DISTINCT + - col1 / col0 AS col1 FROM tab0 AS cor0
----
-1
-2
-3

onlyif mysql # use DIV operator for integer division
query I rowsort label-8670
SELECT ALL col1 DIV cor0.col0 + cor0.col2 AS col2 FROM tab0 cor0
----
3
36
83

skipif mysql # not compatible
query I rowsort label-8670
SELECT ALL col1 / cor0.col0 + cor0.col2 AS col2 FROM tab0 cor0
----
3
36
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8671
SELECT + col2 * + CAST( 87 AS SIGNED ) * col0 + - 90 AS col2 FROM tab2 AS cor0
----
16353
176346
261084

skipif mysql # not compatible
query I rowsort label-8671
SELECT + col2 * + CAST ( 87 AS INTEGER ) * col0 + - 90 AS col2 FROM tab2 AS cor0
----
16353
176346
261084

query I rowsort
SELECT + col1 * col1 + - ( - col1 + - cor0.col2 ) * col1 AS col1 FROM tab1 AS cor0
----
1586
2756
770

query I rowsort
SELECT - col1 * + ( col1 ) AS col1 FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT + + col1 * + cor0.col0 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT DISTINCT cor1.col1 AS col0 FROM tab0, tab1 cor0, tab1 AS cor1
----
10
13
26

query I rowsort
SELECT ALL - col1 * + col2 + + cor0.col1 * col0 AS col0 FROM tab2 cor0
----
-620
3068
697

onlyif mysql # use DIV operator for integer division
query I rowsort label-8677
SELECT - col1 + + cor0.col2 DIV col0 FROM tab1 AS cor0
----
-10
-12
-8

skipif mysql # not compatible
query I rowsort label-8677
SELECT - col1 + + cor0.col2 / col0 FROM tab1 AS cor0
----
-10
-12
-8

query I rowsort
SELECT - col2 * 48 FROM tab2 AS cor0
----
-1248
-1296
-1824

query I rowsort
SELECT col1 + + 19 FROM tab0 AS cor0
----
105
110
116

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 15 col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

query I rowsort
SELECT DISTINCT - 30 + + col1 AS col2 FROM tab0
----
56
61
67

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 83 + - col0 + col1 col2 FROM tab1
----
-137
-150
-60

query I rowsort
SELECT ALL 83 * 99 + - col0 FROM tab2 AS cor0
----
8138
8139
8210

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 * 69 + cor0.col0 col2 FROM tab2 AS cor0
----
490
5460
5530

query I rowsort
SELECT DISTINCT - 45 AS col0 FROM tab2, tab0 AS cor0
----
-45

onlyif mysql # use DIV operator for integer division
query I rowsort label-8686
SELECT DISTINCT col0 DIV cor0.col0 + + col0 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-8686
SELECT DISTINCT col0 / cor0.col0 + + col0 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT - 66 - + col1 FROM tab1 cor0
----
-76
-79
-92

query I rowsort
SELECT + 46 AS col1 FROM tab1
----
46
46
46

query I rowsort
SELECT - - 40 + col2 * + col0 FROM tab0 AS cor0
----
7338
75
832

query I rowsort
SELECT - col0 + - col1 * 3 FROM tab0 AS cor0
----
-282
-326
-362

query I rowsort
SELECT + col0 - cor0.col2 AS col0 FROM tab0 AS cor0
----
-9
34
7

onlyif mysql # use DIV operator for integer division
query I rowsort label-8692
SELECT DISTINCT - + col0 DIV + col2 AS col1 FROM tab0 cor0
----
-1
-35
0

skipif mysql # not compatible
query I rowsort label-8692
SELECT DISTINCT - + col0 / + col2 AS col1 FROM tab0 cor0
----
-1
-35
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * col2 + - col0 + - col2 * cor0.col1 col1 FROM tab2 AS cor0
----
-7
-78
-79

onlyif mysql # use DIV operator for integer division
query I rowsort label-8694
SELECT ALL + cor0.col1 DIV - CAST( - col1 + + col2 AS SIGNED ) FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-8694
SELECT ALL + cor0.col1 / - CAST ( - col1 + + col2 AS INTEGER ) FROM tab1 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-8695
SELECT - 40 DIV col2 AS col2 FROM tab0 cor0
----
-1
-40
0

skipif mysql # not compatible
query I rowsort label-8695
SELECT - 40 / col2 AS col2 FROM tab0 cor0
----
-1
-40
0

query I rowsort
SELECT + cor1.col2 + - 58 AS col2 FROM tab0, tab2 AS cor0, tab0 AS cor1, tab1, tab1 AS cor2
----
243 values hashing to ce08c7124e8732cb5acfe10ad71ac4e6

onlyif mysql # use DIV operator for integer division
query I rowsort label-8697
SELECT - + col0 DIV 9 AS col2 FROM tab2 AS cor0
----
-8
-8
0

skipif mysql # not compatible
query I rowsort label-8697
SELECT - + col0 / 9 AS col2 FROM tab2 AS cor0
----
-8
-8
0

query I rowsort
SELECT ( + col1 + - tab1.col1 ) FROM tab1
----
0
0
0

query I rowsort
SELECT + - 81 * + col1 FROM tab2 AS cor0
----
-1377
-2511
-4779

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 14 col0 FROM tab0 AS cor0
----
-14
-14
-14

query I rowsort
SELECT - + col0 * - cor0.col2 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT - ( col2 ) + col2 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT ALL + - ( 10 ) AS col2 FROM tab1 AS cor0
----
-10
-10
-10

query I rowsort
SELECT DISTINCT + + col0 + - 92 AS col0 FROM tab1 AS cor0
----
-12
-28
-89

query I rowsort
SELECT DISTINCT ( col1 ) + cor0.col0 FROM tab1 AS cor0
----
29
74
93

query I rowsort
SELECT + col2 + 72 * col2 FROM tab1
----
3942
4161
7008

query I rowsort
SELECT cor0.col2 - 99 FROM tab1, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 34c650348c5e0380672ba81ceb11982a

query I rowsort
SELECT ALL - col2 + 35 FROM tab2
----
-3
8
9

query I rowsort
SELECT - col1 * 66 FROM tab1
----
-1716
-660
-858

query I rowsort
SELECT ALL ( - 79 ) + - col0 FROM tab0
----
-103
-114
-168

onlyif mysql # use DIV operator for integer division
query I rowsort label-8711
SELECT ALL + ( 93 ) + - col2 DIV col0 FROM tab2
----
90
93
93

skipif mysql # not compatible
query I rowsort label-8711
SELECT ALL + ( 93 ) + - col2 / col0 FROM tab2
----
90
93
93

query I rowsort
SELECT DISTINCT - col1 + + col0 + col1 FROM tab0
----
24
35
89

query I rowsort
SELECT ALL - col0 + - ( col2 * col0 + tab1.col1 ) FROM tab1
----
-191
-3722
-7773

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8714
SELECT ALL CAST( NULL AS SIGNED ) / + col2 + + col2 + col0 AS col0 FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8714
SELECT ALL CAST ( NULL AS INTEGER ) / + col2 + + col2 + col0 AS col0 FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT col0 + + 82 FROM tab2 cor0
----
160
161
89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8716
SELECT + col2 + - col1 DIV + col0 col1 FROM tab1 AS cor0
----
46
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8716
SELECT + col2 + - col1 / + col0 col1 FROM tab1 AS cor0
----
46
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 31 col2 FROM tab1 AS cor0
----
31
31
31

query I rowsort
SELECT + cor0.col1 FROM tab0, tab2, tab0 AS cor0, tab1
----
81 values hashing to 8c9db501a604ea66e3b5e5598f3f2a91

query I rowsort
SELECT ( col1 * + col2 ) AS col2 FROM tab0
----
2838
7462
97

query I rowsort
SELECT 69 AS col0 FROM tab2, tab0 cor0, tab0 AS cor1
----
27 values hashing to 2810c3097fe4771e273cfff903357b40

query I rowsort
SELECT + 70 * col1 AS col1 FROM tab1 cor0
----
1820
700
910

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8722
SELECT ALL col0 * col0 * CAST( NULL AS SIGNED ) FROM tab2
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8722
SELECT ALL col0 * col0 * CAST ( NULL AS INTEGER ) FROM tab2
----
NULL
NULL
NULL

query I rowsort
SELECT 72 * + tab1.col2 - - 43 * col0 FROM tab1
----
10352
4017
6856

query I rowsort
SELECT ALL - col2 + - ( + 80 ) FROM tab1 AS cor0
----
-134
-137
-176

query I rowsort
SELECT col1 + 55 * + col2 AS col1 FROM tab0 AS cor0
----
152
1901
4601

onlyif mysql # use DIV operator for integer division
query I rowsort label-8726
SELECT ALL col1 DIV col0 + + 41 AS col2 FROM tab0 AS cor0
----
42
43
44

skipif mysql # not compatible
query I rowsort label-8726
SELECT ALL col1 / col0 + + 41 AS col2 FROM tab0 AS cor0
----
42
43
44

query I rowsort
SELECT ALL col1 * cor0.col0 - cor0.col0 FROM tab1 AS cor0
----
576
75
960

query I rowsort
SELECT DISTINCT - col1 + ( col0 ) FROM tab1 AS cor0
----
-23
54
67

query I rowsort
SELECT + col0 * 23 FROM tab1 AS cor0
----
1472
1840
69

query I rowsort
SELECT DISTINCT - cor0.col0 * + ( col0 ) AS col0 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT ALL cor0.col1 + + 32 FROM tab1 AS cor0
----
42
45
58

query I rowsort
SELECT ALL - 83 AS col1 FROM tab1
----
-83
-83
-83

query I rowsort
SELECT DISTINCT + col0 + 33 AS col1 FROM tab1 AS cor0
----
113
36
97

query I rowsort
SELECT + col1 * - 20 FROM tab0 AS cor0
----
-1720
-1820
-1940

query I rowsort
SELECT ALL + + cor0.col0 + ( col0 * col1 + 8 ) FROM tab1 AS cor0
----
1128
712
89

query I rowsort
SELECT ALL - + col0 + col1 * 59 FROM tab1 AS cor0
----
1531
526
687

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 69 col0 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
69

query I rowsort
SELECT DISTINCT + col2 - 11 FROM tab0 cor0
----
-10
22
71

query I rowsort
SELECT ALL col2 - ( col1 + col2 ) FROM tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT ALL + + cor0.col2 + col1 * + ( + col1 ) AS col1 FROM tab0 AS cor0
----
7429
8363
9410

query I rowsort
SELECT ALL + col0 - 38 FROM tab0 AS cor0
----
-14
-3
51

query I rowsort
SELECT - 97 FROM tab0, tab2 cor0, tab1 cor1
----
27 values hashing to 12bd12d33f03250bee508c5641e140d5

query I rowsort
SELECT ALL + cor0.col0 * col2 + - col2 AS col1 FROM tab0 AS cor0
----
34
7216
759

query I rowsort
SELECT + + 37 * - col1 AS col1 FROM tab0 cor0
----
-3182
-3367
-3589

query I rowsort
SELECT + col1 * + 63 FROM tab0 cor0
----
5418
5733
6111

query I rowsort
SELECT DISTINCT + + ( col1 ) * col0 + ( + 69 ) * col2 AS col0 FROM tab0 AS cor0
----
13757
3464
4341

query I rowsort
SELECT ALL + 49 + + cor0.col0 - cor0.col2 FROM tab1 AS cor0
----
-2
33
56

query I rowsort
SELECT col2 + 99 FROM tab2
----
125
126
137

query I rowsort
SELECT ALL + ( 73 ) FROM tab1, tab0 AS cor0
----
9 values hashing to e5fbf5d129b181bacd6113bbc8732496

query I rowsort
SELECT - col2 + ( tab0.col0 ) FROM tab0
----
-9
34
7

query I rowsort
SELECT DISTINCT + 44 * cor0.col0 FROM tab1 AS cor0
----
132
2816
3520

query I rowsort
SELECT + col1 * col0 + - col2 * cor0.col2 + cor0.col2 * col0 FROM tab0 cor0
----
1767
3429
8673

query I rowsort
SELECT ALL - 49 * + col2 AS col0 FROM tab0 AS cor0
----
-1617
-4018
-49

onlyif mysql # use DIV operator for integer division
query I rowsort label-8754
SELECT ALL - col1 DIV col0 AS col1 FROM tab2 AS cor0
----
-4
0
0

skipif mysql # not compatible
query I rowsort label-8754
SELECT ALL - col1 / col0 AS col1 FROM tab2 AS cor0
----
-4
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8755
SELECT DISTINCT - - cor0.col2 - col2 * + CAST( NULL AS SIGNED ) AS col0 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-8755
SELECT DISTINCT - - cor0.col2 - col2 * + CAST ( NULL AS INTEGER ) AS col0 FROM tab0 cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8756
SELECT + ( col1 ) * ( - 8 ) DIV - col0 FROM tab2 AS cor0
----
1
35
6

skipif mysql # not compatible
query I rowsort label-8756
SELECT + ( col1 ) * ( - 8 ) / - col0 FROM tab2 AS cor0
----
1
35
6

query I rowsort
SELECT ALL - 67 + 22 * col1 FROM tab2
----
1231
307
615

query I rowsort
SELECT + ( col0 ) * col1 * - ( col1 ) + ( 39 ) * col0 FROM tab2 AS cor0
----
-19750
-268476
-6454

query I rowsort
SELECT + col2 * col2 + + ( col1 ) FROM tab1 AS cor0
----
2942
3259
9229

query I rowsort
SELECT col1 + + col1 * 48 FROM tab0 AS cor0
----
4214
4459
4753

query I rowsort
SELECT DISTINCT col1 * col2 * + cor0.col2 AS col2 FROM tab2 AS cor0
----
22599
24548
39884

query I rowsort
SELECT DISTINCT - col2 + - col1 * col0 FROM tab0 AS cor0
----
-2097
-3396
-8181

query I rowsort
SELECT + 25 + + col0 AS col2 FROM tab2 AS cor0
----
103
104
32

query I rowsort
SELECT + + col0 * - col0 + + col1 * col1 FROM tab2 AS cor0
----
-2603
-5952
912

query I rowsort
SELECT + cor1.col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 7786718bd8042022537378d40ec87475

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 58 + col0 col2 FROM tab1
----
122
138
61

query I rowsort
SELECT col0 * col2 + + col2 AS col2 FROM tab0 AS cor0
----
36
7380
825

query I rowsort
SELECT ALL - 55 AS col2 FROM tab0
----
-55
-55
-55

query I rowsort
SELECT - col0 + - col0 + - col0 FROM tab2 AS cor0
----
-21
-234
-237

onlyif mysql # use DIV operator for integer division
query I rowsort label-8770
SELECT - col0 + col2 * col1 DIV col2 + col2 col1 FROM tab1 AS cor0
----
29
3
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8770
SELECT - col0 + col2 * col1 / col2 + col2 col1 FROM tab1 AS cor0
----
29
3
77

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 - col0 col1 FROM tab1 AS cor0
----
-29
-74
-93

query I rowsort
SELECT DISTINCT + 50 + - col0 AS col1 FROM tab0 AS cor0
----
-39
15
26

query I rowsort
SELECT ALL col0 + + ( - col0 ) FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 * - col2 + col0 * - cor0.col2 * + col1 + + col2 AS col1 FROM tab2 AS cor0
----
-121654
-53998
-6021

query I rowsort
SELECT + + 27 AS col2 FROM tab2 cor0
----
27
27
27

query I rowsort
SELECT ALL - + cor0.col2 + + col1 FROM tab1 AS cor0
----
-28
-47
-83

query I rowsort
SELECT - col0 + col1 * + col0 + - cor0.col2 FROM tab1 AS cor0
----
21
519
864

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8778
SELECT CAST( col0 AS SIGNED ) - + col2 AS col1 FROM tab1 AS cor0
----
-16
-51
7

skipif mysql # not compatible
query I rowsort label-8778
SELECT CAST ( col0 AS INTEGER ) - + col2 AS col1 FROM tab1 AS cor0
----
-16
-51
7

query I rowsort
SELECT col0 * 21 + - col2 FROM tab2 cor0
----
120
1612
1621

onlyif mysql # use DIV operator for integer division
query I rowsort label-8780
SELECT - + 71 + + col2 + - col2 DIV + ( 95 ) AS col0 FROM tab1 AS cor0
----
-14
-17
24

skipif mysql # not compatible
query I rowsort label-8780
SELECT - + 71 + + col2 + - col2 / + ( 95 ) AS col0 FROM tab1 AS cor0
----
-14
-17
24

query I rowsort
SELECT - col0 + col1 + col0 AS col1 FROM tab1 AS cor0
----
10
13
26

query I rowsort
SELECT col0 * col0 * col0 AS col2 FROM tab0
----
13824
42875
704969

query I rowsort
SELECT + cor0.col0 * - col2 + col0 FROM tab2 AS cor0
----
-182
-1950
-2923

query I rowsort
SELECT + col0 * + col2 * - tab0.col2 FROM tab0
----
-26136
-35
-598436

query I rowsort
SELECT + cor0.col1 * - ( col1 ) FROM tab2 AS cor0
----
-289
-3481
-961

query I rowsort
SELECT + - col0 * - ( + col2 + + col1 ) FROM tab0 AS cor0
----
15397
2856
3430

query I rowsort
SELECT + 25 AS col2 FROM tab0, tab2 cor0
----
9 values hashing to 525a55d5ed224a62da65df36731881a7

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8788
SELECT cor0.col0 * CAST( NULL AS DECIMAL ) col0 FROM tab2, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8788
SELECT cor0.col0 * CAST ( NULL AS REAL ) col0 FROM tab2, tab0 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

query I rowsort
SELECT + col1 * + 1 + - tab1.col0 FROM tab1
----
-54
-67
23

query I rowsort
SELECT ALL - col1 + + 24 * col0 AS col0 FROM tab1
----
1526
1907
46

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8791
SELECT ALL - col2 * + CAST( ( + col2 ) AS SIGNED ) AS col0 FROM tab0 AS cor0
----
-1
-1089
-6724

skipif mysql # not compatible
query I rowsort label-8791
SELECT ALL - col2 * + CAST ( ( + col2 ) AS INTEGER ) AS col0 FROM tab0 AS cor0
----
-1
-1089
-6724

query I rowsort
SELECT DISTINCT + col2 + 56 AS col1 FROM tab2 AS cor0
----
82
83
94

query I rowsort
SELECT ALL - 87 FROM tab0, tab2 cor0
----
9 values hashing to 84bcab58a965cc8ae97b39d2d01b3d23

query I rowsort
SELECT - cor0.col2 * - 99 FROM tab1 cor0
----
5346
5643
9504

query I rowsort
SELECT + 16 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to ee5bde9f68ee828e8cd86b0d590090bc

query I rowsort
SELECT DISTINCT col0 + + cor0.col1 AS col1 FROM tab2 cor0
----
137
38
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - ( + 18 ) col2 FROM tab1 cor0
----
-18
-18
-18

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8798
SELECT DISTINCT CAST( NULL AS SIGNED ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0 AS cor2
----
NULL

skipif mysql # not compatible
query I rowsort label-8798
SELECT DISTINCT CAST ( NULL AS INTEGER ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab1, tab1 AS cor1, tab0 AS cor2
----
NULL

query I rowsort
SELECT DISTINCT ( cor0.col2 ) AS col1 FROM tab2, tab1 AS cor0
----
54
57
96

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8800
SELECT - CAST( col1 AS SIGNED ) - col2 FROM tab0 AS cor0
----
-119
-173
-98

skipif mysql # not compatible
query I rowsort label-8800
SELECT - CAST ( col1 AS INTEGER ) - col2 FROM tab0 AS cor0
----
-119
-173
-98

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - ( + ( + col0 ) ) col0 FROM tab0 AS cor0
----
-24
-35
-89

query I rowsort
SELECT + 97 + + 59 FROM tab1
----
156
156
156

onlyif mysql # use DIV operator for integer division
query I rowsort label-8803
SELECT DISTINCT + col0 * 17 - - col2 DIV - col0 FROM tab0
----
1513
407
595

skipif mysql # not compatible
query I rowsort label-8803
SELECT DISTINCT + col0 * 17 - - col2 / - col0 FROM tab0
----
1513
407
595

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8804
SELECT DISTINCT CAST( - 2 AS SIGNED ) - tab0.col2 FROM tab0
----
-3
-35
-84

skipif mysql # not compatible
query I rowsort label-8804
SELECT DISTINCT CAST ( - 2 AS INTEGER ) - tab0.col2 FROM tab0
----
-3
-35
-84

query I rowsort
SELECT ALL ( tab1.col1 ) * + col1 - + col2 * tab1.col0 AS col2 FROM tab1
----
-3548
-7511
514

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8806
SELECT ALL + CAST( NULL AS SIGNED ) - 27 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8806
SELECT ALL + CAST ( NULL AS INTEGER ) - 27 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8807
SELECT 65 DIV col0 FROM tab0
----
0
1
2

skipif mysql # not compatible
query I rowsort label-8807
SELECT 65 / col0 FROM tab0
----
0
1
2

query I rowsort
SELECT col1 * 31 AS col1 FROM tab1 cor0
----
310
403
806

query I rowsort
SELECT - col1 * + 19 AS col1 FROM tab0 AS cor0
----
-1634
-1729
-1843

query I rowsort
SELECT + - 86 AS col2 FROM tab1 AS cor0
----
-86
-86
-86

query I rowsort
SELECT ALL + 24 FROM tab0, tab1, tab1 AS cor0
----
27 values hashing to aeeac431d22528188e8a5a2a60d2d080

query I rowsort
SELECT cor0.col1 * cor1.col2 AS col0 FROM tab1, tab1 cor0, tab1 AS cor1
----
27 values hashing to 6eca0fdf700a988d88ac850bac7633ab

query I rowsort
SELECT - col2 * - cor0.col0 AS col2 FROM tab2 AS cor0
----
189
2028
3002

query I rowsort
SELECT ( + col1 ) + + col2 AS col0 FROM tab0
----
119
173
98

query I rowsort
SELECT - 70 * col2 FROM tab0
----
-2310
-5740
-70

query I rowsort
SELECT ALL - col0 - 63 AS col0 FROM tab0 AS cor0
----
-152
-87
-98

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT col2 + - CAST ( + 17 AS REAL ) FROM tab0 AS cor0
----
-16
16
65

query I rowsort
SELECT ALL + - col1 + - cor0.col2 AS col0 FROM tab2 AS cor0
----
-55
-58
-85

query I rowsort
SELECT ALL ( - cor0.col0 ) AS col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + ( + 68 * col1 ) FROM tab1
----
1768
680
884

query I rowsort
SELECT DISTINCT cor0.col2 + - 65 FROM tab2, tab0 AS cor0
----
-32
-64
17

query I rowsort
SELECT + 44 + - cor0.col2 * col0 FROM tab1 AS cor0
----
-118
-3604
-7636

query I rowsort
SELECT ALL + + 18 FROM tab2 AS cor0
----
18
18
18

query I rowsort
SELECT ALL - ( cor0.col2 ) * col0 AS col1 FROM tab1 AS cor0
----
-162
-3648
-7680

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( col2 ) * - 91 + - col0 col1 FROM tab2
----
-2444
-2464
-3537

query I rowsort
SELECT + 66 + col1 AS col0 FROM tab0
----
152
157
163

query I rowsort
SELECT - col0 * col2 - - col0 FROM tab1 cor0
----
-159
-3584
-7600

query I rowsort
SELECT tab2.col2 * ( + tab2.col1 ) + - cor0.col2 FROM tab2, tab0 AS cor0
----
9 values hashing to 76d3c707319428bd826127994db7931d

query I rowsort
SELECT ALL 48 * tab1.col1 AS col0 FROM tab1
----
1248
480
624

query I rowsort
SELECT - 6 * + col2 AS col2 FROM tab1 AS cor0
----
-324
-342
-576

query I rowsort
SELECT DISTINCT + col0 * col1 * + col1 AS col1 FROM tab0
----
177504
329315
737009

query I rowsort
SELECT DISTINCT + col0 * col0 + col2 FROM tab0 AS cor0
----
1226
609
8003

query I rowsort
SELECT ALL col1 * - col1 * cor0.col2 + - 14 FROM tab2 cor0
----
-10996
-25961
-90520

query I rowsort
SELECT col1 + - 71 FROM tab1 AS cor0
----
-45
-58
-61

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8835
SELECT ALL - - CAST( col1 AS SIGNED ) FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-8835
SELECT ALL - - CAST ( col1 AS INTEGER ) FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL + col2 + - 97 AS col0 FROM tab1 AS cor0
----
-1
-40
-43

query I rowsort
SELECT DISTINCT - col1 + + col0 * - col0 FROM tab1 AS cor0
----
-35
-4106
-6413

query I rowsort
SELECT ALL - col0 + - col1 * ( col2 ) * + 60 AS col1 FROM tab0
----
-170304
-447809
-5855

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col1 * - 24 + col0 * + col0 col2 FROM tab2
----
-695
4668
5833

query I rowsort
SELECT + + 93 AS col1 FROM tab0 AS cor0
----
93
93
93

query I rowsort
SELECT DISTINCT + 98 + + cor0.col1 FROM tab1 AS cor0
----
108
111
124

query I rowsort
SELECT ALL - - ( + col2 ) * col0 FROM tab1 AS cor0
----
162
3648
7680

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8843
SELECT - CAST( NULL AS SIGNED ) + col1 / col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8843
SELECT - CAST ( NULL AS INTEGER ) + col1 / col0 AS col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL + + col2 * + col0 AS col0 FROM tab0 cor0
----
35
7298
792

query I rowsort
SELECT DISTINCT + - col2 + col2 + + col1 FROM tab0 AS cor0
----
86
91
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-8846
SELECT + 29 + + col2 DIV + col2 AS col0 FROM tab1 AS cor0
----
30
30
30

skipif mysql # not compatible
query I rowsort label-8846
SELECT + 29 + + col2 / + col2 AS col0 FROM tab1 AS cor0
----
30
30
30

query I rowsort
SELECT ALL + 87 AS col2 FROM tab1 AS cor0
----
87
87
87

query I rowsort
SELECT - 95 * + 71 + + cor0.col0 AS col2 FROM tab0 AS cor0
----
-6656
-6710
-6721

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 12 * col0 + - col2 AS col1 FROM tab0
----
255
419
986

query I rowsort
SELECT 97 * + col2 FROM tab0
----
3201
7954
97

query I rowsort
SELECT ALL + col0 + 23 FROM tab0
----
112
47
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ( 54 ) * - col0 + + ( - 34 ) col0 FROM tab2
----
-412
-4246
-4300

query I rowsort
SELECT DISTINCT cor0.col2 + + ( + col0 ) AS col0 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL ( - col1 ) + col2 AS col2 FROM tab0 cor0
----
-53
-9
-96

query I rowsort
SELECT ALL col0 + 51 FROM tab1 AS cor0
----
115
131
54

onlyif mysql # use DIV operator for integer division
query I rowsort label-8857
SELECT ALL - ( 56 ) * col0 + 85 * col1 DIV col2 FROM tab0 AS cor0
----
-1123
-4890
6285

skipif mysql # not compatible
query I rowsort label-8857
SELECT ALL - ( 56 ) * col0 + 85 * col1 / col2 FROM tab0 AS cor0
----
-1123
-4890
6285

query I rowsort
SELECT - ( ( col1 ) ) AS col0 FROM tab0
----
-86
-91
-97

query I rowsort
SELECT DISTINCT - - cor0.col1 + cor0.col0 AS col2 FROM tab1 AS cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col1 + col2 * 72 col1 FROM tab1 AS cor0
----
3862
4094
6899

onlyif mysql # use DIV operator for integer division
query I rowsort label-8861
SELECT DISTINCT + 16 DIV col2 FROM tab1 AS cor0
----
0

skipif mysql # not compatible
query I rowsort label-8861
SELECT DISTINCT + 16 / col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT - + col2 + - col1 + 89 * - ( + col0 ) FROM tab1 AS cor0
----
-347
-5763
-7229

query I rowsort
SELECT col0 + col2 * 93 FROM tab0 AS cor0
----
128
3093
7715

query I rowsort
SELECT ALL + 13 * col1 AS col0 FROM tab0 AS cor0
----
1118
1183
1261

query I rowsort
SELECT ALL - col1 + - col1 * + ( + 62 ) FROM tab2 AS cor0
----
-1071
-1953
-3717

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col1 * col2 + ( + col0 ) col1 FROM tab1 AS cor0
----
1328
1407
634

query I rowsort
SELECT ALL - cor0.col2 + 86 FROM tab2 cor0
----
48
59
60

query I rowsort
SELECT + + col2 * 23 FROM tab1 cor0
----
1242
1311
2208

query I rowsort
SELECT DISTINCT - col2 + 97 * - col2 FROM tab2 AS cor0
----
-2548
-2646
-3724

query I rowsort
SELECT DISTINCT + col2 * - ( col2 ) FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT - col2 + ( - col2 ) FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT - + col0 + - 49 FROM tab0 AS cor0
----
-138
-73
-84

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col2 + col0 * - col0 + - col2 * - 52 col1 FROM tab1
----
-1075
-1312
2853

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8874
SELECT ALL col0 + CAST( - col0 AS SIGNED ) * + col0 + cor0.col1 FROM tab1 AS cor0
----
-4022
-6307
20

skipif mysql # not compatible
query I rowsort label-8874
SELECT ALL col0 + CAST ( - col0 AS INTEGER ) * + col0 + cor0.col1 FROM tab1 AS cor0
----
-4022
-6307
20

query I rowsort
SELECT DISTINCT - col1 * - col1 + col0 AS col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT - cor0.col0 - 1 AS col2 FROM tab1 AS cor0
----
-4
-65
-81

onlyif mysql # use DIV operator for integer division
query I rowsort label-8877
SELECT ALL - - col2 DIV - col0 AS col0 FROM tab2 AS cor0
----
-3
0
0

skipif mysql # not compatible
query I rowsort label-8877
SELECT ALL - - col2 / - col0 AS col0 FROM tab2 AS cor0
----
-3
0
0

query I rowsort
SELECT + - cor0.col1 + cor0.col2 * - ( - col0 * col1 ) FROM tab0 AS cor0
----
3298
664027
68026

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8879
SELECT - cor0.col2 - + CAST( NULL AS SIGNED ) / + cor0.col1 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8879
SELECT - cor0.col2 - + CAST ( NULL AS INTEGER ) / + cor0.col1 AS col0 FROM tab2 cor0
----
NULL
NULL
NULL

query I rowsort
SELECT + col0 * 74 + + col1 AS col2 FROM tab2 AS cor0
----
549
5831
5863

query I rowsort
SELECT ALL col0 + ( - cor0.col0 ) FROM tab1 AS cor0
----
0
0
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 + ( col1 ) * + col0 * col1 + col0 col1 FROM tab2 AS cor0
----
22989
271674
6741

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - - col2 - - col1 col2 FROM tab0 AS cor0
----
119
173
98

query I rowsort
SELECT + - cor0.col2 * + col2 + - col2 AS col2 FROM tab2 AS cor0
----
-1482
-702
-756

query I rowsort
SELECT ALL - col1 + - col2 * + col2 * col0 AS col0 FROM tab2 AS cor0
----
-114093
-5134
-52787

query I rowsort
SELECT ALL - col2 - - col1 AS col2 FROM tab0 AS cor0
----
53
9
96

query I rowsort
SELECT - 57 AS col2 FROM tab0, tab0 AS cor0
----
9 values hashing to 520dc393896969e02a72ab6c5d92126b

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 0 col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 16 + + 19 * col1 AS col0 FROM tab2 AS cor0
----
1137
339
605

query I rowsort
SELECT ALL + ( + ( + col0 ) ) + col0 AS col0 FROM tab0 AS cor0
----
178
48
70

query I rowsort
SELECT DISTINCT + 77 AS col0 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
77

query I rowsort
SELECT + col1 + + 79 + - 28 * + col0 FROM tab0
----
-2322
-507
-804

query I rowsort
SELECT ALL tab1.col0 * col0 + col2 FROM tab1
----
4153
63
6496

query I rowsort
SELECT - col1 * tab1.col1 AS col2 FROM tab1
----
-100
-169
-676

query I rowsort
SELECT - col1 * + col2 FROM tab2 WHERE NOT - col2 NOT IN ( - col0 )
----

query I rowsort
SELECT + tab2.col2 + col1 * - col0 FROM tab2
----
-1305
-190
-4576

query I rowsort
SELECT ALL col1 + + col1 * - col1 FROM tab0
----
-7310
-8190
-9312

query III rowsort
SELECT * FROM tab0 WHERE col2 NOT IN ( col1 + tab0.col0 )
----
9 values hashing to 38a1673e2e09d694c8cec45c797034a7

query III rowsort
SELECT * FROM tab2 AS cor0 WHERE - col0 <> col0 + col2 + col0
----
9 values hashing to ad05b5942400d5e7a21b323b3da65a45

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT ( NULL ) <> NULL
----

query I rowsort
SELECT - col0 * col2 + col2 * + col1 AS col0 FROM tab2
----
-2356
-494
648

onlyif mysql # use DIV operator for integer division
query I rowsort label-8902
SELECT DISTINCT col0 DIV col1 col0 FROM tab2
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8902
SELECT DISTINCT col0 / col1 col0 FROM tab2
----
0
1
4

query I rowsort
SELECT col2 AS col1 FROM tab2 WHERE NOT ( NULL ) IN ( + col1 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NULL NOT IN ( col0 )
----

query I rowsort
SELECT tab1.col2 * - col2 + - col2 - - tab1.col1 AS col1 FROM tab1
----
-2944
-3296
-9299

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + col1 + col2 col0 FROM tab1
----
10
13
26

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL NOT IN ( col2 * + col0 * - col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + - col0 * + tab1.col1 col0 FROM tab1
----
-1120
-704
-81

query I rowsort
SELECT col2 + + col1 AS col1 FROM tab1 WHERE col1 IN ( col2 * col1 )
----

query I rowsort
SELECT tab2.col2 * + col2 + col0 AS col2 FROM tab2
----
1523
736
754

query I rowsort
SELECT ALL col2 * - tab2.col2 FROM tab2
----
-1444
-676
-729

query I rowsort
SELECT DISTINCT + col2 + col2 + + col2 * + col0 FROM tab1
----
270
3762
7872

query III rowsort
SELECT * FROM tab1 WHERE NOT ( col2 + col0 + col2 ) <= ( NULL )
----

query I rowsort
SELECT - col0 * + col2 * - col1 FROM tab0
----
3395
664118
68112

query I rowsort
SELECT DISTINCT col2 * col0 * col1 FROM tab2
----
119652
51034
5859

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * + col1 col2 FROM tab1 AS cor0
----
1040
640
78

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 + col1 + + col1 * + col0 AS col1 FROM tab1 AS cor0
----
104
1053
650

query I rowsort
SELECT - - col0 + - col1 FROM tab0 cor0
----
-2
-62
-62

query I rowsort
SELECT + col1 FROM tab1 AS cor0 WHERE NOT col2 * - col0 > NULL
----

query I rowsort
SELECT ALL cor0.col1 AS col1 FROM tab0 AS cor0 CROSS JOIN tab1
----
9 values hashing to 585a41a52c0c6c0d697b5d39265b74dc

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE ( + col2 + col1 + - col2 * col0 ) IN ( + tab0.col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - cor0.col0 + 7 col1 FROM tab1 cor0
----
10
71
87

query I rowsort
SELECT + cor0.col2 + - 20 FROM tab0 AS cor0
----
-19
13
62

query I rowsort
SELECT DISTINCT + - cor0.col0 + 75 * col2 FROM tab2 cor0
----
1872
2018
2771

query I rowsort
SELECT ALL + - cor0.col2 * 44 + - 49 FROM tab2 AS cor0
----
-1193
-1237
-1721

onlyif mysql # use DIV operator for integer division
query I rowsort label-8927
SELECT - col0 + + 86 DIV 84 AS col1 FROM tab0 cor0
----
-23
-34
-88

skipif mysql # not compatible
query I rowsort label-8927
SELECT - col0 + + 86 / 84 AS col1 FROM tab0 cor0
----
-23
-34
-88

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8928
SELECT + cor0.col2 + CAST( NULL AS SIGNED ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8928
SELECT + cor0.col2 + CAST ( NULL AS INTEGER ) AS col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + cor0.col2 * + col0 AS col0 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - - col1 + col1 AS col2 FROM tab2 AS cor0
----
118
34
62

query I rowsort
SELECT ALL + + col2 + col2 * 50 + + col2 AS col0 FROM tab0 AS cor0
----
1716
4264
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col0 * - 15 + ( col1 ) * cor0.col2 col1 FROM tab0 AS cor0
----
-428
2478
6127

query I rowsort
SELECT DISTINCT - cor0.col2 + 33 FROM tab2 AS cor0
----
-5
6
7

query I rowsort
SELECT - cor0.col2 + 12 * 78 * - col2 FROM tab0 cor0
----
-30921
-76834
-937

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 39 + + col0 col1 FROM tab0 AS cor0
----
128
63
74

query I rowsort
SELECT + 80 * - col0 + - cor0.col2 FROM tab2 AS cor0
----
-587
-6266
-6358

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 + + cor0.col1 col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 * col2 + col1 * tab2.col0 AS col0 FROM tab2
----
406
4345
6630

query III rowsort
SELECT ALL * FROM tab1 WHERE col0 * col0 BETWEEN NULL AND NULL
----

query I rowsort
SELECT col0 / col0 + - col2 AS col1 FROM tab1 WHERE NOT col1 * col0 >= ( col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-8941
SELECT col2 DIV col1 col1 FROM tab2
----
0
0
2

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8941
SELECT col2 / col1 col1 FROM tab2
----
0
0
2

query I rowsort
SELECT ALL col2 - tab2.col1 AS col0 FROM tab2
----
-33
-4
21

query I rowsort
SELECT DISTINCT col1 FROM tab1 WHERE NULL BETWEEN NULL AND - col1
----

query I rowsort
SELECT - cor0.col2 * - 27 AS col0 FROM tab1, tab1 AS cor0
----
9 values hashing to ff6162e0ec52b9f9437b6969c2ae51dc

query I rowsort
SELECT ALL - col1 * + tab2.col2 AS col1 FROM tab2
----
-1534
-646
-837

onlyif mysql # use DIV operator for integer division
query I rowsort label-8946
SELECT - ( - col1 ) DIV col1 FROM tab2 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-8946
SELECT - ( - col1 ) / col1 FROM tab2 AS cor0
----
1
1
1

query I rowsort
SELECT - + 42 + col2 FROM tab2 AS cor0
----
-15
-16
-4

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab0 AS cor0 CROSS JOIN tab1, tab1 cor1, tab0, tab0 AS cor2
----
3645 values hashing to 750b3c1b743e18f68d402d034647fcf2

query I rowsort
SELECT ALL + - col0 * 45 + 55 * + col1 AS col0 FROM tab1 cor0
----
-2330
-2885
1295

query I rowsort
SELECT ALL + - col1 + col2 * col1 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT DISTINCT - + col1 - + col1 AS col2 FROM tab0 AS cor0
----
-172
-182
-194

query I rowsort
SELECT + col1 * cor0.col1 + col1 FROM tab0 AS cor0
----
7482
8372
9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-8953
SELECT ALL col1 DIV + cor0.col1 + - col1 col0 FROM tab1 cor0
----
-12
-25
-9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8953
SELECT ALL col1 / + cor0.col1 + - col1 col0 FROM tab1 cor0
----
-12
-25
-9

query I rowsort
SELECT ALL col1 * - 12 FROM tab1 cor0
----
-120
-156
-312

query I rowsort
SELECT ALL - col0 + + 7 AS col1 FROM tab1 AS cor0
----
-57
-73
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - 75 col0 FROM tab1 AS cor0
----
-18
-21
21

query I rowsort
SELECT DISTINCT - 32 FROM tab2, tab2 AS cor0
----
-32

query I rowsort
SELECT ALL ( col0 ) + col0 * - col0 FROM tab0 AS cor0
----
-1190
-552
-7832

query I rowsort
SELECT ALL + col0 + 27 FROM tab0 AS cor0
----
116
51
62

onlyif mysql # use DIV operator for integer division
query I rowsort label-8960
SELECT DISTINCT - col0 - + 6 DIV cor0.col2 FROM tab1 AS cor0
----
-3
-64
-80

skipif mysql # not compatible
query I rowsort label-8960
SELECT DISTINCT - col0 - + 6 / cor0.col2 FROM tab1 AS cor0
----
-3
-64
-80

query I rowsort
SELECT + + ( + ( col2 ) ) FROM tab2 cor0
----
26
27
38

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8962
SELECT - col0 * CAST( 99 AS SIGNED ) + col2 * - col1 AS col1 FROM tab1
----
-1701
-6906
-9168

skipif mysql # not compatible
query I rowsort label-8962
SELECT - col0 * CAST ( 99 AS INTEGER ) + col2 * - col1 AS col1 FROM tab1
----
-1701
-6906
-9168

query I rowsort
SELECT DISTINCT 0 * - col0 AS col2 FROM tab1 cor0
----
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8964
SELECT tab2.col1 * - CAST( + col2 AS SIGNED ) * col2 - col2 * - col1 FROM tab2
----
-21762
-23902
-38350

skipif mysql # not compatible
query I rowsort label-8964
SELECT tab2.col1 * - CAST ( + col2 AS INTEGER ) * col2 - col2 * - col1 FROM tab2
----
-21762
-23902
-38350

query I rowsort
SELECT DISTINCT - ( + cor0.col1 ) * - ( - col2 ) FROM tab1 AS cor0
----
-1248
-1404
-570

query I rowsort
SELECT - - 81 * + col2 FROM tab2 AS cor0
----
2106
2187
3078

query I rowsort
SELECT - 87 + - col0 AS col0 FROM tab2 AS cor0
----
-165
-166
-94

query I rowsort
SELECT DISTINCT - 2 + - col1 AS col1 FROM tab0 AS cor0
----
-88
-93
-99

query I rowsort
SELECT 86 AS col0 FROM tab0, tab2 AS cor0, tab2, tab0 AS cor1
----
81 values hashing to e219687f6f4ab6f7ee442792edcebca9

query I rowsort
SELECT DISTINCT 42 + col0 + ( 20 ) * col0 FROM tab0 AS cor0
----
1911
546
777

query I rowsort
SELECT DISTINCT - cor0.col0 * + col0 AS col0 FROM tab0 AS cor0
----
-1225
-576
-7921

onlyif mysql # use DIV operator for integer division
query I rowsort label-8972
SELECT tab1.col2 DIV - col2 + - 51 - 44 AS col1 FROM tab1
----
-96
-96
-96

skipif mysql # not compatible
query I rowsort label-8972
SELECT tab1.col2 / - col2 + - 51 - 44 AS col1 FROM tab1
----
-96
-96
-96

query I rowsort
SELECT tab0.col2 * - col1 - col2 FROM tab0
----
-2871
-7544
-98

query I rowsort
SELECT + - col0 + col1 AS col0 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT ALL + col2 + - 46 FROM tab0 AS cor0
----
-13
-45
36

query I rowsort
SELECT DISTINCT + - col2 * + col1 - col2 FROM tab0 AS cor0
----
-2871
-7544
-98

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-8977
SELECT - cor0.col2 + + CAST( NULL AS SIGNED ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-8977
SELECT - cor0.col2 + + CAST ( NULL AS INTEGER ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-8978
SELECT DISTINCT - + col1 + - col0 DIV col2 col0 FROM tab1 AS cor0
----
-11
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-8978
SELECT DISTINCT - + col1 + - col0 / col2 col0 FROM tab1 AS cor0
----
-11
-13
-26

onlyif mysql # use DIV operator for integer division
query I rowsort label-8979
SELECT DISTINCT - cor0.col0 DIV 96 + + cor0.col1 FROM tab0 AS cor0
----
86
91
97

skipif mysql # not compatible
query I rowsort label-8979
SELECT DISTINCT - cor0.col0 / 96 + + cor0.col1 FROM tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL - - col1 + ( - col1 ) * col0 - - col0 * - col2 FROM tab2 cor0
----
-375
-4328
-6571

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + col2 * - 80 col1 FROM tab0
----
-2554
-6469
17

query I rowsort
SELECT ALL - col2 * + tab1.col2 + col0 AS col0 FROM tab1
----
-2913
-3185
-9136

query I rowsort
SELECT ALL - 16 + col2 AS col0 FROM tab0
----
-15
17
66

query I rowsort
SELECT ALL + cor0.col1 - - cor0.col2 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 5484e660e65aa37f29a1eca3fc30f5cc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col2 + + col1 col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT col0 * tab0.col2 + + col0 * - col2 + - col0 FROM tab0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-8987
SELECT DISTINCT - col0 + col0 + col2 DIV col2 FROM tab0
----
1

skipif mysql # not compatible
query I rowsort label-8987
SELECT DISTINCT - col0 + col0 + col2 / col2 FROM tab0
----
1

query I rowsort
SELECT + col1 + col2 + col1 AS col0 FROM tab2 AS cor0
----
144
72
89

query I rowsort
SELECT DISTINCT + tab1.col2 * - col2 + + col0 AS col2 FROM tab1
----
-2913
-3185
-9136

query I rowsort
SELECT + col2 * col0 + - col2 * - col0 AS col1 FROM tab0
----
14596
1584
70

query I rowsort
SELECT - tab2.col0 + col0 * col2 AS col0 FROM tab2
----
182
1950
2923

query I rowsort
SELECT + tab0.col1 + + tab0.col1 AS col0 FROM tab0
----
172
182
194

query I rowsort
SELECT ALL col0 * col1 + col1 AS col1 FROM tab0
----
2150
3492
8190

query I rowsort
SELECT DISTINCT - col0 * + tab1.col1 FROM tab1
----
-1040
-640
-78

query I rowsort
SELECT DISTINCT + 65 FROM tab0, tab2 AS cor0
----
65

query I rowsort
SELECT tab2.col0 * - col2 - - col0 AS col1 FROM tab2
----
-182
-1950
-2923

query I rowsort
SELECT col0 + + 45 FROM tab2
----
123
124
52

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * - ( + col0 ) + - col1 * col2 col2 FROM tab2
----
-1026
-3562
-3648

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( col2 ) * col0 col2 FROM tab2 cor0
----
189
2028
3002

query I rowsort
SELECT col2 + + 36 AS col1 FROM tab1
----
132
90
93

query I rowsort
SELECT DISTINCT - 21 + - cor0.col0 FROM tab0, tab0 AS cor0
----
-110
-45
-56

query I rowsort
SELECT ( - 10 ) FROM tab0
----
-10
-10
-10

query I rowsort
SELECT DISTINCT - 38 AS col1 FROM tab0
----
-38

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 46 col0 FROM tab1, tab2 AS cor0
----
-46

query I rowsort
SELECT ( - col0 * + col0 ) + col1 AS col0 FROM tab1
----
-4086
-6387
17

query I rowsort
SELECT DISTINCT + col1 + - col2 + - cor0.col2 FROM tab0 AS cor0
----
-73
20
95

query I rowsort
SELECT ( col0 ) + + col0 + col1 * + col1 AS col2 FROM tab0
----
7444
8459
9479

query I rowsort
SELECT DISTINCT - 45 + col0 AS col2 FROM tab1
----
-42
19
35

query I rowsort
SELECT ALL + col0 * + col2 * col0 AS col0 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT DISTINCT - + 63 + col0 * cor0.col2 AS col0 FROM tab2 AS cor0
----
126
1965
2939

query I rowsort
SELECT + 94 * col0 FROM tab1 cor0
----
282
6016
7520

query I rowsort
SELECT + - col2 + cor0.col0 * col0 AS col2 FROM tab0 cor0
----
1224
543
7839

query I rowsort
SELECT cor0.col0 + cor0.col2 * + col0 * + col2 FROM tab1 AS cor0
----
208000
737360
8751

query I rowsort
SELECT col2 * + col0 - cor0.col0 FROM tab1 AS cor0
----
159
3584
7600

query I rowsort
SELECT DISTINCT - + 77 * cor0.col2 FROM tab2 cor0
----
-2002
-2079
-2926

query I rowsort
SELECT - + 21 * + cor0.col1 AS col2 FROM tab2 AS cor0
----
-1239
-357
-651

query I rowsort
SELECT 29 * 65 + col2 AS col0 FROM tab2
----
1911
1912
1923

onlyif mysql # use DIV operator for integer division
query I rowsort label-9018
SELECT + - col2 DIV col2 AS col0 FROM tab1 cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9018
SELECT + - col2 / col2 AS col0 FROM tab1 cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9019
SELECT DISTINCT - col2 DIV col0 col0 FROM tab0
----
-1
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9019
SELECT DISTINCT - col2 / col0 col0 FROM tab0
----
-1
0

query I rowsort
SELECT - 65 * cor0.col0 AS col0 FROM tab2, tab0 AS cor0
----
9 values hashing to 8331886af9b10effd9cfe299f4aa1fcf

query I rowsort
SELECT DISTINCT - ( - 14 ) AS col1 FROM tab0
----
14

query I rowsort
SELECT + 36 * + 67 AS col1 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 6e1d1de01979bc5ff8ef16f207431b65

query I rowsort
SELECT - + ( col1 ) AS col1 FROM tab1 cor0
----
-10
-13
-26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + ( col2 ) col0 FROM tab0 cor0
----
0
0
0

query I rowsort
SELECT - - col1 - 24 FROM tab0 AS cor0
----
62
67
73

query I rowsort
SELECT + + col2 + 83 AS col0 FROM tab2 AS cor0
----
109
110
121

query I rowsort
SELECT + - col2 * - ( - col0 ) FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT col2 + - cor0.col0 AS col1 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL + col2 * + 28 + + 87 * col0 FROM tab0 cor0
----
10039
3012
3073

query I rowsort
SELECT ALL 44 FROM tab2, tab0 AS cor0
----
9 values hashing to ab2bc2b9f8baa300df7755e5980a319d

query I rowsort
SELECT 2 AS col1 FROM tab0, tab2 AS cor0
----
9 values hashing to 84dbfaf9bc17dd097f15bc36b4186261

query I rowsort
SELECT - col2 * col0 * + col0 AS col1 FROM tab1 AS cor0
----
-233472
-486
-614400

query I rowsort
SELECT + - 12 + - ( - col1 + + cor0.col2 ) * 69 AS col0 FROM tab0 cor0
----
3645
609
6612

query I rowsort
SELECT DISTINCT col2 + col0 * + col2 FROM tab2
----
2054
216
3040

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + - col0 + + cor0.col2 * col2 col1 FROM tab2 AS cor0
----
1365
598
722

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9036
SELECT CAST( 79 AS SIGNED ) FROM tab1 AS cor0
----
79
79
79

skipif mysql # not compatible
query I rowsort label-9036
SELECT CAST ( 79 AS INTEGER ) FROM tab1 AS cor0
----
79
79
79

query I rowsort
SELECT ALL - 32 * - 47 FROM tab1 AS cor0
----
1504
1504
1504

skipif mysql # not compatible
query I rowsort
SELECT CAST ( - ( + col1 ) AS REAL ) * + col0 + col0 * col2 - - cor0.col0 FROM tab0 cor0
----
-1248
-3325
-712

query I rowsort
SELECT DISTINCT - + cor0.col1 * ( + col1 + cor0.col2 * + col2 ) FROM tab1 AS cor0
----
-119977
-32590
-76492

query I rowsort
SELECT - cor0.col0 + + cor0.col1 FROM tab1 AS cor0
----
-54
-67
23

query I rowsort
SELECT DISTINCT - col2 + col0 * - col0 AS col2 FROM tab0 AS cor0
----
-1226
-609
-8003

query I rowsort
SELECT - - 55 AS col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 1626bd3008abd9f18cc88cdecf7b64d0

query I rowsort
SELECT ALL 7 + + col0 * - cor0.col1 FROM tab1 cor0
----
-1033
-633
-71

query I rowsort
SELECT ALL - 81 * col0 FROM tab0 AS cor0
----
-1944
-2835
-7209

query I rowsort
SELECT DISTINCT - + col1 * col2 - + 8 FROM tab0 AS cor0
----
-105
-2846
-7470

query I rowsort
SELECT + col0 * col0 + 5 FROM tab0 cor0
----
1230
581
7926

query I rowsort
SELECT DISTINCT 48 * col2 + + ( col1 ) * - col1 AS col0 FROM tab1 AS cor0
----
1916
2636
4439

onlyif mysql # use DIV operator for integer division
query I rowsort label-9048
SELECT DISTINCT + 35 * + cor0.col0 + col2 DIV + 63 - - cor0.col2 FROM tab1 AS cor0
----
159
2297
2897

skipif mysql # not compatible
query I rowsort label-9048
SELECT DISTINCT + 35 * + cor0.col0 + col2 / + 63 - - cor0.col2 FROM tab1 AS cor0
----
159
2297
2897

query I rowsort
SELECT + ( - cor0.col2 ) FROM tab0, tab2 AS cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT ( tab2.col2 * col0 ) AS col1 FROM tab2
----
189
2028
3002

query IIIIIIIIIIIIIII rowsort
SELECT ALL * FROM tab2, tab0 AS cor0 CROSS JOIN tab1, tab0, tab2 AS cor1
----
3645 values hashing to da83d3eeaeb9e24a3cb14bb7058757dd

query I rowsort
SELECT - col2 * col1 * col0 AS col1 FROM tab2 AS cor0
----
-119652
-51034
-5859

query I rowsort
SELECT - + cor0.col2 - col0 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT 50 AS col1 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
50

query I rowsort
SELECT col1 * + col2 * col0 FROM tab1 AS cor0
----
36480
4212
99840

query I rowsort
SELECT DISTINCT + col2 * - col1 AS col2 FROM tab0
----
-2838
-7462
-97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9057
SELECT + col0 * + CAST( NULL AS SIGNED ) * - tab0.col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9057
SELECT + col0 * + CAST ( NULL AS INTEGER ) * - tab0.col0 FROM tab0
----
NULL
NULL
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9058
SELECT CAST( NULL AS SIGNED ) AS col2 FROM tab1, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

skipif mysql # not compatible
query I rowsort label-9058
SELECT CAST ( NULL AS INTEGER ) AS col2 FROM tab1, tab2 cor0
----
9 values hashing to cd7a7901e47c15155404aff0d216fe0b

onlyif mysql # use DIV operator for integer division
query I rowsort label-9059
SELECT + + 87 + - col1 DIV col1 FROM tab2 AS cor0
----
86
86
86

skipif mysql # not compatible
query I rowsort label-9059
SELECT + + 87 + - col1 / col1 FROM tab2 AS cor0
----
86
86
86

query I rowsort
SELECT ALL - col1 * 82 AS col1 FROM tab0 AS cor0
----
-7052
-7462
-7954

query I rowsort
SELECT DISTINCT - tab0.col2 AS col2 FROM tab0, tab2, tab0 AS cor0
----
-1
-33
-82

onlyif mysql # use DIV operator for integer division
query I rowsort label-9062
SELECT - col1 DIV 91 FROM tab0
----
-1
-1
0

skipif mysql # not compatible
query I rowsort label-9062
SELECT - col1 / 91 FROM tab0
----
-1
-1
0

query I rowsort
SELECT DISTINCT col1 * + 5 AS col0 FROM tab1
----
130
50
65

query I rowsort
SELECT ALL tab2.col1 - - 31 AS col1 FROM tab2
----
48
62
90

query I rowsort
SELECT DISTINCT - col0 * - 58 - 20 FROM tab1
----
154
3692
4620

query I rowsort
SELECT DISTINCT col0 - - ( - col0 * tab0.col0 ) FROM tab0
----
-1190
-552
-7832

query I rowsort
SELECT ALL col0 + 58 AS col0 FROM tab0 AS cor0
----
147
82
93

query I rowsort
SELECT - 51 - col0 FROM tab2 AS cor0
----
-129
-130
-58

query I rowsort
SELECT col0 + col0 * + col1 * + 80 AS col2 FROM tab0 AS cor0
----
165144
271635
648009

query I rowsort
SELECT - col0 * + col1 * 21 + - col0 FROM tab1 AS cor0
----
-13504
-1641
-21920

query I rowsort
SELECT ALL - cor0.col2 + - col1 * 17 FROM tab0 AS cor0
----
-1495
-1629
-1650

query I rowsort
SELECT - col2 + col0 + + col1 FROM tab1
----
-25
-3
17

query I rowsort
SELECT DISTINCT - col1 * - col1 * 2 AS col1 FROM tab1 AS cor0
----
1352
200
338

query I rowsort
SELECT ALL - col2 + 75 AS col1 FROM tab2 AS cor0
----
37
48
49

query I rowsort
SELECT ALL + - col1 * 90 + col1 + col0 * 41 FROM tab1 AS cor0
----
-2191
1734
2123

query I rowsort
SELECT col0 * 35 * 18 FROM tab1
----
1890
40320
50400

query I rowsort
SELECT DISTINCT + + col1 * + col2 + ( - col1 ) AS col1 FROM tab2 AS cor0
----
1475
629
806

query I rowsort
SELECT - + col2 + 17 AS col0 FROM tab2 AS cor0
----
-10
-21
-9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9079
SELECT DISTINCT + col2 + + CAST( NULL AS SIGNED ) * 31 / cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9079
SELECT DISTINCT + col2 + + CAST ( NULL AS INTEGER ) * 31 / cor0.col0 AS col1 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT ALL - + col1 * + cor0.col0 FROM tab1 AS cor0
----
-1040
-640
-78

query I rowsort
SELECT + - col1 * + 74 AS col0 FROM tab2 AS cor0
----
-1258
-2294
-4366

query I rowsort
SELECT - - 17 * cor0.col2 AS col2 FROM tab1 AS cor0
----
1632
918
969

query I rowsort
SELECT col0 + + 4 FROM tab1
----
68
7
84

query I rowsort
SELECT + 39 * + col0 * - col0 + - 25 * + col0 FROM tab0
----
-23064
-311144
-48650

query I rowsort
SELECT ALL + ( 13 ) + col2 FROM tab1 AS cor0
----
109
67
70

query I rowsort
SELECT DISTINCT - 32 - col2 AS col1 FROM tab0 AS cor0
----
-114
-33
-65

query I rowsort
SELECT + cor0.col0 * + ( col1 ) FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL 89 + col2 * - col0 * 46 - + col0 FROM tab1 AS cor0
----
-167783
-353271
-7366

onlyif mysql # use DIV operator for integer division
query I rowsort label-9089
SELECT ALL + col0 DIV + col1 + 73 AS col1 FROM tab0 AS cor0
----
73
73
73

skipif mysql # not compatible
query I rowsort label-9089
SELECT ALL + col0 / + col1 + 73 AS col1 FROM tab0 AS cor0
----
73
73
73

query I rowsort
SELECT DISTINCT + ( col1 ) * - cor0.col2 - - col0 AS col2 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL + cor0.col2 + + cor0.col0 AS col0 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-9092
SELECT col1 DIV + col0 + cor0.col0 * + 46 FROM tab0 AS cor0
----
1107
1612
4095

skipif mysql # not compatible
query I rowsort label-9092
SELECT col1 / + col0 + cor0.col0 * + 46 FROM tab0 AS cor0
----
1107
1612
4095

query I rowsort
SELECT ALL col0 * col0 * - ( - col0 ) AS col0 FROM tab1 cor0
----
262144
27
512000

query I rowsort
SELECT col2 * - col2 + col1 AS col0 FROM tab2 AS cor0
----
-1427
-617
-698

query I rowsort
SELECT DISTINCT 47 * - col0 FROM tab1 AS cor0
----
-141
-3008
-3760

query I rowsort
SELECT DISTINCT - cor0.col2 + + col2 AS col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col1 * col0 - ( - 42 + + col2 ) FROM tab1 cor0
----
625
66
986

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 13 col0 FROM tab1 AS cor0
----
-13

query I rowsort
SELECT + ( 94 * col0 ) + + col0 - col1 FROM tab1
----
259
6070
7587

query I rowsort
SELECT col0 - ( col2 ) * col2 AS col0 FROM tab0
----
-1065
-6635
34

query I rowsort
SELECT col2 * col0 + col2 + 74 * + col1 * col0 FROM tab1
----
51065
5988
84736

query I rowsort
SELECT DISTINCT + 35 * col1 AS col2 FROM tab0 AS cor0
----
3010
3185
3395

query I rowsort
SELECT DISTINCT col1 + col2 * - col1 FROM tab0 AS cor0
----
-2752
-7371
0

query I rowsort
SELECT DISTINCT + + 8 * col0 AS col1 FROM tab2 AS cor0
----
56
624
632

query I rowsort
SELECT DISTINCT - - cor0.col1 FROM tab2, tab0 AS cor0
----
86
91
97

query I rowsort
SELECT ALL col1 * - col1 AS col0 FROM tab2 cor0
----
-289
-3481
-961

query I rowsort
SELECT + col2 + + col0 * + 61 FROM tab1 cor0
----
237
3961
4976

query I rowsort
SELECT ALL - - 69 * col0 AS col2 FROM tab2 AS cor0
----
483
5382
5451

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - + col0 * + col2 col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT col0 + 81 AS col1 FROM tab1 AS cor0
----
145
161
84

query I rowsort
SELECT + col2 + - 35 AS col1 FROM tab0 AS cor0
----
-2
-34
47

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9112
SELECT + + col1 + + CAST( NULL AS SIGNED ) FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9112
SELECT + + col1 + + CAST ( NULL AS INTEGER ) FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - - col1 * ( - col0 ) FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT + col1 + + 46 AS col1 FROM tab0 AS cor0
----
132
137
143

query I rowsort
SELECT ALL + 41 + col1 FROM tab2
----
100
58
72

query I rowsort
SELECT + 21 * + col1 AS col0 FROM tab1
----
210
273
546

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 26 + tab0.col1 col2 FROM tab0
----
112
117
123

query I rowsort
SELECT ALL - + col0 * - col2 AS col0 FROM tab2 AS cor0
----
189
2028
3002

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9119
SELECT + CAST( 69 AS SIGNED ) * cor0.col0 AS col0 FROM tab1 AS cor0
----
207
4416
5520

skipif mysql # not compatible
query I rowsort label-9119
SELECT + CAST ( 69 AS INTEGER ) * cor0.col0 AS col0 FROM tab1 AS cor0
----
207
4416
5520

query I rowsort
SELECT + 36 * - cor0.col2 AS col1 FROM tab0 cor0
----
-1188
-2952
-36

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9121
SELECT DISTINCT CAST( NULL AS SIGNED ) * - col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9121
SELECT DISTINCT CAST ( NULL AS INTEGER ) * - col1 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9122
SELECT + + CAST( - cor0.col0 AS SIGNED ) * col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

skipif mysql # not compatible
query I rowsort label-9122
SELECT + + CAST ( - cor0.col0 AS INTEGER ) * col2 AS col0 FROM tab2 AS cor0
----
-189
-2028
-3002

query I rowsort
SELECT ALL + col0 * - col1 + - col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT + 67 * - ( + col0 * col1 ) FROM tab0 cor0
----
-138288
-227465
-542633

query I rowsort
SELECT ALL col2 * + col1 AS col1 FROM tab2
----
1534
646
837

query I rowsort
SELECT DISTINCT + col1 * col2 + col1 AS col0 FROM tab2
----
1593
663
868

query I rowsort
SELECT ALL - 7 * col2 AS col2 FROM tab0
----
-231
-574
-7

query I rowsort
SELECT DISTINCT - cor0.col2 FROM tab2, tab1 AS cor0, tab1, tab2 AS cor1
----
-54
-57
-96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL ( + col2 ) col1 FROM tab0 AS cor0
----
1
33
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 66 * + col0 col0 FROM tab2 AS cor0
----
462
5148
5214

query I rowsort
SELECT ALL - 3 + + ( cor0.col0 ) FROM tab2 cor0
----
4
75
76

query I rowsort
SELECT DISTINCT + 7 + ( col0 ) FROM tab1 AS cor0
----
10
71
87

query I rowsort
SELECT DISTINCT + - col0 * + col0 * col0 FROM tab0 AS cor0
----
-13824
-42875
-704969

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 71 * + 59 * col1 col2 FROM tab2 AS cor0
----
-129859
-247151
-71213

query I rowsort
SELECT DISTINCT - ( - col2 ) * col1 AS col0 FROM tab1
----
1248
1404
570

query I rowsort
SELECT ALL - 98 + + col0 AS col2 FROM tab2 AS cor0
----
-19
-20
-91

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + cor0.col2 + + col0 col1 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT + col2 * + 50 * col0 FROM tab2 cor0
----
101400
150100
9450

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col2 + ( + cor0.col0 ) col2 FROM tab0 cor0
----
171
36
57

query I rowsort
SELECT DISTINCT col1 * col2 + col2 FROM tab0 AS cor0
----
2871
7544
98

query I rowsort
SELECT col2 * cor0.col2 + 18 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
3384
3429
9450

query I rowsort
SELECT ALL col1 * 76 FROM tab1
----
1976
760
988

query I rowsort
SELECT DISTINCT 48 FROM tab0, tab2 cor0, tab2 AS cor1
----
48

onlyif mysql # use DIV operator for integer division
query I rowsort label-9144
SELECT DISTINCT + + col2 DIV - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1

skipif mysql # not compatible
query I rowsort label-9144
SELECT DISTINCT + + col2 / - cor0.col2 AS col2 FROM tab0 AS cor0
----
-1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9145
SELECT - CAST( ( + col1 ) AS SIGNED ) * 35 FROM tab2 AS cor0
----
-1085
-2065
-595

skipif mysql # not compatible
query I rowsort label-9145
SELECT - CAST ( ( + col1 ) AS INTEGER ) * 35 FROM tab2 AS cor0
----
-1085
-2065
-595

onlyif mysql # use DIV operator for integer division
query I rowsort label-9146
SELECT DISTINCT col2 DIV + col1 - - col1 AS col2 FROM tab2 AS cor0
----
19
31
59

skipif mysql # not compatible
query I rowsort label-9146
SELECT DISTINCT col2 / + col1 - - col1 AS col2 FROM tab2 AS cor0
----
19
31
59

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9147
SELECT DISTINCT CAST( NULL AS SIGNED ) + - col0 * col1 * CAST( NULL AS DECIMAL ) FROM tab0 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9147
SELECT DISTINCT CAST ( NULL AS INTEGER ) + - col0 * col1 * CAST ( NULL AS REAL ) FROM tab0 AS cor0
----
NULL

query I rowsort
SELECT ALL - + 47 + + 3 FROM tab2 AS cor0
----
-44
-44
-44

query I rowsort
SELECT ( + cor1.col1 ) + + cor1.col0 FROM tab2, tab0 AS cor0, tab0 AS cor1
----
27 values hashing to 30d7054d1d16cc0cd2af7741ad06735e

onlyif mysql # use DIV operator for integer division
query I rowsort label-9150
SELECT - col2 + - ( 94 ) DIV col1 FROM tab1
----
-103
-57
-66

skipif mysql # not compatible
query I rowsort label-9150
SELECT - col2 + - ( 94 ) / col1 FROM tab1
----
-103
-57
-66

query I rowsort
SELECT col1 * 68 AS col0 FROM tab1
----
1768
680
884

query I rowsort
SELECT DISTINCT col2 * + tab0.col1 FROM tab0
----
2838
7462
97

onlyif mysql # use DIV operator for integer division
query I rowsort label-9153
SELECT - 63 * col1 + 88 + + col2 DIV col2 FROM tab0 AS cor0
----
-5329
-5644
-6022

skipif mysql # not compatible
query I rowsort label-9153
SELECT - 63 * col1 + 88 + + col2 / col2 FROM tab0 AS cor0
----
-5329
-5644
-6022

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9154
SELECT - col1 * col0 + - CAST( NULL AS SIGNED ) - + ( + col1 ) * 43 * + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9154
SELECT - col1 * col0 + - CAST ( NULL AS INTEGER ) - + ( + col1 ) * 43 * + col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - ( - col1 ) * + 74 + col1 - + cor0.col1 * - 79 AS col0 FROM tab2 AS cor0
----
2618
4774
9086

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9156
SELECT - col2 * col0 - + CAST( NULL AS SIGNED ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9156
SELECT - col2 * col0 - + CAST ( NULL AS INTEGER ) AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT col1 + col0 * + col2 + col1 FROM tab2 AS cor0
----
2146
251
3036

query I rowsort
SELECT DISTINCT 3 AS col0 FROM tab0
----
3

query I rowsort
SELECT tab0.col2 + + cor0.col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 1b6920525e1810523fdee3171c929510

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9160
SELECT DISTINCT - - CAST( NULL AS SIGNED ) FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

skipif mysql # not compatible
query I rowsort label-9160
SELECT DISTINCT - - CAST ( NULL AS INTEGER ) FROM tab0 AS cor0 CROSS JOIN tab0 AS cor1
----
NULL

query I rowsort
SELECT + tab1.col2 FROM tab1, tab1 cor0
----
9 values hashing to 80ca0a1cc337a7714a8990a764cfdb17

query I rowsort
SELECT + col1 * col0 + - col1 * - col0 FROM tab0 AS cor0
----
16198
4128
6790

query I rowsort
SELECT ALL - + col0 + col2 AS col2 FROM tab1 AS cor0
----
-7
16
51

onlyif mysql # use DIV operator for integer division
query I rowsort label-9164
SELECT ALL col1 DIV col0 col0 FROM tab0
----
1
2
3

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9164
SELECT ALL col1 / col0 col0 FROM tab0
----
1
2
3

query I rowsort
SELECT DISTINCT - 59 + - cor0.col2 FROM tab2, tab0 AS cor0, tab1 cor1
----
-141
-60
-92

query I rowsort
SELECT + col0 + - col2 * - col0 AS col1 FROM tab2
----
196
2106
3081

onlyif mysql # use DIV operator for integer division
query I rowsort label-9167
SELECT DISTINCT - 74 DIV - col1 - - col2 FROM tab0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-9167
SELECT DISTINCT - 74 / - col1 - - col2 FROM tab0
----
1
33
82

query I rowsort
SELECT + col0 - + tab2.col0 AS col0 FROM tab2
----
0
0
0

query I rowsort
SELECT + col2 + col2 + - col2 AS col0 FROM tab1
----
54
57
96

query I rowsort
SELECT + + col0 + cor0.col2 * col1 FROM tab0 cor0
----
132
2862
7551

query I rowsort
SELECT - col1 + + 65 * + 35 AS col1 FROM tab2 cor0
----
2216
2244
2258

query I rowsort
SELECT + col1 + col2 * - col0 AS col2 FROM tab0 AS cor0
----
-706
-7207
62

query I rowsort
SELECT DISTINCT - 38 * 56 FROM tab0, tab0 AS cor0
----
-2128

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col0 * - ( + col0 * col0 ) + 91 col2 FROM tab1 AS cor0
----
16777307
172
40960091

query I rowsort
SELECT ALL - col0 * col2 * + cor0.col2 AS col2 FROM tab1 AS cor0
----
-207936
-737280
-8748

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * ( + cor0.col2 ) + col1 col0 FROM tab1 AS cor0
----
-136
-3638
-7667

query I rowsort
SELECT + - col2 * + 57 AS col1 FROM tab1 AS cor0
----
-3078
-3249
-5472

query I rowsort
SELECT - col2 * + ( cor0.col1 ) + col1 AS col2 FROM tab2 cor0
----
-1475
-629
-806

query I rowsort
SELECT ALL col0 * cor0.col0 AS col1 FROM tab0 AS cor0
----
1225
576
7921

query I rowsort
SELECT ALL + + col1 * ( col0 ) * col1 + + 53 FROM tab1 AS cor0
----
13573
2081
6453

query I rowsort
SELECT col0 * - col1 - - 19 * + col2 FROM tab0 AS cor0
----
-1437
-3376
-6541

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + ( col0 ) col0 FROM tab1
----
3
64
80

query I rowsort
SELECT ALL + - cor0.col1 + 45 FROM tab2 AS cor0
----
-14
14
28

query I rowsort
SELECT ALL - - cor0.col2 * 29 - cor0.col2 AS col2 FROM tab2 AS cor0
----
1064
728
756

query I rowsort
SELECT - cor0.col0 * - cor0.col0 * col1 AS col2 FROM tab0 AS cor0
----
118825
49536
720811

query I rowsort
SELECT - col0 + 25 FROM tab2 cor0
----
-53
-54
18

query I rowsort
SELECT - 7 * - 6 FROM tab1, tab0 cor0
----
9 values hashing to 64c29db9f1cd7ed4ddeb1735e3e0d442

query I rowsort
SELECT DISTINCT + 64 + cor0.col2 * col0 AS col0 FROM tab2 AS cor0
----
2092
253
3066

query I rowsort
SELECT ALL - - 87 - col0 FROM tab2 AS cor0
----
8
80
9

query I rowsort
SELECT DISTINCT - - 48 + + col0 AS col2 FROM tab2 AS cor0
----
126
127
55

onlyif mysql # use DIV operator for integer division
query I rowsort label-9191
SELECT DISTINCT - col0 * col0 DIV col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-9191
SELECT DISTINCT - col0 * col0 / col0 FROM tab0 AS cor0
----
-24
-35
-89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 * 71 col2 FROM tab1 AS cor0
----
1846
710
923

query I rowsort
SELECT ALL col0 + + 89 * col1 FROM tab1 AS cor0
----
1237
2317
954

query I rowsort
SELECT - col2 * - cor0.col1 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT + 15 * - 32 FROM tab0 AS cor0
----
-480

query I rowsort
SELECT + 29 + - col0 FROM tab0 AS cor0
----
-6
-60
5

query I rowsort
SELECT col1 + cor0.col1 * col1 AS col2 FROM tab1 AS cor0
----
110
182
702

query I rowsort
SELECT DISTINCT - col1 * ( cor0.col2 ) FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + col1 * - col0 + cor0.col0 + - 55 FROM tab0 AS cor0
----
-2095
-3415
-8065

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col0 + - 83 col2 FROM tab1
----
-19
-3
-80

query I rowsort
SELECT - ( col0 ) * + col1 FROM tab0 AS cor0
----
-2064
-3395
-8099

onlyif mysql # use DIV operator for integer division
query I rowsort label-9202
SELECT - col2 DIV ( col2 ) + tab0.col2 * - ( - col1 * + col1 ) FROM tab0
----
244067
679041
9408

skipif mysql # not compatible
query I rowsort label-9202
SELECT - col2 / ( col2 ) + tab0.col2 * - ( - col1 * + col1 ) FROM tab0
----
244067
679041
9408

query I rowsort
SELECT cor0.col1 - 9 AS col2 FROM tab0, tab0 AS cor0, tab0 cor1
----
27 values hashing to 2d2517b4530f634c16677baaf1d60eb8

onlyif mysql # use DIV operator for integer division
query I rowsort label-9204
SELECT 97 DIV + ( - col0 ) FROM tab1
----
-1
-1
-32

skipif mysql # not compatible
query I rowsort label-9204
SELECT 97 / + ( - col0 ) FROM tab1
----
-1
-1
-32

query I rowsort
SELECT ALL ( - 32 ) AS col2 FROM tab2, tab2 AS cor0
----
9 values hashing to ef8f93119983b962f4c81381ebf4b1e6

onlyif mysql # use DIV operator for integer division
query I rowsort label-9206
SELECT - col1 + + col0 DIV ( col0 ) FROM tab2 AS cor0
----
-16
-30
-58

skipif mysql # not compatible
query I rowsort label-9206
SELECT - col1 + + col0 / ( col0 ) FROM tab2 AS cor0
----
-16
-30
-58

onlyif mysql # use DIV operator for integer division
query I rowsort label-9207
SELECT DISTINCT col0 DIV col1 + col0 FROM tab2
----
7
79
83

skipif mysql # not compatible
query I rowsort label-9207
SELECT DISTINCT col0 / col1 + col0 FROM tab2
----
7
79
83

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9208
SELECT CAST( col0 AS SIGNED ) * - col2 * + 71 + ( col2 ) + col2 AS col2 FROM tab1
----
-11394
-258894
-545088

skipif mysql # not compatible
query I rowsort label-9208
SELECT CAST ( col0 AS INTEGER ) * - col2 * + 71 + ( col2 ) + col2 AS col2 FROM tab1
----
-11394
-258894
-545088

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 30 * + col2 - col2 col0 FROM tab0 AS cor0
----
-1023
-2542
-31

query I rowsort
SELECT DISTINCT + cor0.col1 * - 64 FROM tab0 AS cor0
----
-5504
-5824
-6208

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( + col2 ) - col0 col0 FROM tab1 AS cor0
----
-7
16
51

query I rowsort
SELECT ALL cor0.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-9213
SELECT ALL - 6 + - cor0.col0 + + col0 * + CAST( - col1 AS SIGNED ) AS col2 FROM tab1 AS cor0
----
-1126
-710
-87

skipif mysql # not compatible
query I rowsort label-9213
SELECT ALL - 6 + - cor0.col0 + + col0 * + CAST ( - col1 AS INTEGER ) AS col2 FROM tab1 AS cor0
----
-1126
-710
-87

query I rowsort
SELECT - ( col1 ) + col1 * col1 AS col1 FROM tab1
----
156
650
90

onlyif mysql # use DIV operator for integer division
query I rowsort label-9215
SELECT DISTINCT + 81 + col2 DIV col0 AS col1 FROM tab2
----
81
84

skipif mysql # not compatible
query I rowsort label-9215
SELECT DISTINCT + 81 + col2 / col0 AS col1 FROM tab2
----
81
84

onlyif mysql # use DIV operator for integer division
query I rowsort label-9216
SELECT + 48 DIV - col1 AS col0 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9216
SELECT + 48 / - col1 AS col0 FROM tab0
----
0
0
0

query I rowsort
SELECT + col0 * col1 * - col0 AS col1 FROM tab2 cor0
----
-106097
-1519
-358956

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 54 col2 FROM tab0, tab0 AS cor0
----
9 values hashing to d2364c4ffc09ac2cf1f6fa4d767d8b09

query I rowsort
SELECT ALL - col1 + + ( col2 ) FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT tab1.col1 * + 47 FROM tab1, tab0 AS cor0
----
9 values hashing to 8e197b72f4a67d793e701835abe39c4b

query I rowsort
SELECT ALL - 79 * - col0 AS col1 FROM tab2
----
553
6162
6241

query I rowsort
SELECT DISTINCT + cor1.col2 * cor1.col2 AS col0 FROM tab1 cor0 CROSS JOIN tab1 AS cor1
----
2916
3249
9216

skipif mysql # not compatible
query I rowsort
SELECT col2 + - CAST ( - 30 * + tab1.col1 AS REAL ) AS col1 FROM tab1
----
357
486
834

query I rowsort
SELECT ALL + col2 * + ( col2 ) AS col2 FROM tab2
----
1444
676
729

query I rowsort
SELECT col0 + - ( + col0 ) * cor0.col1 AS col0 FROM tab0 AS cor0
----
-2040
-3360
-8010

query I rowsort
SELECT DISTINCT - - col2 + - 47 * col0 AS col2 FROM tab2 AS cor0
----
-302
-3640
-3675

query I rowsort
SELECT DISTINCT + col2 * ( ( + col2 ) ) FROM tab1
----
2916
3249
9216

query I rowsort
SELECT - col1 + - ( ( + col1 ) ) FROM tab0
----
-172
-182
-194

query I rowsort
SELECT - col0 * - ( 29 ) FROM tab0 cor0
----
1015
2581
696

query I rowsort
SELECT DISTINCT - col1 + ( + col2 ) AS col0 FROM tab0 AS cor0
----
-53
-9
-96

query I rowsort
SELECT DISTINCT + cor0.col0 * - 62 + ( + col0 ) AS col1 FROM tab2 AS cor0
----
-427
-4758
-4819

query I rowsort
SELECT DISTINCT - ( - 47 ) FROM tab2, tab0 AS cor0
----
47

query I rowsort
SELECT ALL + col1 + 93 FROM tab1 AS cor0
----
103
106
119

query I rowsort
SELECT + - col1 * - 11 * + col2 + col2 + 78 FROM tab0 cor0
----
1146
31329
82242

query I rowsort
SELECT ALL col1 * 41 + col2 FROM tab1 AS cor0
----
1120
467
629

query I rowsort
SELECT ALL + ( col2 + col2 ) FROM tab0
----
164
2
66

query I rowsort
SELECT + - col2 + - col0 * col2 FROM tab1 AS cor0
----
-216
-3705
-7776

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col1 + + ( - col2 ) * col0 col1 FROM tab0 AS cor0
----
-706
-7207
62

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9239
SELECT + + CAST( 5 AS SIGNED ) AS col0 FROM tab1 AS cor0
----
5
5
5

skipif mysql # not compatible
query I rowsort label-9239
SELECT + + CAST ( 5 AS INTEGER ) AS col0 FROM tab1 AS cor0
----
5
5
5

query I rowsort
SELECT - ( tab1.col1 ) AS col2 FROM tab1
----
-10
-13
-26

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9241
SELECT tab1.col2 * - col2 * - CAST( NULL AS DECIMAL ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9241
SELECT tab1.col2 * - col2 * - CAST ( NULL AS REAL ) FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT + 73 * col1 + col0 * 27 FROM tab1 AS cor0
----
1979
2458
3109

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort
SELECT ALL + col0 + col1 * - CAST ( col2 AS REAL ) col0 FROM tab2 AS cor0
----
-1456
-567
-830

query I rowsort
SELECT - - col2 * - 12 + + ( + cor0.col1 ) * + 42 FROM tab2 cor0
----
2166
258
978

query I rowsort
SELECT cor0.col2 + ( - ( cor0.col1 ) ) FROM tab0 AS cor0
----
-53
-9
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9246
SELECT - - col2 * col1 DIV - 33 + col1 AS col2 FROM tab0 AS cor0
----
-135
0
95

skipif mysql # not compatible
query I rowsort label-9246
SELECT - - col2 * col1 / - 33 + col1 AS col2 FROM tab0 AS cor0
----
-135
0
95

query I rowsort
SELECT + col0 + - 19 AS col2 FROM tab2 cor0
----
-12
59
60

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - cor0.col2 + - 20 col1 FROM tab1, tab0 AS cor0
----
9 values hashing to 0d021ed1ef9b97108a99b15c1d12aa9c

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 30 + - col1 * + 61 * - col0 col0 FROM tab0
----
125874
207065
494009

query I rowsort
SELECT col1 * - col1 + - 38 * col2 FROM tab1
----
-2266
-2728
-3817

query I rowsort
SELECT ALL 7 * tab2.col0 FROM tab2
----
49
546
553

query I rowsort
SELECT 12 + col1 FROM tab1 AS cor0
----
22
25
38

query I rowsort
SELECT 75 AS col2 FROM tab1, tab0 AS cor0
----
9 values hashing to 22042bfd4d787415457a42bb93d48eea

query I rowsort
SELECT + 64 * col1 * + col0 FROM tab0
----
132096
217280
518336

query I rowsort
SELECT ALL - 51 AS col2 FROM tab1, tab1 AS cor0
----
9 values hashing to 08d3853e39924d3c636260a6dd856837

onlyif mysql # use DIV operator for integer division
query I rowsort label-9256
SELECT + col1 DIV + ( + col2 ) AS col1 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9256
SELECT + col1 / + ( + col2 ) AS col1 FROM tab1
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9257
SELECT 59 DIV - col2 FROM tab0
----
-1
-59
0

skipif mysql # not compatible
query I rowsort label-9257
SELECT 59 / - col2 FROM tab0
----
-1
-59
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9258
SELECT DISTINCT 35 * tab2.col2 DIV + col0 - - col2 col1 FROM tab2
----
162
37
54

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9258
SELECT DISTINCT 35 * tab2.col2 / + col0 - - col2 col1 FROM tab2
----
162
37
54

query I rowsort
SELECT - - 3 AS col0 FROM tab1 AS cor0
----
3
3
3

query I rowsort
SELECT DISTINCT - 38 AS col0 FROM tab0, tab0 cor0
----
-38

query I rowsort
SELECT ALL - col1 + + col0 * - 60 + col1 FROM tab2 AS cor0
----
-420
-4680
-4740

query I rowsort
SELECT + col1 * col0 + col2 * col1 FROM tab0 cor0
----
15561
3492
4902

query I rowsort
SELECT 43 + col0 AS col2 FROM tab1 AS cor0
----
107
123
46

query I rowsort
SELECT - col2 * 31 * + col1 AS col1 FROM tab1
----
-17670
-38688
-43524

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9265
SELECT CAST( NULL AS SIGNED ) / tab1.col1 AS col2 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9265
SELECT CAST ( NULL AS INTEGER ) / tab1.col1 AS col2 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - col0 * cor0.col1 AS col0 FROM tab1 cor0
----
-1040
-640
-78

onlyif mysql # use DIV operator for integer division
query I rowsort label-9267
SELECT - col2 DIV - 72 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9267
SELECT - col2 / - 72 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - + col2 * ( + col1 ) * - col2 AS col0 FROM tab0 AS cor0
----
611884
93654
97

query I rowsort
SELECT DISTINCT - tab2.col1 * col1 * - col0 AS col2 FROM tab2
----
22831
271518
6727

query I rowsort
SELECT DISTINCT - tab1.col0 * + tab1.col2 FROM tab1
----
-162
-3648
-7680

query I rowsort
SELECT DISTINCT - - col0 * 13 FROM tab0 AS cor0
----
1157
312
455

query I rowsort
SELECT - 79 AS col0 FROM tab2, tab2 AS cor0
----
9 values hashing to 1b7b0b34fe3431fb409719624d12791f

query I rowsort
SELECT ALL - col2 * col1 + - col1 AS col0 FROM tab0 AS cor0
----
-194
-2924
-7553

query I rowsort
SELECT DISTINCT - col1 * col1 + col1 * - col2 AS col2 FROM tab0 AS cor0
----
-10234
-15743
-9506

onlyif mysql # use DIV operator for integer division
query I rowsort label-9275
SELECT DISTINCT + 8 DIV cor0.col1 FROM tab1 cor0
----
0

skipif mysql # not compatible
query I rowsort label-9275
SELECT DISTINCT + 8 / cor0.col1 FROM tab1 cor0
----
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9276
SELECT + col1 DIV - ( - col2 ) FROM tab0 AS cor0
----
1
2
97

skipif mysql # not compatible
query I rowsort label-9276
SELECT + col1 / - ( - col2 ) FROM tab0 AS cor0
----
1
2
97

query I rowsort
SELECT ALL - ( + ( - col2 ) ) * - col2 AS col2 FROM tab2 AS cor0
----
-1444
-676
-729

query I rowsort
SELECT ALL col0 * - 75 AS col0 FROM tab2 cor0
----
-525
-5850
-5925

query I rowsort
SELECT ALL - - col1 + - col2 * col2 FROM tab0 AS cor0
----
-1003
-6633
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9280
SELECT ALL - + ( - 48 ) DIV cor0.col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9280
SELECT ALL - + ( - 48 ) / cor0.col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT + col0 + 92 * + col2 FROM tab2 AS cor0
----
2470
2491
3575

onlyif mysql # use DIV operator for integer division
query I rowsort label-9282
SELECT + - 24 * 37 DIV col1 AS col0 FROM tab0 cor0
----
-10
-9
-9

skipif mysql # not compatible
query I rowsort label-9282
SELECT + - 24 * 37 / col1 AS col0 FROM tab0 cor0
----
-10
-9
-9

query I rowsort
SELECT DISTINCT col2 * 59 AS col0 FROM tab1
----
3186
3363
5664

query I rowsort
SELECT + 86 * 16 AS col2 FROM tab2 AS cor0
----
1376
1376
1376

query I rowsort
SELECT 89 AS col1 FROM tab0 cor0
----
89
89
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 76 col2 FROM tab0 AS cor0
----
-76

query I rowsort
SELECT - 55 * col2 AS col0 FROM tab2 AS cor0
----
-1430
-1485
-2090

query I rowsort
SELECT + 67 AS col1 FROM tab0 AS cor0
----
67
67
67

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9289
SELECT - col0 * - cor0.col0 * + CAST( NULL AS SIGNED ) + - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9289
SELECT - col0 * - cor0.col0 * + CAST ( NULL AS INTEGER ) + - col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9290
SELECT - col0 DIV col0 + + col1 AS col2 FROM tab2 AS cor0
----
16
30
58

skipif mysql # not compatible
query I rowsort label-9290
SELECT - col0 / col0 + + col1 AS col2 FROM tab2 AS cor0
----
16
30
58

query I rowsort
SELECT - col0 - - col0 AS col0 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9292
SELECT col1 * - CAST( col0 AS SIGNED ) AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

skipif mysql # not compatible
query I rowsort label-9292
SELECT col1 * - CAST ( col0 AS INTEGER ) AS col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + col1 * tab1.col2 + 83 AS col0 FROM tab1
----
1331
1487
653

query I rowsort
SELECT DISTINCT + cor0.col2 + - cor0.col1 AS col1 FROM tab1 AS cor0
----
28
47
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-9295
SELECT - col1 + col0 DIV cor0.col0 FROM tab0 AS cor0
----
-85
-90
-96

skipif mysql # not compatible
query I rowsort label-9295
SELECT - col1 + col0 / cor0.col0 FROM tab0 AS cor0
----
-85
-90
-96

query I rowsort
SELECT DISTINCT - col2 + - col0 * - col0 * col1 FROM tab2 AS cor0
----
106059
1492
358930

query I rowsort
SELECT - ( cor0.col0 ) * + cor0.col0 FROM tab2, tab2 AS cor0
----
9 values hashing to f921d4cdc13dc0e8c0388ccf3f81ffc1

query I rowsort
SELECT ALL - + col0 * 53 * + col0 AS col0 FROM tab0 AS cor0
----
-30528
-419813
-64925

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 + - col0 * + col2 col0 FROM tab1 AS cor0
----
-216
-3705
-7776

onlyif mysql # use DIV operator for integer division
query I rowsort label-9300
SELECT DISTINCT - - 90 DIV + col2 AS col1 FROM tab1 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-9300
SELECT DISTINCT - - 90 / + col2 AS col1 FROM tab1 AS cor0
----
0
1

query I rowsort
SELECT col2 + - col1 * + ( col2 ) AS col1 FROM tab0
----
-2805
-7380
-96

query I rowsort
SELECT ALL - col2 * col1 + 8 FROM tab0 AS cor0
----
-2830
-7454
-89

query I rowsort
SELECT DISTINCT + col1 + + col1 * 71 + col2 AS col1 FROM tab0 AS cor0
----
6225
6634
6985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + 6 - + cor0.col0 col2 FROM tab1 cor0
----
-58
-74
3

query I rowsort
SELECT + 42 * + col2 FROM tab1 AS cor0
----
2268
2394
4032

query I rowsort
SELECT DISTINCT col2 * cor0.col1 * ( ( - cor0.col1 ) * ( - col1 ) ) AS col2 FROM tab1 AS cor0
----
210912
57000
949104

query I rowsort
SELECT DISTINCT + 59 AS col2 FROM tab0, tab0 AS cor0, tab2 AS cor1, tab1, tab2 cor2
----
59

query I rowsort
SELECT DISTINCT + col0 + + col1 * 40 AS col1 FROM tab1 AS cor0
----
1043
464
600

query I rowsort
SELECT + 30 AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to da5de0c411a2c0f445400f1b63ea9f89

query I rowsort
SELECT ALL + ( + col2 ) AS col0 FROM tab0 AS cor0
----
1
33
82

query I rowsort
SELECT DISTINCT + - cor0.col2 + 86 AS col1 FROM tab1 cor0
----
-10
29
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 22 * cor0.col2 + + col1 col0 FROM tab0 AS cor0
----
119
1895
812

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9313
SELECT DISTINCT - - CAST( + col2 AS SIGNED ) col1 FROM tab2 AS cor0
----
26
27
38

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9313
SELECT DISTINCT - - CAST ( + col2 AS INTEGER ) col1 FROM tab2 AS cor0
----
26
27
38

query I rowsort
SELECT ALL 19 AS col2 FROM tab0 AS cor0
----
19
19
19

query I rowsort
SELECT ALL + 4 * - 1 FROM tab2 AS cor0
----
-4
-4
-4

query I rowsort
SELECT DISTINCT - col2 * + col1 + + 81 * tab2.col1 FROM tab2
----
1674
3245
731

query I rowsort
SELECT col1 + col1 * col0 - + col0 AS col0 FROM tab2
----
1281
241
4583

onlyif mysql # use DIV operator for integer division
query I rowsort label-9318
SELECT ALL col0 DIV - 19 AS col1 FROM tab0
----
-1
-1
-4

skipif mysql # not compatible
query I rowsort label-9318
SELECT ALL col0 / - 19 AS col1 FROM tab0
----
-1
-1
-4

query I rowsort
SELECT DISTINCT + 80 AS col2 FROM tab0, tab0 cor0
----
80

query I rowsort
SELECT ( col2 * tab0.col0 ) FROM tab0
----
35
7298
792

query I rowsort
SELECT DISTINCT col0 * + 54 * + col1 FROM tab1
----
34560
4212
56160

onlyif mysql # use DIV operator for integer division
query I rowsort label-9322
SELECT DISTINCT + col2 DIV + 78 FROM tab1
----
0
1

skipif mysql # not compatible
query I rowsort label-9322
SELECT DISTINCT + col2 / + 78 FROM tab1
----
0
1

query I rowsort
SELECT DISTINCT - + col1 + col1 * col2 FROM tab0 AS cor0
----
0
2752
7371

query I rowsort
SELECT + 22 AS col0 FROM tab0, tab1 AS cor0
----
9 values hashing to c55ee7433d8d39a59b1de2aadd9538c9

query I rowsort
SELECT - + col2 + + col0 * col1 AS col2 FROM tab0 cor0
----
2031
3394
8017

query I rowsort
SELECT - ( - col0 ) * col2 AS col1 FROM tab0
----
35
7298
792

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT 73 col2 FROM tab1
----
73

query I rowsort
SELECT + ( - 50 ) * + tab0.col1 FROM tab0
----
-4300
-4550
-4850

query I rowsort
SELECT - - col1 + + cor0.col1 + - 52 FROM tab1 AS cor0
----
-26
-32
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9330
SELECT + CAST( NULL AS SIGNED ) AS col0 FROM tab2, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9330
SELECT + CAST ( NULL AS INTEGER ) AS col0 FROM tab2, tab1 AS cor0 CROSS JOIN tab0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT + 32 AS col1 FROM tab1
----
32
32
32

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT col0 * col2 * - 80 col0 FROM tab1
----
-12960
-291840
-614400

query I rowsort
SELECT DISTINCT - 56 * + col1 FROM tab2
----
-1736
-3304
-952

query I rowsort
SELECT ALL - col0 * col0 + - 43 * col1 FROM tab2
----
-1382
-6972
-8621

query I rowsort
SELECT ALL ( ( - tab2.col2 ) ) FROM tab2, tab2 AS cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

query I rowsort
SELECT ALL col0 + - col0 * col1 * col1 FROM tab1
----
-13440
-2025
-6336

query I rowsort
SELECT + col1 * + 32 - 70 * - col2 * col2 AS col1 FROM tab0 AS cor0
----
3174
473592
78982

query I rowsort
SELECT DISTINCT - col2 * ( - col1 ) + col1 FROM tab1 AS cor0
----
1261
1430
580

query I rowsort
SELECT DISTINCT - col2 + 95 FROM tab2 AS cor0
----
57
68
69

onlyif mysql # use DIV operator for integer division
query I rowsort label-9340
SELECT ALL col1 + 13 DIV 13 AS col1 FROM tab1 AS cor0
----
11
14
27

skipif mysql # not compatible
query I rowsort label-9340
SELECT ALL col1 + 13 / 13 AS col1 FROM tab1 AS cor0
----
11
14
27

query I rowsort
SELECT ALL + + col1 - + col1 FROM tab0 AS cor0
----
0
0
0

query I rowsort
SELECT - col1 * 94 - cor0.col0 AS col2 FROM tab1 AS cor0
----
-1004
-1302
-2447

query I rowsort
SELECT ALL - ( col0 ) * - col1 + + col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL - col1 + + 55 * col1 * col2 AS col1 FROM tab2 AS cor0
----
35513
46004
84311

query I rowsort
SELECT DISTINCT - col2 * - col0 * col0 AS col1 FROM tab0 cor0
----
1225
19008
649522

query I rowsort
SELECT ALL - + 97 * 50 + + col2 FROM tab1 AS cor0
----
-4754
-4793
-4796

query I rowsort
SELECT - col1 * col0 * + col0 - - col2 FROM tab1 AS cor0
----
-180
-40903
-83104

query I rowsort
SELECT ALL - 72 + col1 * col2 FROM tab2 AS cor0
----
1462
574
765

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9349
SELECT DISTINCT CAST( NULL AS SIGNED ) * 40 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9349
SELECT DISTINCT CAST ( NULL AS INTEGER ) * 40 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT + - 25 + - ( col0 ) AS col0 FROM tab2 AS cor0
----
-103
-104
-32

onlyif mysql # use DIV operator for integer division
query I rowsort label-9351
SELECT ALL + + 95 + + col2 DIV + col1 FROM tab1 AS cor0
----
100
102
97

skipif mysql # not compatible
query I rowsort label-9351
SELECT ALL + + 95 + + col2 / + col1 FROM tab1 AS cor0
----
100
102
97

query I rowsort
SELECT 33 * + cor0.col0 AS col1 FROM tab2 AS cor0
----
231
2574
2607

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9353
SELECT + ( col1 ) * + cor0.col2 + 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-9353
SELECT + ( col1 ) * + cor0.col2 + CAST ( NULL AS INTEGER ) col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9354
SELECT ALL - col1 + col1 DIV - ( + col2 ) AS col2 FROM tab1
----
-10
-13
-26

skipif mysql # not compatible
query I rowsort label-9354
SELECT ALL - col1 + col1 / - ( + col2 ) AS col2 FROM tab1
----
-10
-13
-26

query I rowsort
SELECT - col0 + ( col1 ) * cor0.col0 FROM tab2 AS cor0
----
1264
210
4524

query I rowsort
SELECT ALL + tab1.col0 * col2 * col2 FROM tab1
----
207936
737280
8748

query I rowsort
SELECT ALL 21 * + col1 FROM tab1 AS cor0
----
210
273
546

query I rowsort
SELECT 17 * 80 * col2 FROM tab0
----
111520
1360
44880

query I rowsort
SELECT - + 66 FROM tab1, tab2, tab2 AS cor0
----
27 values hashing to cd4a3594ee8b45223ebf9f25840cd112

query I rowsort
SELECT + - col2 * ( cor0.col1 ) FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT ( + ( - col1 ) ) * col1 FROM tab0
----
-7396
-8281
-9409

query I rowsort
SELECT - ( col1 ) + - col2 * + ( col0 ) * col0 + col1 FROM tab1
----
-233472
-486
-614400

query I rowsort
SELECT cor0.col1 + - 16 FROM tab1 AS cor0
----
-3
-6
10

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - + 34 * col1 col1 FROM tab1 AS cor0
----
-340
-442
-884

query I rowsort
SELECT + - col0 * 2 FROM tab1 AS cor0
----
-128
-160
-6

query I rowsort
SELECT ALL + ( - col1 ) AS col2 FROM tab2
----
-17
-31
-59

query I rowsort
SELECT ALL 77 + + col2 FROM tab1
----
131
134
173

query I rowsort
SELECT cor0.col2 * 12 FROM tab0 AS cor0
----
12
396
984

query I rowsort
SELECT + + cor0.col1 * col1 AS col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT - col1 * - 68 FROM tab0 AS cor0
----
5848
6188
6596

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col2 * ( + 75 ) + col1 - ( - cor0.col0 + - col2 ) col2 FROM tab0 AS cor0
----
-2332
-5888
58

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL cor0.col0 * + 17 col0 FROM tab0 AS cor0
----
1513
408
595

query I rowsort
SELECT ALL col2 * + 62 + - cor0.col0 * - cor0.col2 AS col1 FROM tab0 cor0
----
12382
2838
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9374
SELECT ALL - col1 * - CAST( - cor0.col2 AS SIGNED ) FROM tab2 AS cor0
----
-1534
-646
-837

skipif mysql # not compatible
query I rowsort label-9374
SELECT ALL - col1 * - CAST ( - cor0.col2 AS INTEGER ) FROM tab2 AS cor0
----
-1534
-646
-837

query I rowsort
SELECT + col1 + ( + 92 ) FROM tab2 AS cor0
----
109
123
151

onlyif mysql # use DIV operator for integer division
query I rowsort label-9376
SELECT DISTINCT col2 DIV ( + col2 * col1 ) col0 FROM tab1 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9376
SELECT DISTINCT col2 / ( + col2 * col1 ) col0 FROM tab1 AS cor0
----
0

query I rowsort
SELECT ALL - col0 * + 32 - cor0.col2 * col0 AS col2 FROM tab2 AS cor0
----
-413
-4524
-5530

query I rowsort
SELECT - tab2.col2 + - tab2.col1 * - col1 FROM tab2
----
251
3455
934

query I rowsort
SELECT ALL - col2 + - ( + col0 ) FROM tab0 cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT col2 - cor0.col2 FROM tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT + col0 * ( col0 ) FROM tab0 AS cor0
----
1225
576
7921

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 cor0, tab0 AS cor1, tab2 cor2
----
972 values hashing to a9068b700464993db9fae6f630605fde

query I rowsort
SELECT DISTINCT + ( col0 ) + col1 AS col1 FROM tab2 AS cor0
----
137
38
96

skipif mysql # not compatible
query I rowsort
SELECT ALL CAST ( cor0.col1 AS REAL ) - + col2 / 48 FROM tab0 AS cor0
----
86
90
97

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9385
SELECT DISTINCT + CAST( NULL AS SIGNED ) * ( - col0 ) + ( + 10 ) + col1 FROM tab0 cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9385
SELECT DISTINCT + CAST ( NULL AS INTEGER ) * ( - col0 ) + ( + 10 ) + col1 FROM tab0 cor0
----
NULL

query I rowsort
SELECT ALL + col1 + + cor0.col2 * - col1 FROM tab0 cor0
----
-2752
-7371
0

query I rowsort
SELECT ALL + col2 + cor0.col2 * col0 AS col2 FROM tab2 AS cor0
----
2054
216
3040

query I rowsort
SELECT ALL - 84 * - ( + col0 ) * - col1 AS col1 FROM tab2 AS cor0
----
-112812
-18228
-386568

query I rowsort
SELECT DISTINCT col2 * 16 + col2 AS col2 FROM tab2 AS cor0
----
442
459
646

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9390
SELECT DISTINCT - - CAST( + col0 AS SIGNED ) * - cor0.col2 * - col0 + ( col0 ) * + col0 AS col1 FROM tab0 cor0
----
19584
2450
657443

skipif mysql # not compatible
query I rowsort label-9390
SELECT DISTINCT - - CAST ( + col0 AS INTEGER ) * - cor0.col2 * - col0 + ( col0 ) * + col0 AS col1 FROM tab0 cor0
----
19584
2450
657443

query I rowsort
SELECT DISTINCT - col1 - + 60 FROM tab0 AS cor0
----
-146
-151
-157

query I rowsort
SELECT + col2 * - col1 * - col0 + col0 FROM tab1
----
36544
4215
99920

query I rowsort
SELECT + col1 * - col0 + 29 * col2 * + col1 AS col1 FROM tab2
----
17391
24056
39884

query I rowsort
SELECT DISTINCT + 65 AS col1 FROM tab1, tab0 AS cor0
----
65

onlyif mysql # use DIV operator for integer division
query I rowsort label-9395
SELECT DISTINCT - ( col1 ) + - col2 DIV + cor0.col0 FROM tab1 cor0
----
-10
-14
-44

skipif mysql # not compatible
query I rowsort label-9395
SELECT DISTINCT - ( col1 ) + - col2 / + cor0.col0 FROM tab1 cor0
----
-10
-14
-44

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col0 + + col2 col2 FROM tab2 AS cor0
----
104
117
34

query I rowsort
SELECT ALL cor0.col2 * - col0 FROM tab1 AS cor0
----
-162
-3648
-7680

query I rowsort
SELECT ALL - 3 + + col1 FROM tab1 AS cor0
----
10
23
7

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - cor0.col2 col0 FROM tab1 cor0
----
54
57
96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9400
SELECT + - col2 - + col0 DIV + col0 AS col2 FROM tab0 cor0
----
-2
-34
-83

skipif mysql # not compatible
query I rowsort label-9400
SELECT + - col2 - + col0 / + col0 AS col2 FROM tab0 cor0
----
-2
-34
-83

query I rowsort
SELECT DISTINCT - - cor0.col1 AS col0 FROM tab1 AS cor0
----
10
13
26

onlyif mysql # use DIV operator for integer division
query I rowsort label-9402
SELECT + col2 + col0 DIV CAST( - cor0.col2 + col0 * 29 AS SIGNED ) FROM tab1 AS cor0
----
54
57
96

skipif mysql # not compatible
query I rowsort label-9402
SELECT + col2 + col0 / CAST ( - cor0.col2 + col0 * 29 AS INTEGER ) FROM tab1 AS cor0
----
54
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 29 col0 FROM tab1
----
29

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9404
SELECT CAST( NULL AS SIGNED ) + + col0 - - col0 * ( - 34 ) FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9404
SELECT CAST ( NULL AS INTEGER ) + + col0 - - col0 * ( - 34 ) FROM tab1
----
NULL
NULL
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT col1 + - cor0.col0 col1 FROM tab1 AS cor0
----
-54
-67
23

onlyif mysql # use DIV operator for integer division
query I rowsort label-9406
SELECT ALL + col0 + + col2 DIV + cor0.col1 FROM tab2 cor0
----
7
78
81

skipif mysql # not compatible
query I rowsort label-9406
SELECT ALL + col0 + + col2 / + cor0.col1 FROM tab2 cor0
----
7
78
81

query I rowsort
SELECT ALL + 36 AS col0 FROM tab0 cor0
----
36
36
36

onlyif mysql # use DIV operator for integer division
query I rowsort label-9408
SELECT - col2 DIV - col1 AS col2 FROM tab0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9408
SELECT - col2 / - col1 AS col2 FROM tab0
----
0
0
0

query I rowsort
SELECT + 42 * 44 * + col0 AS col2 FROM tab1
----
118272
147840
5544

query I rowsort
SELECT DISTINCT + col2 + - col1 * col1 FROM tab0
----
-7363
-8199
-9408

query I rowsort
SELECT ( col1 ) * + col1 AS col2 FROM tab2
----
289
3481
961

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9412
SELECT - CAST( col2 AS SIGNED ) + - col0 * - col2 FROM tab0
----
34
7216
759

skipif mysql # not compatible
query I rowsort label-9412
SELECT - CAST ( col2 AS INTEGER ) + - col0 * - col2 FROM tab0
----
34
7216
759

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9413
SELECT ALL - CAST( NULL AS SIGNED ) FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

skipif mysql # not compatible
query I rowsort label-9413
SELECT ALL - CAST ( NULL AS INTEGER ) FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 16be8868a1e6f4e8850509f9327afe90

query I rowsort
SELECT ALL 53 * tab2.col1 FROM tab2, tab1 AS cor0
----
9 values hashing to 50b30f82362dcc3395e29d5b7046c8aa

query I rowsort
SELECT - + ( + 38 ) + col1 AS col1 FROM tab1 AS cor0
----
-12
-25
-28

query I rowsort
SELECT ALL - ( col1 ) * cor0.col0 FROM tab0 AS cor0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL - 26 * - col0 FROM tab0 AS cor0
----
2314
624
910

query I rowsort
SELECT ALL 73 AS col1 FROM tab1 AS cor0
----
73
73
73

query I rowsort
SELECT DISTINCT + ( col0 + + col1 ) FROM tab1
----
29
74
93

query I rowsort
SELECT col0 * 47 FROM tab0
----
1128
1645
4183

query I rowsort
SELECT DISTINCT + + 2 + - col2 FROM tab1 AS cor0
----
-52
-55
-94

onlyif mysql # use DIV operator for integer division
query I rowsort label-9422
SELECT DISTINCT - 76 DIV + col2 FROM tab0 AS cor0
----
-2
-76
0

skipif mysql # not compatible
query I rowsort label-9422
SELECT DISTINCT - 76 / + col2 FROM tab0 AS cor0
----
-2
-76
0

query I rowsort
SELECT col1 + + cor0.col1 AS col2 FROM tab0 AS cor0
----
172
182
194

query I rowsort
SELECT + 25 * - col1 AS col0 FROM tab0 AS cor0
----
-2150
-2275
-2425

query I rowsort
SELECT ( col0 ) * + col2 + - col1 + + col1 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT - 80 * - cor0.col2 * col0 FROM tab0 AS cor0
----
2800
583840
63360

query I rowsort
SELECT DISTINCT + 98 * col2 + 79 AS col1 FROM tab1 AS cor0
----
5371
5665
9487

query I rowsort
SELECT - col0 * col2 + col2 AS col0 FROM tab2
----
-162
-2002
-2964

query I rowsort
SELECT DISTINCT + - col0 * 64 FROM tab0 AS cor0
----
-1536
-2240
-5696

query I rowsort
SELECT + col0 * + col1 - + 6 * - col1 FROM tab2 cor0
----
1445
403
4956

query I rowsort
SELECT ALL + col1 * 40 + + col1 FROM tab0 AS cor0
----
3526
3731
3977

onlyif mysql # use DIV operator for integer division
query I rowsort label-9432
SELECT + col0 * col2 DIV cor0.col2 + col1 DIV + col0 AS col2 FROM tab0 AS cor0
----
27
37
90

skipif mysql # not compatible
query I rowsort label-9432
SELECT + col0 * col2 / cor0.col2 + col1 / + col0 AS col2 FROM tab0 AS cor0
----
27
37
90

query I rowsort
SELECT tab2.col0 + 32 + col0 FROM tab2
----
188
190
46

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1 AS cor0 CROSS JOIN tab2, tab2 AS cor1, tab2 AS cor2, tab0 AS cor3
----
3645 values hashing to 5ec52b92c3c8d78cc0a61df3fc16f18b

query I rowsort
SELECT - - col2 * + col0 + - col1 FROM tab0 cor0
----
-62
706
7207

query I rowsort
SELECT + col1 + + 15 * 47 AS col0 FROM tab1 AS cor0
----
715
718
731

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9437
SELECT DISTINCT + col1 * - CAST( NULL AS DECIMAL ) + + 78 / + col1 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9437
SELECT DISTINCT + col1 * - CAST ( NULL AS REAL ) + + 78 / + col1 AS col0 FROM tab2 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + col1 + 28 AS col0 FROM tab0 AS cor0
----
114
119
125

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col0 + - col1 * - col1 col0 FROM tab2 cor0
----
3559
368
968

query I rowsort
SELECT ALL - + cor0.col1 * - col2 AS col1 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL - col0 * ( cor0.col2 ) FROM tab0 AS cor0
----
-35
-7298
-792

query I rowsort
SELECT - col0 * col1 - 2 * col0 * - ( + col1 ) AS col2 FROM tab2 AS cor0
----
1343
217
4602

query I rowsort
SELECT ALL - col0 + + 50 AS col2 FROM tab0 AS cor0
----
-39
15
26

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - col0 - + col0 col1 FROM tab2 AS cor0
----
0

query I rowsort
SELECT - col0 * - 14 + 35 FROM tab0 AS cor0
----
1281
371
525

query I rowsort
SELECT + + col1 * ( - col2 ) AS col0 FROM tab0 AS cor0
----
-2838
-7462
-97

query I rowsort
SELECT + + col1 + col2 + col2 * - col1 AS col0 FROM tab0 AS cor0
----
-2719
-7289
1

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9448
SELECT DISTINCT - CAST( NULL AS DECIMAL ) / - cor0.col0 AS col0 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9448
SELECT DISTINCT - CAST ( NULL AS REAL ) / - cor0.col0 AS col0 FROM tab2 AS cor0
----
NULL

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9449
SELECT DISTINCT CAST( + ( col2 ) AS SIGNED ) FROM tab0 cor0
----
1
33
82

skipif mysql # not compatible
query I rowsort label-9449
SELECT DISTINCT CAST ( + ( col2 ) AS INTEGER ) FROM tab0 cor0
----
1
33
82

query I rowsort
SELECT ALL + - 60 + col0 FROM tab0 AS cor0
----
-25
-36
29

query I rowsort
SELECT - col1 * col0 + + col1 + + col0 AS col1 FROM tab2
----
-1247
-179
-4465

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9452
SELECT CAST( NULL AS SIGNED ) * 0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9452
SELECT CAST ( NULL AS INTEGER ) * 0 AS col1 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ( - col1 ) + col1 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT ALL - col0 * + col1 - + col1 * 53 AS col2 FROM tab1 AS cor0
----
-1170
-1456
-1729

query I rowsort
SELECT + 55 * - col2 * + col0 + - 21 FROM tab2 cor0
----
-10416
-111561
-165131

query I rowsort
SELECT DISTINCT - col2 * + col2 + + col1 * - col1 + cor0.col0 * + cor0.col2 * + 23 AS col0 FROM tab0 cor0
----
-8605
152849
9731

query I rowsort
SELECT + 34 - + 46 * cor0.col0 FROM tab1 cor0
----
-104
-2910
-3646

query I rowsort
SELECT - tab1.col2 + + col1 * col0 + + tab1.col2 FROM tab1
----
1040
640
78

query I rowsort
SELECT - + cor0.col1 - - col1 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT - 62 * - col1 FROM tab2 AS cor0
----
1054
1922
3658

query I rowsort
SELECT 77 + - cor0.col2 AS col0 FROM tab1 AS cor0
----
-19
20
23

query I rowsort
SELECT + - col1 * - 31 * col0 AS col2 FROM tab2 AS cor0
----
142662
41633
6727

query I rowsort
SELECT - ( 15 ) FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 1172c9a62bdad7db0def9205c06ee1f2

query I rowsort
SELECT - col2 + 93 * + col0 FROM tab2 AS cor0
----
624
7228
7309

query I rowsort
SELECT DISTINCT + ( 83 ) AS col2 FROM tab0 AS cor0 CROSS JOIN tab1 AS cor1
----
83

query I rowsort
SELECT + ( - cor1.col2 ) - - cor1.col2 FROM tab1 AS cor0 CROSS JOIN tab1 AS cor1
----
9 values hashing to 8b75136b2b51c77345c03804ec1cda5c

query I rowsort
SELECT - 29 * + 70 + cor0.col0 FROM tab1, tab2 AS cor0
----
9 values hashing to 7d10b36ed0b95718053609c072f478a1

query I rowsort
SELECT ALL + col1 + 27 FROM tab2
----
44
58
86

query I rowsort
SELECT DISTINCT col1 + - 8 * - 88 FROM tab1
----
714
717
730

query I rowsort
SELECT ALL - col1 + ( + col0 ) * + col2 FROM tab2
----
158
1969
2985

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 21 col0 FROM tab2, tab1 AS cor0
----
9 values hashing to c5272facdaaa11f884c8cc0d9d4f41c7

query I rowsort
SELECT - - col0 * 25 FROM tab1 AS cor0
----
1600
2000
75

query I rowsort
SELECT DISTINCT col2 - - col2 * 20 FROM tab1 AS cor0
----
1134
1197
2016

onlyif mysql # use DIV operator for integer division
query I rowsort label-9474
SELECT ALL + - 47 DIV col2 FROM tab1 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9474
SELECT ALL + - 47 / col2 FROM tab1 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT + 99 * - col0 AS col1 FROM tab2 AS cor0
----
-693
-7722
-7821

onlyif mysql # use DIV operator for integer division
query I rowsort label-9476
SELECT - col0 DIV + cor0.col1 AS col2 FROM tab1 AS cor0
----
-6
-6
0

skipif mysql # not compatible
query I rowsort label-9476
SELECT - col0 / + cor0.col1 AS col2 FROM tab1 AS cor0
----
-6
-6
0

query I rowsort
SELECT + - col0 + - col1 AS col1 FROM tab0 AS cor0
----
-110
-132
-180

query I rowsort
SELECT - ( col0 ) + 26 FROM tab1 AS cor0
----
-38
-54
23

query I rowsort
SELECT ALL + tab0.col2 * + cor0.col0 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to caa3e6469432624a16bd3084f5c6de58

query I rowsort
SELECT ALL 50 * + col0 AS col0 FROM tab2
----
350
3900
3950

query I rowsort
SELECT tab0.col2 * + ( col2 ) FROM tab0
----
1
1089
6724

query I rowsort
SELECT + 91 FROM tab1, tab2 AS cor0
----
9 values hashing to 5748627ef5fd86a21cd559fd278d7277

query I rowsort
SELECT - 38 * + cor0.col2 AS col1 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to eb6ccb02fabb86b472870f1865ca24b5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9484
SELECT col2 * CAST( col1 AS SIGNED ) FROM tab2
----
1534
646
837

skipif mysql # not compatible
query I rowsort label-9484
SELECT col2 * CAST ( col1 AS INTEGER ) FROM tab2
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + - col1 * col0 col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT + 77 * + col1 + cor0.col1 AS col1 FROM tab0 AS cor0
----
6708
7098
7566

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9487
SELECT + CAST( NULL AS SIGNED ) * - cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9487
SELECT + CAST ( NULL AS INTEGER ) * - cor0.col2 FROM tab0 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT - 25 + col1 FROM tab0 AS cor0
----
61
66
72

query I rowsort
SELECT + 75 * 16 AS col2 FROM tab1 AS cor0
----
1200
1200
1200

query I rowsort
SELECT - col1 + 1 FROM tab1 cor0
----
-12
-25
-9

onlyif mysql # use DIV operator for integer division
query I rowsort label-9491
SELECT cor0.col0 + col0 DIV col0 FROM tab1 AS cor0
----
4
65
81

skipif mysql # not compatible
query I rowsort label-9491
SELECT cor0.col0 + col0 / col0 FROM tab1 AS cor0
----
4
65
81

query I rowsort
SELECT ALL 29 * 0 + + col1 AS col2 FROM tab0
----
86
91
97

query I rowsort
SELECT DISTINCT 2 AS col1 FROM tab1, tab0 AS cor0
----
2

query I rowsort
SELECT ALL tab0.col0 FROM tab1, tab2, tab1 AS cor0, tab0
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

query I rowsort
SELECT ALL + + 56 FROM tab2 AS cor0
----
56
56
56

query I rowsort
SELECT ALL cor1.col0 FROM tab2, tab1 AS cor0, tab0 AS cor1, tab0 AS cor2
----
81 values hashing to 2304fcc140e955eb2d1ee28ab1eea994

query I rowsort
SELECT ALL + 24 * col2 FROM tab1 cor0
----
1296
1368
2304

query I rowsort
SELECT ALL 99 + col2 * - col1 FROM tab0
----
-2739
-7363
2

query I rowsort
SELECT ALL col2 * col0 * ( + col0 ) + + col2 + + 38 * + col0 AS col2 FROM tab0 AS cor0
----
19953
2556
652986

query I rowsort
SELECT - 46 + + cor0.col1 AS col2 FROM tab1 AS cor0
----
-20
-33
-36

query I rowsort
SELECT DISTINCT 31 + col2 FROM tab0 cor0
----
113
32
64

query I rowsort
SELECT col0 + col1 + + 82 * cor0.col1 FROM tab0 AS cor0
----
7162
7642
8086

query I rowsort
SELECT ALL + cor0.col0 + - col1 FROM tab2 AS cor0
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + ( - cor0.col0 ) col1 FROM tab0 AS cor0
----
-24
-35
-89

onlyif mysql # use DIV operator for integer division
query I rowsort label-9505
SELECT ALL - col0 DIV - cor0.col2 FROM tab1 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9505
SELECT ALL - col0 / - cor0.col2 FROM tab1 AS cor0
----
0
0
1

query I rowsort
SELECT ALL 64 AS col2 FROM tab1 AS cor0
----
64
64
64

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9507
SELECT - - col0 + col0 * CAST( NULL AS SIGNED ) * cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9507
SELECT - - col0 + col0 * CAST ( NULL AS INTEGER ) * cor0.col2 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 10 * + col0 * 22 AS col0 FROM tab2 AS cor0
----
-1540
-17160
-17380

query I rowsort
SELECT DISTINCT - ( col0 ) * 25 + col2 * + col2 FROM tab2 AS cor0
----
-1274
-531
554

query I rowsort
SELECT DISTINCT + col0 + - col0 * col2 FROM tab0 cor0
----
-7209
-768
0

query I rowsort
SELECT col2 * + 86 AS col1 FROM tab0 cor0
----
2838
7052
86

query I rowsort
SELECT + tab1.col1 + col2 + + ( tab1.col1 ) FROM tab1
----
106
122
77

query I rowsort
SELECT - col1 * - 91 AS col1 FROM tab1 AS cor0
----
1183
2366
910

query I rowsort
SELECT - - col1 * col1 * + col0 + col1 FROM tab0 AS cor0
----
177590
329412
737100

query I rowsort
SELECT + col0 + + ( - col1 ) FROM tab2 AS cor0
----
-24
19
62

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL + cor0.col0 + col1 col0 FROM tab1 AS cor0
----
29
74
93

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col2 * - 20 col2 FROM tab2 cor0
----
520
540
760

query I rowsort
SELECT DISTINCT col0 + + 95 AS col1 FROM tab1 cor0
----
159
175
98

query I rowsort
SELECT - tab1.col0 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 729c1edda9332398299f39cd174ed840

query I rowsort
SELECT DISTINCT + col1 + + 33 * 6 FROM tab2 AS cor0
----
215
229
257

onlyif mysql # use DIV operator for integer division
query I rowsort label-9521
SELECT ALL - col0 DIV cor0.col1 AS col1 FROM tab2 cor0
----
-1
-4
0

skipif mysql # not compatible
query I rowsort label-9521
SELECT ALL - col0 / cor0.col1 AS col1 FROM tab2 cor0
----
-1
-4
0

query I rowsort
SELECT - col1 + - 99 * - col1 FROM tab1 AS cor0
----
1274
2548
980

query I rowsort
SELECT ALL + col2 * + 10 + col0 AS col2 FROM tab2 AS cor0
----
277
338
459

query I rowsort
SELECT - + ( 99 ) + cor0.col1 FROM tab0 AS cor0
----
-13
-2
-8

skipif mysql # not compatible
query I rowsort
SELECT - CAST ( - 91 AS REAL ) AS col2 FROM tab0 AS cor0
----
91
91
91

query I rowsort
SELECT DISTINCT - col2 + + col1 * - col1 + 11 FROM tab2 AS cor0
----
-316
-3496
-977

onlyif mysql # use DIV operator for integer division
query I rowsort label-9527
SELECT DISTINCT + - 62 DIV + col0 FROM tab1 AS cor0
----
-20
0

skipif mysql # not compatible
query I rowsort label-9527
SELECT DISTINCT + - 62 / + col0 FROM tab1 AS cor0
----
-20
0

query I rowsort
SELECT ALL + col1 - + 26 AS col1 FROM tab2
----
-9
33
5

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9529
SELECT + CAST( NULL AS SIGNED ) AS col2 FROM tab1, tab2 AS cor0, tab0, tab1 AS cor1
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

skipif mysql # not compatible
query I rowsort label-9529
SELECT + CAST ( NULL AS INTEGER ) AS col2 FROM tab1, tab2 AS cor0, tab0, tab1 AS cor1
----
81 values hashing to cb33c30d6f52bbb24338a293c740f29c

query I rowsort
SELECT DISTINCT col2 * col2 + 23 + col0 * col0 FROM tab1
----
15639
2948
7368

query I rowsort
SELECT - col2 * 46 + + ( + col2 + + ( col0 ) ) * cor0.col1 * + cor0.col0 FROM tab1 AS cor0
----
178624
1962
74818

query I rowsort
SELECT col2 + col1 * cor0.col0 AS col0 FROM tab1 AS cor0
----
1136
132
697

query I rowsort
SELECT ALL - col0 + col0 + - tab0.col0 * col1 AS col2 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL tab2.col0 + col2 * 89 AS col0 FROM tab2
----
2392
2410
3461

query I rowsort
SELECT ALL col0 + - col2 + + 50 FROM tab1
----
-1
34
57

query I rowsort
SELECT 99 + col1 FROM tab0
----
185
190
196

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT 71 col1 FROM tab1, tab2, tab0 AS cor0
----
27 values hashing to 95a6ff35b7b8f00868fb58bcaa32d0c2

skipif mysql # not compatible
query I rowsort
SELECT ALL - + col2 * CAST ( + col1 AS REAL ) - + cor0.col0 AS col0 FROM tab1 AS cor0
----
-1328
-1407
-634

query I rowsort
SELECT DISTINCT - cor0.col0 * - cor0.col1 * + cor0.col2 AS col0 FROM tab0 AS cor0
----
3395
664118
68112

query I rowsort
SELECT col1 * - ( 46 + + col2 ) * + col2 AS col1 FROM tab0 AS cor0
----
-224202
-4559
-955136

query I rowsort
SELECT col0 + - col2 * - col0 FROM tab0 cor0
----
70
7387
816

onlyif mysql # use DIV operator for integer division
query I rowsort label-9542
SELECT - + col0 DIV col0 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

skipif mysql # not compatible
query I rowsort label-9542
SELECT - + col0 / col0 AS col1 FROM tab0 AS cor0
----
-1
-1
-1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9543
SELECT col1 DIV + col1 AS col2 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9543
SELECT col1 / + col1 AS col2 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT ALL - 22 * 4 AS col2 FROM tab2 AS cor0
----
-88
-88
-88

query I rowsort
SELECT col2 * - 81 FROM tab2 AS cor0
----
-2106
-2187
-3078

query I rowsort
SELECT ALL - cor0.col0 * + 82 + cor0.col1 * col1 AS col0 FROM tab0 AS cor0
----
5428
6539
983

onlyif mysql # use DIV operator for integer division
query I rowsort label-9547
SELECT col2 DIV 14 AS col1 FROM tab2 AS cor0
----
1
1
2

skipif mysql # not compatible
query I rowsort label-9547
SELECT col2 / 14 AS col1 FROM tab2 AS cor0
----
1
1
2

query I rowsort
SELECT DISTINCT 68 * cor0.col1 AS col1 FROM tab1 cor0
----
1768
680
884

query I rowsort
SELECT ALL + - cor0.col2 * col1 + + cor0.col1 * - cor0.col0 FROM tab2 AS cor0
----
-1054
-1989
-6136

query I rowsort
SELECT ALL + ( col2 ) + - col0 + 31 FROM tab2 AS cor0
----
-10
-21
51

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col1 * col0 * col0 col2 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT DISTINCT 32 * - col1 FROM tab0 AS cor0
----
-2752
-2912
-3104

query I rowsort
SELECT - 40 AS col2 FROM tab0, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 01aad4539198a6509248e086869f90a6

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col1 + col2 - 93 col0 FROM tab1 AS cor0
----
-13
-26
16

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 * col0 col1 FROM tab2 cor0
----
-49
-6084
-6241

query I rowsort
SELECT DISTINCT - 91 AS col2 FROM tab2, tab0 AS cor0, tab0 AS cor1, tab2 AS cor2
----
-91

onlyif mysql # use DIV operator for integer division
query I rowsort label-9557
SELECT + col1 * col0 + cor0.col2 DIV + col0 FROM tab0 AS cor0
----
2065
3395
8099

skipif mysql # not compatible
query I rowsort label-9557
SELECT + col1 * col0 + cor0.col2 / + col0 FROM tab0 AS cor0
----
2065
3395
8099

query I rowsort
SELECT - 80 AS col0 FROM tab2 AS cor0
----
-80
-80
-80

onlyif mysql # use DIV operator for integer division
query I rowsort label-9559
SELECT ALL ( + col0 ) * ( 47 ) + col2 DIV + ( cor0.col0 ) AS col0 FROM tab0 AS cor0
----
1129
1645
4183

skipif mysql # not compatible
query I rowsort label-9559
SELECT ALL ( + col0 ) * ( 47 ) + col2 / + ( cor0.col0 ) AS col0 FROM tab0 AS cor0
----
1129
1645
4183

query I rowsort
SELECT DISTINCT - ( - col2 ) + col1 * col2 AS col0 FROM tab1 AS cor0
----
1344
1458
627

query I rowsort
SELECT ALL - col2 + cor0.col1 * ( + col0 ) FROM tab0 cor0
----
2031
3394
8017

query I rowsort
SELECT + + 41 AS col1 FROM tab2 AS cor0
----
41
41
41

query I rowsort
SELECT DISTINCT + col0 - cor0.col2 * col2 FROM tab0 AS cor0
----
-1065
-6635
34

query I rowsort
SELECT DISTINCT - - 32 + col1 AS col1 FROM tab2 AS cor0
----
49
63
91

query I rowsort
SELECT DISTINCT + ( col1 * - col0 ) AS col0 FROM tab0
----
-2064
-3395
-8099

query I rowsort
SELECT ALL + - cor0.col1 - col1 * col2 FROM tab2 AS cor0
----
-1593
-663
-868

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9567
SELECT DISTINCT cor0.col2 + cor0.col0 + CAST( col2 AS SIGNED ) AS col1 FROM tab0 cor0
----
253
37
90

skipif mysql # not compatible
query I rowsort label-9567
SELECT DISTINCT cor0.col2 + cor0.col0 + CAST ( col2 AS INTEGER ) AS col1 FROM tab0 cor0
----
253
37
90

query IIIIII rowsort
SELECT DISTINCT * FROM tab1, tab2 AS cor0 WHERE NULL NOT BETWEEN ( NULL ) AND ( NULL )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col1 * 80 + - 18 * + col2 * col2 col2 FROM tab0 AS cor0
----
-128312
-26482
-7778

query I rowsort
SELECT DISTINCT 53 + col2 FROM tab1
----
107
110
149

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9571
SELECT + - col2 + + CAST( NULL AS SIGNED ) * cor0.col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9571
SELECT + - col2 + + CAST ( NULL AS INTEGER ) * cor0.col2 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL 31 AS col0 FROM tab2, tab1 AS cor0
----
9 values hashing to d1ebd1cea4a9773069af34fbf8ea3540

query I rowsort
SELECT 10 + - cor0.col2 FROM tab2, tab0 AS cor0, tab2 AS cor1, tab1 AS cor2
----
81 values hashing to bb2c732dc363b8784c555913a6aac81a

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9574
SELECT ALL - CAST( NULL AS SIGNED ) + - 50 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9574
SELECT ALL - CAST ( NULL AS INTEGER ) + - 50 AS col1 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT + - col1 + col0 * - col1 FROM tab2 AS cor0
----
-1360
-248
-4661

query I rowsort
SELECT DISTINCT 66 AS col1 FROM tab0, tab1 AS cor0
----
66

query I rowsort
SELECT - 12 * - 4 FROM tab0 AS cor0
----
48
48
48

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT CAST ( - 88 AS REAL ) AS col0 FROM tab1
----
-88

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col0 + ( - col0 ) * + col0 col2 FROM tab0 AS cor0
----
-1190
-552
-7832

onlyif mysql # use DIV operator for integer division
query I rowsort label-9580
SELECT ALL col2 + 65 DIV col0 FROM tab0
----
2
35
82

skipif mysql # not compatible
query I rowsort label-9580
SELECT ALL col2 + 65 / col0 FROM tab0
----
2
35
82

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 * - 80 + col0 * + col2 col1 FROM tab2 cor0
----
749
8268
9322

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9582
SELECT - - col0 + + CAST( NULL AS DECIMAL ) / - col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9582
SELECT - - col0 + + CAST ( NULL AS REAL ) / - col2 AS col1 FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9583
SELECT DISTINCT - col2 DIV + CAST( - col0 AS SIGNED ) AS col0 FROM tab0 AS cor0
----
0
1

skipif mysql # not compatible
query I rowsort label-9583
SELECT DISTINCT - col2 / + CAST ( - col0 AS INTEGER ) AS col0 FROM tab0 AS cor0
----
0
1

query I rowsort
SELECT - col2 + col2 * + col1 * col0 AS col0 FROM tab1 AS cor0
----
36423
4158
99744

query I rowsort
SELECT DISTINCT + col1 * col2 * 46 AS col2 FROM tab0 AS cor0
----
130548
343252
4462

query I rowsort
SELECT DISTINCT - cor0.col1 + - 74 * - col0 AS col2 FROM tab0 AS cor0
----
1690
2493
6495

query I rowsort
SELECT ALL + + col1 + - 85 * cor0.col1 FROM tab0 AS cor0
----
-7224
-7644
-8148

query I rowsort
SELECT - col1 * - 16 + col0 AS col0 FROM tab1 AS cor0
----
224
288
419

query I rowsort
SELECT ALL - + col1 + - col2 AS col0 FROM tab1 AS cor0
----
-109
-67
-80

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL col1 + + 87 col1 FROM tab0 AS cor0
----
173
178
184

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( 84 AS REAL ) * + col1 * + col1 FROM tab2 cor0
----
24276
292404
80724

query I rowsort
SELECT ALL - 40 FROM tab1, tab0 AS cor0
----
9 values hashing to f02f17e9bc17e514af018c6f245ed7a9

query I rowsort
SELECT ALL + ( col1 ) + + col2 * 50 AS col2 FROM tab0 AS cor0
----
147
1736
4191

query I rowsort
SELECT + 52 * col1 AS col0 FROM tab2 AS cor0
----
1612
3068
884

query I rowsort
SELECT - 90 AS col0 FROM tab2
----
-90
-90
-90

query I rowsort
SELECT ALL ( - col2 ) * col1 FROM tab1 AS cor0
----
-1248
-1404
-570

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9597
SELECT DISTINCT ( col2 + CAST( NULL AS SIGNED ) ) col2 FROM tab1
----
NULL

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9597
SELECT DISTINCT ( col2 + CAST ( NULL AS INTEGER ) ) col2 FROM tab1
----
NULL

query I rowsort
SELECT - col0 - col2 * - 79 FROM tab0 AS cor0
----
2583
44
6389

query I rowsort
SELECT col1 + + 77 FROM tab0 AS cor0
----
163
168
174

query I rowsort
SELECT ALL - cor0.col2 * + 22 AS col1 FROM tab2 AS cor0
----
-572
-594
-836

query I rowsort
SELECT 75 FROM tab0, tab2, tab2 AS cor0
----
27 values hashing to e61b59795204c348103a58c0a8e4ce16

query I rowsort
SELECT + col0 * col1 + - tab2.col1 * - col0 AS col2 FROM tab2
----
2686
434
9204

onlyif mysql # use DIV operator for integer division
query I rowsort label-9603
SELECT 3 + col0 * col0 + col0 DIV + col0 FROM tab0
----
1229
580
7925

skipif mysql # not compatible
query I rowsort label-9603
SELECT 3 + col0 * col0 + col0 / + col0 FROM tab0
----
1229
580
7925

query I rowsort
SELECT - - col2 - col2 FROM tab2 cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9605
SELECT col2 * col1 - col1 DIV - tab2.col0 FROM tab2
----
1534
646
841

skipif mysql # not compatible
query I rowsort label-9605
SELECT col2 * col1 - col1 / - tab2.col0 FROM tab2
----
1534
646
841

query I rowsort
SELECT DISTINCT + ( tab0.col1 ) - ( 28 ) * col0 FROM tab0
----
-2401
-586
-883

query I rowsort
SELECT ALL + cor0.col0 * cor0.col2 AS col2 FROM tab2 cor0
----
189
2028
3002

onlyif mysql # use DIV operator for integer division
query I rowsort label-9608
SELECT DISTINCT col1 DIV - cor0.col0 AS col1 FROM tab2 AS cor0
----
-4
0

skipif mysql # not compatible
query I rowsort label-9608
SELECT DISTINCT col1 / - cor0.col0 AS col1 FROM tab2 AS cor0
----
-4
0

query I rowsort
SELECT + col1 * + col1 + - col2 + + col1 FROM tab2 AS cor0
----
268
3514
965

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9610
SELECT DISTINCT col1 * - CAST( - col2 AS SIGNED ) FROM tab1 AS cor0
----
1248
1404
570

skipif mysql # not compatible
query I rowsort label-9610
SELECT DISTINCT col1 * - CAST ( - col2 AS INTEGER ) FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT ALL col0 + - col0 * cor0.col0 AS col0 FROM tab0 cor0
----
-1190
-552
-7832

query I rowsort
SELECT DISTINCT - cor0.col1 * - col1 AS col1 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT ALL 66 AS col2 FROM tab2 AS cor0 CROSS JOIN tab0 AS cor1
----
9 values hashing to 29794915b585eea848ad670075452c88

query I rowsort
SELECT ( + col1 ) * - 98 - 2 FROM tab2
----
-1668
-3040
-5784

onlyif mysql # use DIV operator for integer division
query I rowsort label-9615
SELECT ALL col0 + col2 - ( tab2.col2 ) DIV col1 FROM tab2
----
104
115
34

skipif mysql # not compatible
query I rowsort label-9615
SELECT ALL col0 + col2 - ( tab2.col2 ) / col1 FROM tab2
----
104
115
34

query I rowsort
SELECT ALL col0 + 37 FROM tab1
----
101
117
40

query I rowsort
SELECT ALL + tab2.col2 + + col0 * ( col0 ) FROM tab2
----
6110
6279
76

query I rowsort
SELECT ALL col0 + - 19 + - col0 FROM tab2
----
-19
-19
-19

query I rowsort
SELECT ALL col0 * + 87 + tab1.col1 AS col0 FROM tab1
----
287
5578
6973

query I rowsort
SELECT + col2 + tab0.col1 * + 75 AS col0 FROM tab0
----
6483
6907
7276

query I rowsort
SELECT ALL + col0 * col2 + 25 * col1 AS col0 FROM tab2
----
3427
3503
964

query I rowsort
SELECT ALL + col2 * col1 + + col0 AS col1 FROM tab2 AS cor0
----
1612
725
844

query I rowsort
SELECT DISTINCT col0 * - 79 FROM tab2 AS cor0
----
-553
-6162
-6241

query I rowsort
SELECT tab2.col0 * 97 - col2 FROM tab2
----
652
7540
7625

query I rowsort
SELECT ALL - 84 AS col1 FROM tab0
----
-84
-84
-84

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9626
SELECT - CAST( NULL AS SIGNED ) - + col0 AS col0 FROM tab0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9626
SELECT - CAST ( NULL AS INTEGER ) - + col0 AS col0 FROM tab0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL col1 * - 27 AS col0 FROM tab1
----
-270
-351
-702

query I rowsort
SELECT ALL + 31 + 49 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 6dd5038be71dffa82f5ceba787caab91

query I rowsort
SELECT DISTINCT - 38 FROM tab0, tab2, tab2 AS cor0, tab1
----
-38

query I rowsort
SELECT ( - col2 ) * col2 AS col0 FROM tab1 AS cor0
----
-2916
-3249
-9216

query I rowsort
SELECT - + col1 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
-100
-169
-676

query I rowsort
SELECT ALL 22 AS col0 FROM tab0 AS cor0
----
22
22
22

query I rowsort
SELECT ALL 97 * + col1 AS col1 FROM tab1
----
1261
2522
970

query I rowsort
SELECT 71 AS col0 FROM tab0 AS cor0
----
71
71
71

query I rowsort
SELECT DISTINCT + + 65 + - col1 * - col0 AS col0 FROM tab0 AS cor0
----
2129
3460
8164

onlyif mysql # use DIV operator for integer division
query I rowsort label-9636
SELECT ALL - + 4 DIV col0 FROM tab2 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9636
SELECT ALL - + 4 / col0 FROM tab2 AS cor0
----
0
0
0

query I rowsort
SELECT DISTINCT 4 + - col2 * 91 FROM tab1 AS cor0
----
-4910
-5183
-8732

onlyif mysql # use DIV operator for integer division
query I rowsort label-9638
SELECT DISTINCT col1 * col2 DIV ( 50 + col1 ) col1 FROM tab1 AS cor0
----
18
19
9

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9638
SELECT DISTINCT col1 * col2 / ( 50 + col1 ) col1 FROM tab1 AS cor0
----
18
19
9

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9639
SELECT col2 + - cor0.col2 * - CAST( NULL AS SIGNED ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9639
SELECT col2 + - cor0.col2 * - CAST ( NULL AS INTEGER ) AS col0 FROM tab2 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT ALL - 14 AS col1 FROM tab1 AS cor0
----
-14
-14
-14

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT cor0.col1 * cor0.col2 col0 FROM tab1 AS cor0
----
1248
1404
570

query I rowsort
SELECT DISTINCT 75 * - col2 AS col1 FROM tab1 AS cor0
----
-4050
-4275
-7200

onlyif mysql # use DIV operator for integer division
query I rowsort label-9643
SELECT DISTINCT + col2 - col1 * col1 DIV + ( + col2 ) FROM tab0 AS cor0
----
-18
-191
-9408

skipif mysql # not compatible
query I rowsort label-9643
SELECT DISTINCT + col2 - col1 * col1 / + ( + col2 ) FROM tab0 AS cor0
----
-18
-191
-9408

query I rowsort
SELECT + col0 - - col2 FROM tab1 AS cor0
----
121
176
57

onlyif mysql # use DIV operator for integer division
query I rowsort label-9645
SELECT DISTINCT + + col0 DIV + col0 FROM tab2 cor0
----
1

skipif mysql # not compatible
query I rowsort label-9645
SELECT DISTINCT + + col0 / + col0 FROM tab2 cor0
----
1

query I rowsort
SELECT ALL + ( col0 ) * - col0 + col1 FROM tab2 AS cor0
----
-18
-6025
-6224

query I rowsort
SELECT DISTINCT + ( cor0.col1 ) AS col2 FROM tab2 AS cor0
----
17
31
59

query I rowsort
SELECT 84 AS col2 FROM tab0, tab1 AS cor0
----
9 values hashing to cadd876c26338fc58b9297e74fc324d8

query I rowsort
SELECT ALL - 81 + - col0 AS col2 FROM tab0
----
-105
-116
-170

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL 93 + - col2 col2 FROM tab0
----
11
60
92

onlyif mysql # use DIV operator for integer division
query I rowsort label-9651
SELECT - 63 DIV + col2 + + col1 * - col1 col2 FROM tab0 AS cor0
----
-7397
-8281
-9472

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9651
SELECT - 63 / + col2 + + col1 * - col1 col2 FROM tab0 AS cor0
----
-7397
-8281
-9472

query I rowsort
SELECT - - col1 * + col2 + 74 FROM tab0 AS cor0
----
171
2912
7536

query I rowsort
SELECT ALL - ( - 52 * + col2 ) + ( + col1 ) FROM tab2
----
1411
1435
1993

query I rowsort
SELECT + ( 99 ) FROM tab2, tab1, tab2 AS cor0
----
27 values hashing to 05ea182fd6036c7f5e0ea08fc061cc67

onlyif mysql # use DIV operator for integer division
query I rowsort label-9655
SELECT DISTINCT ( col2 ) + + col1 DIV col1 AS col0 FROM tab2
----
27
28
39

skipif mysql # not compatible
query I rowsort label-9655
SELECT DISTINCT ( col2 ) + + col1 / col1 AS col0 FROM tab2
----
27
28
39

query I rowsort
SELECT ALL col2 - col0 AS col0 FROM tab0 AS cor0
----
-34
-7
9

query I rowsort
SELECT - col0 * - 84 AS col0 FROM tab2 AS cor0
----
588
6552
6636

query I rowsort
SELECT ALL - - col0 + + 88 FROM tab2 AS cor0
----
166
167
95

query I rowsort
SELECT DISTINCT col0 + col1 * + cor0.col1 FROM tab2 AS cor0
----
3559
368
968

query I rowsort
SELECT ALL + col1 * ( + 55 ) * col1 + - 65 FROM tab1 AS cor0
----
37115
5435
9230

onlyif mysql # use DIV operator for integer division
query I rowsort label-9661
SELECT DISTINCT ( col2 ) DIV tab0.col1 FROM tab0
----
0

skipif mysql # not compatible
query I rowsort label-9661
SELECT DISTINCT ( col2 ) / tab0.col1 FROM tab0
----
0

query I rowsort
SELECT DISTINCT col1 * + col0 * 7 FROM tab2
----
1519
32214
9401

query I rowsort
SELECT - + 66 AS col1 FROM tab1, tab2, tab1 AS cor0
----
27 values hashing to cd4a3594ee8b45223ebf9f25840cd112

onlyif mysql # use DIV operator for integer division
query I rowsort label-9664
SELECT ALL + col0 DIV col1 col2 FROM tab2 AS cor0
----
0
1
4

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9664
SELECT ALL + col0 / col1 col2 FROM tab2 AS cor0
----
0
1
4

query I rowsort
SELECT DISTINCT col2 * - col1 AS col1 FROM tab2 cor0
----
-1534
-646
-837

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9666
SELECT DISTINCT + col0 * CAST( NULL AS SIGNED ) * col1 + col0 - col1 FROM tab2 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9666
SELECT DISTINCT + col0 * CAST ( NULL AS INTEGER ) * col1 + col0 - col1 FROM tab2 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9667
SELECT DISTINCT col1 * + ( cor0.col1 ) + + col2 * + cor0.col1 DIV col1 FROM tab2 AS cor0
----
327
3507
988

skipif mysql # not compatible
query I rowsort label-9667
SELECT DISTINCT col1 * + ( cor0.col1 ) + + col2 * + cor0.col1 / col1 FROM tab2 AS cor0
----
327
3507
988

query I rowsort
SELECT DISTINCT + tab1.col2 * col2 AS col1 FROM tab1
----
2916
3249
9216

query I rowsort
SELECT col0 + - 62 AS col2 FROM tab2
----
-55
16
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + 78 * col1 col1 FROM tab0 AS cor0
----
6708
7098
7566

query I rowsort
SELECT DISTINCT - tab2.col1 FROM tab2, tab0, tab2 cor0
----
-17
-31
-59

query I rowsort
SELECT DISTINCT 56 * col1 FROM tab0
----
4816
5096
5432

query IIIIIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 AS cor0 CROSS JOIN tab2, tab0, tab1 AS cor1
----
3645 values hashing to b8435223668db186a5012e4112253f28

query I rowsort
SELECT + + ( - 63 ) * + col0 AS col1 FROM tab1 AS cor0
----
-189
-4032
-5040

query I rowsort
SELECT DISTINCT 37 FROM tab0, tab0 AS cor0 CROSS JOIN tab1
----
37

query I rowsort
SELECT + - 94 * 97 FROM tab1 AS cor0
----
-9118
-9118
-9118

query I rowsort
SELECT 39 * - col0 AS col0 FROM tab1 AS cor0
----
-117
-2496
-3120

query I rowsort
SELECT + 54 * col2 + ( + 94 ) + col0 * col0 FROM tab1 AS cor0
----
11678
3019
7268

query I rowsort
SELECT ALL + ( - cor0.col0 ) + - col1 AS col2 FROM tab1 AS cor0
----
-29
-74
-93

onlyif mysql # use DIV operator for integer division
query I rowsort label-9680
SELECT ALL col1 DIV + cor0.col2 + col1 FROM tab0 AS cor0
----
194
88
92

skipif mysql # not compatible
query I rowsort label-9680
SELECT ALL col1 / + cor0.col2 + col1 FROM tab0 AS cor0
----
194
88
92

query I rowsort
SELECT DISTINCT - - col2 * + cor0.col0 + - col1 * - col2 + col2 FROM tab0 AS cor0
----
133
14842
3663

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9682
SELECT ALL + CAST( 81 AS SIGNED ) FROM tab2, tab1 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

skipif mysql # not compatible
query I rowsort label-9682
SELECT ALL + CAST ( 81 AS INTEGER ) FROM tab2, tab1 AS cor0
----
9 values hashing to 7a8ea30c6803aeddc5fca5b5821d8267

onlyif mysql # use DIV operator for integer division
query I rowsort label-9683
SELECT col1 DIV - col0 + col0 + col0 * + col2 AS col2 FROM tab2 AS cor0
----
192
2106
3081

skipif mysql # not compatible
query I rowsort label-9683
SELECT col1 / - col0 + col0 + col0 * + col2 AS col2 FROM tab2 AS cor0
----
192
2106
3081

query I rowsort
SELECT - cor0.col1 * 71 AS col0 FROM tab1 AS cor0
----
-1846
-710
-923

query I rowsort
SELECT DISTINCT - 51 + 20 * + cor1.col0 AS col1 FROM tab2 AS cor0 CROSS JOIN tab1 AS cor1
----
1229
1549
9

query I rowsort
SELECT ( + col0 + - col1 ) * - col1 FROM tab2
----
-1054
-1121
744

query I rowsort
SELECT + col0 * ( - col1 ) + col2 FROM tab1 AS cor0
----
-24
-583
-944

query I rowsort
SELECT col0 + cor0.col2 AS col2 FROM tab1 AS cor0
----
121
176
57

query I rowsort
SELECT ALL - col1 * + col1 - - col0 * col2 FROM tab0
----
-6604
-9374
-983

query I rowsort
SELECT ALL col0 - - tab2.col0 * + tab2.col2 * + col0 FROM tab2
----
1330
158262
237237

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT tab0.col0 - - col2 * col1 col0 FROM tab0
----
132
2862
7551

query III rowsort
SELECT DISTINCT * FROM tab1 WHERE - col0 - + col0 / col1 NOT BETWEEN col0 / - col2 AND + col1 / col0
----
9 values hashing to 8d6692e6d41505c3ad42d919bd9ecd0d

query I rowsort
SELECT - - col1 + - col1 - - col2 FROM tab1 AS cor0
----
54
57
96

query I rowsort
SELECT + col2 + + col1 * col0 * col1 FROM tab0 AS cor0
----
177537
329316
737091

query I rowsort
SELECT + - col2 * - cor0.col2 + col1 AS col0 FROM tab0 AS cor0
----
1175
6815
98

query I rowsort
SELECT DISTINCT - col2 + col0 AS col0 FROM tab1 AS cor0 WHERE ( NULL ) IN ( col1 / col2 + col2 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 * cor0.col2 col1 FROM tab2 cor0
----
1444
676
729

query III rowsort
SELECT ALL * FROM tab1 AS cor0 WHERE ( NULL ) IN ( col0 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9699
SELECT DISTINCT cor0.col1 + col0 * col1 DIV col2 AS col0 FROM tab0 cor0
----
148
189
3492

skipif mysql # not compatible
query I rowsort label-9699
SELECT DISTINCT cor0.col1 + col0 * col1 / col2 AS col0 FROM tab0 cor0
----
148
189
3492

query I rowsort
SELECT col2 * + cor0.col2 + col1 AS col2 FROM tab2 AS cor0
----
1461
735
760

onlyif mysql # use DIV operator for integer division
query I rowsort label-9701
SELECT ALL + cor0.col2 DIV - cor0.col2 + + col0 FROM tab1 AS cor0
----
2
63
79

skipif mysql # not compatible
query I rowsort label-9701
SELECT ALL + cor0.col2 / - cor0.col2 + + col0 FROM tab1 AS cor0
----
2
63
79

onlyif mysql # use DIV operator for integer division
query I rowsort label-9702
SELECT col1 DIV cor0.col1 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-9702
SELECT col1 / cor0.col1 + + cor0.col2 AS col2 FROM tab0 AS cor0
----
2
34
83

query IIIIII rowsort
SELECT * FROM tab1, tab0 AS cor0 WHERE NOT NULL NOT IN ( cor0.col1 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col1 + + col2 col2 FROM tab2 AS cor0
----
-33
-4
21

query I rowsort
SELECT + col0 + col0 * - col1 + col1 FROM tab1 AS cor0
----
-49
-566
-947

query I rowsort
SELECT ALL - col1 * col0 AS col1 FROM tab0 cor0
----
-2064
-3395
-8099

query I rowsort
SELECT DISTINCT col2 * col0 * cor0.col0 AS col2 FROM tab2 AS cor0
----
1323
158184
237158

query I rowsort
SELECT ALL + + ( - col1 ) - 19 FROM tab2 AS cor0
----
-36
-50
-78

query I rowsort
SELECT + 92 - + cor0.col2 FROM tab0, tab1 cor0, tab1 AS cor1
----
27 values hashing to ffba4750e3d7f190b218707e489afafa

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - col2 + - col2 * col2 col2 FROM tab1 AS cor0
----
-2970
-3306
-9312

query I rowsort
SELECT DISTINCT tab2.col1 FROM tab2 WHERE NULL IN ( + col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9712
SELECT + col0 DIV col0 col0 FROM tab0
----
1
1
1

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9712
SELECT + col0 / col0 col0 FROM tab0
----
1
1
1

query I rowsort
SELECT DISTINCT col0 * + col1 + + col2 * tab2.col2 FROM tab2
----
2787
5278
946

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - 8 + col0 col0 FROM tab2 AS cor0
----
-1
70
71

query I rowsort
SELECT ALL + 11 * - col2 AS col1 FROM tab1 AS cor0
----
-1056
-594
-627

query I rowsort
SELECT DISTINCT col0 - col0 * - col2 FROM tab2
----
196
2106
3081

query I rowsort
SELECT 62 * col1 - + tab2.col0 AS col2 FROM tab2
----
1915
3580
975

onlyif mysql # use DIV operator for integer division
query I rowsort label-9718
SELECT DISTINCT 35 DIV + col2 - ( col2 ) FROM tab0
----
-32
-82
34

skipif mysql # not compatible
query I rowsort label-9718
SELECT DISTINCT 35 / + col2 - ( col2 ) FROM tab0
----
-32
-82
34

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col2 * 56 col0 FROM tab2 AS cor0
----
1456
1512
2128

query I rowsort
SELECT ALL cor0.col0 * cor0.col0 + cor0.col1 AS col2 FROM tab2 AS cor0
----
6143
6258
80

query I rowsort
SELECT + col0 + + 76 AS col2 FROM tab1 AS cor0
----
140
156
79

query I rowsort
SELECT - 85 + col1 * col2 + - col2 AS col1 FROM tab0
----
11
2720
7295

query I rowsort
SELECT - 79 + col2 * + col0 AS col0 FROM tab2
----
110
1949
2923

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col0 col2 FROM tab2, tab1, tab0 cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

query I rowsort
SELECT DISTINCT 20 * col0 AS col1 FROM tab0
----
1780
480
700

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - col0 + + col0 col0 FROM tab0 WHERE ( col2 * col0 ) IN ( col2 )
----

query I rowsort
SELECT ALL + tab2.col2 + col1 FROM tab2 WHERE NOT - col1 / - col1 = NULL
----

query I rowsort
SELECT col2 AS col0 FROM tab1 WHERE NOT + col2 / col2 NOT IN ( - tab1.col1 + col2 + - col2 )
----

query I rowsort
SELECT col1 - + col1 * - col2 FROM tab0
----
194
2924
7553

query I rowsort
SELECT ALL tab1.col0 + col1 * tab1.col1 AS col2 FROM tab1
----
164
249
679

query III rowsort
SELECT ALL * FROM tab0 WHERE NOT col1 * col0 BETWEEN NULL AND ( NULL )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9732
SELECT col0 + - col0 DIV + tab0.col1 col0 FROM tab0
----
24
35
89

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9732
SELECT col0 + - col0 / + tab0.col1 col0 FROM tab0
----
24
35
89

query III rowsort
SELECT DISTINCT * FROM tab2 WHERE ( NULL ) < NULL
----

query I rowsort
SELECT ALL + col2 + col1 * col2 AS col1 FROM tab1
----
1344
1458
627

query I rowsort
SELECT DISTINCT + tab1.col1 + - col1 + col0 FROM tab1
----
3
64
80

query I rowsort
SELECT - col1 * + col2 + col0 - - col2 FROM tab2
----
-1430
-529
-803

query I rowsort
SELECT col1 + - col2 * + col1 AS col0 FROM tab0
----
-2752
-7371
0

query I rowsort
SELECT + col0 + + col0 FROM tab0 WHERE NOT col2 * col1 + col1 * col0 IN ( col0 * col0 )
----
178
48
70

query I rowsort
SELECT DISTINCT - col0 + - col2 * - col0 AS col1 FROM tab2
----
182
1950
2923

query I rowsort
SELECT - col1 AS col1 FROM tab1 WHERE NULL NOT BETWEEN ( - col1 + col2 * + col0 ) AND NULL
----

query I rowsort
SELECT ALL tab1.col2 + - col1 + + col2 FROM tab1
----
104
179
82

query I rowsort
SELECT - col0 * col1 + + col1 + + col0 FROM tab1
----
-49
-566
-947

query I rowsort
SELECT + col1 FROM tab0 WHERE ( NULL ) NOT IN ( col2 - col0 )
----

query III rowsort
SELECT * FROM tab2 WHERE NOT NULL >= - col2
----

query I rowsort
SELECT ALL + tab2.col1 + + col2 AS col2 FROM tab2
----
55
58
85

query I rowsort
SELECT tab0.col0 + + tab0.col1 AS col0 FROM tab0
----
110
132
180

query I rowsort
SELECT tab1.col2 - - col2 AS col2 FROM tab1
----
108
114
192

query I rowsort
SELECT tab1.col2 FROM tab1 WHERE NOT ( col1 ) NOT IN ( - col0 * + col0 )
----

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + + col1 col1 FROM tab1
----
-54
-67
23

query I rowsort
SELECT DISTINCT col2 * + col2 + col0 AS col1 FROM tab1 WHERE NULL NOT IN ( - col1 - tab1.col2 / - col1 )
----

query III rowsort
SELECT DISTINCT * FROM tab0 WHERE NOT NULL IN ( col1 )
----

query I rowsort
SELECT DISTINCT tab0.col2 + + tab0.col2 FROM tab0
----
164
2
66

query I rowsort
SELECT - tab1.col0 + - col0 * + col1 AS col0 FROM tab1 WHERE NOT NULL NOT IN ( + col1 - col2 )
----

onlyif mysql # use DIV operator for integer division
query I rowsort label-9754
SELECT ALL + col1 DIV - col2 + col2 * + col1 col1 FROM tab1
----
1248
1404
570

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9754
SELECT ALL + col1 / - col2 + col2 * + col1 col1 FROM tab1
----
1248
1404
570

onlyif mysql # use DIV operator for integer division
query I rowsort label-9755
SELECT + col0 * col2 DIV 46 + - col1 AS col2 FROM tab0
----
-69
-97
67

skipif mysql # not compatible
query I rowsort label-9755
SELECT + col0 * col2 / 46 + - col1 AS col2 FROM tab0
----
-69
-97
67

query I rowsort
SELECT ( col1 ) + - col0 FROM tab0
----
2
62
62

query I rowsort
SELECT DISTINCT - 96 * col2 - - 99 * col2 FROM tab2 AS cor0
----
114
78
81

onlyif mysql # use DIV operator for integer division
query I rowsort label-9758
SELECT ALL col0 DIV col1 + ( + ( + col1 ) * col1 ) AS col0 FROM tab1 AS cor0
----
106
175
676

skipif mysql # not compatible
query I rowsort label-9758
SELECT ALL col0 / col1 + ( + ( + col1 ) * col1 ) AS col0 FROM tab1 AS cor0
----
106
175
676

query I rowsort
SELECT DISTINCT - cor0.col2 + cor0.col2 AS col0 FROM tab1, tab1 AS cor0
----
0

query I rowsort
SELECT DISTINCT - - 12 * col2 + + col2 AS col1 FROM tab0 cor0
----
1066
13
429

query I rowsort
SELECT ALL + 39 + col2 FROM tab1 AS cor0
----
135
93
96

query I rowsort
SELECT ALL - - col0 * - col0 - + col2 FROM tab0 AS cor0
----
-1226
-609
-8003

onlyif mysql # use DIV operator for integer division
query I rowsort label-9763
SELECT cor0.col2 DIV - 4 AS col0 FROM tab0 AS cor0
----
-20
-8
0

skipif mysql # not compatible
query I rowsort label-9763
SELECT cor0.col2 / - 4 AS col0 FROM tab0 AS cor0
----
-20
-8
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9764
SELECT DISTINCT - + col2 + CAST( + 25 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-57
-8
24

skipif mysql # not compatible
query I rowsort label-9764
SELECT DISTINCT - + col2 + CAST ( + 25 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-57
-8
24

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9765
SELECT DISTINCT - col1 + + CAST( NULL AS SIGNED ) * + col2 / col1 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9765
SELECT DISTINCT - col1 + + CAST ( NULL AS INTEGER ) * + col2 / col1 FROM tab1 AS cor0
----
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9766
SELECT - col0 * col1 DIV + 89 AS col1 FROM tab2 AS cor0
----
-15
-2
-51

skipif mysql # not compatible
query I rowsort label-9766
SELECT - col0 * col1 / + 89 AS col1 FROM tab2 AS cor0
----
-15
-2
-51

query I rowsort
SELECT - 22 + - col1 AS col2 FROM tab2
----
-39
-53
-81

query I rowsort
SELECT + - tab0.col2 AS col2 FROM tab0, tab1, tab0 AS cor0
----
27 values hashing to 6a43e7f15194af73fe1c83385e6ebebc

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + tab0.col0 col1 FROM tab0, tab2, tab2 cor0
----
27 values hashing to 9fc1dcd76feaf43e5c5dc060a02014cd

onlyif mysql # use DIV operator for integer division
query I rowsort label-9770
SELECT DISTINCT col1 DIV col2 col1 FROM tab1
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9770
SELECT DISTINCT col1 / col2 col1 FROM tab1
----
0

query I rowsort
SELECT - col0 * - ( + 95 ) FROM tab1 AS cor0
----
285
6080
7600

query I rowsort
SELECT DISTINCT col2 * - col1 * - col1 + + 83 * 82 * - col1 FROM tab1 AS cor0
----
-140452
-62360
-72254

query I rowsort
SELECT DISTINCT + - ( - cor0.col0 ) - - cor0.col1 FROM tab0 AS cor0
----
110
132
180

query I rowsort
SELECT - ( 31 ) + + col2 * cor0.col0 AS col1 FROM tab0 AS cor0
----
4
7267
761

query I rowsort
SELECT DISTINCT - + cor0.col2 + + 16 AS col0 FROM tab2 AS cor0
----
-10
-11
-22

onlyif mysql # use DIV operator for integer division
query I rowsort label-9776
SELECT ALL ( col1 ) DIV + col2 + - col1 - 31 AS col1 FROM tab0 AS cor0
----
-115
-121
-31

skipif mysql # not compatible
query I rowsort label-9776
SELECT ALL ( col1 ) / + col2 + - col1 - 31 AS col1 FROM tab0 AS cor0
----
-115
-121
-31

query I rowsort
SELECT + ( 80 ) AS col0 FROM tab2 AS cor0
----
80
80
80

query I rowsort
SELECT + 70 * + col0 + + col0 FROM tab2 cor0
----
497
5538
5609

query I rowsort
SELECT + 36 * ( col1 ) + 65 * + cor0.col1 AS col2 FROM tab0 AS cor0
----
8686
9191
9797

query I rowsort
SELECT ALL + tab2.col1 + col0 * 87 + col2 AS col1 FROM tab2
----
667
6871
6928

query I rowsort
SELECT DISTINCT + + col2 + + ( + col2 ) AS col1 FROM tab2 cor0
----
52
54
76

query I rowsort
SELECT - 55 AS col0 FROM tab0 cor0
----
-55
-55
-55

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - 90 col2 FROM tab2 AS cor0
----
-90
-90
-90

query I rowsort
SELECT ALL col0 * cor0.col2 + col1 FROM tab2 AS cor0
----
2087
220
3019

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - col0 + col2 * - col0 col2 FROM tab0 AS cor0
----
-70
-7387
-816

query I rowsort
SELECT + 5 + col2 + col2 * - ( - col2 ) * col0 FROM tab2 AS cor0
----
114119
5135
52759

query I rowsort
SELECT - cor0.col1 + col1 FROM tab1 cor0
----
0
0
0

query I rowsort
SELECT 47 + + 67 * - col2 AS col0 FROM tab0
----
-20
-2164
-5447

query I rowsort
SELECT + col2 + cor0.col0 * - col0 FROM tab2 AS cor0
----
-22
-6058
-6203

onlyif mysql # use DIV operator for integer division
query I rowsort label-9790
SELECT + 72 DIV col0 + col2 * - col0 FROM tab2
----
-179
-2028
-3002

skipif mysql # not compatible
query I rowsort label-9790
SELECT + 72 / col0 + col2 * - col0 FROM tab2
----
-179
-2028
-3002

query I rowsort
SELECT - + 36 + + col2 FROM tab0 AS cor0
----
-3
-35
46

query I rowsort
SELECT - col2 * - cor0.col1 + cor0.col1 * col1 FROM tab1 AS cor0
----
1417
2080
670

onlyif mysql # use DIV operator for integer division
query I rowsort label-9793
SELECT ALL - tab2.col0 DIV - col0 FROM tab2
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9793
SELECT ALL - tab2.col0 / - col0 FROM tab2
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9794
SELECT DISTINCT + ( + col2 + col0 ) DIV - col0 AS col2 FROM tab0
----
-1
-2

skipif mysql # not compatible
query I rowsort label-9794
SELECT DISTINCT + ( + col2 + col0 ) / - col0 AS col2 FROM tab0
----
-1
-2

query I rowsort
SELECT DISTINCT 77 AS col1 FROM tab0
----
77

query I rowsort
SELECT - 21 * + 70 AS col1 FROM tab1
----
-1470
-1470
-1470

query I rowsort
SELECT + 44 + col1 AS col1 FROM tab2 AS cor0
----
103
61
75

query I rowsort
SELECT ( col1 ) * col1 AS col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT col0 * col0 * tab1.col2 AS col1 FROM tab1
----
233472
486
614400

query I rowsort
SELECT DISTINCT col0 * - ( - 15 ) + col1 + col1 * - col1 FROM tab2
----
-2252
-825
913

onlyif mysql # use DIV operator for integer division
query I rowsort label-9801
SELECT - col1 DIV + 89 FROM tab1
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9801
SELECT - col1 / + 89 FROM tab1
----
0
0
0

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9802
SELECT col2 + - CAST( - col0 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
171
36
57

skipif mysql # not compatible
query I rowsort label-9802
SELECT col2 + - CAST ( - col0 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
171
36
57

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - tab0.col2 * col1 col0 FROM tab0
----
-2838
-7462
-97

query I rowsort
SELECT 14 * + 28 AS col2 FROM tab2
----
392
392
392

query I rowsort
SELECT 25 * 39 AS col1 FROM tab0
----
975
975
975

query I rowsort
SELECT + ( 84 ) FROM tab1 cor0
----
84
84
84

skipif mysql # not compatible
query I rowsort
SELECT DISTINCT + + CAST ( - col2 AS REAL ) AS col1 FROM tab2 cor0
----
-26
-27
-38

query I rowsort
SELECT 35 * + 43 AS col1 FROM tab1
----
1505
1505
1505

query I rowsort
SELECT DISTINCT 70 * tab0.col0 FROM tab0
----
1680
2450
6230

query I rowsort
SELECT col2 * 72 AS col2 FROM tab1
----
3888
4104
6912

skipif mysql # not compatible
query I rowsort
SELECT + - CAST ( 81 AS REAL ) AS col0 FROM tab1 AS cor0
----
-81
-81
-81

query I rowsort
SELECT ALL col2 - - 96 * col2 FROM tab2 cor0
----
2522
2619
3686

query I rowsort
SELECT - ( 49 ) AS col2 FROM tab1 AS cor0
----
-49
-49
-49

query I rowsort
SELECT ALL + ( col0 ) + + cor0.col1 * + cor0.col0 * col1 FROM tab0 AS cor0
----
177528
329350
737098

query I rowsort
SELECT + - ( - col2 ) * + col1 AS col1 FROM tab2 AS cor0
----
1534
646
837

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + col2 + - col1 * col2 * - col2 col0 FROM tab0 AS cor0
----
611966
93687
98

query I rowsort
SELECT ALL + col1 + 73 FROM tab1 AS cor0
----
83
86
99

onlyif mysql # use DIV operator for integer division
query I rowsort label-9818
SELECT DISTINCT 51 DIV + col1 + - col1 FROM tab2 AS cor0
----
-14
-30
-59

skipif mysql # not compatible
query I rowsort label-9818
SELECT DISTINCT 51 / + col1 + - col1 FROM tab2 AS cor0
----
-14
-30
-59

query I rowsort
SELECT DISTINCT + col1 * - col0 * - col0 + col1 * - col1 * col0 FROM tab0 AS cor0
----
-127968
-16198
-210490

query I rowsort
SELECT - - 21 AS col0 FROM tab1 AS cor0
----
21
21
21

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9821
SELECT ALL + CAST( + 29 AS SIGNED ) * col2 FROM tab1 cor0
----
1566
1653
2784

skipif mysql # not compatible
query I rowsort label-9821
SELECT ALL + CAST ( + 29 AS INTEGER ) * col2 FROM tab1 cor0
----
1566
1653
2784

query I rowsort
SELECT DISTINCT ( - col0 ) + col2 FROM tab2 AS cor0
----
-41
-52
20

query I rowsort
SELECT - col2 + - 57 AS col2 FROM tab2
----
-83
-84
-95

query I rowsort
SELECT 43 * + col0 FROM tab1
----
129
2752
3440

query I rowsort
SELECT - ( col0 ) + - cor0.col1 FROM tab0 AS cor0
----
-110
-132
-180

onlyif mysql # use DIV operator for integer division
query I rowsort label-9826
SELECT ALL + - CAST( + cor0.col2 AS SIGNED ) DIV - col2 FROM tab0 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9826
SELECT ALL + - CAST ( + cor0.col2 AS INTEGER ) / - col2 FROM tab0 AS cor0
----
1
1
1

query I rowsort
SELECT + + ( + 52 ) FROM tab0 AS cor0
----
52
52
52

query I rowsort
SELECT DISTINCT 15 + ( + col2 ) AS col2 FROM tab0 AS cor0
----
16
48
97

query I rowsort
SELECT ALL - cor0.col1 * - ( + cor0.col0 ) FROM tab1 AS cor0
----
1040
640
78

query IIIIIIIIIIII rowsort
SELECT ALL * FROM tab0, tab1 cor0 CROSS JOIN tab2, tab0 cor1
----
972 values hashing to 9a5ab925af18e11f7748f3b2e722ff3d

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + - col0 * + col1 col2 FROM tab2 AS cor0
----
-1343
-217
-4602

query I rowsort
SELECT DISTINCT col1 * - tab0.col1 + col0 AS col2 FROM tab0
----
-7372
-8192
-9374

query I rowsort
SELECT col1 * - tab1.col1 + - tab1.col2 * tab1.col0 FROM tab1
----
-3748
-7849
-838

query I rowsort
SELECT DISTINCT 63 * - cor1.col2 FROM tab2, tab2 AS cor0, tab2 AS cor1
----
-1638
-1701
-2394

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9835
SELECT ALL tab2.col2 * - CAST( col0 AS SIGNED ) * - col0 FROM tab2
----
1323
158184
237158

skipif mysql # not compatible
query I rowsort label-9835
SELECT ALL tab2.col2 * - CAST ( col0 AS INTEGER ) * - col0 FROM tab2
----
1323
158184
237158

query I rowsort
SELECT col2 + - tab2.col1 * 71 * col1 FROM tab2
----
-20481
-247125
-68204

onlyif mysql # use DIV operator for integer division
query I rowsort label-9837
SELECT + + col2 DIV ( + col1 + col1 ) AS col2 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9837
SELECT + + col2 / ( + col1 + col1 ) AS col2 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9838
SELECT col0 DIV col1 AS col1 FROM tab0 AS cor0
----
0
0
0

skipif mysql # not compatible
query I rowsort label-9838
SELECT col0 / col1 AS col1 FROM tab0 AS cor0
----
0
0
0

onlyif mysql # use DIV operator for integer division
query I rowsort label-9839
SELECT ALL - col0 * 96 DIV + col1 FROM tab2 AS cor0
----
-126
-21
-446

skipif mysql # not compatible
query I rowsort label-9839
SELECT ALL - col0 * 96 / + col1 FROM tab2 AS cor0
----
-126
-21
-446

query I rowsort
SELECT ALL - col1 * + ( - col1 ) AS col1 FROM tab0 AS cor0
----
7396
8281
9409

query I rowsort
SELECT DISTINCT + + cor0.col0 + - col0 FROM tab2 AS cor0
----
0

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + + col2 + - col0 * - 12 col2 FROM tab1 AS cor0
----
1056
825
90

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT + cor0.col2 * - 96 col2 FROM tab0 AS cor0
----
-3168
-7872
-96

onlyif mysql # use DIV operator for integer division
query I rowsort label-9844
SELECT ALL - cor0.col2 DIV ( - col2 ) - col0 AS col0 FROM tab1 cor0
----
-2
-63
-79

skipif mysql # not compatible
query I rowsort label-9844
SELECT ALL - cor0.col2 / ( - col2 ) - col0 AS col0 FROM tab1 cor0
----
-2
-63
-79

query I rowsort
SELECT col0 * + col0 + col2 * cor0.col2 AS col2 FROM tab0 AS cor0
----
1226
14645
1665

query I rowsort
SELECT ALL - col2 + + ( + 10 ) FROM tab1 AS cor0
----
-44
-47
-86

query I rowsort
SELECT - cor0.col0 * + ( 68 ) FROM tab2 AS cor0
----
-476
-5304
-5372

query I rowsort
SELECT DISTINCT - cor0.col1 * ( + col2 ) + col0 * cor0.col2 FROM tab1 AS cor0
----
-1242
3078
6432

query I rowsort
SELECT - - cor0.col2 * - 15 + cor0.col1 * + col1 AS col0 FROM tab0 AS cor0
----
6901
7051
9394

onlyif mysql # use DIV operator for integer division
query I rowsort label-9850
SELECT DISTINCT col2 DIV 11 - - 10 col0 FROM tab0 AS cor0
----
10
13
17

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9850
SELECT DISTINCT col2 / 11 - - 10 col0 FROM tab0 AS cor0
----
10
13
17

query I rowsort
SELECT + cor0.col0 * + ( 1 ) FROM tab1 AS cor0
----
3
64
80

query I rowsort
SELECT cor0.col1 * col2 + + ( col2 ) * + cor0.col1 AS col1 FROM tab1 AS cor0
----
1140
2496
2808

query I rowsort
SELECT DISTINCT - - col2 + 38 * 38 + col2 FROM tab1 AS cor0
----
1552
1558
1636

query I rowsort
SELECT ALL + - cor0.col2 + col2 * col0 FROM tab1 AS cor0
----
108
3591
7584

query I rowsort
SELECT - 7 * + 10 FROM tab0 AS cor0
----
-70
-70
-70

query I rowsort
SELECT ALL - - 92 FROM tab2 cor0
----
92
92
92

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9857
SELECT - CAST( NULL AS SIGNED ) + - col0 / col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9857
SELECT - CAST ( NULL AS INTEGER ) + - col0 / col0 FROM tab1 AS cor0
----
NULL
NULL
NULL

query I rowsort
SELECT DISTINCT - - 33 * cor0.col0 AS col0 FROM tab2 AS cor0
----
231
2574
2607

query I rowsort
SELECT DISTINCT - 90 * cor0.col2 AS col2 FROM tab1 cor0
----
-4860
-5130
-8640

onlyif mysql # use DIV operator for integer division
query I rowsort label-9860
SELECT DISTINCT - 93 DIV + col0 FROM tab0 AS cor0
----
-1
-2
-3

skipif mysql # not compatible
query I rowsort label-9860
SELECT DISTINCT - 93 / + col0 FROM tab0 AS cor0
----
-1
-2
-3

query I rowsort
SELECT ALL - col1 + col2 * + tab1.col0 AS col1 FROM tab1
----
136
3638
7667

query I rowsort
SELECT ALL - + col0 + - col0 AS col2 FROM tab0 AS cor0
----
-178
-48
-70

query I rowsort
SELECT + + col2 * col2 + col2 + col0 AS col2 FROM tab0 cor0
----
1146
37
6895

query I rowsort
SELECT DISTINCT 87 FROM tab2, tab0 cor0 CROSS JOIN tab0, tab1 AS cor1
----
87

query I rowsort
SELECT ALL + + 52 + cor0.col1 FROM tab2 AS cor0
----
111
69
83

query I rowsort
SELECT ALL + col0 + col0 * cor0.col2 + + col1 FROM tab0 AS cor0
----
167
7478
902

query I rowsort
SELECT col0 * col2 + + col1 FROM tab0 cor0
----
132
7389
878

query I rowsort
SELECT DISTINCT - col2 - + cor0.col0 AS col2 FROM tab0 AS cor0
----
-171
-36
-57

query I rowsort
SELECT DISTINCT 27 + - col0 * col2 FROM tab0
----
-7271
-765
-8

query I rowsort
SELECT + col0 + - col1 * col0 AS col1 FROM tab0
----
-2040
-3360
-8010

query I rowsort
SELECT + + cor0.col0 + col1 + + 75 FROM tab0 AS cor0
----
185
207
255

query I rowsort
SELECT DISTINCT cor0.col1 * 68 AS col1 FROM tab2 AS cor0
----
1156
2108
4012

query I rowsort
SELECT + col2 + - col1 + col0 AS col2 FROM tab1 AS cor0
----
111
163
31

query I rowsort
SELECT DISTINCT - cor0.col1 + col1 AS col2 FROM tab2 cor0
----
0

query I rowsort
SELECT ALL + col2 + 64 AS col2 FROM tab1 AS cor0
----
118
121
160

onlyif mysql # use DIV operator for integer division
query I rowsort label-9876
SELECT - col2 DIV ( col0 ) FROM tab0 AS cor0
----
-1
0
0

skipif mysql # not compatible
query I rowsort label-9876
SELECT - col2 / ( col0 ) FROM tab0 AS cor0
----
-1
0
0

query I rowsort
SELECT DISTINCT - col0 + ( + cor0.col1 ) AS col2 FROM tab2 AS cor0
----
-19
-62
24

onlyif mysql # use DIV operator for integer division
query I rowsort label-9878
SELECT DISTINCT + col1 DIV ( + ( + col2 ) ) FROM tab1 cor0
----
0

skipif mysql # not compatible
query I rowsort label-9878
SELECT DISTINCT + col1 / ( + ( + col2 ) ) FROM tab1 cor0
----
0

query I rowsort
SELECT - + 6 AS col2 FROM tab2, tab0, tab1 AS cor0
----
27 values hashing to 8be8910507908e6353d02a545b748252

onlyif mysql # use DIV operator for integer division
query I rowsort label-9880
SELECT 20 DIV col0 + 29 FROM tab0
----
29
29
29

skipif mysql # not compatible
query I rowsort label-9880
SELECT 20 / col0 + 29 FROM tab0
----
29
29
29

query I rowsort
SELECT ALL tab1.col1 + + col1 * 5 AS col2 FROM tab1
----
156
60
78

query I rowsort
SELECT ( col2 ) + + col1 * col2 + tab1.col1 AS col1 FROM tab1
----
1357
1484
637

onlyif mysql # use DIV operator for integer division
query I rowsort label-9883
SELECT + + ( col2 ) DIV 98 + - col0 FROM tab0 cor0
----
-24
-35
-89

skipif mysql # not compatible
query I rowsort label-9883
SELECT + + ( col2 ) / 98 + - col0 FROM tab0 cor0
----
-24
-35
-89

query I rowsort
SELECT ALL + 77 * - col0 FROM tab2
----
-539
-6006
-6083

query I rowsort
SELECT + 23 * cor0.col0 AS col1 FROM tab0 AS cor0
----
2047
552
805

onlyif mysql # use DIV operator for integer division
query I rowsort label-9886
SELECT ALL col1 + + CAST( 70 AS SIGNED ) + - col2 DIV + col2 AS col0 FROM tab1
----
79
82
95

skipif mysql # not compatible
query I rowsort label-9886
SELECT ALL col1 + + CAST ( 70 AS INTEGER ) + - col2 / + col2 AS col0 FROM tab1
----
79
82
95

query I rowsort
SELECT col0 + col1 * 35 FROM tab0
----
3034
3274
3430

query I rowsort
SELECT ALL cor0.col1 AS col2 FROM tab1, tab0 AS cor0, tab2 AS cor1
----
27 values hashing to 2d6d3031dfe90e0c02db13aa63993bfd

query I rowsort
SELECT DISTINCT col2 + tab1.col2 + col2 AS col2 FROM tab1
----
162
171
288

query I rowsort
SELECT ALL - col1 + - tab0.col2 * col2 AS col1 FROM tab0
----
-1175
-6815
-98

query I rowsort
SELECT ALL + cor0.col1 + col2 + cor0.col1 FROM tab1 cor0
----
106
122
77

query I rowsort
SELECT cor1.col1 + cor0.col2 AS col1 FROM tab1, tab1 AS cor0, tab0 AS cor1
----
27 values hashing to 193f02533a54aa725386e300dcc85182

query I rowsort
SELECT + - col1 * cor0.col1 - - col1 FROM tab1 AS cor0
----
-156
-650
-90

query I rowsort
SELECT DISTINCT col0 - + col2 * + col1 FROM tab1 AS cor0
----
-1168
-1401
-506

query I rowsort
SELECT ALL col0 * - 68 AS col1 FROM tab2
----
-476
-5304
-5372

query I rowsort
SELECT ALL + tab1.col2 + + 11 * 2 AS col1 FROM tab1, tab0, tab2 AS cor0
----
27 values hashing to 0ad7add517ddf9496ca7c04f212ad712

query I rowsort
SELECT ALL 68 AS col2 FROM tab1, tab2 AS cor0, tab2 AS cor1
----
27 values hashing to 10aa25f1c6b97582c34521ac6452e0b4

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9898
SELECT - CAST( NULL AS SIGNED ) * cor0.col0 + col2 * - ( col1 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9898
SELECT - CAST ( NULL AS INTEGER ) * cor0.col0 + col2 * - ( col1 ) FROM tab0 AS cor0
----
NULL
NULL
NULL

onlyif mysql # use DIV operator for integer division
query I rowsort label-9899
SELECT + + 88 + col0 DIV col1 FROM tab2 AS cor0
----
88
89
92

skipif mysql # not compatible
query I rowsort label-9899
SELECT + + 88 + col0 / col1 FROM tab2 AS cor0
----
88
89
92

query I rowsort
SELECT ALL 43 * col0 AS col1 FROM tab0 AS cor0
----
1032
1505
3827

skipif mysql # not compatible
query I rowsort
SELECT - + CAST ( 40 AS REAL ) * col2 AS col0 FROM tab1 AS cor0
----
-2160
-2280
-3840

onlyif mysql # use DIV operator for integer division
query I rowsort label-9902
SELECT col0 DIV + 73 FROM tab2 cor0
----
0
1
1

skipif mysql # not compatible
query I rowsort label-9902
SELECT col0 / + 73 FROM tab2 cor0
----
0
1
1

query I rowsort
SELECT - col1 * col0 + - col0 FROM tab2
----
-1422
-224
-4680

query I rowsort
SELECT DISTINCT col0 * col1 + + 29 FROM tab1
----
1069
107
669

query I rowsort
SELECT DISTINCT col2 + - tab1.col1 * + tab1.col1 FROM tab1
----
-43
-622
-73

onlyif mysql # use DIV operator for integer division
query I rowsort label-9906
SELECT + 20 + - col0 DIV + col0 AS col1 FROM tab0 AS cor0
----
19
19
19

skipif mysql # not compatible
query I rowsort label-9906
SELECT + 20 + - col0 / + col0 AS col1 FROM tab0 AS cor0
----
19
19
19

skipif mysql # not compatible
query I rowsort
SELECT + CAST ( col1 AS REAL ) * col0 + col2 AS col0 FROM tab2 AS cor0
----
1381
244
4628

onlyif mysql # use DIV operator for integer division
query I rowsort label-9908
SELECT cor0.col1 * + col1 + + col1 DIV 83 FROM tab0 AS cor0
----
7397
8282
9410

skipif mysql # not compatible
query I rowsort label-9908
SELECT cor0.col1 * + col1 + + col1 / 83 FROM tab0 AS cor0
----
7397
8282
9410

onlyif mysql # use DIV operator for integer division
query I rowsort label-9909
SELECT + ( cor0.col0 ) DIV col0 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9909
SELECT + ( cor0.col0 ) / col0 FROM tab1 AS cor0
----
1
1
1

onlyif mysql # use DIV operator for integer division
query I rowsort label-9910
SELECT ( col2 ) + + col1 DIV 23 - 0 col0 FROM tab1
----
55
57
96

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9910
SELECT ( col2 ) + + col1 / 23 - 0 col0 FROM tab1
----
55
57
96

query I rowsort
SELECT col0 * + col0 - cor0.col0 * + 19 AS col1 FROM tab1 AS cor0
----
-48
2880
4880

query I rowsort
SELECT DISTINCT + 43 + col1 - col1 AS col1 FROM tab0
----
43

query I rowsort
SELECT + 25 * col1 + - col2 FROM tab1
----
193
229
596

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9914
SELECT - CAST( + 21 AS SIGNED ) * col2 + col2 col0 FROM tab0 AS cor0
----
-1640
-20
-660

skipif postgresql # PostgreSQL requires AS when renaming output columns
skipif mysql # not compatible
query I rowsort label-9914
SELECT - CAST ( + 21 AS INTEGER ) * col2 + col2 col0 FROM tab0 AS cor0
----
-1640
-20
-660

query I rowsort
SELECT ( col2 ) + col0 * cor0.col1 * col2 AS col2 FROM tab1 AS cor0
----
36537
4266
99936

query I rowsort
SELECT + col0 - + 51 * + cor0.col0 FROM tab2 AS cor0
----
-350
-3900
-3950

query I rowsort
SELECT - + 34 * col0 + col0 AS col1 FROM tab1 AS cor0
----
-2112
-2640
-99

onlyif mysql # use DIV operator for integer division
query I rowsort label-9918
SELECT ALL - - 44 * col2 DIV - ( cor0.col1 * - cor0.col2 ) FROM tab1 AS cor0
----
1
3
4

skipif mysql # not compatible
query I rowsort label-9918
SELECT ALL - - 44 * col2 / - ( cor0.col1 * - cor0.col2 ) FROM tab1 AS cor0
----
1
3
4

query I rowsort
SELECT DISTINCT 18 FROM tab1 cor0
----
18

onlyif mysql # use DIV operator for integer division
query I rowsort label-9920
SELECT - + 64 DIV cor0.col1 + + col1 FROM tab1 cor0
----
24
4
9

skipif mysql # not compatible
query I rowsort label-9920
SELECT - + 64 / cor0.col1 + + col1 FROM tab1 cor0
----
24
4
9

query I rowsort
SELECT - - col0 * - col0 AS col2 FROM tab2 AS cor0
----
-49
-6084
-6241

query I rowsort
SELECT col0 + - col2 * - cor0.col1 + - col2 * col0 AS col2 FROM tab2 AS cor0
----
-2277
-416
655

query I rowsort
SELECT - 5 + col2 * + col1 AS col2 FROM tab1 AS cor0
----
1243
1399
565

query I rowsort
SELECT - - col1 * + col0 * - col0 FROM tab2 AS cor0
----
-106097
-1519
-358956

query I rowsort
SELECT col2 * ( - tab1.col1 ) FROM tab1
----
-1248
-1404
-570

query I rowsort
SELECT ALL ( 59 ) FROM tab1
----
59
59
59

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + 85 col1 FROM tab0
----
85

query I rowsort
SELECT DISTINCT + cor0.col2 * col2 + col1 FROM tab1 cor0
----
2942
3259
9229

query I rowsort
SELECT - 74 FROM tab1, tab2 AS cor0
----
9 values hashing to 5a567947d14593676e3825756f8e6130

query I rowsort
SELECT - 69 + - col0 FROM tab0
----
-104
-158
-93

query I rowsort
SELECT - col0 + + tab0.col2 * col2 FROM tab0
----
-34
1065
6635

onlyif mysql # use DIV operator for integer division
query I rowsort label-9932
SELECT + tab1.col2 DIV + tab1.col0 FROM tab1
----
0
1
18

skipif mysql # not compatible
query I rowsort label-9932
SELECT + tab1.col2 / + tab1.col0 FROM tab1
----
0
1
18

query I rowsort
SELECT - 23 * cor0.col0 FROM tab1 AS cor0
----
-1472
-1840
-69

query I rowsort
SELECT ALL - col1 + + 24 FROM tab1
----
-2
11
14

query IIIIIIIIIIII rowsort
SELECT * FROM tab1, tab2 cor0, tab2, tab0 cor1
----
972 values hashing to e4c748f267e8d2a0e6d563281e1fb975

query I rowsort
SELECT - 63 * col0 FROM tab0 cor0
----
-1512
-2205
-5607

query I rowsort
SELECT DISTINCT - 96 * col1 + - 58 FROM tab0 AS cor0
----
-8314
-8794
-9370

query I rowsort
SELECT ALL + ( + col0 ) * + col1 - 37 AS col1 FROM tab0 AS cor0
----
2027
3358
8062

query I rowsort
SELECT DISTINCT - + col0 * - col2 + - col1 AS col1 FROM tab2 cor0
----
158
1969
2985

query I rowsort
SELECT 81 * - col1 FROM tab2
----
-1377
-2511
-4779

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9941
SELECT DISTINCT - col1 * + col1 - CAST( - col2 AS SIGNED ) FROM tab2 AS cor0
----
-251
-3455
-934

skipif mysql # not compatible
query I rowsort label-9941
SELECT DISTINCT - col1 * + col1 - CAST ( - col2 AS INTEGER ) FROM tab2 AS cor0
----
-251
-3455
-934

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9942
SELECT - 33 + col1 * + CAST( - col2 AS SIGNED ) AS col1 FROM tab0 AS cor0
----
-130
-2871
-7495

skipif mysql # not compatible
query I rowsort label-9942
SELECT - 33 + col1 * + CAST ( - col2 AS INTEGER ) AS col1 FROM tab0 AS cor0
----
-130
-2871
-7495

query I rowsort
SELECT ALL cor0.col2 + - col2 AS col2 FROM tab2 cor0
----
0
0
0

query I rowsort
SELECT 29 * - col1 AS col0 FROM tab2 AS cor0
----
-1711
-493
-899

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT - - col2 * col0 col2 FROM tab0 AS cor0
----
35
7298
792

query I rowsort
SELECT - col0 * 45 FROM tab1 AS cor0
----
-135
-2880
-3600

query I rowsort
SELECT - 60 + 63 FROM tab1 AS cor0
----
3
3
3

query I rowsort
SELECT ALL col1 * ( - 42 ) AS col2 FROM tab2
----
-1302
-2478
-714

query I rowsort
SELECT col0 * - ( - 29 ) FROM tab2
----
203
2262
2291

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT + col0 * - col0 * + col1 col0 FROM tab1
----
-234
-40960
-83200

onlyif mysql # use DIV operator for integer division
query I rowsort label-9951
SELECT ALL col2 DIV + ( + col2 ) FROM tab0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9951
SELECT ALL col2 / + ( + col2 ) FROM tab0
----
1
1
1

query I rowsort
SELECT DISTINCT - ( col2 ) + tab1.col2 FROM tab1
----
0

query I rowsort
SELECT + col0 * 40 FROM tab0
----
1400
3560
960

query I rowsort
SELECT ALL + col1 * col1 + col2 AS col0 FROM tab0
----
7429
8363
9410

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9955
SELECT CAST( NULL AS SIGNED ) * + 50 AS col0 FROM tab1
----
NULL
NULL
NULL

skipif mysql # not compatible
query I rowsort label-9955
SELECT CAST ( NULL AS INTEGER ) * + 50 AS col0 FROM tab1
----
NULL
NULL
NULL

query I rowsort
SELECT col0 * - ( col2 ) AS col1 FROM tab0
----
-35
-7298
-792

onlyif mysql # use DIV operator for integer division
query I rowsort label-9957
SELECT col1 DIV 69 + tab0.col2 FROM tab0
----
2
34
83

skipif mysql # not compatible
query I rowsort label-9957
SELECT col1 / 69 + tab0.col2 FROM tab0
----
2
34
83

onlyif mysql # use DIV operator for integer division
query I rowsort label-9958
SELECT ALL + 28 * col0 + - col1 DIV - CAST( + col2 AS SIGNED ) AS col0 FROM tab1 cor0
----
1792
2240
84

skipif mysql # not compatible
query I rowsort label-9958
SELECT ALL + 28 * col0 + - col1 / - CAST ( + col2 AS INTEGER ) AS col0 FROM tab1 cor0
----
1792
2240
84

query I rowsort
SELECT cor0.col0 AS col1 FROM tab0 AS cor0 CROSS JOIN tab2 AS cor1
----
9 values hashing to 8b49799942a9e353a3d279cf64ef3f63

query I rowsort
SELECT ALL - + col1 * - col0 + col0 FROM tab2 AS cor0
----
1422
224
4680

query I rowsort
SELECT ALL - tab2.col2 AS col2 FROM tab2, tab1 AS cor0
----
9 values hashing to 7b5938124253798426fbf09c18e1fd75

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT ALL - 61 * col0 col0 FROM tab1 AS cor0
----
-183
-3904
-4880

query I rowsort
SELECT DISTINCT - + 72 * - col0 AS col0 FROM tab0 AS cor0
----
1728
2520
6408

query I rowsort
SELECT ALL + - 92 * + col2 FROM tab2 AS cor0
----
-2392
-2484
-3496

query I rowsort
SELECT ALL - col0 + col1 * 88 AS col0 FROM tab1 AS cor0
----
1064
2285
816

query I rowsort
SELECT - - 81 * - col1 AS col2 FROM tab2 AS cor0
----
-1377
-2511
-4779

onlyif mysql # use DIV operator for integer division
query I rowsort label-9967
SELECT + col1 DIV + col1 AS col1 FROM tab1 AS cor0
----
1
1
1

skipif mysql # not compatible
query I rowsort label-9967
SELECT + col1 / + col1 AS col1 FROM tab1 AS cor0
----
1
1
1

query I rowsort
SELECT DISTINCT + + col2 * - col2 * - col0 FROM tab0 AS cor0
----
26136
35
598436

query I rowsort
SELECT DISTINCT col2 - - ( col0 ) FROM tab2
----
104
117
34

onlyif mysql # use DIV operator for integer division
query I rowsort label-9970
SELECT col0 DIV + col2 + col0 + - col0 FROM tab1
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9970
SELECT col0 / + col2 + col0 + - col0 FROM tab1
----
0
0
1

query I rowsort
SELECT - 40 FROM tab2, tab2 AS cor0, tab0 AS cor1
----
27 values hashing to 01aad4539198a6509248e086869f90a6

query I rowsort
SELECT + - cor0.col2 * 2 AS col0 FROM tab2 AS cor0
----
-52
-54
-76

query I rowsort
SELECT - cor0.col2 * - cor0.col0 AS col2 FROM tab1 AS cor0
----
162
3648
7680

query I rowsort
SELECT DISTINCT col2 - - 40 FROM tab1 AS cor0
----
136
94
97

query I rowsort
SELECT + col1 * + cor0.col1 AS col0 FROM tab1 AS cor0
----
100
169
676

query I rowsort
SELECT DISTINCT - col1 + + col2 * col0 FROM tab1 AS cor0
----
136
3638
7667

query I rowsort
SELECT ALL - col1 - 77 * col2 * col0 AS col1 FROM tab0 AS cor0
----
-2792
-562037
-61070

onlyif mysql # use DIV operator for integer division
query I rowsort label-9978
SELECT - cor0.col1 + col0 DIV col1 FROM tab0 AS cor0
----
-86
-91
-97

skipif mysql # not compatible
query I rowsort label-9978
SELECT - cor0.col1 + col0 / col1 FROM tab0 AS cor0
----
-86
-91
-97

query I rowsort
SELECT 82 + col1 + col1 * ( - col2 ) AS col2 FROM tab1 AS cor0
----
-1153
-1296
-478

onlyif mysql # use DIV operator for integer division
query I rowsort label-9980
SELECT DISTINCT col1 DIV cor0.col1 AS col2 FROM tab2 cor0
----
1

skipif mysql # not compatible
query I rowsort label-9980
SELECT DISTINCT col1 / cor0.col1 AS col2 FROM tab2 cor0
----
1

query I rowsort
SELECT DISTINCT + 35 + col0 * col2 AS col1 FROM tab1 AS cor0
----
197
3683
7715

query I rowsort
SELECT + ( col1 ) + col0 * - 76 * + col2 FROM tab2 AS cor0
----
-14333
-154069
-228135

query I rowsort
SELECT col2 * 73 FROM tab1 cor0
----
3942
4161
7008

onlyif mysql # use DIV operator for integer division
query I rowsort label-9984
SELECT - + ( - col2 ) DIV col0 FROM tab0 AS cor0
----
0
0
1

skipif mysql # not compatible
query I rowsort label-9984
SELECT - + ( - col2 ) / col0 FROM tab0 AS cor0
----
0
0
1

query I rowsort
SELECT ALL col1 + 98 * + col1 AS col2 FROM tab1 AS cor0
----
1287
2574
990

onlyif mysql # support for MySQL specific system types and syntax
query I rowsort label-9986
SELECT DISTINCT + CAST( NULL AS SIGNED ) / cor0.col2 AS col0 FROM tab1 AS cor0
----
NULL

skipif mysql # not compatible
query I rowsort label-9986
SELECT DISTINCT + CAST ( NULL AS INTEGER ) / cor0.col2 AS col0 FROM tab1 AS cor0
----
NULL

query I rowsort
SELECT DISTINCT + 78 * 36 + cor0.col0 AS col0 FROM tab2 cor0
----
2815
2886
2887

onlyif mysql # use DIV operator for integer division
query I rowsort label-9988
SELECT col1 + - col0 - col2 DIV + cor0.col2 FROM tab1 AS cor0
----
-55
-68
22

skipif mysql # not compatible
query I rowsort label-9988
SELECT col1 + - col0 - col2 / + cor0.col2 FROM tab1 AS cor0
----
-55
-68
22

query I rowsort
SELECT ALL + + 91 FROM tab0 AS cor0
----
91
91
91

query I rowsort
SELECT + col1 + + 21 AS col1 FROM tab1
----
31
34
47

query I rowsort
SELECT tab0.col2 + ( + col2 * col0 ) + - ( ( + col2 ) ) * tab0.col0 FROM tab0
----
1
33
82

onlyif mysql # use DIV operator for integer division
query I rowsort label-9992
SELECT DISTINCT col1 DIV tab2.col0 - col1 FROM tab2
----
-17
-27
-59

skipif mysql # not compatible
query I rowsort label-9992
SELECT DISTINCT col1 / tab2.col0 - col1 FROM tab2
----
-17
-27
-59

onlyif mysql # use DIV operator for integer division
query I rowsort label-9993
SELECT col2 * col1 DIV tab0.col1 - + col0 AS col1 FROM tab0
----
-34
-7
9

skipif mysql # not compatible
query I rowsort label-9993
SELECT col2 * col1 / tab0.col1 - + col0 AS col1 FROM tab0
----
-34
-7
9

query I rowsort
SELECT + 80 AS col1 FROM tab0, tab1 AS cor0
----
9 values hashing to 878f012d707aab113cedaf56e6c52e94

query I rowsort
SELECT DISTINCT tab1.col2 - - 75 FROM tab1
----
129
132
171

query I rowsort
SELECT + col2 + - 50 + - tab1.col1 FROM tab1
----
-22
-3
33

skipif postgresql # PostgreSQL requires AS when renaming output columns
query I rowsort
SELECT DISTINCT - - 56 * + col0 + + cor0.col0 * + ( - col2 ) col1 FROM tab0 AS cor0
----
-2314
1925
552

query I rowsort
SELECT + 58 * col2 + + col1 AS col2 FROM tab2 AS cor0
----
1567
1597
2221

onlyif mysql # use DIV operator for integer division
query I rowsort label-9999
SELECT ALL ( col0 ) DIV col1 AS col0 FROM tab1 AS cor0
----
0
6
6

skipif mysql # not compatible
query I rowsort label-9999
SELECT ALL ( col0 ) / col1 AS col0 FROM tab1 AS cor0
----
0
6
6

